File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed
Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change 1515 fail-fast : false
1616
1717 steps :
18+ - name : Check CMake version
19+ run : cmake --version
20+ - name : List installed Visual Studios
21+ run : Get-ChildItem "C:\Program Files\Microsoft Visual Studio"
22+ - name : List installed Windows SDKs
23+ run : dir "C:\Program Files (x86)\Windows Kits\10\Lib"
24+
25+ - name : Detect latest Windows SDK version
26+ id : sdk
27+ shell : pwsh
28+ run : |
29+ $sdks = Get-ChildItem "C:\Program Files (x86)\Windows Kits\10\Lib" |
30+ Where-Object { $_.Name -match '^\d+\.\d+\.\d+\.\d+$' } |
31+ Sort-Object Name -Descending
32+ $latest = $sdks[0].Name
33+ "Latest SDK: $latest"
34+ echo "sdkver=$latest" >> $env:GITHUB_OUTPUT
35+
1836 - uses : ilammy/msvc-dev-cmd@v1
1937 - uses : actions/checkout@v4
2038 with :
3250 # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
3351 run : >
3452 cmake --preset x64-release
53+ -DCMAKE_SYSTEM_VERSION=${{ steps.sdk.outputs.sdkver }}
3554 -S ${{ github.workspace }}
3655
3756 - name : Build
You can’t perform that action at this time.
0 commit comments