@@ -40,30 +40,32 @@ jobs:
4040 matrix :
4141 config : [ "Debug", "Release" ]
4242 build_system : [ MSBuild, CMake ]
43- runner : [ windows-2022, windows-2019 ]
43+ os : [ windows-2022, windows-2019 ]
4444 full_config_build :
4545 - ${{fromJSON(inputs.full_config_build)}}
4646 exclude :
4747 - full_config_build : false
48- runner : windows-2022
48+ os : windows-2022
4949 build_system : MSBuild
5050 config : " Debug"
5151 - full_config_build : false
52- runner : windows-2019
52+ os : windows-2019
5353 build_system : CMake
5454 - full_config_build : false
55- runner : windows-2022
55+ os : windows-2022
5656 build_system : CMake
5757 config : " Release"
5858 include :
59- - runner : windows-2022
59+ - os : windows-2022
60+ runner : [windows-2022]
6061 vc-path : ' C:\Program Files\Microsoft Visual Studio\2022\Enterprise'
6162 CUDA-VERSION : ' 12.0.1.52833'
6263 CUDA-MAJOR : ' 12'
6364 CUDA-MINOR : ' 0'
6465 vcpkg-version : ${{ inputs.vs22_vcpkg_version }}
65- - runner : windows-2019
66- vc-path : ' C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise'
66+ - os : windows-2019
67+ runner : [self-hosted, windows, x64, vs-2019, meshinspector]
68+ vc-path : ' C:\Program Files (x86)\Microsoft Visual Studio\2019\Community'
6769 CUDA-VERSION : ' 11.4.2.47141'
6870 CUDA-MAJOR : ' 11'
6971 CUDA-MINOR : ' 4'
7375 contents : read # This is required for actions/checkout
7476
7577 env :
76- BUILD_C_SHARP : ${{ matrix.runner == 'windows-2022' && matrix.build_system == 'MSBuild' }}
78+ BUILD_C_SHARP : ${{ matrix.os == 'windows-2022' && matrix.build_system == 'MSBuild' }}
7779 PYTEST_C_SHARP_ARGS : --run-c-sharp-samples --csharp-sample-dir=..\source\x64\${{ matrix.config }}
7880
7981 steps :
@@ -94,13 +96,14 @@ jobs:
9496 with :
9597 target_os : windows
9698 target_arch : x64
97- cxx_compiler : ${{ matrix.runner }} # runner name will be transformed to MSVC name (e.g. windows-2022 -> msvc-2022)
99+ cxx_compiler : ${{ matrix.os }} # os name will be transformed to MSVC name (e.g. windows-2022 -> msvc-2022)
98100 build_config : ${{ matrix.config }}
99101 build_system : ${{ matrix.build_system }}
100102
101103 - name : Clean Vcpkg Directory
104+ if : ${{ matrix.os == 'windows-2022' }}
102105 working-directory : C:\vcpkg
103- run : git clean -ffdx
106+ run : git clean -ffdx
104107
105108 - name : Checkout & Update Vcpkg ${{ matrix.vcpkg-version }}
106109 working-directory : C:\vcpkg
@@ -135,17 +138,19 @@ jobs:
135138 run : C:\vcpkg\vcpkg.exe integrate install
136139
137140 - name : Restore CUDA Cache
141+ if : ${{ matrix.os == 'windows-2022' }}
138142 uses : actions/cache@v4
139143 id : cuda-cache
140144 with :
141145 key : cuda-${{matrix.CUDA-VERSION}}
142146 path : C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA*
143147
144148 - name : Install CUDA
145- if : steps.cuda-cache.outputs.cache-hit != 'true'
149+ if : ${{ steps.cuda-cache.outputs.cache-hit != 'true' && matrix.os == 'windows-2022' }}
146150 run : choco install cuda --version=${{matrix.CUDA-VERSION}} --confirm
147151
148152 - name : Setup CUDA
153+ if : ${{ matrix.os == 'windows-2022' }}
149154 shell : bash
150155 run : |
151156 echo "CUDA_PATH=C:\\Program Files\\NVIDIA GPU Computing Toolkit\\CUDA\\v${{ matrix.CUDA-MAJOR }}.${{ matrix.CUDA-MINOR }}" >> $GITHUB_ENV
@@ -154,6 +159,7 @@ jobs:
154159 echo "C:\\Program Files\\NVIDIA GPU Computing Toolkit\\CUDA\\v${{ matrix.CUDA-MAJOR }}.${{ matrix.CUDA-MINOR }}\\bin" >> $GITHUB_PATH
155160
156161 - name : Install Visual Studio Integration
162+ if : ${{ matrix.os == 'windows-2022' }}
157163 run : |
158164 $x = (dir $env:CUDA_PATH -dir -recurse -depth 2).where({$_.name -eq 'visual_studio_integration'}).fullname
159165 $y = (dir $x -dir -recurse).where({$_.name -eq 'MSBuildExtensions'}).fullname + '\*'
@@ -280,7 +286,7 @@ jobs:
280286 mrbind : ${{ inputs.mrbind }}
281287 pytest_args : " ${{ env.BUILD_C_SHARP == 'true' && env.PYTEST_C_SHARP_ARGS || '' }} --run-cuda=negative"
282288 smoke : ${{ !inputs.full_config_build && matrix.config == 'Debug' }}
283- test_artifacts_path : windows/${{ matrix.runner }}/${{ matrix.config }}
289+ test_artifacts_path : windows/${{ matrix.os }}/${{ matrix.config }}
284290 upload_test_artifacts : ${{ inputs.upload_test_artifacts }}
285291
286292 - name : Delete unwanted files
@@ -291,35 +297,35 @@ jobs:
291297 if exist source\x64\Release\pybind11nonlimitedapi_meshlib_3*.dll del /Q source\x64\Release\pybind11nonlimitedapi_meshlib_3*.dll
292298
293299 - name : Archive files # https://github.com/actions/download-artifact#maintaining-file-permissions-and-case-sensitive-files
294- if : ${{ inputs.upload_artifacts && matrix.runner == 'windows-2019' && matrix.build_system == 'MSBuild' }}
300+ if : ${{ inputs.upload_artifacts && matrix.os == 'windows-2019' && matrix.build_system == 'MSBuild' }}
295301 run : tar -a -c -f MREDist_${{ matrix.config }}.zip ./source/x64/${{matrix.config}}
296302
297303 - name : Upload Windows Binaries Archive
298- if : ${{ inputs.upload_artifacts && matrix.runner == 'windows-2019' && matrix.build_system == 'MSBuild' }}
304+ if : ${{ inputs.upload_artifacts && matrix.os == 'windows-2019' && matrix.build_system == 'MSBuild' }}
299305 uses : actions/upload-artifact@v4
300306 with :
301307 name : WindowsArchive_${{matrix.config}}
302308 path : MREDist_${{matrix.config}}.zip
303309 retention-days : 1
304310
305311 - name : Create and fix fake Wheel for NuGet
306- if : ${{ inputs.nuget_build && matrix.runner == 'windows-2022' && matrix.config == 'Release' && matrix.build_system == 'MSBuild' && env.BUILD_C_SHARP == 'true' }}
312+ if : ${{ inputs.nuget_build && matrix.os == 'windows-2022' && matrix.config == 'Release' && matrix.build_system == 'MSBuild' && env.BUILD_C_SHARP == 'true' }}
307313 run : |
308314 py -3 -m venv wheel_venv
309315 wheel_venv\Scripts\Activate
310316 python -m pip install delvewheel
311317 python ./scripts/nuget_patch/patch_library_deps.py "./source/x64/Release/MRMeshC.dll" "./patched_content/"
312318
313319 - name : Upload NuGet files to Artifacts
314- if : ${{ inputs.nuget_build && matrix.runner == 'windows-2022' && matrix.config == 'Release' && matrix.build_system == 'MSBuild' && env.BUILD_C_SHARP == 'true' }}
320+ if : ${{ inputs.nuget_build && matrix.os == 'windows-2022' && matrix.config == 'Release' && matrix.build_system == 'MSBuild' && env.BUILD_C_SHARP == 'true' }}
315321 uses : actions/upload-artifact@v4
316322 with :
317323 name : DotNetPatchArchiveWindows-x64
318324 path : ./patched_content/*
319325 retention-days : 1
320326
321327 - name : Upload NuGet library DLL to Artifacts
322- if : ${{ inputs.nuget_build && matrix.runner == 'windows-2022' && matrix.config == 'Release' && matrix.build_system == 'MSBuild' && env.BUILD_C_SHARP == 'true' }}
328+ if : ${{ inputs.nuget_build && matrix.os == 'windows-2022' && matrix.config == 'Release' && matrix.build_system == 'MSBuild' && env.BUILD_C_SHARP == 'true' }}
323329 uses : actions/upload-artifact@v4
324330 with :
325331 name : DotNetDll
0 commit comments