commit bdc42499fa363136fd2cbb741e63ef31438ac906
parent 649f8f7ba4b8068d32d5164a002fb41c9f9dc8e6
Author: finwo <finwo@pm.me>
Date: Wed, 17 Feb 2021 23:37:30 +0100
Fallback to clang-8 as CC in build.sh
Diffstat:
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/build.sh b/build.sh
@@ -2,10 +2,11 @@
arch=wasm32
target=${arch}
+CC=$(command -v clang clang-8; true)
+LC=$(command -v llc llc-8; true)
-
-# # Reset/fetch submodules
-# git submodule update --force --init --recursive
+# Reset/fetch submodules
+git submodule update --force --init --recursive
# Apply patches
( cd lib/supercop && patch -p1 < ../../patch/supercop/00-single-file-compile.patch )
@@ -13,7 +14,7 @@ target=${arch}
# Build libc
( cd lib/matter && make clean && make -e TARGET=${target} )
-clang \
+${CC} \
-nostdinc \
--target=${target} \
-emit-llvm \
@@ -25,7 +26,7 @@ clang \
-S \
-Os \
supercop.c || exit 1
-llc \
+${LC} \
-march=${arch} \
-filetype=obj \
-O3 \