<commit_before>cmake_minimum_required(VERSION 3.0)

set(ROOT_DIR ${CMAKE_CURRENT_LIST_DIR}/../..)
set(OPENVR_PLUGIN_INCL_DIRS)
set(OPENVR_PLUGIN_REQ_LIBS)
set(OPENVR_MONITOR_INCL_DIRS)
set(OPENVR_MONITOR_REQ_LIBS)

# platform independent include paths
list(APPEND OPENVR_PLUGIN_INCL_DIRS
    ${PSMOVECLIENT_INCLUDE_DIR}
)

#OpenVR
FIND_PACKAGE(OpenVR REQUIRED)
list(APPEND OPENVR_PLUGIN_INCL_DIRS ${OPENVR_INCLUDE_DIR})
list(APPEND OPENVR_PLUGIN_REQ_LIBS ${OPENVR_LIBRARIES})    
list(APPEND OPENVR_MONITOR_INCL_DIRS ${OPENVR_INCLUDE_DIR})
list(APPEND OPENVR_MONITOR_REQ_LIBS ${OPENVR_LIBRARIES})   
    
# platform independent libraries
list(APPEND OPENVR_PLUGIN_REQ_LIBS ${PSMOVECLIENT_LIB_DIR}/${PSMOVECLIENT_LIB_FILE})

# Shared library
add_library(driver_psmove SHARED driver_psmoveservice.cpp)
target_include_directories(driver_psmove PUBLIC ${OPENVR_PLUGIN_INCL_DIRS})
target_link_libraries(driver_psmove ${OPENVR_PLUGIN_REQ_LIBS})

# Monitor app
add_executable(monitor_psmove monitor_psmoveservice.cpp)
target_include_directories(monitor_psmove PUBLIC ${OPENVR_MONITOR_INCL_DIRS})
target_link_libraries(monitor_psmove ${OPENVR_LIBRARIES})

# Install    
IF(${CMAKE_SYSTEM_NAME} MATCHES "Windows")
install(TARGETS driver_psmove
	RUNTIME DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin
	LIBRARY DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/lib
	ARCHIVE DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/lib)
install(FILES $<TARGET_PDB_FILE:driver_psmove> 
	DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin OPTIONAL)
install(TARGETS monitor_psmove
	RUNTIME DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin
	LIBRARY DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/lib
	ARCHIVE DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/lib)    
install(FILES $<TARGET_PDB_FILE:monitor_psmove> 
	DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin OPTIONAL)
install(DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/
    DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin
    FILES_MATCHING PATTERN "*${ARCH_LABEL}.bat" PATTERN "*.vrdrivermanifest")
install(DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/resources
    DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin
    FILES_MATCHING PATTERN "*.png" PATTERN "*.tga" PATTERN "*.json" PATTERN "*.obj" PATTERN "*.mtl")
install(DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/configuration
    DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin
    FILES_MATCHING PATTERN "*.vricons")
install(DIRECTORY ${PSMOVESERVICE_BIN_DIR}/assets
	DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin OPTIONAL)    
install(FILES ${PSMOVESERVICE_BIN_DIR}/PSMoveClient_CAPI.dll
    ${PSMOVESERVICE_BIN_DIR}/PSMoveConfigTool.exe
    ${PSMOVESERVICE_BIN_DIR}/PSMoveService.exe
    ${PSMOVESERVICE_BIN_DIR}/test_camera.exe
    ${PSMOVESERVICE_BIN_DIR}/test_camera_parallel.exe
    ${PSMOVESERVICE_BIN_DIR}/test_console_CAPI.exe
    ${PSMOVESERVICE_BIN_DIR}/test_ds4_controller.exe
    ${PSMOVESERVICE_BIN_DIR}/test_navi_controller.exe
    ${PSMOVESERVICE_BIN_DIR}/test_psmove_controller.exe
	DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin OPTIONAL)    
ELSE() #Linux/Darwin
ENDIF()
<commit_msg>Fix for issue #3 (Issue with installing the .bat files) * Added missing openvr dll to the driver installation<commit_after>cmake_minimum_required(VERSION 3.0)

set(ROOT_DIR ${CMAKE_CURRENT_LIST_DIR}/../..)
set(OPENVR_PLUGIN_INCL_DIRS)
set(OPENVR_PLUGIN_REQ_LIBS)
set(OPENVR_MONITOR_INCL_DIRS)
set(OPENVR_MONITOR_REQ_LIBS)

# platform independent include paths
list(APPEND OPENVR_PLUGIN_INCL_DIRS
    ${PSMOVECLIENT_INCLUDE_DIR}
)

#OpenVR
FIND_PACKAGE(OpenVR REQUIRED)
list(APPEND OPENVR_PLUGIN_INCL_DIRS ${OPENVR_INCLUDE_DIR})
list(APPEND OPENVR_PLUGIN_REQ_LIBS ${OPENVR_LIBRARIES})    
list(APPEND OPENVR_MONITOR_INCL_DIRS ${OPENVR_INCLUDE_DIR})
list(APPEND OPENVR_MONITOR_REQ_LIBS ${OPENVR_LIBRARIES})   
    
# platform independent libraries
list(APPEND OPENVR_PLUGIN_REQ_LIBS ${PSMOVECLIENT_LIB_DIR}/${PSMOVECLIENT_LIB_FILE})

# Shared library
add_library(driver_psmove SHARED driver_psmoveservice.cpp)
target_include_directories(driver_psmove PUBLIC ${OPENVR_PLUGIN_INCL_DIRS})
target_link_libraries(driver_psmove ${OPENVR_PLUGIN_REQ_LIBS})

# Monitor app
add_executable(monitor_psmove monitor_psmoveservice.cpp)
target_include_directories(monitor_psmove PUBLIC ${OPENVR_MONITOR_INCL_DIRS})
target_link_libraries(monitor_psmove ${OPENVR_LIBRARIES})

# Install    
IF(${CMAKE_SYSTEM_NAME} MATCHES "Windows")
install(TARGETS driver_psmove
	RUNTIME DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin
	LIBRARY DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/lib
	ARCHIVE DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/lib)
install(FILES $<TARGET_PDB_FILE:driver_psmove> 
	DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin OPTIONAL)
install(TARGETS monitor_psmove
	RUNTIME DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin
	LIBRARY DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/lib
	ARCHIVE DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/lib)    
install(FILES $<TARGET_PDB_FILE:monitor_psmove> 
	DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin OPTIONAL)
install(DIRECTORY ${OPENVR_BINARIES_DIR}/ 
        DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin
        FILES_MATCHING PATTERN "*.dll" PATTERN "*.pdb")     
install(DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/
    DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin
    FILES_MATCHING PATTERN "*${ARCH_LABEL}.bat" PATTERN "*.vrdrivermanifest")
install(DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/resources
    DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin
    FILES_MATCHING PATTERN "*.png" PATTERN "*.tga" PATTERN "*.json" PATTERN "*.obj" PATTERN "*.mtl")
install(DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/configuration
    DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin
    FILES_MATCHING PATTERN "*.vricons")
install(DIRECTORY ${PSMOVESERVICE_BIN_DIR}/assets
	DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin OPTIONAL)    
install(FILES ${PSMOVESERVICE_BIN_DIR}/PSMoveClient_CAPI.dll
    ${PSMOVESERVICE_BIN_DIR}/PSMoveConfigTool.exe
    ${PSMOVESERVICE_BIN_DIR}/PSMoveService.exe
    ${PSMOVESERVICE_BIN_DIR}/test_camera.exe
    ${PSMOVESERVICE_BIN_DIR}/test_camera_parallel.exe
    ${PSMOVESERVICE_BIN_DIR}/test_console_CAPI.exe
    ${PSMOVESERVICE_BIN_DIR}/test_ds4_controller.exe
    ${PSMOVESERVICE_BIN_DIR}/test_navi_controller.exe
    ${PSMOVESERVICE_BIN_DIR}/test_psmove_controller.exe
	DESTINATION ${ROOT_DIR}/${PSM_DRIVER_PROJECT_NAME}/${ARCH_LABEL}/bin OPTIONAL)    
ELSE() #Linux/Darwin
ENDIF()

{'fraction_non_alphanumeric': 0.11544574483456148, 'fraction_numerical': 0.0010114145354717526, 'mean_word_length': 8.521320495185694, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2741768', 'n_tokens_mistral': 2786, 'n_tokens_neox': 2665, 'n_words': 312}