hello I am obviously missing some blatant point, but I cannot see where.
Using texinfo 7.3 on archlinux. ----8<---- #> makeinfo --version texi2any (GNU texinfo) 7.3 Copyright (C) 2026 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. ---->8---- The problem is: makeinfo --pdf ./foo.texinfo fails with: ----8<---- #> makeinfo --pdf ./foo.texinfo /bin/texi2dvi: texinfo.tex appears to be broken. This may be due to the environment variable TEX set to something other than (plain) tex, a corrupt texinfo.tex file, or to tex itself simply not working. This is pdfTeX, Version 3.141592653-2.6-1.40.29 (TeX Live 2026/Arch Linux) (preloaded format=etex) restricted \write18 enabled. entering extended mode ! I can't find file `txiversion.tex'. <*> txiversion.tex (Press Enter to retry, or Control-D to exit) Please type another input file name: ! Emergency stop. <*> No pages of output. Transcript written on texput.log. /bin/texi2dvi: quitting. #> ---->8---- The foo.texinfo source is: ----8<---- \input texinfo @c -*-texinfo-*- @setfilename foo.info @settitle Minimal reproducer @node Top , node 1 ,(dir) ,(dir) @menu * node 1:: * node 2:: * node3:: @end menu @node node 1, node 2, Top, Top This is node 1 @node node 2, node 3, node 1, Top This is node 2 @node node 3, , node 2, Top This is node 3 @bye ---->8---- As far as I seem to understand, the error happens inside the function run_makeinfo of the texi2dvi script, precisely here: ----8<---- $TEX txiversion.tex </dev/null >txiversion.out 2>txiversion.err ---->8---- The compilation of txiversion.tex (the line above) is run in the $version_test_dir directory, which gets created on the fly as a subdirectory of the directory where foo.texinfo is located. If I print the value of $version_test_dir just before the failing line, I get: ----8<---- foo.t2d/version_test ---->8---- Since the path to the txiversion.tex source to be compiled by $TEX is not explicitly defined, $TEX relies upon TEXINPUTS to find it. My TEXINPUTS environment variable is: ----8<---- TEXINPUTS=./:/home/balducci/latex/packages//:/usr/share/texmf-dist// ---->8---- I would expect that my TEXINPUTS variable would allow $TEX to find the txiversion.tex source, since it contains the current directory "./"; but if I print the value of TEXINPUTS just before the failing line, I get: ----8<---- /home/balducci/tmp/texinfo-pdf:/home/balducci/tmp/texinfo-pdf/.:/home/balducci/tmp/texinfo-pdf/./:/home/balducci/latex/packages//:/usr/share/texmf-dist// ---->8---- that is: the current directory "./" originally present in my TEXINPUTS variable has been appended to the *absolute* path of the directory where the foo.texinfo is located. I can now see the origin of the error, since txiversion.tex is not present in any path contained in TEXINPUTS. In support of my interpretation, if I define my TEXINPUTS variable as: ----8<---- TEXINPUTS=.//:/home/balducci/latex/packages//:/usr/share/texmf-dist// ---->8---- (that is: ".//" instead of "./") then the makeinfo command completes successfully. However, having ".//" in TEXINPUTS does not seem a good thing to me, for, in general, one wants to be independent on whatever is located under the current directory in the file system. Another way to make the makeinfo command succeed is to explicitly tell $TEX that txiversion.tex is in the current directory: ----8<---- #> diff -u texi2dvi-BAD texi2dvi-GOOD --- texi2dvi-BAD 2026-05-16 15:15:48.349066869 -0100 +++ texi2dvi-GOOD 2026-05-16 15:16:10.055797934 -0100 @@ -1115,7 +1115,7 @@ echo '\input texinfo.tex @bye' >txiversion.tex # Be sure that if tex wants to fail, it is not interactive: # close stdin. - $TEX txiversion.tex </dev/null >txiversion.out 2>txiversion.err + $TEX ./txiversion.tex </dev/null >txiversion.out 2>txiversion.err ); then :; else report "texinfo.tex appears to be broken. This may be due to the environment variable TEX set to something ---->8---- This seems to me a much better and portable solution, since this way the compilation test of txiversion.tex is completely independent on any possible value of the TEXINPUTS variable. So my questions are: * can anybody on the list reproduce this problem? * if not: what am I doing wrong? I thank you very much in advance for any hint/help ciao -gabriele
