[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Should -dev packages providing .pc files depend on pkg-config?



On Sat, Apr 05, 2008 at 04:52:29PM +0200, Tollef Fog Heen wrote:
That depends on the library you are linking against.  I, as an library
author is free to say «the only supported way to use my gargleblaster
library is through the I_CAN_HAS_GARGELBLASTER autoconf macro» (which
then proceeds to set GARGLEBLASTER_CFLAGS and GARGLEBLASTER_LIBS by
using pkg-config).  If I do that, pkg-config is effectively part of
the API.

If the only supported way to link against your library is to use the autotools, you should be shot, especially if libtool is anywhere in the equation. Not everybody uses the autotools, and their only benefit is portability.

Secondly, Debian is not necessarily in the business of doing everything upstream authors want. I remember Mozilla was quite upset when we started shipping shared libraries of their components (XUL, NSS, etc.), because their way was to statically link a stub and then dlopen the modules. Debian decided that was not the way that best served our users, and proceeded to ignore their recommendation[0].

I think it is safe to say that Debian supports passing the appropriate command line arguments without using pkg-config, even if upstream does not. At least that seems to be my experience.

[0] Google for "Mozilla Debian shared library"

--
brian m. carlson / brian with sandals: Houston, Texas, US
+1 713 440 7475 | http://crustytoothpaste.ath.cx/~bmc | My opinion only
troff on top of XML: http://crustytoothpaste.ath.cx/~bmc/code/thwack
OpenPGP: RSA v4 4096b 88AC E9B2 9196 305B A994 7552 F1BA 225C 0223 B187

Attachment: signature.asc
Description: Digital signature


Reply to: