2014-02-12 12:55:42 +01:00
|
|
|
# This hooks removes empty dirs and warns about them.
|
|
|
|
|
|
|
|
hook() {
|
2015-11-26 22:27:55 +01:00
|
|
|
if [ -d "${PKGDESTDIR}" ]; then
|
2019-10-21 00:13:40 +02:00
|
|
|
find "${PKGDESTDIR}" -mindepth 1 -type d -empty -print -delete|sort -r|while read f; do
|
2015-11-26 22:27:55 +01:00
|
|
|
_dir="${f##${PKGDESTDIR}}"
|
|
|
|
msg_warn "$pkgver: removed empty dir: ${_dir}\n"
|
|
|
|
done
|
|
|
|
fi
|
2014-02-12 12:55:42 +01:00
|
|
|
}
|