linux26: do not set CFLAGS_KERNEL to TARGET_CFLAGS
authorSven Neumann <s.neumann@raumfeld.com>
Wed, 22 Jul 2009 12:25:05 +0000 (14:25 +0200)
committerPeter Korsgaard <jacmet@sunsite.dk>
Wed, 22 Jul 2009 20:43:51 +0000 (22:43 +0200)
Using TARGET_CFLAGS breaks the kernel build for the arm platform. The
result is a kernel that can not be booted. So simply do not fiddle with
the CFLAGS on a kernel build and the kernel build system will do the
right thing (TM).

[Peter: do the same thing for the standard kernel build]

Signed-off-by: Sven Neumann <s.neumann@raumfeld.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
target/linux/Makefile.in
target/linux/Makefile.in.advanced

index ff0b88e3498deea1a664c35985423dc590849495..3e8bc7b3072c89d064d8136de53709625a305227 100644 (file)
@@ -89,11 +89,8 @@ LINUX26_PATCH_DIR:=$(BOARD_PATH)/kernel-patches/
 #"))
 endif
 endif
-__LINUX26_NO_PIC=-fPIC -fpic -DPIC -fwrapv -ftrapv
-__LINUX26_ZERO_OPTIMIZATION=-O0
 LINUX26_MAKE_FLAGS = HOSTCC="$(HOSTCC)" HOSTCFLAGS="$(HOSTCFLAGS)" \
        ARCH=$(KERNEL_ARCH) \
-       CFLAGS_KERNEL="$(filter-out $(__LINUX26_NO_PIC) $(__LINUX26_ZERO_OPTIMIZATION),$(TARGET_CFLAGS))" \
        INSTALL_MOD_PATH=$(TARGET_DIR) \
        CROSS_COMPILE=$(KERNEL_CROSS) \
        LDFLAGS="$(TARGET_LDFLAGS)" \
index 9d878f2b0b668814aa1fe95a7a3fbe19331af23b..47a1f4ebb02bf3cfaa00ad3259a2a42b42d3760d 100644 (file)
@@ -190,10 +190,8 @@ LINUX_KERNEL:=$(LINUX26_KERNEL)
 # -----------------------------------------------------------------------------
 LINUX26_BZCAT:=$(BZCAT)
 
-__LINUX26_NO_PIC=-fPIC -fpic -DPIC -fwrapv -ftrapv
 LINUX26_MAKE_FLAGS = HOSTCC="$(HOSTCC)" HOSTCFLAGS="$(HOSTCFLAGS)" \
        ARCH=$(KERNEL_ARCH) \
-       CFLAGS_KERNEL="$(filter-out $(__LINUX26_NO_PIC),$(TARGET_CFLAGS))" \
        INSTALL_MOD_PATH=$(TARGET_DIR) \
        CROSS_COMPILE=$(KERNEL_CROSS) \
        LDFLAGS="$(TARGET_LDFLAGS)" \
@@ -549,6 +547,7 @@ linux-status:
        @echo LINUX26_SOURCE=$(LINUX26_SOURCE)
        @echo LINUX26_TARGETS=$(LINUX26_TARGETS)
        @echo LINUX26_VERSION=$(LINUX26_VERSION)
+       @echo LINUX26_MAKE_FLAGS=$(LINUX26_MAKE_FLAGS)
        @echo PROJECT_BUILD_DIR=$(PROJECT_BUILD_DIR)
        @echo TARGETS=$(TARGETS)