-
Notifications
You must be signed in to change notification settings - Fork 1
/
CMakeLists.txt
60 lines (51 loc) · 1.31 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
# Simulator Plugin
set(libs)
# OpenGL
find_package(OpenGL REQUIRED)
include_directories(${OPENGL_INCLUDE_DIR})
list(APPEND libs ${OPENGL_LIBRARIES})
# Qt5
find_package(Qt5 COMPONENTS Core Network Gui REQUIRED)
list(APPEND libs Qt5::Core Qt5::Network Qt5::Gui)
# ODE
find_package(ODE REQUIRED)
include_directories(${ODE_INCLUDE_DIRS})
list(APPEND libs ${ODE_LIBRARIES})
add_definitions(-DdDOUBLE)
# Protobuf
find_package(Protobuf REQUIRED)
include_directories(${PROTOBUF_INCLUDE_DIRS})
list(APPEND libs ${PROTOBUF_LIBRARIES})
file(GLOB PROTO_FILES "${CMAKE_SOURCE_DIR}/Utils/Protobuf/*.proto")
protobuf_generate_cpp(PROTO_CPP PROTO_H ${PROTO_FILES})
include_directories(
${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/physics
${CMAKE_SOURCE_DIR}/Utils
${CMAKE_SOURCE_DIR}/Utils/ZSPlugin
)
file(GLOB CPPFILES
"${CMAKE_SOURCE_DIR}/Utils/*.cpp"
"${CMAKE_CURRENT_SOURCE_DIR}/physics/*.cpp"
"${CMAKE_CURRENT_SOURCE_DIR}/*.cpp"
"${CMAKE_CURRENT_SOURCE_DIR}/physics/*.h"
"${CMAKE_CURRENT_SOURCE_DIR}/*.h"
)
set(HEADERS
sslworld.h
)
set(SOURCES
sslworld.cpp
)
set(srcs
${PROTO_CPP}
${PROTO_H}
${HEADERS}
${SOURCES}
${CPPFILES}
)
add_library(zss_simulator SHARED ${srcs})
target_link_libraries(zss_simulator ${libs})
install(TARGETS zss_simulator
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib)