Skip to content

Make MacOS compile in the CI - #3600

Draft
IntegratedQuantum wants to merge 4 commits into
PixelGuys:masterfrom
IntegratedQuantum:macos_CI
Draft

IntegratedQuantum wants to merge 4 commits into
PixelGuys:masterfrom
IntegratedQuantum:macos_CI

Conversation

@IntegratedQuantum

Copy link
Copy Markdown
Member

Also updates Cubyz-libs after PixelGuys/Cubyz-libs#28 and PixelGuys/Cubyz-libs#27 to validate the CI-generated libraries

fixes #3541
fixes #3543

IntegratedQuantum added a commit to PixelGuys/Cubyz-libs that referenced this pull request Sep 14, 2026
@IntegratedQuantum

Copy link
Copy Markdown
Member Author

It appears to be more complicated than I thought it would be, I'm not sure how to work with extensions in MoltenVK, and I'm not going to remote-debug this. Someone who actually has a Mac will have to it when the time comes for #299.

@IntegratedQuantum
IntegratedQuantum marked this pull request as draft September 14, 2026 20:24
@blackedout01

Copy link
Copy Markdown
Contributor

@IntegratedQuantum Are you referring to vkCmdPushDescriptorSetKHR? This function got promoted to be part of Vulkan 1.4 and as MoltenVK implements this version, it can just be used as vkCmdPushDescriptorSet when compiling for macOS.
A quick fix would be the following:

if (builtin.target.os.tag == .macos) {
    c.vkCmdPushDescriptorSet(self.handle, @intFromEnum(bindPoint), pipeline.pipelineLayout, 0, @intCast(writeInfo.len), writeInfo.ptr);
} else {
    c.vkCmdPushDescriptorSetKHR(self.handle, @intFromEnum(bindPoint), pipeline.pipelineLayout, 0, @intCast(writeInfo.len), writeInfo.ptr);
}

But it's repetetive, could you suggest a prettier version?

@IntegratedQuantum

Copy link
Copy Markdown
Member Author

Yes, that's true for this extension, but in the future I would like to support other extensions as well, like VK_EXT_fragment_shader_interlock #817 which is not in any core version.
So I would like to do it properly for this extension, so that we have extension loading set up properly when the time comes for implementing #817.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Check macos compilation in the CI The Game No Longer Compiles on MacOS

2 participants