diff options
author | Allen Byrne <byrn@hdfgroup.org> | 2018-10-02 21:16:34 (GMT) |
---|---|---|
committer | Allen Byrne <byrn@hdfgroup.org> | 2018-10-02 21:17:10 (GMT) |
commit | 8c26358eca11455235df239a7e9f3a225b3141da (patch) | |
tree | f9ae4061b519ae7c516830a59a92faba93f9f006 /hl/examples | |
parent | 66ef37d0d8030f38c924374facc49f6af6f6ddd5 (diff) | |
download | hdf5-8c26358eca11455235df239a7e9f3a225b3141da.zip hdf5-8c26358eca11455235df239a7e9f3a225b3141da.tar.gz hdf5-8c26358eca11455235df239a7e9f3a225b3141da.tar.bz2 |
Merge CMake changes from 1.10 to 1.8
Diffstat (limited to 'hl/examples')
-rw-r--r-- | hl/examples/CMakeLists.txt | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/hl/examples/CMakeLists.txt b/hl/examples/CMakeLists.txt index 79dfee1..97c6de5 100644 --- a/hl/examples/CMakeLists.txt +++ b/hl/examples/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required (VERSION 3.10) -PROJECT (HDF5_HL_EXAMPLES ) +project (HDF5_HL_EXAMPLES C) #----------------------------------------------------------------------------- # Define Sources @@ -28,8 +28,9 @@ set (examples foreach (example ${examples}) add_executable (hl_ex_${example} ${HDF5_HL_EXAMPLES_SOURCE_DIR}/${example}.c) - TARGET_C_PROPERTIES (hl_ex_${example} STATIC " " " ") - target_link_libraries (hl_ex_${example} ${HDF5_HL_LIB_TARGET} ${HDF5_LIB_TARGET}) + target_include_directories(hl_ex_${example} PRIVATE "${HDF5_SRC_DIR};${HDF5_BINARY_DIR};$<$<BOOL:${HDF5_ENABLE_PARALLEL}>:${MPI_C_INCLUDE_DIRS}>") + TARGET_C_PROPERTIES (hl_ex_${example} STATIC) + target_link_libraries (hl_ex_${example} PRIVATE ${HDF5_HL_LIB_TARGET} ${HDF5_LIB_TARGET}) set_target_properties (hl_ex_${example} PROPERTIES FOLDER examples/hl) endforeach () |