Bug 4892

Summary: Cairo 1.0.2 does not recognize freetype 2.1.10
Product: cairo Reporter: John Berger <john>
Component: generalAssignee: Carl Worth <cworth>
Status: RESOLVED FIXED QA Contact: cairo-bugs mailing list <cairo-bugs>
Severity: normal    
Priority: high CC: bpopov
Version: 1.0.2   
Hardware: SPARC   
OS: Solaris   
Whiteboard:
i915 platform: i915 features:

Description John Berger 2005-10-26 08:00:00 UTC
When attempting to compile Cairo v1.0.2 on Solaris 9 (SPARC), it refuses to
recognize that Freetype v2.1.10 is installed.  I installed and compiled Freetype
from source code as well.  As a result, PDF and PS backends are disabled.  It
also does not recognize X libraries even though they've been in
/usr/openwin/lib/X11 on Solaris for years.

Fontconfig will not compile on Solaris 9 due to a libiconv error, but I'll
create another bug report (if necessary) for that.

bash-2.05# pkg-config --list-all
gmodule-export-2.0    GModule - Dynamic module loader for GLib
gmodule-2.0           GModule - Dynamic module loader for GLib
freetype2             FreeType 2 - A free, high-quality, and portable font engine.
glib-2.0              GLib - C Utility Library
gobject-2.0           GObject - GLib Type, Object, Parameter and Signal Library
gthread-2.0           GThread - Thread support for GLib
libpng                libpng12 - Loads and saves PNG files
gmodule-no-export-2.0 GModule - Dynamic module loader for GLib
pangox                Pango X - X Window System font support for Pango
libpng12              libpng12 - Loads and saves PNG files
pango                 Pango - Internationalized text handling
atk                   Atk - Accessibility Toolkit
 
bash-2.05#LD_LIBRARY_PATH="/usr/sfw/lib:/usr/local/lib:/usr/openwin/lib/X11:/usr/lib"
CFLAGS='-mcpu=v9' ./configure
.
.
checking for PNG... yes
checking for FONTCONFIG... sh: gnome-config: not found
checking for FcFini... no
checking pthread.h usability... yes
checking pthread.h presence... yes
checking for pthread.h... yes
configure: WARNING: PS backend requires FreeType 2.1.4 or newer, disabling
checking for compress in -lz... yes
checking zlib.h usability... yes
checking zlib.h presence... yes
checking for zlib.h... yes
configure: WARNING: PDF backend requires FreeType 2.1.4 or newer, disabling
checking for stdint.h... (cached) no
checking for inttypes.h... (cached) yes
checking sys/int_types.h usability... yes
checking sys/int_types.h presence... yes
.
.
cairo will be compiled with the following surface backends:
  Xlib: no (requires Xrender http://freedesktop.org/Software/xlibs)
  Quartz: no
  XCB: no
  Win32: no
  PostScript: no
  PDF: no
  glitz: no

the following font backends:
  FreeType: no
  Win32: no
  ATSUI: no

and the following features:
  PNG functions: yes
configure: error: Cairo requires at least one font backend.
		  Please install freetype and fontconfig, then try again:
		  http://freetype.org/	http://fontconfig.org/
Comment 1 John Berger 2005-10-26 08:51:40 UTC
Looks like cairo does not recognize FreeType unless FontConfig is installed. 
This is a somewhat deceptive message because FreeType IS installed.  Although
the message at the bottom says to install both FreeType and FontConfig, the
"following font backends" section makes it seem as though the dependency is on
FreeType when in reality it is on FontConfig.  (I'm assuming that this is the
reality of it because (A) FontConfig has a dependency on FreeType and (B) Cairo
was suddenly very happy once FontConfig was compiled and installed.)

Please change "the following font backends" display to stress a dependecy on
FontConfig, not FreeType.
Comment 2 Boris Popov 2006-01-08 09:41:29 UTC
Having a similar problem trying to compile latest cvs snapshot on win32
msys/mingw with FreeType 2.1.10 (also tried with 2.1.8)

checking for FONTCONFIG... yes
checking for FcFini... no
checking for FREETYPE... yes
checking for FT_Bitmap_Size.y_ppem... no
checking for FT_Load_Sfnt_Table... no
checking for FT_GlyphSlot_Embolden... no
checking pthread.h usability... no
checking pthread.h presence... no
checking for pthread.h... no
configure: WARNING: PS backend requires FreeType 2.1.4 or newer, disabling
checking for compress in -lz... no
configure: WARNING: PDF backend requires FreeType 2.1.4 or newer, disabling
configure: WARNING: SVG backend requires FreeType 2.1.4 or newer, disabling

...

cairo will be compiled with the following surface backends:
  image:      yes (always builtin)
  Xlib:       no (requires Xrender http://freedesktop.org/Software/xlibs)
  Quartz:     no
  XCB:        no
  Win32:      yes
  PostScript: no (requires zlib http://www.gzip.org/zlib/)
  PDF:        no
  SVG:        no
  glitz:      no
  BeOS:       no
  DirectFB:   no

the following font backends:
  FreeType:   yes
  Win32:      yes
  ATSUI:      no

Any hints?
Comment 3 Behdad Esfahbod 2006-10-25 13:53:19 UTC
This has been long fixed.

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.