diff options
Diffstat (limited to 'video-ps3eye/CMakeLists.txt')
-rw-r--r-- | video-ps3eye/CMakeLists.txt | 33 |
1 files changed, 20 insertions, 13 deletions
diff --git a/video-ps3eye/CMakeLists.txt b/video-ps3eye/CMakeLists.txt index d42c83ff..888c4fc7 100644 --- a/video-ps3eye/CMakeLists.txt +++ b/video-ps3eye/CMakeLists.txt @@ -21,18 +21,6 @@ if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/ps3eye-driver/CMakeLists.txt") endif() endif() -if(TARGET ps3eye-driver) - otr_module(video-ps3eye) - link_libraries(ps3eye-driver) - add_executable(ps3eye-subprocess "wrapper.cxx") - if(WIN32) - set(path "${SDK_LIBUSB}/libusb-1.0.dll") - if(EXISTS "${path}") - otr_install_lib("${path}" "${opentrack-hier-pfx}") - endif() - endif() -endif() - if(TARGET ps3eye-sdl) install(TARGETS "ps3eye-sdl" DESTINATION "${opentrack-hier-pfx}") if(WIN32) @@ -51,6 +39,25 @@ if(TARGET ps3eye-mode-test) install(TARGETS "ps3eye-mode-test" DESTINATION "${opentrack-hier-pfx}") endif() +if(TARGET ps3eye-driver) + add_executable(ps3eye-subprocess "wrapper.cxx" "shm.cxx") + if(CMAKE_HOST_SYSTEM_NAME STREQUAL "Linux") + target_link_libraries(ps3eye-subprocess rt ps3eye-driver) + endif() + install(TARGETS "ps3eye-subprocess" DESTINATION "${opentrack-hier-pfx}") +endif() + +if(TARGET ps3eye-subprocess) + otr_module(video-ps3eye) + link_libraries(ps3eye-driver) + if(WIN32) + set(path "${SDK_LIBUSB}/libusb-1.0.dll") + if(EXISTS "${path}") + otr_install_lib("${path}" "${opentrack-hier-pfx}") + endif() + endif() +endif() + if(TARGET ps3eye-frame-test) install(TARGETS "ps3eye-frame-test" DESTINATION "${opentrack-hier-pfx}") -endif()
\ No newline at end of file +endif() |