For a minimal non-working example, here is the first document, called mwe1.tex:
Code: Select all
\documentclass{article}
\begin{document}
\immediate\write18{latex mwe2.tex}
This is document 1.
\end{document}
Code: Select all
\documentclass{article}
\begin{document}
This is document 2.
\end{document}
On the MiKTeX website and elsewhere, I read that \write18 is "partially enabled" out of the box for MiKTeX 2.9, meaning that it should run recognized commands such as latex or pdflatex without "-enable-write18" or "-shell-escape". However, when I run "latex mwe1.tex" or "pdflatex mwe1.tex", the \write18 does not seem to work: I get a DVI or PDF file for mwe1, but no DVI or PDF for mwe2. The following line occurs in the .log file:
Code: Select all
runsystem(latex mwe2.tex)...disabled (restricted).
Code: Select all
This is pdfTeX, Version 3.1415926-1.40.11 (MiKTeX 2.9) (preloaded format=latex 2011.4.7) 10 MAY 2011 12:18
entering extended mode
**mwe1.tex
("C:\Documents and Settings\ahendric\Desktop\deleteme\doublecompile\MWE\mwe1.te
x"
LaTeX2e <2009/09/24>
Babel <v3.8l> and hyphenation patterns for english, afrikaans, ancientgreek, ar
abic, armenian, assamese, basque, bengali, bokmal, bulgarian, catalan, coptic,
croatian, czech, danish, dutch, esperanto, estonian, farsi, finnish, french, ga
lician, german, german-x-2009-06-19, greek, gujarati, hindi, hungarian, iceland
ic, indonesian, interlingua, irish, italian, kannada, kurmanji, lao, latin, lat
vian, lithuanian, malayalam, marathi, mongolian, mongolianlmc, monogreek, ngerm
an, ngerman-x-2009-06-19, nynorsk, oriya, panjabi, pinyin, polish, portuguese,
romanian, russian, sanskrit, serbian, slovak, slovenian, spanish, swedish, swis
sgerman, tamil, telugu, turkish, turkmen, ukenglish, ukrainian, uppersorbian, u
senglishmax, welsh, loaded.
("C:\Program Files\MiKTeX 2.9\tex\latex\base\article.cls"
Document Class: article 2007/10/19 v1.4h Standard LaTeX document class
("C:\Program Files\MiKTeX 2.9\tex\latex\base\size10.clo"
File: size10.clo 2007/10/19 v1.4h Standard LaTeX file (size option)
)
\c@part=\count79
\c@section=\count80
\c@subsection=\count81
\c@subsubsection=\count82
\c@paragraph=\count83
\c@subparagraph=\count84
\c@figure=\count85
\c@table=\count86
\abovecaptionskip=\skip41
\belowcaptionskip=\skip42
\bibindent=\dimen102
)
("C:\Documents and Settings\ahendric\Desktop\deleteme\doublecompile\MWE\mwe1.au
x")
LaTeX Font Info: Checking defaults for OML/cmm/m/it on input line 2.
LaTeX Font Info: ... okay on input line 2.
LaTeX Font Info: Checking defaults for T1/cmr/m/n on input line 2.
LaTeX Font Info: ... okay on input line 2.
LaTeX Font Info: Checking defaults for OT1/cmr/m/n on input line 2.
LaTeX Font Info: ... okay on input line 2.
LaTeX Font Info: Checking defaults for OMS/cmsy/m/n on input line 2.
LaTeX Font Info: ... okay on input line 2.
LaTeX Font Info: Checking defaults for OMX/cmex/m/n on input line 2.
LaTeX Font Info: ... okay on input line 2.
LaTeX Font Info: Checking defaults for U/cmr/m/n on input line 2.
LaTeX Font Info: ... okay on input line 2.
runsystem(latex mwe2.tex)...disabled (restricted).
[1
]
("C:\Documents and Settings\ahendric\Desktop\deleteme\doublecompile\MWE\mwe1.au
x") )
Here is how much of TeX's memory you used:
202 strings out of 494054
2546 string characters out of 3148564
48862 words of memory out of 3000000
3577 multiletter control sequences out of 15000+200000
3640 words of font info for 14 fonts, out of 3000000 for 9000
715 hyphenation exceptions out of 8191
23i,4n,17p,152b,107s stack positions out of 5000i,500n,10000p,200000b,50000s
Output written on mwe1.dvi (1 page, 328 bytes).