set(test1_suffixes sleep crash ill)
foreach(suffix ${test1_suffixes})
- configure_file(test1.c test1-default-${suffix}.c COPYONLY)
- add_executable(test1-default-${suffix} test1-default-${suffix}.c)
+ add_executable(test1-default-${suffix} test1.c)
set(DEFAULT_FLAGS_TARGETS test1-default-${suffix})
- configure_file(test1.c test1-custom-${suffix}.c COPYONLY)
- add_executable(test1-custom-${suffix} test1-custom-${suffix}.c)
+ add_executable(test1-custom-${suffix} test1.c)
set(CUSTOM_FLAGS_TARGETS test1-custom-${suffix})
endforeach()
+
pkg_check_modules (GLIB2 glib-2.0)
configure_file(test2.c test2-custom.c COPYONLY)
target_link_libraries(test2-custom ${GLIB2_LDFLAGS})
list(APPEND CUSTOM_FLAGS_TARGETS test2-custom)
-configure_file(test3.c test3-custom.c COPYONLY)
-add_executable(test3-custom test3-custom.c)
+add_executable(test3-custom test3.c)
target_include_directories(test3-custom SYSTEM PUBLIC ${GLIB2_INCLUDE_DIRS})
target_link_libraries(test3-custom ${GLIB2_LDFLAGS} -lpthread)
list(APPEND CUSTOM_FLAGS_TARGETS test3-custom)