diff options
author | Robin Haberkorn <robin.haberkorn@googlemail.com> | 2025-03-16 17:00:39 +0300 |
---|---|---|
committer | Robin Haberkorn <robin.haberkorn@googlemail.com> | 2025-03-16 17:00:39 +0300 |
commit | 95510959997fe189c6cf3fb8444eeb2edcd6d952 (patch) | |
tree | 073780f13975d073212f421fd5b88cf75be3346b /.github/workflows | |
parent | f29fda9a391af1ee05258cb143959e867b67ce23 (diff) | |
download | sciteco-95510959997fe189c6cf3fb8444eeb2edcd6d952.tar.gz |
CI: perhaps fixed address sanitizing
It can be done only under ncurses, as Gtk results in many false positives.
Also, try to use it on GCC and Clang.
It didn't work with GCC on FreeBSD, but perhaps it will work on Ubuntu.
Diffstat (limited to '.github/workflows')
-rw-r--r-- | .github/workflows/ci.yml | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index aeecd9a..9a289f3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -7,9 +7,7 @@ jobs: strategy: matrix: os: [ubuntu-20.04, ubuntu-22.04] - # Enable Adress Sanitizer only on Clang. - # This will improve the test suite quality, even without Valgrind. - compiler: ['CC=gcc CXX=g++', '--disable-malloc-replacement CC=clang CXX=clang++ CFLAGS="-fsanitize=address -fno-omit-frame-pointer" CXXFLAGS="-fsanitize=address -fno-omit-frame-pointer"'] + compiler: ['CC=gcc CXX=g++', 'CC=clang CXX=clang++'] interface: [ncurses, gtk] # NOTE: The virtual environments already contain both GCC and Clang @@ -33,10 +31,17 @@ jobs: groff doxygen - name: Configure Build + env: + # Enable Adress Sanitizer only on ncurses. + # Gtk produces a lot of false negatives. + # This will improve the test suite quality, even without Valgrind. + CFLAGS: ${{ matrix.interface == 'ncurses' && '-fsanitize=address -fno-omit-frame-pointer' }} + CXXFLAGS: ${{ matrix.interface == 'ncurses' && '-fsanitize=address -fno-omit-frame-pointer' }} + MALLOC_REPLACEMENT: ${{ matrix.interface == 'ncurses' && 'no' || 'check' }} run: | autoreconf -i ./configure --with-interface=${{ matrix.interface }} --enable-debug --enable-html-manual \ - ${{ matrix.compiler }} + --enable-malloc-replacement=$MALLOC_REPLACEMENT ${{ matrix.compiler }} # NOTE: xvfb-run emulates an XServer and is required when building # Gtk versions (since SciTECO calls itself during the build). |