Python build #42
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Python build | |
on: workflow_dispatch | |
jobs: | |
build: | |
strategy: | |
matrix: | |
python-version: [ '3.7', '3.8', '3.9', '3.10', '3.11', '3.12', '3.13' ] | |
os: ['windows-latest', 'macos-latest'] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python 3.10 | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install wheel build | |
python -m build | |
- name: Upload a Build Artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: "elkai-${{ matrix.os }}-${{ matrix.python-version }}.whl" | |
path: dist/*.whl | |
build-linux: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Python wheels manylinux build | |
uses: pypa/[email protected] | |
env: | |
CIBW_ARCHS: auto64 # only 64-bit | |
CIBW_SKIP: "pp* *-musllinux_* cp36*" # no PyPy builds | |
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014 # centos 7 | |
CIBW_BEFORE_BUILD: "python -m pip install build" | |
# CIBW_BEFORE_BUILD: "python -m pip install scikit-build cmake && python -c \"import skbuild; f = skbuild.__file__.replace('__init__.py', 'resources/cmake/FindPythonExtensions.cmake'); ff = open(f, 'w+'); content = ff.read(); ff.truncate(); ff.write(content.replace('NOT _is_non_lib', 'FALSE'))\"" | |
- name: Upload a Build Artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: "elkai-manylinux" | |
path: wheelhouse/*.whl |