aboutsummaryrefslogtreecommitdiffhomepage
path: root/.circleci
diff options
context:
space:
mode:
authorAyke van Laethem <[email protected]>2020-12-03 00:59:20 +0100
committerRon Evans <[email protected]>2020-12-10 07:01:32 +0100
commitbb27bbcb41d37d78988b571c2d0943ba808cf52d (patch)
treeba91f8aad10abe531396625edb8a66aac3cabffd /.circleci
parent9c2d2b662bdf21caa54ae943901af3478f9e5c72 (diff)
downloadtinygo-bb27bbcb41d37d78988b571c2d0943ba808cf52d.tar.gz
tinygo-bb27bbcb41d37d78988b571c2d0943ba808cf52d.zip
all: switch to LLVM 11 for static builds
This commit switches to LLVM 11 for builds with LLVM linked statically (e.g. `make`). It does not yet switch the default for builds dynamically linked to LLVM, that should be done in a later change. This commit also changes to use the default host toolchain (probably GCC) instead of Clang as the default compiler in CI. There were some issues with Clang 3.8 in CI and hopefully this will fix it. Additionally it updates the way LLVM is built on Windows, with -DLLVM_ENABLE_PIC=OFF (which should have been used all along). This change makes it possible to revert a hack to build libclang manually and instead uses the libclang static library like on all other operating systems, simplifying the Makefile.
Diffstat (limited to '.circleci')
-rw-r--r--.circleci/config.yml30
1 files changed, 12 insertions, 18 deletions
diff --git a/.circleci/config.yml b/.circleci/config.yml
index db027a831..defaa8a19 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -68,12 +68,12 @@ commands:
steps:
- restore_cache:
keys:
- - llvm-source-10-v1
+ - llvm-source-11-v1
- run:
name: "Fetch LLVM source"
command: make llvm-source
- save_cache:
- key: llvm-source-10-v1
+ key: llvm-source-11-v1
paths:
- llvm-project
build-wasi-libc:
@@ -153,17 +153,14 @@ commands:
- llvm-source-linux
- restore_cache:
keys:
- - llvm-build-10-linux-v1-assert
+ - llvm-build-11-linux-v1-assert
- run:
name: "Build LLVM"
command: |
if [ ! -f llvm-build/lib/liblldELF.a ]
then
# install dependencies
- sudo apt-get install cmake clang ninja-build
- # make build faster
- export CC=clang
- export CXX=clang++
+ sudo apt-get install cmake ninja-build
# hack ninja to use less jobs
echo -e '#!/bin/sh\n/usr/bin/ninja -j3 "$@"' > /go/bin/ninja
chmod +x /go/bin/ninja
@@ -171,7 +168,7 @@ commands:
make ASSERT=1 llvm-build
fi
- save_cache:
- key: llvm-build-10-linux-v1-assert
+ key: llvm-build-11-linux-v1-assert
paths:
llvm-build
- run: make ASSERT=1
@@ -214,17 +211,14 @@ commands:
- llvm-source-linux
- restore_cache:
keys:
- - llvm-build-10-linux-v1
+ - llvm-build-11-linux-v1-noassert
- run:
name: "Build LLVM"
command: |
if [ ! -f llvm-build/lib/liblldELF.a ]
then
# install dependencies
- sudo apt-get install cmake clang ninja-build
- # make build faster
- export CC=clang
- export CXX=clang++
+ sudo apt-get install cmake ninja-build
# hack ninja to use less jobs
echo -e '#!/bin/sh\n/usr/bin/ninja -j3 "$@"' > /go/bin/ninja
chmod +x /go/bin/ninja
@@ -232,7 +226,7 @@ commands:
make llvm-build
fi
- save_cache:
- key: llvm-build-10-linux-v1
+ key: llvm-build-11-linux-v1-noassert
paths:
llvm-build
- build-wasi-libc
@@ -286,17 +280,17 @@ commands:
- go-cache-macos-v2-{{ checksum "go.mod" }}
- restore_cache:
keys:
- - llvm-source-10-macos-v1
+ - llvm-source-11-macos-v1
- run:
name: "Fetch LLVM source"
command: make llvm-source
- save_cache:
- key: llvm-source-10-macos-v1
+ key: llvm-source-11-macos-v1
paths:
- llvm-project
- restore_cache:
keys:
- - llvm-build-10-macos-v1
+ - llvm-build-11-macos-v1
- run:
name: "Build LLVM"
command: |
@@ -308,7 +302,7 @@ commands:
make llvm-build
fi
- save_cache:
- key: llvm-build-10-macos-v1
+ key: llvm-build-11-macos-v1
paths:
llvm-build
- restore_cache: