aboutsummaryrefslogtreecommitdiff
path: root/configure.sh
diff options
context:
space:
mode:
Diffstat (limited to '')
-rwxr-xr-xconfigure.sh7
1 files changed, 6 insertions, 1 deletions
diff --git a/configure.sh b/configure.sh
index 9a790ca..b9779c2 100755
--- a/configure.sh
+++ b/configure.sh
@@ -1,8 +1,13 @@
1#!/bin/sh 1#!/bin/sh
2 2
3cc -mavx2 utils/detect-immintrin.c && detected="AVX2" && rm a.out 3detect() { cc -march=native -dM -E - < /dev/null | grep "$1"; }
4
5[ -n "$(detect __AVX2__)" ] && detected="AVX2"
6
4TYPE=${TYPE-"$detected"} 7TYPE=${TYPE-"$detected"}
5 8
9echo "Using CUBE_$TYPE"
10
6STD="-std=c99" 11STD="-std=c99"
7WFLAGS="-pedantic -Wall -Wextra -Wno-unused-parameter -Wno-unused-function" 12WFLAGS="-pedantic -Wall -Wextra -Wno-unused-parameter -Wno-unused-function"
8[ "$TYPE" = "AVX2" ] && AVX="-mavx2" 13[ "$TYPE" = "AVX2" ] && AVX="-mavx2"

Generated with cgit - Back to sebastiano.tronto.net