The pkg-config files for libcrypto and libssl claim to be version 1.0.0. This was noticed on the openvpn-devel mailing list when they started requiring OpenSSL 1.0.1 or newer:
https://sourceforge.net/p/openvpn/mailman/message/35785095/ While I don't think their approach of testing specific version numbers is correct, it doesn't hurt to be consistent with what LibreSSL portable reports. This diff is based on what LibreSSL portable does. While here, also remove an old commented-out variable from before the tree was reorganised. Index: lib/libcrypto/generate_pkgconfig.sh =================================================================== RCS file: /cvs/src/lib/libcrypto/generate_pkgconfig.sh,v retrieving revision 1.2 diff -u -p -r1.2 generate_pkgconfig.sh --- lib/libcrypto/generate_pkgconfig.sh 3 Sep 2016 12:42:46 -0000 1.2 +++ lib/libcrypto/generate_pkgconfig.sh 17 Apr 2017 14:32:29 -0000 @@ -50,10 +50,9 @@ if [ ! -w "${objdir}" ]; then exit 1 fi -version_re="s/^#define[[:blank:]]+SHLIB_VERSION_NUMBER[[:blank:]]+\"(.*)\".*/\1/p" -#version_file=${curdir}/src/crypto/opensslv.h +version_re="s/^#define[[:blank:]]+LIBRESSL_VERSION_TEXT[[:blank:]]+\"LibreSSL (.*)\".*/\1/p" version_file=${curdir}/opensslv.h -lib_version=$(sed -nE ${version_re} ${version_file}) +lib_version=$(sed -nE "${version_re}" "${version_file}") # Put -I${includedir} into Cflags so configure script tests like # test -n "`pkg-config --cflags openssl`" @@ -66,8 +65,8 @@ exec_prefix=\${prefix} libdir=\${exec_prefix}/lib includedir=\${prefix}/include -Name: OpenSSL-libcrypto -Description: OpenSSL cryptography library +Name: LibreSSL-libcrypto +Description: LibreSSL cryptography library Version: ${lib_version} Requires: Libs: -L\${libdir} -lcrypto Index: lib/libssl/generate_pkgconfig.sh =================================================================== RCS file: /cvs/src/lib/libssl/generate_pkgconfig.sh,v retrieving revision 1.9 diff -u -p -r1.9 generate_pkgconfig.sh --- lib/libssl/generate_pkgconfig.sh 3 Sep 2016 12:42:42 -0000 1.9 +++ lib/libssl/generate_pkgconfig.sh 17 Apr 2017 14:32:29 -0000 @@ -50,9 +50,9 @@ if [ ! -w "${objdir}" ]; then exit 1 fi -version_re="s/^#define[[:blank:]]+SHLIB_VERSION_NUMBER[[:blank:]]+\"(.*)\".*/\1/p" +version_re="s/^#define[[:blank:]]+LIBRESSL_VERSION_TEXT[[:blank:]]+\"LibreSSL (.*)\".*/\1/p" version_file=${curdir}/../libcrypto/opensslv.h -lib_version=$(sed -nE ${version_re} ${version_file}) +lib_version=$(sed -nE "${version_re}" "${version_file}") # Put -I${includedir} into Cflags so configure script tests like # test -n "`pkg-config --cflags openssl`" @@ -65,7 +65,7 @@ exec_prefix=\${prefix} libdir=\${exec_prefix}/lib includedir=\${prefix}/include -Name: OpenSSL +Name: LibreSSL-libssl Description: Secure Sockets Layer and cryptography libraries Version: ${lib_version} Requires: @@ -81,7 +81,7 @@ exec_prefix=\${prefix} libdir=\${exec_prefix}/lib includedir=\${prefix}/include -Name: OpenSSL +Name: LibreSSL Description: Secure Sockets Layer and cryptography libraries and tools Version: ${lib_version} Requires: