diff options
author | Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> | 2023-11-24 15:47:28 +0000 |
---|---|---|
committer | Hennadii Stepanov <32963518+hebasto@users.noreply.github.com> | 2023-11-24 15:47:28 +0000 |
commit | 1a889f7ea043fc61865511a0d143321bbdc540a5 (patch) | |
tree | 7f69fa275e60d12ee695c50b7bb8010fcfe8fcd4 /.github | |
parent | 4335e553596a0ad5b136d3aa9fc898c906d226b4 (diff) |
ci: Set MSVC toolset version explicitly
This change avoids toolset incompatibilities that cause linker errors.
Diffstat (limited to '.github')
-rw-r--r-- | .github/workflows/ci.yml | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d2e609cd31..9419a0f19a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -197,6 +197,8 @@ jobs: run: | msbuild -version | Out-File -FilePath "$env:GITHUB_WORKSPACE\msbuild_version" Get-Content -Path "$env:GITHUB_WORKSPACE\msbuild_version" + $env:VCToolsVersion | Out-File -FilePath "$env:GITHUB_WORKSPACE\toolset_version" + Get-Content -Path "$env:GITHUB_WORKSPACE\toolset_version" $env:CI_QT_URL | Out-File -FilePath "$env:GITHUB_WORKSPACE\qt_url" $env:CI_QT_CONF | Out-File -FilePath "$env:GITHUB_WORKSPACE\qt_conf" @@ -279,6 +281,7 @@ jobs: run: | Set-Location "$env:VCPKG_INSTALLATION_ROOT" Add-Content -Path "triplets\x64-windows-static.cmake" -Value "set(VCPKG_BUILD_TYPE release)" + Add-Content -Path "triplets\x64-windows-static.cmake" -Value "set(VCPKG_PLATFORM_TOOLSET_VERSION $env:VCToolsVersion)" .\vcpkg.exe --vcpkg-root "$env:VCPKG_INSTALLATION_ROOT" integrate install git rev-parse HEAD | Out-File -FilePath "$env:GITHUB_WORKSPACE\vcpkg_commit" Get-Content -Path "$env:GITHUB_WORKSPACE\vcpkg_commit" @@ -293,7 +296,7 @@ jobs: uses: actions/cache@v3 with: path: ~/AppData/Local/vcpkg/archives - key: ${{ github.job }}-vcpkg-binary-${{ hashFiles('vcpkg_commit', 'msbuild_version', 'build_msvc/vcpkg.json') }} + key: ${{ github.job }}-vcpkg-binary-${{ hashFiles('vcpkg_commit', 'msbuild_version', 'toolset_version', 'build_msvc/vcpkg.json') }} - name: Generate project files run: py -3 build_msvc\msvc-autogen.py |