Re: pkg-config including too much crap
On Tue, Apr 04, 2006, Roger Leigh wrote:
> 1. gtk+-2.0.pc does not use Libs.private. This would clean up most of
> the libraries. This is a GTK+ bug.
gtk+-2.0.pc's Libs only has -lgtk, it requires gdk, atk, and cairo
because of grep -ir #include /usr/include/gtk-2.0 | grep -v 'atk' (it
needs at least the Cflags). Some people go as far as saying that since
the headers are included from gtk's headers, the resulting binaries
should be linked against these dependency-libs.
Some discussion of this in #340904 and friends.
> 2. Even then, -lgtk-x11-2.0 still needs to come from the Requires, but
> should still be private. For this, a Requires.private would be the
> best solution (but its Cflags should still remain public). This
> needs implementing in pkg-config.
Exactly, the Cflags should always be used IMO, there's some debate on
whether one should still link against libs of which the headers are
Loïc Minier <firstname.lastname@example.org>