Fix config checks for Image Builder and SDK - only build them when requested. Clear...
authorFelix Fietkau <nbd@openwrt.org>
Sun, 14 Jan 2007 23:37:40 +0000 (23:37 +0000)
committerFelix Fietkau <nbd@openwrt.org>
Sun, 14 Jan 2007 23:37:40 +0000 (23:37 +0000)
SVN-Revision: 6102

package/Makefile
target/Makefile
target/imagebuilder/Makefile
target/sdk/Makefile

index eafd8cbe6e75f7b12553a147132e461dc9a6c9ff..cd4304e667a68da332792fb29595fa1f27673989 100644 (file)
@@ -50,7 +50,9 @@ prereq: $(PREREQ_PACKAGES)
 download: $(DOWNLOAD_PACKAGES)
 compile-targets: $(COMPILE_PACKAGES)
 compile:
+       @-rm -f $(PACKAGE_DIR)/*.ipk
        $(MAKE) compile-targets
+
 install-targets: $(INSTALL_PACKAGES)
 install:
        rm -rf $(BUILD_DIR)/root
index 4853e3fbd2df3a829e4fc8d0213f4a6c182b000f..3f97b9a14da72ca3b04075d2b52c6a64d3b7a8f1 100644 (file)
@@ -20,7 +20,15 @@ IMAGE_DIR:=linux/$(BOARD)-$(KERNEL)/image
 download: $(patsubst %,%-download,$(TARGETS-y))
 prepare: linux-prepare
 compile: linux-compile image_compile
-install: image_clean linux-install sdk_install image_install imagebuilder_install
+install: image_clean linux-install image_install 
+
+ifeq ($(CONFIG_SDK),y)
+install: sdk_install
+endif
+ifeq ($(CONFIG_IB),y)
+install: imagebuilder_install
+endif
+
 clean: linux-clean sdk-clean imagebuilder-clean image_clean
 
 prereq: FORCE
index 439a103428472f0817befd1c67321f286336f2f1..b59b265adcfecc1ff0ece30ff9ef64c33087cd6f 100644 (file)
@@ -18,7 +18,7 @@ IB_BUILD_DIR:=$(BUILD_DIR)/$(IB_NAME)
 
 all: compile
 
-$(BIN_DIR)/$(IB_NAME).tar.bz2: FORCE
+$(BIN_DIR)/$(IB_NAME).tar.bz2: clean
        rm -rf $(IB_BUILD_DIR)
        mkdir -p $(IB_BUILD_DIR)/build_$(ARCH)/linux-$(KERNEL)-$(BOARD) $(IB_BUILD_DIR)/staging_dir_$(ARCH)/bin $(IB_BUILD_DIR)/target/linux
        $(CP) \
@@ -43,5 +43,5 @@ prepare:
 compile: $(BIN_DIR)/$(IB_NAME).tar.bz2
 install: compile
 
-clean:
+clean: FORCE
        rm -rf $(IB_BUILD_DIR) $(BIN_DIR)/$(IB_NAME).tar.bz2
index 56a6c97ecdbd9203914179d47711be49a18f222c..d65b934c95342168ead7b8a8c6e50a01a82e619c 100644 (file)
@@ -18,8 +18,7 @@ SDK_BUILD_DIR:=$(BUILD_DIR)/$(SDK_NAME)
 
 all: compile
 
-$(BIN_DIR)/$(SDK_NAME).tar.bz2:
-       rm -rf $(SDK_BUILD_DIR)
+$(BIN_DIR)/$(SDK_NAME).tar.bz2: clean
        mkdir -p $(SDK_BUILD_DIR)/dl $(SDK_BUILD_DIR)/package
        $(CP) $(INCLUDE_DIR) $(SCRIPT_DIR) $(TOPDIR)/docs $(SDK_BUILD_DIR)/
        $(TAR) -cf - -C $(TOPDIR) --exclude=ccache/ staging_dir_$(ARCH) | \
@@ -45,7 +44,7 @@ $(BIN_DIR)/$(SDK_NAME).tar.bz2:
 download:
 prepare:
 compile: $(BIN_DIR)/$(SDK_NAME).tar.bz2
-install:
+install: compile
 
 clean:
        rm -rf $(SDK_BUILD_DIR) $(BIN_DIR)/$(SDK_NAME).tar.bz2