Skip to content

Commit

Permalink
Add macOS support on AppVeyor
Browse files Browse the repository at this point in the history
  • Loading branch information
mayeut committed Mar 7, 2020
1 parent ec42cb6 commit 0226da1
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 25 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Usage
|-----------------|-------|-------|---------|
| Azure Pipelines ||||
| Travis CI ||||
| AppVeyor || ||
| AppVeyor || ||
| CircleCI ||| |

`cibuildwheel` is not intended to run on your development machine. Because it uses system Python from Python.org it will try to install packages globally - not what you expect from a build tool! Instead, isolated CI services like Travis CI, CircleCI, Azure Pipelines and AppVeyor are ideal.
Expand Down
32 changes: 21 additions & 11 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,21 @@
image:
- Ubuntu
- Visual Studio 2015

build_script:
- cmd: "C:\\Python37\\python.exe -m pip install -r requirements-dev.txt"
- sh: "${HOME}/.localpython3.7.4/bin/python3 -m pip install -r requirements-dev.txt"
# the '-u' flag is required so the output is in the correct order.
# See https://github.com/joerick/cibuildwheel/pull/24 for more info.
- cmd: "C:\\Python37\\python.exe -u ./bin/run_tests.py"
- sh: "${HOME}/.localpython3.7.4/bin/python3 ./bin/run_tests.py"
environment:
matrix:
- APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu
APPVEYOR_JOB_NAME: "python37-x64-ubuntu"
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
APPVEYOR_JOB_NAME: "python37-x64-vs2015"
- APPVEYOR_BUILD_WORKER_IMAGE: macos-mojave
APPVEYOR_JOB_NAME: "python37-x64-macos-mojave"

stack: python 3.7

build: off

init:
- cmd: set PATH=C:\Python37;C:\Python37\Scripts;%PATH%

install: python -m pip install -r requirements-dev.txt

# the '-u' flag is required so the output is in the correct order.
# See https://github.com/joerick/cibuildwheel/pull/24 for more info.
test_script: python -u ./bin/run_tests.py
4 changes: 2 additions & 2 deletions docs/setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,9 @@ Commit this file, enable building of your repo on CircleCI, and push.

CircleCI will store the built wheels for you - you can access them from the project console. Check out the CircleCI [docs](https://circleci.com/docs/2.0/configuration-reference/#section=configuration) for more info on this config file.

# AppVeyor [linux/windows] {: #appveyor}
# AppVeyor [linux/mac/windows] {: #appveyor}

To build Linux and Windows wheels on AppVeyor, create an `appveyor.yml` file in your repo.
To build Linux, Mac, and Windows wheels on AppVeyor, create an `appveyor.yml` file in your repo.

> appveyor.yml
Expand Down
28 changes: 17 additions & 11 deletions examples/appveyor-minimal.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
image:
- Ubuntu
- Visual Studio 2015

build_script:
# windows
- cmd: pip3 install cibuildwheel==1.1.0
- cmd: cibuildwheel --output-dir wheelhouse
# linux
- sh: "${HOME}/.localpython3.7.4/bin/python3 -m pip install cibuildwheel==1.1.0"
- sh: "${HOME}/.localpython3.7.4/bin/python3 -m cibuildwheel --output-dir wheelhouse"
environment:
matrix:
- APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu
APPVEYOR_JOB_NAME: "python37-x64-ubuntu"
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
APPVEYOR_JOB_NAME: "python37-x64-vs2015"
- APPVEYOR_BUILD_WORKER_IMAGE: macos-mojave
APPVEYOR_JOB_NAME: "python37-x64-macos-mojave"

stack: python 3.7

init:
- cmd: set PATH=C:\Python37;C:\Python37\Scripts;%PATH%

install: python -m pip install cibuildwheel==1.1.0

build_script: python -m cibuildwheel --output-dir wheelhouse

artifacts:
- path: "wheelhouse\\*.whl"
Expand Down

0 comments on commit 0226da1

Please sign in to comment.