ci: add dual build artifacts for Windows (min-rust vs migrations) (#2208)

Add $(ExtraDefines) to PreprocessorDefinitions in all 4 configurations
of the vcxproj. This allows passing /p:ExtraDefines=DISABLE_RUST from
the MSBuild command line to use C code paths for switchable modules.

The Windows CI now produces two Release artifacts per architecture:
- "CCExtractor Windows x64 Release build" — min Rust (DISABLE_RUST)
- "CCExtractor Windows x64 Release build (with migrations)" — max Rust

The migrations build uses /t:Rebuild to do a clean rebuild without
DISABLE_RUST after the min-rust build completes.

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Carlos Fernandez Sanz
2026-03-17 08:48:02 -07:00
committed by GitHub
parent 92389cff84
commit 52b5385c2a
2 changed files with 26 additions and 7 deletions

View File

@@ -113,15 +113,15 @@ jobs:
with:
arch: ${{ matrix.arch }}
# Build Release-Full
- name: Build Release-Full
# Build Release-Full (min Rust — C paths where available)
- name: Build Release-Full (min Rust)
env:
LIBCLANG_PATH: "C:\\Program Files\\LLVM\\lib"
LLVM_CONFIG_PATH: "C:\\Program Files\\LLVM\\bin\\llvm-config"
BINDGEN_EXTRA_CLANG_ARGS: -fmsc-version=0
VCPKG_ROOT: ${{ github.workspace }}/vcpkg
VCPKG_DEFAULT_TRIPLET: ${{ matrix.vcpkg_triplet }}
run: msbuild ccextractor.sln /p:Configuration=Release-Full /p:Platform=${{ matrix.platform }} /p:GpacDir="${{ matrix.gpac_install }}"
run: msbuild ccextractor.sln /p:Configuration=Release-Full /p:Platform=${{ matrix.platform }} /p:GpacDir="${{ matrix.gpac_install }}" /p:ExtraDefines=DISABLE_RUST
working-directory: ./windows
- name: Display Release version information
@@ -140,6 +140,25 @@ jobs:
./windows/${{ matrix.outdir }}Release-Full/ccextractorwinfull.exe
./windows/${{ matrix.outdir }}Release-Full/*.dll
# Build Release-Full (with migrations — max Rust)
- name: Build Release-Full (with migrations)
env:
LIBCLANG_PATH: "C:\\Program Files\\LLVM\\lib"
LLVM_CONFIG_PATH: "C:\\Program Files\\LLVM\\bin\\llvm-config"
BINDGEN_EXTRA_CLANG_ARGS: -fmsc-version=0
VCPKG_ROOT: ${{ github.workspace }}/vcpkg
VCPKG_DEFAULT_TRIPLET: ${{ matrix.vcpkg_triplet }}
run: msbuild ccextractor.sln /t:Rebuild /p:Configuration=Release-Full /p:Platform=${{ matrix.platform }} /p:GpacDir="${{ matrix.gpac_install }}"
working-directory: ./windows
- name: Upload Release artifact (with migrations)
uses: actions/upload-artifact@v7
with:
name: CCExtractor Windows ${{ matrix.arch }} Release build (with migrations)
path: |
./windows/${{ matrix.outdir }}Release-Full/ccextractorwinfull.exe
./windows/${{ matrix.outdir }}Release-Full/*.dll
# Build Debug-Full (reuses cached Cargo artifacts)
- name: Build Debug-Full
env: