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

molten-vk: install ICD to non-overridable path #204611

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft

Conversation

cho-m
Copy link
Member

@cho-m cho-m commented Jan 17, 2025

  • Have you followed the guidelines for contributing?
  • Have you ensured that your commits follow the commit style guide?
  • Have you checked that there aren't other open pull requests for the same formula update/change?
  • Have you built your formula locally with HOMEBREW_NO_INSTALL_FROM_API=1 brew install --build-from-source <formula>, where <formula> is the name of the formula you're submitting?
  • Is your test running fine brew test <formula>, where <formula> is the name of the formula you're submitting?
  • Does your build pass brew audit --strict <formula> (after doing HOMEBREW_NO_INSTALL_FROM_API=1 brew install --build-from-source <formula>)? If this is a new formula, does it pass brew audit --new <formula>?

For #203233. May as well use non-overridable path to reduce chances of user configuration impacting functionality.

Prior bottle,

XDG_DATA_DIRS=/tmp vulkaninfo --summary
ERROR: [Loader Message] Code 0 : vkCreateInstance: Found no drivers!
Cannot create Vulkan instance.
This problem is often caused by a faulty installation of the Vulkan driver or attempting to use a GPU that does not support Vulkan.
ERROR at /tmp/vulkan-tools-20241221-15121-nec5zd/Vulkan-Tools-1.4.304/vulkaninfo/./vulkaninfo.h:456:vkCreateInstance failed with ERROR_INCOMPATIBLE_DRIVERvulkaninfo --summary | rg driver
VK_LUNARG_direct_driver_loading        : extension revision 1
	driverVersion      = 0.2.2019
	driverID           = DRIVER_ID_MOLTENVK
	driverName         = MoltenVK
	driverInfo         = 1.2.11
	driverUUID         = 4d564b00-0000-27e3-0f02-020700000000

New build:

XDG_DATA_DIRS=/tmp vulkaninfo --summary | rg driver
VK_LUNARG_direct_driver_loading        : extension revision 1
	driverVersion      = 0.2.2019
	driverID           = DRIVER_ID_MOLTENVK
	driverName         = MoltenVK
	driverInfo         = 1.2.11
	driverUUID         = 4d564b00-0000-27e3-0f02-020700000000

@github-actions github-actions bot added the macos-only Formula depends on macOS label Jan 17, 2025
Comment on lines +182 to +183
"\"./libMoltenVK.dylib\"",
"\"#{lib}/libMoltenVK.dylib\""
Copy link
Member Author

@cho-m cho-m Jan 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could keep a relative path if preferred. Absolute path is simpler for inreplace. Relative path does avoid relocation in JSON file (though wouldn't expect performance impact unlike relocation in binary file).

Suggested change
"\"./libMoltenVK.dylib\"",
"\"#{lib}/libMoltenVK.dylib\""
"./libMoltenVK.dylib",
(lib/"libMoltenVK.dylib").relative_path_from(prefix/"etc/vulkan/icd.d")

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
macos-only Formula depends on macOS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant