diff options
Diffstat (limited to 'hl/test')
-rw-r--r-- | hl/test/CMakeLists.txt | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/hl/test/CMakeLists.txt b/hl/test/CMakeLists.txt index 43fc312..b7eac09 100644 --- a/hl/test/CMakeLists.txt +++ b/hl/test/CMakeLists.txt @@ -19,6 +19,7 @@ configure_file (${HDF5_HL_TEST_SOURCE_DIR}/H5srcdir_str.h.in H5srcdir_str.h @ON # -------------------------------------------------------------------- macro (HL_ADD_EXE hl_name) add_executable (hl_${hl_name} ${hl_name}.c) + target_compile_options(hl_${hl_name} PRIVATE "${HDF5_CMAKE_C_FLAGS}") target_include_directories (hl_${hl_name} PRIVATE "${HDF5_TEST_SRC_DIR};${HDF5_SRC_DIR};${HDF5_BINARY_DIR};$<$<BOOL:${HDF5_ENABLE_PARALLEL}>:${MPI_C_INCLUDE_DIRS}>") if (NOT BUILD_SHARED_LIBS) TARGET_C_PROPERTIES (hl_${hl_name} STATIC) @@ -49,6 +50,7 @@ HL_ADD_EXE (test_h5do_compat) # test_packet has two source files add_executable (hl_test_packet test_packet.c test_packet_vlen.c) + target_compile_options(hl_test_packet PRIVATE "${HDF5_CMAKE_C_FLAGS}") target_include_directories (hl_test_packet PRIVATE "${HDF5_TEST_SRC_DIR};${HDF5_SRC_DIR};${HDF5_BINARY_DIR};$<$<BOOL:${HDF5_ENABLE_PARALLEL}>:${MPI_C_INCLUDE_DIRS}>") if (NOT BUILD_SHARED_LIBS) TARGET_C_PROPERTIES (hl_test_packet STATIC) @@ -73,6 +75,7 @@ set_target_properties (hl_test_packet PROPERTIES FOLDER test/hl) # -------------------------------------------------------------------- if (HDF5_BUILD_GENERATORS AND NOT ONLY_SHARED_LIBS) add_executable (hl_gen_test_ds gen_test_ds.c) + target_compile_options(hl_gen_test_ds PRIVATE "${HDF5_CMAKE_C_FLAGS}") target_include_directories (hl_gen_test_ds PRIVATE "${HDF5_SRC_DIR};${HDF5_BINARY_DIR};$<$<BOOL:${HDF5_ENABLE_PARALLEL}>:${MPI_C_INCLUDE_DIRS}>") TARGET_C_PROPERTIES (hl_gen_test_ds STATIC) target_link_libraries (hl_gen_test_ds PRIVATE @@ -83,6 +86,7 @@ if (HDF5_BUILD_GENERATORS AND NOT ONLY_SHARED_LIBS) set_target_properties (hl_gen_test_ds PROPERTIES FOLDER test/hl/gen) add_executable (hl_gen_test_ld gen_test_ld.c) + target_compile_options(hl_gen_test_ld PRIVATE "${HDF5_CMAKE_C_FLAGS}") target_include_directories (hl_gen_test_ld PRIVATE "${HDF5_SRC_DIR};${HDF5_BINARY_DIR};$<$<BOOL:${HDF5_ENABLE_PARALLEL}>:${MPI_C_INCLUDE_DIRS}>") TARGET_C_PROPERTIES (hl_gen_test_ld STATIC) target_link_libraries (hl_gen_test_ld PRIVATE |