Skip to content

Commit dc7e38c

Browse files
committed
Update Github CI runners, fix Ubuntu 18.04 compilation
1 parent 5b3a3d6 commit dc7e38c

File tree

4 files changed

+20
-14
lines changed

4 files changed

+20
-14
lines changed

.github/workflows/android.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
- {arch: "arm64-v8a"}
3030

3131
steps:
32-
- uses: actions/checkout@v2
32+
- uses: actions/checkout@v3
3333

3434
- name: Configure CMake
3535
run: |

.github/workflows/cppcmake.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,27 +34,29 @@ jobs:
3434
config:
3535
- {name: "ubuntu-20.04", os: "ubuntu-20.04", cmake_extra: "-DLSL_BUNDLED_PUGIXML=OFF"}
3636
- {name: "ubuntu-18.04", os: "ubuntu-latest", docker: "ubuntu:18.04" }
37-
- {name: "ubuntu-22.04", os: "ubuntu-latest", docker: "ubuntu:22.04" }
37+
- {name: "ubuntu-22.04", os: "ubuntu-22.04", cmake_extra: "-DLSL_BUNDLED_PUGIXML=OFF" }
3838
- {name: "windows-x64", os: "windows-2019", cmake_extra: "-T v140,host=x86"}
3939
- {name: "windows-32", os: "windows-2019", cmake_extra: "-T v140,host=x86 -A Win32"}
4040
- {name: "macOS-latest", os: "macOS-latest"}
4141

4242
# runs all steps in the container configured in config.docker or as subprocesses when empty
4343
container: ${{ matrix.config.docker }}
4444
steps:
45-
- uses: actions/checkout@v2
45+
- uses: actions/checkout@v3
4646
- name: set up build environment in container
4747
run: |
48+
set -x
4849
apt update
49-
apt install -y --no-install-recommends g++ git python3-pip ninja-build file dpkg-dev lsb-release sudo curl
50-
if [[ "$(apt search cmake | grep ^cmake/ | cut -d" " -f 2 | sort -V | tail -1 | cut -d. -f-2)" == 3.10 ]]
51-
then python3 -m pip install cmake
50+
apt install -y --no-install-recommends g++ git ninja-build file dpkg-dev lsb-release sudo curl
51+
if [[ "${{ matrix.config.name }}" = "ubuntu-18.04" ]]; then
52+
curl -sSkL https://github.com/Kitware/CMake/releases/download/v3.25.1/cmake-3.25.1-linux-x86_64.tar.gz | \
53+
tar -xzf - -C /usr --strip-components=1
5254
else apt install -y --no-install-recommends cmake libpugixml-dev
5355
fi
5456
if: ${{ matrix.config.docker }}
5557
- name: Configure CMake
5658
run: |
57-
if [[ "${{ matrix.config.os }}" == "ubuntu-20.04" ]]; then
59+
if [[ "${{ matrix.config.name }}" = ubuntu-2* ]]; then
5860
sudo apt-get install -y --no-install-recommends libpugixml-dev
5961
fi
6062
cmake --version

.github/workflows/mingw_static.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
shell: 'msys2 {0}'
2121

2222
steps:
23-
- uses: actions/checkout@v2
23+
- uses: actions/checkout@v3
2424
- uses: msys2/setup-msys2@v2
2525
with:
2626
release: false

.github/workflows/sanitize.yml

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,35 +11,39 @@ on:
1111
description: 'Sanitizer to run'
1212
required: true
1313
default: 'address'
14+
# caution: memory sanitizer is currently broken with Catch
1415
options: ['address', 'thread', 'memory', 'undefined']
1516
type: choice
1617

1718
defaults:
1819
run:
1920
shell: bash
2021

22+
env:
23+
LLVM_VERSION: 15
24+
2125
jobs:
2226
build:
2327
name: "${{ github.event.inputs.sanitizer }}"
2428
runs-on: 'ubuntu-latest'
2529

2630
steps:
27-
- uses: actions/checkout@v2
31+
- uses: actions/checkout@v3
2832
- name: Install build toolchain
2933
run: |
30-
wget https://apt.llvm.org/llvm-snapshot.gpg.key
31-
echo "deb [signed-by=$PWD/llvm-snapshot.gpg.key] http://apt.llvm.org/focal/ llvm-toolchain-focal-13 main" | sudo tee /etc/apt/sources.list.d/llvm.list
34+
curl -sSL https://apt.llvm.org/llvm-snapshot.gpg.key | sudo gpg --dearmor --yes -o /etc/apt/trusted.gpg.d/llvm.gpg
35+
echo "deb http://apt.llvm.org/jammy/ llvm-toolchain-jammy-$LLVM_VERSION main" | sudo tee /etc/apt/sources.list.d/llvm.list
3236
sudo apt update
33-
sudo apt install -y libpugixml-dev clang-13 gdb
37+
sudo apt install -y libpugixml-dev clang-$LLVM_VERSION gdb
3438
- name: Configure CMake
3539
run: |
3640
# linking a C++ library to a C program fails with ubsan enabled; disable lslver for this run
3741
sed -i -e'/lslver/d' CMakeLists.txt
3842
cmake --version
3943
cmake -S . -B build \
4044
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
41-
-DCMAKE_C_COMPILER=clang-13 \
42-
-DCMAKE_{CXX_COMPILER,LINKER}=clang++-13 \
45+
-DCMAKE_C_COMPILER=clang-$LLVM_VERSION \
46+
-DCMAKE_{CXX_COMPILER,LINKER}=clang++-$LLVM_VERSION \
4347
-DCMAKE_{C,CXX,EXE_LINKER,SHARED_LINKER}_FLAGS="-fsanitize=${{ github.event.inputs.sanitizer }}" \
4448
-DLSL_COMFY_DEFAULTS=ON \
4549
-DLSL_UNITTESTS=ON \

0 commit comments

Comments
 (0)