From fae594861a95ccc3ef97fd142a883ffb1b437c5b Mon Sep 17 00:00:00 2001 From: Benjamin Saunders Date: Sun, 28 Jul 2024 17:20:13 -0700 Subject: [PATCH] Install Vulkan SDK in Windows CI --- .github/workflows/package.yml | 10 +--------- .github/workflows/rust.yml | 9 +++++++-- 2 files changed, 8 insertions(+), 11 deletions(-) diff --git a/.github/workflows/package.yml b/.github/workflows/package.yml index 10a948e1..84323c69 100644 --- a/.github/workflows/package.yml +++ b/.github/workflows/package.yml @@ -10,22 +10,14 @@ jobs: runs-on: windows-latest env: VULKAN_VERSION: "1.3.231.1" - VULKAN_SDK: "C:/VulkanSDK/1.3.231.1" steps: - uses: actions/checkout@v3 with: lfs: true - - name: Cache Vulkan SDK - id: cache-vulkan - uses: actions/cache@v4 - with: - path: ${{ env.VULKAN_SDK }} - key: vulkan-${{ env.VULKAN_VERSION }} - name: Install Vulkan SDK - if: steps.cache-vulkan.outputs.cache-hit != 'true' run: | Invoke-WebRequest -Uri "https://sdk.lunarg.com/sdk/download/${{ env.VULKAN_VERSION }}/windows/VulkanSDK-${{ env.VULKAN_VERSION }}-Installer.exe" -OutFile vulkan.exe - 7z x -aoa vulkan.exe "-o$env:VULKAN_SDK" Lib share/vulkan/registry/vk.xml + vulkan.exe /S - uses: actions-rs/toolchain@v1 with: diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 945c3f92..5744cd1c 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -13,6 +13,9 @@ jobs: runs-on: ${{ matrix.os }} + env: + VULKAN_VERSION: "1.3.231.1" + steps: - name: Install shaderc if: matrix.os == 'ubuntu-latest' @@ -20,9 +23,11 @@ jobs: wget -nv -r -nd -A install.tgz 'https://storage.googleapis.com/shaderc/badges/build_link_linux_clang_release.html' tar xf install.tgz export SHADERC_LIB_DIR="$PWD/install/lib" - - name: Install Ninja + - name: Install Vulkan SDK if: matrix.os == 'windows-latest' - run: choco install ninja + run: | + Invoke-WebRequest -Uri "https://sdk.lunarg.com/sdk/download/${{ env.VULKAN_VERSION }}/windows/VulkanSDK-${{ env.VULKAN_VERSION }}-Installer.exe" -OutFile vulkan.exe + .\vulkan.exe /S - uses: actions/checkout@v1 - uses: actions-rs/toolchain@v1