[texhax] Setting the right environment vars and config
thomas.jung at public-files.de
Sat May 8 23:40:05 CEST 2010
I have a problem to get the right configuration on a Windows 7 mashine.
First I installed TexLive 2009 and if I start "latex mytest.tex" all seems
be fine and the file will be compiled.
Then I would like to add additional paths (because my project is organized
in several subdirectories) where latex should search for my own project
style and bib files.. Btw: in miktex there is an option
So I asked in the tex.live mailinglist "include directories to search for
like *.bib *.sty, etc." how to do this and got a very helfull hint from a
user. He said
I have to set BIBINPUTS and TEXINPUTS and latex, bibtex, etc will search
theses paths too.
OK, I wrote a batch wrapper which sets
as relative paths and the additional paths will be found.
The above example "latex mytest.tex" doesn't work anymore and I get the
! LaTeX Error: File `book.cls' not found. UUUUhhhh ;-)
Strange, I think. Because latex starts to compile and bibtex finds now my
bib files and latex finds my own style files in the subdirectories given by
But it looks like this BININPUTS and TEXIINPUTS _overwrites_ the defaults
OK, I searched at the documentation (kapthesa) and there are many VARS which
sets all the paths. e.g. TEXMF, TEXMFLOCAL, TEXMFMAIN, TEXMFCNF, etc.
I also find this statement in the documentation and this is very confusing.
Automatic setting of environment variables.
No manual configuration steps are required.
But in fact there are _no_ environment vars set in Windows 7 (Setup as
Perhaps this was the behavior of previous versions of texlive and with
previous versions of windows. But with Windows 7 and Tex-Live 2009 there
are _no_ environment vars set by the tlmgr and if a user sets this
TEXINPUTS var, the installation doesn't work ;-)
Ok, but now do I have to set _ALL_ of this environment Variables by hand, if
I set this aditional paths? btw: Would be good if latex, bibtex, etc would
the "defaults" which are defined AFAIK in
and not to overwrite them.
Is it enough to set
and then I can use/set the vars in my batch like
or should I set the var
and can set my customizations like:
, because latex, bibtex will now search the TEXMFCNF subdir and find
the texmf.cnf file?
Don't know/sure what is the best practice and what will work
More information about the texhax