-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeLists.txt
61 lines (51 loc) · 1.49 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
#
# InvenSense plugin for OSVR
#
cmake_minimum_required(VERSION 3.0.0)
project(com_sensics_InvenSense)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
find_package(osvr REQUIRED)
find_package(invn REQUIRED)
find_package(jsoncpp REQUIRED)
# Generate our JSON header file
osvr_convert_json(com_sensics_InvenSense_json
com_sensics_InvenSense.json
"${CMAKE_CURRENT_BINARY_DIR}/com_sensics_InvenSense_json.h")
# Be able to find our generated header file.
include_directories("${CMAKE_CURRENT_BINARY_DIR}")
include_directories("${CMAKE_CURRENT_SOURCE_DIR}/vendor/invn/include")
include_directories("${CMAKE_CURRENT_SOURCE_DIR}/vendor/invn/sources")
include_directories("${CMAKE_CURRENT_SOURCE_DIR}/vendor/invn/external/include")
include_directories("${CMAKE_CURRENT_SOURCE_DIR}/quat")
add_subdirectory(quat)
# Build and install the plugin
osvr_add_plugin(com_sensics_InvenSense
com_sensics_InvenSense.cpp
InvenSenseController.h
InvenSenseController.cpp
DeviceInstance.h
DeviceInstance.cpp
"${CMAKE_CURRENT_BINARY_DIR}/com_sensics_InvenSense_json.h")
target_link_libraries(com_sensics_InvenSense
osvr::osvrPluginKitCpp
osvr::osvrUtil
IDDClient
IDD
IDDHostAdapter
EmbUtils
DynamicProtocol
IDDDeviceEmdWrapIcm20xxx
IDDHostUtils
PocoNetmd
PocoUtilmd
PocoXMLmd
PocoFoundationmd
PocoJSONmd
ws2_32
iphlpapi
jsoncpp_lib
quat)
# Install docs, license, sample config
install(FILES
osvr_server_config.InvenSense.sample.json
DESTINATION .)