Subject: Updating GTK+ to 2.8 - some doubts
To: None <>
From: Julio M. Merino Vidal <>
List: tech-pkg
Date: 10/01/2005 16:08:16
Hi all,

I've updated gtk2 to 2.8 in my local tree, but I'm not sure on how to
proceed now.
This version adds a new dependency on cairo.  AFAICT, cairo is used interna=
by GTK, so programs using this library shouldn't care at all about the new =
dependency.  Furthermore, 2.8 is supposed to be API and ABI compatible with
previous versions.

The "problem" comes from how pkg-config works.  Whenever a package requests
the flags to link against gtk2, it gets:

[dawn jmmv] $ pkg-config --libs gtk+-2.0
-Wl,-R/usr/pkg/lib -L/usr/pkg/lib -lgtk-x11-2.0 -lgdk-x11-2.0
-latk-1.0 -lgdk_pixbuf-2.0 -lm -lpangocairo-1.0 -lpango-1.0 -lcairo
-lgobject-2.0 -lgmodule-2.0 -lglib-2.0

Notice that -lcairo (and internal library) is exposed to the linker command=
; the
same happens with all other required libraries (atk, pango and glib).=20
This means
that packages built with the new GTK will have an extra dependency listed i=
their binaries.  I think this is a big mistake, as it breaks all the
dependencies concept.

This is not a big problem, though, as new binaries can coexist with old one=

The only issue I can see is that new binary packages must ensure that they
require gtk 2.8.  Thus one needs to bump BUILDLINK_RECOMMENDED to
2.8.0.  Is it?  Or is it BUILDLINK_DEPENDS?

If bumping the recommended version, do we need to bump revisions for all
packages using gtk2?  This is scary.

Or maybe we'd "fix" pkg-config to not list internal libraries on those
platforms that
do not require it?


Julio M. Merino Vidal <>
The NetBSD Project -