Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ jobs:
version: ${{ fromJSON(github.event.inputs.versions)[0] }}
cache: false
- name: Setup tmate session
if: steps.composite.outcome != 'success' || ${{ contains(github.event.inputs.extra_tests, 'tmate-after') }}
if: steps.composite.outcome != 'success' || contains(github.event.inputs.extra_tests, 'tmate-after')
uses: mxschmitt/action-tmate@v3.9
with:
limit-access-to-actor: true
Expand Down
20 changes: 18 additions & 2 deletions vulkan_prebuilt_helpers.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,16 @@ function _os_filename() {
esac
}

function _version_ge() {
local IFS=.
local i v1=($1) v2=($2)
for ((i=0; i<${#v1[@]} || i<${#v2[@]}; i++)); do
if (( ${v1[i]:-0} > ${v2[i]:-0} )); then return 0; fi
if (( ${v1[i]:-0} < ${v2[i]:-0} )); then return 1; fi
done
return 0
}

function download_vulkan_installer() {
local os=$1
local filename=$(_os_filename $os)
Expand Down Expand Up @@ -46,8 +56,14 @@ function install_linux() {
}

function install_windows() {
test -d $VULKAN_SDK && test -f vulkan_sdk.exe
7z x vulkan_sdk.exe -aoa -o$VULKAN_SDK
test -d "$VULKAN_SDK" && test -f vulkan_sdk.exe
if _version_ge "$VULKAN_SDK_VERSION" "1.4.313.0" ; then
echo "installing via installer command-line (version >= 1.4.313.0)" >&2
./vulkan_sdk.exe --root "$VULKAN_SDK" --accept-licenses --default-answer --confirm-command install
else
echo "installing via 7z extraction (version < 1.4.313.0)" >&2
7z x vulkan_sdk.exe -aoa -o"$VULKAN_SDK"
fi
}

function install_mac() {
Expand Down