PREUN
/bin/sh
#Stop mtinkd when uninstalling printer-filters
/usr/share/rpm-helper/del-service mtink $1 mtinkd
POSTIN
/bin/sh
/usr/share/rpm-helper/add-service mtink $1 mtinkd
if [ "$1" -eq "1" ]; then
# On fresh installs, disable mtinkd on boot time
chkconfig mtinkd off
fi
# Restart the mtinkd when it is running, but do not activate it by
# default. It blocks the ports for non-Epson devices.
if [ "$1" -eq "2" ]; then
# On update
service mtinkd condrestart > /dev/null 2>/dev/null || :
fi
if [ -x /usr/bin/update-menus ]; then /usr/bin/update-menus || true ; fi
POSTUN
/bin/sh
if [ "$1" -ge "1" ]; then
# On update
/sbin/service mtinkd condrestart >/dev/null 2>&1
fi
if [ "$1" = "0" -a -x /usr/bin/update-menus ]; then /usr/bin/update-menus || true ; fi
Triggers
printer-utils-2007
/bin/sh
mtinkpid="`pidof mtink`"
if ! [ -z "${mtinkpid}" ]; then
kill `cat ${mtinkpid}`
/etc/rc.d/init.d/mtinkd start
fi