New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Latexmlc (LaTeXML 0.8.2) epub generation fails on Windows 10 #827
Comments
I am sorry to say currently latexml doesn't have an active windows maintainer, so the regression is understandable. If this is indeed a Windows-only problem I would welcome any patches sent to the main repository, as I may not have time to address this myself soon. |
Yeah there's that (what @dginev says)... And although I appreciate your trying to do some debugging, I'm not at all clear what the messages are saying. In the first case, isn't As for the other cases, I'm not clear what it means to "run through TeXWorks"; Isn't that a TeX frontend? I'm not clear what should happen in that case, why it might run any better. It seems that what has happened there is some confusion about which libraries get linked. That's probably not a useful scenario. |
Apologize for the late response. I'm not at all clear what the messages are saying. In the first case, isn't %1 a windows variable as used in a script? What's the actual command that gets executed? Does the TeX file implied by % exist? Were there no other errors or warnings? (Possibly the script you've used hid them?) Yes, I am executing the windows batch file to convert the active document in TeXWorks to epub using the syntax specified in https://github.com/brucemiller/LaTeXML/wiki/Integrating-LaTeXML-into-TeX-editors. The issue I found is, the Perl installation invoked in TeXWorks uses the lib from tlperl found in TeXLive folder. Whereas the same batch file executed on command prompt uses the Strawberry Perl libs where the required files (XML::LibXML) are found. As for the other cases, I'm not clear what it means to "run through TeXWorks"; Isn't that a TeX frontend? I'm not clear what should happen in that case, why it might run any better. It seems that what has happened there is some confusion about which libraries get linked. That's probably not a useful scenario. Yes, TeXWorks is a TeX Frontend that comes along with TeXLive installations. Being a newbie to Perl, unable to understand how the @inc is constructed and append the path to XML::LibXML. I understand this is off-topic. I have attached a txt file that highlights the difference in environment where the batch file (latexmlc-epub.bat) is executed. |
Thanks for the clarifications. There are 2 parts here: Firstly, LaTeXML "should" work under Strawberry Perl's Perl (ie. from the command line) since it supplies the necessary and consistent libraries. Running under TeXWorks is probably not fruitful, since there's no way to know what libraries it accesses. On the other hand, LaTeXML does need to use parts of your local TeX installation: the So, what might be useful for debugging would be to run |
Thanks for your prompt response. Here is the output captured after executing the following. E:\Testing\LaTeXML>latexmlc --dest sample2e.epub sample2e.tex (Loading C:\Strawberry\perl\site\lib\LaTeXML\Package\TeX.pool.ltxml... latexmlc (LaTeXML version 0.8.2) (Digesting TeX sample2e... (post-processing... The resultant epub along with the source attached herewith. The epub file extension has been changed to zip as epub attachment is not supported here. Sample2e.tex changed to Sample2e.txt. |
The OPS folder alongwith sample2e.xhtml missing in the resultant epub file. |
Hmm...the log looks like what it should look like, and it claims to have processed the xhtml file. But the epub file seems to be corrupt. I may have to hijack a windows machine to figure it out. |
Line No. 215-221 Pack.pm The actual text content are appended to the archive file. Any thoughts. |
Hm, the only way I can figure out what exactly misfired here is to reproduce on Windows 10 and see which part is deleted. As you say the content should be appended to the archive, which should still be operational on Linux. I may need to get an updated Windows 10 install going and come back to give feedback here, sorry for the slow reply! |
Hi! I am finally back in front of a Windows 10 machine and I can reproduce this report. Will try to diagnose now. Btw, I successfully installed a fresh latexml via:
As the epub generation failed on a very basic file, I think I will also contribute a new test, to ensure we don't regress in the future. |
There are multiple issues with epub generation.
Command line latexmlc --dest "%1.epub" "%1.tex" produces an epub with only mimetype file and META-INF folder containing container.xml.
The same script when run through TeXWorks throws an error
Can't locate loadable object for module XML::LibXML in @inc (@inc contains: C:\Strawberry\perl\site\lib D:/texlive/2016/tlpkg/tlperl/lib d:/texlive/2016/tlpkg/tlperl/site/lib d:/texlive/2016/tlpkg/tlperl/lib .) at C:\Strawberry\perl\site\lib/XML/LibXML.pm line 156.
and does not generate any epub.
On removing the path definition d:\texlive\2016\tlpkg\tlperl\bin from TeXWorks preferences, produces a new error
Cwd.c: loadable library and perl binaries are mismatched (got handshake key 0AA80080, needed 0AF00080)
The text was updated successfully, but these errors were encountered: