彻底删除 texlive

彻底删除 texlive

我升级到了 texlive 2017,但遇到了一些问题,因此想恢复到 2015 版本。我用它删除了它,sudo apt-get purge --auto-remove texlive*但似乎并没有删除所有内容。当我尝试时,sudo apt-get install texlive我收到以下错误:

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

    The following packages have unmet dependencies.
     libosgi-compendium-java : Depends: libgeronimo-jpa-2.0-spec-java but it is not going to be installed
     texlive : Depends: texlive-latex-recommended (>= 2015) but it is not going to be installed
               Depends: texlive-latex-base (>= 2015) but it is not going to be installed
               Depends: texlive-fonts-recommended (>= 2015) but it is not going to be installed
    E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.

然后我尝试按照这个帖子但在这种情况下它没有帮助。有什么想法吗?

提前致谢!

答案1

尝试删除完整包 (texlive-full)。可能有一些依赖项残留。祝你好运。

  sudo apt-get purge --autoremove texlive-full

这可能有助于修复损坏的软件包:

sudo apt-get install -f
sudo apt-get update
sudo apt-get upgrade
sudo dpkg --configure -a 

如果上述方法不起作用,请考虑以下事项:

sudo apt-get purge texlive*
sudo rm -rf /usr/local/texlive/* and rm -rf ~/.texlive*
sudo rm -rf /usr/local/share/texmf
sudo rm -rf /var/lib/texmf
sudo rm -rf /etc/texmf
sudo apt-get remove tex-common --purge
rm -rf ~/.texlive

find -L /usr/local/bin/ -lname /usr/local/texlive/*/bin/* | xargs rm

相关内容