Skip to content

Commit

Permalink
iox-eclipse-iceoryx#433 add flags to examples
Browse files Browse the repository at this point in the history
Signed-off-by: Dietrich Krönke <[email protected]>
  • Loading branch information
dkroenke committed Dec 22, 2020
1 parent 3dd0643 commit af57383
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 4 deletions.
10 changes: 6 additions & 4 deletions iceoryx_examples/ice_multi_publisher/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,17 @@ endif()

add_executable(iox-multi-publisher ./ice_multi_publisher.cpp)
target_link_libraries(iox-multi-publisher iceoryx_posh::iceoryx_posh)
target_compile_options(iox-multi-publisher PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-subscriber ./ice_subscriber.cpp)
target_link_libraries(iox-subscriber iceoryx_posh::iceoryx_posh)
add_executable(iox-multi-subscriber ./ice_subscriber.cpp)
target_link_libraries(iox-multi-subscriber iceoryx_posh::iceoryx_posh)
target_compile_options(iox-multi-subscriber PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

set_target_properties(
iox-subscriber iox-multi-publisher
iox-multi-subscriber iox-multi-publisher
PROPERTIES CXX_STANDARD_REQUIRED ON
CXX_STANDARD ${ICEORYX_CXX_STANDARD}
POSITION_INDEPENDENT_CODE ON)

install(TARGETS iox-multi-publisher iox-subscriber
install(TARGETS iox-multi-publisher iox-multi-subscriber
RUNTIME DESTINATION bin)
6 changes: 6 additions & 0 deletions iceoryx_examples/icedelivery/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -30,31 +30,37 @@ add_executable(iox-ex-publisher-typed ./iox_publisher_typed.cpp)
target_link_libraries(iox-ex-publisher-typed
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-publisher-typed PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-publisher-with-history ./iox_publisher_with_history.cpp)
target_link_libraries(iox-ex-publisher-with-history
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-publisher-with-history PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-publisher-untyped ./iox_publisher_untyped.cpp)
target_link_libraries(iox-ex-publisher-untyped
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-publisher-untyped PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-subscriber-typed ./iox_subscriber_typed.cpp)
target_link_libraries(iox-ex-subscriber-typed
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-subscriber-typed PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-subscriber-with-history ./iox_subscriber_with_history.cpp)
target_link_libraries(iox-ex-subscriber-with-history
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-subscriber-with-history PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-subscriber-untyped ./iox_subscriber_untyped.cpp)
target_link_libraries(iox-ex-subscriber-untyped
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-subscriber-untyped PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

set_target_properties(iox-ex-subscriber-typed iox-ex-subscriber-untyped
iox-ex-publisher-with-history iox-ex-subscriber-with-history
Expand Down
2 changes: 2 additions & 0 deletions iceoryx_examples/icedelivery_on_c/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ target_link_libraries(iox-c-publisher
set_target_properties(iox-c-publisher PROPERTIES
POSITION_INDEPENDENT_CODE ON
)
target_compile_options(iox-c-publisher PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-c-subscriber ./ice_c_subscriber.c)
set_source_files_properties(./ice_c_subscriber.c PROPERTIES LANGUAGE C)
Expand All @@ -46,6 +47,7 @@ target_link_libraries(iox-c-subscriber
set_target_properties(iox-c-subscriber PROPERTIES
POSITION_INDEPENDENT_CODE ON
)
target_compile_options(iox-c-subscriber PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

install(
TARGETS iox-c-publisher iox-c-subscriber
Expand Down
1 change: 1 addition & 0 deletions iceoryx_examples/singleprocess/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ set_target_properties(single_process PROPERTIES
CXX_STANDARD ${ICEORYX_CXX_STANDARD}
POSITION_INDEPENDENT_CODE ON
)
target_compile_options(single_process PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

install(
TARGETS single_process
Expand Down
6 changes: 6 additions & 0 deletions iceoryx_examples/waitset/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,31 +28,37 @@ add_executable(iox-ex-waitset-publisher ./ice_waitset_publisher.cpp)
target_link_libraries(iox-ex-waitset-publisher
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-waitset-publisher PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-waitset-gateway ./ice_waitset_gateway.cpp)
target_link_libraries(iox-ex-waitset-gateway
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-waitset-gateway PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-waitset-grouping ./ice_waitset_grouping.cpp)
target_link_libraries(iox-ex-waitset-grouping
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-waitset-grouping PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-waitset-individual ./ice_waitset_individual.cpp)
target_link_libraries(iox-ex-waitset-individual
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-waitset-individual PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-waitset-sync ./ice_waitset_sync.cpp)
target_link_libraries(iox-ex-waitset-sync
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-waitset-sync PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-waitset-trigger ./ice_waitset_trigger.cpp)
target_link_libraries(iox-ex-waitset-trigger
iceoryx_posh::iceoryx_posh
)
target_compile_options(iox-ex-waitset-trigger PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

set_target_properties(
iox-ex-waitset-trigger
Expand Down
5 changes: 5 additions & 0 deletions iceoryx_examples/waitset_on_c/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -30,30 +30,35 @@ target_link_libraries(iox-ex-c-waitset-publisher
iceoryx_posh::iceoryx_posh
iceoryx_binding_c::iceoryx_binding_c
)
target_compile_options(iox-ex-c-waitset-publisher PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-c-waitset-gateway ./ice_c_waitset_gateway.c)
target_link_libraries(iox-ex-c-waitset-gateway
iceoryx_posh::iceoryx_posh
iceoryx_binding_c::iceoryx_binding_c
)
target_compile_options(iox-ex-c-waitset-gateway PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-c-waitset-grouping ./ice_c_waitset_grouping.c)
target_link_libraries(iox-ex-c-waitset-grouping
iceoryx_posh::iceoryx_posh
iceoryx_binding_c::iceoryx_binding_c
)
target_compile_options(iox-ex-c-waitset-grouping PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-c-waitset-individual ./ice_c_waitset_individual.c)
target_link_libraries(iox-ex-c-waitset-individual
iceoryx_posh::iceoryx_posh
iceoryx_binding_c::iceoryx_binding_c
)
target_compile_options(iox-ex-c-waitset-individual PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

add_executable(iox-ex-c-waitset-sync ./ice_c_waitset_sync.c)
target_link_libraries(iox-ex-c-waitset-sync
iceoryx_posh::iceoryx_posh
iceoryx_binding_c::iceoryx_binding_c
)
target_compile_options(iox-ex-c-waitset-sync PRIVATE ${ICEORYX_WARNINGS} ${ICEORYX_SANITIZER_FLAGS})

set_source_files_properties(
./ice_c_waitset_sync.c
Expand Down

0 comments on commit af57383

Please sign in to comment.