X-Git-Url: https://git.deb.at/w?a=blobdiff_plain;f=debian%2Fpostinst;h=dc97dc008b2eab87d1fc39fd176c16e884a7f055;hb=29f418e5b19fdabcb2ad6735a4d92b269ab3cfb3;hp=9abee6f800794a68cb0bb8edcd4efd64b803f0fc;hpb=0b72fe17e679c0b3c88448cc2fc6830d3db20f93;p=pkg%2Fbeep.git diff --git a/debian/postinst b/debian/postinst index 9abee6f..dc97dc0 100644 --- a/debian/postinst +++ b/debian/postinst @@ -1,5 +1,9 @@ -#!/bin/sh -e +#!/bin/sh # postinst for beep +# copyright 2002-2011 by Rhonda D'Vine +# Licenced under WTFPLv2 + +set -e # Source debconf library. if [ -e /usr/share/debconf/confmodule ]; then @@ -16,28 +20,39 @@ if [ -e /usr/share/debconf/confmodule ]; then suid="$RET" fi -# repair typo in option (see #135866) -if [ "$suid" = "suid root with only group audio executeable" ] ; then - db_set beep/suid_option "suid root with only group audio executable" - suid="suid root with only group audio executable" +# option changes as suggested by #492724 +if [ "$suid" = "suid root for all" ] ; then + db_set beep/suid_option "usable for all" + suid="usable for all" +fi +if [ "$suid" = "suid root with only group audio executable" ] ; then + db_set beep/suid_option "usable for group audio" + suid="usable for group audio" +fi +if [ "$suid" = "not suid at all" ] ; then + db_set beep/suid_option "usable only for root" + suid="usable only for root" fi + if [ -x /usr/sbin/dpkg-statoverride ] ; then if ! dpkg-statoverride --list /usr/bin/beep >/dev/null ; then - if [ "$suid" = "suid root for all" ] ; then + if [ "$suid" = "usable for all" ] ; then chmod 4755 /usr/bin/beep - elif [ "$suid" = "suid root with only group audio executable" ] ; then + elif [ "$suid" = "usable for group audio" ] ; then chmod 4754 /usr/bin/beep - elif [ "$suid" = "not suid at all" ] ; then + elif [ "$suid" = "usable only for root" ] ; then chmod 0755 /usr/bin/beep fi fi else - if [ "$suid" = "suid root for all" ] ; then + if [ "$suid" = "usable for all" ] ; then chmod 4755 /usr/bin/beep - elif [ "$suid" = "suid root with only group audio executable" ] ; then + elif [ "$suid" = "usable for group audio" ] ; then chmod 4754 /usr/bin/beep - elif [ "$suid" = "not suid at all" ] ; then + elif [ "$suid" = "usable only for root" ] ; then chmod 0755 /usr/bin/beep fi fi + +#DEBHELPER#