Subject: Problems building cairo
To: None <>
From: None <>
List: tech-pkg
Date: 02/15/2006 11:27:16

(Hope this is the right list for this question ...)

Using pkgsrc, I am trying to build py-gtk2 for Red Hat Enterprise Linux WS
release 3 (Taroon Update 6)

I am consistently running into a problem building graphics/cairo that
results in the following error:

(...snip configure output prior to error ...)
config.status: executing depfiles commands

cairo will be compiled with the following surface backends:
  Xlib: yes
  Quartz: no
  XCB: no
  Win32: no
  PostScript: no
  PDF: no
  glitz: yes

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:

*** Error code 1

bmake: stopped in /m/mls/pkg/trees/dev/src/graphics/cairo

FreeType and fontconfig are installed, and pkg_info shows them as such.

I traced the error to .buildlink not having any symlinks to the
fontconfig.pc file and freetype2.pc file.  (they are built in my pkgsrc
What I can't determine is why the wrapper phase does not detect these
packages that are installed in my pkgsrc tree.

First time was metadata from CVS dated Jan 19.

I also tried metadata from Feb 7th with the same result.  (BTW, cairo
metadata does not cause fontconfig or freetype to be built automatically -
missing dependency?).

The graphics/cairo/ file provides the BUILDLINK_DEPENDS and
include for both freetype and fontconfig, so I don't know why the wrapper
phase doesn't create the links for these packages ...

I tried adding a post-wrapper target to the graphics/cairo/Makefile that
created the symlinks to the freetype2.pc and fontconfiig.pc files in
work/.buildlink/lib/pkgconfig and the build got further, but eventually
complained about not being able to find freetype headers ... I'm guessing
there are other symlinks that aren't there in the .buildlink/include dir

I can keep adding symlinks in the post-wrapper target, but this doesn't
solve the real problem.

I'm relatively new to pkgsrc, so not sure where to go from here ...
Any help will be appreciated ...

Tim Noell
Lexmark International, Inc.