diff options
| author | peter <peter@pmikkelsen.com> | 2026-09-22 19:18:35 +0000 |
|---|---|---|
| committer | peter <peter@pmikkelsen.com> | 2026-09-22 19:18:35 +0000 |
| commit | 949896e24ef16d703ee07fb3e489f2a986050d5b (patch) | |
| tree | dd0b7a9855532881dcb7b526e9fe5874770c8c4c /tools/check | |
| parent | ea381bac43f3ce78be5fa3ea10810810670dfb89 (diff) | |
Final changes to be able to switch over to an autotools based setupautotools
FossilOrigin-Name: 6a01b406226d3f60ea7d86fc177296f8e0a6c1e0816264bac807e30d78edbf21
Diffstat (limited to 'tools/check')
| -rwxr-xr-x | tools/check | 24 |
1 files changed, 22 insertions, 2 deletions
diff --git a/tools/check b/tools/check index 717746d..eee6490 100755 --- a/tools/check +++ b/tools/check @@ -2,7 +2,7 @@ set -e -types="Debug Release Coverage" +types="debug release coverage" mkdir -p build cd build @@ -10,7 +10,27 @@ cd build for type in $types do rm -rf $type - cmake .. -G Ninja -B $type -DCMAKE_BUILD_TYPE=$type + mkdir -p $type + cd $type + case $type in + debug) + CFLAGS="-O0 -g3 -fsanitize=address,undefined" + ;; + coverage) + CFLAGS="-O0 -g3 --coverage -fcondition-coverage" + ;; + release) + CFLAGS="-O3" + ;; + *) + echo "Unsupported type" + exit 1 + ;; + esac + ../../configure --enable-build-mode=$type CFLAGS="$CFLAGS -Wall -Wextra -Werror -std=c89 -pedantic" + make check + ../../configure --enable-build-mode=$type CFLAGS="$CFLAGS" + cd .. done cd .. |