- add_executable (macro-shared macro-shared/macro-shared.c)
- target_link_libraries(macro-shared simgrid)
- set_target_properties(macro-shared PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/macro-shared)
-
- add_executable (macro-partial-shared macro-partial-shared/macro-partial-shared.c)
- target_link_libraries(macro-partial-shared simgrid)
- set_target_properties(macro-partial-shared PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/macro-partial-shared)
-
- add_executable (macro-partial-shared-communication macro-partial-shared-communication/macro-partial-shared-communication.c)
- target_link_libraries(macro-partial-shared-communication simgrid)
- set_target_properties(macro-partial-shared-communication PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/macro-partial-shared-communication)
+ foreach(x macro-shared macro-partial-shared macro-partial-shared-communication )
+ add_executable (${x} ${x}/${x}.c)
+ target_link_libraries(${x} simgrid)
+ set_target_properties(${x} PROPERTIES RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/${x})
+
+ set(tesh_files ${tesh_files} ${CMAKE_CURRENT_SOURCE_DIR}/${x}/${x}.tesh)
+ set(teshsuite_src ${teshsuite_src} ${CMAKE_CURRENT_SOURCE_DIR}/${x}/${x}.c)
+ endforeach()