This topic describes the process to set up a Python virtual environment.
Procedure
- Clone the cryptography and maturin
repositories:
$ git clone git@github.com:pyca/cryptography.git
$ git clone git@github.com:PyO3/maturin.git
- Set up the C/C++ compilers, along with the appropriate compiler flags:
$ export CC="ibm-clang_r"
$ export CXX="ibm-clang++_r"
$ export CFLAGS="-O3 -fPIC -fno-lto"
$ export CXXFLAGS="-O3 -fPIC -fno-lto"
- Set up a virtual environment for the cryptography build
with:
$ python3 –m venv myenv
$ source myenv/bin/activate && cd cryptography
- From inside the repo, use pip to install dependencies and the
package:
$ pip3 install setuptools wheel cffi
$ pip3 install –vvv /path/to/maturin
$ pip3 install -–no-build-isolation . -vvv