Menu

#1461 PDF docs, has anything changed in building process ?

v3.6
closed
nobody
None
Windows
Buildsystem
2021-12-30
2021-04-06
Retroplay
No

Path of installed programs:
MSYS2 (C:\MSYS64)
MiKTeX (C:\MiKTeX)

Making all in readmes
You don't have a working TeX binary (tex) installed anywhere in
your PATH, and texi2dvi cannot proceed without one.  If you want to use
this script, you'll need to install TeX (if you don't have it) or change
your PATH or TEX environment variable (if you do).  See the --help
output for more details.

For information about obtaining TeX, please see http://tug.org/texlive,
or do a web search for TeX and your operating system or distro.
make[2]: *** [Makefile:851: vice.pdf] Error 1
make[1]: *** [Makefile:558: all-recursive] Error 1
make: *** [Makefile:521: all-recursive] Error 1

Michael@Husalteret MINGW64 /src/vice
$ pacman -Ss texi
msys/texinfo 6.7-3 (base-devel) [installed]
    Utilities to work with and produce manuals, ASCII text, and on-line
    documentation from a single source file
msys/texinfo-tex 6.7-3 (base-devel) [installed]
    Utilities to work with and produce manuals, ASCII text, and on-line
    documentation from a single source file

Michael@Husalteret MINGW64 /src/vice
$ echo "$PATH:"
/mingw64/bin:/usr/local/bin:/usr/bin:/bin:/c/Windows/System32:/c/Windows:/c/Windows/System32/Wbem:/c/Windows/System32/WindowsPowerShell/v1.0/:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/c/miktex/miktex/bin/x64:

Michael@Husalteret MINGW64 /src/vice
$

As you can see, texinfo + texinfo-tex is installed and MiKTeX is added to my path, yet the script can't find tex bin anywhere ?

I tried with TeX Live as well (took ages to install), same deal.

Discussion

  • gpz

    gpz - 2021-04-06

    Did it work before? (before when?)

    I dont think anything changed in that area for a while shrug

     
  • Retroplay

    Retroplay - 2021-04-06

    It used to work, yes.
    All I have done is reinstall MSYS2 because a faulty mintty update broke the system (unable to open/log into shell).
    Also, when doing ./ configure, pdftex is found as well as texinfo.
    I have no idea what's going on here.

    If problem persists, I'll just --disable-pdf-docs, everything else is working as it should.

     
  • Greg King

    Greg King - 2021-04-07

    The bug is in MSys2's BASH, not VICE. It sets an environment variable to a wrong spelling:

    $ declare -p OSTYPE
    declare -- OSTYPE="msys"
    

    OSTYPE should hold an upper-case "MSYS". That misspelling makes texi2dvi think that it's running on pure Windows (not a POSIX overlay). Therefore, it looks for semicolons in the PATH string, instead of colons. It can't find where to look for programs.

    You can work around that bug by putting this line in "~/.bash_profile":

    export OSTYPE="MSYS"
    
     
  • Retroplay

    Retroplay - 2021-04-07

    You're a lifesaver, Greg.
    That did the trick.
    Perhaps this should be added to MiKTeX instructions part of the docs for Windows.
    Might save others from a headache, or two :)

    Which reminds me,
    yasm is also needed if configured with --enable-static-ffmpeg.
    $ pacman -S mingw-w64-i686-yasm mingw-w64-x86_64-yasm
    Just an FYI

     
    • compyx

      compyx - 2021-04-07

      Our 'Windows-MinGW-GTK3-Howto.txt' doesn't mention yasm at all, so do we add yasm to the section "Run the following command lines to install your prerequisites", or do we make a separate section for ffmpeg where we mention yasm?

       
      • Greg King

        Greg King - 2021-04-07

        I have some updates for that "Howto" file. One of them is that we don't need to build the static stuff anymore; MSys2 has FFMPEG now. I'll submit a patch.

         
        • compyx

          compyx - 2021-04-07

          Alright, that would be much appreciated.

           
  • compyx

    compyx - 2021-04-07

    I'm confused, shouldn't configure error out when it can't find pdftex?

    I haven't updated msys2 in a while, but my msys2 install also has the lower case 'msys':

    $ declare -p OSTYPE
    declare -- OSTYPE="msys"
    

    I did have C:\opt\miktex\miktex\bin\x64 in my Windows %PATH%, which would explain the "configure assuming running on pure Windows with lower case 'msys'".
    However when I removed that (and rebooted) configure still finds pdftex and the .pdf file is properly built.

    In my ~/.bash_profile I have:

    export PATH="$PATH:/c/opt/miktex/miktex/bin/x64"
    

    When I comment that out, configure fails, as it should.

    So I'm not sure the upper/lower case 'msys' is the issue. Also, if that is indeed a bug in msys2, why can't I find any bug report/fix for this?

     
  • Greg King

    Greg King - 2021-04-07

    It's not "configure"; it's "texi2dvi". Look at lines 79 to 92 in "/bin/texi2dvi".

    The "uname" command wants to see "MSYS"; it doesn't recognize "msys"!

     
  • Greg King

    Greg King - 2021-04-07

    So ... we have bash (it seems to set OSTYPE), texi2dvi, and uname. At least one of them changed (and broke) recently (I don't know exactly when it happened).

     
  • gpz

    gpz - 2021-09-07

    so how do we solve this?

     
  • Marco van den Heuvel

    installed miktex, added it to my msys path, configured vice, then during the build miktex dialog showed up and asked me for some stuff that needed to be installed, I let it install and update and now I have a vice.pdf

    AKA works for me.

     
  • gpz

    gpz - 2021-09-08

    you probably need an up to date msys2

     
  • gpz

    gpz - 2021-09-08
     
  • gpz

    gpz - 2021-10-25

    so apparently the issue got closed

    the question is still how we should proceed. is the problem still present in an up to date msys2 ?

     
  • compyx

    compyx - 2021-10-25

    I'll check, but if it is and msys2 just closes the issue without any feedback, what can we do?

     
  • gpz

    gpz - 2021-10-25

    all we can do is adding the workaround to the docs, and to the wiki page - i guess (one of you guess will have to do it, i am still not sure i understood the problem+solution 100%)

     
  • compyx

    compyx - 2021-10-25

    Since msys2 now carries texlive, I uninstalled miktex from C:\opt, updated $PATH and used some texlive packages from the msys2 repos. So now pdftex is correctly found by configure, but we run into another issue:

    /usr/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.22 (TeX Live 2021/Built by MSYS2 project) (preloaded format=etex)
     restricted \write18 enabled.
    entering extended mode
    ! I can't find file `txiversion.tex'.
    <*> txiversion.tex
    
    (Press Enter to retry, or Control-Z to exit)
    Please type another input file name:
    ! Emergency stop.
    <*> txiversion.tex
    
    No pages of output.
    Transcript written on texput.log.
    /usr/bin/texi2dvi: quitting.
    make[2]: *** [Makefile:855: vice.pdf] Error 1
    make[1]: *** [Makefile:562: all-recursive] Error 1
    make: *** [Makefile:525: all-recursive] Error 1
    

    Using find / -name 'txiversion.tex it indeed appears there is no 'txiversion.tex' file anywhere in the msys2 tree on my system. So I'll try to wrestle the pacman package manager into giving me the package(s) that provide that file.

     
  • compyx

    compyx - 2021-10-25

    Looks like texi2dvi is supposed to generate the txiversion.tex file, but before that happens texi2dvi complains about a corrupt texinfo.tex file. All this works fine on my Debian box, which also uses texlive.

    I give up, someone who knows more about Windows and TeX can have a look.

     
  • gpz

    gpz - 2021-10-26
    • Category: Documentation --> Buildsystem
     
  • compyx

    compyx - 2021-10-28
    • status: open --> closed
     
  • compyx

    compyx - 2021-10-28

    Blacky Stardust mentioned this works on his Windows box without a hitch, so must by msys2 config. Closing.

     

Log in to post a comment.

MongoDB Logo MongoDB