preprocessor + CI cleanup

also:
- minor refactors in path
- updated conformance tests
This commit is contained in:
Mark Gillard
2022-07-31 15:47:42 +03:00
parent e2edd69399
commit 501a80e231
28 changed files with 2202 additions and 1896 deletions

View File

@@ -29,6 +29,10 @@ concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
clang_version: '14'
gcc_version: '11'
jobs:
linux:
strategy:
@@ -48,22 +52,56 @@ jobs:
runs-on: ubuntu-latest
defaults:
run:
shell: bash
steps:
- name: Install dependencies
- name: Install base dependencies
run: |
sudo apt -y update
if [ ${{ matrix.compiler }} = clang++ ]; then compiler=clang; else compiler=${{ matrix.compiler }}; fi
sudo apt -y install --no-install-recommends $compiler ${{ matrix.linker }} pkgconf git ca-certificates locales-all python3 python3-pip python3-setuptools python3-wheel ninja-build
sudo pip3 install --upgrade meson
sudo apt -y install --no-install-recommends ${{ matrix.linker }} git python3 python3-pip ninja-build locales-all
sudo -H pip3 install --no-cache-dir --upgrade meson
- uses: actions/checkout@v3
- name: Check toml.hpp
run: |
sudo pip3 install --upgrade --requirement tools/requirements.txt
cd tools
sudo -H pip3 install --upgrade --requirement ./requirements.txt
python3 ci_single_header_check.py
- name: Update LLVM package repository
if: ${{ startsWith(matrix.compiler, 'clang') || startsWith(matrix.linker, 'lld') }}
run: |
sudo apt -y install --no-install-recommends software-properties-common wget
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
codename=$(lsb_release -sc)
sudo add-apt-repository --yes --no-update "deb http://apt.llvm.org/${codename}/ llvm-toolchain-${codename}-${{ env.clang_version }} main"
sudo apt -y update
- name: Install clang
if: ${{ startsWith(matrix.compiler, 'clang') }}
run: |
sudo apt -y install --no-install-recommends clang-${{ env.clang_version }}
sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-${{ env.clang_version }} 1000
- name: Install g++
if: ${{ startsWith(matrix.compiler, 'g++') }}
run: |
sudo apt -y install --no-install-recommends g++-${{ env.gcc_version }}
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-${{ env.gcc_version }} 1000
- name: Install lld
if: ${{ startsWith(matrix.linker, 'lld') }}
run: |
sudo apt -y install --no-install-recommends lld-${{ env.clang_version }}
sudo update-alternatives --install /usr/bin/ld.lld ld.lld /usr/bin/ld.lld-${{ env.clang_version }} 1000
- name: Configure locales
run: |
sudo locale-gen 'en_US.utf8' 'ja_JP.utf8' 'de_DE.utf8' 'it_IT.utf8' 'tr_TR.utf8' 'fi_FI.utf8' 'fr_FR.utf8' 'zh_CN.utf8'
- name: Configure Meson
run: |
CXX=${{ matrix.compiler }} CXX_LD=${{ matrix.linker }} meson setup build --buildtype=${{ matrix.type }} -Dcompile_library=${{ matrix.compile_library }} -Dpedantic=true -Dbuild_tests=true -Dbuild_examples=true -Dgenerate_cmake_config=false -Db_lto=false -Dubsan_examples=true -Dasan_examples=true
@@ -97,7 +135,7 @@ jobs:
python3 -m pip install -U pip==21.3.1
pip3 install meson ninja
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: ilammy/msvc-dev-cmd@v1
@@ -114,13 +152,14 @@ jobs:
tipi-build-linux:
name: tipi.build project build and dependency resolution
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/master'
container: tipibuild/tipi-ubuntu
env:
HOME: /root
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- run: mkdir -p ~/.tipi
# checking if the tomlplusplus project builds and passes tests