]> git.ipfire.org Git - thirdparty/kmod.git/commitdiff
ci: use meson bla -C builddir/
authorEmil Velikov <emil.l.velikov@gmail.com>
Tue, 3 Jun 2025 21:46:47 +0000 (22:46 +0100)
committerLucas De Marchi <lucas.de.marchi@gmail.com>
Thu, 5 Jun 2025 06:39:11 +0000 (01:39 -0500)
Use builddir/ as indicated in our README, which makes it obvious that
what the argument is. While there, remove a few instances of mkdir/cd -
meson and ninja can handle it themselves.

Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Link: https://github.com/kmod-project/kmod/pull/362
Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>
.github/workflows/codeql.yml
.github/workflows/coverage.yml
.github/workflows/docs.yml
.github/workflows/main.yml

index 487a45f2e065b829be813b15163556943ab8f717..a6b00cde88147caf63b7772930966ff52a57baee 100644 (file)
@@ -53,9 +53,8 @@ jobs:
 
       - name: Build
         run: |
-          mkdir build && cd build
-          meson setup --native-file ../build-dev.ini ${{ matrix.meson_setup }} . ..
-          meson compile
+          meson setup --native-file build-dev.ini ${{ matrix.meson_setup }} builddir/
+          meson compile -C builddir/
 
       - name: Perform CodeQL Analysis
         uses: github/codeql-action/analyze@ff0a06e83cb2de871e5a09832bc6a81e7276941f # v3.28.18
@@ -68,7 +67,7 @@ jobs:
         uses: advanced-security/filter-sarif@f3b8118a9349d88f7b1c0c488476411145b6270d # v1.0.1
         with:
           patterns: |
-            -build/meson-private/**/testfile.c
+            -builddir/meson-private/**/testfile.c
           input: sarif-results/cpp.sarif
           output: sarif-results/cpp.sarif
 
index a5ccf1087541a4e712c3432adaf46535954cde72..32beea1cc979a31af568416c3ae06016892b4436 100644 (file)
@@ -44,14 +44,13 @@ jobs:
 
       - name: Build
         run: |
-          mkdir build && cd build
-          meson setup --native-file ../build-dev.ini ${{ matrix.meson_setup }} . ..
-          meson compile
-          meson test
-          ninja coverage-xml
+          meson setup --native-file build-dev.ini ${{ matrix.meson_setup }} builddir/
+          meson compile -C builddir/
+          meson test -C builddir/
+          ninja -C builddir/ coverage-xml
 
       - name: Upload Coverage
         uses: codecov/codecov-action@18283e04ce6e62d37312384ff67231eb8fd56d24 # v5.4.3
         with:
           token: ${{ secrets.CODECOV_TOKEN }}
-          file: build/meson-logs/coverage.xml
+          file: builddir/meson-logs/coverage.xml
index 0b43c57c60dd0c2104e9b82947f18874a496a2c8..61bcd7414e98f8281bdf1b1d68116d88b776e528 100644 (file)
@@ -29,8 +29,8 @@ jobs:
 
       - name: Build docs
         run: |
-          meson setup -Ddocs=true build .
-          meson compile -C build
+          meson setup -Ddocs=true builddir/
+          meson compile -C builddir/
 
       - name: Extract docs version
         shell: bash
@@ -50,7 +50,7 @@ jobs:
         env:
           API_TOKEN_GITHUB: ${{ secrets.KMOD_DOCS }}
         with:
-          source-directory: 'build/libkmod/docs/html'
+          source-directory: 'builddir/libkmod/docs/html'
           destination-github-username: '${{ github.repository_owner }}'
           destination-repository-name: 'kmod-project.github.io'
           user-name: 'github-actions[bot]'
index ab3f3fd452a74a630cb1b61f770325cf5f431cdc..f80396858ad0157ad9d1fa06678654f9f80da1a7 100644 (file)
@@ -173,17 +173,17 @@ jobs:
             export CC_LD="${{ matrix.linker }}"
           fi
 
-          meson setup --native-file build-dev.ini $setup_options build
+          meson setup --native-file build-dev.ini $setup_options builddir/
 
       - name: build
-        run: cd build && meson compile
+        run: meson compile -C builddir/
 
       - name: test
         if: ${{ matrix.skip_test != 'true' }}
-        run: cd build && meson test || meson test --verbose
+        run: meson test -C builddir/ || meson test -C builddir/ --verbose
 
       - name: install
-        run: cd build && DESTDIR=$PWD/inst meson install
+        run: DESTDIR=$PWD/inst meson install -C builddir/
 
       - name: distcheck
-        run: cd build && meson dist
+        run: meson dist -C builddir/