From 40d4759f262a86bcebaf3a91d9d813f4d6a3ae10 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrgen=20Gehring?= Date: Fri, 16 Oct 2015 06:35:29 -0700 Subject: vSomeIP 1.3.0p2 --- CMakeLists.txt | 5 ++++- examples/vsomeipd.cpp | 18 ++++++++++++++++++ 2 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 examples/vsomeipd.cpp diff --git a/CMakeLists.txt b/CMakeLists.txt index fd8a193..07c91e4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -127,6 +127,9 @@ target_link_libraries(subscribe-sample vsomeip ${Boost_LIBRARIES} ${DL_LIBRARY}) add_executable(notify-sample examples/notify-sample.cpp ${EXAMPLE_CONFIG_FILES}) target_link_libraries(notify-sample vsomeip ${Boost_LIBRARIES} ${DL_LIBRARY}) +add_executable(vsomeipd examples/vsomeipd.cpp ${EXAMPLE_CONFIG_FILES}) +target_link_libraries(vsomeipd vsomeip ${Boost_LIBRARIES} ${DL_LIBRARY}) + ################################################################################################### file (GLOB_RECURSE vsomeip_INCLUDE "interface/*.hpp") @@ -149,7 +152,7 @@ install ( ) install ( - TARGETS request-sample response-sample subscribe-sample notify-sample + TARGETS request-sample response-sample subscribe-sample notify-sample vsomeipd RUNTIME DESTINATION "${INSTALL_BIN_DIR}" COMPONENT bin ) diff --git a/examples/vsomeipd.cpp b/examples/vsomeipd.cpp new file mode 100644 index 0000000..6d2ede7 --- /dev/null +++ b/examples/vsomeipd.cpp @@ -0,0 +1,18 @@ +// Copyright (C) 2014-2015 Bayerische Motoren Werke Aktiengesellschaft (BMW AG) +// This Source Code Form is subject to the terms of the Mozilla Public +// License, v. 2.0. If a copy of the MPL was not distributed with this +// file, You can obtain one at http://mozilla.org/MPL/2.0/. + +// Example(!) for the most simple daemon application + +#include + +int main(int argc, char **argv) { + std::shared_ptr its_daemon + = vsomeip::runtime::get()->create_application("vsomeipd"); + + if (its_daemon->init()) + its_daemon->start(); + + return 0; +} -- cgit v1.2.1