Re: Compiling from source, adding latest libgd source
| From: | Christoph M. Becker | Date: | Wed, 16 Dec 2020 13:02:36 +0000 |
| Subject: | Re: Compiling from source, adding latest libgd source | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-327387@lists.php.net to get a copy of this message | ||
On 16.12.2020 at 13:30, Pete Cooper wrote:
> I am compiling PHP 8.0,1RC1 from source on Ubuntu 20.04LTS. I would like to be able to use the
> current version of libgd (v2.3.0) instead of the bundled version (v2.1.0 compatible) or the
> system-installed version (v2.2.5).. Is this possible?
>
> If I use the
--enable-gd flag, PHP 8.0.1RC1 uses the bundled
> libgd (expected).
> If I also use the --with-external-gd flag, PHP 8.0.1RC1 uses
> the system-wide libgd (expected).
>
> Is there a way I can compile PHP with the libgd source, or alternatively point the PHP
> configure / compile process to point to a pre-compiled version of libgd specifically for PHP (e.g.
> if I compile libgd source to /etc/php/shared/libgd/).
As of PHP 7.4.0, gd and several other extensions rely on pkg-config to
figure out the location of libraries. Set PKG_CONFIG_PATH as required, e.g.
PKG_CONFIG_PATH=/etc/php/shared/libgd/lib/pkgconfig/
Regards,
Christoph