PHP配置Configure报错:Please reinstall the libzip distribution
发生情景:
php执行配置命令configure时,报如下错误:
checking for libzip... not found
configure: error: Please reinstall the libzip distribution
错误含义:
没有找到libzip
请重新安装libzip的dev包。
尝试解决:
(1)移除旧的libzip:
yum remove libzip
(2)安装新版本:
curl-O https://libzip.org/download/libzip-1.5.1.tar.gz
tar -zxvf libzip-1.5.1.tar.gz
cd libzip-1.5.1
mkdir build
cd build
cmake ..
make && make install
注意:如果提示cmake版本过低,需新版本,则需要重新安装cmake。
cmake安装方法
wget https://github.com/Kitware/CMake/releases/download/v3.14.3/cmake-3.14.3.tar.gz
tar -zxvf cmake-3.14.3.tar.gz
cd cmake-3.14.3
./bootstrap
make && make instal
注意:低版本的不需要cmake,例如1.2版本:
curl-O https://nih.at/libzip/libzip-1.2.0.tar.gz
tar -zxvf libzip-1.2.0.tar.gz
cd libzip-1.2.0
./configure
make && make install