18 lines
433 B
CMake
18 lines
433 B
CMake
if (NOT BUILD_TESTING)
|
|
message("-- Examples disabled")
|
|
return()
|
|
endif()
|
|
message("-- Examples enabled")
|
|
|
|
set(EXAMPLES
|
|
rpc/reader
|
|
)
|
|
|
|
foreach(example ${EXAMPLES})
|
|
string(REPLACE "/" "_" target ${example})
|
|
add_executable(example_${target} ${example}.cpp)
|
|
add_dependencies(example_${target} dipp)
|
|
target_link_libraries(example_${target} dipp)
|
|
set_target_properties(example_${target} PROPERTIES OUTPUT_NAME ${target})
|
|
endforeach()
|