Poudriere build of pdo_* ports fails if ZTS is enabled

From: José_Pérez <fbl_at_aoek.com>
Date: Sat, 28 Dec 2024 10:13:32 UTC
Hi,
I get this failure when poudriere building pdo_*, e.g. is with 
php82-pdo_pgsql:

===>   Returning to build of php82-pdo_pgsql-8.2.26
===>   php82-pdo_pgsql-8.2.26 depends on file: 
/usr/local/lib/php/20220829/pdo.so - not found
===>   Installing existing package /packages/All/php82-pdo-8.2.26.pkg
[14-default-job-01] Installing php82-pdo-8.2.26...
[14-default-job-01] Extracting php82-pdo-8.2.26: .......... done
=====
Message from php82-pdo-8.2.26:

--
This file has been added to automatically load the installed extension:
/usr/local/etc/php/ext-20-pdo.ini.sample
===>   php82-pdo_pgsql-8.2.26 depends on file: 
/usr/local/lib/php/20220829/pdo.so - not found
*** Error code 1

Stop.
make: stopped in /usr/ports/databases/php82-pdo_pgsql
=>> Cleaning up wrkdir
===>  Cleaning for php82-pdo_pgsql-8.2.26


The problem seems to be related to the fact that the ports searches for 
the dependency in the wrong place (/usr/local/lib/php/20220829/pdo.so 
instead of /usr/local/lib/php/20220829-zts/pdo.so), looks like it does 
not see the enabled ZTS option in lang/php82.


Kindly note that I do have WITH_MPM=event in /etc/make.conf but this 
only works with Apache, in my case I use Nginx.

Is there a known workaround?

Thank you.


-- 
José Pérez