-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathCMakeLists.txt
92 lines (72 loc) · 3.18 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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
cmake_minimum_required(VERSION 2.8.3)
project(gazebo_radiation_plugins)
add_definitions(-std=c++11)
find_package(catkin REQUIRED COMPONENTS
roscpp
gazebo_dev
gazebo_ros
pluginlib
message_generation
)
find_package(Boost REQUIRED COMPONENTS filesystem)
add_service_files(
FILES
EnvironmentEvolver.srv
GenWorldsFromModels.srv
GenYamlsFromWorld.srv
ConvertWorldBuilderModel.srv
GenRandomEnvironmentalEffects.srv
MassYamlLoader.srv
)
add_message_files(
FILES
Simulated_Radiation_Msg.msg
)
generate_messages(
DEPENDENCIES
std_msgs
geometry_msgs
)
catkin_package(
INCLUDE_DIRS include
LIBRARIES ${PROJECT_NAME} radiation_source radiation_source_plugin radiation_sensor radiation_sensor_plugin
CATKIN_DEPENDS gazebo_dev pluginlib rosbash message_runtime
)
include_directories(
include
${catkin_INCLUDE_DIRS}
${Boost_INCLUDE_DIRS}
)
add_library(custom_sensor_preloader SHARED src/CustomSensorPreloader.cpp)
add_dependencies(custom_sensor_preloader ${${PROJECT_NAME}_EXPORTED_TARGETS} ${catkin_EXPORTED_TARGETS})
target_link_libraries(custom_sensor_preloader ${catkin_LIBRARIES} ${Boost_LIBRARIES} ${GAZEBO_LIBRARIES})
add_library(radiation_source SHARED src/RadiationSource.cpp)
add_dependencies(radiation_source ${${PROJECT_NAME}_EXPORTED_TARGETS} ${catkin_EXPORTED_TARGETS})
target_link_libraries(radiation_source ${catkin_LIBRARIES} ${GAZEBO_LIBRARIES} ${IGNITION-MSGS_LIBRARIES})
add_library(radiation_source_plugin SHARED src/RadiationSourcePlugin.cpp)
add_dependencies(radiation_source_plugin ${${PROJECT_NAME}_EXPORTED_TARGETS} ${catkin_EXPORTED_TARGETS})
target_link_libraries(radiation_source_plugin ${catkin_LIBRARIES} ${GAZEBO_LIBRARIES} ${IGNITION-MSGS_LIBRARIES})
add_library(radiation_sensor SHARED src/RadiationSensor.cpp)
add_dependencies(radiation_sensor ${${PROJECT_NAME}_EXPORTED_TARGETS} ${catkin_EXPORTED_TARGETS})
target_link_libraries(radiation_sensor ${catkin_LIBRARIES} ${GAZEBO_LIBRARIES} ${IGNITION-MSGS_LIBRARIES})
add_library(radiation_sensor_plugin SHARED src/RadiationSensorPlugin.cpp)
add_dependencies(radiation_sensor_plugin ${${PROJECT_NAME}_EXPORTED_TARGETS} ${catkin_EXPORTED_TARGETS})
target_link_libraries(radiation_sensor_plugin ${catkin_LIBRARIES} ${GAZEBO_LIBRARIES} ${IGNITION-MSGS_LIBRARIES})
catkin_install_python(PROGRAMS scripts/generate_radiation_sources.py
DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION})
file(GENERATE
OUTPUT "${CATKIN_DEVEL_PREFIX}/${CATKIN_PACKAGE_BIN_DESTINATION}/gzserver"
INPUT "${CMAKE_CURRENT_SOURCE_DIR}/scripts/gzserver.in")
file(GENERATE
OUTPUT "${CATKIN_DEVEL_PREFIX}/${CATKIN_PACKAGE_BIN_DESTINATION}/gazebo"
INPUT "${CMAKE_CURRENT_SOURCE_DIR}/scripts/gazebo.in")
install(TARGETS custom_sensor_preloader radiation_source radiation_source_plugin radiation_sensor radiation_sensor_plugin
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
)
install(FILES
"${CATKIN_DEVEL_PREFIX}/${CATKIN_PACKAGE_BIN_DESTINATION}/gzserver"
"${CATKIN_DEVEL_PREFIX}/${CATKIN_PACKAGE_BIN_DESTINATION}/gazebo"
DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)
install(FILES radiation_source.xml DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION})
install(FILES radiation_sensor.xml DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION})