tudace / tuda_latex_templates

LaTeX Templates for TU Darmstadt
LaTeX Project Public License v1.3c
208 stars 71 forks source link

pdfa option not working with lualatex #422

Closed PeteS4 closed 1 year ago

PeteS4 commented 1 year ago

Package version:

texlive-tuda-ci.noarch    9:svn58661-59.fc37
texlive-pdfx.noarch       9:svn50338-59.fc37

MWE:

\documentclass[pdfa=true]{tudapub}
\begin{document}
Test
\end{document}

When using the pdfa=true option with pdflatex, I get a warning stating

Package tudapub Warning: You use pdfa-mode in PDFTeX.
(tudapub)                This can lead to incompatiblities especially with
(tudapub)                older compiler versions.
(tudapub)                You should prefer using lualatex.

When I use lualatex instead of pdflatex, the document does not compile, and the log reads:

[...]

/usr/share/texlive/texmf-dist/tex/latex/pdfx/pdfx.sty:1264: Undefined control sequence.
l.1264  \ifnum\shellescape
                        =1
/usr/share/texlive/texmf-dist/tex/latex/pdfx/pdfx.sty:1264: Missing number, treated as zero.
<to be read again> 
=
l.1264  \ifnum\shellescape=
                         1

/usr/share/texlive/texmf-dist/tex/latex/pdfx/pdfx.sty:1285: Package pdfx Error: CreationDate is not properly supported;
 PDF validation may fail..

See the pdfx package documentation for explanation.
Type  H <return>  for immediate help.
 ...                                              

l.1285 ...utput-driver="xdvipdfmx -z 0" <filename> }

[...]

warning  (pdf backend): objcompresslevel > 0 requires minorversion > 4
<<sRGB.icc>> (/usr/share/texlive/texmf-dist/tex/generic/pdftex/glyphtounicode.tex
/usr/share/texlive/texmf-dist/tex/generic/pdftex/glyphtounicode.tex:7: Undefined control sequence.
l.7 \pdfglyphtounicode
                    {A}{0041}

/usr/share/texlive/texmf-dist/tex/generic/pdftex/glyphtounicode.tex:7: LaTeX Error: Missing \begin{document}.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              

l.7 \pdfglyphtounicode{A
                      }{0041}
/usr/share/texlive/texmf-dist/tex/generic/pdftex/glyphtounicode.tex:8: Undefined control sequence.
l.8 \pdfglyphtounicode
                    {AE}{00C6}
/usr/share/texlive/texmf-dist/tex/generic/pdftex/glyphtounicode.tex:9: Undefined control sequence.

[...]

This goes on for 100 similar errors and then aborts.

TeXhackse commented 1 year ago

We are not officially supporting the linux distro packages just vanilla texlive. With an up to date TeX Live (and even some older) ones it's working without any issues.

I'd need more information on your package status and LaTeX kernel version to reconstruct but I still think it's a specific issue unrelated to TUDa-CI.

btw… pdfa should be true by default so need to enable that option.

PeteS4 commented 1 year ago

Thanks for the fast reply.

Output of \listfiles:

 *File List*
 tudapub.cls    2021/03/19 v3.13a Publications using TU Darmstadt's Corporate Design (TUDa-CI)
   expl3.sty    2021-05-07 L3 programming layer (loader) 
l3backend-pdftex.def    2021-05-07 L3 backend support: PDF output (pdfTeX)
l3keys2e.sty    2021-05-07 LaTeX2e option processing using LaTeX3 keys
URspecialopts.sty    2019/01/22 v2.1 Implementation of keyval-options accepting multiple values as grouped clists
  xparse.sty    2021-01-09 L3 Experimental document command parser
xparse-2020-10-01.sty    
scrartcl.cls    2021/03/17 v3.33 KOMA-Script document class (article)
scrkbase.sty    2021/03/17 v3.33 KOMA-Script package (KOMA-Script-dependent basics and keyval usage)
 scrbase.sty    2021/03/17 v3.33 KOMA-Script package (KOMA-Script-independent basics and keyval usage)
scrlfile.sty    2021/03/17 v3.33 KOMA-Script package (file load hooks)
scrlfile-hook.sty    2021/03/17 v3.33 KOMA-Script package (using LaTeX hooks)
 scrlogo.sty    2021/03/17 v3.33 KOMA-Script package (logo)
  keyval.sty    2014/10/28 v1.15 key=value parser (DPC)
tocbasic.sty    2021/03/17 v3.33 KOMA-Script package (handling toc-files)
tudasize9pt.clo    TUDa-CI  font size class option (9pt)
typearea.sty    2021/03/17 v3.33 KOMA-Script package (type area)
tudarules.sty    2021/03/19 v3.13a Creation of colored bars for tuda-ci bundle
tudacolors.sty    2021/03/19 v3.13a Color definition for TU Darmstadt's tuda-ci bundle
  xcolor.sty    2016/05/11 v2.12 LaTeX color extensions (UK)
   color.cfg    2016/01/02 v1.6 sample color configuration
  pdftex.def    2020/10/05 v1.2a Graphics/color driver for pdftex
tudacolors.def    2021/03/19 3.13a Color definitions for tuda-ci
tudafonts.sty    2021/03/19 3.13a font loading for TUDa-CI, TU Darmstadt's Corporate Design
   iftex.sty    2020/03/06 v1.0d TeX engine tests
anyfontsize.sty    2007/11/22 anyfontsize.sty by pts
XCharter.sty    2021/04/03 v1.216
 fontenc.sty
  t2aenc.def    2005/09/27 v1.0i Cyrillic encoding definition file
  t2aenc.dfu    2019/11/14 v1.2k UTF-8 support for inputenc
  ly1enc.def    2009/07/22 v0.7 TeX 'n ANSI encoding (DPC/KB)
  ly1enc.dfu    2019/11/14 v1.2k UTF-8 support for inputenc
textcomp.sty    2020/02/02 v2.0n Standard LaTeX package
scalefnt.sty    
etoolbox.sty    2020/10/05 v2.5k e-TeX tools for LaTeX (JAW)
 xstring.sty    2019/02/06 v1.83 String manipulations (CT)
  ifthen.sty    2014/09/29 v1.1c Standard LaTeX ifthen package (DPC)
fontaxes.sty    2020/07/21 v1.0e Font selection axes
 xkeyval.sty    2020/11/20 v2.8 package option processing (HA)
 xkeyval.tex    2014/12/03 v2.7a key=value parser (HA)
microtype.sty    2021/03/14 v2.8c Micro-typographical refinements (RS)
microtype-pdftex.def    2021/03/14 v2.8c Definitions specific to pdftex (RS)
microtype.cfg    2021/03/14 v2.8c microtype main configuration file (RS)
  roboto.sty    2019/12/11 (Bob Tennent) Supports Roboto fonts for all LaTeX engines.
 ifxetex.sty    2019/10/25 v0.7 ifxetex legacy package. Use iftex instead.
ifluatex.sty    2019/10/25 v1.5 ifluatex legacy package. Use iftex instead.
 fontenc.sty
T1XCharter-TLF.fd    2017/06/25 (autoinst) Font definitions for T1/XCharter-TLF.
roboto-mono.sty    2019/12/11 (Bob Tennent) Supports RobotoMono fonts for all LaTeX engines.
 fontenc.sty
scrlayer-scrpage.sty    2021/03/17 v3.33 KOMA-Script package (end user interface for scrlayer)
scrlayer.sty    2021/03/17 v3.33 KOMA-Script package (defining layers and page styles)
geometry.sty    2020/01/02 v5.9 Page Geometry
  ifvtex.sty    2019/10/25 v1.7 ifvtex legacy package. Use iftex instead.
tuda-a4paper.clo    2021/03/19 v3.13a tuda-ci size adjustments for a4paper
graphicx.sty    2020/09/09 v1.2b Enhanced LaTeX Graphics (DPC,SPQR)
graphics.sty    2020/08/30 v1.4c Standard LaTeX Graphics (DPC,SPQR)
    trig.sty    2016/01/03 v1.10 sin cos tan (DPC)
graphics.cfg    2016/06/04 v1.11 sample graphics configuration
hyperref.sty    2021-02-27 v7.00k Hypertext links for LaTeX
 ltxcmds.sty    2020-05-10 v1.25 LaTeX kernel commands for general use (HO)
pdftexcmds.sty    2020-06-27 v0.33 Utility functions of pdfTeX for LuaTeX (HO)
infwarerr.sty    2019/12/03 v1.5 Providing info/warning/error messages (HO)
kvsetkeys.sty    2019/12/15 v1.18 Key value parser (HO)
kvdefinekeys.sty    2019-12-19 v1.6 Define keys (HO)
pdfescape.sty    2019/12/09 v1.15 Implements pdfTeX's escape features (HO)
 hycolor.sty    2020-01-27 v1.10 Color options for hyperref/bookmark (HO)
letltxmacro.sty    2019/12/03 v1.6 Let assignment for LaTeX macros (HO)
 auxhook.sty    2019-12-17 v1.6 Hooks for auxiliary files (HO)
kvoptions.sty    2020-10-07 v3.14 Key value format for package options (HO)
  pd1enc.def    2021-02-27 v7.00k Hyperref: PDFDocEncoding definition (HO)
hyperref-langpatches.def    2021-02-27 v7.00k Hyperref: patches for babel languages
 intcalc.sty    2019/12/15 v1.3 Expandable calculations with integers (HO)
etexcmds.sty    2019/12/15 v1.7 Avoid name clashes with e-TeX commands (HO)
   puenc.def    2021-02-27 v7.00k Hyperref: PDF Unicode definition (HO)
     url.sty    2013/09/16  ver 3.4  Verb mode for urls, etc.
  bitset.sty    2019/12/09 v1.3 Handle bit-vector datatype (HO)
bigintcalc.sty    2019/12/15 v1.5 Expandable calculations on big integers (HO)
atbegshi-ltx.sty    2020/08/17 v1.0a Emulation of the original atbegshi package
with kernel methods
 hpdftex.def    2021-02-27 v7.00k Hyperref driver for pdfTeX
atveryend-ltx.sty    2020/08/19 v1.0a Emulation of the original atvery package
with kernel methods
rerunfilecheck.sty    2019/12/05 v1.9 Rerun checks for auxiliary files (HO)
uniquecounter.sty    2019/12/15 v1.4 Provide unlimited unique counter (HO)
  t2acmr.fd    2001/08/11 v1.0a Computer Modern Cyrillic font definitions
  ly1ptm.fd    2001/02/01 font definitions for LY1/ptm using Berry names.
supp-pdf.mkii
epstopdf-base.sty    2020-01-24 v2.11 Base part for package epstopdf
epstopdf-sys.cfg    2010/07/13 v1.3 Configuration of (r)epstopdf for TeX Live
  mt-bch.cfg    2007/03/03 v1.5 microtype config. file: Bitstream Charter (RS)
 nameref.sty    2021-04-02 v2.47 Cross-referencing by name of section
refcount.sty    2019/12/15 v3.6 Data extraction from label references (HO)
gettitlestring.sty    2019/12/15 v1.6 Cleanup title references (HO)
bookmark.sty    2020-11-06 v1.29 PDF bookmarks (HO)
bkm-pdftex.def    2020-11-06 v1.29 bookmark driver for pdfTeX (HO)
T1Roboto-LF.fd    2019/12/11 (autoinst) Font definitions for T1/Roboto-LF.
  mt-cmr.cfg    2013/05/19 v2.2 microtype config. file: Computer Modern Roman (RS)

The output also contains the following version information (I don't know which is the relevant one):

This is LuaHBTeX, Version 1.13.0 (TeX Live 2021) 
 restricted system commands enabled.
LaTeX2e <2020-10-01> patch level 4
 L3 programming layer <2021-05-07>

But if packaged versions are not supported anyway, I will just use Overleaf for the final compilation. :-)

TeXhackse commented 1 year ago

Yup, your version is just outdated. Guess you are on fedora. Issue mostly is that we cannot package the bundle for all the different distros out there. You can always install a vanilla TeX Live and resolve it that way, see https://tug.org/texlive/

Overleaf might also depend on which server you are using if you get the current version or an outdated one.

PeteS4 commented 1 year ago

I'm not a huge fan of sideloading software, but I just now tested compiling on the TU Darmstadt sharelatex installation and it works just fine. Thanks again for the fast weekend support! :-)

TeXhackse commented 1 year ago

You can always package it yourself to not having to do that. We just cannot afford maintaining all of them that's why I never made any and stick to the TeX ecosystem which is providing the mechanism via CTAN.