mirror of
https://github.com/avinal/blowfish.git
synced 2026-01-09 22:38:33 +05:30
- Increased CMake minimum version to 3.30 - added test run in github workflow Signed-off-by: Avinal Kumar <avinal.xlvii@gmail.com>
38 lines
1009 B
YAML
38 lines
1009 B
YAML
name: Build and Test
|
|
|
|
on: [push, pull_request]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
matrix:
|
|
compiler: [g++, clang++]
|
|
build_type: [Debug]
|
|
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Install latest CMake
|
|
run: |
|
|
wget https://github.com/Kitware/CMake/releases/download/v4.2.0/cmake-4.2.0-linux-x86_64.sh
|
|
chmod +x cmake-4.2.0-linux-x86_64.sh
|
|
sudo ./cmake-4.2.0-linux-x86_64.sh --skip-license --prefix=/usr/local
|
|
|
|
- name: Configure with sanitizers
|
|
run: |
|
|
SAN="-fsanitize=address,undefined -fno-omit-frame-pointer"
|
|
cmake -S . -B build \
|
|
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
|
|
-DCMAKE_CXX_COMPILER=${{ matrix.compiler }} \
|
|
-DCMAKE_C_FLAGS="$SAN" \
|
|
-DCMAKE_CXX_FLAGS="$SAN"
|
|
|
|
- name: Build
|
|
run: cmake --build build -j
|
|
|
|
- name: Run tests
|
|
working-directory: build
|
|
run: ctest --output-on-failure -V
|