[tex-live] texdoc can't find texmf.cnf

Jonathan Kew jonathan_kew at sil.org
Sun Jun 22 19:13:07 CEST 2008


Is it just me, or is there a problem with texdoc? I'm trying to run  
from the Master tree in TL svn....

When I run texdoc (which is now a symlink to texlive/Master/texmf/ 
scripts/texlive/texdoc.tlu), it fails to find texmf.cnf, and  
therefore also fails to find anything else. I've run with  
KPATHSEA_DEBUG=-1 to see what's happening, and it seems that the  
starting point is the compile-time path:

   {$SELFAUTOLOC,$SELFAUTODIR,$SELFAUTOPARENT}{,{/share,}/texmf{- 
local,}/web2c}

Remember that the script is at texlive/Master/texmf/scripts/texlive/ 
texdoc.tlu. So the variables here resolve to:

   SELFAUTOLOC    -> texlive/Master/texmf/scripts/texlive
   SELFAUTODIR    -> texlive/Master/texmf/scripts
   SELFAUTOPARENT -> texlive/Master/texmf

and the places to search for texmf.cnf then resolve to:

   texlive/Master/texmf/scripts/texlive
   texlive/Master/texmf/scripts
   texlive/Master/texmf
   texlive/Master/texmf/scripts/texlive/share/texmf-local/web2c
   texlive/Master/texmf/scripts/share/texmf-local/web2c
   texlive/Master/texmf/share/texmf-local/web2c
   texlive/Master/texmf/scripts/texlive/texmf-local/web2c
   texlive/Master/texmf/scripts/texmf-local/web2c
   texlive/Master/texmf/texmf-local/web2c
   texlive/Master/texmf/scripts/texlive/share/texmf/web2c
   texlive/Master/texmf/scripts/share/texmf/web2c
   texlive/Master/texmf/share/texmf/web2c
   texlive/Master/texmf/scripts/texlive/texmf/web2c
   texlive/Master/texmf/scripts/texmf/web2c
   texlive/Master/texmf/texmf/web2c

Of these, only the first three (corresponding to the three $SELFAUTO*  
variables with no subdirs) actually exist; there is no web2c  
directory, let alone a texmf.cnf, at any of the other locations.

The problem seems to arise because the kpathsea assumpting (embodied  
in the compile-time paths) is that the binary will be no more than  
two levels down from the "root" of the TL installation (corresponding  
to texlive/Master here), so that $SELFAUTOPARENT will move up to the  
root, and we can then append /texmf/web2c and find the standard  
texmf.cnf file.

However, texdoc.tlu is now installed at a deeper level, under texmf/ 
scripts/texlive, so $SELFAUTOPARENT only brings us up as far as the  
texmf/ directory. The compile-time paths then add a second texmf/  
level before web2c, and we don't find the file we need.

AFAICT, there are two ways to address this: either (a) modify the  
compile-time path to something like

   {$SELFAUTOLOC,$SELFAUTODIR,$SELFAUTOPARENT}{,{/share,}{,/texmf{- 
local,}}/web2c}

(untested, the intent was to make the entire /texmf{-local,} part  
optional); or (b) move the texdoc.tlu script, and any other scripts  
that might need to find texmf.cnf in a similar way, up one level in  
the hierarchy.

Or I suppose we could create a $SELFAUTOGRANDPARENT variable, and add  
this to the mix. I don't expect that to be a popular idea, though!

JK



More information about the tex-live mailing list