web2c: Output file location

 
 3.4 Output file location
 ========================
 
 All the programs generally follow the usual convention for output files.
 Namely, they are placed in the directory current when the program is
 run, regardless of any input file location; or, in a few cases, output
 is to standard output.
 
    For example, if you run 'tex /tmp/foo', for example, the output will
 be in './foo.dvi' and './foo.log', not '/tmp/foo.dvi' and
 '/tmp/foo.log'.
 
    You can use the '-output-directory' option to cause all output files
 that would normally be written in the current directory to be written in
 the specified directory instead.  ⇒Common options.
 
    If the current directory is not writable, and '-output-directory' is
 not specified, the main programs (TeX, Metafont, MetaPost, and BibTeX)
 make an exception: if the config file or environment variable value
 'TEXMFOUTPUT' is set (it is not by default), output files are written to
 the directory specified.
 
    'TEXMFOUTPUT' is also checked for input files, as TeX often generates
 files that need to be subsequently read; for input, no suffixes (such as
 '.tex') are added by default and no exhaustive path searching is done,
 the input name is simply checked as given.