After installing mod_php80, Apache 2.4 refuses to start with error message >httpd: Syntax error on line 158 of /usr/local/etc/apache24/httpd.conf: Can't locate API module structure `php8_module' in file /usr/local/libexec/apache24/libphp.so: Undefined symbol "php8_module" The offending line: >LoadModule php8_module libexec/apache24/libphp.so Omitting the 8 solves the issue: >LoadModule php_module libexec/apache24/libphp.so
^Triage: assign to appropriate maintainer but also notify maintainer of www/mod_php80 .
I encountered this same issue, and removing the "8" character also fixed it for me.
Created attachment 221257 [details] Patch against lang/php80 I think the changed naming convention in PHP 8.0 causes this problem. I wrote this patch, which - at least - worked in my jail. But i only tested it against Apache. I have not tested it yet against everything else. Can you please review it and check if it fixes your problems? Thank you! Torsten
I've tried to test this, but I'm afraid I'm over my head here. I recently setup a poudriere server, which is how I build my Apache/PHP. I tried the following: poudriere jail -s -j amd64-12-2 jexec amd64-12-2-default that got me into the jail, I think. I see the file to patch: /usr/ports/lang/php80/Makefile and use `ee` to open it, but it won't save my changes. :(
A commit references this bug: Author: tz Date: Sat Jan 9 23:59:15 UTC 2021 New revision: 560908 URL: https://svnweb.freebsd.org/changeset/ports/560908 Log: lang/php80: Fix "can't locate API module structure `php8_module' in file /usr/local/libexec/apache24/libphp.so" Because of the SHORTMODNAME an entry for php8_module was added to httpd.conf when installing www/mod_php80. This was an error, because the module is now simple named "php_module". PR: 251411 Reported by: <freebsd-bugzilla@b-society.se> Sponsored by: PHP Update Service Changes: head/lang/php80/Makefile
Thank you Sean for your testing attempts! I tested it now on my own and think it is good enough. :)
Thanks for the fix! Is a new port now live? I can test that at least...
A commit references this bug: Author: tz Date: Sun Jan 10 21:20:01 UTC 2021 New revision: 561111 URL: https://svnweb.freebsd.org/changeset/ports/561111 Log: MFH: r560908 lang/php80: Fix "can't locate API module structure `php8_module' in file /usr/local/libexec/apache24/libphp.so" Because of the SHORTMODNAME an entry for php8_module was added to httpd.conf when installing www/mod_php80. This was an error, because the module is now simple named "php_module". PR: 251411 Reported by: <freebsd-bugzilla@b-society.se> Sponsored by: PHP Update Service Changes: _U branches/2021Q1/ branches/2021Q1/lang/php80/Makefile
> Thanks for the fix! Is a new port now live? I can test that at least... It is committed on head and now in quarterly. So if you build the ports by yourself: yes. If you use pkg it maybe needs a while until the packages are build.