libxml-2.0-uninstalled.pc.in


Log

Author Commit Date CI Message
James Le Cuirot 6864d92f 2023-09-04T09:25:44 autoconf: Don't bake build time CFLAGS into pkg-config file Having slept on it, I've realised that baking the dependency CFLAGS into the pkg-config file is pointless when it is only used to link against them. It may even cause problems.
James Le Cuirot 93e8bb2a 2023-09-02T17:12:58 build: Generate better pkg-config files for static-only builds pkg-config supports `Requires.private` and `Libs.private` fields for static linking. However, if you're building a dynamic binary, then pkg-config will use the non-private fields, even if just the static libxml2 is available. This will result in libxml2 being underlinked, causing the build to fail. The solution is to fold the private fields into the non-private fields when the shared libxml2 is not being built. This works for Autotools and CMake. Meson also knows how to handle this when it automatically generates pkg-config files.
James Le Cuirot 4640ccac 2023-09-02T16:18:30 build: Generate better pkg-config file for SYSROOT builds The -I and -L flags you use to build should not necessarily be the same ones you bake into installed files. If you are building with dependencies located under a SYSROOT then the installed files should have no knowledge of that SYSROOT. For example, if the build requires `-L/path/to/sysroot/usr/lib/foo` then only `-L/usr/lib/foo` should be baked into the installed files. pkg-config is SYSROOT-aware, so this issue can be sidestepped by using the `Requires` field rather than the `Libs` and `Cflags` fields. This is easily resolved if you rely solely on pkg-config, but this project falls back to standard Autoconf checks, so a little more effort is required. Unfortunately, this issue cannot feasibly be resolved for CMake. `find_package` is used rather than `pkg_check_modules`, so we cannot tell whether a pkg-config file for each dependency is present or not, even if `find_package` uses pkg-config behind the scenes. The CMake build does not record any dependency -I or -L flags into the pkg-config file anyway. This is a problem in itself, although these dependencies are most likely installed to standard locations. Meson is very much better at handling this, as it generates the pkg-config file automatically using the correct logic.
Nick Wellnhofer 5cae1a14 2022-04-03T02:20:59 Update libxml-2.0-uninstalled.pc.in
David Seifert 5c71ada8 2022-03-30T16:51:17 Detect libm using libtool's macros
Philip Withnall f859d9a7 2013-10-28T17:15:07 build: Add @LZMA_LIBS@ to libxml’s pkg-config files If libxml2 is built and linked against liblzma, the latter needs to appear in libxml2’s Libs.private pkg-config field, otherwise static linking against libxml2 will fail due to unresolved liblzma symbols. https://bugzilla.gnome.org/show_bug.cgi?id=711026
Arfrever Frehtes Taifersar Arahesis 1f01f49b 2012-08-28T22:16:50 Handle ICU_LIBS as LIBADD, not LDFLAGS to prevent linking errors For https://bugzilla.gnome.org/show_bug.cgi?id=677606 For https://bugs.gentoo.org/show_bug.cgi?id=417539 If libxml2-2.8.0 is built with --with-icu --with-python on a system that has an older version of libxml2 installed, then during "make install", libxml2mod.so gets relinked to the systemwide version of libxml2.so.2 instead of libxml2.so.2 from the build tree, and fails at runtime if symbol versions from the older libxml2.so.2 are not available. This effectively makes it impossible to build a libxml2-2.8.0 binary package on a system that does not already have libxml2-2.8.0 installed. Investigation by Rafał Mużyło and Arfrever Frehtes Taifersar Arahesis revealed the cause of the problem to be that libxml2's configure was adding ICU_LIBS to LDFLAGS instead of to LIBADD. This resulted in GNU libtool using the wrong argument order in its relinking command that gets run during "make install".
AEST 2003 Malcolm Tredinnick 0643112b 2003-09-30T02:36:08 New file for building against uninstalled libxml2 builds. Support the Tue Sep 30 12:31:00 AEST 2003 Malcolm Tredinnick <malcolm@commsecure.com.au> * libxml-2.0-uninstalled.pc.in: New file for building against uninstalled libxml2 builds. * configure.in, Makefile.am: Support the *-uninstalled.pc file.