X-Git-Url: https://git.rrq.au/?a=blobdiff_plain;f=debian%2Flilo.preinst;h=d852ad6d21df7ed911f8cf598b39b57d8719cfda;hb=47fd68ef024abaeae5964a61640a8e030bc21575;hp=2620238cd3780231d68c431eb920c76125322d3e;hpb=e54ace12fd683ce1f41b25ed66641e40b84212b0;p=rrq%2Fmaintain_lilo.git diff --git a/debian/lilo.preinst b/debian/lilo.preinst index 2620238..d852ad6 100644 --- a/debian/lilo.preinst +++ b/debian/lilo.preinst @@ -1,19 +1,46 @@ -#!/bin/sh -e +#!/bin/sh +# preinst script lilo +# +# see: dh_installdeb(1) -#DEBHELPER# +set -e + +BMPS="sarge sid" + +# remove old-named config files +dpkg-maintscript-helper rm_conffile \ + /etc/kernel/postinst.d/zz-lilo 1:22.8-10 lilo -- "$@" + +dpkg-maintscript-helper rm_conffile \ + /etc/kernel/postrm.d/zz-lilo 1:22.8-10 lilo -- "$@" + +dpkg-maintscript-helper rm_conffile \ + /etc/kernel/postinst.d/zz-lilo 1:22.8-10 lilo -- "$@" + +dpkg-maintscript-helper rm_conffile \ + /etc/initramfs/post-update.d/lilo 1:22.8-10 lilo -- "$@" -if [ -d /usr/share/lilo/contrib ]; then - echo - echo "WARNING:" - echo "The use of /usr/share/lilo/contrib as the directory of the" - echo "bitmaps is deprecated and may be removed later." - echo "You may want to put your bitmaps on /usr/share/lilo instead." - echo "I will remove the packaged bitmaps but you must move yours" - echo "to other place." - echo - rm -f /usr/share/lilo/contrib/sid.bmp - rm -f /usr/share/lilo/contrib/sarge.bmp - rm -f /usr/share/lilo/contrib/debianlilo.bmp - rm -f /usr/share/lilo/contrib/coffee.bmp -fi +# targets: install|upgrade|abort-upgrade + +case "$1" in + install|upgrade|abort-upgrade) + if test -L /boot/debian.bmp; then + rm -f /boot/debian.bmp; + fi + for i in ${BMPS}; do + rm -f /boot/${i}.bmp /boot/${i}.dat /boot/${i}*bmp.conf; + done + ;; + *) + echo "postinst called with unknown argument \`$1'" >&2 + exit 1 + ;; +esac + +# dh_installdeb will replace this with shell code automatically +# generated by other debhelper scripts. + +#DEBHELPER# + +exit 0