configure: error: OpenSSL library not found.
时间: 2023-11-14 18:04:39 浏览: 116
To resolve the "OpenSSL library not found" error, you can follow these steps:
1. Make sure OpenSSL is installed on your system. If not, you will need to install it. The installation process varies depending on your operating system.
- For Ubuntu/Debian-based systems:
```
sudo apt-get install libssl-dev
```
- For CentOS/Fedora systems:
```
sudo dnf install openssl-devel
```
- For macOS systems with Homebrew:
```
brew install openssl
```
2. Once OpenSSL is installed, you may need to specify the location of the OpenSSL library and header files manually. You can do this by setting the `OPENSSL_CFLAGS` and `OPENSSL_LIBS` environment variables when running the configure script or compiling your code.
For example, if the OpenSSL library is installed in the default location, you can run the configure script like this:
```
OPENSSL_CFLAGS="-I/usr/include/openssl" OPENSSL_LIBS="-L/usr/lib -lssl -lcrypto" ./configure
```
Make sure to adjust the paths if your OpenSSL installation is in a different location.
3. After setting the environment variables, run the configure script again and check if the error is resolved.
If you still encounter any issues, please provide more details about your system and the specific software you are trying to compile, so that I can assist you further.