pkg-config-lite
LRN
lrn1986 at gmail.com
Fri Mar 30 19:53:03 PDT 2012
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 19.03.2012 22:51, Oliver Lange wrote:
>
> Howdy,
>
> pkg-config 0.26 without glib dependency:
>
> http://sourceforge.net/projects/pkgconfiglite/
>
> Maybe you want to check this out. It shows how little code from
> glib is required by pkg-config. It has no dependencies (other than
> libc).
>
> Changes are minor and maybe you'd like to take over?
>
It sounds cool, but pkg-config-0.26 (or was it 0.25?) actually REMOVED
a built-in copy of glib-1.2 that was used to avoid circular dependency
and to make pkg-config self-contained.
It barely worked on Windows - i was able to fix it up by transplanting
quite a bit of mangled glib-2.x source code into it, but that just
shows that pkg-config IS dependent on glib-2, and tapping that
dependency can bring benefits (again, if the dependency is not used
extensively at the moment, it's because the transition is still fresh
enough).
That is, making pkg-config self-contained that way most likely goes in
a direction opposite the one pkg-config is moving in.
Circular dependency between pkg-config and glib is easy to avoid
(assuming that ${prefix} is set to prefix, usually "/mingw"):
save_exec_prefix=${exec_prefix}
save_libdir=${libdir}
save_includedir=${includedir}
save_IFS=$IFS
IFS=$(echo -en "\n\b")
for l in $(cat /mingw/lib/pkgconfig/libffi.pc | sed -n -e
'/\(exec_prefix\|libdir\|includedir\)=/p' -e
's/Libs:\(.\+\)/LIBFFI_LIBS="\1"/ p' -e
's/Cflags:\(.\+\)/LIBFFI_CFLAGS="\1"/ p')
do
eval $l
done
IFS=$save_IFS
<configure glib>
exec_prefix=${save_exec_prefix}
libdir=${save_libdir}
includedir=${save_includedir}
That is, glib only needs pkg-config to find libffi, and this one time
we can just point the proverbial finger...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iQEcBAEBAgAGBQJPdnGMAAoJEOs4Jb6SI2CwlLIIAMFKCdHBdC1wROxAzB59Ywwc
LpsKfnICh9KFJOime+ZDEhgSpwmRvL0YHTjt+P2zraV9EuX79CiLOqf6mK5xZ1ny
C2D6hE6VyGJZVwR/W17P7+DkVl3dWpfnAMeG2w1qjDB0Ce8zFx2txVTOcBLmoz2i
6VddznH7PDinxHIHQjEW5a4n4HtXLeAR4WmiN0n3DSyNwD3DOyGCYzaLICjKK92s
+ZVwcGfrD8RmAKWE4mQiwsISZ4XHXgnU2Gt/JsmrROcjB4U2awPUFEU5xhJdixf9
IIADICgEjJHAdek+SsNkXZCMV7qruvMfXD0tFKz92/rGIxt07SfdG+54+4UOlds=
=5lGV
-----END PGP SIGNATURE-----
More information about the pkg-config
mailing list