Nie jesteś zalogowany.
Jeśli nie posiadasz konta, zarejestruj je już teraz! Pozwoli Ci ono w pełni korzystać z naszego serwisu. Spamerom dziękujemy!
Prosimy o pomoc dla małej Julki — przekaż 1% podatku na Fundacji Dzieciom zdazyć z Pomocą.
Więcej informacji na dug.net.pl/pomagamy/.
Strony: 1
Fragment *.php:
exec("cd ".PUN_ROOT.$path."; latex f$prefix.tex");
Po wykonaniu kodu log zawiera:
This is pdfTeX, Version 3.1415926-1.40.9 (Web2C 7.5.7) (format=latex 2010.5.12) 12 MAY 2010 18:37 entering extended mode **f14.tex (./f14.tex LaTeX2e <2005/12/01> Babel <v3.8l> and hyphenation patterns for english, usenglishmax, dumylang, noh yphenation, loaded. ! LaTeX Error: File `article.cls' not found. Type X to quit or <RETURN> to proceed, or enter new name. (Default extension: cls) Enter file name: ! Emergency stop. <read *> l.1 \documentclass{article}\oddsidemargin 0pt^^M End of file on the terminal! Here is how much of TeX's memory you used: 10 strings out of 10070 164 string characters out of 33056 45092 words of memory out of 3000000 3285 multiletter control sequences out of 10000+647 3640 words of font info for 14 fonts, out of 100000 for 500 28 hyphenation exceptions out of 659 10i,0n,7p,68b,8s stack positions out of 300i,50n,60p,3000b,4000s No pages of output.
Spodziewany plik nie jest tworzony.
Log tego samego polecenia wykonanego w terminalu ręcznie:
This is pdfTeXk, Version 3.1415926-1.40.9 (Web2C 7.5.7) (format=latex 2010.5.12) 12 MAY 2010 18:34 entering extended mode %&-line parsing enabled. **f13.tex (./f13.tex LaTeX2e <2005/12/01> Babel <v3.8l> and hyphenation patterns for english, usenglishmax, dumylang, noh yphenation, loaded. (/usr/share/texmf-dist/tex/latex/base/article.cls Document Class: article 2005/09/16 v1.4f Standard LaTeX document class (/usr/share/texmf-dist/tex/latex/base/size10.clo File: size10.clo 2005/09/16 v1.4f 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 ) (/usr/share/texmf-dist/tex/latex/amsfonts/amssymb.sty Package: amssymb 2002/01/22 v2.2d (/usr/share/texmf-dist/tex/latex/amsfonts/amsfonts.sty Package: amsfonts 2001/10/25 v2.2f \@emptytoks=\toks14 \symAMSa=\mathgroup4 \symAMSb=\mathgroup5 LaTeX Font Info: Overwriting math alphabet `\mathfrak' in version `bold' (Font) U/euf/m/n --> U/euf/b/n on input line 132. )) (/usr/share/texmf-dist/tex/latex/amsmath/amsmath.sty Package: amsmath 2000/07/18 v2.13 AMS math features \@mathmargin=\skip43 For additional information on amsmath, use the `?' option. (/usr/share/texmf-dist/tex/latex/amsmath/amstext.sty Package: amstext 2000/06/29 v2.01 (/usr/share/texmf-dist/tex/latex/amsmath/amsgen.sty File: amsgen.sty 1999/11/30 v2.0 \@emptytoks=\toks15 \ex@=\dimen103 )) (/usr/share/texmf-dist/tex/latex/amsmath/amsbsy.sty Package: amsbsy 1999/11/29 v1.2d \pmbraise@=\dimen104 ) (/usr/share/texmf-dist/tex/latex/amsmath/amsopn.sty Package: amsopn 1999/12/14 v2.01 operator names ) \inf@bad=\count87 LaTeX Info: Redefining \frac on input line 211. \uproot@=\count88 \leftroot@=\count89 LaTeX Info: Redefining \overline on input line 307. \classnum@=\count90 \DOTSCASE@=\count91 LaTeX Info: Redefining \ldots on input line 379. LaTeX Info: Redefining \dots on input line 382. LaTeX Info: Redefining \cdots on input line 467. \Mathstrutbox@=\box26 \strutbox@=\box27 \big@size=\dimen105 LaTeX Font Info: Redeclaring font encoding OML on input line 567. LaTeX Font Info: Redeclaring font encoding OMS on input line 568. \macc@depth=\count92 \c@MaxMatrixCols=\count93 \dotsspace@=\muskip10 \c@parentequation=\count94 \dspbrk@lvl=\count95 \tag@help=\toks16 \row@=\count96 \column@=\count97 \maxfields@=\count98 \andhelp@=\toks17 \eqnshift@=\dimen106 \alignsep@=\dimen107 \tagshift@=\dimen108 \tagwidth@=\dimen109 \totwidth@=\dimen110 \lineht@=\dimen111 \@envbody=\toks18 \multlinegap=\skip44 \multlinetaggap=\skip45 \mathdisplay@stack=\toks19 LaTeX Info: Redefining \[ on input line 2666. LaTeX Info: Redefining \] on input line 2667. ) No file f13.aux. \openout1 = `f13.aux'. LaTeX Font Info: Checking defaults for OML/cmm/m/it on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Checking defaults for T1/cmr/m/n on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Checking defaults for OT1/cmr/m/n on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Checking defaults for OMS/cmsy/m/n on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Checking defaults for OMX/cmex/m/n on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Checking defaults for U/cmr/m/n on input line 5. LaTeX Font Info: ... okay on input line 5. LaTeX Font Info: Try loading font information for U+msa on input line 7. (/usr/share/texmf-dist/tex/latex/amsfonts/umsa.fd File: umsa.fd 2002/01/19 v2.2g AMS font definitions ) LaTeX Font Info: Try loading font information for U+msb on input line 7. (/usr/share/texmf-dist/tex/latex/amsfonts/umsb.fd File: umsb.fd 2002/01/19 v2.2g AMS font definitions ) [1 ] (./f13.aux) ) Here is how much of TeX's memory you used: 1087 strings out of 495070 11852 string characters out of 1183056 56671 words of memory out of 3000000 4316 multiletter control sequences out of 10000+50000 6239 words of font info for 25 fonts, out of 3000000 for 5000 28 hyphenation exceptions out of 8191 27i,4n,24p,215b,110s stack positions out of 5000i,500n,10000p,200000b,50000s Output written on f13.dvi (1 page, 628 bytes).
Spodziewany plik jest tworzony.
Wydaje się, że w PHP nie znajduje pliku /usr/share/texmf-dist/tex/latex/base/article.cls. Pomocy?
Offline
nie umiesz debugowac....
sprawdz zamiast latex moze jakieś ls, albi coś w tym slylu? pwd i takie tam
może w ustawieniach jest zablokowany dostep do ścieżki?
Offline
Kod PHP jest wykonywany jako inny użytkownik (www czy cos w ten desen). Mozesz nie miec ustawionych podstawowych zmiennych systemowych, jak głupie PATH czy jakiejś wewnętrznej zmiennej LaTeX-owej która mówi gdzie należy szukać plików klas.
Offline
Wydaje się, że rzeczywiście chodziło o PATH. Dlaczego jednak znajdował /usr/bin/latex (mniejsza z tym, że nie działał jak należy), ale /usr/bin/strace już nie, pozostanie dla mnie zagadką.
Dzięki.
Offline
Strony: 1