[php-src] PR #13755: [WIP] Add PHP pkgconf .pc metadata file(s)
| From: | petk | Date: | Tue, 19 Mar 2024 10:27:06 +0000 |
| Subject: | [php-src] PR #13755: [WIP] Add PHP pkgconf .pc metadata file(s) | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-25478@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/13755
Author: petk
This is for the time being just a concept and work in progress so it can be properly synced with
#12389 It will be rebased and changes gradually incorporated since it depends on other refactoring
of the libdir variable name syncs and simplifications.
Since PHP *nix Autotools build system already extensively relies on [pkgconf
(pkg-config)](https://people.freedesktop.org/~dbn/pkg-config-guide.html) command-line tool to find
dependencies it should also provide its own .pc file(s).
This adds an initial php.pc.in and php-embed.pc.in template files that are created during the
configuration and build phase. They are installed in the provided system pkgconfig directory. For
example:
/usr/lib/pkgconfig/php.pc
/usr/lib/pkgconfig/php-embed.pc
/usr/lib/x86_64-linux-gnu/pkgconfig/php.pc
[Pkgconf][1] is a more actively maintained continuation of the initial [Freedesktop's
pkg-config project][2].
Extensions and applications embedding the PHP Embed SAPI can then optionally use also the pkgconf
command-line tool to get the required PHP CFLAGS and/or LIBS.
pkgconf --libs php-embed
pkgconf --modversion php-embed
pkgconf --cflags php-embed
pkgconf --cflags php
[1]: https://github.com/pkgconf/pkgconf
[2]: https://gitlab.freedesktop.org/pkg-config/pkg-config