Jan Wilmans <janwilm...@gmail.com> added the comment:
I couldn't get this to work at all, python 3.7 compiled fine, but at the end it reports: ''' *** WARNING: renaming "_ssl" since importing it failed: libssl.so.1.1: cannot open shared object file: No such file or directory *** WARNING: renaming "_hashlib" since importing it failed: libssl.so.1.1: cannot open shared object file: No such file or directory Python build finished successfully! Following modules built successfully but were removed because they could not be imported: _hashlib _ssl Could not build the ssl module! Python requires an OpenSSL 1.0.2 or 1.1 compatible libssl with X509_VERIFY_PARAM_set1_host(). LibreSSL 2.6.4 and earlier do not provide the necessary APIs, https://github.com/libressl-portable/portable/issues/381 ''' But in the end I got it to work like this: ----- install_python3.7.sh ---- #!/bin/bash set -euo pipefail mkdir /tmp/openssl cd /tmp/openssl wget https://www.openssl.org/source/openssl-1.1.1a.tar.gz tar -xvf openssl-1.1.1a.tar.gz cd openssl-1.1.1a ./config --prefix=/usr/local/openssl1.1.1 --openssldir=/usr/local/openssl1.1.1 make make install rm -rf /tmp/opensll echo /usr/local/openssl1.1.1/lib > /etc/ld.so.conf.d/openssl1.1.1.conf ldconfig mkdir /tmp/python37 wget https://www.python.org/ftp/python/3.7.3/Python-3.7.3.tgz tar xfz Python-3.7.3.tgz cd Python-3.7.3 ./configure --with-ensurepip=yes --with-openssl=/usr/local/openssl1.1.1 CFLAGS="-I/usr/local/openssl1.1.1/include" LDFLAGS="-L/usr/local/openssl1.1.1/lib" CXX=/usr/bin/g++ make make install rm -rf /tmp/python37 ldconfig -------------------- This important pieces are: echo /usr/local/openssl1.1.1/lib > /etc/ld.so.conf.d/openssl1.1.1.conf ldconfig to make it find the .so to load it at runtime and ./configure --with-ensurepip=yes --with-openssl=/usr/local/openssl1.1.1 CFLAGS="-I/usr/local/openssl1.1.1/include" LDFLAGS="-L/usr/local/openssl1.1.1/lib" CXX=/usr/bin/g++ specifying the non-standard openssl-version specifically. ---------- nosy: +Jan Wilmans _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue34028> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com