fix(ci): specify MSVC linker in CI and release workflows

- Added `-DCMAKE_LINKER=link.exe` to both CI and release workflows to ensure compatibility with MSVC, addressing issues with lld-link on protobuf resource files.

Benefits:
- Enhances build reliability on Windows by using the appropriate linker for MSVC, improving the overall CI and release process.
This commit is contained in:
scawful
2025-10-13 20:07:10 -04:00
parent 26faa7e0af
commit 85e6fb5a83
2 changed files with 2 additions and 0 deletions

View File

@@ -234,6 +234,7 @@ jobs:
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} `
-DCMAKE_C_COMPILER=${{ matrix.cc }} `
-DCMAKE_CXX_COMPILER=${{ matrix.cxx }} `
-DCMAKE_LINKER=link.exe ` # Use MSVC linker; lld-link fails on protobuf resource files
-DCMAKE_TOOLCHAIN_FILE="$vcpkgToolchain" `
-DVCPKG_TARGET_TRIPLET=x64-windows-static `
-DVCPKG_MANIFEST_MODE=ON `

View File

@@ -241,6 +241,7 @@ jobs:
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} `
-DCMAKE_C_COMPILER=${{ matrix.cc }} `
-DCMAKE_CXX_COMPILER=${{ matrix.cxx }} `
-DCMAKE_LINKER=link.exe ` # Use MSVC linker; lld-link fails on protobuf resource files
-DCMAKE_TOOLCHAIN_FILE="$vcpkgToolchain" `
-DVCPKG_TARGET_TRIPLET=x64-windows-static `
-DVCPKG_MANIFEST_MODE=ON `