From 4d54b1daeefc0acd44a6d8971c70104a534ed853 Mon Sep 17 00:00:00 2001 From: Mark Wright Date: Wed, 1 Mar 2017 23:57:07 +1100 Subject: dev-lisp/sbcl: Fix the detection of -nopie and -no-pie. The change 3403dbaffc0a9bab49b78cf0bb5308cce0a0c153 that upstream did for https://bugs.launchpad.net/sbcl/+bug/1633559 does not work on Gentoo. So it was patched out in the fix for #607302 with sbcl-1.3.14-config.patch, which unfortunately leads to #583930. Thanks to Toralf Forster for reporting, and grozin for testing. Gentoo-bug: 599902, 607302, 583930 Package-Manager: portage-2.3.3 --- dev-lisp/sbcl/files/sbcl-1.3.14-config.patch | 22 ---------------------- ...4-gentoo-fix_nopie_for_hardened_toolchain.patch | 17 +++++++++++++++++ 2 files changed, 17 insertions(+), 22 deletions(-) delete mode 100644 dev-lisp/sbcl/files/sbcl-1.3.14-config.patch create mode 100644 dev-lisp/sbcl/files/sbcl-1.3.14-gentoo-fix_nopie_for_hardened_toolchain.patch (limited to 'dev-lisp/sbcl/files') diff --git a/dev-lisp/sbcl/files/sbcl-1.3.14-config.patch b/dev-lisp/sbcl/files/sbcl-1.3.14-config.patch deleted file mode 100644 index c12700d0d6f7..000000000000 --- a/dev-lisp/sbcl/files/sbcl-1.3.14-config.patch +++ /dev/null @@ -1,22 +0,0 @@ -diff -Nuar a/src/runtime/GNUmakefile b/src/runtime/GNUmakefile ---- a/src/runtime/GNUmakefile 2017-01-22 20:43:20.000000000 +0100 -+++ b/src/runtime/GNUmakefile 2017-02-09 15:42:22.340029401 +0100 -@@ -39,18 +39,6 @@ - # OS_SRC, OS_LIBS, OS_CLEAN_FILES - include Config - --# Disable PIE when possible --ifneq ($(shell $(CC) -dumpspecs 2>/dev/null | grep -e no-pie),) --CFLAGS += -fno-pie --LINKFLAGS += -no-pie --LDFLAGS += -no-pie --endif --ifneq ($(shell $(CC) -dumpspecs 2>/dev/null | grep -e -nopie),) --CFLAGS += -fno-pie --LINKFLAGS += -nopie --LDFLAGS += -nopie --endif -- - COMMON_SRC = alloc.c backtrace.c breakpoint.c coreparse.c dynbind.c \ - funcall.c gc-common.c globals.c interr.c interrupt.c \ - largefile.c monitor.c os-common.c parse.c print.c purify.c \ diff --git a/dev-lisp/sbcl/files/sbcl-1.3.14-gentoo-fix_nopie_for_hardened_toolchain.patch b/dev-lisp/sbcl/files/sbcl-1.3.14-gentoo-fix_nopie_for_hardened_toolchain.patch new file mode 100644 index 000000000000..aa74a2d61354 --- /dev/null +++ b/dev-lisp/sbcl/files/sbcl-1.3.14-gentoo-fix_nopie_for_hardened_toolchain.patch @@ -0,0 +1,17 @@ +--- sbcl-1.3.14-orig/src/runtime/GNUmakefile 2017-01-23 06:43:20.000000000 +1100 ++++ sbcl-1.3.14/src/runtime/GNUmakefile 2017-02-28 12:44:37.627161988 +1100 +@@ -40,12 +40,12 @@ + include Config + + # Disable PIE when possible +-ifneq ($(shell $(CC) -dumpspecs 2>/dev/null | grep -e no-pie),) ++ifneq ($(shell $(CC) -dumpspecs 2>/dev/null | grep -e '[^f]no-pie'),) + CFLAGS += -fno-pie + LINKFLAGS += -no-pie + LDFLAGS += -no-pie + endif +-ifneq ($(shell $(CC) -dumpspecs 2>/dev/null | grep -e -nopie),) ++ifneq ($(shell $(CC) -dumpspecs 2>/dev/null | grep -e '[^f]nopie'),) + CFLAGS += -fno-pie + LINKFLAGS += -nopie + LDFLAGS += -nopie -- cgit v1.2.3-65-gdbad