Bug 19253

Summary: Please add --enable-fontconfig configuration option
Product: cairo Reporter: Otfried Cheong <freedesktop>
Component: freetype font backendAssignee: David Turner <david>
Status: RESOLVED FIXED QA Contact: cairo-bugs mailing list <cairo-bugs>
Severity: enhancement    
Priority: medium    
Version: 1.8.4   
Hardware: All   
OS: All   
See Also: https://bugs.freedesktop.org/show_bug.cgi?id=98043
Whiteboard:
i915 platform: i915 features:

Description Otfried Cheong 2008-12-23 04:27:17 UTC
I'm the author of an application that uses cairo for drawing.  I use Freetype fonts, but all the font management is done by the application itself (more precisely, the fonts come from PDF files generated by pdflatex).

To build my application for Windows, I need to compile cairo with support for freetype.  However, this currently requires me to also build fontconfig and libexpat (used by fontconfig), and to package those with my application.

This is complete unnecessary: The Freetype font driver in cairo is perfectly usable and useful without fontconfig (creating fonts using cairo_ft_font_face_create_for_ft_face).   I'm currently patching Cairo myself, commenting out everything in cairo-ft-font.[hc] that depends on fontconfig, and modifying the makefile to not link with fontconfig.  

It would be great if this could be a configuration option, as it would probably be useful for others as well.
Comment 1 Chris Wilson 2009-03-17 05:36:24 UTC
commit 3ec94f9b5917b8f71304c982bd153e5a810f3b12
Author: Behdad Esfahbod <behdad@behdad.org>
Date:   Tue Mar 17 00:53:30 2009 -0400

    Support compiling without fontconfig
    
    Adds a new, fake, fontconfig font backend.  Fontconfig can be disabled
    using --disable-fc, in which case the toy text API wont find fonts and
    the internal font will always be used.
    
    Also defines the feature macro CAIRO_HAS_FC_FONT.  The two fontconfig-specif
    functions in cairo-ft.h depend on that macro now.

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.