summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xdebian/bfh-container.postrm7
-rwxr-xr-xdebian/bfh-container.preinst2
2 files changed, 8 insertions, 1 deletions
diff --git a/debian/bfh-container.postrm b/debian/bfh-container.postrm
index 0af1095..025ef0e 100755
--- a/debian/bfh-container.postrm
+++ b/debian/bfh-container.postrm
@@ -13,6 +13,13 @@ case "${1}" in
do
dpkg-divert --package bfh-container --quiet --remove --rename --divert "/usr/lib/container/divert/${FILE}.orig" "/usr/sbin/${FILE}"
done
+
+ if test -d /usr/lib/container; then
+ if test -d /usr/lib/container/divert; then
+ rmdir --ignore-fail-on-non-empty /usr/lib/container/divert
+ fi
+ rmdir --ignore-fail-on-non-empty /usr/lib/container
+ fi
;;
purge|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
diff --git a/debian/bfh-container.preinst b/debian/bfh-container.preinst
index ab15a9c..2a6624f 100755
--- a/debian/bfh-container.preinst
+++ b/debian/bfh-container.preinst
@@ -4,7 +4,7 @@ set -e
case "${1}" in
install|upgrade)
- mkdir -p /lib/container/divert
+ mkdir -p /usr/lib/container/divert
for FILE in halt poweroff reboot shutdown coldreboot
do