From ecf7425b2d950455d3bd3d0a50e62a85c41e3d79 Mon Sep 17 00:00:00 2001 From: Alex Gaynor Date: Sun, 19 Mar 2017 23:10:52 -0400 Subject: Update wheel scripts to match what Jenkins has (#3459) * Include python3.6 in the macOS wheel script * Pull in changes from Jenkins * For Windows as well --- .jenkins/mac-wheel.sh | 21 ++++++++++++++++----- .jenkins/windows-wheel.bat | 17 ++++++++++++++++- 2 files changed, 32 insertions(+), 6 deletions(-) (limited to '.jenkins') diff --git a/.jenkins/mac-wheel.sh b/.jenkins/mac-wheel.sh index 3a6bf64b..4056ccc7 100644 --- a/.jenkins/mac-wheel.sh +++ b/.jenkins/mac-wheel.sh @@ -1,9 +1,13 @@ #!/bin/bash -xe -# output the list of things we've installed as a point in time check of how up to date the builder is + +# output the list of things we've installed as a point in time check of how up +# to date the builder is /usr/sbin/system_profiler SPInstallHistoryDataType -# Jenkins logs in as a non-interactive shell, so we don't even have /usr/local/bin in PATH +# Jenkins logs in as a non-interactive shell, so we don't even have +# /usr/local/bin in PATH export PATH=/usr/local/bin:$PATH -# pyenv is nothing but trouble with non-interactive shells so we can't eval "$(pyenv init -)" +# pyenv is nothing but trouble with non-interactive shells so we can't +# eval "$(pyenv init -)" export PATH="/Users/jenkins/.pyenv/shims:${PATH}" export PYENV_SHELL=bash @@ -28,6 +32,9 @@ if [[ "${label}" == "10.10" ]]; then py35) PYTHON=python3.5 ;; + py36) + PYTHON=python3.6 + ;; pypy) PYTHON=pypy ;; @@ -46,14 +53,18 @@ else py35) PYTHON=/Library/Frameworks/Python.framework/Versions/3.5/bin/python3.5 ;; + py36) + PYTHON=/Library/Frameworks/Python.framework/Versions/3.6/bin/python3.6 + ;; esac fi printenv virtualenv .venv -p $PYTHON source .venv/bin/activate -pip install -U wheel # upgrade wheel to latest before we use it to build the wheel -CRYPTOGRAPHY_OSX_NO_LINK_FLAGS="1" LDFLAGS="/usr/local/opt/openssl/lib/libcrypto.a /usr/local/opt/openssl/lib/libssl.a" CFLAGS="-I/usr/local/opt/openssl/include" pip wheel cryptography --wheel-dir=wheelhouse --no-use-wheel +# upgrade wheel to latest before we use it to build the wheel +pip install -U wheel +CRYPTOGRAPHY_OSX_NO_LINK_FLAGS="1" LDFLAGS="/usr/local/opt/openssl@1.1/lib/libcrypto.a /usr/local/opt/openssl@1.1/lib/libssl.a" CFLAGS="-I/usr/local/opt/openssl@1.1/include" pip wheel cryptography --wheel-dir=wheelhouse --no-use-wheel pip install -f wheelhouse cryptography --no-index python -c "from cryptography.hazmat.backends.openssl.backend import backend;print('Loaded: ' + backend.openssl_version_text());print('Linked Against: ' + backend._ffi.string(backend._lib.OPENSSL_VERSION_TEXT).decode('ascii'))" otool -L `find .venv -name '_openssl*.so'` diff --git a/.jenkins/windows-wheel.bat b/.jenkins/windows-wheel.bat index 17883e3e..356226a7 100644 --- a/.jenkins/windows-wheel.bat +++ b/.jenkins/windows-wheel.bat @@ -1,5 +1,6 @@ wmic qfe @set PATH="C:\Python27";"C:\Python27\Scripts";%PATH% +@set CRYPTOGRAPHY_WINDOWS_LINK_OPENSSL110=1 SET if "%TOXENV%" == "py26" ( @set PYTHON="C:\Python26\python.exe" @@ -15,6 +16,20 @@ if "%TOXENV%" == "py34" ( ) if "%TOXENV%" == "py35" ( @set PYTHON="C:\Python35\python.exe" +) +if "%TOXENV%" == "py36" ( + @set PYTHON="C:\Python36\python.exe" +) + +@set py35orabove=true + +if not "%TOXENV%" == "py35" ( + if not "%TOXENV%" == "py36" ( + @set py35orabove=false + ) +) + +if "%py35orabove%" == "true" ( if %label% == windows ( @set INCLUDE="C:\OpenSSL-Win32-2015\include";%INCLUDE% @set LIB="C:\OpenSSL-Win32-2015\lib";%LIB% @@ -39,4 +54,4 @@ pip wheel cryptography --wheel-dir=wheelhouse --no-use-wheel for %%x in (wheelhouse\*.whl) do ( pip install %%x ) -python -c "from cryptography.hazmat.backends.openssl.backend import backend;print('Loaded: ' + backend.openssl_version_text());print('Linked Against: ' + backend._ffi.string(backend._lib.OPENSSL_VERSION_TEXT).decode('ascii'))" +python -c "from cryptography.hazmat.backends.openssl.backend import backend;print('Loaded: ' + backend.openssl_version_text());print('Linked Against: ' + backend._ffi.string(backend._lib.OPENSSL_VERSION_TEXT).decode('ascii'))" \ No newline at end of file -- cgit v1.2.3