What did you do? If possible, provide a simple script for reproducing the error.
<?php
$http = new Swoole\Http\Server('127.0.0.1', 9501);
$http->on('start', function ($server) {
echo "Swoole http server is started at http://127.0.0.1:9501\n";
});
$http->on('request', function ($request, $response) {
$response->header('Content-Type', 'text/plain');
$response->end('Hello World');
});
$http->start();
What did you expect to see?
Swoole http server is started at http://127.0.0.1:9501
What did you see instead?
php: symbol lookup error: /usr/lib/php/20190902/openswoole.so: undefined symbol: __atomic_store_8
What version of Swoole are you using (show your php --ri swoole)?
$ php --ri openswoole
openswoole
Open Swoole => enabled
Author => Open Swoole Group <hello@openswoole.com>
Version => 4.9.1
Built => Dec 27 2021 10:51:12
coroutine => enabled with boost asm context
epoll => enabled
eventfd => enabled
signalfd => enabled
cpu_affinity => enabled
spinlock => enabled
rwlock => enabled
curl-native => enabled
pcre => enabled
zlib => 1.2.11
brotli => E16777225/D16777225
mutex_timedlock => enabled
pthread_barrier => enabled
futex => enabled
async_redis => enabled
Directive => Local Value => Master Value
swoole.enable_coroutine => On => On
swoole.enable_library => On => On
swoole.enable_preemptive_scheduler => Off => Off
swoole.display_errors => On => On
swoole.use_shortname => On => On
swoole.unixsock_buffer_size => 8388608 => 8388608
What is your machine environment used (show your uname -a & php -v & gcc -v) ?
$ uname -a
Linux homebridge 5.10.63+ #1488 Thu Nov 18 16:14:04 GMT 2021 armv6l GNU/Linux
$ php -v
PHP 7.4.25 (cli) (built: Oct 23 2021 21:53:50) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
with Zend OPcache v7.4.25, Copyright (c), by Zend Technologies
It looks like reincarnation of https://github.com/swoole/swoole-src/issues/4308
Swoole http server is started at http://127.0.0.1:9501
php: symbol lookup error: /usr/lib/php/20190902/openswoole.so: undefined symbol: __atomic_store_8
php --ri swoole
)?uname -a
&php -v
&gcc -v
) ?It is installed by pecl, OpenSwoole v4.9.1, but it does the same when installed from sources with 4.9.0 (and older versions down to 4.7.1 too).