diff options
-rw-r--r-- | CMakeLists.txt | 23 |
1 files changed, 19 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 10f6503..b25cc89 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -84,17 +84,28 @@ file(GLOB vsomeip-sd_SRC add_library(vsomeip-sd SHARED ${vsomeip-sd_SRC})
target_link_libraries(vsomeip-sd vsomeip ${Boost_LIBRARIES} rt ${DL_LIBRARY})
+# Configuration files
+
+set(EXAMPLE_CONFIG_FILES
+ "config/vsomeip.json"
+ "config/vsomeip-local.json"
+ "config/vsomeip-tcp-client.json"
+ "config/vsomeip-tcp-service.json"
+ "config/vsomeip-udp-client.json"
+ "config/vsomeip-udp-service.json"
+)
+
# Examples
-add_executable(request-sample examples/request-sample.cpp)
+add_executable(request-sample examples/request-sample.cpp ${EXAMPLE_CONFIG_FILES})
target_link_libraries(request-sample vsomeip ${Boost_LIBRARIES} ${DL_LIBRARY})
-add_executable(response-sample examples/response-sample.cpp)
+add_executable(response-sample examples/response-sample.cpp ${EXAMPLE_CONFIG_FILES})
target_link_libraries(response-sample vsomeip ${Boost_LIBRARIES} ${DL_LIBRARY})
-add_executable(subscribe-sample examples/subscribe-sample.cpp)
+add_executable(subscribe-sample examples/subscribe-sample.cpp ${EXAMPLE_CONFIG_FILES})
target_link_libraries(subscribe-sample vsomeip ${Boost_LIBRARIES} ${DL_LIBRARY})
-add_executable(notify-sample examples/notify-sample.cpp)
+add_executable(notify-sample examples/notify-sample.cpp ${EXAMPLE_CONFIG_FILES})
target_link_libraries(notify-sample vsomeip ${Boost_LIBRARIES} ${DL_LIBRARY})
# Test
@@ -129,6 +140,10 @@ install ( RUNTIME DESTINATION "${INSTALL_BIN_DIR}" COMPONENT bin
)
+install (
+ FILES ${EXAMPLE_CONFIG_FILES} DESTINATION etc/vsomeip COMPONENT config
+)
+
# Add all targets to the build-tree export set
export (TARGETS vsomeip FILE "${PROJECT_BINARY_DIR}/vSomeIPTargets.cmake")
|