added python support #97
Workflow file for this run
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: ci | |
on: | |
push: | |
branches: [master] | |
paths: | |
- '.github/workflows/ci.yml' | |
- '*.h' | |
- '*.c' | |
pull_request: | |
branches: [master] | |
paths: | |
- '.github/workflows/ci.yml' | |
- '*.h' | |
- '*.c' | |
concurrency: | |
group: ci-${{ github.ref }} | |
cancel-in-progress: true | |
permissions: | |
contents: read | |
jobs: | |
ubuntu: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: build-test | |
run: | | |
gcc main.c -o ruapu | |
./ruapu | |
- name: build-test-clang | |
run: | | |
clang main.c -o ruapu-clang | |
./ruapu-clang | |
- name: build-test-python | |
run: | | |
pip3 install . | |
python3 -c 'import ruapu; print(ruapu.supports("neon")); print(ruapu.supports(isa="avx"))' | |
macos: | |
runs-on: macos-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: build-test | |
run: | | |
clang main.c -o ruapu | |
./ruapu | |
- name: build-test-python | |
run: | | |
pip3 install . | |
python3 -c 'import ruapu; print(ruapu.supports("neon")); print(ruapu.supports(isa="avx"))' | |
macos-arm64: | |
runs-on: macos-14 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: build-test | |
run: | | |
clang main.c -o ruapu | |
./ruapu | |
- name: build-test-python | |
run: | | |
pip3 install . | |
python3 -c 'import ruapu; print(ruapu.supports("neon")); print(ruapu.supports(isa="avx"))' | |
windows: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ilammy/msvc-dev-cmd@v1 | |
- name: build-test | |
run: | | |
cl.exe /Fe: ruapu.exe main.c | |
.\ruapu.exe | |
- name: build-test-mingw | |
shell: bash | |
run: | | |
gcc main.c -o ruapu-mingw.exe | |
./ruapu-mingw.exe | |
- name: build-test-python | |
run: | | |
pip3 install . | |
python3 -c 'import ruapu; print(ruapu.supports("neon")); print(ruapu.supports(isa="avx"))' | |
qemu: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
arch: [ arm, arm64, mips64le, ppc64le, riscv64, s390x ] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: setup-qemu | |
uses: docker/setup-qemu-action@v3 | |
with: | |
platforms: linux/${{ matrix.arch }} | |
- name: build-test | |
run: | | |
docker run -u root --rm -v $(pwd):/${{ github.workspace }} -w ${{ github.workspace }} --platform linux/${{ matrix.arch }} debian:unstable-slim \ | |
/bin/bash -c "apt update && apt install -y build-essential && gcc main.c -o ruapu && ./ruapu" |