Replacing Debian LaTeX packages with vanilla TeX Live
Debian’s LaTeX packages are great. They’re easy to install and work well in the majority of cases. But they can be outdated. Some recent CTAN packages aren’t available in the Debian packages, especially if you’ve not upgraded your system in a while. By being careful, it’s possible to replace your Debian-installed LaTeX packages with a vanilla TeX Live installation. This post describes the steps involved in migrating to a bright, shiny, up-to-date LaTeX distribution.

Image credits: Debian Project, TeX Live
LaTeX rocks. It makes great-looking output and it’s compiled from source code, so it’s natural for a software developer like me to use. As a physicist, reaching for LaTeX is normal for me. After all, I’ve been using it to create various documents since the middle of the 90’s.
I’m also a Debian Linux user, so I usually use the LaTeX packages that come
with Debian. That is, until recently. I realised that there are packages
in the current TeX Live release (2025) that I want to use, but aren’t part
of my version of Debian. I’m still on bullseye. Yes, I need to upgrade.
Don’t @
me.
Anyway, like I was saying, I wanted to use packages from TeX Live but aren’t available on my system. I wanted to use two packages in particular. The first was zugferd, which creates PDF invoices compatible with the European digital invoice requirements. The second was moloch, a patched and improved beamer theme based on metropolis.
What to do? The hard answer: replace the Debian packages with TeX Live. What could go wrong? Ahem.
A word of warning: what I’m going to be doing here could break things on your system. Follow these instructions carefully and keep your brain switched on at all times. Also, back up your system, just in case.
So, what does the current situation look like? Asking the TeX Live manager
program (tlmgr
) what its current version is will tell us what we want to
know:
$ tlmgr --version
tlmgr revision 57424 (2021-01-15 03:30:58 +0100)
tlmgr using installation: /usr/share/texlive
TeX Live (https://tug.org/texlive) version 2020
Oh dear, that is rather long in the tooth. No wonder I can’t find anything that’s only recently appeared.
What path should we take? Well, there are several things to do, so let’s consider them and formulate a plan. We need to:
- Remove the old packages.
- Install TeX Live.
- Set up an equivs file to tell Debian which packages the local TeX Live installation takes care of so that Debian doesn’t have to.
- Wire up paths so that the TeX Live binaries are found in preference to the system-installed binaries.
YOLO?
What if we removed the old packages first? How much would break by doing that as the first step? To answer this question we can ask the question: What’s the “blast radius” of simply removing all LaTeX packages that are currently installed?
We can ask apt
which packages involve latex and are currently
installed:1
$ apt search latex | grep installed
WARNING: apt does not have a stable CLI interface. Use with caution in scripts.
docutils-common/oldstable,oldstable,now 0.16+dfsg-4 all [installed,automatic]
doxygen/oldstable,now 1.9.1-1 amd64 [installed]
dvisvgm/oldstable,now 2.11.1-1 amd64 [installed,automatic]
fig2dev/oldstable,now 1:3.2.8-3+deb11u1 amd64 [installed,automatic]
fonts-arphic-bkai00mp/oldstable,oldstable,now 2.10-21 all [installed,automatic]
fonts-arphic-bsmi00lp/oldstable,oldstable,now 2.10-18 all [installed,automatic]
fonts-arphic-gbsn00lp/oldstable,oldstable,now 2.11-16 all [installed,automatic]
fonts-arphic-gkai00mp/oldstable,oldstable,now 2.11-16 all [installed,automatic]
fonts-mathjax/oldstable,oldstable,now 2.7.9+dfsg-1 all [installed,automatic]
fonts-mathjax-extras/oldstable,oldstable,now 2.7.9+dfsg-1 all [installed,automatic]
fonts-texgyre/oldstable,oldstable,now 20180621-3.1 all [installed,automatic]
fonts-unfonts-core/oldstable,oldstable,now 1:1.0.2-080608-16 all [installed,automatic]
fonts-unfonts-extra/oldstable,oldstable,now 1:1.0.2-080608+dfsg-9 all [installed,automatic]
gedit-plugin-synctex/oldstable,now 3.38.1-1 amd64 [installed,automatic]
ispell/oldstable,now 3.4.02-2 amd64 [installed,automatic]
latex-cjk-all/oldstable,oldstable,now 4.8.4+git20170127-3 all [installed,automatic]
latex-cjk-chinese/oldstable,now 4.8.4+git20170127-3 amd64 [installed,automatic]
latex-cjk-chinese-arphic-bkai00mp/oldstable,oldstable,now 1.23+nmu1 all [installed,automatic]
latex-cjk-chinese-arphic-bsmi00lp/oldstable,oldstable,now 1.23+nmu1 all [installed,automatic]
latex-cjk-chinese-arphic-gbsn00lp/oldstable,oldstable,now 1.23+nmu1 all [installed,automatic]
latex-cjk-chinese-arphic-gkai00mp/oldstable,oldstable,now 1.23+nmu1 all [installed,automatic]
latex-cjk-common/oldstable,now 4.8.4+git20170127-3 amd64 [installed,automatic]
latex-cjk-japanese/oldstable,now 4.8.4+git20170127-3 amd64 [installed,automatic]
latex-cjk-japanese-wadalab/oldstable,oldstable,now 0.20050817-17.1 all [installed,automatic]
latex-cjk-korean/oldstable,oldstable,now 4.8.4+git20170127-3 all [installed,automatic]
latex-cjk-thai/oldstable,oldstable,now 4.8.4+git20170127-3 all [installed,automatic]
latexmk/oldstable,oldstable,now 1:4.70b-0.2 all [installed]
libgl2ps1.4/oldstable,now 1.4.2+dfsg1-1 amd64 [installed,automatic]
libgtksourceview-3.0-common/oldstable,oldstable,now 3.24.11-2 all [installed,automatic]
libgtksourceview-4-common/oldstable,oldstable,now 4.8.0-1 all [installed,automatic]
libjlatexmath-java/oldstable,oldstable,now 1.0.7-3 all [installed,automatic]
libjs-mathjax/oldstable,oldstable,now 2.7.9+dfsg-1 all [installed,automatic]
lilypond/oldstable,now 2.22.0-10 amd64 [installed,automatic]
pandoc/oldstable,now 2.9.2.1-1+deb11u1 amd64 [installed]
pandoc-data/oldstable,oldstable,now 2.9.2.1-1+deb11u1 all [installed,automatic]
plantuml/oldstable,oldstable,now 1:1.2020.2+ds-1 all [installed]
preview-latex-style/oldstable,oldstable,now 12.2-1 all [installed,automatic]
python3-docutils/oldstable,oldstable,now 0.16+dfsg-4 all [installed,automatic]
python3-jinja2/oldstable,oldstable,now 2.11.3-1 all [installed,automatic]
python3-pygments/oldstable,oldstable,now 2.7.1+dfsg-2.1 all [installed]
python3-sagetex/oldstable,oldstable,now 3.5+ds-2 all [installed,automatic]
python3-sphinx/oldstable,oldstable,now 3.4.3-2 all [installed,automatic]
ruby-kramdown/oldstable,oldstable,now 2.3.0-5 all [installed,automatic]
sagetex/oldstable,oldstable,now 3.5+ds-2 all [installed,automatic]
texlive-base/oldstable,oldstable,now 2020.20210202-3 all [installed,automatic]
texlive-binaries/oldstable,now 2020.20200327.54578-7+deb11u1 amd64 [installed,automatic]
texlive-extra-utils/oldstable,oldstable,now 2020.20210202-3 all [installed,automatic]
texlive-font-utils/oldstable,oldstable,now 2020.20210202-3 all [installed]
texlive-fonts-extra/oldstable,oldstable,now 2020.20210202-3 all [installed]
texlive-fonts-recommended/oldstable,oldstable,now 2020.20210202-3 all [installed]
texlive-lang-chinese/oldstable,oldstable,now 2020.20210202-2 all [installed,automatic]
texlive-lang-cjk/oldstable,oldstable,now 2020.20210202-2 all [installed,automatic]
texlive-lang-cyrillic/oldstable,oldstable,now 2020.20210202-2 all [installed]
texlive-lang-english/oldstable,oldstable,now 2020.20210202-2 all [installed]
texlive-lang-european/oldstable,oldstable,now 2020.20210202-2 all [installed]
texlive-lang-french/oldstable,oldstable,now 2020.20210202-2 all [installed]
texlive-lang-german/oldstable,oldstable,now 2020.20210202-2 all [installed]
texlive-lang-greek/oldstable,oldstable,now 2020.20210202-2 all [installed,automatic]
texlive-lang-italian/oldstable,oldstable,now 2020.20210202-2 all [installed]
texlive-lang-japanese/oldstable,oldstable,now 2020.20210202-2 all [installed]
texlive-lang-korean/oldstable,oldstable,now 2020.20210202-2 all [installed,automatic]
texlive-lang-other/oldstable,oldstable,now 2020.20210202-2 all [installed,automatic]
texlive-lang-polish/oldstable,oldstable,now 2020.20210202-2 all [installed]
texlive-lang-portuguese/oldstable,oldstable,now 2020.20210202-2 all [installed]
texlive-lang-spanish/oldstable,oldstable,now 2020.20210202-2 all [installed]
texlive-latex-base/oldstable,oldstable,now 2020.20210202-3 all [installed,automatic]
texlive-latex-base-doc/oldstable,oldstable,now 2020.20210202-3 all [installed]
texlive-latex-extra/oldstable,oldstable,now 2020.20210202-3 all [installed]
texlive-latex-extra-doc/oldstable,oldstable,now 2020.20210202-3 all [installed]
texlive-latex-recommended/oldstable,oldstable,now 2020.20210202-3 all [installed,automatic]
texlive-latex-recommended-doc/oldstable,oldstable,now 2020.20210202-3 all [installed]
texlive-luatex/oldstable,oldstable,now 2020.20210202-3 all [installed]
texlive-pictures/oldstable,oldstable,now 2020.20210202-3 all [installed,automatic]
texlive-plain-generic/oldstable,oldstable,now 2020.20210202-3 all [installed,automatic]
texlive-pstricks/oldstable,oldstable,now 2020.20210202-3 all [installed]
texlive-science/oldstable,oldstable,now 2020.20210202-3 all [installed]
texlive-xetex/oldstable,oldstable,now 2020.20210202-3 all [installed]
tipa/oldstable,oldstable,now 2:1.3-20.1 all [installed,automatic]
Hrm, that’s quite a lot. I’m beginning to think that removing things first isn’t the way to go.
If we make a dry run of purging the texlive-base
package, we’ll get more
info about the potential effects of removing packages ahead of time:
$ sudo apt purge --dry-run texlive-base
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages were automatically installed and are no longer required:
fonts-adf-accanthis fonts-adf-berenis fonts-adf-gillius fonts-adf-universalis fonts-arphic-bkai00mp
fonts-arphic-bsmi00lp fonts-arphic-gbsn00lp fonts-arphic-gkai00mp fonts-baekmuk fonts-cabin
fonts-comfortaa fonts-ebgaramond fonts-ebgaramond-extra fonts-gfs-artemisia fonts-gfs-baskerville
fonts-gfs-complutum fonts-gfs-didot fonts-gfs-neohellenic fonts-gfs-olga fonts-gfs-porson
fonts-gfs-solomos fonts-go fonts-junicode fonts-lobster fonts-lobstertwo fonts-oflb-asana-math
fonts-open-sans fonts-roboto-unhinted fonts-sil-charis fonts-sil-gentiumplus
fonts-sil-gentiumplus-compact fonts-sil-padauk fonts-tlwg-garuda fonts-tlwg-garuda-otf
fonts-tlwg-kinnari fonts-tlwg-kinnari-otf fonts-tlwg-laksaman fonts-tlwg-laksaman-otf
fonts-tlwg-loma fonts-tlwg-loma-otf fonts-tlwg-mono fonts-tlwg-mono-otf fonts-tlwg-norasi
fonts-tlwg-norasi-otf fonts-tlwg-purisa fonts-tlwg-purisa-otf fonts-tlwg-sawasdee
fonts-tlwg-sawasdee-otf fonts-tlwg-typewriter fonts-tlwg-typewriter-otf fonts-tlwg-typist
fonts-tlwg-typist-otf fonts-tlwg-typo fonts-tlwg-typo-otf fonts-tlwg-umpush fonts-tlwg-umpush-otf
fonts-tlwg-waree fonts-tlwg-waree-otf fonts-unfonts-core fonts-unfonts-extra
latex-cjk-chinese-arphic-bkai00mp latex-cjk-chinese-arphic-bsmi00lp
latex-cjk-chinese-arphic-gbsn00lp latex-cjk-chinese-arphic-gkai00mp latex-cjk-japanese-wadalab
libalgorithm-c3-perl libbit-vector-perl libcarp-clan-perl libclass-c3-perl libclass-c3-xs-perl
libclass-data-inheritable-perl libcrypt-rc4-perl libdata-optlist-perl libdate-calc-perl
libdate-calc-xs-perl libdevel-globaldestruction-perl libdigest-perl-md5-perl
libdist-checkconflicts-perl libemail-date-format-perl libeval-closure-perl libexception-class-perl
libfile-homedir-perl libfontbox-java libipc-shareable-perl libjcode-pm-perl liblog-dispatch-perl
liblog-log4perl-perl libmime-lite-perl libmime-types-perl libmro-compat-perl
libnamespace-autoclean-perl libole-storage-lite-perl libparams-util-perl
libparams-validationcompiler-perl libparse-recdescent-perl libpdfbox-java libspecio-perl
libspreadsheet-parseexcel-perl libspreadsheet-writeexcel-perl libsub-exporter-perl
libsub-install-perl libunicode-map-perl libxstring-perl libyaml-tiny-perl preview-latex-style ps2eps
python3-sagetex teckit texlive-fonts-extra-links
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
latex-cjk-all* latex-cjk-chinese* latex-cjk-common* latex-cjk-japanese* latex-cjk-korean*
latex-cjk-thai* latexmk* sagetex* texlive-base* texlive-extra-utils* texlive-font-utils*
texlive-fonts-extra* texlive-fonts-recommended* texlive-lang-chinese* texlive-lang-cjk*
texlive-lang-cyrillic* texlive-lang-english* texlive-lang-european* texlive-lang-french*
texlive-lang-german* texlive-lang-greek* texlive-lang-italian* texlive-lang-japanese*
texlive-lang-korean* texlive-lang-other* texlive-lang-polish* texlive-lang-portuguese*
texlive-lang-spanish* texlive-latex-base* texlive-latex-base-doc* texlive-latex-extra*
texlive-latex-extra-doc* texlive-latex-recommended* texlive-latex-recommended-doc* texlive-luatex*
texlive-pictures* texlive-plain-generic* texlive-pstricks* texlive-publishers-doc* texlive-science*
texlive-science-doc* texlive-xetex* tipa*
0 upgraded, 0 newly installed, 43 to remove and 4 not upgraded.
<snip>
... details of all purge actions
Yeah, that’s too much. I’ll leave removing things until afterwards. It was worth a look, though!
A more careful path
A better way to do this is to follow an already well-trodden path. The Debian TeX Live documentation describes a solid set of instructions to replace Debian packages with TeX Live in the “Integrating vanilla TeX Live with Debian” section. It also turns out that the path setting instructions need expanding upon as we’ll see later. Note that the path I’ve used here has a different order to that suggested by the Debian TeX Live documentation. This turned out to be the better ordering in my case.
The path that we now wish to take looks like this:
- Install TeX Live as root, system-wide.
- Build a dummy local TeX Live package to override LaTeX-related Debian packages handled by TeX Live.
- Remove any now-unnecessary LaTeX-related Debian packages.
-
Add TeX Live’s
bin/
directory to yourPATH
environment variable.
Install TeX Live system-wide
By default, TeX Live installs into /usr/local/texlive
, so it won’t
interact with any system-installed LaTeX binaries from Debian. Unless, of
course, you choose to install TeX Live into the system locations. That
would be
bad. In
fact, the TeX Live quick installation
docs mention this:
You do not need to remove an installation of a previous release, or any system-provided TeX; multiple releases of TL can coexist on the same system without conflict.
This statement is very reassuring. It means that once we’re sure TeX Live is working properly, we can remove the unneeded Debian packages without much worry.
Let’s install TeX Live now.
First up, change into the /tmp
directory and download the TeX Live
installer:
$ cd /tmp/
$ wget https://mirror.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz
--2025-04-02 18:06:36-- https://mirror.ctan.org/systems/texlive/tlnet/install-tl-unx.tar.gz
Resolving mirror.ctan.org (mirror.ctan.org)... 2a03:4000:5e:d33::1, 89.58.7.101
Connecting to mirror.ctan.org (mirror.ctan.org)|2a03:4000:5e:d33::1|:443... connected.
HTTP request sent, awaiting response... 307 Temporary Redirect
Location: https://ctan.net/systems/texlive/tlnet/install-tl-unx.tar.gz [following]
--2025-04-02 18:06:36-- https://ctan.net/systems/texlive/tlnet/install-tl-unx.tar.gz
Resolving ctan.net (ctan.net)... 184.174.32.204
Connecting to ctan.net (ctan.net)|184.174.32.204|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 5752943 (5.5M) [application/x-gzip]
Saving to: ‘install-tl-unx.tar.gz’
install-tl-unx.tar.gz 100%[=====================================>] 5.49M 6.69MB/s in 0.8s
2025-04-02 18:06:37 (6.69 MB/s) - ‘install-tl-unx.tar.gz’ saved [5752943/5752943]
As soon as that arrives, unpack it:2
$ tar -xvzf install-tl-unx.tar.gz
In my case, this created a directory called install-tl-20250402/
. If you
follow these instructions in the future, the date in the directory name will
be different.
Change into the directory and install TeX Live via sudo
using the medium
scheme.3
$ cd install-tl-20250402/
$ sudo perl ./install-tl --scheme=medium
Loading https://ftp.agdsn.de/pub/mirrors/latex/dante/systems/texlive/tlnet/tlpkg/texlive.tlpdb
./install-tl: No medium, switching to scheme-minimal.
Installing TeX Live 2025 from: https://ftp.agdsn.de/pub/mirrors/latex/dante/systems/texlive/tlnet (verified)
Platform: x86_64-linux => 'GNU/Linux on x86_64'
Distribution: net (downloading)
Using URL: https://ftp.agdsn.de/pub/mirrors/latex/dante/systems/texlive/tlnet
Directory for temporary files: /tmp/DYmEM84ErP
======================> TeX Live installation procedure <=====================
======> Letters/digits in <angle brackets> indicate <=======
======> menu items for actions or customizations <=======
= help> https://tug.org/texlive/doc/install-tl.html <=======
Detected platform: GNU/Linux on x86_64
<B> set binary platforms: 1 out of 15
<S> set installation scheme: scheme-medium
<C> set installation collections:
22 collections out of 41, disk space required: 2287 MB (free: 82510 MB)
<D> set directories:
TEXDIR (the main TeX directory):
/usr/local/texlive/2025
TEXMFLOCAL (directory for site-wide local files):
/usr/local/texlive/texmf-local
TEXMFSYSVAR (directory for variable and automatically generated data):
/usr/local/texlive/2025/texmf-var
TEXMFSYSCONFIG (directory for local config):
/usr/local/texlive/2025/texmf-config
TEXMFVAR (personal directory for variable and automatically generated data):
~/.texlive2025/texmf-var
TEXMFCONFIG (personal directory for local config):
~/.texlive2025/texmf-config
TEXMFHOME (directory for user-specific files):
~/texmf
<O> options:
[ ] use letter size instead of A4 by default
[X] allow execution of restricted list of programs via \write18
[X] create all format files
[X] install macro/font doc tree
[X] install macro/font source tree
[ ] create symlinks to standard directories
<V> set up for portable installation
Actions:
<I> start installation to hard disk
<P> save installation profile to 'texlive.profile' and exit
<Q> quit
Enter command:
Running the install-tl
command interactively (the default) gives a nice
overview of the available options. One could change settings here if one
wants to, but we only want to install, so enter I
at the Enter command
prompt:
Enter command: I
Installing to: /usr/local/texlive/2025
Installing [1/4, time/total: ??:??/??:??]: hyphen-base [23k]
Installing [2/4, time/total: 00:01/01:38]: kpathsea [1042k]
Installing [3/4, time/total: 00:01/00:02]: texlive-scripts [551k]
Installing [4/4, time/total: 00:01/00:01]: texlive.infra [565k]
Time used for installing the packages: 00:02
Installing [0001/1474, time/total: ??:??/??:??]: 12many [376k]
Installing [0002/1474, time/total: 00:00/00:00]: a2ping [69k]
Installing [0003/1474, time/total: 00:00/00:00]: a2ping.x86_64-linux [1k]
Installing [0004/1474, time/total: 00:00/00:00]: abbr [4k]
<snip>
... lots more output
Equivalently, one could have installed everything non-interactively with the
--no-interaction
flag like so:
$ sudo perl ./install-tl --scheme=medium --no-interaction
Loading https://mirror.clientvps.com/CTAN/systems/texlive/tlnet/tlpkg/texlive.tlpdb
./install-tl: No medium, switching to scheme-minimal.
Installing TeX Live 2025 from: https://mirror.clientvps.com/CTAN/systems/texlive/tlnet (not verified)
Platform: x86_64-linux => 'GNU/Linux on x86_64'
Distribution: net (downloading)
Using URL: https://mirror.clientvps.com/CTAN/systems/texlive/tlnet
Directory for temporary files: /tmp/W_YDxGXhKg
Installing to: /usr/local/texlive/2025
Installing [1/4, time/total: ??:??/??:??]: hyphen-base [23k]
Installing [2/4, time/total: 00:01/01:38]: kpathsea [1042k]
Installing [3/4, time/total: 00:02/00:04]: texlive-scripts [551k]
Installing [4/4, time/total: 00:03/00:04]: texlive.infra [565k]
Time used for installing the packages: 00:04
Installing [0001/1474, time/total: ??:??/??:??]: 12many [376k]
Installing [0002/1474, time/total: 00:01/58:26]: a2ping [69k]
Installing [0003/1474, time/total: 00:02/01:38:46]: a2ping.x86_64-linux [1k]
<snip>
... lots more output
This will take a while so you might want to go for a walk, read something, get a drink, whatever.
On my test system, it took 13 minutes to install the packages and around 15
minutes in total. That’s not really that long; however using
--scheme=full
can take hours!
Test the vanilla TeX Live installation
Let’s see if our newly-installed TeX Live works as we hope by running a
little test. We prepend the path to the vanilla TeX Live binaries
(/usr/local/texlive/2025/bin/x86_64-linux
) to our PATH
environment
variable. This way we use TeX Live’s version of (say) pdflatex
instead of
the version in /usr/bin/
.
$ export PATH=/usr/local/texlive/2025/bin/x86_64-linux:$PATH
Now we need to check that we’ve got the right pdflatex
:
$ which pdflatex
/usr/local/texlive/2025/bin/x86_64-linux/pdflatex
Looking good!
The TeX Live installation
instructions mention building a
simple test document by running latex small2e
. This will produce a .dvi
file as output and I haven’t used one of those in decades. Instead, we can
perform the same test with pdflatex
:
$ pdflatex small2e
This is pdfTeX, Version 3.141592653-2.6-1.40.27 (TeX Live 2025) (preloaded format=pdflatex)
restricted \write18 enabled.
entering extended mode
(/usr/local/texlive/2025/texmf-dist/tex/latex/base/small2e.tex
LaTeX2e <2024-11-01> patch level 2
L3 programming layer <2025-01-18>
(/usr/local/texlive/2025/texmf-dist/tex/latex/base/article.cls
Document Class: article 2024/06/29 v1.4n Standard LaTeX document class
(/usr/local/texlive/2025/texmf-dist/tex/latex/base/size10.clo))
(/usr/local/texlive/2025/texmf-dist/tex/latex/l3backend/l3backend-pdftex.def)
No file small2e.aux.
(/usr/local/texlive/2025/texmf-dist/tex/latex/base/omscmr.fd)
[1{/usr/local/texlive/2025/texmf-var/fonts/map/pdftex/updmap/pdftex.map}{/usr/l
ocal/texlive/2025/texmf-dist/fonts/enc/dvips/cm-super/cm-super-ts1.enc}]
(./small2e.aux) )</usr/local/texlive/2025/texmf-dist/fonts/type1/public/amsfont
s/cm/cmbx10.pfb></usr/local/texlive/2025/texmf-dist/fonts/type1/public/amsfonts
/cm/cmbx12.pfb></usr/local/texlive/2025/texmf-dist/fonts/type1/public/amsfonts/
cm/cmr10.pfb></usr/local/texlive/2025/texmf-dist/fonts/type1/public/amsfonts/cm
/cmsy10.pfb></usr/local/texlive/2025/texmf-dist/fonts/type1/public/amsfonts/cm/
cmti10.pfb></usr/local/texlive/2025/texmf-dist/fonts/type1/public/cm-super/sfrm
1000.pfb>
Output written on small2e.pdf (1 page, 67359 bytes).
Transcript written on small2e.log.
That worked, which is nice. Also, we can see (in the first line of output) that we’re using TeX Live 2025. Great!
Viewing the output in evince
we see:
Brilliant! We’re now more confident that we can continue.
Build a dummy package with equivs
One could leave things as they are and prepend the TeX Live paths to the
PATH
environment variable. This way we use the TeX Live binaries in
preference to the system-installed ones. The TeX Live installation notes
also mention this option. However, leaving the system packages installed
could clash with the TeX Live installation in the future. Experience tells
me that doing so could cause confusion if not worse. Thus, we want to build
a dummy TeX Live Debian package to tell Debian which packages TeX Live now
handles. To create this dummy package of “equivalent packages”, we need to
install the equivs
Debian package, which manages this task for us:
$ sudo apt install equivs
To create our equivalent package, first make a temporary directory and change into it:
$ mkdir /tmp/tl-equivs && cd /tmp/tl-equivs
We now need to create a control
file, which is part of creating a Debian
package. There are a couple of ways to do this. One is to follow the
Debian instructions and create a stub control
file with equivs-control
:
$ equivs-control texlive-local
This will create a file called texlive-local
in the /tmp/tl-equivs
directory. You can edit it and replace its content with that of the equivs
file for the appropriate TeX Live version for your Debian version. In the
case I’m describing here, this is the equivs file for TeX Live
2020.
Make sure to change the Maintainer
field to use your name and email
address.
Or, we could simply download the equivs file directly with wget
:
$ wget -O texlive-local 'https://wiki.debian.org/TeXLive?action=AttachFile&do=get&target=debian-equivs-2020-ex.txt'
--2025-04-03 15:07:29-- https://wiki.debian.org/TeXLive?action=AttachFile&do=get&target=debian-equivs-2020-ex.txt
Resolving wiki.debian.org (wiki.debian.org)... 82.195.75.112, 2001:41b8:202:deb:6564:a62:52c3:4b70
Connecting to wiki.debian.org (wiki.debian.org)|82.195.75.112|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 2314 (2.3K) [text/plain]
Saving to: ‘texlive-local’
texlive-local 100%[=====================================>] 2.26K --.-KB/s in 0s
2025-04-03 15:07:29 (21.7 MB/s) - ‘texlive-local’ saved [2314/2314]
This creates the desired file with the appropriate equivs content.
You will still need to change the Maintainer
field in the texlive-local
control file to use your name and email address. E.g.:
Maintainer: Hans Wurst <hans.wurst@example.com>
Now we’re ready to build the dummy package with equivs-build
:
$ equivs-build texlive-local
dpkg-buildpackage: info: source package texlive-local
dpkg-buildpackage: info: source version 2020-1
dpkg-buildpackage: info: source distribution unstable
dpkg-buildpackage: info: source changed by Paul Cochrane <paul@peateasea.de>
dpkg-buildpackage: info: host architecture amd64
dpkg-source --before-build .
debian/rules clean
dh clean
dh_clean
debian/rules binary
dh binary
dh_update_autotools_config
dh_autoreconf
create-stamp debian/debhelper-build-stamp
dh_prep
dh_install
dh_installdocs
dh_installchangelogs
dh_perl
dh_link
dh_strip_nondeterminism
dh_compress
dh_fixperms
dh_missing
dh_installdeb
dh_gencontrol
dh_md5sums
dh_builddeb
dpkg-deb: building package 'texlive-local' in '../texlive-local_2020-1_all.deb'.
dpkg-genbuildinfo --build=binary
dpkg-genchanges --build=binary >../texlive-local_2020-1_amd64.changes
dpkg-genchanges: info: binary-only upload (no source code included)
dpkg-source --after-build .
dpkg-buildpackage: info: binary-only upload (no source included)
The package has been created.
Attention, the package has been created in the current directory,
not in ".." as indicated by the message above!
This will create a Debian package in the current directory called
texlive-local_2020-1_all.deb
:
$ tree
.
├── texlive-local
├── texlive-local_2020-1_all.deb
├── texlive-local_2020-1_amd64.buildinfo
└── texlive-local_2020-1_amd64.changes
0 directories, 4 files
Now install the Debian package we just built:4
$ sudo apt install ./texlive-local_2020-1_all.deb
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Note, selecting 'texlive-local' instead of './texlive-local_2020-1_all.deb'
The following packages were automatically installed and are no longer required:
libalgorithm-c3-perl libclass-c3-perl libclass-c3-xs-perl libclass-data-inheritable-perl
libdata-optlist-perl libdevel-globaldestruction-perl libdist-checkconflicts-perl
libemail-date-format-perl libeval-closure-perl libexception-class-perl libfile-homedir-perl
libipc-shareable-perl liblog-dispatch-perl liblog-log4perl-perl libmime-lite-perl libmime-types-perl
libmro-compat-perl libnamespace-autoclean-perl libparams-util-perl libparams-validationcompiler-perl
libspecio-perl libsub-exporter-perl libsub-install-perl libxstring-perl libyaml-tiny-perl
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
freeglut3
The following packages will be REMOVED:
texlive-extra-utils texlive-plain-generic texlive-pstricks
The following NEW packages will be installed:
freeglut3 texlive-local
0 upgraded, 2 newly installed, 3 to remove and 4 not upgraded.
Need to get 125 kB/128 kB of archives.
After this operation, 175 MB disk space will be freed.
Do you want to continue? [Y/n]
Get:1 /tmp/tl-equivs/texlive-local_2020-1_all.deb texlive-local all 2020-1 [3,376 B]
Get:2 http://ftp.de.debian.org/debian bullseye/main amd64 freeglut3 amd64 2.8.1-6 [125 kB]
Fetched 125 kB in 0s (631 kB/s)
(Reading database ... 906250 files and directories currently installed.)
Removing texlive-extra-utils (2020.20210202-3) ...
Removing texlive-pstricks (2020.20210202-3) ...
Removing texlive-plain-generic (2020.20210202-3) ...
Selecting previously unselected package freeglut3:amd64.
(Reading database ... 895167 files and directories currently installed.)
Preparing to unpack .../freeglut3_2.8.1-6_amd64.deb ...
Unpacking freeglut3:amd64 (2.8.1-6) ...
Selecting previously unselected package texlive-local.
Preparing to unpack .../texlive-local_2020-1_all.deb ...
Unpacking texlive-local (2020-1) ...
Setting up freeglut3:amd64 (2.8.1-6) ...
Setting up texlive-local (2020-1) ...
Processing triggers for man-db (2.9.4-2) ...
Processing triggers for tex-common (6.16) ...
Running mktexlsr. This may take some time... done.
Building format(s) --all.
This may take some time... done.
Processing triggers for libc-bin (2.31-13+deb11u11) ...
Scanning processes...
Scanning processor microcode...
Scanning linux images...
Running kernel seems to be up-to-date.
The processor microcode seems to be up-to-date.
No services need to be restarted.
No containers need to be restarted.
No user sessions are running outdated binaries.
In my case, the package freeglut3
was installed along with the
texlive-local
package, but I think that’s ok.
I hope that the Perl modules really aren’t needed anymore. Time will tell. I usually use perlbrew anyway, so I’m probably ok. YMMV.
Let’s clean up the extra packages now.
$ sudo apt autoremove
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages will be REMOVED:
libalgorithm-c3-perl libclass-c3-perl libclass-c3-xs-perl libclass-data-inheritable-perl
libdata-optlist-perl libdevel-globaldestruction-perl libdist-checkconflicts-perl
libemail-date-format-perl libeval-closure-perl libexception-class-perl libfile-homedir-perl
libipc-shareable-perl liblog-dispatch-perl liblog-log4perl-perl libmime-lite-perl libmime-types-perl
libmro-compat-perl libnamespace-autoclean-perl libparams-util-perl libparams-validationcompiler-perl
libspecio-perl libsub-exporter-perl libsub-install-perl libxstring-perl libyaml-tiny-perl
0 upgraded, 0 newly installed, 25 to remove and 4 not upgraded.
After this operation, 3,023 kB disk space will be freed.
Do you want to continue? [Y/n]
(Reading database ... 895177 files and directories currently installed.)
Removing liblog-dispatch-perl (2.70-1) ...
Removing libspecio-perl (0.47-1) ...
Removing libmro-compat-perl (0.13-1) ...
Removing libclass-c3-perl (0.35-1) ...
Removing libalgorithm-c3-perl (0.11-1) ...
Removing libclass-c3-xs-perl (0.15-1+b1) ...
Removing libparams-validationcompiler-perl (0.30-1) ...
Removing libexception-class-perl (1.44-1) ...
Removing libclass-data-inheritable-perl (0.08-3) ...
Removing libeval-closure-perl (0.14-1) ...
Removing libsub-exporter-perl (0.987-1) ...
Removing libdata-optlist-perl (0.110-1.1) ...
Removing libdevel-globaldestruction-perl (0.14-1.1) ...
Removing libdist-checkconflicts-perl (0.11-1.1) ...
Removing libmime-lite-perl (3.031-1) ...
Removing libemail-date-format-perl (1.005-1.1) ...
Removing libfile-homedir-perl (1.006-1) ...
Removing libipc-shareable-perl (0.61-2) ...
Removing liblog-log4perl-perl (1.54-1) ...
Removing libmime-types-perl (2.18-1) ...
Removing libnamespace-autoclean-perl (0.29-1) ...
Removing libparams-util-perl (1.102-1+b1) ...
Removing libsub-install-perl (0.928-1.1) ...
Removing libxstring-perl (0.005-1+b1) ...
Removing libyaml-tiny-perl (1.73-1) ...
Processing triggers for man-db (2.9.4-2) ...
Nice! We’re ready to start removing Debian packages that have now become redundant.
Removing now-unnecessary Debian packages
What does it look like if we were to remove texlive-base
now?
$ sudo apt purge --dry-run texlive-base
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages were automatically installed and are no longer required:
fonts-adf-accanthis fonts-adf-berenis fonts-adf-gillius fonts-adf-universalis fonts-arphic-bkai00mp
fonts-arphic-bsmi00lp fonts-arphic-gbsn00lp fonts-arphic-gkai00mp fonts-baekmuk fonts-cabin
fonts-comfortaa fonts-ebgaramond fonts-ebgaramond-extra fonts-gfs-artemisia fonts-gfs-baskerville
fonts-gfs-complutum fonts-gfs-didot fonts-gfs-neohellenic fonts-gfs-olga fonts-gfs-porson
fonts-gfs-solomos fonts-go fonts-junicode fonts-lobster fonts-lobstertwo fonts-oflb-asana-math
fonts-open-sans fonts-roboto-unhinted fonts-sil-charis fonts-sil-gentiumplus
fonts-sil-gentiumplus-compact fonts-sil-padauk fonts-tlwg-garuda fonts-tlwg-garuda-otf
fonts-tlwg-kinnari fonts-tlwg-kinnari-otf fonts-tlwg-laksaman fonts-tlwg-laksaman-otf
fonts-tlwg-loma fonts-tlwg-loma-otf fonts-tlwg-mono fonts-tlwg-mono-otf fonts-tlwg-norasi
fonts-tlwg-norasi-otf fonts-tlwg-purisa fonts-tlwg-purisa-otf fonts-tlwg-sawasdee
fonts-tlwg-sawasdee-otf fonts-tlwg-typewriter fonts-tlwg-typewriter-otf fonts-tlwg-typist
fonts-tlwg-typist-otf fonts-tlwg-typo fonts-tlwg-typo-otf fonts-tlwg-umpush fonts-tlwg-umpush-otf
fonts-tlwg-waree fonts-tlwg-waree-otf fonts-unfonts-core fonts-unfonts-extra
latex-cjk-chinese-arphic-bkai00mp latex-cjk-chinese-arphic-bsmi00lp
latex-cjk-chinese-arphic-gbsn00lp latex-cjk-chinese-arphic-gkai00mp latex-cjk-japanese-wadalab
libbit-vector-perl libcarp-clan-perl libcrypt-rc4-perl libdate-calc-perl libdate-calc-xs-perl
libdigest-perl-md5-perl libfontbox-java libjcode-pm-perl libole-storage-lite-perl
libparse-recdescent-perl libpdfbox-java libspreadsheet-parseexcel-perl
libspreadsheet-writeexcel-perl libunicode-map-perl preview-latex-style ps2eps teckit
texlive-fonts-extra-links tipa
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
latex-cjk-all* latex-cjk-chinese* latex-cjk-common* latex-cjk-japanese* latex-cjk-korean*
latex-cjk-thai* texlive-base* texlive-font-utils* texlive-fonts-extra* texlive-fonts-recommended*
texlive-lang-chinese* texlive-lang-cjk* texlive-lang-cyrillic* texlive-lang-english*
texlive-lang-european* texlive-lang-french* texlive-lang-german* texlive-lang-greek*
texlive-lang-italian* texlive-lang-japanese* texlive-lang-korean* texlive-lang-other*
texlive-lang-polish* texlive-lang-portuguese* texlive-lang-spanish* texlive-latex-base*
texlive-latex-base-doc* texlive-latex-extra* texlive-latex-extra-doc* texlive-latex-recommended*
texlive-latex-recommended-doc* texlive-luatex* texlive-pictures* texlive-publishers-doc*
texlive-science* texlive-science-doc* texlive-xetex*
0 upgraded, 0 newly installed, 37 to remove and 4 not upgraded.
<snip>
... lots of purge detail
There are fewer packages listed now and that makes this step seem more
manageable. For instance, we see that several fonts will be removed. I
don’t think I need them. Several more Perl libraries will also be removed,
and I think I can do without them. The remaining packages also look like
they can go. Let’s purge texlive-base
now and then autoremove the
packages that are no longer necessary after purging.
$ sudo apt purge texlive-base
<snip>
$ sudo apt autoremove
<snip>
I’ve spared you the detailed output, so you’ll have to believe me that everything looked ok. Some of the fonts couldn’t be removed because the directory wasn’t empty. Oh well. I don’t think that’s a huge problem.
Is there anything that didn’t get cleaned up by this package purging?
$ apt search texlive | grep installed
WARNING: apt does not have a stable CLI interface. Use with caution in scripts.
pandoc/oldstable,now 2.9.2.1-1+deb11u1 amd64 [installed]
texlive-binaries/oldstable,now 2020.20200327.54578-7+deb11u1 amd64 [installed,automatic]
texlive-local/now 2020-1 all [installed,local]
Not much! We don’t need texlive-binaries
anymore as it’s part of the
texlive-local
dummy equivs
package. We want to keep pandoc
though, so
we’ll leave it where it is.
Purging the binaries package…
$ sudo apt purge texlive-binaries
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages were automatically installed and are no longer required:
dvisvgm libptexenc1 libteckit0 libtexlua53 libtexluajit2 libzzip-0-13 t1utils
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
dvipng* texlive-binaries*
0 upgraded, 0 newly installed, 2 to remove and 4 not upgraded.
After this operation, 50.4 MB disk space will be freed.
Do you want to continue? [Y/n]
(Reading database ... 724284 files and directories currently installed.)
Removing dvipng (1.15-1.1+b1) ...
Removing texlive-binaries (2020.20200327.54578-7+deb11u1) ...
Processing triggers for man-db (2.9.4-2) ...
Looking good. The packages to autoremove we don’t need anymore as TeX Live should handle them for us now, so let’s get rid of them:
$ sudo apt autoremove
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages will be REMOVED:
dvisvgm libptexenc1 libteckit0 libtexlua53 libtexluajit2 libzzip-0-13 t1utils
0 upgraded, 0 newly installed, 7 to remove and 4 not upgraded.
After this operation, 8,521 kB disk space will be freed.
Do you want to continue? [Y/n]
(Reading database ... 723991 files and directories currently installed.)
Removing dvisvgm (2.11.1-1) ...
Removing libptexenc1:amd64 (2020.20200327.54578-7+deb11u1) ...
Removing libteckit0:amd64 (2.5.10+ds1-3) ...
Removing libtexlua53:amd64 (2020.20200327.54578-7+deb11u1) ...
Removing libtexluajit2:amd64 (2020.20200327.54578-7+deb11u1) ...
Removing libzzip-0-13:amd64 (0.13.62-3.3+deb11u1) ...
Removing t1utils (1.41-4) ...
Processing triggers for man-db (2.9.4-2) ...
Processing triggers for libc-bin (2.31-13+deb11u11) ...
Instead of focusing only on TeX Live packages, what about checking more generally for LaTeX packages?
$ apt search latex | grep installed
WARNING: apt does not have a stable CLI interface. Use with caution in scripts.
docutils-common/oldstable,oldstable,now 0.16+dfsg-4 all [installed,automatic]
doxygen/oldstable,now 1.9.1-1 amd64 [installed]
fig2dev/oldstable,now 1:3.2.8-3+deb11u1 amd64 [installed,automatic]
fonts-mathjax/oldstable,oldstable,now 2.7.9+dfsg-1 all [installed,automatic]
fonts-mathjax-extras/oldstable,oldstable,now 2.7.9+dfsg-1 all [installed,automatic]
fonts-texgyre/oldstable,oldstable,now 20180621-3.1 all [installed,automatic]
gedit-plugin-synctex/oldstable,now 3.38.1-1 amd64 [installed,automatic]
ispell/oldstable,now 3.4.02-2 amd64 [installed,automatic]
latexmk/oldstable,oldstable,now 1:4.70b-0.2 all [installed]
libgl2ps1.4/oldstable,now 1.4.2+dfsg1-1 amd64 [installed,automatic]
libgtksourceview-3.0-common/oldstable,oldstable,now 3.24.11-2 all [installed,automatic]
libgtksourceview-4-common/oldstable,oldstable,now 4.8.0-1 all [installed,automatic]
libjlatexmath-java/oldstable,oldstable,now 1.0.7-3 all [installed,automatic]
libjs-mathjax/oldstable,oldstable,now 2.7.9+dfsg-1 all [installed,automatic]
lilypond/oldstable,now 2.22.0-10 amd64 [installed,automatic]
pandoc/oldstable,now 2.9.2.1-1+deb11u1 amd64 [installed]
pandoc-data/oldstable,oldstable,now 2.9.2.1-1+deb11u1 all [installed,automatic]
plantuml/oldstable,oldstable,now 1:1.2020.2+ds-1 all [installed]
python3-docutils/oldstable,oldstable,now 0.16+dfsg-4 all [installed,automatic]
python3-jinja2/oldstable,oldstable,now 2.11.3-1 all [installed,automatic]
python3-pygments/oldstable,oldstable,now 2.7.1+dfsg-2.1 all [installed]
python3-sagetex/oldstable,oldstable,now 3.5+ds-2 all [installed,automatic]
python3-sphinx/oldstable,oldstable,now 3.4.3-2 all [installed,automatic]
ruby-kramdown/oldstable,oldstable,now 2.3.0-5 all [installed,automatic]
sagetex/oldstable,oldstable,now 3.5+ds-2 all [installed,automatic]
There’s only one package we need to deal with here: latexmk
. It’s in the
package list of our equivs file, so it’s safe to remove:
$ sudo apt purge latexmk
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
The following packages will be REMOVED:
latexmk*
0 upgraded, 0 newly installed, 1 to remove and 4 not upgraded.
After this operation, 810 kB disk space will be freed.
Do you want to continue? [Y/n]
(Reading database ... 723919 files and directories currently installed.)
Removing latexmk (1:4.70b-0.2) ...
Processing triggers for man-db (2.9.4-2) ...
(Reading database ... 723885 files and directories currently installed.)
Purging configuration files for latexmk (1:4.70b-0.2) ...
We’re almost done!
Add TeX Live bin/
directory to the PATH
The last thing we need to do is to prepend the TeX Live bin/
directory
path (/usr/local/texlive/2025/bin/x86_64-linux/
) to our PATH
environment
variable. That way this path is available to us in each new shell as well
as when we run sudo
.
The Debian TeX Live documentation
recommends adding the TeX Live bin/
directory to the ENV_PATH
setting in
/etc/login.defs
. For instance, to do this, we’d edit the file
$ sudo vim /etc/login.defs
and change this line:
ENV_PATH PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
to
ENV_PATH PATH=/usr/local/texlive/2025/bin/x86_64-linux/:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
then one would need to log out of the X-Windows session or reboot for this setting to be effective in any new shell sessions.
Unfortunately, this doesn’t work.
The problem is that ENV_PATH
gets completely overridden by the setting in
/etc/profile
. For instance, on my system, the first few lines of
/etc/profile
are:
$ head /etc/profile
# /etc/profile: system-wide .profile file for the Bourne shell (sh(1))
# and Bourne compatible shells (bash(1), ksh(1), ash(1), ...).
if [ "$(id -u)" -eq 0 ]; then
PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
else
PATH="/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games"
fi
export PATH
This rewrites the PATH
completely! And it overwrites the PATH
for both
root
and normal users.
To really set things, we need to edit /etc/profile
and prepend
/usr/local/texlive/2025/bin/x86_64-linux/
to both PATH
assignments.
I.e. your /etc/profile
should look like this:
$ head /etc/profile
# /etc/profile: system-wide .profile file for the Bourne shell (sh(1))
# and Bourne compatible shells (bash(1), ksh(1), ash(1), ...).
if [ "$(id -u)" -eq 0 ]; then
PATH="/usr/local/texlive/2025/bin/x86_64-linux:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
else
PATH="/usr/local/texlive/2025/bin/x86_64-linux:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games"
fi
export PATH
There’s still one more problem: to install new TeX Live packages, we need to
run tlmgr
via sudo
. It turns out that sudo
also defines its own
PATH
and that differs from what’s defined in /etc/login.defs
and
/etc/profile
. To fix this problem, we have to prepend
/usr/local/texlive/2025/bin/x86_64-linux
to the secure_path
setting in our
sudoers
file. In other words:
$ sudo visudo
<various-sudo-settings>
Defaults secure_path="/usr/local/texlive/2025/bin/x86_64-linux:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
<more-sudo-settings>
Now TeX Live commands will be available when running them under sudo
.
Phew! Hopefully, that’s all!
You can test that the change to /etc/profile
worked by starting bash
as a
login shell:
$ bash -l
<bash-login-shell>$ which pdflatex
/usr/local/texlive/2025/bin/x86_64-linux/pdflatex
<bash-login-shell>$ Ctrl-D
$
Ok, that looks good. You should also find that sudo
also finds tlmgr
correctly, e.g.:
$ sudo which tlmgr
/usr/local/texlive/2025/bin/x86_64-linux/tlmgr
Done! We’ve replaced Debian’s LaTeX packages with a vanilla TeX Live installation. Cool!
Installing new packages
Now to get back to what I wanted to do in the beginning: use packages such
as zugferd
. I can now install it with tlmgr
:
$ sudo tlmgr install zugferd
tlmgr: package repository https://ftp.agdsn.de/pub/mirrors/latex/dante/systems/texlive/tlnet (verified)
[1/1, ??:??/??:??] install: zugferd [423k]
running mktexlsr ...
done running mktexlsr.
tlmgr: package log updated: /usr/local/texlive/2025/texmf-var/web2c/tlmgr.log
tlmgr: command log updated: /usr/local/texlive/2025/texmf-var/web2c/tlmgr-commands.log
That’s awesome! I can get back to what I was doing before. Hrm, now what was that exactly?
Wrapping up
In this post, I’ve described why one might want to replace Debian’s LaTeX- and TeX Live-related packages with vanilla TeX Live ones and the detailed steps of how to do that. If you’re faced with the same situation, hopefully, you now have the information you need to make this change on your system with confidence. Good luck!
-
I think I could have used
apt-cache
for this task (or possiblydpkg
in some form), however this command worked well for my purposes. ↩ -
The TeX Live installation docs recommend using
zcat
piped intotar
:zcat < install-tl-unx.tar.gz | tar xf - # note final - on that command line
I’m not sure why one would want to jump through such hoops. Perhaps it’s necessary so that the command works on all Unix systems. Dunno. I’ve used systems where
tar
didn’t interact withgzip
directly, so I can understand why one might want to use such an invocation. Still, that was over 15 years ago, so I’m not sure how current the documented instructions are. Either way, Debian’star
can unzipgzip
-ed files for us, so the more compacttar
command I use is the way to go. ↩ -
We use the
medium
scheme because otherwise, the installer uses thefull
scheme. Doing so installs all packages (and I mean all) which takes a very long time. Also, we don’t need most of the packages anyway, so they only sit around taking up disk space. Thus, it’s better to install themedium
scheme and install anything that’s missing as we need to. ↩ -
I chose to use
apt
here for the installation. Equivalently, you could usedpkg
:sudo dpkg -i texlive-local_2020-1_all.deb
Support
If you liked this post and want to see more, please buy me a coffee!
