Skip to content

Commit da1a461

Browse files
fixes
1 parent 6f401bc commit da1a461

5 files changed

Lines changed: 12 additions & 17 deletions

File tree

.azure-pipelines/generate_windows_matrix_build.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
configs = {}
1212
for platform, debug, uwp in product(PLATFORMS, (False,), TRUE_FALSE):
1313
# No need to support ARM/ARM64 except for UWP.
14-
if uwp and (platform.lower() == 'arm' or platform.lower() == 'arm64'):
14+
if not uwp and (platform.lower() == 'arm' or platform.lower() == 'arm64'):
1515
continue
1616

1717
label = [platform]

src/CMakeLists.txt

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,16 @@ include(GNUInstallDirs)
2828
set(OpenGL_GL_PREFERENCE GLVND)
2929
if (NOT CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
3030
# OpenGL package will be found for UWP apps but gl.h excludes UWP apps so it isn't actually usable.
31-
find_package(OpenGL)
31+
find_package(OpenGL)
3232
endif()
3333

3434
if(OPENGL_FOUND)
3535
add_definitions(-DXR_USE_GRAPHICS_API_OPENGL)
3636
message(STATUS "Enabling OpenGL support")
3737
elseif(BUILD_ALL_EXTENSIONS)
38-
message(FATAL_ERROR "OpenGL not found")
38+
if (NOT CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
39+
message(FATAL_ERROR "OpenGL not found")
40+
endif()
3941
endif()
4042

4143
if(NOT CMAKE_VERSION VERSION_LESS 3.7.0)
@@ -116,6 +118,11 @@ endif()
116118
# Several files use these compile-time platform switches
117119
if(WIN32)
118120
add_definitions(-DXR_USE_PLATFORM_WIN32)
121+
# TODO remove once work is done to get more stuff building for UWP.
122+
if (CMAKE_SYSTEM_NAME STREQUAL "WindowsStore")
123+
set(BUILD_TESTS OFF)
124+
set(BUILD_CONFORMANCE_TESTS OFF)
125+
endif()
119126
elseif(PRESENTATION_BACKEND MATCHES "xlib")
120127
add_definitions(-DXR_USE_PLATFORM_XLIB)
121128
elseif(PRESENTATION_BACKEND MATCHES "xcb")

src/tests/hello_xr/CMakeLists.txt

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -69,11 +69,7 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Windows")
6969
target_compile_definitions(hello_xr PRIVATE _CRT_SECURE_NO_WARNINGS)
7070
target_compile_options(hello_xr PRIVATE /Zc:wchar_t /Zc:forScope /W4 /WX)
7171
endif()
72-
target_link_libraries(hello_xr d3d11 d3d12 d3dcompiler dxgi ole32)
73-
74-
if(OPENGL_FOUND)
75-
target_link_libraries(hello_xr ${OPENGL_gl_LIBRARY})
76-
endif()
72+
target_link_libraries(hello_xr d3d11 d3d12 d3dcompiler dxgi ole32 ${OPENGL_gl_LIBRARY})
7773
elseif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
7874
target_compile_options(hello_xr PRIVATE -Wall)
7975
target_link_libraries(hello_xr m pthread)

src/tests/list/CMakeLists.txt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,6 @@ endif()
3838
if(CMAKE_SYSTEM_NAME STREQUAL "Windows")
3939
target_compile_options(runtime_list PRIVATE /Zc:wchar_t /Zc:forScope /W4 /WX)
4040
target_link_libraries(runtime_list openxr_loader)
41-
if(OPENGL_FOUND)
42-
target_link_libraries(runtime_list ${OPENGL_gl_LIBRARY})
43-
endif()
4441
endif()
4542

4643
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")

src/tests/loader_test/CMakeLists.txt

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,12 +45,7 @@ endif()
4545
if(CMAKE_SYSTEM_NAME STREQUAL "Windows")
4646
target_compile_definitions(loader_test PRIVATE _CRT_SECURE_NO_WARNINGS)
4747
target_compile_options(loader_test PRIVATE /Zc:wchar_t /Zc:forScope /W4 /WX)
48-
target_link_libraries(loader_test openxr_loader d3d11)
49-
50-
if(OPENGL_FOUND)
51-
target_link_libraries(loader_test ${OPENGL_gl_LIBRARY})
52-
endif()
53-
48+
target_link_libraries(loader_test openxr_loader)
5449
elseif(CMAKE_SYSTEM_NAME STREQUAL "Linux")
5550
target_compile_options(
5651
loader_test PRIVATE -Wall -Wno-unused-function -Wno-format-truncation

0 commit comments

Comments
 (0)