Skip to content

Commit

Permalink
Changes from OpenXR SDK 1.0.32.1 hotfix: Fix CMake build of loader on…
Browse files Browse the repository at this point in the history
… Universal Windows Platform

Also fix Azure Pipelines CI.

GitOrigin-RevId: 401db2742417b942e594e2717a39979ecdf1af8f
  • Loading branch information
rpavlik committed Dec 1, 2023
1 parent 8ecba63 commit e0e1879
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
1 change: 1 addition & 0 deletions HOTFIX
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1
11 changes: 7 additions & 4 deletions src/loader/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -205,17 +205,20 @@ elseif(WIN32)
)

if(MSVC)
if(DYNAMIC_LOADER)
target_sources(
openxr_loader
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/openxr-loader.def"
)
endif()

if(DYNAMIC_LOADER AND NOT (CMAKE_SYSTEM_NAME STREQUAL "WindowsStore"))
# If building DLLs, force static CRT linkage
set_target_properties(
openxr_loader
PROPERTIES MSVC_RUNTIME_LIBRARY
"MultiThreaded$<$<CONFIG:Debug>:Debug>"
)
target_sources(
openxr_loader
PRIVATE "${CMAKE_CURRENT_SOURCE_DIR}/openxr-loader.def"
)
else()
# WindowsStore (UWP) apps must be compiled with dynamic CRT linkage (default)
# Otherwise for static libs, link the CRT dynamically
Expand Down

0 comments on commit e0e1879

Please sign in to comment.