Created attachment 167119 [details] config.log of make with ZTS checked mod_php70 fails if the www/apache24 port is configured to use any MPM other than prefork (I selected event and worker mpms and they both fail the same way).
Created attachment 167120 [details] Output of: /usr/local/sbin/pkg-static info -g -Ea
Looks like ZTS or not ZTS build for mod_php70 will fail if apache24 is configured with a non prefork mpm selected.
Hm, cannot comment at the moment since I haven't tested php7 at the time, but I think there are already report from users using apache24 with php7 (freebsd-ports mailing list). Perhaps it will be a good idea to deprecate mod_php altogether and pointing users to php-fpm. https://wiki.apache.org/httpd/PHP-FPM
It works with apache22 (well, it builds - haven't been able to actually try it, unfortunately). BTW: if you use php-fpm, does one still need to enable the ZTS-option? There's surprisingly little information about the whole ZTS topic. I only use PHP-FPM ever since it started to be included in PHP 5.3.
(In reply to rainer from comment #4) No, with php-fpm ZTS is not required. In best case mod_php7 will go away, mod_php is the only reason apache24 default to prefork MPM instead of worker so we do mot need a second set of ports/packages for php.
(In reply to Olli Hauer from comment #5) s/worker/event/
I was thinking along that (PHP-FPM is after all completely decoupled from the web-server and its threading-mechanism). But in the discussion on github, somebody said something like "it may still be needed for some modules". I was looking for some more documentation about this - but there simply isn't. mod_php might still be needed by some. So, as little as I care for it, I just assume it should be kept around for a while for those poor souls who haven't got time to migrate.
Hi, Can you please try the following patch? https://people.freebsd.org/~miwi/patches/php70-zts-phtread.diff
(In reply to Olli Hauer from comment #3) php-fpm has many of its own issues, which is why I specifically *dont* use it. Also, php-fpm has issues with modules such as simplexml (with or without ZTS enabled) I can't even begin to count the number of servers i've reverted from using php-fpm to mod_php or suphp methods after issues with specific modules under fpm.
I'll test the patch out and let you know.
Compiles fine with the patch
The mod_php isn't threadsafe. See my report.
miwi@ resigned.
Created attachment 177484 [details] php70 patch from comment 8 Assign tz@ (php70/mod_php70 maintainer) - Re-open. You may want to start with the patch from comment 8 (attached here)
FYI, this fix was already approved by miwi@ and committed by fluffy@ in r415304 in May. So I reassign this PR back to miwi@ and close.