Bug 102141

Summary: fontconfig git makes gimp not see fonts.
Product: fontconfig Reporter: Hussam Al-Tayeb <ht990332>
Component: libraryAssignee: Akira TAGOH <akira>
Status: RESOLVED FIXED QA Contact: Behdad Esfahbod <freedesktop>
Severity: normal    
Priority: medium CC: akira, fontconfig-bugs
Version: 2.12   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Hussam Al-Tayeb 2017-08-10 18:39:02 UTC
With fontconfig git, gimp text tool says I don't have any installed fonts.
Reverting to fontconfig 2.12.4 fixes it.
I still need to do a git bisect to report which checkin broke this. A GIMP developer suggested I report it here.
Comment 1 Hussam Al-Tayeb 2017-08-10 19:00:32 UTC
A git bisect led to https://cgit.freedesktop.org/fontconfig/commit/?id=12b7501bad3ed4d7819b00a27a9c021e7d120aa0 as first bad commit.
Comment 2 Akira TAGOH 2017-08-12 11:00:37 UTC
Thank you for reporting. I can reproduce this issue here too. let me take a look.
Comment 3 Akira TAGOH 2017-08-13 07:20:53 UTC
fixed in git dc56ff8
Comment 4 Michael Forney 2017-09-21 04:06:29 UTC
I don't quite understand your fix in dc56ff80.

In 2.12.4, a failure in FcConfigFile or FcOpen both lead to bail with error == FcTrue, causing the warning message to print and FcFalse to be returned.

In 2.12.5, a failure in either of those causes FcConfigParseAndLoad to just return FcTrue.

My system doesn't have a fontconfig config file, and just uses the fallback configuration. However, as of 2.12.5, FcConfigParseAndLoad returns FcTrue when the config doesn't exist causing FcInitLoadOwnConfig to not load the fallback config.

Reverting dc56ff80 solves the issue for me. I don't understand what issue it was meant to fix, but it does not seem to "Keep the same behavior to the return value of FcConfigParseAndLoad" as the commit message suggests.
Comment 5 Akira TAGOH 2017-09-21 05:04:56 UTC
Hmm, okay. reverted and fixed again. thanks

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.