[Tex/LaTex] Kile can’t locate texmf-dist packages

installingkiletexliveUbuntu

I was using the default Ubuntu texlive package (plus extras) but it has really outdated versions, and I had to manually download newer versions, texhash, search dependencies, etc.

I'm now using TexLive 2013 to handle packages, but my system is in a sorry state, with packages both in /usr/share/texmf-texlive/ (from my previous install) and /usr/local/texlive/2013/texmf-dist (from my current install). Is there a safe way to clean it? I've already removed the apt texlive package, but these files are still there.

More simply, is there a way to point Kile to the new package location? I've already set the PATH variable to point to /usr/local/texlive/2013/bin/i386-linux. However, I can't find where to configure it to search in another place.

Best Answer

Solved it! Adding the following entry in ~/.bashrc, Kile was able to find the newly installed packages.

TEXMFDIST="/usr/local/texlive/2013/texmf-dist"
export TEXMFDIST

Note that you must restart the computer if you launch Kile from the graphic interface. It will work if you launch it from a fresh terminal, because it'll already have the new environment variable.