diff options
Diffstat (limited to 'indra')
-rw-r--r-- | indra/cmake/OpenXR.cmake | 22 | ||||
-rw-r--r-- | indra/newview/CMakeLists.txt | 2 |
2 files changed, 24 insertions, 0 deletions
diff --git a/indra/cmake/OpenXR.cmake b/indra/cmake/OpenXR.cmake new file mode 100644 index 0000000000..2cc862b927 --- /dev/null +++ b/indra/cmake/OpenXR.cmake @@ -0,0 +1,22 @@ +# -*- cmake -*- + +include(Prebuilt) + +include_guard() +add_library( ll::openxr INTERFACE IMPORTED ) + +if(USE_CONAN ) + target_link_libraries( ll::openxr INTERFACE CONAN_PKG::openxr ) + return() +endif() + +use_prebuilt_binary(openxr) +if (WINDOWS) + target_link_libraries( ll::openxr INTERFACE ${ARCH_PREBUILT_DIRS_RELEASE}/openxr_loader.lib ) +else() + target_link_libraries( ll::openxr INTERFACE ${ARCH_PREBUILT_DIRS_RELEASE}/libopenxr_loader.a ) +endif (WINDOWS) + +if( NOT LINUX ) + target_include_directories( ll::openxr SYSTEM INTERFACE ${LIBS_PREBUILT_DIR}/include) +endif() diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt index 7a9f3a46b5..859ccbd4cd 100644 --- a/indra/newview/CMakeLists.txt +++ b/indra/newview/CMakeLists.txt @@ -33,6 +33,7 @@ include(NVAPI) include(OPENAL) include(OpenGL) include(OpenSSL) +include(OpenXR) include(PNG) include(TemplateCheck) include(TinyEXR) @@ -1928,6 +1929,7 @@ target_link_libraries(${VIEWER_BINARY_NAME} ${LLPHYSICSEXTENSIONS_LIBRARIES} ll::bugsplat ll::tracy + ll::openxr ) if( TARGET ll::intel_memops ) |