tectonic-typesetting / tectonic-texlive-bundles

Generate Tectonic bundles from the TeXLive source tree
MIT License
5 stars 3 forks source link

Unable to use a freshly-built bundle #13

Closed rm-dr closed 10 months ago

rm-dr commented 1 year ago

I'm trying to build a set of texlive bundles using the documented commands:

./driver.sh build-image
./driver.sh update-containers
./driver.sh make-installation bundles/tlextras
./driver.sh install-packages bundles/tlextras
./driver.sh make-zipfile bundles/tlextras
./driver.sh make-itar bundles/tlextras

I'm building against Texlive 2022 (tags/texlive-2022.0 in the git repo)

They all complete successfully, but tectonic refuses to compile latex documents using the bundle. With the V2 interface, the following Texlive.toml works:

[doc]
name = "Test"
bundle = "https://data1.fullyjustified.net/tlextras-2022.0r0.tar"

[[output]]
name = "main"
type = "pdf"

And the one below doesn't, failing with the following error. test/formats.py also fails for the same reason.

[doc]
name = "Test"
bundle = "file:///REDACTED/tectonic-texlive-bundles/state/artifacts/tlextras-2022.0r0/tlextras-2022.0r0.zip"

[[output]]
name = "main"
type = "pdf"
error: latex.ltx:10583: Undefined control sequence
error: halted on potentially-recoverable error as specified

I'm using tectonic 0.14.1. What's going on?

rm-dr commented 1 year ago

Update:

The following lines of latex.ltx in the zip bundle seem to be causing an issue: \ (These are lines 10582-10601, the first line after \ifx triggers the error above)

\ifx \Umathcode\@undefined  \else
\DeclareTextCommand{\textzerooldstyle} \UnicodeEncodingName{\oldstylenums{0}}
\DeclareTextCommand{\textoneoldstyle}  \UnicodeEncodingName{\oldstylenums{1}}
\DeclareTextCommand{\texttwooldstyle}  \UnicodeEncodingName{\oldstylenums{2}}
\DeclareTextCommand{\textthreeoldstyle}\UnicodeEncodingName{\oldstylenums{3}}
\DeclareTextCommand{\textfouroldstyle} \UnicodeEncodingName{\oldstylenums{4}}
\DeclareTextCommand{\textfiveoldstyle} \UnicodeEncodingName{\oldstylenums{5}}
\DeclareTextCommand{\textsixoldstyle}  \UnicodeEncodingName{\oldstylenums{6}}
\DeclareTextCommand{\textsevenoldstyle}\UnicodeEncodingName{\oldstylenums{7}}
\DeclareTextCommand{\texteightoldstyle}\UnicodeEncodingName{\oldstylenums{8}}
\DeclareTextCommand{\textnineoldstyle} \UnicodeEncodingName{\oldstylenums{9}}
\DeclareTextSymbol{\textpilcrow}        \UnicodeEncodingName{"00B6}
\DeclareTextSymbol{\textborn}           \UnicodeEncodingName{"002A}
\DeclareTextSymbol{\textdied}           \UnicodeEncodingName{"2020}
\DeclareTextSymbol{\textlbrackdbl}      \UnicodeEncodingName{"27E6}
\DeclareTextSymbol{\textrbrackdbl}      \UnicodeEncodingName{"27E7}
\DeclareTextSymbol{\textguarani}        \UnicodeEncodingName{"20B2}
\DeclareTextSymbol{\textdollaroldstyle}{TS1}{138}
\DeclareTextSymbol{\textcentoldstyle}  {TS1}{139}
\fi               % --- END of Unicode engines specials

I removed these lines and built all my documents using the new bundle. Everything worked.\ (Of course, maybe removing those lines broke a feature I've never used.)

diff says that the latex.ltx in the repo and the latex.ltx in the currently active tarball are identical.


I forked this repo, reworked the build process, and built a bundle from texlive2023.0r0 without any patches. It worked. Maybe the patches for tl2022 are bad?

rm-dr commented 1 year ago

In my quest to get tectonic working on my documents, I forked and rewrote the bundle-building code in this repo.

It's not done yet, but building and configuring bundles is already much easier than before.\ I also have a working texlive2023.0r0 bundle, which resolves #12.