[linux] 02/02: [amd64] kbuild: Add -fno-PIE to scripts/gcc-x86_64-has-stack-protector.sh

debian-kernel at lists.debian.org debian-kernel at lists.debian.org
Thu Nov 3 23:23:34 UTC 2016


This is an automated email from the git hooks/post-receive script.

benh pushed a commit to branch master
in repository linux.

commit 7aecddec046dd1f5437a5b1846600395eb3f4aa4
Author: Ben Hutchings <ben at decadent.org.uk>
Date:   Thu Nov 3 16:51:48 2016 -0600

    [amd64] kbuild: Add -fno-PIE to scripts/gcc-x86_64-has-stack-protector.sh
---
 debian/patches/bugfix/all/kbuild-add-fno-pie.patch | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/debian/patches/bugfix/all/kbuild-add-fno-pie.patch b/debian/patches/bugfix/all/kbuild-add-fno-pie.patch
index b284510..4bd05cb 100644
--- a/debian/patches/bugfix/all/kbuild-add-fno-pie.patch
+++ b/debian/patches/bugfix/all/kbuild-add-fno-pie.patch
@@ -14,6 +14,7 @@ Also add to KBUILD_AFLAGSi due to:
 |arch/x86/entry/vdso/vdso32/note.S:1:0: sorry, unimplemented: -mfentry isn’t supported for 32-bit in c ombination with -fpic
 
 Signed-off-by: Sebastian Andrzej Siewior <bigeasy at linutronix.de>
+[bwh: Also add the option to scripts/gcc-x86_64-has-stack-protector.sh]
 ---
  Makefile | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
@@ -35,3 +36,13 @@ Signed-off-by: Sebastian Andrzej Siewior <bigeasy at linutronix.de>
  KBUILD_AFLAGS_MODULE  := -DMODULE
  KBUILD_CFLAGS_MODULE  := -DMODULE
  KBUILD_LDFLAGS_MODULE := -T $(srctree)/scripts/module-common.lds
+--- a/scripts/gcc-x86_64-has-stack-protector.sh
++++ b/scripts/gcc-x86_64-has-stack-protector.sh
+@@ -1,6 +1,6 @@
+ #!/bin/sh
+ 
+-echo "int foo(void) { char X[200]; return 3; }" | $* -S -x c -c -O0 -mcmodel=kernel -fstack-protector - -o - 2> /dev/null | grep -q "%gs"
++echo "int foo(void) { char X[200]; return 3; }" | $* -S -x c -c -O0 -mcmodel=kernel -fno-PIE -fstack-protector - -o - 2> /dev/null | grep -q "%gs"
+ if [ "$?" -eq "0" ] ; then
+ 	echo y
+ else

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/kernel/linux.git



More information about the Kernel-svn-changes mailing list