diff options
| author | Sebastiano Tronto <sebastiano@tronto.net> | 2024-09-03 21:52:16 +0200 |
|---|---|---|
| committer | Sebastiano Tronto <sebastiano@tronto.net> | 2024-09-03 21:52:16 +0200 |
| commit | c9e2d6466e42d6b779ac9ffa7c5ee9a9c7558df8 (patch) | |
| tree | f4f569fcbd4d6704fb5dd44892911ce808f03332 /configure.sh | |
| parent | ff4bde84872ec0b93f0f097f5a56bd5e7cbb0311 (diff) | |
| download | nissy-core-c9e2d6466e42d6b779ac9ffa7c5ee9a9c7558df8.tar.gz nissy-core-c9e2d6466e42d6b779ac9ffa7c5ee9a9c7558df8.zip | |
Moved stuff around
Diffstat (limited to 'configure.sh')
| -rwxr-xr-x | configure.sh | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/configure.sh b/configure.sh index 76d02de..e12dc06 100755 --- a/configure.sh +++ b/configure.sh | |||
| @@ -16,15 +16,18 @@ detectsan() { | |||
| 16 | TYPE=${TYPE-"$detected"} | 16 | TYPE=${TYPE-"$detected"} |
| 17 | 17 | ||
| 18 | STD="-std=c99" | 18 | STD="-std=c99" |
| 19 | WFLAGS="-pedantic -Wall -Wextra -Wno-unused-parameter -Wno-unused-function" | 19 | WFLAGS="-pedantic -Wall -Wextra" |
| 20 | # -Wstringop-overflow seems to be causing problems when combined with -O3 | ||
| 21 | # Someone else complained here: https://access.redhat.com/solutions/6755371 | ||
| 22 | WNOFLAGS="-Wno-unused-parameter -Wno-unused-function -Wno-stringop-overflow" | ||
| 20 | [ "$TYPE" = "AVX2" ] && AVX="-mavx2" | 23 | [ "$TYPE" = "AVX2" ] && AVX="-mavx2" |
| 21 | [ -n "$(detectsan address)" ] && ADDR="-fsanitize=address" | 24 | [ -n "$(detectsan address)" ] && ADDR="-fsanitize=address" |
| 22 | [ -n "$(detectsan undefined)" ] && UNDEF="-fsanitize=undefined" | 25 | [ -n "$(detectsan undefined)" ] && UNDEF="-fsanitize=undefined" |
| 23 | SAN="$ADDR $UNDEF" | 26 | SAN="$ADDR $UNDEF" |
| 24 | LIBS="-lpthread" | 27 | LIBS="-lpthread" |
| 25 | 28 | ||
| 26 | CFLAGS="$STD $LIBS $WFLAGS $AVX -O3" | 29 | CFLAGS="$STD $LIBS $WFLAGS $WNOFLAGS $AVX -O3" |
| 27 | DBGFLAGS="$STD $LIBS $WFLAGS $SAN $AVX -g3 -DDEBUG" | 30 | DBGFLAGS="$STD $LIBS $WFLAGS $WNOFLAGS $SAN $AVX -g3 -DDEBUG" |
| 28 | 31 | ||
| 29 | echo "Cube type: CUBE_$TYPE" | 32 | echo "Cube type: CUBE_$TYPE" |
| 30 | echo "Compiler: ${CC:-cc}" | 33 | echo "Compiler: ${CC:-cc}" |
