Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 26074d5bfc19afba72fba2f2f92b5b565dc11460
https://github.com/WebKit/WebKit/commit/26074d5bfc19afba72fba2f2f92b5b565dc11460
Author: Zak Ridouh <[email protected]>
Date: 2026-04-16 (Thu, 16 Apr 2026)
Changed paths:
M Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRBindingImpl.cpp
M Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRBindingImpl.h
M
Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRProjectionLayerImpl.cpp
M Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRProjectionLayerImpl.h
M Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRSubImageImpl.cpp
M Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRSubImageImpl.h
M Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRViewImpl.cpp
M Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRViewImpl.h
M Source/cmake/OptionsMac.cmake
Log Message:
-----------
[CMake] Guard WebXR WebGPU bindings with ENABLE(WEBGPU)
https://bugs.webkit.org/show_bug.cgi?id=312032
rdar://174939004
Reviewed by Pascoe and Mike Wyrzykowski.
The WebGPU/Implementation/WebGPUXR*.cpp files use #if
HAVE(WEBGPU_IMPLEMENTATION)
as their only guard. On Cocoa, HAVE(WEBGPU_IMPLEMENTATION) is unconditionally 1
(PlatformHave.h), so these files always compile — even when ENABLE(WEBGPU) is
OFF
and the WebGPU library isn't built. This produces undefined symbols for wgpuXR*
functions.
Add ENABLE(WEBGPU) to the file-level guards of the 8 XR-specific implementation
files so they compile to nothing when WebGPU is disabled.
With this fix, ENABLE_WEBXR can safely default to ON in OptionsMac.cmake.
* Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRBindingImpl.cpp:
* Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRBindingImpl.h:
* Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRProjectionLayerImpl.cpp:
* Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRProjectionLayerImpl.h:
* Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRSubImageImpl.cpp:
* Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRSubImageImpl.h:
* Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRViewImpl.cpp:
* Source/WebCore/Modules/WebGPU/Implementation/WebGPUXRViewImpl.h:
* Source/cmake/OptionsMac.cmake:
Canonical link: https://commits.webkit.org/311401@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications