postinst is in qemu-kvm 1.0+noroms-0ubuntu13.
This file is a maintainer script. It is executed when installing (*inst) or removing (*rm) the package.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 | #!/bin/sh
set -e
if [ "$1" = configure ]; then
# Clean up old kvm confiles from jaunty-era kvm
if [ -n "$2" ] && dpkg --compare-versions "$2" lt 0.12.3-0ubuntu6; then
for i in "/lib/udev/rules.d/45-kvm.rules" "/etc/init.d/kvm" "/etc/kvm/kvm-ifup"; do
[ -f "$i" ] && rm -f "$i" || true
done
fi
fi
# Automatically added by dh_installinit
if [ -e "/etc/init/qemu-kvm.conf" ]; then
invoke-rc.d qemu-kvm start || true
fi
# End automatically added section
# Automatically added by dh_installinit
update-rc.d -f qemu-kvm remove >/dev/null || true
# End automatically added section
# Automatically added by dh_installudev
if [ "$1" = configure ]; then
if [ -e "/etc/udev/rules.d/45_qemu-kvm.rules" ]; then
echo "Preserving user changes to /etc/udev/rules.d/45-qemu-kvm.rules ..."
if [ -e "/etc/udev/rules.d/45-qemu-kvm.rules" ]; then
mv -f "/etc/udev/rules.d/45-qemu-kvm.rules" "/etc/udev/rules.d/45-qemu-kvm.rules.dpkg-new"
fi
mv -f "/etc/udev/rules.d/45_qemu-kvm.rules" "/etc/udev/rules.d/45-qemu-kvm.rules"
fi
fi
# End automatically added section
exit 0
|