summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon McVittie <smcv@collabora.com>2022-09-06 14:29:34 +0100
committerSimon McVittie <smcv@debian.org>2022-10-24 16:12:14 +0100
commitd98b745d4365a1375c1148fda0d8e1811881a481 (patch)
tree66c109ea3393b0d7e581995e9d6369c7e58238e3
parentf85097a427e1e2ea910df29e0c592978df10e979 (diff)
downloadflatpak-d98b745d4365a1375c1148fda0d8e1811881a481.tar.gz
workflows: Use Meson for the main build
This is somewhat faster than Autotools. We still use Autotools for the alt, clang and valgrind builds, to make sure we cover both. As a bonus, the use of undefined behaviour and address sanitizers here actually works (unlike in Autotools, see #4844) so we're getting test coverage with detection of common issues like use-after-free. Signed-off-by: Simon McVittie <smcv@collabora.com>
-rw-r--r--.github/workflows/check.yml28
1 files changed, 15 insertions, 13 deletions
diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml
index bfabce1b..9ac9c1e1 100644
--- a/.github/workflows/check.yml
+++ b/.github/workflows/check.yml
@@ -64,30 +64,32 @@ jobs:
popd
- name: Create logs dir
run: mkdir test-logs
- - name: autogen.sh
- run: NOCONFIGURE=1 ./autogen.sh
- name: configure
# We don't do gtk-doc or GObject-Introspection here, because they can
# clash with AddressSanitizer. Instead, the clang build enables those.
run: |
- mkdir _build
- pushd _build
- ../configure --enable-internal-checks --enable-asan --disable-introspection --with-curl --with-system-bubblewrap --with-system-dbus-proxy
- popd
+ meson _build \
+ -Db_sanitize=address,undefined \
+ -Dgir=disabled \
+ -Dgtkdoc=disabled \
+ -Dhttp_backend=curl \
+ -Dinternal_checks=true \
+ -Dsystem_bubblewrap=bwrap \
+ -Dsystem_dbus_proxy=xdg-dbus-proxy \
+ ${NULL+}
env:
CFLAGS: -O2 -Wp,-D_FORTIFY_SOURCE=2
- name: Build flatpak
- run: make -C _build -j $(getconf _NPROCESSORS_ONLN)
+ run: ninja -C _build
+ env:
+ ASAN_OPTIONS: detect_leaks=0 # Right now we're not fully clean, but this gets us use-after-free etc
- name: Run tests
- run: make -C _build check -j $(getconf _NPROCESSORS_ONLN)
+ run: meson test -C _build
env:
ASAN_OPTIONS: detect_leaks=0 # Right now we're not fully clean, but this gets us use-after-free etc
- - name: Collect overall test logs on failure
- if: failure()
- run: mv _build/test-suite.log test-logs/ || true
- - name: Collect individual test logs on cancel
+ - name: Collect logs on failure
if: failure() || cancelled()
- run: mv _build/tests/*.log test-logs/ || true
+ run: mv _build/meson-logs/* test-logs/ || true
- name: Upload test logs
uses: actions/upload-artifact@v1
if: failure() || cancelled()