[tex-live] 3.4.4 System font configuration for XeTEX and LuaTEX

jfbu jfbu at free.fr
Sat Jun 18 09:31:04 CEST 2016


Hi all,

with luaotfload 2.7-fix-3 now on CTAN, the symlinks are automatically filtered out from the database

Hence doing on mac os x 

ln -s /Library/TeX/Root/texmf-dist/fonts/opentype ~/Library/Fonts/TeXOpenType

ln -s /Library/TeX/Root/texmf-dist/fonts/truetype ~/Library/Fonts/TeXTrueType

to make all opentype/truetype fonts inside the texlive/mactex
tree visible to XeTeX hasn't anymore an impact on increased font
database for LuaTeX

Jean-François

Le 16 mai 2016 à 01:24, Zdenek Wagner <zdenek.wagner at gmail.com> a écrit :

> Hi,
> 
> this is good to know. A friend of mine just copied all the font files which I do not consider good. Imagine that one year later you will have to remove TL fonts and install the new versions. Copying all files can then turn into a nightmare. This is why I sggested to try to symlink the directory tree. It is good news that it works.
> 
> I have not only the TL fonts but also a huge collection of commercial fonts. Yes, when I want to see the font list in any Linux application, it takes some time but I do not need it frequently. I prefer having the fonts available.
> 
> 
> Zdeněk Wagner
> http://ttsm.icpf.cas.cz/team/wagner.shtml
> http://icebearsoft.euweb.cz
> 
> 2016-05-15 16:38 GMT+02:00 jfbu <jfbu at free.fr>:
> Hi
> 
> 
> Le 14 mai 2016 à 09:37, Zdenek Wagner <zdenek.wagner at gmail.com> a
> écrit :
> 
> >> 2016-05-14 0:49 GMT+02:00 Karl Berry <karl at freefriends.org>:
> >>     because in recent years I don't think that was the case.
> >>
> >> I suppose you're right. I'll have to ask about what can be
> >> sensibly said instead. Thanks.
> >>
> >>     Else one must use filenames, or fontspec with ExternalLocation
> >>
> >> Well, that's preferable anyway :). --karl
> > As I remember, someone has already mentioned that the font
> > instructions for Mac OSX are wrong.
> 
> I think that was me, a few weeks ago ;-) and perhaps also
> last year ;-)
> 
> Then the formulation changed but the new formulation says that
> things are automatically set-up for XeTeX on mac os x, which is
> wrong.
> 
> 
> > I do not have Mac so I cannot try whether it is really necessary
> > to copy the fonts, maybe the symlink would be sufficient. And I do
> > not know whether the font files must be symlinked, maybe just the
> > parent directory may be symlinked. I do not know whether Mac can
> > look for fonts into subdirectories.
> >
> 
> 1. I had not tried earlier the symlink approach because the Mac
> comes with FontBook app which has a concept of "Font Library"
> which one can add to it without having to copy or symlink the
> fonts. Also I feared that perhaps I would have to symlink
> individually files or many repertories.
> 
> The "Font Library" method initially seemed to work but I soon
> realized it was a nightmare, because FontBook.app is seriously
> broken (at least on Mavericks, but Herb indicates he also has had
> bad experiences).
> 
> Thus I dropped it some months ago and entered resignation mode.
> 
> (Michael Sharpe has some very nice extras to his font packages so
> that even when accessing a font by filename with xelatex one does
> not have to list explicitely the bold, italic, etc.. variants, but
> doing this for all fonts obviously requires extra work)
> 
> 2. But Herb Schulz gave me very good advice to simply symlink the
> texmf-dist/fonts/opentype (and I did also texmf-dist/fonts/truetype)
> from $HOME/Library/Fonts. The miracle is :
> 
> a. FontBook.app is still usable after that. There is only a
> slight delay in opening it, about two seconds during which the font
> list is prepared.
> 
> b. all fonts in sub-repertories are found nicely
> 
> c. there are a few duplicates between .otf and .ttf (FreeSerif,
> FreeSans, FreeMono in particular) but the FontBook GUI allows to
> choose which fonts to validate and this works with no hiccup.
> (which is surprising regarding FontBook.app)
> 
> d. there is slight disadvantage that some fonts with names
> starting with "drm" occupies many (dozens) lines in FontBook
> display, but that's cosmetic.
> 
> After my bad experience with the concept of "Font Library" I was
> very much surprised that simply putting symlinks worked out so
> well. Thanks Herb !
> 
> And I could confirm that after that, all the TeXLive distributed
> opentype/truetype fonts become generally available to Mac
> Applications such as TextEdit, OpenOffice, etc... and to XeTeX
> naturally. The delay I mentioned above applies only to FontBook.app,
> applications such as OpenOffice have their font popup instantly
> available with TeX Gyre Termes etc... and naturally XeTeX works
> with no delay either.
> 
> 3. There is perhaps an impact on LuaTeX+luaotfload, because the
> TeXLive distributed fonts will be indexed twice. I do not know if
> this slows down LuaTeX. I opened a ticked on github site of
> luaotfload about this asking for info.
> 
> https://github.com/lualatex/luaotfload/issues/359
> 
> 4. The specific way to symlink by Herb takes advantage of the
> TeXDist structure which has been part of MacTeX install for some
> years, in /Library/TeX. This way the symlinks are dynamical and
> obey on the fly change of TeXLive distribution year.
> 
> ln -s /Library/TeX/Root/texmf-dist/fonts/opentype
> ~/Library/Fonts/TeXOpenType
> 
> I did also
> 
> ln -s /Library/TeX/Root/texmf-dist/fonts/truetype
> ~/Library/Fonts/TeXTrueType
> 
> but had to resolve a few duplicates then as mentioned above.
> 
> (the point is that /Library/TeX/Root is already itself a symlink,
> and when changing distribution year via the former Panel or via
> TLU, its target is automatically updated)
> 
> 5. To make my story complete: took me a while to go to the root
> of the following problem. I was surprised to see that log files
> with \XeTeXtracingfonts1 indicated the opentype fonts were picked
> always from texlive/2015, even if working with TL2014 or TL2016
> pretest.
> 
> Turns out that my earlier attempt at adding TeXLive OpenType fonts
> to general mac os availability via a "Font Library" added to FontBook.app
> had resulted in some non-removed cache in /private/var/folders.
> 
> I looked
> in vain everywhere in my $HOME and in obvious system locations,
> for such a file, as it was obviously the only explanation to the
> observed behavior and was finally saved by the tip at
> 
> http://osxdaily.com/2015/01/08/clear-font-caches-databases-mac-os-x/
> 
> which is to do $ sudo atsutil databases -remove
> 
> it is important to reboot immediately after that.
> 
> This last item is only of relevance to people who messed up with
> FontBook.app before, I guess.
> 
> To sum up: For smooth experience with XeTeX on Mac OS X, some
> people (me following Herb) have found that
> 
> ln -s /Library/TeX/Root/texmf-dist/fonts/opentype ~/Library/Fonts/TeXOpenType
> 
> and
> 
> ln -s /Library/TeX/Root/texmf-dist/fonts/truetype ~/Library/Fonts/TeXTrueType
> 
> is a well-working approach. In some rare cases, it might be needed to do
> (before or after it does not matter)
> 
>    sudo atsutil databases -remove
> 
> and
> to reboot. That's only to clean-up a pre-existing dysfunctional font situation.
> 
> Hope it helps.
> 
> Jean-François
> 
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tug.org/pipermail/tex-live/attachments/20160618/2d6cc36d/attachment-0001.html>


More information about the tex-live mailing list