aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'patches/busybox/1.33.0/busybox-1.30.1-allow-for-genkernel-cross-compile.patch')
-rw-r--r--patches/busybox/1.33.0/busybox-1.30.1-allow-for-genkernel-cross-compile.patch39
1 files changed, 39 insertions, 0 deletions
diff --git a/patches/busybox/1.33.0/busybox-1.30.1-allow-for-genkernel-cross-compile.patch b/patches/busybox/1.33.0/busybox-1.30.1-allow-for-genkernel-cross-compile.patch
new file mode 100644
index 0000000..0694e09
--- /dev/null
+++ b/patches/busybox/1.33.0/busybox-1.30.1-allow-for-genkernel-cross-compile.patch
@@ -0,0 +1,39 @@
+We don't use CROSS_COMPILE in genkernel to allow for multilib
+compilation (i.e. x86_64 can compile for x86 without dedicated x86 toolchain).
+
+--- a/Makefile
++++ b/Makefile
+@@ -271,8 +271,8 @@ export quiet Q KBUILD_VERBOSE
+ # Look for make include files relative to root of kernel src
+ MAKEFLAGS += --include-dir=$(srctree)
+
+-HOSTCC = gcc
+-HOSTCXX = g++
++HOSTCC ?= gcc
++HOSTCXX ?= g++
+ HOSTCFLAGS :=
+ HOSTCXXFLAGS :=
+ # We need some generic definitions
+@@ -288,15 +288,15 @@ MAKEFLAGS += -rR
+
+ # Make variables (CC, etc...)
+
+-AS = $(CROSS_COMPILE)as
+-CC = $(CROSS_COMPILE)gcc
++AS ?= $(CROSS_COMPILE)as
++CC ?= $(CROSS_COMPILE)gcc
+ LD = $(CC) -nostdlib
+ CPP = $(CC) -E
+-AR = $(CROSS_COMPILE)ar
+-NM = $(CROSS_COMPILE)nm
+-STRIP = $(CROSS_COMPILE)strip
+-OBJCOPY = $(CROSS_COMPILE)objcopy
+-OBJDUMP = $(CROSS_COMPILE)objdump
++AR ?= $(CROSS_COMPILE)ar
++NM ?= $(CROSS_COMPILE)nm
++STRIP ?= $(CROSS_COMPILE)strip
++OBJCOPY ?= $(CROSS_COMPILE)objcopy
++OBJDUMP ?= $(CROSS_COMPILE)objdump
+ PKG_CONFIG ?= $(CROSS_COMPILE)pkg-config
+ AWK = awk
+ GENKSYMS = scripts/genksyms/genksyms