tags 603429 + patch thanks Hi!
* Holger Levsen <hol...@layer-acht.org> [101114 01:04]: [..] > From the attached log (scroll to the bottom...): > > Configuration file `/etc/default/hylafax' > ==> Modified (by you or by a script) since installation. > ==> Package distributor has shipped an updated version. > What would you like to do about it ? Your options are: > Y or I : install the package maintainer's version > N or O : keep your currently-installed version > D : show the differences between the versions > Z : start a shell to examine the situation > The default action is to keep your current version. > *** hylafax (Y/I/N/O/D/Z) [default=N] ? dpkg: error processing > hylafax-server (--configure): > EOF on stdin at conffile prompt > Setting up perl-modules (5.10.1-14) ... > Setting up dmsetup (2:1.02.48-3) ... > Setting up libdevmapper1.02.1 (2:1.02.48-3) ... > Setting up perl (5.10.1-14) ... > Setting up defoma (0.11.11) ... > Errors were encountered while processing: > hylafax-server > E: Sub-process /usr/bin/dpkg returned an error code (1) I think the attached patch solves this problem, by not installing /etc/default/hylafax via the package, but instead installing this file to /usr/share/hylafax, and then using ucf to install it to /etc/default. For that I had to rename debian/hylafax-server.hylafax.default to avoid it being installed by dh_installinit, which clutters the attached a bit. Best Regards, Alexander PS: Oh, and ignore the changelog; I don't intend to NMU it.
diff -Nru hylafax-6.0.5/debian/changelog hylafax-6.0.5/debian/changelog --- hylafax-6.0.5/debian/changelog 2010-10-12 12:19:13.000000000 +0200 +++ hylafax-6.0.5/debian/changelog 2010-12-01 16:57:22.000000000 +0100 @@ -1,3 +1,13 @@ +hylafax (2:6.0.5-4.1) unstable; urgency=low + + * Non-maintainer upload. + * Use ucf to install /etc/default/hylafax (Closes: #603429) + * Also added ucf as dependency for hylafax-server + * Don't install /etc/default/hylafax via debhelper, as previous version + might already have been changed + + -- Alexander Reichle-Schmehl <toli...@debian.org> Wed, 01 Dec 2010 16:28:35 +0100 + hylafax (2:6.0.5-4) unstable; urgency=low * Added two packages with debug information. diff -Nru hylafax-6.0.5/debian/control hylafax-6.0.5/debian/control --- hylafax-6.0.5/debian/control 2010-10-12 12:25:38.000000000 +0200 +++ hylafax-6.0.5/debian/control 2010-12-01 15:51:33.000000000 +0100 @@ -11,7 +11,7 @@ Package: hylafax-server Architecture: any Section: comm -Depends: ${shlibs:Depends}, ${misc:Depends}, libtiff-tools (>= 3.6.1-3), hylafax-client (= ${binary:Version}), bsd-mailx | mailx, psmisc, sed (>= 4.1.2), ghostscript, adduser, lsb-base (>= 3.0-6), exim4-daemon-light | mail-transport-agent +Depends: ${shlibs:Depends}, ${misc:Depends}, libtiff-tools (>= 3.6.1-3), hylafax-client (= ${binary:Version}), bsd-mailx | mailx, psmisc, sed (>= 4.1.2), ghostscript, adduser, lsb-base (>= 3.0-6), exim4-daemon-light | mail-transport-agent, ucf Suggests: mgetty, psrip Conflicts: mgetty-fax, capi4hylafax (<< 1:01.02.03-4) Description: Flexible client/server fax software - server daemons diff -Nru hylafax-6.0.5/debian/hylafax-server.hylafax.default hylafax-6.0.5/debian/hylafax-server.hylafax.default --- hylafax-6.0.5/debian/hylafax-server.hylafax.default 2010-08-13 23:11:55.000000000 +0200 +++ hylafax-6.0.5/debian/hylafax-server.hylafax.default 1970-01-01 01:00:00.000000000 +0100 @@ -1,56 +0,0 @@ -# default settings for hylafax server - -# try to check for the correct USE_FAXGETTY value -if grep -E '^[^#]*:respawn:/usr/sbin/fax(getty|modem).*$' /etc/inittab >/dev/null 2>&1 || grep -E '^exec[ \t]*/usr/sbin/fax(getty|modem)' /etc/init/*.conf >/dev/null 2>&1 -then - USE_FAXGETTY=init -else - USE_FAXGETTY=yes -fi - -# Arguments for faxgetty command. At least -D should be specified -# as explained in debian bug #462459. -FAXGETTYARGS="-D" - -# In a send only installation you may want to use faxgetty -# or faxmodem on lines already configured with faxaddmodem. -# faxgetty is the new default, faxmodem the old one. -# For a better understanding of the difference between faxmodem -# and faxgetty, see http://www.hylafax.org/archive/1999-09/msg00043.php -# -# In a send/receive installation you must use faxgetty. -# -# To use faxmodem change the following variable value to "no". -# -# You may also prefer to run faxmodem/faxgetty via inittab instead of -# running it here from a script. In this case set its value as -# "init". -# USE_FAXGETTY=yes - -# -# Uncomment this line once hylafax has been fully configured and/or -# you want to enable the server. -# -# RUN_HYLAFAX=1 - -# -# If you need to bind hylafax to one address only, just uncomment -# this variable and change the value using your preferred IP. -# -# BINDTO="-l 127.0.0.1" - -# -# The following variables are automatically assigned by running -# the faxsetup utility. If you leave them commented out then -# faxsetup values are used. You may specify here the values to -# use. -# -# OLDPROT="-o 4557" -# NEWPROT="-i 4559" -# SNPP="-s 444" - -# -# hfaxd may be run from inetd while faxq should still be executed -# by the init script. If you run hfax via inetd or xinetd then -# uncomment the following line -# HFAXD_FROM_INET=true diff -Nru hylafax-6.0.5/debian/hylafax-server.hylafax.default-maintainer hylafax-6.0.5/debian/hylafax-server.hylafax.default-maintainer --- hylafax-6.0.5/debian/hylafax-server.hylafax.default-maintainer 1970-01-01 01:00:00.000000000 +0100 +++ hylafax-6.0.5/debian/hylafax-server.hylafax.default-maintainer 2010-08-13 23:11:55.000000000 +0200 @@ -0,0 +1,56 @@ +# default settings for hylafax server + +# try to check for the correct USE_FAXGETTY value +if grep -E '^[^#]*:respawn:/usr/sbin/fax(getty|modem).*$' /etc/inittab >/dev/null 2>&1 || grep -E '^exec[ \t]*/usr/sbin/fax(getty|modem)' /etc/init/*.conf >/dev/null 2>&1 +then + USE_FAXGETTY=init +else + USE_FAXGETTY=yes +fi + +# Arguments for faxgetty command. At least -D should be specified +# as explained in debian bug #462459. +FAXGETTYARGS="-D" + +# In a send only installation you may want to use faxgetty +# or faxmodem on lines already configured with faxaddmodem. +# faxgetty is the new default, faxmodem the old one. +# For a better understanding of the difference between faxmodem +# and faxgetty, see http://www.hylafax.org/archive/1999-09/msg00043.php +# +# In a send/receive installation you must use faxgetty. +# +# To use faxmodem change the following variable value to "no". +# +# You may also prefer to run faxmodem/faxgetty via inittab instead of +# running it here from a script. In this case set its value as +# "init". +# USE_FAXGETTY=yes + +# +# Uncomment this line once hylafax has been fully configured and/or +# you want to enable the server. +# +# RUN_HYLAFAX=1 + +# +# If you need to bind hylafax to one address only, just uncomment +# this variable and change the value using your preferred IP. +# +# BINDTO="-l 127.0.0.1" + +# +# The following variables are automatically assigned by running +# the faxsetup utility. If you leave them commented out then +# faxsetup values are used. You may specify here the values to +# use. +# +# OLDPROT="-o 4557" +# NEWPROT="-i 4559" +# SNPP="-s 444" + +# +# hfaxd may be run from inetd while faxq should still be executed +# by the init script. If you run hfax via inetd or xinetd then +# uncomment the following line +# HFAXD_FROM_INET=true diff -Nru hylafax-6.0.5/debian/hylafax-server.postinst hylafax-6.0.5/debian/hylafax-server.postinst --- hylafax-6.0.5/debian/hylafax-server.postinst 2010-06-20 00:29:50.000000000 +0200 +++ hylafax-6.0.5/debian/hylafax-server.postinst 2010-12-01 16:57:40.000000000 +0100 @@ -275,7 +275,11 @@ if [ "$RET" = "true" ]; then # removed redirect to /dev/null so that user knows that # hylafax is actually restarting - sed -i -e 's/# RUN_HYLAFAX=1/RUN_HYLAFAX=1/' /etc/default/hylafax + tmpfile=$(mktemp) + sed -e 's/# RUN_HYLAFAX=1/RUN_HYLAFAX=1/' < /usr/share/hylafax/hylafax.default-maintainer > $tmpfile + ucf --debconf-ok $tmpfile /etc/default/hylafax + ucfr hylafax-server /etc/default/hylafax + rm -f $tmpfile # invoke-rc.d hylafax stop || true # Added || true in order to complete the installation even if something goes diff -Nru hylafax-6.0.5/debian/hylafax-server.postrm hylafax-6.0.5/debian/hylafax-server.postrm --- hylafax-6.0.5/debian/hylafax-server.postrm 2009-12-28 20:05:40.000000000 +0100 +++ hylafax-6.0.5/debian/hylafax-server.postrm 2010-12-01 16:28:22.000000000 +0100 @@ -25,4 +25,20 @@ done [ -d /var/spool/hylafax/bin ] && rmdir /var/spool/hylafax/bin + + for ext in '~' '%' .bak .ucf-new .ucf-old .ucf-dist; do + rm -f /etc/default/hylafax$ext + done + + # remove the configuration file itself + rm -f /etc/default/hylafax + + # and finally clear it out from the ucf database + if which ucf >/dev/null; then + ucf --purge /etc/default/hylafax + fi + if which ucfr >/dev/null; then + ucfr --purge foo /etc/default/hylafax + fi + fi diff -Nru hylafax-6.0.5/debian/rules hylafax-6.0.5/debian/rules --- hylafax-6.0.5/debian/rules 2010-10-12 13:17:47.000000000 +0200 +++ hylafax-6.0.5/debian/rules 2010-12-01 16:34:05.000000000 +0100 @@ -116,6 +116,8 @@ cp -p debian/lintian.override.hylafax-server \ $(d_server)/usr/share/lintian/overrides/$(p_server) + cp debian/hylafax-server.hylafax.default-maintainer $(d_server)/usr/share/hylafax/hylafax.default-maintainer + install --mode=a+rx -p debian/copy_configuration_from_spool $(d_server)/usr/lib/hylafax/bin/ override_dh_installman: @@ -163,7 +165,8 @@ var/spool/hylafax/etc var/spool/hylafax/recvq var/spool/hylafax/status var/spool/hylafax/sendq \ var/spool/hylafax/doneq var/spool/hylafax/docq var/spool/hylafax/tmp var/spool/hylafax/pollq \ usr/share/man/man5 usr/share/man/man8 \ - usr/share/lintian/overrides + usr/share/lintian/overrides \ + usr/share/hylafax dh_installdirs -p$(p_client) \ etc/hylafax \ usr/bin \
signature.asc
Description: Digital signature