auctex
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: LaTeX doesn't find the source file


From: Oscar Bruno
Subject: Re: LaTeX doesn't find the source file
Date: Tue, 1 Mar 2022 10:55:57 -0800

Dear Ikumi --

1. Go where the source file is (e.g., "cd c:/tmp") and run pdflatex
   directly (without involving emacs):
pdflatex SOURCEFILE.tex
   Does that run normally or stop with the same error?

This does not result in error. In fact, this is the method I have been using to do my work since I found this problem. Below please find a sample output:

****************
abbey $ pdflatex test.tex
This is pdfTeX, Version 3.14159265-2.6-1.40.16 (TeX Live 2015/Cygwin) (preloaded format=pdflatex)
 restricted \write18 enabled.
entering extended mode
(./test.tex
LaTeX2e <2015/01/01>
Babel <3.9l> and hyphenation patterns for 79 languages loaded.
(/usr/share/texmf-dist/tex/latex/base/article.cls
Document Class: article 2014/09/29 v1.4h Standard LaTeX document class
(/usr/share/texmf-dist/tex/latex/base/size10.clo)) (./test.aux) [1{/var/lib/tex
mf/fonts/map/pdftex/updmap/pdftex.map}] (./test.aux) )</usr/share/texmf-dist/fo
nts/type1/public/amsfonts/cm/cmr10.pfb>
Output written on test.pdf (1 page, 12705 bytes).
Transcript written on test.log.
****************

2. If that doesn't cause error, try diabling your personal setting for
   emacs according to AUCTeX FAQ.
   (The paragraph which begins with
Second, you can try to figure out if...
   in https://www.gnu.org/software/auctex/manual/auctex/FAQ.html#FAQ )
   On windows, the command `emacs -q -no-site-file -l auctex' should be
   replaced with `runemacs -q -no-site-file -l auctex'.

This test did provide an interesting result -- although I cannot say what the problem is, it may give you a useful hint.

The test is as you suggested:

****************
abbey $ ls
test.aux  test.log  test.pdf  test.tex  test.tex~  texput.log
abbey $ runemacs -q -no-site-file -l auctex test.tex
****************

As a result of this an emacs window opened with the following error message:

****************
Cannot open load file: No such file or directory, auctex
****************

So, auctex cannot find the file, even though the command is invoked in the directory that contains the file (per the ls command shown above).

It seems you are getting close!

Thanks,

Oscar


On Mon, Feb 28, 2022 at 10:30 PM Ikumi Keita <ikumi@ikumi.que.jp> wrote:
Hi Oscar,

Then, open command prompt and try the following one or two:
1. Go where the source file is (e.g., "cd c:/tmp") and run pdflatex
   directly (without involving emacs):
pdflatex SOURCEFILE.tex
   Does that run normally or stop with the same error?
2. If that doesn't cause error, try diabling your personal setting for
   emacs according to AUCTeX FAQ.
   (The paragraph which begins with
Second, you can try to figure out if...
   in https://www.gnu.org/software/auctex/manual/auctex/FAQ.html#FAQ )
   On windows, the command `emacs -q -no-site-file -l auctex' should be
   replaced with `runemacs -q -no-site-file -l auctex'.

Regards,
Ikumi Keita
#StandWithUkraine #StopRussianAggression

>>>>> Oscar Bruno <obruno@caltech.edu> writes:
> Hi Ikumi -- thanks for the suggestions

> 3. Is that error peculiar to the file "ParallelIFGF.tex", or common for
>> other files?
>> 4. Make a folder which contains pure ASCII characters in its path, say,
>> C:\tmp .  Then place some LaTeX source file there and open it with
>> AUCTeX.  Does the same error persist for that file, too?


> The error is not peculiar to this particular file: it happens with all tex
> files I have tested in many different directories. Following your
> suggestion I created a new directory  C:\tmp, and the super simple tex
> file test.tex which contains the following:

> \documentclass{article}
> \begin{document}

> This is a test latex code.

> \end{document}

> ***********
> Typesetting using C-c C-c I got the following error message:

> Running `LaTeX' on `test' with ``pdflatex  -file-line-error
>  -interaction=nonstopmode "test.tex"''
> This is pdfTeX, Version 3.14159265-2.6-1.40.21 (TeX Live 2020/W32TeX)
> (preloaded format=pdflatex)
>  restricted \write18 enabled.
> entering extended mode
> ! I can't find file `test.tex'.
> <*> test.tex

> (Press Enter to retry, or Control-Z to exit)
> Please type another input file name
> ! Emergency stop.
> <*> test.tex

> !  ==> Fatal error occurred, no output PDF file produced!
> Transcript written on texput.log.

> TeX Output exited abnormally with code 1 at Mon Feb 28 10:18:06

> ***********
> With regards to your other questions:

> 1. What is the value of `default-directory' in the source file buffer?
>> (In that buffer, type C-h v default-directory RET to see its value.)
>> 2. Does that result point to the directory (folder) where the source
>> file is?


> I did this for several files, and it always points to the directory where
> the source file is. For example, the output on the test file above is the
> following

> default-directory is a variable defined in ‘C source code’.
> Its value is "c:/tmp/"
> Local in buffer test.tex; global value is nil

>   Automatically becomes permanently buffer-local when set.
>   This variable is safe as a file local variable if its value
>   satisfies the predicate ‘stringp’.

> Documentation:
> Name of default directory of current buffer.
> It should be a directory name (as opposed to a directory file-name).
> On GNU and Unix systems, directory names end in a slash ‘/’.
> To interactively change the default directory, use command ‘cd’.

> ***********
> Thanks for looking into it.

> Oscar

reply via email to

[Prev in Thread] Current Thread [Next in Thread]