Skip to content

Commit 9daeae3

Browse files
committed
Uncomment stuff, and add clang.
1 parent 49ab5e6 commit 9daeae3

File tree

3 files changed

+71
-65
lines changed

3 files changed

+71
-65
lines changed

.github/workflows/clang.yml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: Clang builds
2+
3+
on: [push]
4+
5+
jobs:
6+
test_clang:
7+
strategy:
8+
fail-fast: false
9+
matrix:
10+
name:
11+
- clang-ubuntu18.04-gcc5
12+
- clang-ubuntu18.04-clang8
13+
- clang-ubuntu18.04-clang8
14+
- clang-win2019-clang
15+
- clang-macos10.14-xcode11
16+
include:
17+
- name: clang-ubuntu18.04-gcc5
18+
os: ubuntu-18.04
19+
compiler: gcc
20+
compiler-version: 5
21+
- name: clang-ubuntu18.04-clang8
22+
os: ubuntu-18.04
23+
compiler: clang
24+
compiler-version: 8
25+
- name: clang-win2019-clang
26+
os: windows-2019
27+
compiler: clang
28+
compiler-version: latest
29+
- name: clang-macos10.14-xcode11
30+
os: macos-10.14
31+
compiler: xcode
32+
compiler-version: 11
33+
name: ${{ matrix.name }}
34+
runs-on: ${{ matrix.os }}
35+
steps:
36+
- uses: actions/checkout@v1
37+
with:
38+
fetch-depth: 1
39+
- name: Install deps
40+
shell: bash
41+
run: .github/workflows/utils/install_deps.sh ${{ runner.os }} ${{ matrix.compiler }} ${{ matrix.compiler-version }}
42+
- if: runner.os == 'Linux'
43+
run: echo "::set-env name=extra_cmake_args::-DLLVM_USE_LINKER=gold"
44+
- name: configure
45+
shell: bash
46+
run: |
47+
mkdir build
48+
cd build
49+
cmake -GNinja \
50+
-DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra" \
51+
-DCMAKE_BUILD_TYPE=Release \
52+
-DLLVM_ENABLE_ASSERTIONS:BOOL=ON \
53+
${extra_cmake_args:-} \
54+
../llvm
55+
- name: build
56+
run: ninja -C build
57+
- name: test
58+
run: ninja -C build check
59+
- name: test-clang
60+
run: ninja -C build check-clang

.github/workflows/libcxx.yml

Lines changed: 3 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,9 @@ jobs:
88
fail-fast: false
99
matrix:
1010
name:
11-
# - libcxx-ubuntu18.04-clang8-cxx03
12-
# - libcxx-ubuntu18.04-clang8-cxx11
13-
- libcxx-win2019-clang-cxx11
14-
# - libcxx-macos10.14-xcode11-cxx11
11+
- libcxx-ubuntu18.04-clang8-cxx03
12+
- libcxx-ubuntu18.04-clang8-cxx11
13+
- libcxx-macos10.14-xcode11-cxx11
1514
include:
1615
- name: libcxx-ubuntu18.04-clang8-cxx03
1716
os: ubuntu-18.04
@@ -23,11 +22,6 @@ jobs:
2322
compiler: clang
2423
compiler-version: 8
2524
cxx-std: c++11
26-
- name: libcxx-win2019-clang-cxx11
27-
os: windows-2019
28-
compiler: clang
29-
compiler-version: 8
30-
cxx-std: c++11
3125
- name: libcxx-macos10.14-xcode11-cxx11
3226
os: macos-10.14
3327
compiler: xcode
@@ -62,56 +56,3 @@ jobs:
6256
run: ninja -C build check-libcxx
6357
# - name: test abilist
6458
# run: ninja -C build check-cxx-abilist
65-
66-
67-
# test_clang:
68-
# strategy:
69-
# fail-fast: false
70-
# matrix:
71-
# name:
72-
# # - clang-ubuntu18.04-clang8-cxx03
73-
# # - clang-ubuntu18.04-clang8-cxx11
74-
# - libcxx-win2019-clang-cxx11
75-
# # - clang-macos10.14-xcode11-cxx11
76-
# include:
77-
# - name: clang-ubuntu18.04-clang8
78-
# os: ubuntu-18.04
79-
# compiler: clang
80-
# compiler-version: 8
81-
# - name: clang-ubuntu18.04-clang8
82-
# os: ubuntu-18.04
83-
# compiler: clang
84-
# compiler-version: 8
85-
# - name: libcxx-win2019-clang
86-
# os: windows-2019
87-
# compiler: clang
88-
# compiler-version: 8
89-
# - name: libcxx-macos10.14-xcode11
90-
# os: macos-10.14
91-
# compiler: xcode
92-
# compiler-version: 11
93-
# name: ${{ matrix.name }}
94-
# runs-on: ${{ matrix.os }}
95-
# steps:
96-
# - uses: actions/checkout@v1
97-
# with:
98-
# fetch-depth: 1
99-
# - name: Install deps
100-
# shell: bash
101-
# run: .github/workflows/utils/install_deps.sh ${{ runner.os }} ${{ matrix.compiler }} ${{ matrix.compiler-version }}
102-
# - name: configure
103-
# run: >-
104-
# mkdir build &&
105-
# cd build &&
106-
# cmake -GNinja
107-
# -DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra"
108-
# -DLLVM_USE_LINKER=gold
109-
# -DCMAKE_BUILD_TYPE=Release
110-
# -DLLVM_ENABLE_ASSERTIONS:BOOL=ON
111-
# ../llvm
112-
# - name: build
113-
# run: ninja -C build
114-
# - name: test
115-
# run: ninja -C build check
116-
# - name: test-clang
117-
# run: ninja -C build check-clang

.github/workflows/utils/install_deps.sh

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ compiler=$2
77
compiler_version=$3
88

99
if [[ $os_kind == 'Linux' ]]; then
10-
sudo apt-get install -y ninja-build "clang-${compiler_version}"
11-
echo "::set-env name=CC::clang-${compiler_version}"
12-
echo "::set-env name=CXX::clang++-${compiler_version}"
10+
if [[ $compiler = gcc ]]; then
11+
compiler_pkg="g++-${compiler_version}"
12+
else
13+
compiler_pkg="${compiler}-${compiler_version}"
14+
fi
15+
sudo apt-get install -y ninja-build "${compiler_pkg}"
16+
echo "::set-env name=CC::${compiler}-${compiler_version}"
17+
echo "::set-env name=CXX::${compiler}++-${compiler_version}"
1318
elif [[ $os_kind == 'macOS' ]]; then
1419
brew install ninja
1520
sudo xcode-select -switch "/Applications/Xcode_${compiler_version}.app"

0 commit comments

Comments
 (0)