Skip to content

Update CI to use clang 14 #31

Update CI to use clang 14

Update CI to use clang 14 #31

Workflow file for this run

name: CI
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
compiler: [gcc, clang]
build_type: [debug, release]
steps:
- uses: actions/checkout@v2
- name: install-clang
if: matrix.compiler == 'clang'
run: |
sudo apt-get install -y clang
sudo update-alternatives --remove-all cc
sudo update-alternatives --install /usr/bin/cc cc /usr/bin/clang 14
- name: configure-debug
if: matrix.build_type == 'debug'
run: |
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Debug -DHASHMAP_BUILD_TESTS=ON -DHASHMAP_BUILD_EXAMPLES=ON ${GITHUB_WORKSPACE}
- name: configure-release
if: matrix.build_type == 'release'
run: |
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release -DHASHMAP_BUILD_TESTS=ON -DHASHMAP_BUILD_EXAMPLES=ON ${GITHUB_WORKSPACE}
- name: make
run: |
make VERBOSE=1 -C build
- name: install
run: |
cd build
sudo make install
- name: test
run: |
cd build
ctest --output-on-failure