TUM-LIS / tum-dissertation-latex

Latex template for a TUM dissertation/PhD thesis
Creative Commons Attribution 4.0 International
95 stars 48 forks source link

Incompatibility with TeX Live >= 2023 / xcolor #28

Open FG-TUM opened 3 weeks ago

FG-TUM commented 3 weeks ago

Problem Description

On distributions with TeX Live >= 2023 building locally make pdf-local fails. This is an issue if one wants to use new-ish LaTeX packages.

Error Message

$ make pdf-local
# some output omitted ...
(./inc/tumcolor.sty
(/usr/share/texlive/texmf-dist/tex/latex/xcolor/xcolor.sty
(/usr/share/texlive/texmf-dist/tex/latex/graphics-cfg/color.cfg)

! LaTeX Error: Unknown option 'pgfplots' for package xcolor.

For immediate help type H <return>.
 ...

l.266 \edef
           \Gin@driver{\Gin@driver}
? H

LaTeX has been asked to set an option called 'pgfplots' but the package
"xcolor" has not created an option with this name.

It appears something in the xcolor package has changed so it doesn't accept the pdfplots option anymore? However, I don't see anything about that specifically in their changelog so I'm not sure if this was ever a valid option?

Affected Distributions

Workaround

The offending lines are here: https://github.com/TUM-LIS/tum-dissertation-latex/blob/9b425cf543aebb1c1eaf14f9c08ac765cf719c86/inc/tumcolor.sty#L26-L30

My knowledge about sty files is very limited. Both of the following workarounds seem to work but I guess they have undesired side effects:

So please someone who understands this better stand up and provide a good solution :)