Skip to content

Commit b84828b

Browse files
committed
CI: Build macOS binary without Vulkan if Vulkan SDK fails installing
It's not rare for this step to fail, either due to network errors, or occasional changes in how the Vulkan SDK is distributed which require editing our script.
1 parent 28102e6 commit b84828b

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

.github/workflows/macos_builds.yml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,21 +44,28 @@ jobs:
4444
uses: ./.github/actions/godot-deps
4545

4646
- name: Setup Vulkan SDK
47+
id: vulkan-sdk
4748
run: |
48-
sh misc/scripts/install_vulkan_sdk_macos.sh
49+
if sh misc/scripts/install_vulkan_sdk_macos.sh; then
50+
echo "VULKAN_ENABLED=yes" >> "$GITHUB_OUTPUT"
51+
else
52+
echo "::warning::macOS: Vulkan SDK installation failed, building without Vulkan support."
53+
echo "VULKAN_ENABLED=no" >> "$GITHUB_OUTPUT"
54+
fi
55+
continue-on-error: true
4956

5057
- name: Compilation (x86_64)
5158
uses: ./.github/actions/godot-build
5259
with:
53-
sconsflags: ${{ env.SCONSFLAGS }} arch=x86_64
60+
sconsflags: ${{ env.SCONSFLAGS }} arch=x86_64 vulkan=${{ steps.vulkan-sdk.outputs.VULKAN_ENABLED }}
5461
platform: macos
5562
target: ${{ matrix.target }}
5663
tests: ${{ matrix.tests }}
5764

5865
- name: Compilation (arm64)
5966
uses: ./.github/actions/godot-build
6067
with:
61-
sconsflags: ${{ env.SCONSFLAGS }} arch=arm64
68+
sconsflags: ${{ env.SCONSFLAGS }} arch=arm64 vulkan=${{ steps.vulkan-sdk.outputs.VULKAN_ENABLED }}
6269
platform: macos
6370
target: ${{ matrix.target }}
6471
tests: ${{ matrix.tests }}

0 commit comments

Comments
 (0)