Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix MoltenVK detection #89327

Merged
merged 1 commit into from
Mar 9, 2024
Merged

Conversation

pohy
Copy link
Contributor

@pohy pohy commented Mar 9, 2024

There have recently been changes to the logic detecting Vulkan SDK on MacOS.
I have MoltenVK installed using homebrew and the macos-arm64_x86_64 is not available on my system.

Hence I have added code to detect multiple arch variants.

Following is info about my MoltenVK installation:

$ brew info molten-vk                                                                                                                                                                                                                                   
==> molten-vk: stable 1.2.7 (bottled), HEAD
Implementation of the Vulkan graphics and compute API on top of Metal
https://github.com/KhronosGroup/MoltenVK
/opt/homebrew/Cellar/molten-vk/1.2.7 (145 files, 89.6MB) *
  Poured from bottle using the formulae.brew.sh API on 2024-02-02 at 14:16:49
From: https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/m/molten-vk.rb
License: Apache-2.0
==> Dependencies
Build: cmake ✔
==> Requirements
Build: Xcode >= 11.7 (on macOS) ✔
Required: macOS >= 10.12 (or Linux) ✔, macOS ✔
==> Options
--HEAD
        Install HEAD version
==> Analytics
install: 1,133 (30 days), 4,053 (90 days), 15,190 (365 days)
install-on-request: 580 (30 days), 2,120 (90 days), 7,696 (365 days)
build-error: 102 (30 days)

$ brew ls molten-vk                                                                                                                                                                                                                                     
/opt/homebrew/Cellar/molten-vk/1.2.7/bin/MoltenVKShaderConverter
/opt/homebrew/Cellar/molten-vk/1.2.7/Frameworks/MoltenVK.xcframework/ (2 files)
/opt/homebrew/Cellar/molten-vk/1.2.7/Frameworks/MoltenVKShaderConverter.xcframework/ (2 files)
/opt/homebrew/Cellar/molten-vk/1.2.7/include/MoltenVK/ (6 files)
/opt/homebrew/Cellar/molten-vk/1.2.7/include/MoltenVKShaderConverter/ (4 files)
/opt/homebrew/Cellar/molten-vk/1.2.7/lib/libMoltenVK.dylib
/opt/homebrew/Cellar/molten-vk/1.2.7/lib/libMoltenVK.a
/opt/homebrew/Cellar/molten-vk/1.2.7/libexec/include/ (120 files)
/opt/homebrew/Cellar/molten-vk/1.2.7/libexec/lib/ (3 files)
/opt/homebrew/Cellar/molten-vk/1.2.7/share/vulkan/icd.d/MoltenVK_icd.json

$ ls /opt/homebrew/Frameworks/MoltenVK.xcframework/                                                                                                                                                                                                     
Info.plist  macos-arm64

@pohy pohy requested a review from a team as a code owner March 9, 2024 19:30
platform/macos/detect.py Outdated Show resolved Hide resolved
@akien-mga akien-mga added cherrypick:4.1 Considered for cherry-picking into a future 4.1.x release cherrypick:4.2 Considered for cherry-picking into a future 4.2.x release labels Mar 9, 2024
@akien-mga akien-mga merged commit 30d08f0 into godotengine:master Mar 9, 2024
16 checks passed
@akien-mga
Copy link
Member

Thanks!

@akien-mga
Copy link
Member

Doesn't seem trivially cherry-pickable for 4.2/4.1 as we haven't backported 94238d0. If those branches have the same issue, the detect.py refactor part of 94238d0 could likely be cherry-picked together with this PR.

@akien-mga akien-mga removed cherrypick:4.1 Considered for cherry-picking into a future 4.1.x release cherrypick:4.2 Considered for cherry-picking into a future 4.2.x release labels Mar 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants