Skip to content

Commit

Permalink
ENH: Copy and install OpenXRRemoting libraries along side VTK libraries
Browse files Browse the repository at this point in the history
This requires VTK MR-10449 (see [1]) backported to Slicer/VTK through
the Slicer PR-7190 (see [2]).

[1] https://gitlab.kitware.com/vtk/vtk/-/merge_requests/10449
[2] Slicer/Slicer#7190
  • Loading branch information
jcfr committed Aug 28, 2023
1 parent 32f6141 commit 5d5db0b
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,36 @@ endif()
add_subdirectory(MixedReality)
## NEXT_MODULE

#-----------------------------------------------------------------------------
# Install OpenXRRemoting
#
# RemotingXR.json and companion files are copied or installed along side the
# vtkRenderingRemotingOpenXR library so that "vtkOpenXRManagerRemoteConnection::Initialize()"
# can locate the files and set the XR_RUNTIME_JSON env. variable
set(OpenXRRemoting_FILES )
if(WIN32)
set(OpenXRRemoting_FILES
Microsoft.Holographic.AppRemoting.OpenXr.dll
Microsoft.Holographic.AppRemoting.OpenXr.SU.dll
PerceptionDevice.dll
RemotingXR.json
)
endif()
set(_dest ${CMAKE_BINARY_DIR}/${Slicer_THIRDPARTY_BIN_DIR})
foreach(file IN LISTS OpenXRRemoting_FILES)
# Copy
message(STATUS "Copying ${file} to ${_dest}")
file(COPY ${OpenXRRemoting_BIN_DIR}/${file}
DESTINATION ${_dest}
USE_SOURCE_PERMISSIONS
)
# Install
install(FILES ${OpenXRRemoting_BIN_DIR}/${file}
DESTINATION ${Slicer_INSTALL_THIRDPARTY_BIN_DIR}
COMPONENT RuntimeLibraries
)
endforeach()

#-----------------------------------------------------------------------------
set(EXTENSION_CPACK_INSTALL_CMAKE_PROJECTS)
list(APPEND EXTENSION_CPACK_INSTALL_CMAKE_PROJECTS "${vtkRenderingVR_DIR};vtkRenderingVR;runtime;/")
Expand Down

0 comments on commit 5d5db0b

Please sign in to comment.