0

I'm embarassed by this but but it all resulted from me putting my Ubuntu OS into a coma. I got a new PC with Windows 10 and Ubuntu (linux) installed as dual operating systems. I rarely use Windows but I installed TeXLive 2021 from the DVD into the Ubuntu side of things. Running pdflatex on sample2e.tex (one of the example files) worked fine, but when I tried to process anything but the example files (e.g. same class but with with packages or a different class) all failed because the package/class files could not be found although they are on my computer in `/usr/local/texlive/2021/texmf-dist/tex/latex'

How do I get pdflatex and friends to find these extra class/package files? I have tried setting environment variables like TEXMFLOCAL to the above directory but they are still not found.

9
  • 1
    if sample2e.tex works it must load files. So check the log-file where it looks for things. Dec 20, 2021 at 19:07
  • Or try with kpsewhich article.cls.
    – Skillmon
    Dec 20, 2021 at 19:41
  • @Skillmon I did kpsewhich article.cls and it returned \usr/share\texlive\texmf-dist\tex\latex\base\article.cls. I also did kpsewhich memoir.cls which returned nothing. Dec 20, 2021 at 20:02
  • 1
    you have not put the texlive you installed in your path, your comment shows that kpsewhich (and presumably pdftex) are the system tex using files in /usr/share/texlive not the one you installed in .usr/local/texlive/2021. Edit your .profile to add /usr/local/texlive/2021/texmf-dist/bin/whatever to the front of your PATH Dec 20, 2021 at 20:33
  • 1
    see Post Install at tug.org/texlive/quickinstall.html Dec 20, 2021 at 20:35

1 Answer 1

1

you have not put the texlive you installed in your path, your comment shows that kpsewhich (and presumably pdftex) are the system tex using files in

/usr/share/texlive 

not the one you installed in

/usr/local/texlive/2021

Edit your .profile to add

/usr/local/texlive/2021/texmf-dist/bin/x86_64-linux

to the front of your PATH, eg a line such as

export PATH=/usr/local/texlive/2021/bin/x86_64-linux:$PATH

(You will need to log in again to see the effect of a an edit to .profile)

see Post Install at https://tug.org/texlive/quickinstall.html

1
  • Thank you for pointing me at .profile. It's been over ten years since I had to tweak it and it had faded from my memory (as have many other things). Dec 24, 2021 at 18:14

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .