因为测试程序的需求,需要将一台阿里云香港服务器由PHP8.0换成PHP8.1版本,服务器系统为Debian11,在安装PHP8.1过程出现错误提示 No package 'libwebp' found 安装失败,详细提示如下: Configuring extensionschecking for io.h... nochecking for strtoll... yeschecking for atoll... yeschecking whether to build with LIBXML support... yeschecking for libxml-2.0 >= 2.9.0... yeschecking for OpenSSL support... yeschecking for Kerberos support... nochecking whether to use system default cipher list instead of hardcoded value... nochecking for openssl >= 1.0.2... yeschecking for RAND_egd... nochecking for PCRE library to use... bundledchecking whether to enable PCRE JIT functionality... yeschecking whether Intel CET is enabled... nochecking whether to enable the SQLite3 extension... yeschecking for sqlite3 >= 3.7.7... yeschecking for sqlite3_errstr in -lsqlite3... yeschecking for sqlite3_expanded_sql in -lsqlite3... yeschecking for sqlite3_load_extension in -lsqlite3... yeschecking for ZLIB support... yeschecking for zlib >= 1.2.0.4... yeschecking whether to enable bc style precision math functions... yeschecking for BZip2 support... nochecking whether to enable calendar conversion support... nochecking whether to enable ctype functions... yeschecking for cURL support... yeschecking for libcurl >= 7.29.0... yeschecking for SSL support in libcurl... yeschecking for libcurl linked against old openssl... nochecking for curl_easy_perform in -lcurl... yeschecking for QDBM support... nochecking for GDBM support... nochecking for NDBM support... nochecking for TCADB support... nochecking for LMDB support... nochecking for Berkeley DB4 support... nochecking for Berkeley DB3 support... nochecking for Berkeley DB2 support... nochecking for DB1 support... nochecking for DBM support... nochecking for CDB support... nochecking for INI File support... nochecking for FlatFile support... nochecking whether to enable DBA interface... nochecking whether to enable dl-test extension... nochecking whether to enable DOM support... yeschecking for libxml-2.0 >= 2.9.0... yeschecking whether to build with Enchant support... nochecking whether to enable EXIF (metadata from images) support... yeschecking for FFI support... nochecking for fileinfo support... nochecking whether to enable input filter support... yeschecking whether to enable FTP support... yeschecking whether to explicitly enable FTP SSL support... nochecking for openssl >= 1.0.2... yeschecking for GD support... yeschecking for external libgd... nochecking for libavif... nochecking for libwebp... yeschecking for libjpeg... yeschecking for libXpm... nochecking for FreeType 2... yeschecking whether to enable JIS-mapped Japanese font support in GD... nochecking for fabsf... yeschecking for floorf... yeschecking for zlib... yeschecking for libpng... yeschecking for libwebp >= 0.2.0... noconfigure: error: Package requirements (libwebp >= 0.2.0) were not met:No package 'libwebp' foundConsider adjusting the PKG_CONFIG_PATH environment variable if youinstalled software in a non-standard prefix.Alternatively, you may set the environment variables WEBP_CFLAGSand WEBP_LIBS to avoid the need to call pkg-config.See the pkg-config man page for more details.make: *** No targets specified and no makefile found. Stop.make: *** No rule to make target 'install'. Stop.PHP install failed, Please Contact the author!KilledImage

从提示可以判断出是由于缺少了libwep安装包导致的,需要先手动安装好libwebp才能继续安装PHP8.1,通过搜索找到解决方法。 Debian/Ubuntu系统 登录root,依次执行下面的命令: 1、更新安装源 apt-get update2、安装libwebp及依赖 apt-get install libwebp-devRedhat/Centos7版本系列系统: 1、下载libwebp安装依赖包 wget http://mirror.centos.org/centos/ ... -7.el7.i686.rpmwget http://mirror.centos.org/centos/ ... .0-7.el7.x86_64.rpm2、安装libwebp及依赖包 rpm -ivh libwebp*Redhat/Centos8版本系列系统: 1、下载libwebp安装依赖包 wget https://vault.centos.org/centos/ ... .el8.x86_64.rpmwget https://vault.centos.org/centos/ ... .0.0-5.el8.i686.rpm2、安装libwebp及依赖包 rpm -ivh libwebp* 安装好libwebp再安装PHP8.1就没有问题了。
|