move ipkg.conf creation from tools/ipkg-utils to include/package-ipkg.mk
authorNicolas Thill <nico@openwrt.org>
Sat, 25 Aug 2007 11:55:01 +0000 (11:55 +0000)
committerNicolas Thill <nico@openwrt.org>
Sat, 25 Aug 2007 11:55:01 +0000 (11:55 +0000)
SVN-Revision: 8481

include/package-ipkg.mk
tools/ipkg-utils/Makefile

index 36f030375d1a16264d14202fbe839a0680a07907..c67ee4b8aee21e413348f43d0dc59d248108a196 100644 (file)
@@ -60,7 +60,7 @@ ifeq ($(DUMP),)
                $($(1)_COMMANDS) \
        )
 
-    $$(IPKG_$(1)): $(PKG_BUILD_DIR)/.built $$(IDIR_$(1))/CONTROL/control
+    $$(IPKG_$(1)): $(STAGING_DIR)/etc/ipkg.conf $(PKG_BUILD_DIR)/.built $$(IDIR_$(1))/CONTROL/control
        $(call Package/$(1)/install,$$(IDIR_$(1)))
        mkdir -p $(PACKAGE_DIR)
        -find $$(IDIR_$(1)) -name 'CVS' -o -name '.svn' -o -name '.#*' | $(XARGS) rm -rf
@@ -71,6 +71,11 @@ ifeq ($(DUMP),)
     $$(INFO_$(1)): $$(IPKG_$(1))
        $(IPKG) install $$(IPKG_$(1))
 
+    $(STAGING_DIR)/etc/ipkg.conf:
+       mkdir -p $(STAGING_DIR)/etc
+       echo "dest root /" > $(STAGING_DIR)/etc/ipkg.conf
+       echo "option offline_root $(TARGET_DIR)" >> $(STAGING_DIR)/etc/ipkg.conf
+
     $(1)-clean:
        rm -f $(PACKAGE_DIR)/$(1)_*
 
index 9c0330859b8330e53165dad34a2e63c5fe5e41d6..830d38a7c442cd401a1add11540428f6363f272f 100644 (file)
@@ -17,9 +17,6 @@ PKG_CAT:=zcat
 include $(INCLUDE_DIR)/host-build.mk
 
 define Build/Install
-       mkdir -p $(STAGING_DIR)/etc
-       echo "dest root /" > $(STAGING_DIR)/etc/ipkg.conf
-       echo "option offline_root $(TARGET_DIR)" >> $(STAGING_DIR)/etc/ipkg.conf
        $(INSTALL_BIN) \
                $(PKG_BUILD_DIR)/ipkg-build \
                $(PKG_BUILD_DIR)/ipkg-buildpackage \