@@ -3,138 +3,83 @@ name: Build
33on : [push, pull_request, workflow_dispatch]
44
55jobs :
6- build-linux :
7- runs-on : ubuntu-latest
8- steps :
9- - name : Install dependencies
10- run : sudo apt-get update && sudo apt-get install libsndfile1-dev libvolk2-dev libfftw3-dev catch2
11-
12- - name : Checkout
13- uses : actions/checkout@v4
14- with :
15- submodules : true
16- fetch-depth : 0
6+ build :
7+ strategy :
8+ matrix :
9+ sys :
10+ - { os: windows-latest, shell: 'msys2 {0}' }
11+ - { os: ubuntu-latest, shell: bash }
12+ - { os: macos-latest, shell: bash }
1713
18- - name : Build
19- uses : " ./.github/actions/build"
20- with :
21- target : sigutils
22- cmake_configuration_parameters : -DCMAKE_INSTALL_PREFIX=/usr
23-
24- - name : Build tests
25- uses : " ./.github/actions/build"
26- with :
27- target : sigutils_test
28-
29- - name : Test
30- uses : " ./.github/actions/test"
14+ runs-on : ${{ matrix.sys.os }}
3115
32- - name : Package
33- uses : " ./.github/actions/package"
34- with :
35- generators : TGZ;DEB
36-
37- build-macos :
38- runs-on : macos-latest
39- steps :
40- - name : Install dependencies
41- run : brew install libsndfile volk fftw catch2
42-
43- - name : Checkout
44- uses : actions/checkout@v4
45- with :
46- submodules : true
47- fetch-depth : 0
48-
49- - name : Build
50- uses : " ./.github/actions/build"
51- with :
52- target : sigutils
53-
54- - name : Build tests
55- uses : " ./.github/actions/build"
56- with :
57- target : sigutils_test
58-
59- - name : Test
60- uses : " ./.github/actions/test"
61-
62- - name : Package
63- uses : " ./.github/actions/package"
64- with :
65- generators : TGZ
66-
67- build-windows :
68- runs-on : windows-latest
6916 defaults :
7017 run :
71- shell : msys2 {0}
18+ shell : ${{ matrix.sys.shell }}
19+
7220 steps :
73- - name : Install dependencies
21+ - name : Install dependencies (Ubuntu)
22+ if : matrix.sys.os == 'ubuntu-latest'
23+ run : |
24+ sudo apt-get update
25+ sudo apt-get install meson libsndfile1-dev libvolk2-dev libfftw3-dev catch2
26+
27+ - name : Install dependencies (Mac OS)
28+ if : matrix.sys.os == 'macos-latest'
29+ run : brew install -vd meson libsndfile volk fftw catch2
30+
31+ - name : Install dependencies (Windows)
32+ if : matrix.sys.os == 'windows-latest'
7433 uses : msys2/setup-msys2@v2
7534 with :
76- msystem : MINGW64
35+ msystem : UCRT64
7736 update : true
78- install : git mingw-w64-x86_64-gcc mingw-w64-x86_64-make mingw-w64-x86_64-cmake mingw-w64-x86_64-libsndfile mingw-w64-x86_64-fftw mingw-w64-x86_64-volk mingw-w64-x86_64-catch
37+ install : git mingw-w64-ucrt- x86_64-meson mingw-w64-ucrt- x86_64-ninja mingw-w64-ucrt- x86_64-gcc mingw-w64-ucrt- x86_64-libsndfile mingw-w64-ucrt- x86_64-fftw mingw-w64-ucrt- x86_64-volk mingw-w64-ucrt -x86_64-catch
7938
8039 - name : Checkout
8140 uses : actions/checkout@v4
8241 with :
83- submodules : true
8442 fetch-depth : 0
8543
86- - name : Build
87- uses : " ./.github/actions/build"
88- with :
89- shell : msys2 {0}
90- target : sigutils
44+ - name : Configure
45+ run : meson setup builddir
9146
92- - name : Build tests
93- uses : " ./.github/actions/build"
94- with :
95- shell : msys2 {0}
96- target : sigutils_test
47+ - name : Build
48+ run : meson compile -C builddir
9749
9850 - name : Test
99- uses : " ./.github/actions/test"
100- with :
101- shell : msys2 {0}
102-
103- - name : Package
104- uses : " ./.github/actions/package"
105- with :
106- generators : ZIP
107-
108- release :
109- runs-on : " ubuntu-latest"
110- needs :
111- - build-linux
112- - build-macos
113- - build-windows
114-
115- steps :
116- - name : Get current date
117- id : date
118- run : echo "::set-output name=date::$(date +'%Y-%m-%d')"
119-
120- - name : Download binaries
121- uses : actions/download-artifact@v4
122-
123- - name : Release nightly
124- if : github.ref == 'refs/heads/master'
125- uses : marvinpinto/action-automatic-releases@v1.2.1
126- with :
127- repo_token : " ${{ secrets.GITHUB_TOKEN }}"
128- automatic_release_tag : " latest"
129- prerelease : true
130- title : " Sigutils nightly (${{steps.date.outputs.date}})"
131- files : sigutils*/*
132-
133- - name : Release stable
134- if : contains(github.ref, 'refs/tags/v')
135- uses : marvinpinto/action-automatic-releases@v1.2.1
136- with :
137- repo_token : " ${{ secrets.GITHUB_TOKEN }}"
138- prerelease : false
139- title : " Sigutils ${{github.ref_name}}"
140- files : sigutils*/*
51+ run : meson test -C builddir
52+
53+ # TODO: Package
54+ # TODO: Upload artifacts
55+
56+ # release:
57+ # runs-on: "ubuntu-latest"
58+ # needs: build
59+
60+ # steps:
61+ # - name: Get current date
62+ # id: date
63+ # run: echo "::set-output name=date::$(date +'%Y-%m-%d')"
64+
65+ # - name: Download binaries
66+ # uses: actions/download-artifact@v4
67+
68+ # - name: Release nightly
69+ # if: github.ref == 'refs/heads/master'
70+ # uses: marvinpinto/action-automatic-releases@v1.2.1
71+ # with:
72+ # repo_token: "${{ secrets.GITHUB_TOKEN }}"
73+ # automatic_release_tag: "latest"
74+ # prerelease: true
75+ # title: "Sigutils nightly (${{steps.date.outputs.date}})"
76+ # files: sigutils*/*
77+
78+ # - name: Release stable
79+ # if: contains(github.ref, 'refs/tags/v')
80+ # uses: marvinpinto/action-automatic-releases@v1.2.1
81+ # with:
82+ # repo_token: "${{ secrets.GITHUB_TOKEN }}"
83+ # prerelease: false
84+ # title: "Sigutils ${{github.ref_name}}"
85+ # files: sigutils*/*
0 commit comments