1 | #!/bin/sh |
---|
2 | # postinst script for sipbmp3 |
---|
3 | # |
---|
4 | # see: dh_installdeb(1) |
---|
5 | |
---|
6 | set -e |
---|
7 | |
---|
8 | # summary of how this script can be called: |
---|
9 | # * <postinst> `configure' <most-recently-configured-version> |
---|
10 | # * <old-postinst> `abort-upgrade' <new version> |
---|
11 | # * <conflictor's-postinst> `abort-remove' `in-favour' <package> |
---|
12 | # <new-version> |
---|
13 | # * <postinst> `abort-remove' |
---|
14 | # * <deconfigured's-postinst> `abort-deconfigure' `in-favour' |
---|
15 | # <failed-install-package> <version> `removing' |
---|
16 | # <conflicting-package> <version> |
---|
17 | # for details, see http://www.debian.org/doc/debian-policy/ or |
---|
18 | # the debian-policy package |
---|
19 | |
---|
20 | . /usr/share/debconf/confmodule |
---|
21 | |
---|
22 | case "$1" in |
---|
23 | configure|reconfigure) |
---|
24 | chmod +x /usr/lib/sipbmp3/inst/create-filter-config |
---|
25 | chmod +x /usr/lib/sipbmp3/inst/edit-printcap |
---|
26 | chmod +x /usr/lib/sipbmp3/inst/edit-lpd.conf |
---|
27 | chmod +x /usr/lib/sipbmp3/inst/run-checkpc |
---|
28 | chmod +x /usr/lib/sipbmp3/inst/edit-lpd.perms |
---|
29 | /usr/lib/sipbmp3/inst/create-filter-config |
---|
30 | /usr/lib/sipbmp3/inst/edit-printcap |
---|
31 | /usr/lib/sipbmp3/inst/edit-lpd.conf |
---|
32 | /usr/lib/sipbmp3/inst/run-checkpc |
---|
33 | /usr/lib/sipbmp3/inst/edit-lpd.perms |
---|
34 | |
---|
35 | if [ -e /usr/lib/sipbmp3/config/printer_name ]; then |
---|
36 | rm /usr/lib/sipbmp3/config/printer_name |
---|
37 | fi |
---|
38 | |
---|
39 | if [ -e /usr/lib/sipbmp3/config/zephyr_class ]; then |
---|
40 | rm /usr/lib/sipbmp3/config/zephyr_class |
---|
41 | fi |
---|
42 | |
---|
43 | inaudio=$(groups daemon | grep audio || true) |
---|
44 | if [ -z "$inaudio" ]; then |
---|
45 | adduser daemon audio |
---|
46 | fi |
---|
47 | |
---|
48 | db_stop |
---|
49 | ;; |
---|
50 | |
---|
51 | abort-upgrade|abort-remove|abort-deconfigure) |
---|
52 | ;; |
---|
53 | |
---|
54 | *) |
---|
55 | echo "postinst called with unknown argument \`$1'" >&2 |
---|
56 | exit 1 |
---|
57 | ;; |
---|
58 | esac |
---|
59 | |
---|
60 | # dh_installdeb will replace this with shell code automatically |
---|
61 | # generated by other debhelper scripts. |
---|
62 | |
---|
63 | #DEBHELPER# |
---|
64 | |
---|
65 | exit 0 |
---|