aboutsummaryrefslogtreecommitdiffstats
path: root/include/package-ipkg.mk
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2016-11-08 05:47:39 +0100
committerFelix Fietkau <nbd@nbd.name>2016-11-08 10:49:51 +0100
commit64c386c5662e923d284b1c5b742cb72d7ad24671 (patch)
tree9bf3a4048503b37729b0c390e618069d2d22357f /include/package-ipkg.mk
parent7ee661def6da779917ef405e04eb7eb4230ebb0a (diff)
downloadupstream-64c386c5662e923d284b1c5b742cb72d7ad24671.tar.gz
upstream-64c386c5662e923d284b1c5b742cb72d7ad24671.tar.bz2
upstream-64c386c5662e923d284b1c5b742cb72d7ad24671.zip
build: remove stale .ipk files if package dir changes
If a package nonshared status is changed, a stale .ipk file might still be present in the old package directory. Remove the .ipk file from all package directories when building a new one (or explicitly running clean) Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'include/package-ipkg.mk')
-rw-r--r--include/package-ipkg.mk4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/package-ipkg.mk b/include/package-ipkg.mk
index c90eeb2b46..afd2d4ef7a 100644
--- a/include/package-ipkg.mk
+++ b/include/package-ipkg.mk
@@ -175,7 +175,7 @@ $(_endef)
$$(IPKG_$(1)) : export DESCRIPTION=$$(Package/$(1)/description)
$$(IPKG_$(1)) : export PATH=$$(TARGET_PATH_PKG)
$$(IPKG_$(1)): $(STAMP_BUILT) $(INCLUDE_DIR)/package-ipkg.mk
- @rm -rf $$(PDIR_$(1))/$(1)_* $$(IDIR_$(1))
+ @rm -rf $$(IDIR_$(1)) $$(call opkg_package_files,$(1))
mkdir -p $(PACKAGE_DIR) $$(IDIR_$(1))/CONTROL $(PKG_INFO_DIR)
$(call Package/$(1)/install,$$(IDIR_$(1)))
-find $$(IDIR_$(1)) -name 'CVS' -o -name '.svn' -o -name '.#*' -o -name '*~'| $(XARGS) rm -rf
@@ -230,7 +230,7 @@ $(_endef)
@[ -f $$(IPKG_$(1)) ]
$(1)-clean:
- rm -f $$(PDIR_$(1))/$(1)_*
+ $$(if $$(call opkg_package_files,$(1)),rm -f $$(call opkg_package_files,$(1)))
clean: $(1)-clean