projects
/
openwrt
/
staging
/
dedeckeh.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
build: add support for automatically removing build dir contents during build
[openwrt/staging/dedeckeh.git]
/
include
/
package.mk
diff --git
a/include/package.mk
b/include/package.mk
index 37cea1448df8339f9eb2d325bbac70b04dc537ad..b88f2c52b0e54ab0d686ea679c665d34401788f7 100644
(file)
--- a/
include/package.mk
+++ b/
include/package.mk
@@
-211,6
+211,12
@@
define Build/CoreTargets
.configure: $(STAMP_CONFIGURED)
.dist: $(STAMP_CONFIGURED)
.distcheck: $(STAMP_CONFIGURED)
.configure: $(STAMP_CONFIGURED)
.dist: $(STAMP_CONFIGURED)
.distcheck: $(STAMP_CONFIGURED)
+
+ ifneq ($(CONFIG_AUTOREMOVE),)
+ compile:
+ $(FIND) $(PKG_BUILD_DIR) -mindepth 1 -maxdepth 1 -not '(' -type f -and -name '.*' -and -size 0 ')' -and -not -name '.pkgdir' | \
+ $(XARGS) rm -rf
+ endif
endef
define Build/DefaultTargets
endef
define Build/DefaultTargets