ghostscript:mactex 与 homebrew 冲突

ghostscript:mactex 与 homebrew 冲突

我正在使用 auctex,但在 emacs 中预览公式对我来说不起作用。问题似乎与 ghostscript 有关。我尝试使用 brew 重新安装 ghostscript,但出现以下错误。

brew reinstall ghostscript
==> Reinstalling ghostscript 
==> Downloading https://homebrew.bintray.com/bottles/ghostscript-9.52.mojave.bottle.tar.gz
Already downloaded: /Users/user/Library/Caches/Homebrew/downloads/91f3c9535bda739dd9663190e036d7661f4e27463b96ea05c9b5db5a98ca9abe--ghostscript-9.52.mojave.bottle.tar.gz
==> Pouring ghostscript-9.52.mojave.bottle.tar.gz
Error: The `brew link` step did not complete successfully
The formula built, but is not symlinked into /usr/local
Could not symlink bin/dvipdf
Target /usr/local/bin/dvipdf
already exists. You may want to remove it:
  rm '/usr/local/bin/dvipdf'

To force the link and overwrite all conflicting files:
  brew link --overwrite ghostscript

To list all files that would be deleted:
  brew link --overwrite --dry-run ghostscript

Possible conflicting files are:
/usr/local/bin/dvipdf
/usr/local/bin/eps2eps
/usr/local/bin/gsbj
/usr/local/bin/gsdj
/usr/local/bin/gsdj500
/usr/local/bin/gslj
/usr/local/bin/gslp
/usr/local/bin/gsnd
/usr/local/bin/lprsetup.sh
/usr/local/bin/pdf2dsc
/usr/local/bin/pdf2ps
/usr/local/bin/pf2afm
/usr/local/bin/pfbtopfa
/usr/local/bin/pphs
/usr/local/bin/printafm
/usr/local/bin/ps2ascii
/usr/local/bin/ps2epsi
/usr/local/bin/ps2pdf
/usr/local/bin/ps2pdf12
/usr/local/bin/ps2pdf13
/usr/local/bin/ps2pdf14
/usr/local/bin/ps2pdfwr
/usr/local/bin/ps2ps
/usr/local/bin/ps2ps2
/usr/local/bin/unix-lpr.sh
/usr/local/share/man/man1/dvipdf.1
/usr/local/share/man/man1/eps2eps.1 -> /usr/local/share/man/man1/ps2ps.1
/usr/local/share/man/man1/gs.1
/usr/local/share/man/man1/gsbj.1 -> /usr/local/share/man/man1/gslp.1
/usr/local/share/man/man1/gsdj.1 -> /usr/local/share/man/man1/gslp.1
/usr/local/share/man/man1/gsdj500.1 -> /usr/local/share/man/man1/gslp.1
/usr/local/share/man/man1/gslj.1 -> /usr/local/share/man/man1/gslp.1
/usr/local/share/man/man1/gslp.1
/usr/local/share/man/man1/gsnd.1
/usr/local/share/man/man1/pdf2dsc.1
/usr/local/share/man/man1/pdf2ps.1
/usr/local/share/man/man1/pf2afm.1
/usr/local/share/man/man1/pfbtopfa.1
/usr/local/share/man/man1/printafm.1
/usr/local/share/man/man1/ps2ascii.1
/usr/local/share/man/man1/ps2epsi.1
/usr/local/share/man/man1/ps2pdf.1
/usr/local/share/man/man1/ps2pdf12.1 -> /usr/local/share/man/man1/ps2pdf.1
/usr/local/share/man/man1/ps2pdf13.1 -> /usr/local/share/man/man1/ps2pdf.1
/usr/local/share/man/man1/ps2pdf14.1 -> /usr/local/share/man/man1/ps2pdf.1
/usr/local/share/man/man1/ps2pdfwr.1
/usr/local/share/man/man1/ps2ps.1
==> Summary

答案1

我使用 brew doctor 并获取所有损坏的符号链接的列表。
在此列表中,您将找到 /usr/local/share/ghostscript/9.10/Resource/Font/logo10.pfb 和其他一些类似的。
然后使用sudo rm '/usr/local/share/ghostscript/9.10/Resource/Font/logo10.pfb'它将其删除。
也许同一目录中有多个,因此您可以使用sudo rm -r '/usr/local/share/ghostscript/9.10/Resource/Font'
也许这会有所帮助。

相关内容