I compiled openssl from github: https://github.com/openssl/openssl.
Examining the Makefile generated (by ./config
) the default install directory is /usr/local/lib64
.
However, on RHEL, this directory is not in the load library path. The following worked for me on RHEL 7.9:
Edit ld.conf file to add a line containing /usr/local/lib64 :
$ sudo nano /etc/ld.so.conf.d/lib.conf
/usr/local/lib64
Sometimes, openssl is installed at /usr/local/ssl, and a file like /etc/ld.so.conf.d/openssl.conf is created. The path to libraries can be added here:
$ sudo nano /etc/ld.so.conf.d/openssl.conf
/usr/local/ssl/lib64
After adding the path to the file, update the library paths
$ sudo ldconfig
Sanity check
$ openssl version
Output: OpenSSL 3.0.0-alpha11 28 jan 2021 (Library: OpenSSL 3.0.0-alpha11 28 jan 2021)