summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorBoris Nagaev <bnagaev@gmail.com>2016-02-15 18:50:40 (GMT)
committerBoris Nagaev <bnagaev@gmail.com>2016-04-20 20:35:13 (GMT)
commit07a0103247814dfd39f0dc057ae3d5cd70da8769 (patch)
tree21d6aaf4f7432077a8deb61894b8859873988182 /tools
parent3f47774f1c93c8cfae905897ea3a2b2229cd81f0 (diff)
downloadmxe-07a0103247814dfd39f0dc057ae3d5cd70da8769.zip
mxe-07a0103247814dfd39f0dc057ae3d5cd70da8769.tar.gz
mxe-07a0103247814dfd39f0dc057ae3d5cd70da8769.tar.bz2
build-pkg: provide a way to mute removeEmptyDirs()
Diffstat (limited to 'tools')
-rwxr-xr-xtools/build-pkg.lua7
1 files changed, 5 insertions, 2 deletions
diff --git a/tools/build-pkg.lua b/tools/build-pkg.lua
index 638a2b4..38500e8 100755
--- a/tools/build-pkg.lua
+++ b/tools/build-pkg.lua
@@ -531,13 +531,16 @@ end
local function removeEmptyDirs(item)
-- removing an empty dir can reveal another one (parent)
+ -- don't pass item to mute the log message
local go_on = true
while go_on do
go_on = false
local f = io.popen('find usr/* -empty -type d', 'r')
for dir in f:lines() do
- log("Remove empty directory %s created by %s",
- dir, item)
+ if item then
+ log("Remove empty directory %s created by %s",
+ dir, item)
+ end
os.remove(dir)
go_on = true
end