Feature/shared exports msvc (#525)

This commit is contained in:
Philemon Benner
2025-10-19 16:32:15 +02:00
committed by GitHub
parent 06988aa0e1
commit 83951fd90b
42 changed files with 212 additions and 90 deletions
+35
View File
@@ -64,4 +64,39 @@ jobs:
./build/benchmarks/json/reflect-cpp-json-benchmarks --benchmark_filter=canada >> $GITHUB_STEP_SUMMARY
./build/benchmarks/json/reflect-cpp-json-benchmarks --benchmark_filter=licenses >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
windows-msvc-shared:
strategy:
fail-fast: false
matrix:
format: ["JSON", "AVRO", "CAPNPROTO", "CBOR", "FLEXBUFFERS", "MSGPACK", "PARQUET", "TOML", "UBJSON", "XML", "YAML"]
name: "windows-msvc-shared (${{ matrix.format }})"
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 0
- name: Export GitHub Actions cache environment variables
uses: actions/github-script@v7
with:
script: |
core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || '');
core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || '');
- uses: ilammy/msvc-dev-cmd@v1
- uses: lukka/run-vcpkg@v11
- name: Compile tests (JSON)
if: matrix.format == 'JSON'
run: |
cmake -S . -B build -DREFLECTCPP_BUILD_SHARED=ON -DCMAKE_CXX_STANDARD=20 -DREFLECTCPP_BUILD_TESTS=ON -DCMAKE_BUILD_TYPE=Release
cmake --build build --config Release -j4
- name: Compile tests (Other formats)
if: matrix.format != 'JSON'
run: |
cmake -S . -B build -DREFLECTCPP_BUILD_SHARED=ON -DCMAKE_CXX_STANDARD=20 -DREFLECTCPP_BUILD_TESTS=ON -DREFLECTCPP_JSON=OFF -DREFLECTCPP_${{ matrix.format }}=ON -DCMAKE_BUILD_TYPE=Release
cmake --build build --config Release -j4
- name: Run tests
run: |
ctest --test-dir build --output-on-failure