X-Git-Url: http://git.rohieb.name/openwrt.git/blobdiff_plain/d1020e0c943dbf817cdf133553a122df4d96e15b..f6b242d80b0fd6e280c4a9379bc97323944a0a79:/include/kernel.mk diff --git a/include/kernel.mk b/include/kernel.mk index 748605705..b413d8484 100644 --- a/include/kernel.mk +++ b/include/kernel.mk @@ -23,11 +23,11 @@ else endif ifneq (,$(findstring uml,$(BOARD))) - KERNEL_CC:=$(HOSTCC) - KERNEL_CROSS:= + KERNEL_CC?=$(HOSTCC) + KERNEL_CROSS?= else - KERNEL_CC:=$(TARGET_CC) - KERNEL_CROSS:=$(TARGET_CROSS) + KERNEL_CC?=$(TARGET_CC) + KERNEL_CROSS?=$(TARGET_CROSS) endif PATCH_DIR ?= ./patches$(shell [ -d "./patches-$(KERNEL_PATCHVER)" ] && printf -- "-$(KERNEL_PATCHVER)" || true ) @@ -51,13 +51,14 @@ endif ifneq (,$(findstring uml,$(BOARD))) LINUX_KARCH:=um else - LINUX_KARCH:=$(shell echo $(ARCH) | sed -e 's/i[3-9]86/i386/' \ - -e 's/mipsel/mips/' \ - -e 's/mipseb/mips/' \ - -e 's/powerpc/ppc/' \ - -e 's/sh[234]/sh/' \ - -e 's/armeb/arm/' \ - ) + ifeq (,$(LINUX_KARCH)) + LINUX_KARCH:=$(shell echo $(ARCH) | sed -e 's/i[3-9]86/i386/' \ + -e 's/mipsel/mips/' \ + -e 's/mipseb/mips/' \ + -e 's/sh[234]/sh/' \ + -e 's/armeb/arm/' \ + ) + endif endif @@ -87,7 +88,10 @@ define ModuleAutoLoad chmod 0755 $(2)/CONTROL/postinst; \ fi endef - + +ifeq ($(DUMP)$(TARGET_BUILD),) + -include $(LINUX_DIR)/.config +endif define KernelPackage NAME:=$(1)