diff options
| -rw-r--r-- | .github/workflows/ci-windows.yml | 23 |
1 files changed, 20 insertions, 3 deletions
diff --git a/.github/workflows/ci-windows.yml b/.github/workflows/ci-windows.yml index e467cf542..7addf746a 100644 --- a/.github/workflows/ci-windows.yml +++ b/.github/workflows/ci-windows.yml @@ -7,7 +7,10 @@ on: jobs: build: if: "!contains(github.event.head_commit.message, '[skip windows ci]')" - runs-on: windows-2019 + runs-on: windows-2025 + env: + CONAN_USER_HOME: ${{ github.workspace }}/win/build + CONAN_USER_HOME_SHORT: None steps: - uses: actions/checkout@v4 @@ -21,20 +24,34 @@ jobs: with: version: 1.66.0 + - name: Try to restore libraries from the cache + uses: actions/cache/restore@v4 + id: library-cache + with: + key: conan-${{ hashFiles('win/conanfile.txt') }} + path: ${{ env.CONAN_USER_HOME }}/.conan + - name: Install libraries working-directory: ${{ github.workspace }}/win/build run: | (Get-Content ../conanfile.txt).replace('##', '') | Set-Content ../conanfile.txt conan install .. --build=missing + - name: Save libraries to the cache + if: ${{ steps.library-cache.outputs.cache-hit != 'true' }} + uses: actions/cache/save@v4 + with: + key: ${{ steps.library-cache.outputs.cache-primary-key }} + path: ${{ env.CONAN_USER_HOME }}/.conan + - name: Run CMake working-directory: ${{ github.workspace }}/win/build env: LDFLAGS: /DEBUG:FASTLINK /INCREMENTAL run: | - cmake -G "Visual Studio 16 2019" -A "x64" .. + cmake -G "Visual Studio 17 2022" -A "x64" .. - name: Build InspIRCd working-directory: ${{ github.workspace }}/win/build run: | - msbuild InspIRCd.sln /M:3 /P:Configuration=Release /P:Platform=x64 /T:ALL_BUILD /VERBOSITY:MINIMAL + msbuild InspIRCd.sln /M:5 /P:Configuration=Release /P:Platform=x64 /T:ALL_BUILD /VERBOSITY:MINIMAL |
