[MPlayer-dev-eng] [PATCH] directfb -> pkg-config

The Wanderer inverseparadox at comcast.net
Fri Feb 17 14:39:26 CET 2006


Rich Felker wrote:

> On Thu, Feb 16, 2006 at 11:56:39PM +0100, Aurelien Jacobs wrote:

>> Also you didn't replied about dependencies. What if certain
>> versions of libfoo requires you to add -lbar ?
> 
> For dynamic libraries, this is automatically taken care of. For
> archive (static) libraries, one solution (perhaps the most proper for
> strange dependencies) is including one archive inside the other.
> However, for most common libraries, the dependencies are _known_ by
> the program using the library, e.g. libpng's dependence on libz.
> 
> Seriously, this all worked fine for the past 7 years or so before
> there was such a thing as pkg-config. pkg-config is yet another case
> of overengineering and inventing a solution to a nonexistant problem,
> or rather inventing the problem itself, which seems to be a common
> mistake of GNU/Linux these days and leads to endless bloat...

And what about cases where the program using the library does *not* know
about the dependencies? It is entirely conceivable, given some of my
back-burner projects, that I might have one day attempted to write a
program capable of producing PNG output; I had no idea that libpng
depended on libz. When initial compile tests gave linker errors,
pkg-config is the first thing I would have thought of (other than random
Googling) to try to find out what compiler flags I would need in order
to successfully compile such a program.

I'm not saying "we should use pkg-config exclusively and dump the
current system used in configure"; philosophically, I agree that adding
such dependencies when we don't have to is a bad thing. I *am* saying
that while pkg-config may not be a solution to the kind of problem
you're talking about, it *does* provide a solution to a problem which is
real enough in practice, and as far as I know it is the only such
solution which currently exists.

-- 
       The Wanderer

Warning: Simply because I argue an issue does not mean I agree with any
side of it.

Secrecy is the beginning of tyranny.




More information about the MPlayer-dev-eng mailing list