Hartmut Henkel writes:
On Wed, 6 Aug 2003, i wrote:
where tex and initex both look into the same line, TEXINPUTS.tex.
...which is again wrong :-( Slowly getting it, sorry. Hope this is now right: In the teTeX distributed texmf.cnf file, the parsing is as follows:
* tex reads line TEXINPUTS.tex. * tex -ini reads line TEXINPUTS.tex. * initex doesn't find a match and reads the catch-all (!), TEXINPUTS, which is fine for initex. * pdftex reads line TEXINPUTS.pdftex. * pdftex -ini reads line TEXINPUTS.pdftex. * pdfinitex finds no direct match, so it tries the last resort TEXINPUTS, where it doesn't find pdf-related entries. Same with pdfeinitex and mptodf, which runs on pdfetex.
This sounds about right. The problem originates in us having both "formats" and "engines". Files specific to a format can be found in places like "texmf/tex/<format>", for example "texmf/tex/latex" and "texmf/tex/latex209". For engines, the "tex" part in "texmf/tex/..." is replaced with the engine name. So we get, as Thomas pointed out, something like an N*M structure, which does tend to get out of hand... For the purposes of path searches, the 'initex' programs are not treated any differtly from all the others. That is, "initex" is used as the "format-suffix", unless overruled by the command-line options. (Examples of the latter are found in the web2c Makefile.) With pdfelatex, you'd be looking in paths suitable for the pdfetex, pdftex, etex, and tex engines -- and is that the correct order? And for each of these engines, you should look in "texmf/<engine>/latex" first. This is because for historical reasons, there are unavoidable name clashes between latex and latex209 files. This means that if you have a texmf tree with both latex and latex209 in it, then _all_ latex-based formats require that their files are looked for in "texmf/<engine>/latex" _first_. Now you could already simply things if all the engine-specific trees are merged into the "texmf/tex" tree. It should not be too hard to keep those files apart even in the single tree, and avoid duplicates. Then the "texmf/tex/latex" subtree is for "latex" regardless of the underlying engine. (And "texmf/tex/pdfelatex" could be specific for the pdfelatex format, which just happens to be specific to a single engine.) Just pushing some nonrandom thoughts... -- Olaf Weber (This space left blank for technical reasons.)