|
7 | 7 | name: Build wheels for ${{ matrix.os }} |
8 | 8 | runs-on: ${{ matrix.os }} |
9 | 9 | strategy: |
| 10 | + fail-fast: false |
10 | 11 | matrix: |
11 | 12 | # os: [ubuntu-20.04, windows-2019, macOS-10.15] |
12 | 13 | os: [ubuntu-20.04, macOS-10.15] |
13 | 14 |
|
14 | 15 | steps: |
15 | | - - uses: actions/checkout@v2 |
| 16 | + - uses: actions/checkout@v3 |
16 | 17 | - uses: actions/setup-python@v2 |
17 | 18 |
|
18 | | - - name: Install cibuildwheel |
19 | | - run: python -m pip install cibuildwheel==1.10.0 |
20 | 19 | - name: Build wheels |
21 | | - run: python -m cibuildwheel --output-dir wheelhouse |
| 20 | + uses: pypa/cibuildwheel@v2.3.1 |
22 | 21 | env: |
23 | | - CIBW_BUILD: cp37-* cp38-* |
| 22 | + CIBW_BUILD: cp37-* cp38-* cp39-* cp310-* |
| 23 | + CIBW_SKIP: "*-win32 *-manylinux_i686 *-musllinux_*" |
| 24 | + CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014 |
24 | 25 | CIBW_BEFORE_ALL_LINUX: bin/cibw_before_build_linux.sh |
25 | 26 | CIBW_BEFORE_ALL_MACOS: bin/cibw_before_build_macosx.sh |
26 | | - # There are problems with both older and newer cython versions... |
27 | | - CIBW_BEFORE_BUILD: pip install numpy cython==0.27.3 |
| 27 | + CIBW_BEFORE_BUILD: pip install numpy cython |
28 | 28 | CIBW_ENVIRONMENT: > |
29 | 29 | C_INCLUDE_PATH=$(pwd)/.local/include/ |
30 | 30 | LIBRARY_PATH=$(pwd)/.local/lib/ |
31 | 31 | LD_LIBRARY_PATH=$(pwd)/.local/lib:$LD_LIBRARY_PATH |
| 32 | + CIBW_TEST_COMMAND: python -c 'import flint; print(str(flint.fmpz(2)))' |
| 33 | + |
32 | 34 | - uses: actions/upload-artifact@v2 |
33 | 35 | with: |
34 | 36 | path: wheelhouse/*.whl |
| 37 | + |
| 38 | + test_wheels: |
| 39 | + needs: build_wheels |
| 40 | + name: Test ${{ matrix.python-version }} wheel on ${{ matrix.os }} |
| 41 | + runs-on: ${{ matrix.os }} |
| 42 | + strategy: |
| 43 | + fail-fast: false |
| 44 | + matrix: |
| 45 | + os: [ubuntu-20.04, macOS-10.15] |
| 46 | + python-version: ['3.7', '3.8', '3.9', '3.10'] |
| 47 | + |
| 48 | + steps: |
| 49 | + - uses: actions/checkout@v2 |
| 50 | + - uses: actions/setup-python@v2 |
| 51 | + with: |
| 52 | + python-version: ${{ matrix.python-version }} |
| 53 | + - uses: actions/download-artifact@v3 |
| 54 | + with: |
| 55 | + name: artifact |
| 56 | + path: wheelhouse |
| 57 | + - run: python -m venv venv |
| 58 | + - run: venv/bin/pip install -U pip |
| 59 | + - run: venv/bin/pip install --find-links wheelhouse python_flint |
| 60 | + - run: venv/bin/python test/test.py |
0 commit comments