From a4489e688ae0c130b65fc3b1e37b2f9d41639efe Mon Sep 17 00:00:00 2001 From: Michael Prokop Date: Tue, 30 Dec 2008 13:22:21 +0100 Subject: [PATCH] Change dpkg-divert handling in preinst --- debian/changelog | 7 +++++++ debian/preinst | 36 ++++++++++++++++-------------------- 2 files changed, 23 insertions(+), 20 deletions(-) diff --git a/debian/changelog b/debian/changelog index 45d32e4..9db6d4d 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +grml-etc (1.1.10) unstable; urgency=low + + * Change dpkg-divert handling in preinst. This hopefully + addresses the changes introduced with #508392 in dpkg. + + -- Michael Prokop Tue, 30 Dec 2008 13:19:58 +0100 + grml-etc (1.1.9) unstable; urgency=low * /etc/wvdial.conf.umts: add usage example for web.vodafone.de diff --git a/debian/preinst b/debian/preinst index ba60baa..20e4b94 100755 --- a/debian/preinst +++ b/debian/preinst @@ -39,29 +39,25 @@ rm_conffile() { case "$1" in install|upgrade) - if [ -r /etc/mgetty/login.config ] ; then - for cmd in $TO_DIVERT1; do - divert_gen $cmd /etc/mgetty - done - fi + for cmd in $TO_DIVERT1; do + divert_gen $cmd /etc/mgetty + done + for cmd in $TO_DIVERT2; do divert_gen $cmd /etc/init.d done - if [ -d /etc/kismet ] ; then - for cmd in $TO_DIVERT3; do - divert_gen $cmd /etc/kismet - done - fi - if [ -d /etc/pcmcia ] ; then - for cmd in $TO_DIVERT4; do - divert_gen $cmd /etc/pcmcia - done - fi - if [ -d /etc/X11/windowlab ] ; then - for cmd in $TO_DIVERT5; do - divert_gen $cmd /etc/X11/windowlab - done - fi + + for cmd in $TO_DIVERT3; do + divert_gen $cmd /etc/kismet + done + + for cmd in $TO_DIVERT4; do + divert_gen $cmd /etc/pcmcia + done + + for cmd in $TO_DIVERT5; do + divert_gen $cmd /etc/X11/windowlab + done # did I mention that dpkg-divert sucks? if [ -n "$2" ] ; then -- 2.1.4