Feature: sink level #125
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# | |
# Copyright Soramitsu Co., 2021-2023 | |
# Copyright Quadrivium Co., 2023 | |
# All Rights Reserved | |
# SPDX-License-Identifier: Apache-2.0 | |
# | |
name: OS and Compilers | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
jobs: | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
os: [ubuntu-latest, macOS-latest] | |
compiler: [{ | |
"cc": "gcc", | |
"cxx": "g++" | |
}, { | |
"cc": "clang", | |
"cxx": "clang++" | |
}] | |
exclude: | |
- os: macOS-latest | |
compiler: | |
cc: gcc | |
steps: | |
- name: checkout | |
uses: actions/checkout@v1 | |
with: | |
submodules: true | |
clean: true | |
fetch-depth: 1 | |
- name: install dependencies | |
run: | | |
set -e | |
if [ "$RUNNER_OS" = "macOS" ]; then | |
brew install ninja | |
else | |
sudo apt-get update || true | |
sudo apt-get install -y ninja-build gcovr gcc-13 g++-13 clang-18 clang++-18 clang-tidy-18 clang-format-18 | |
sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 90 | |
sudo update-alternatives --install /usr/bin/clang-tidy clang-tidy /usr/bin/clang-tidy-18 999 | |
sudo update-alternatives --install /usr/bin/clang-format clang-format /usr/bin/clang-format-18 999 | |
sudo update-alternatives --install /usr/bin/clang clang /usr/lib/llvm-18/bin/clang-18 999 | |
sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-18 999 | |
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-13 90 | |
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-13 90 | |
sudo update-alternatives --install /usr/bin/gcov gcov /usr/bin/gcov-13 90 | |
fi | |
# sudo python3 -m pip install --upgrade pip | |
# sudo python3 -m pip install scikit-build | |
# sudo python3 -m pip install cmake==3.25 requests gitpython gcovr pyyaml | |
- name: cmake | |
env: | |
CC: ${{ matrix.compiler.cc }} | |
CXX: ${{ matrix.compiler.cxx }} | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # has to be included to access other secrets | |
GITHUB_HUNTER_USERNAME: ${{ secrets.GITHUB_HUNTER_USERNAME }} | |
GITHUB_HUNTER_TOKEN: ${{ secrets.GITHUB_HUNTER_TOKEN }} | |
run: cmake . -Bbuild | |
- name: build | |
run: cmake --build build -- -j4 | |
- name: test | |
env: | |
CTEST_OUTPUT_ON_FAILURE: 1 | |
run: cmake --build build --target test |