Build Python wheels for windows on travis (#160)

* upgrade for windows on travis

* Install python on travis windows, update readme, update tests

* update readme, travis config and clean code

* install python inside cibuildwheel run

* use register to get python path

* fixes from review

* fix pip version

* use nuget for instal python

* clean code

* Update cibuildwheel/windows.py

Co-Authored-By: Joe Rickerby <joerick@mac.com>

* fixes from review

* Final bits of tidy up
This commit is contained in:
Grzegorz Bokota
2019-10-23 21:53:10 +01:00
committed by Joe Rickerby
co-authored by Joe Rickerby
parent 4f705b7cc9
commit 80974e5b39
5 changed files with 98 additions and 24 deletions
+6 -2
View File
@@ -6,7 +6,8 @@ This file is added to the PYTHONPATH in the test runner at bin/run_test.py.
import subprocess, sys, os
IS_RUNNING_ON_AZURE = os.path.exists('C:\\hostedtoolcache')
IS_WINDOWS_RUNNING_ON_AZURE = os.path.exists('C:\\hostedtoolcache')
IS_WINDOWS_RUNNING_ON_TRAVIS = os.environ.get('TRAVIS_OS_NAME') == 'windows'
def cibuildwheel_get_build_identifiers(project_path, env=None):
@@ -97,9 +98,12 @@ def expected_wheels(package_name, package_version):
else:
raise Exception('unsupported platform')
if IS_RUNNING_ON_AZURE:
if IS_WINDOWS_RUNNING_ON_AZURE:
# Python 3.4 isn't supported on Azure.
templates = [t for t in templates if '-cp34-' not in t]
if IS_WINDOWS_RUNNING_ON_TRAVIS:
# Python 2.7 and 3.4 isn't supported on Travis.
templates = [t for t in templates if '-cp27-' not in t and '-cp34-' not in t]
return [filename.format(package_name=package_name, package_version=package_version)
for filename in templates]