PHP 7.4 configure error: Package requirements (sqlite3 > 3.7.4) were not met
Question
When compiling php-7.4.6 on Linux, run the command ./configure --prefix=/develop/
, but the following error occurs.
checking for sqlite3 > 3.7.4... no
configure: error: Package requirements (sqlite3 > 3.7.4) were not met:
Package 'sqlite3', required by 'virtual:world', not found
Consider adjusting the PKG_CONFIG_PATH environment variable if you
installed software in a non-standard prefix.
Alternatively, you may set the environment variables SQLITE_CFLAGS
and SQLITE_LIBS to avoid the need to call pkg-config.
See the pkg-config man page for more details.
Solution
It requires sqlite-devel
package, which can be installed manually or using the command line.
1. Install manually
On the web page https://pkgs.org/search/?q=sqlite-devel, find the sqlite-devel
version that matches your operating system, and download and install it.
2. Install using command line
Ubuntu / Debian:
sudo apt-get install libsqlite3-dev
RHEL / CentOS:
sudo yum install sqlite-devel