diff options
author | Florian Fainelli <florian@openwrt.org> | 2009-09-06 13:42:50 +0000 |
---|---|---|
committer | Florian Fainelli <florian@openwrt.org> | 2009-09-06 13:42:50 +0000 |
commit | 77c4df9e45673bb810a83ea5c329e78586935a41 (patch) | |
tree | 902f23d97f1c5c24ddf8b74702924fd57d47820b /target/linux/uml | |
parent | 37f1b4ed7d858565d7152f1d80bbd8b6d5ae0ec9 (diff) | |
download | mtk-20170518-77c4df9e45673bb810a83ea5c329e78586935a41.zip mtk-20170518-77c4df9e45673bb810a83ea5c329e78586935a41.tar.gz mtk-20170518-77c4df9e45673bb810a83ea5c329e78586935a41.tar.bz2 |
fix build failures with bash4
SVN-Revision: 17525
Diffstat (limited to 'target/linux/uml')
-rw-r--r-- | target/linux/uml/patches/005-fix_bash4_builds.patch | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/target/linux/uml/patches/005-fix_bash4_builds.patch b/target/linux/uml/patches/005-fix_bash4_builds.patch new file mode 100644 index 0000000..9561824 --- /dev/null +++ b/target/linux/uml/patches/005-fix_bash4_builds.patch @@ -0,0 +1,49 @@ +commit 67dac695a1f33716f3e35c2292e7391410d58751 +Author: Paul Bolle <pebolle@tiscali.nl> +Date: Sun Sep 6 14:36:01 2009 +0200 + + um: add work around for build problems with bash 4 + + Building User Mode Linux fails with bash 4. The UML Makefiles use an + environment variable called CPPFLAGS_vmlinux.lds but bash 4 does not + export environment variables with a dot in their name. Add a hack to + allow building UML with bash 4 (which should not affect other shells). + + Signed-off-by: Paul Bolle <pebolle@tiscali.nl> + +diff --git a/arch/um/Makefile b/arch/um/Makefile +index 0728def..dc1ea7d 100644 +--- a/arch/um/Makefile ++++ b/arch/um/Makefile +@@ -99,9 +99,6 @@ CFLAGS_NO_HARDENING := $(call cc-option, -fno-PIC,) $(call cc-option, -fno-pic,) + CONFIG_KERNEL_STACK_ORDER ?= 2 + STACK_SIZE := $(shell echo $$[ 4096 * (1 << $(CONFIG_KERNEL_STACK_ORDER)) ] ) + +-CPPFLAGS_vmlinux.lds = -U$(SUBARCH) -DSTART=$(START) -DELF_ARCH=$(ELF_ARCH) \ +- -DELF_FORMAT="$(ELF_FORMAT)" -DKERNEL_STACK_SIZE=$(STACK_SIZE) +- + # The wrappers will select whether using "malloc" or the kernel allocator. + LINK_WRAPS = -Wl,--wrap,malloc -Wl,--wrap,free -Wl,--wrap,calloc + +@@ -152,4 +149,5 @@ $(SHARED_HEADERS)/kern_constants.h: + $(Q)mkdir -p $(dir $@) + $(Q)echo '#include "../../../../include/asm/asm-offsets.h"' >$@ + +-export SUBARCH USER_CFLAGS CFLAGS_NO_HARDENING OS HEADER_ARCH DEV_NULL_PATH ++export SUBARCH USER_CFLAGS CFLAGS_NO_HARDENING OS HEADER_ARCH DEV_NULL_PATH \ ++ ELF_ARCH ELF_FORMAT STACK_SIZE START +diff --git a/arch/um/kernel/Makefile b/arch/um/kernel/Makefile +index 388ec0a..2907436 100644 +--- a/arch/um/kernel/Makefile ++++ b/arch/um/kernel/Makefile +@@ -3,6 +3,10 @@ + # Licensed under the GPL + # + ++CPPFLAGS_vmlinux.lds = -P -C -U$(ARCH) -U$(SUBARCH) -DSTART=$(START) \ ++ -DELF_ARCH=$(ELF_ARCH) -DELF_FORMAT="$(ELF_FORMAT)" \ ++ -DKERNEL_STACK_SIZE=$(STACK_SIZE) ++ + extra-y := vmlinux.lds + clean-files := + |