Problems with php-gd in php8.1

1k views Asked by At

I have php8.1 running on FreeBSD 12.

Install php81-gd and having a trouble to start php due to the following error:

Any guess how to fix it, please?

PHP Warning:  PHP Startup: Unable to load dynamic library 'gd.so' (tried: /usr/local/lib/php/20210902/gd.so (/usr/local/lib/php/20210902/gd.so: Undefined symbol "gdImageCreateFromAvif"), /usr/local/lib/php/20210902/gd.so.so (Cannot open "/usr/local/lib/php/20210902/gd.so.so")) in Unknown on line 0```
1

There are 1 answers

0
oysta On

You probably need to upgrade the libgd package as well with pkg upgrade libgd; for whatever reason the package manager doesn’t seem to do it automatically when you install the php81-gd package.