latex is driving me batty -- ! Package fontspec Error: The font "DejaVu Sans" cannot be found.

Steven Smith steve.t.smith at gmail.com
Fri Sep 13 13:12:40 UTC 2019


Here’s the ports I have on a working system that provide the DejaVu fonts:

> locate DejaVuSansMono.ttf | egrep -e '^/opt/local' | xargs port provides | sed -E -e 's/^[^:]+:[[:space:]]//' | uniq
> py37-matplotlib
> dejavu-fonts
> texlive-fonts-extra

The port texlive-fonts-extra should install this file, and everything should work:

/opt/local/share/texmf-texlive/fonts/truetype/public/dejavu/DejaVuSansMono.ttf

The other two ports should be irrelevant.

The reinplace lines in the Portfile (below) should have removed all the spaces from this font name in the LaTeX file and added a “.ttf” to the find specification.

Did this happen? It doesn’t look like it from your LaTeX logs. Why isn’t there a .ttf? Which files are those? What happens if you go to ${worksrcpath}, edit the offending .tex file, and compile it by hand?


> This issue is supposed to be fixed in these lines:
> https://github.com/macports/macports-ports/blob/2c234633658e98876b28b4cdf07852a2eff07b86/lang/ghc/Portfile#L183-L194





More information about the macports-users mailing list