aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/linux-2.4/Makefile
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2005-06-05 14:42:57 +0000
committerFelix Fietkau <nbd@openwrt.org>2005-06-05 14:42:57 +0000
commitd703a241d3e23944af9d50a9abcbe635f443ceb2 (patch)
treef15b4448aedd2f9021a2571f29f62b7f33d2defb /target/linux/linux-2.4/Makefile
parent941f587141cc3013117dba3fe0be65b1ead853f7 (diff)
downloadmaster-187ad058-d703a241d3e23944af9d50a9abcbe635f443ceb2.tar.gz
master-187ad058-d703a241d3e23944af9d50a9abcbe635f443ceb2.tar.bz2
master-187ad058-d703a241d3e23944af9d50a9abcbe635f443ceb2.zip
add rebuild target for the linux directory
git-svn-id: svn://svn.openwrt.org/openwrt/trunk/openwrt@1149 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/linux-2.4/Makefile')
-rw-r--r--target/linux/linux-2.4/Makefile14
1 files changed, 14 insertions, 0 deletions
diff --git a/target/linux/linux-2.4/Makefile b/target/linux/linux-2.4/Makefile
index 08e91da6d2..9a594b77fe 100644
--- a/target/linux/linux-2.4/Makefile
+++ b/target/linux/linux-2.4/Makefile
@@ -213,6 +213,8 @@ $(TARGET_MODULES_DIR):
source: $(DL_DIR)/$(LINUX_SOURCE)
prepare: $(LINUX_DIR)/.configured
compile: $(LINUX_DIR)/.modules_done $(TARGETS)
+ rm -f $(LINUX_DIR)
+ ln -s $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION) $(LINUX_DIR)
$(MAKE) -C $(TOPDIR)/target/linux/package \
TARGET_DIR="$(LINUX_TARGET_DIR)" \
BUILD_DIR="$(LINUX_BUILD_DIR)" \
@@ -225,6 +227,18 @@ install: compile $(TARGET_MODULES_DIR)
echo -e 'dest root /\noption offline_root $(LINUX_BUILD_DIR)/root' > $(LINUX_BUILD_DIR)/ipkg.conf
[ "$(INSTALL_TARGETS)" != "" ] && $(IPKG_KERNEL) install $(INSTALL_TARGETS) || true
+mostlyclean:
+ rm -f $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION)/.{drivers-unpacked,modules_done}
+ $(MAKE) -C $(LINUX_BUILD_DIR)/linux-$(LINUX_VERSION) clean
+ rm -f $(LINUX_KERNEL) $(LINUX_IMAGE)
+
+rebuild:
+ -$(MAKE) mostlyclean
+ if [ -f $(LINUX_KERNEL) ]; then \
+ $(MAKE) clean; \
+ fi
+ $(MAKE) compile
+
clean:
rm -rf $(LINUX_BUILD_DIR)
rm -f $(TARGETS)