On 5/7/22 12:11, Stuart Henderson wrote:
Do you also get a crash from e.g. "php-8.0 -i"?
If so, can you run that under gdb and try and get a backtrace?
pkg_add gdb
egdb php-8.0
set args -i
run
bt
php-8.0 -i runs without any problems.
php-8.0 -i
phpinfo()
PHP Version => 8.0.10
System => OpenBSD sbc3.fusion-zone.net 7.1 GENERIC#35 armv7
Build Date => Oct 26 2021 18:40:20
Build System => OpenBSD armv7-1.ports.openbsd.org 7.0 GENERIC#80406 armv7
Configure Command => './configure'
...
Here is the output of 'egdb php-8.0'
egdb php-8.0
GNU gdb (GDB) 7.12.1
Copyright (C) 2017 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "arm-unknown-openbsd7.0".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from php-8.0...(no debugging symbols found)...done.
(gdb) set args -i
(gdb) run
Starting program: /usr/local/bin/php-8.0 -i
Program received signal SIGILL, Illegal instruction.
0x7ffcfee0 in _armv8_pmull_probe () at
/usr/src/lib/libcrypto/armv4cpuid.S:91
91 /usr/src/lib/libcrypto/armv4cpuid.S: No such file or directory.
(gdb) bt
#0 0x7ffcfee0 in _armv8_pmull_probe () at
/usr/src/lib/libcrypto/armv4cpuid.S:91
#1 0x7ffda950 in OPENSSL_cpuid_setup () at
/usr/src/lib/libcrypto/armcap.c:69
#2 0x77570b2c in _dl_call_init_recurse (object=0x9440d600,
initfirst=initfirst@entry=0) at /usr/src/libexec/ld.so/loader.c:831
#3 0x775709ec in _dl_call_init_recurse (object=0x8161cc00,
initfirst=initfirst@entry=0) at /usr/src/libexec/ld.so/loader.c:806
#4 0x775709ec in _dl_call_init_recurse (object=object@entry=0x8bf39000,
initfirst=0) at /usr/src/libexec/ld.so/loader.c:806
#5 0x7757c544 in _dl_call_init (object=0x8bf39000) at
/usr/src/libexec/ld.so/loader.c:776
#6 _dl_boot (argv=<optimized out>, envp=<optimized out>,
dyn_loff=<optimized out>, dl_data=0xbfff1a3c) at
/usr/src/libexec/ld.so/loader.c:697
#7 0x7757cb08 in _dl_start () at /usr/src/libexec/ld.so/arm/ldasm.S:61
#8 0x7757cb08 in _dl_start () at /usr/src/libexec/ld.so/arm/ldasm.S:61
...
The manual start of php-fpm-8.0 shows following warning message. But
also the comment of line 143 doesn't solve the problem.
/usr/local/sbin/php-fpm-8.0
[07-May-2022 13:36:54] WARNING: Nothing matches the include pattern
'/etc/php-fpm.d/*.conf' from /etc/php-fpm.conf at line 143.
Here is the output of '/usr/local/sbin/php-fpm-8.0'
egdb /usr/local/sbin/php-fpm-8.0
GNU gdb (GDB) 7.12.1
Copyright (C) 2017 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "arm-unknown-openbsd7.0".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/local/sbin/php-fpm-8.0...(no debugging symbols
found)...done.
(gdb) run
Starting program: /usr/local/sbin/php-fpm-8.0
Program received signal SIGILL, Illegal instruction.
0x87bf4ee0 in _armv8_pmull_probe () at
/usr/src/lib/libcrypto/armv4cpuid.S:91
91 /usr/src/lib/libcrypto/armv4cpuid.S: No such file or directory.
(gdb) bt
#0 0x87bf4ee0 in _armv8_pmull_probe () at
/usr/src/lib/libcrypto/armv4cpuid.S:91
#1 0x87bff950 in OPENSSL_cpuid_setup () at
/usr/src/lib/libcrypto/armcap.c:69
#2 0x644b0b2c in _dl_call_init_recurse (object=0x5d0c6200,
initfirst=initfirst@entry=0) at /usr/src/libexec/ld.so/loader.c:831
#3 0x644b09ec in _dl_call_init_recurse (object=0x70f88000,
initfirst=initfirst@entry=0) at /usr/src/libexec/ld.so/loader.c:806
#4 0x644b09ec in _dl_call_init_recurse (object=object@entry=0x8ad54000,
initfirst=0) at /usr/src/libexec/ld.so/loader.c:806
#5 0x644bc544 in _dl_call_init (object=0x8ad54000) at
/usr/src/libexec/ld.so/loader.c:776
#6 _dl_boot (argv=<optimized out>, envp=<optimized out>,
dyn_loff=<optimized out>, dl_data=0xbffc6a3c) at
/usr/src/libexec/ld.so/loader.c:697
#7 0x644bcb08 in _dl_start () at /usr/src/libexec/ld.so/arm/ldasm.S:61
#8 0x644bcb08 in _dl_start () at /usr/src/libexec/ld.so/arm/ldasm.S:61
...
After I populated /usr/src (src.tar.gz and sys.tar.gz from
https://ftp.artfiles.org/openbsd/7.1/) there is no file
/usr/src/lib/libcrypto/armv4cpuid.S
The only *.S file is sparccpuid.S
Maybe the cause is the _armv8_pmull_probe on an armv7 platform?
The last armv7 snapshot package builds are from 2021-11-16. Currently
there are no official 7.1 packages for the armv7 platform. I run the
latest snapshot (2022-05-03) on this machine. Maybe this has an impact
(package from the 7.0 time on a 7.1 system)?
Thanks,
Sven