[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Minios-devel] [UNIKRAFT PATCH 01/22] build: Remove the check of '--enable-default-pie' in Makefile.uk


  • To: <minios-devel@xxxxxxxxxxxxxxxxxxxx>, <simon.kuenzer@xxxxxxxxx>
  • From: Wei Chen <wei.chen@xxxxxxx>
  • Date: Thu, 8 Nov 2018 09:51:32 +0000
  • Authentication-results: spf=pass (sender IP is 40.67.248.234) smtp.mailfrom=arm.com; lists.xenproject.org; dkim=none (message not signed) header.d=none;lists.xenproject.org; dmarc=bestguesspass action=none header.from=arm.com;
  • Cc: Kaly.Xin@xxxxxxx, nd@xxxxxxx, wei.chen@xxxxxxx
  • Delivery-date: Thu, 08 Nov 2018 09:52:11 +0000
  • List-id: Mini-os development list <minios-devel.lists.xenproject.org>
  • Nodisclaimer: True
  • Spamdiagnosticmetadata: NSPM
  • Spamdiagnosticoutput: 1:99

As discussed in mailing list [1], the check for '--enable-default-pie'
is unnecessary, because GCC supports '-no-pie' as soon as it.
We have checked '-no-pie' already. So we can remove the check for
'--enable-default-pie' to get rid of the console command.

[1]https://lists.xenproject.org/archives/html/minios-devel/2018-09/msg00067.html

Signed-off-by: Wei Chen <wei.chen@xxxxxxx>
---
 Makefile.uk | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/Makefile.uk b/Makefile.uk
index 0cc6690..2d11544 100644
--- a/Makefile.uk
+++ b/Makefile.uk
@@ -57,13 +57,11 @@ ASFLAGS  += -DUK_VERSION=$(UK_VERSION).$(UK_SUBVERSION) 
-DUK_FULLVERSION=$(UK_FU
 CFLAGS   += -DUK_VERSION=$(UK_VERSION).$(UK_SUBVERSION) 
-DUK_FULLVERSION=$(UK_FULLVERSION) -DUK_CODENAME="$(UK_CODENAME)"
 CXXFLAGS += -DUK_VERSION=$(UK_VERSION).$(UK_SUBVERSION) 
-DUK_FULLVERSION=$(UK_FULLVERSION) -DUK_CODENAME="$(UK_CODENAME)"
 
-# Check whether the pie option is enabled by default. If possible,
-# add -no-pie to link flags to override default pie option.
-PIE_ON = $(shell $(CC) -v 2>&1 | grep -Fo "enable-default-pie")
-ifneq ($(PIE_ON),)
+# If GCC supports "-no-pie" flag, we will add this flag to link flags to
+# override "pie" option, because some distributions will set
+# "--enbale-default-pie" by default.
 ASFLAGS-$(call gcc_version_ge,6,1)     += -no-pie
 CFLAGS-$(call gcc_version_ge,6,1)      += -no-pie
 CXXFLAGS-$(call gcc_version_ge,6,1)    += -no-pie
 LIBLDFLAGS-$(call gcc_version_ge,6,1)  += -no-pie
 LDFLAGS-$(call gcc_version_ge,6,1)     += -no-pie
-endif
-- 
2.17.1


_______________________________________________
Minios-devel mailing list
Minios-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/minios-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.