Skip to content

Commit ae82f4e

Browse files
Add CMake configuration for primitives examples
1 parent 51fbf82 commit ae82f4e

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

examples/CMakeLists.txt

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
set(PRIMITIVES_EXAMPLE_SOURCES
2+
ex01_default_arithmetic.cpp
3+
ex02_type_policy.cpp
4+
ex03_value_policy.cpp
5+
ex04_error_policy.cpp
6+
ex05_concurrency_policy.cpp
7+
ex06_custom_underlying.cpp
8+
ex07_custom_policy.cpp
9+
ex08_custom_operation.cpp
10+
)
11+
12+
foreach(example_source IN LISTS PRIMITIVES_EXAMPLE_SOURCES)
13+
get_filename_component(example_name ${example_source} NAME_WE)
14+
add_executable(${example_name} ${example_source})
15+
target_link_libraries(${example_name} PRIVATE mcpplibs-primitives)
16+
endforeach()

0 commit comments

Comments
 (0)