[reSIProcate] [RFC] pkgconfig support
Gregor Jasny
jasny at vidsoft.de
Sat Dec 13 16:45:13 CST 2008
Hi,
I've got a patch here for you to comment on. Now that we can choose
between ares and c-ares, the application developers will have to
link against the correct version, too. To ease this step, I've
implemented support for generating a pkgconfig file during install.
Some comments:
build/Makefile.pkg
* For every library you can specify an additional variable naming the
pkgconfig name. It is called *_PKGNAME.
build/Makefile.post
* if it's a library we're installing PKGCONFIG_FILE points to the
pkgconfig location. After all libs and headers are installed, the file
is written by simple echo calls. I've preferred this procedure over a
template libfoo.pc.in, because it produced the non-intrusivest patch
* We sort and make the dependent libraries unique by calling '$(sort )
* For every dependent library 'pkg' in this unique list we do the following:
We add all $($(pkg)_PKGNAME) to the Requires: field. Libraries with
a not set (thus empty) PKGNAME will therefore not end up here
If the *_PKGNAME was empty, we add -l*_LIBNAME if *_LIBNAME is not
empty to avoid nasty things like -lbar -l -lfoo happening
To be done:
* Add Name: Version: and Description: to generated .pc files
* Understand and use Libs.private:
I await your comments!
Thanks,
Gregor
-------------- next part --------------
A non-text attachment was scrubbed...
Name: resip-pkgconfig.diff
Type: text/x-diff
Size: 2933 bytes
Desc: not available
URL: <http://list.resiprocate.org/pipermail/resiprocate-devel/attachments/20081213/bfc8fde8/attachment.diff>
More information about the resiprocate-devel
mailing list