From 76a8dfe8fcd964cdb018e17d49603143efd6720d Mon Sep 17 00:00:00 2001 From: nico Date: Tue, 2 Jan 2007 19:36:39 +0000 Subject: fix grub segfaults on hosts where gcc is built with stack smashing protection git-svn-id: svn://svn.openwrt.org/openwrt/trunk@5969 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- target/linux/x86-2.6/image/grub/Makefile | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'target/linux') diff --git a/target/linux/x86-2.6/image/grub/Makefile b/target/linux/x86-2.6/image/grub/Makefile index e30443e18..365b32762 100644 --- a/target/linux/x86-2.6/image/grub/Makefile +++ b/target/linux/x86-2.6/image/grub/Makefile @@ -43,6 +43,7 @@ ifeq ($(HOST_ARCH),x86_64) --mandir=/usr/man \ --infodir=/usr/info \ $(DISABLE_NLS) \ + --disable-auto-linux-mem-opt \ ) endef else @@ -62,12 +63,20 @@ else --localstatedir=/var \ --mandir=/usr/man \ --infodir=/usr/info \ + $(DISABLE_NLS) \ + --disable-auto-linux-mem-opt \ ) endef endif +# +# ./configure detects whether the host compiler supports +# -fno-stack-protector but only sets STAGE2_CFLAGS accordingly +# define Build/Compile - $(MAKE) -C $(PKG_BUILD_DIR) + $(MAKE) -C $(PKG_BUILD_DIR) \ + GRUB_CFLAGS="\$$$$(STAGE2_CFLAGS)" \ + STAGE1_CFLAGS="\$$$$(STAGE2_CFLAGS)" endef define Build/InstallDev -- cgit v1.2.3