Skip to content

Build codecs from source on Windows #79

Build codecs from source on Windows

Build codecs from source on Windows #79

Workflow file for this run

name: build
on: [push, pull_request]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: macos-latest
arch: arm64
shell: bash
- os: macos-latest
arch: x86_64
shell: bash
- os: ubuntu-latest
arch: aarch64
shell: bash
- os: ubuntu-latest
arch: i686
shell: bash
- os: ubuntu-latest
arch: x86_64
shell: bash
- os: windows-latest
arch: AMD64
shell: 'msys2 {0}'
- os: windows-latest
arch: x86
shell: 'msys2 {0}'
defaults:
run:
shell: ${{ matrix.shell }}
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install qemu (linux)
if: matrix.os == 'ubuntu-latest'
uses: docker/setup-qemu-action@v2
- name: Install msys2 (Windows)
if: matrix.os == 'windows-latest'
uses: msys2/setup-msys2@v2
with:
install: base-devel mingw-w64-x86_64-gcc mingw-w64-x86_64-nasm
path-type: inherit
- name: Build codecs
env:
CIBW_ARCHS: ${{ matrix.arch }}
CIBW_BEFORE_BUILD: python scripts/build-codecs.py /tmp/vendor
CIBW_BEFORE_BUILD_WINDOWS: python scripts\build-codecs.py C:\cibw\vendor
CIBW_BUILD: cp38-*
CIBW_SKIP: "*musllinux*"
CIBW_TEST_COMMAND: python -c "import dummy"
run: |
pip install cibuildwheel
cibuildwheel --output-dir output
rm -f output/*.whl
shell: bash
- name: Upload codecs
uses: actions/upload-artifact@v3
with:
name: output
path: output/