From 32fe3b5ef7f24bbda823866f73e189ea6207aeb7 Mon Sep 17 00:00:00 2001 From: Christophe Rhodes Date: Thu, 22 Dec 2016 16:41:22 +0000 Subject: [PATCH] add -no-pie Makefile stanza for x86-linux (now builds with --arch=x86 work again on current-ish debian) --- src/runtime/Config.x86-linux | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/runtime/Config.x86-linux b/src/runtime/Config.x86-linux index 117630b6a..cd5859479 100644 --- a/src/runtime/Config.x86-linux +++ b/src/runtime/Config.x86-linux @@ -49,6 +49,14 @@ LINKFLAGS += -nopie LDFLAGS += -nopie endif +# The following works for Ubuntu 16.10. There must be a better way to +# do this across various flavors of linux. +ifneq ($(shell $(CC) -dumpspecs 2>/dev/null | grep -e no-pie),) +CFLAGS += -fno-pie +LINKFLAGS += -no-pie +LDFLAGS += -no-pie +endif + GC_SRC = gencgc.c # Nothing to do for after-grovel-headers. -- 2.11.4.GIT