安装php-sodium错误Debian10.9
root@debian:~# pecl install libsodium
WARNING: channel "pecl.php.net" has updated its protocols, use "pecl channel-upd ate pecl.php.net" to update
PHP Fatal error:Uncaught Error: Call to undefined function popen() in /usr/loc al/php/lib/php/OS/Guess.php:254
Stack trace:
#0 /usr/local/php/lib/php/OS/Guess.php(152): OS_Guess->_detectGlibcVersion()
#1 /usr/local/php/lib/php/OS/Guess.php(107): OS_Guess->parseSignature()
#2 /usr/local/php/lib/php/PEAR/Dependency2.php(109): OS_Guess->__construct()
#3 /usr/local/php/lib/php/PEAR/Downloader.php(277): PEAR_Dependency2->__construc t()
#4 /usr/local/php/lib/php/PEAR/Downloader.php(556): PEAR_Downloader->getDependen cy2Object()
#5 /usr/local/php/lib/php/PEAR/Downloader.php(458): PEAR_Downloader->analyzeDepe ndencies()
#6 /usr/local/php/lib/php/PEAR/Command/Install.php(671): PEAR_Downloader->downlo ad()
#7 /usr/local/php/lib/php/PEAR/Command/Common.php(270): PEAR_Command_Install->do Install()
#8 /usr/local/php/lib/php/pearcmd.php(317): PEAR_Command_Common->run()
#9 /usr/local/php/lib/php/peclcmd.php(32): require_once('...')
#10 {main}
thrown in /usr/local/php/lib/php/OS/Guess.php on line 254
root@debian:~# /etc/init.d/php-fpm restart
Gracefully shutting down php-fpm . done
Starting php-fpm NOTICE: PHP message: PHP Warning:PHP S tartup: Unable to load dynamic library 'sodium' (tried: /usr/local/php/lib/php/e xtensions/no-debug-non-zts-20200930/sodium (/usr/local/php/lib/php/extensions/no -debug-non-zts-20200930/sodium: cannot open shared object file: No such file or directory), /usr/local/php/lib/php/extensions/no-debug-non-zts-20200930/sodium.s o (/usr/local/php/lib/php/extensions/no-debug-non-zts-20200930/sodium.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
done
root@debian:~# ^C
安装不了, apt-get install libsodium-dev,Debian10.9
现在微信支付API的V3版支付接口都需要sodium,建议默认安装上
root@debian:~# apt-get install libsodium-dev
正在读取软件包列表... 完成
正在分析软件包的依赖关系树
正在读取状态信息... 完成
下列【新】软件包将被安装:
libsodium-dev
升级了 0 个软件包,新安装了 1 个软件包,要卸载 0 个软件包,有 0 个软件包未被升级 。
需要下载 176 kB 的归档。
解压缩后会消耗 796 kB 的额外空间。
获取:1 http://deb.debian.org/debian buster/main amd64 libsodium-dev amd64 1.0.17 -1
已下载 176 kB,耗时 1秒 (168 kB/s)
正在选中未选择的软件包 libsodium-dev:amd64。
(正在读取数据库 ... 系统当前共安装有 113631 个文件和目录。)
准备解压 .../libsodium-dev_1.0.17-1_amd64.deb...
正在解压 libsodium-dev:amd64 (1.0.17-1) ...
正在设置 libsodium-dev:amd64 (1.0.17-1) ...
root@debian:~# pecl install libsodium
WARNING: channel "pecl.php.net" has updated its protocols, use "pecl channel-upd ate pecl.php.net" to update
PHP Fatal error:Uncaught Error: Call to undefined function popen() in /usr/loc al/php/lib/php/OS/Guess.php:254
Stack trace:
#0 /usr/local/php/lib/php/OS/Guess.php(152): OS_Guess->_detectGlibcVersion()
#1 /usr/local/php/lib/php/OS/Guess.php(107): OS_Guess->parseSignature()
#2 /usr/local/php/lib/php/PEAR/Dependency2.php(109): OS_Guess->__construct()
#3 /usr/local/php/lib/php/PEAR/Downloader.php(277): PEAR_Dependency2->__construc t()
#4 /usr/local/php/lib/php/PEAR/Downloader.php(556): PEAR_Downloader->getDependen cy2Object()
#5 /usr/local/php/lib/php/PEAR/Downloader.php(458): PEAR_Downloader->analyzeDepe ndencies()
#6 /usr/local/php/lib/php/PEAR/Command/Install.php(671): PEAR_Downloader->downlo ad()
#7 /usr/local/php/lib/php/PEAR/Command/Common.php(270): PEAR_Command_Install->do Install()
#8 /usr/local/php/lib/php/pearcmd.php(317): PEAR_Command_Common->run()
#9 /usr/local/php/lib/php/peclcmd.php(32): require_once('...')
#10 {main}
thrown in /usr/local/php/lib/php/OS/Guess.php on line 254
root@debian:~# /etc/init.d/php-fpm restart
Gracefully shutting down php-fpm . done
Starting php-fpm NOTICE: PHP message: PHP Warning:PHP S tartup: Unable to load dynamic library 'sodium' (tried: /usr/local/php/lib/php/e xtensions/no-debug-non-zts-20200930/sodium (/usr/local/php/lib/php/extensions/no -debug-non-zts-20200930/sodium: cannot open shared object file: No such file or directory), /usr/local/php/lib/php/extensions/no-debug-non-zts-20200930/sodium.s o (/usr/local/php/lib/php/extensions/no-debug-non-zts-20200930/sodium.so: cannot open shared object file: No such file or directory)) in Unknown on line 0
done
wget http://pecl.php.net/get/libsodium-2.0.23.tgz
单独下载2.2.23的安装好用了,php8.0.6,还是得手工 erer 发表于 2021-6-5 18:52
root@debian:~# apt-get install libsodium-dev
正在读取软件包列表... 完成
正在分析软件包的依赖关系树
popen、readlink 函数从php禁用函数里删除就可以正常使用pecl命令安装了
apt-get install libsodium-dev 正常安装,没有报错 apt-get install libsodium-dev 自动安装的是1.0.17
我的php8.0.6 erer 发表于 2021-6-6 11:16
apt-get install libsodium-dev 自动安装的是1.0.17
我的php8.0.6
每个debian版本的各种依赖包版本都不一样
debian 10对应的libsodium-dev版本是1.0.17一点问题都没有 licess 发表于 2021-6-6 19:59
每个debian版本的各种依赖包版本都不一样
debian 10对应的libsodium-dev版本是1.0.17一点问题都没有 ...
假如说现在我需要安装curl ,但是我现在怎么知道 curl 需要那些依赖??? sunny123456 发表于 2021-6-25 16:50
假如说现在我需要安装curl ,但是我现在怎么知道 curl 需要那些依赖???
不管是系统的curl还是php-curl默认都自带,php-curl这都是最最基本的模块 licess 发表于 2021-6-25 21:23
不管是系统的curl还是php-curl默认都自带,php-curl这都是最最基本的模块
我举个例子,比方说我现在安装某个 扩展,但是我不知道还需要安装那些他的依赖项, sunny123456 发表于 2021-6-26 10:31
我举个例子,比方说我现在安装某个 扩展,但是我不知道还需要安装那些他的依赖项, ...
php官网每个模块/扩展的文档里都有具体说明 licess 发表于 2021-6-26 17:35
php官网每个模块/扩展的文档里都有具体说明
好的,我去看下,谢谢
页:
[1]