X-Git-Url: https://gerrit.automotivelinux.org/gerrit/gitweb?a=blobdiff_plain;f=src%2FCMakeLists.txt;h=5da7e6effda820b8634499b2574bb6c32eea4c43;hb=refs%2Ftags%2Flamprey%2F12.1.6;hp=f568da1c83ac99de964882192ad367a3bfaac08a;hpb=92f95384ce4b4a198b1fea93272201421f7b9a39;p=src%2Flow-level-can-generator.git diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index f568da1..5da7e6e 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -17,28 +17,35 @@ ########################################################################### # Add target to project dependency list -PROJECT_TARGET_ADD(can-config-generator) +set(TARGET_NAME can-config-generator) - # Define project Targets - add_executable(${TARGET_NAME} - main.cpp - openxc/message_set.cpp - openxc/can_bus.cpp - openxc/can_message.cpp - openxc/command.cpp - openxc/diagnostic_message.cpp - openxc/mapping.cpp - openxc/signal.cpp) - - TARGET_INCLUDE_DIRECTORIES(${TARGET_NAME} - PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/../3rdparty/json +# Define project Targets +add_executable(${TARGET_NAME} + main.cpp + openxc/message_set.cpp + openxc/can_bus.cpp + openxc/can_message.cpp + openxc/command.cpp + openxc/diagnostic_message.cpp + openxc/mapping.cpp + openxc/signal.cpp + openxc/decoder.cpp ) - # Library dependencies (include updates automatically) - TARGET_LINK_LIBRARIES(can-config-generator - ${link_libraries} - ) +TARGET_INCLUDE_DIRECTORIES(${TARGET_NAME} + PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/../3rdparty/json +) + +# Library dependencies (include updates automatically) +TARGET_LINK_LIBRARIES(${TARGET_NAME} + ${link_libraries} +) + +# installation directory +INSTALL(TARGETS ${TARGET_NAME} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}) - # installation directory - INSTALL(TARGETS can-config-generator - RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) +# Print a helper message when every thing is finished +# ---------------------------------------------------- +set(CLOSING_MESSAGE "Test with: ./src/can-config-generator -m ../tests/basic.json -o application-generated.cpp")