Bug 1278049 - Default search directories do not include the location of TeX Live fonts
Default search directories do not include the location of TeX Live fonts
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: texlive (Show other bugs)
rawhide
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Tom "spot" Callaway
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-11-04 10:42 EST by Dimitrios Christidis
Modified: 2016-01-22 16:23 EST (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-01-22 16:23:16 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Dimitrios Christidis 2015-11-04 10:42:35 EST
Description of problem:
Beginning with Fedora 23, the OTF files for Computer Modern Unicode are included in texlive-cm-unicode. However, fontconfig is not configured to search the install location by default. Thus, the user is required to perform additional steps to use that font in TeX or other applications.


Version-Release number of selected component (if applicable):
fontconfig-2.11.94-4.fc23.x86_64
texlive-cm-unicode-svn19445.0.7.0-14.fc23.noarch


How reproducible:
Always


Steps to Reproduce:
1. dnf install texlive-cm-unicode
2. fc-list | grep CMU


Actual results:
fontconfig does not locate the recently installed fonts.


Expected results:
After installation, the fonts should be available for use without further actions.
Comment 1 Nicolas Mailhot 2015-11-04 12:31:50 EST
The problem is in texlive, which is not following Fedora packaging guidelines. They would ensure its fonts are properly published in fontconfig, app install, etc

https://fedoraproject.org/wiki/Packaging:FontsPolicy
Comment 2 Dimitrios Christidis 2015-11-04 13:58:16 EST
It seems that I was also mistaken on the date of addition; the OTF files have been present for quite some time. I never noticed because fontspec would not find the fonts automatically.

Am I using them in a wrong way? If so, this bug might be invalid.

Nevertheless, I think it would be useful to make those fonts available to all applications.
Comment 3 Nicolas Mailhot 2015-11-04 14:08:32 EST
You're not using it the wrong way, it's texlive that installs its fonts for historical reasons in private locations no other software will look in.

It used to annoy everyone but TEX users. However nowadays TEX is migrating to text engines that look for fonts in the same places as everyone else (because TEX users want to use the nice unicode opentype fonts available in standard locations), so now TEX warts are hitting TEX users too.

The solution is to install TEX opentype fonts in standard locations fontconfig/rpm/etc look for them, as required by Fedora packaging guidelines.
Comment 4 Tom "spot" Callaway 2015-11-09 16:39:55 EST
I'm worried that I'll break TeX (a much older and scarier system) by moving their fonts into unexpected locations, even if those locations are more reasonable for the rest of the world.

Would a good compromise be to make symlinks to the OTF font files in /usr/share/fonts/%{name} (%{_fontdir}) in the texlive packages?
Comment 5 Akira TAGOH 2015-11-09 21:42:50 EST
That should works. but we need to do this change carefully so that this would means we'll see more fonts installed by default from POV of fontconfig. it may have a side-effect and gives different looks to users.
Comment 6 Nicolas Mailhot 2015-11-10 05:42:32 EST
(In reply to Akira TAGOH from comment #5)
> That should works. but we need to do this change carefully so that this
> would means we'll see more fonts installed by default from POV of
> fontconfig. it may have a side-effect and gives different looks to users.

I don't see a good way to avoid the side effects except being careful with font aliasing. And the aliasing can not be adjusted before fonts are actually there.

But the fonts (at least all the otf and ttf ones) need to move to /usr/share/fonts/something since people (and apps) now expect this location, even though all of them have not realized yet what fontconfig is. All kind of apps poke in /usr/share/fonts directly nowadays without using system fontconfig. If you look at font questions on stackoverflow the standard answer now is to put fonts there, not to run xfs like people answered just a few years ago.

spot has the right transitional answer, though determining when to get rid of the compat symlinks is going to be tricky.
Comment 7 Akira TAGOH 2015-11-10 22:12:13 EST
(In reply to Nicolas Mailhot from comment #6)
> I don't see a good way to avoid the side effects except being careful with
> font aliasing. And the aliasing can not be adjusted before fonts are
> actually there.

Right. well, was just a reminder to pay more attentions on this change.

> spot has the right transitional answer, though determining when to get rid
> of the compat symlinks is going to be tricky.

Indeed. ideally it would be good to move the fonts under /usr/share/fonts without symlinks. need to test it carefully anyway.
Comment 8 Dimitrios Christidis 2016-01-04 12:14:39 EST
I noticed that the GFS and Linux Libertine fonts (and possibly others) have a separate package that installs the OTF files in /usr/share/fonts. Would this be a safer solution?
Comment 9 Nicolas Mailhot 2016-01-04 16:22:52 EST
(In reply to Dimitrios Christidis from comment #8)
> I noticed that the GFS and Linux Libertine fonts (and possibly others) have
> a separate package that installs the OTF files in /usr/share/fonts. Would
> this be a safer solution?

The otf package for those fonts conforms to Fedora font packaging guidelines
Comment 10 Tom "spot" Callaway 2016-01-14 15:25:12 EST
I'm going to commit the symlink changes into rawhide's texlive. If there are conflicts or mistakes, please test there and let me know. The following texlive subpackages are affected:

accanthis
almfixed
antt
asana-math
baskervaldx
berenisadf
cabin
ccicons
cm-unicode
comicneue
cyklop
dantelogo
drm
ebgaramond
erewhon
fandol
fbb
fdsymbol
fetamont
fira
fontawesome
gfsartemisia
gfsbaskerville
gfsbodoni
gfscomplutum
gfsdidot
gfsneohellenic
gfsporson
gfssolomos
gillius
gnu-freefont
heuristica
inconsolata
iwona
kurier
libertine
librebaskerville
librecaslon
lm
lm-math
lobster2
mdsymbol
mintspirit
mnsymbol
newpx
ocr-b-outline
oldstandard
phaistos
philokalia
playfair
poltawski
punknova
quattrocento
raleway
semaphor
skaknew
sourcecodepro
sourcesanspro
sourceserifpro
stix
tex-gyre
tex-gyre-math
umtypewriter
universalis
xcharter
xits
Comment 11 Tom "spot" Callaway 2016-01-22 16:23:16 EST
This is now "fixed" in texlive-2015-21.20150728_r37987.fc24.

Note You need to log in before you can comment on or make changes to this bug.