Skip to content

Commit 1e3ab4b

Browse files
committed
wpewebkit: Enable WebXR support
Toggle ENABLE_WEBXR and add the needed dependency on the "openxr" recipe. Define XR_USE_PLATFORM_ANDROID when targeting Android.
1 parent 5851f53 commit 1e3ab4b

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

packages/wpewebkit-core.package

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ class Package(package.Package):
5555
'proxy-libintl:libs',
5656
'libpsl:libs',
5757
'openjpeg:libs',
58+
'openxr:libs',
5859
'sqlite3:libs',
5960
'xkbcommon:libs',
6061
'wpewebkit',

recipes/wpewebkit.recipe

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ class Recipe(recipe.Recipe):
2727
'libwebp',
2828
'libwpe',
2929
'openjpeg',
30+
'openxr',
3031
]
3132
# TODO: support accessibility woff2
3233
configure_options = '\
@@ -38,6 +39,7 @@ class Recipe(recipe.Recipe):
3839
-DENABLE_JOURNALD_LOG=OFF \
3940
-DENABLE_BUBBLEWRAP_SANDBOX=OFF \
4041
-DENABLE_SPEECH_SYNTHESIS=OFF \
42+
-DENABLE_WEBXR=ON \
4143
-DUSE_ATK=OFF \
4244
-DUSE_LCMS=OFF \
4345
-DUSE_AVIF=OFF \
@@ -93,12 +95,14 @@ class Recipe(recipe.Recipe):
9395
-DPNG_LIBRARY={self.config.prefix}/lib/libpng.so \
9496
-DPNG_INCLUDE_DIR={self.config.prefix}/include \
9597
'
98+
self.append_env('CXXFLAGS', '-DXR_USE_GRAPHICS_API_OPENGL_ES')
9699
if self.config.target_platform in (Platform.ANDROID):
97100
arch_src_name = self.config.target_arch
98101
if self.config.target_arch == Architecture.ARMv7:
99102
arch_src_name = 'arm'
100103
self.configure_options += ' -DCMAKE_SYSTEM_PROCESSOR=' + arch_src_name
101104
self.configure_options += ' -DANDROID=1'
105+
self.append_env('CXXFLAGS', '-DXR_USE_PLATFORM_ANDROID')
102106
# Placeholder to allow enabling debug externally
103107
self.append_env('WEBKIT_DEBUG', '')
104108
else:

0 commit comments

Comments
 (0)