Bug 783906

Summary: Bad font configuration
Product: [Fedora] Fedora Reporter: Remi Collet <fedora>
Component: GraphicsMagickAssignee: Andreas Thienemann <andreas>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: unspecified    
Version: 16CC: andreas, rdieter
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: GraphicsMagick-1.3.13-3.fc16 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-02-04 05:27:06 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Remi Collet 2012-01-23 07:43:26 UTC
GraphicsMagick-1.3.12-6.fc16.x86_64

$ cat /usr/lib64/GraphicsMagick-1.3.12/config/type.mgk
<?xml version="1.0"?>
<typemap>
   <include file="type-windows.mgk" /> <include file="type-ghostscript.mgk" />
</typemap>

$ grep glyphs /usr/lib64/GraphicsMagick-1.3.12/config/type-windows.mgk
    glyphs="/usr/share/fonts/msttcorefonts/arial.ttf"
    glyphs="/usr/share/fonts/msttcorefonts/ariblk.ttf"
    glyphs="/usr/share/fonts/msttcorefonts/arialbd.ttf"
    glyphs="/usr/share/fonts/msttcorefonts/arialbi.ttf"
    ...

The msttcorefonts are not part of fedora, so should be removed.

Default config should only include font files requires by the package.

So this package should requires "urw-fonts" which provides fonts listed in type-ghostscript.mgk

With current default config, applications which rely on 'getFonts' will crash

Ex: (from php-pecl-gmagick test suite)
Fatal error: Uncaught exception 'GmagickException' with message 'Unable to read font (/usr/share/fonts/msttcorefonts/arial.ttf)' in /dev/shm/php-pecl-gmagick-1.1.0/gmagick-1.1.0RC2/tests/gmagick-006-annotateimage.php on line 13

Comment 1 Rex Dieter 2012-01-23 15:03:18 UTC
Silly me for assuming and hoping that GM would gracefully handle using these msfonts if present, and not crash otherwise.  Boo.

I'll take a look.  Will likely just omit support for msttcorefonts and add the dependency on urw-fonts ... as suggested.

Comment 2 Fedora Update System 2012-01-23 18:26:15 UTC
GraphicsMagick-1.3.13-3.fc16 has been submitted as an update for Fedora 16.
https://admin.fedoraproject.org/updates/GraphicsMagick-1.3.13-3.fc16

Comment 3 Rex Dieter 2012-01-23 18:27:40 UTC
OK, ^^ has been added as a buildroot override too.  Let me know how things go.

Comment 4 Remi Collet 2012-01-23 18:57:34 UTC
Great thanks for the quick fix.
buildroot override is not need for me.

Comment 5 Fedora Update System 2012-01-24 01:42:00 UTC
Package GraphicsMagick-1.3.13-3.fc16:
* should fix your issue,
* was pushed to the Fedora 16 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing GraphicsMagick-1.3.13-3.fc16'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-0856/GraphicsMagick-1.3.13-3.fc16
then log in and leave karma (feedback).

Comment 6 Fedora Update System 2012-02-04 05:27:06 UTC
GraphicsMagick-1.3.13-3.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.