Skip to content

Commit 1008b03

Browse files
committed
Move setting for checks ahead of the install block
1 parent e1e7ef5 commit 1008b03

1 file changed

Lines changed: 6 additions & 7 deletions

File tree

.travis.yml

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,12 @@ before_install:
2727
- make
2828
- sudo make install
2929
- cd ..
30+
- if [ "$BUILD_TYPE" = "asan" ]; then export CFLAGS='-fsanitize=address'; export LDFLAGS='-fsanitize=address'; fi
31+
- if [ "$BUILD_TYPE" = "asanpc" ]; then export CFLAGS='-fsanitize=address -fsanitize=pointer-compare'; export LDFLAGS='-fsanitize=address -fsanitize=pointer-compare'; fi
32+
- if [ "$BUILD_TYPE" = "asanps" ]; then export CFLAGS='-fsanitize=address -fsanitize=pointer-subtract'; export LDFLAGS='-fsanitize=address -fsanitize=pointer-subtract'; fi
33+
- if [ "$BUILD_TYPE" = "lsan" ]; then export CFLAGS='-fsanitize=leak'; export LDFLAGS='-fsanitize=leak'; fi
34+
- if [ "$BUILD_TYPE" = "tsan" ]; then export CFLAGS='-fsanitize=thread'; export LDFLAGS='-fsanitize=thread'; fi
35+
- if [ "$BUILD_TYPE" = "ubsan" ]; then export export CFLAGS='-fsanitize=undefined'; export LDFLAGS='-fsanitize=undefined'; fi
3036
install:
3137
- if [[ "$CROSS_COMPILE" == 1 ]] ; then
3238
if [[ "$ARM_ARCH_DIR" == "aarch64-linux-gnu" ]] ; then
@@ -55,13 +61,6 @@ install:
5561
- if [ "$CROSS_COMPILE" = "1" ] && [ "$ARM_ARCH_DIR" = "aarch64-linux-gnu" ]; then sed -i 's+/usr/bin/ld+$HOME/linker_bin/ld+g' Makefile; fi
5662
- make
5763
- make check TESTS=
58-
before_script:
59-
- if [ "$BUILD_TYPE" = "asan" ]; then export CFLAGS='-fsanitize=address'; export LDFLAGS='-fsanitize=address'; fi
60-
- if [ "$BUILD_TYPE" = "asanpc" ]; then export CFLAGS='-fsanitize=address -fsanitize=pointer-compare'; export LDFLAGS='-fsanitize=address -fsanitize=pointer-compare'; fi
61-
- if [ "$BUILD_TYPE" = "asanps" ]; then export CFLAGS='-fsanitize=address -fsanitize=pointer-subtract'; export LDFLAGS='-fsanitize=address -fsanitize=pointer-subtract'; fi
62-
- if [ "$BUILD_TYPE" = "lsan" ]; then export CFLAGS='-fsanitize=leak'; export LDFLAGS='-fsanitize=leak'; fi
63-
- if [ "$BUILD_TYPE" = "tsan" ]; then export CFLAGS='-fsanitize=thread'; export LDFLAGS='-fsanitize=thread'; fi
64-
- if [ "$BUILD_TYPE" = "ubsan" ]; then export export CFLAGS='-fsanitize=undefined'; export LDFLAGS='-fsanitize=undefined'; fi
6564
script:
6665
- if [[ "$CROSS_COMPILE" == 1 ]]; then
6766
cd test ;

0 commit comments

Comments
 (0)