[tex-k] note from Don Knuth

Maggie McLoughlin mam at theory.Stanford.EDU
Fri Nov 9 00:24:19 CET 2007


Dear Karl,

Help! I'm really stymied this time.

My trusty old computer gave up the ghost --- the CPU was
completely "fried" by an electrical "brownout" --- so I've
bought a new machine. This one has x86-64 architecture,
and I decided to install Ubuntu's version of Linux.

It seems that their version of teTeX (and Debian's too,
probably) has a serious bug that affects people who try
to customize. I don't want to remake all the binaries
unless I have to; and I have already spent altogether
too much time trying to figure out what is broken.
Basically, I cannot run TeX on the input
  \relax
because the system is unable to generate tex.fmt.

(Although tex.fmt does exist.)

An ordinary user doesn't have this problem. Evidently
the fact that I've changed $TEXMFLOCAL means that the
first time I use TeX, it wants to create a whole new
tex.fmt on $HOME/.texmf-var/ (and this is certainly
the right thing, even though I'm the only person
using the machine).

The problem is that the blasted system can't find
the file "fmtutil.cnf", although it clearly exists.

Below is a transcript of the way it fails, including
details of my local configuration files. I hope this
info makes the problem instantly clear.

-------- part one: utter failure when I try -----------

~[1]> setenv KPATHSEA_DEBUG -1
~[2]> tex
kdebug:fopen(/usr/bin/tex, r) => 0x6c4150
kdebug:fclose(0x6c4150) => 0
   ...   [lots of stuff suppressed here]
kdebug:variable: max_print_line = (nil)
kdebug:hash_lookup(hash_extra.tex) => (nil)
kdebug:hash_lookup(hash_extra) => 50000
kdebug:variable: hash_extra = 50000
This is TeX, Version 3.141592 (Web2C 7.5.4)
**\relax
kdebug:hash_lookup(MKTEXFMT.tex) => (nil)
kdebug:hash_lookup(MKTEXFMT) => (nil)
kdebug:variable: MKTEXFMT = (nil)
kdebug:hash_lookup(TEXFORMATS.tex) => (nil)
   ...   [again, I suppress things that seem irrelevant]
kdebug:hash_lookup(TEXMFMAIN) => /usr/share/texmf
kdebug:hash_lookup(TEXMFDIST.kpsewhich) => (nil)
kdebug:hash_lookup(TEXMFDIST) => /usr/share/texmf-{texlive,tetex}
kdebug:Search path for web2c files files (from texmf.cnf)
kdebug:  = /home/don/.texmf-config/web2c:/home/don/.texmf-var/web2c:/home/don/texmf/web2c:/etc/texmf/web2c:!!/var/lib/texmf/web2c:!!/home/texmf/web2c:!!/usr/share/texmf/web2c:!!/usr/share/texmf-texlive/web2c:!!/usr/share/texmf-tetex/web2c
kdebug:  before expansion = $TEXMF/web2c
kdebug:  application override path = (none)
kdebug:  application config file path = (none)
kdebug:  texmf.cnf path = $TEXMF/web2c
kdebug:  compile-time path = /usr/share/texmf/web2c
kdebug:  default suffixes = (none)
kdebug:  other suffixes = (none)
kdebug:  search only with suffix = 0
kdebug:  numeric format value = 38
kdebug:  runtime generation program = (none)
kdebug:  runtime generation command = (none)
kdebug:  program enabled = 0
kdebug:  program enable level = 0
kdebug:kpse_find_file: searching for fmtutil.cnf of type web2c files (from texmf.cnf)
kdebug:start search(files=[fmtutil.cnf], must_exist=0, find_all=0, path=/home/don/.texmf-config/web2c:/home/don/.texmf-var/web2c:/home/don/texmf/web2c:/etc/texmf/web2c:!!/var/lib/texmf/web2c:!!/home/texmf/web2c:!!/usr/share/texmf/web2c:!!/usr/share/texmf-texlive/web2c:!!/usr/share/texmf-tetex/web2c).
kdebug:kpse_normalize_path (/home/don/.texmf-config/web2c) => 1
kdebug:kpse_normalize_path (/home/don/.texmf-config/web2c) => 1
kdebug:path element /home/don/.texmf-config/web2c =>
kdebug:kpse_normalize_path (/home/don/.texmf-var/web2c) => 1
kdebug:kpse_normalize_path (/home/don/.texmf-var/web2c) => 1
kdebug:path element /home/don/.texmf-var/web2c =>
kdebug:kpse_normalize_path (/home/don/texmf/web2c) => 1
kdebug:kpse_normalize_path (/home/don/texmf/web2c) => 1
kdebug:path element /home/don/texmf/web2c =>
kdebug:kpse_normalize_path (/etc/texmf/web2c) => 1
kdebug:kpse_normalize_path (/etc/texmf/web2c) => 1
kdebug:path element /etc/texmf/web2c => /etc/texmf/web2c/
kdebug:kpse_normalize_path (/etc/texmf/web2c/fmtutil.cnf) => 1
kdebug:kpse_normalize_path (/var/lib/texmf/web2c) => 1
kdebug:kpse_normalize_path (/home/texmf/web2c) => 1
kdebug:hash_lookup(fmtutil.cnf) => (nil)
kdebug:kpse_normalize_path (/usr/share/texmf/web2c) => 1
kdebug:hash_lookup(fmtutil.cnf) => (nil)
kdebug:kpse_normalize_path (/usr/share/texmf-texlive/web2c) => 1
kdebug:kpse_normalize_path (/usr/share/texmf-tetex/web2c) => 1
kdebug:search([fmtutil.cnf]) =>
mktexfmt: config file `fmtutil.cnf' not found.
I can't find the format file `tex.fmt'!
~[3]> locate fmtutil.cnf
/usr/share/tetex-bin/fmtutil.cnf
/usr/share/man/man5/fmtutil.cnf.5.gz
/var/lib/texmf/web2c/fmtutil.cnf
~[4]> cat /var/lib/texmf/ls-R
% ls-R -- filename database for kpathsea; do not change this line.
./:
.:
fonts
ls-R
ls-R-TEXMFDIST-TETEX
ls-R-TEXMFMAIN
tex
web2c

./fonts:
map

./fonts/map:
dvipdfm
dvips
pdftex

./fonts/map/dvipdfm:
updmap

./fonts/map/dvipdfm/updmap:
dvipdfm_dl14.map
dvipdfm.map
dvipdfm_ndl14.map

./fonts/map/dvips:
updmap

./fonts/map/dvips/updmap:
builtin35.map
download35.map
ps2pk.map
psfonts.map
psfonts_pk.map
psfonts_t1.map

./fonts/map/pdftex:
updmap

./fonts/map/pdftex/updmap:
pdftex_dl14.map
pdftex.map
pdftex_ndl14.map

./tex:
generic

./tex/generic:
config

./tex/generic/config:
language.dat

./web2c:
aleph.fmt
aleph.log
cont-en.fmt
cont-en.log
etex.fmt
etex.log
fmtutil.cnf
latex.fmt
latex.log
mf.base
mf.log
mptopdf.fmt
mptopdf.log
omega.fmt
omega.log
pdfetex.fmt
pdfetex.log
pdflatex.fmt
pdflatex.log
pdftex.fmt
pdftex.log
tex.fmt
tex.log
updmap.cfg
updmap-sys.log
~[5]> printenv TEXMFCNF
/home/tex:/usr/share/texmf/web2c:/var/lib/texmf/web2c
~[6]> cat /home/tex/texmf.cnf
TEXMFLOCAL    = /home/texmf
TEXMFDBS      = $TEXMFLOCAL;$TEXMFMAIN;$VARTEXFONTS
TEXINPUTS.tex = .;..;/home/tex/local/lib;$TEXMF/tex/{plain,generic,}//
MFINPUTS      = .;/home/tex/local/lib;/home/tex/local/cm;/home/src/mf;/home/src/ams;$TEXMF/metafont//;$TEXMF/fonts/source//
TEXEDIT       = emacs +%d %s
MFEDIT        = emacs +%d %s
MPEDIT        = emacs +%d %s
MKTEXMF       = 0
openout_any   = a
stack_size = 3000	% simultaneous input sources, must be less than 30000
~[7]> ls ~/.te*
/home/don/.texmf-config:

/home/don/.texmf-var:

----- part two: an ordinary user has no trouble finding fmtutil.cnf

~[1]> setenv KPATHSEA_DEBUG -1
~[2]> ls -a
.	      .dmrc	 .gconfd	  .gtkrc-1.2-gnome2  .texmf-var
..	      .emacs.d	 .gnome		  .ICEauthority      texput.log
.bash_logout  .esd_auth  .gnome2	  .metacity	     .Trash
.bashrc       Examples	 .gnome2_private  .nautilus	     .Xauthority
Desktop       .gconf	 .gstreamer-0.10  .profile	     .xsession-errors
~[3]> mktexfmt tex.fmt
kdebug:fopen(/usr/bin/kpsewhich, r) => 0x6050d0
kdebug:fclose(0x6050d0) => 0
kdebug:Search path for cnf files (from compile-time paths.h)
kdebug:  = :/usr/share/texmf/web2c:/usr/share/texmf/web2c
kdebug:  before expansion = $TETEXDIR:/usr/share/texmf/web2c:/usr/share/texmf/web2c
   ... and so on ...
kdebug:hash_lookup(WEB2C) => $TEXMF/web2c $TEXMF/web2c
kdebug:hash_lookup(TEXMF.kpsewhich) => (nil)
kdebug:hash_lookup(TEXMF) => {$TEXMFCONFIG,$TEXMFVAR,$TEXMFHOME,$TEXMFSYSCONFIG,!!$TEXMFSYSVAR,!!$TEXMFLOCAL,!!$TEXMFMAIN,!!$TEXMFDIST} {$TEXMFCONFIG,$TEXMFVAR,$TEXMFHOME,$TEXMFSYSCONFIG,!!$TEXMFSYSVAR,!!$TEXMFLOCAL,!!$TEXMFMAIN,!!$TEXMFDIST}
kdebug:hash_lookup(TEXMFCONFIG.kpsewhich) => (nil)
kdebug:hash_lookup(TEXMFCONFIG) => $HOME/.texmf-config $HOME/.texmf-config
kdebug:hash_lookup(TEXMFVAR.kpsewhich) => (nil)
kdebug:hash_lookup(TEXMFVAR) => $HOME/.texmf-var $HOME/.texmf-var
kdebug:hash_lookup(TEXMFHOME.kpsewhich) => (nil)
kdebug:hash_lookup(TEXMFHOME) => $HOME/texmf $HOME/texmf
kdebug:hash_lookup(TEXMFSYSCONFIG.kpsewhich) => (nil)
kdebug:hash_lookup(TEXMFSYSCONFIG) => /etc/texmf /etc/texmf
kdebug:hash_lookup(TEXMFSYSVAR.kpsewhich) => (nil)
kdebug:hash_lookup(TEXMFSYSVAR) => /var/lib/texmf /var/lib/texmf
kdebug:hash_lookup(TEXMFLOCAL.kpsewhich) => (nil)
kdebug:hash_lookup(TEXMFLOCAL) => /usr/local/share/texmf /usr/local/share/texmf
kdebug:hash_lookup(TEXMFMAIN.kpsewhich) => (nil)
kdebug:hash_lookup(TEXMFMAIN) => /usr/share/texmf /usr/share/texmf
kdebug:hash_lookup(TEXMFDIST.kpsewhich) => (nil)
kdebug:hash_lookup(TEXMFDIST) => /usr/share/texmf-{texlive,tetex} /usr/share/texmf-{texlive,tetex}
kdebug:Search path for web2c files files (from texmf.cnf)
kdebug:  = /home/luser/.texmf-config/web2c:/home/luser/.texmf-var/web2c:/home/luser/texmf/web2c:/etc/texmf/web2c:!!/var/lib/texmf/web2c:!!/usr/local/share/texmf/web2c:!!/usr/share/texmf/web2c:!!/usr/share/texmf-texlive/web2c:!!/usr/share/texmf-tetex/web2c
kdebug:  before expansion = $TEXMF/web2c
kdebug:  application override path = (none)
kdebug:  application config file path = (none)
kdebug:  texmf.cnf path = $TEXMF/web2c
kdebug:  compile-time path = /usr/share/texmf/web2c
kdebug:  default suffixes = (none)
kdebug:  other suffixes = (none)
kdebug:  search only with suffix = 0
kdebug:  numeric format value = 38
kdebug:  runtime generation program = (none)
kdebug:  runtime generation command = (none)
kdebug:  program enabled = 0
kdebug:  program enable level = 0
kdebug:kpse_find_file: searching for fmtutil.cnf of type web2c files (from texmf.cnf)
kdebug:start search(files=[fmtutil.cnf], must_exist=0, find_all=0, path=/home/luser/.texmf-config/web2c:/home/luser/.texmf-var/web2c:/home/luser/texmf/web2c:/etc/texmf/web2c:!!/var/lib/texmf/web2c:!!/usr/local/share/texmf/web2c:!!/usr/share/texmf/web2c:!!/usr/share/texmf-texlive/web2c:!!/usr/share/texmf-tetex/web2c).
kdebug:kpse_normalize_path (/home/luser/.texmf-config/web2c) => 1
kdebug:kpse_normalize_path (/home/luser/.texmf-config/web2c) => 1
kdebug:path element /home/luser/.texmf-config/web2c =>
kdebug:kpse_normalize_path (/home/luser/.texmf-var/web2c) => 1
kdebug:kpse_normalize_path (/home/luser/.texmf-var/web2c) => 1
kdebug:path element /home/luser/.texmf-var/web2c =>
kdebug:kpse_normalize_path (/home/luser/texmf/web2c) => 1
kdebug:kpse_normalize_path (/home/luser/texmf/web2c) => 1
kdebug:path element /home/luser/texmf/web2c =>
kdebug:kpse_normalize_path (/etc/texmf/web2c) => 1
kdebug:kpse_normalize_path (/etc/texmf/web2c) => 1
kdebug:path element /etc/texmf/web2c => /etc/texmf/web2c/
kdebug:kpse_normalize_path (/etc/texmf/web2c/fmtutil.cnf) => 1
kdebug:kpse_normalize_path (/var/lib/texmf/web2c) => 1
kdebug:hash_lookup(fmtutil.cnf) => (nil)
kdebug:hash_lookup(fmtutil.cnf) => /var/lib/texmf/web2c/
kdebug:db:match(/var/lib/texmf/web2c/fmtutil.cnf,/var/lib/texmf/web2c) = 1
kdebug:kpse_normalize_path (/var/lib/texmf/web2c/fmtutil.cnf) => 1
kdebug:search([fmtutil.cnf]) => /var/lib/texmf/web2c/fmtutil.cnf
kdebug:fopen(/usr/bin/kpsewhich, r) => 0x6050d0
kdebug:fclose(0x6050d0) => 0
kdebug:Search path for cnf files (from compile-time paths.h)
kdebug:  = :/usr/share/texmf/web2c:/usr/share/texmf/web2c
kdebug:  before expansion = $TETEXDIR:/usr/share/texmf/web2c:/usr/share/texmf/web2c
kdebug:  application override path = (none)
kdebug:  application config file path = (none)
   ... and eventually
Transcript written on tex.log.
mktexfmt: /home/luser/.texmf-var/web2c/tex.fmt installed.
   ...

-------------------------

Karl, I have had to put TAOCP on hold for a week, and am desperately
hoping that you can get me unstuck!

Thanks in advance for any help you can provide.

Cordially, Don Knuth


More information about the tex-k mailing list