| 1 |
--- |
| 2 |
name: build |
| 3 |
|
| 4 |
on: |
| 5 |
push: |
| 6 |
branches: [master] |
| 7 |
pull_request: |
| 8 |
branches: [master] |
| 9 |
|
| 10 |
workflow_dispatch: |
| 11 |
|
| 12 |
jobs: |
| 13 |
default: |
| 14 |
runs-on: ubuntu-latest |
| 15 |
strategy: |
| 16 |
matrix: |
| 17 |
compiler: [gcc, clang] |
| 18 |
buildtype: [debug, release] |
| 19 |
container: |
| 20 |
image: ghcr.io/linux-nvme/debian.python:latest |
| 21 |
steps: |
| 22 |
- uses: actions/checkout@v5 |
| 23 |
- name: build |
| 24 |
run: | |
| 25 |
scripts/build.sh -b ${{ matrix.buildtype }} -c ${{ matrix.compiler }} -x |
| 26 |
- uses: actions/upload-artifact@v5 |
| 27 |
name: upload logs |
| 28 |
if: failure() |
| 29 |
with: |
| 30 |
name: logs files |
| 31 |
path: | |
| 32 |
.build-ci/meson-logs/*.txt |
| 33 |
|
| 34 |
cross: |
| 35 |
runs-on: ubuntu-latest |
| 36 |
strategy: |
| 37 |
matrix: |
| 38 |
include: |
| 39 |
- arch: armhf |
| 40 |
- arch: s390x |
| 41 |
- arch: ppc64le |
| 42 |
steps: |
| 43 |
- uses: actions/checkout@v5 |
| 44 |
- name: enable foreign arch |
| 45 |
uses: dbhi/qus/action@main |
| 46 |
- name: Login to GitHub Container Registry |
| 47 |
uses: docker/login-action@v3 |
| 48 |
with: |
| 49 |
registry: ghcr.io |
| 50 |
username: ${{ github.actor }} |
| 51 |
password: ${{ secrets.GITHUB_TOKEN }} |
| 52 |
- name: compile and run unit tests |
| 53 |
uses: mosteo-actions/docker-run@v2 |
| 54 |
with: |
| 55 |
image: ghcr.io/linux-nvme/ubuntu-cross-${{ matrix.arch }}:latest |
| 56 |
guest-dir: /build |
| 57 |
host-dir: ${{ github.workspace }} |
| 58 |
command: | |
| 59 |
scripts/build.sh -b release -c gcc -t ${{ matrix.arch }} cross |
| 60 |
params: "--platform linux/amd64" |
| 61 |
pull-params: "--platform linux/amd64" |
| 62 |
- uses: actions/upload-artifact@v5 |
| 63 |
name: upload logs |
| 64 |
if: failure() |
| 65 |
with: |
| 66 |
name: log files |
| 67 |
path: | |
| 68 |
.build-ci/meson-logs/*.txt |
| 69 |
|
| 70 |
libdbus: |
| 71 |
name: libdbus |
| 72 |
runs-on: ubuntu-latest |
| 73 |
container: |
| 74 |
image: ghcr.io/linux-nvme/debian:latest |
| 75 |
steps: |
| 76 |
- uses: actions/checkout@v5 |
| 77 |
- name: build |
| 78 |
run: | |
| 79 |
scripts/build.sh -b release -c gcc libdbus |
| 80 |
- uses: actions/upload-artifact@v5 |
| 81 |
name: upload logs |
| 82 |
if: failure() |
| 83 |
with: |
| 84 |
name: log files |
| 85 |
path: | |
| 86 |
.build-ci/meson-logs/*.txt |
| 87 |
|
| 88 |
fallback-shared-libraries: |
| 89 |
name: fallback shared libraries |
| 90 |
runs-on: ubuntu-latest |
| 91 |
container: |
| 92 |
image: ghcr.io/linux-nvme/debian:latest |
| 93 |
if: github.ref == 'refs/heads/master' |
| 94 |
steps: |
| 95 |
- uses: actions/checkout@v5 |
| 96 |
- name: build |
| 97 |
run: | |
| 98 |
scripts/build.sh -b release -c gcc fallback |
| 99 |
- uses: actions/upload-artifact@v5 |
| 100 |
if: failure() |
| 101 |
with: |
| 102 |
name: log files |
| 103 |
path: | |
| 104 |
.build-ci/meson-logs/*.txt |
| 105 |
|
| 106 |
build-muon: |
| 107 |
name: muon minimal static |
| 108 |
runs-on: ubuntu-latest |
| 109 |
container: |
| 110 |
image: ghcr.io/linux-nvme/debian:latest |
| 111 |
steps: |
| 112 |
- uses: actions/checkout@v5 |
| 113 |
- name: build |
| 114 |
run: | |
| 115 |
scripts/build.sh -m muon |