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

Bug#271603: missing Depends



On 14.09.04 LaMont Jones (lamont@debian.org) wrote:

Hi,

> Setting up tetex-base (2.0.2b-5) ...
> /var/lib/dpkg/info/tetex-base.postinst: line 89: kpsewhich: command not found
> 
> Need to Depend on tetex-bin.
> 
No, it should not. We should just check, if kpsewhich does exist,
before executing it. That special piece of code has only to be
executed if tetex-bin is already installed.
I've attached a preliminary patch, which checks for kpsewhich.
Problem: What does happen, if I do an "test -f $CUR" and CUR is not
set? Will the postin fail?

Thanks,
  Hilmar
-- 
sigmentation fault
--- postinst.orig	2004-09-14 09:04:27.000000000 +0200
+++ postinst	2004-09-14 09:33:19.990875000 +0200
@@ -86,8 +86,10 @@
 # in language.dat, we have to fix this.
 
 # Where is language.dat (or is it not yet anywhere)?
-KPSEWHICH_LDAT=`kpsewhich --progname=tex language.dat` || true
-CUR_LDAT=`readlink -f $KPSEWHICH_LDAT 2>/dev/null` || true
+if [ -x /usr/bin/kpsewhich ]; then
+  KPSEWHICH_LDAT=`kpsewhich --progname=tex language.dat` || true
+  CUR_LDAT=`readlink -f $KPSEWHICH_LDAT 2>/dev/null` || true
+fi
 if [ -f "$CUR_LDAT" ]; then
   # There is a language.dat yet
   if grep "ukhyphen.tex" $CUR_LDAT | grep -v ^% >/dev/null; then # &2 is not redirected on purpose

Reply to: