From 7d193fe6886a1cfe466d4f6998a59e224fa6e29f Mon Sep 17 00:00:00 2001 From: Mike Gabriel Date: Fri, 24 Jul 2015 00:13:27 +0200 Subject: debian/itzks-systems-common.postinst: Only execute update-desktop-database if it exists (i.e., if bin:package desktop-file-utils is installed). --- debian/itzks-systems-common.postinst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'debian/itzks-systems-common.postinst') diff --git a/debian/itzks-systems-common.postinst b/debian/itzks-systems-common.postinst index a2e7da4..4c0964b 100755 --- a/debian/itzks-systems-common.postinst +++ b/debian/itzks-systems-common.postinst @@ -30,7 +30,7 @@ case "$1" in echo $RET 1> /etc/debian-edu/itzks.school # deploy Wine desktop fixes if Wine is installed - if which wine 1>/dev/null; then + if which update-desktop-database 1>/dev/null && which wine 1>/dev/null; then if [ ! -e /usr/share/applications/wine.desktop ]; then cp /usr/share/itzks-systems-common/wine-fixes/wine.desktop /usr/share/applications/wine.desktop fi @@ -47,7 +47,7 @@ case "$1" in cp /usr/share/itzks-systems-common/wine-fixes/wine-bin /usr/lib/mime/packages/wine-bin fi update-desktop-database - else + elif which update-desktop-database 1>/dev/null; then if [ -e /usr/share/applications/wine.desktop ]; then rm -f /usr/share/applications/wine.desktop fi -- cgit v1.2.3