Skip to content

add macos_x86_64 action #1

add macos_x86_64 action

add macos_x86_64 action #1

Workflow file for this run

name: Build wheels on Macos-x86_64
on:
push:
branches:
- action
pull_request:
branches:
- action
jobs:
build_wheels_macos_x86_64:
name: Build wheel for ${{ matrix.python }}-${{ matrix.buildplat[1] }}-${{ matrix.buildplat[2] }}
runs-on: ${{ matrix.buildplat[0] }}
strategy:
fail-fast: false
matrix:
buildplat:
- [macos-latest, macosx, x86_64]
python: ["cp39"]
steps:
- name: Checkout repo
uses: actions/checkout@v3
with:
submodules: recursive
- name: Set up Python
uses: actions/setup-python@v3
with:
python-version: '3.x'
- name: Build wheels on macos
if: ${{ matrix.buildplat[1] == 'macosx' && matrix.buildplat[2] == 'x86_64' }}
uses: pypa/[email protected]
env:
CIBW_BUILD: ${{ matrix.python }}-${{ matrix.buildplat[1] }}*
CIBW_BUILD_VERBOSITY: 3
CIBW_ENVIRONMENT: FFLAGS='-fPIC -fallow-argument-mismatch' SETUPTOOLS_USE_DISTUTILS=stdlib CPP='gcc -E'
CIBW_ENVIRONMENT_PASS_LINUX: FFLAGS SETUPTOOLS_USE_DISTUTILS CPP
CIBW_ARCHS_MACOS: "x86_64"
CIBW_BEFORE_BUILD: |
brew install gfortran && brew unlink gfortran && brew link gfortran
brew install openblas lapack
- name: Setup tmate session
if: ${{ failure() }}
uses: mxschmitt/action-tmate@v3
timeout-minutes: 0
- uses: actions/upload-artifact@v3
with:
name: ${{ matrix.python }}-${{ matrix.buildplat[1] }}-${{ matrix.buildplat[2] }}
path: ./wheelhouse/*.whl