mirror of
https://github.com/boostorg/redis.git
synced 2026-01-19 04:42:09 +00:00
153 lines
5.9 KiB
YAML
153 lines
5.9 KiB
YAML
name: CI
|
|
|
|
|
|
on: [push, pull_request]
|
|
|
|
jobs:
|
|
windows:
|
|
name: "${{matrix.generator}} ${{matrix.toolset}} Boost ${{matrix.boost_version}} ${{matrix.build_type}} ${{matrix.name_args}}"
|
|
runs-on: ${{matrix.os}}
|
|
defaults:
|
|
run:
|
|
shell: bash
|
|
strategy:
|
|
# fail-fast: false
|
|
matrix:
|
|
include:
|
|
- { toolset: msvc-14.2, os: windows-2019, generator: "Visual Studio 16 2019", cxxstd: '17', build-type: 'Debug' }
|
|
- { toolset: msvc-14.2, os: windows-2019, generator: "Visual Studio 16 2019", cxxstd: '17', build-type: 'Release' }
|
|
- { toolset: msvc-14.3, os: windows-2022, generator: "Visual Studio 17 2022", cxxstd: '20', build-type: 'Debug' }
|
|
- { toolset: msvc-14.3, os: windows-2022, generator: "Visual Studio 17 2022", cxxstd: '20', build-type: 'Release' }
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Install dependencies
|
|
run: choco install openssl
|
|
|
|
- name: Setup Boost
|
|
run: python3 tools/ci.py setup-boost --source-dir=$(pwd)
|
|
|
|
- name: Build a Boost distribution using B2
|
|
run: |
|
|
python3 tools/ci.py build-b2-distro \
|
|
--generator "${{ matrix.generator }}" \
|
|
--toolset ${{ matrix.toolset }}
|
|
|
|
- name: Build a Boost distribution using CMake
|
|
run: |
|
|
python3 tools/ci.py build-cmake-distro \
|
|
--build-type ${{ matrix.build-type }} \
|
|
--cxxstd ${{ matrix.cxxstd }} \
|
|
--toolset ${{ matrix.toolset }} \
|
|
--generator "${{ matrix.generator }}"
|
|
|
|
- name: Build the project tests
|
|
run: |
|
|
python3 tools/ci.py build-cmake-standalone-tests \
|
|
--build-type ${{ matrix.build-type }} \
|
|
--cxxstd ${{ matrix.cxxstd }} \
|
|
--toolset ${{ matrix.toolset }} \
|
|
--generator "${{ matrix.generator }}"
|
|
|
|
# # TODO: re-enable this when a Redis server is available for this job
|
|
# - name: Run the project tests
|
|
# run: |
|
|
# python3 tools/ci.py run-cmake-standalone-tests \
|
|
# --build-type ${{ matrix.build-type }}
|
|
|
|
- name: Run add_subdirectory tests
|
|
run: |
|
|
python3 tools/ci.py run-cmake-add-subdirectory-tests \
|
|
--build-type ${{ matrix.build-type }} \
|
|
--toolset ${{ matrix.toolset }} \
|
|
--generator "${{ matrix.generator }}"
|
|
|
|
- name: Run find_package tests with the built cmake distribution
|
|
run: |
|
|
python3 tools/ci.py run-cmake-find-package-tests \
|
|
--build-type ${{ matrix.build-type }} \
|
|
--toolset ${{ matrix.toolset }} \
|
|
--generator "${{ matrix.generator }}"
|
|
|
|
- name: Run find_package tests with the built b2 distribution
|
|
run: |
|
|
python3 tools/ci.py run-cmake-b2-find-package-tests \
|
|
--build-type ${{ matrix.build-type }} \
|
|
--toolset ${{ matrix.toolset }} \
|
|
--generator "${{ matrix.generator }}"
|
|
|
|
posix:
|
|
defaults:
|
|
run:
|
|
shell: bash
|
|
|
|
strategy:
|
|
# fail-fast: false
|
|
matrix:
|
|
include:
|
|
- { toolset: gcc-11, install: g++-11, os: ubuntu-22.04, cxxstd: '17', build-type: 'Debug', ldflags: '' }
|
|
- { toolset: gcc-11, install: g++-11, os: ubuntu-22.04, cxxstd: '20', build-type: 'Release', ldflags: '' }
|
|
- { toolset: clang-11, install: clang-11, os: ubuntu-22.04, cxxstd: '17', build-type: 'Debug', ldflags: '' }
|
|
- { toolset: clang-11, install: clang-11, os: ubuntu-22.04, cxxstd: '20', build-type: 'Debug', ldflags: '' }
|
|
- { toolset: clang-13, install: clang-13, os: ubuntu-22.04, cxxstd: '17', build-type: 'Release', ldflags: '' }
|
|
- { toolset: clang-13, install: clang-13, os: ubuntu-22.04, cxxstd: '20', build-type: 'Release', ldflags: '' }
|
|
- { toolset: clang-14, install: 'clang-14 libc++-14-dev libc++abi-14-dev', os: ubuntu-22.04, cxxstd: '17', build-type: 'Debug', cxxflags: '-stdlib=libc++', ldflags: '-lc++' }
|
|
- { toolset: clang-14, install: 'clang-14 libc++-14-dev libc++abi-14-dev', os: ubuntu-22.04, cxxstd: '20', build-type: 'Release', cxxflags: '-stdlib=libc++', ldflags: '-lc++' }
|
|
name: "${{ matrix.toolset }} ${{ matrix.cxxstd }} ${{ matrix.build-type }} ${{ matrix.cxxflags }}"
|
|
runs-on: ${{ matrix.os }}
|
|
env:
|
|
CXXFLAGS: ${{matrix.cxxflags}} -Wall -Wextra
|
|
LDFLAGS: ${{matrix.ldflags}}
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Install dependencies
|
|
run: sudo apt-get -y install cmake protobuf-compiler redis-server python3 ${{ matrix.install }}
|
|
|
|
- name: Setup Boost
|
|
run: ./tools/ci.py setup-boost --source-dir=$(pwd)
|
|
|
|
- name: Build a Boost distribution using B2
|
|
run: |
|
|
./tools/ci.py build-b2-distro \
|
|
--toolset ${{ matrix.toolset }}
|
|
|
|
- name: Build a Boost distribution using CMake
|
|
run: |
|
|
./tools/ci.py build-cmake-distro \
|
|
--toolset ${{ matrix.toolset }} \
|
|
--build-type ${{ matrix.build-type }} \
|
|
--cxxstd ${{ matrix.cxxstd }}
|
|
|
|
- name: Build the project tests
|
|
run: |
|
|
./tools/ci.py build-cmake-standalone-tests \
|
|
--build-type ${{ matrix.build-type }} \
|
|
--cxxstd ${{ matrix.cxxstd }} \
|
|
--toolset ${{ matrix.toolset }}
|
|
|
|
- name: Run the project tests
|
|
run: |
|
|
./tools/ci.py run-cmake-standalone-tests \
|
|
--build-type ${{ matrix.build-type }}
|
|
|
|
- name: Run add_subdirectory tests
|
|
run: |
|
|
./tools/ci.py run-cmake-add-subdirectory-tests \
|
|
--build-type ${{ matrix.build-type }} \
|
|
--toolset ${{ matrix.toolset }}
|
|
|
|
- name: Run find_package tests with the built cmake distribution
|
|
run: |
|
|
./tools/ci.py run-cmake-find-package-tests \
|
|
--build-type ${{ matrix.build-type }} \
|
|
--toolset ${{ matrix.toolset }}
|
|
|
|
- name: Run find_package tests with the built b2 distribution
|
|
run: |
|
|
./tools/ci.py run-cmake-b2-find-package-tests \
|
|
--build-type ${{ matrix.build-type }} \
|
|
--toolset ${{ matrix.toolset }}
|