diff options
author | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2006-12-18 13:30:05 +0000 |
---|---|---|
committer | Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> | 2006-12-18 13:30:05 +0000 |
commit | 93af6cb26bdc3af63003146a1a2dc5d293f42a83 (patch) | |
tree | 15a7ac66c2b1dc2ef71b9a1558c39b743d38afa6 /target/device/x86/i386/linux26.mk | |
parent | f88374ff2c74007abf73079902575dba2b10f51f (diff) |
- put the full kernel's sources into build_/, install them into toolchain_build_. Saves quite some disk-space on the compile-host.
- Avoid overriding the linux26 target's rules if the kernel headers's and the target's kernel are the same. Avoids a warning.
Diffstat (limited to 'target/device/x86/i386/linux26.mk')
-rw-r--r-- | target/device/x86/i386/linux26.mk | 35 |
1 files changed, 18 insertions, 17 deletions
diff --git a/target/device/x86/i386/linux26.mk b/target/device/x86/i386/linux26.mk index 9ca0d2213..6fa2c9ff2 100644 --- a/target/device/x86/i386/linux26.mk +++ b/target/device/x86/i386/linux26.mk @@ -14,6 +14,7 @@ LINUX26_VERSION=2.6.19.1 LINUX26_SOURCE=linux-$(DOWNLOAD_LINUX26_VERSION).tar.bz2 +LINUX26_BZCAT:=$(BZCAT) LINUX26_SITE=http://ftp.kernel.org/pub/linux/kernel/v2.6 #LINUX26_FORMAT=vmlinux @@ -37,32 +38,30 @@ LINUX26_MAKE_FLAGS = $(TARGET_CONFIGURE_OPTS) ARCH=$(KERNEL_ARCH) \ PATH=$(TARGET_PATH) INSTALL_MOD_PATH=$(TARGET_DIR) \ CROSS_COMPILE=$(KERNEL_CROSS) +$(LINUX26_KCONFIG): + @if [ ! -f "$(LINUX26_KCONFIG)" ] ; then \ + echo ""; \ + echo "You should create a .config for your kernel"; \ + echo "and install it as $(LINUX26_KCONFIG)"; \ + echo ""; \ + sleep 5; \ + fi; - - +ifneq ($(strip $(LINUX26_VERSION)),$(strip $(LINUX_HEADERS_VERSION))) $(DL_DIR)/$(LINUX26_SOURCE): $(WGET) -P $(DL_DIR) $(LINUX26_SITE)/$(LINUX26_SOURCE) $(LINUX26_DIR)/.unpacked: $(DL_DIR)/$(LINUX26_SOURCE) rm -rf $(LINUX26_DIR) - bzcat $(DL_DIR)/$(LINUX26_SOURCE) | tar -C $(BUILD_DIR) -xvf - + $(LINUX26_BZCAT) $(DL_DIR)/$(LINUX26_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) - ifneq ($(DOWNLOAD_LINUX26_VERSION),$(LINUX26_VERSION)) # Rename the dir from the downloaded version to the AFTER patch version mv -f $(BUILD_DIR)/linux-$(DOWNLOAD_LINUX26_VERSION) $(BUILD_DIR)/linux-$(LINUX26_VERSION) endif touch $(LINUX26_DIR)/.unpacked -$(LINUX26_KCONFIG): - @if [ ! -f "$(LINUX26_KCONFIG)" ] ; then \ - echo ""; \ - echo "You should create a .config for your kernel"; \ - echo "and install it as $(LINUX26_KCONFIG)"; \ - echo ""; \ - sleep 5; \ - fi; - $(LINUX26_DIR)/.patched: $(LINUX26_DIR)/.unpacked - #toolchain/patch-kernel.sh $(LINUX26_DIR) $(LINUX26_PATCH_DIR) + toolchain/patch-kernel.sh $(LINUX26_DIR) $(LINUX26_PATCH_DIR) touch $(LINUX26_DIR)/.patched $(LINUX26_DIR)/.configured: $(LINUX26_DIR)/.patched $(LINUX26_KCONFIG) @@ -70,10 +69,7 @@ $(LINUX26_DIR)/.configured: $(LINUX26_DIR)/.patched $(LINUX26_KCONFIG) $(MAKE) $(LINUX26_MAKE_FLAGS) -C $(LINUX26_DIR) oldconfig touch $(LINUX26_DIR)/.configured -linux26-menuconfig: $(LINUX26_DIR)/.patched - [ -f $(LINUX26_DIR)/.config ] || cp $(LINUX26_KCONFIG) $(LINUX26_DIR)/.config - $(MAKE) $(LINUX26_MAKE_FLAGS) -C $(LINUX26_DIR) menuconfig - -[ -f $(LINUX26_DIR)/.config ] && touch $(LINUX26_DIR)/.configured +endif # ($(LINUX26_VERSION),$(LINUX_HEADERS_VERSION)) $(LINUX26_DIR)/.depend_done: $(LINUX26_DIR)/.configured $(MAKE) $(LINUX26_MAKE_FLAGS) -C $(LINUX26_DIR) prepare @@ -99,6 +95,11 @@ $(TARGET_DIR)/lib/modules/$(LINUX26_VERSION)/modules.dep: $(LINUX26_KERNEL) rm -f $(TARGET_DIR)/lib/modules/$(LINUX26_VERSION)/build touch -c $(TARGET_DIR)/lib/modules/$(LINUX26_VERSION)/modules.dep +linux26-menuconfig: $(LINUX26_DIR)/.patched + [ -f $(LINUX26_DIR)/.config ] || cp $(LINUX26_KCONFIG) $(LINUX26_DIR)/.config + $(MAKE) $(LINUX26_MAKE_FLAGS) -C $(LINUX26_DIR) menuconfig + -[ -f $(LINUX26_DIR)/.config ] && touch $(LINUX26_DIR)/.configured + linux26: cross-depmod26 $(TARGET_DIR)/lib/modules/$(LINUX26_VERSION)/modules.dep linux26-source: $(DL_DIR)/$(LINUX26_SOURCE) |