-
-
Save tobiase/d2c48cf36a85447a060a18f2bd63a8a1 to your computer and use it in GitHub Desktop.
Script to solve python compilation with ssl on Arch Linux
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # http://stackoverflow.com/questions/23548188/how-do-i-compile-python-3-4-with-custom-openssl | |
| openssl_version="openssl-1.0.2g" | |
| openssl_package="${openssl_version}.tar.gz" | |
| openssl_path="/opt/$openssl_version" | |
| curl https://www.openssl.org/source/$openssl_package | tar xz && cd $openssl_version && ./config shared --prefix=$openssl_path && make -j8 && sudo make install | |
| export LDFLAGS="-L$openssl_path/lib -Wl,-rpath=$openssl_path/lib" | |
| export LD_LIBRARY_PATH="$openssl_path/lib" | |
| export CPPFLAGS="-I$openssl_path/include/openssl" | |
| # pythonbrew install 2.7.8 | |
| pyenv install 2.7.8 | |
| pyenv local 2.7.8 | |
| exec $SHELL | |
| python -c 'import ssl; print(ssl.OPENSSL_VERSION)' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment