[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#197579: tetex-base: on purge, this pkg removes conffiles from other packages



On 16.06.03 Adam DiCarlo (aph@debian.org) wrote:
> Hilmar Preusse <hille42@web.de> writes:

Hi,

> > Haven't checked that fir unstable, but at least in stable
> > jadetext depends on tetex-extra, which depends on tetex-base.
> > I.e. if anybody purges tetex-base, tetex-extra and jadetex will
> > be removed too. This is just an opinion.
> 
> It's true, but remove != purged. Suppose you purge tetex-base, but
> only remove (not purge) jadetex. Then reinstall jadetex and
> tetex-base -- the jadetex conffiles are still gone. The tetex-base
> ones are brought back. The only recover is to purge/reinstall
> jadetex as well.  But there's no dependency relationship that says
> "if you purge package X, also purge Y".
> 
OK, I see. So during purging of tetex-base we must remove only the
files, which might have been created during postin. The following
patch might do this. The creation of these files is done during
postin of tetex-bin and they are removed during postin on tetex-bin,
so I don't know in the moment, why the entry for /etc/texmf exist
anyway (oh wait, language.dat is not removed during postrm of
tetex-bin). In postin of tetex-bin I found further:

  rm -f ${TEXMFC}* ${FMTCNF}*
  rm -rf ${TEXMFD}
  rm -rf ${FMTD}

in case of purge, with

TEXMFC=/etc/texmf/texmf.cnf
FMTCNF=/etc/texmf/fmtutil.cnf
TEXMFD=/etc/texmf/texmf.d
FMTD=/etc/texmf/fmt.d

which is IMHO the same policy violation. We should remove only the
generated files and the files* versions and then we're done. The last
two commands are surplus.
Who will ever remove /etc/texmf if it is found to be empty? dpkg?
Hope I didn't tell too much nonsense.

H. 
-- 
sigmentation fault
--- postrm	Mon Jun 16 00:00:00 2003
+++ postrm.new	Tue Jun 17 00:15:09 2003
@@ -4,8 +4,7 @@
 rm -f /usr/share/texmf/doc /usr/share/doc/texmf/local 2>/dev/null || true
 
 if [ "x$1" = "xpurge" ]; then
-  rm -fr /var/spool/texmf /var/lib/texmf /var/cache/fonts /etc/texmf \
-      /etc/texdoctk || true
+  rm -fr /var/spool/texmf /var/lib/texmf /var/cache/fonts /etc/texdoctk || true
 fi
 
 # Automatically added by dh_installdebconf
--- postrm	Mon Jun 16 00:00:00 2003
+++ postrm.new	Tue Jun 17 00:12:51 2003
@@ -4,6 +4,7 @@
 FMTCNF=/etc/texmf/fmtutil.cnf
 TEXMFD=/etc/texmf/texmf.d
 FMTD=/etc/texmf/fmt.d
+LDAT=/etc/texmf/language.dat
 
 # unregister xdvi for mime
 if [ -x /usr/sbin/update-mime ]; then
@@ -17,7 +18,7 @@
 rm -f /usr/lib/texmf/web2c /usr/share/texmf/web2c || true
 
 if [ x"$1" = xpurge ] ; then
-  rm -f ${TEXMFC}* ${FMTCNF}*
+  rm -f ${TEXMFC}* ${FMTCNF}* ${LDAT}*
   rm -rf ${TEXMFD}
   rm -rf ${FMTD}
   VARFONTSFILE=/etc/texmf/varfontdirs.debian

Reply to: