diff options
Diffstat (limited to 'tools')
-rw-r--r-- | tools/h5copy/CMakeLists.txt | 6 | ||||
-rw-r--r-- | tools/h5diff/CMakeLists.txt | 6 | ||||
-rw-r--r-- | tools/h5dump/CMakeLists.txt | 20 | ||||
-rw-r--r-- | tools/h5import/CMakeLists.txt | 2 | ||||
-rw-r--r-- | tools/h5jam/CMakeLists.txt | 6 | ||||
-rw-r--r-- | tools/h5ls/CMakeLists.txt | 6 | ||||
-rw-r--r-- | tools/h5repack/CMakeLists.txt | 8 | ||||
-rw-r--r-- | tools/h5stat/CMakeLists.txt | 6 | ||||
-rw-r--r-- | tools/lib/CMakeLists.txt | 17 | ||||
-rw-r--r-- | tools/misc/CMakeLists.txt | 9 |
10 files changed, 50 insertions, 36 deletions
diff --git a/tools/h5copy/CMakeLists.txt b/tools/h5copy/CMakeLists.txt index 2cb3a43..b9dad2d 100644 --- a/tools/h5copy/CMakeLists.txt +++ b/tools/h5copy/CMakeLists.txt @@ -4,7 +4,7 @@ PROJECT (HDF5_TOOLS_H5COPY) #----------------------------------------------------------------------------- # Setup include Directories #----------------------------------------------------------------------------- -INCLUDE_DIRECTORIES (${HDF5_TOOLS_SOURCE_DIR}/lib) +INCLUDE_DIRECTORIES (${HDF5_TOOLS_SRC_DIR}/lib) INCLUDE_DIRECTORIES (${HDF5_PROJECT_DIR}/test) # -------------------------------------------------------------------- @@ -33,7 +33,7 @@ SET (H5_DEP_EXECUTABLES h5copy) ############################################################################## IF (BUILD_TESTING) - IF (NOT BUILD_SHARED_LIBS) + IF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) ADD_EXECUTABLE (h5copygentest ${HDF5_TOOLS_H5COPY_SOURCE_DIR}/h5copygentest.c) H5_NAMING (h5copygentest) IF (WIN32) @@ -47,7 +47,7 @@ IF (BUILD_TESTING) TARGET_LINK_LIBRARIES (h5copygentest ${HDF5_LIB_TARGET} ${HDF5_TOOLS_LIB_TARGET}) #ADD_TEST (NAME h5copygentest COMMAND $<TARGET_FILE:h5copygentest>) - ENDIF (NOT BUILD_SHARED_LIBS) + ENDIF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) # -------------------------------------------------------------------- # Copy all the HDF5 files from the test directory into the source directory diff --git a/tools/h5diff/CMakeLists.txt b/tools/h5diff/CMakeLists.txt index 05aabf69..1342cd2 100644 --- a/tools/h5diff/CMakeLists.txt +++ b/tools/h5diff/CMakeLists.txt @@ -4,7 +4,7 @@ PROJECT (HDF5_TOOLS_H5DIFF) #----------------------------------------------------------------------------- # Setup include Directories #----------------------------------------------------------------------------- -INCLUDE_DIRECTORIES (${HDF5_TOOLS_SOURCE_DIR}/lib) +INCLUDE_DIRECTORIES (${HDF5_TOOLS_SRC_DIR}/lib) INCLUDE_DIRECTORIES (${HDF5_PROJECT_DIR}/test) # -------------------------------------------------------------------- @@ -39,7 +39,7 @@ IF (BUILD_TESTING) # -------------------------------------------------------------------- # Add the h5diff and test executables # -------------------------------------------------------------------- - IF (NOT BUILD_SHARED_LIBS) + IF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) ADD_EXECUTABLE (h5diffgentest ${HDF5_TOOLS_H5DIFF_SOURCE_DIR}/h5diffgentest.c) H5_NAMING (h5diffgentest) IF (WIN32) @@ -53,7 +53,7 @@ IF (BUILD_TESTING) TARGET_LINK_LIBRARIES (h5diffgentest ${HDF5_LIB_TARGET} ${HDF5_TOOLS_LIB_TARGET}) #ADD_TEST (NAME h5diffgentest COMMAND $<TARGET_FILE:h5diffgentest>) - ENDIF (NOT BUILD_SHARED_LIBS) + ENDIF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) # -------------------------------------------------------------------- # Copy all the HDF5 files from the test directory into the source directory diff --git a/tools/h5dump/CMakeLists.txt b/tools/h5dump/CMakeLists.txt index b3c65ef..5ef1cc2 100644 --- a/tools/h5dump/CMakeLists.txt +++ b/tools/h5dump/CMakeLists.txt @@ -4,7 +4,7 @@ PROJECT (HDF5_TOOLS_H5DUMP) #----------------------------------------------------------------------------- # Setup include Directories #----------------------------------------------------------------------------- -INCLUDE_DIRECTORIES (${HDF5_TOOLS_SOURCE_DIR}/lib) +INCLUDE_DIRECTORIES (${HDF5_TOOLS_SRC_DIR}/lib) INCLUDE_DIRECTORIES (${HDF5_PROJECT_DIR}/test) # -------------------------------------------------------------------- @@ -36,7 +36,7 @@ IF (BUILD_TESTING) # -------------------------------------------------------------------- # Add the h5dump test executable # -------------------------------------------------------------------- - IF (NOT BUILD_SHARED_LIBS) + IF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) ADD_EXECUTABLE (h5dumpgentest ${HDF5_TOOLS_H5DUMP_SOURCE_DIR}/h5dumpgentest.c) H5_NAMING (h5dumpgentest) IF (WIN32) @@ -50,7 +50,7 @@ IF (BUILD_TESTING) TARGET_LINK_LIBRARIES (h5dumpgentest ${HDF5_LIB_TARGET} ${HDF5_TOOLS_LIB_TARGET}) #ADD_TEST (NAME h5dumpgentest COMMAND $<TARGET_FILE:h5dumpgentest>) - ENDIF (NOT BUILD_SHARED_LIBS) + ENDIF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) # -------------------------------------------------------------------- # Copy all the HDF5 files from the test directory into the source directory @@ -341,7 +341,7 @@ IF (BUILD_TESTING) TARGET h5dump POST_BUILD COMMAND ${XLATE_UTILITY} - ARGS ${HDF5_TOOLS_SOURCE_DIR}/testfiles/${ddl_file} ${ddldest} -l3 + ARGS ${HDF5_TOOLS_SRC_DIR}/testfiles/${ddl_file} ${ddldest} -l3 ) ENDFOREACH (ddl_file ${HDF5_REFERENCE_FILES}) @@ -352,7 +352,7 @@ IF (BUILD_TESTING) TARGET h5dump POST_BUILD COMMAND ${XLATE_UTILITY} - ARGS ${HDF5_TOOLS_SOURCE_DIR}/testfiles/${xml_file} ${xmldest} -l3 + ARGS ${HDF5_TOOLS_SRC_DIR}/testfiles/${xml_file} ${xmldest} -l3 ) ENDFOREACH (xml_file ${HDF5_XML_REFERENCE_FILES}) @@ -363,7 +363,7 @@ IF (BUILD_TESTING) TARGET h5dump POST_BUILD COMMAND ${CMAKE_COMMAND} - ARGS -E copy_if_different ${HDF5_TOOLS_SOURCE_DIR}/testfiles/${h5_file} ${dest} + ARGS -E copy_if_different ${HDF5_TOOLS_SRC_DIR}/testfiles/${h5_file} ${dest} ) ENDFOREACH (h5_file ${HDF5_REFERENCE_TEST_FILES}) @@ -374,7 +374,7 @@ IF (BUILD_TESTING) TARGET h5dump POST_BUILD COMMAND ${CMAKE_COMMAND} - ARGS -E copy_if_different ${HDF5_TOOLS_SOURCE_DIR}/testfiles/${h5_xml_file} ${dest} + ARGS -E copy_if_different ${HDF5_TOOLS_SRC_DIR}/testfiles/${h5_xml_file} ${dest} ) ENDFOREACH (h5_xml_file ${HDF5_XML_REFERENCE_TEST_FILES}) @@ -389,14 +389,14 @@ IF (BUILD_TESTING) ) IF (WIN32 AND NOT MINGW) - FILE (READ ${HDF5_TOOLS_SOURCE_DIR}/testfiles/tbinregR.exp TEST_STREAM) + FILE (READ ${HDF5_TOOLS_SRC_DIR}/testfiles/tbinregR.exp TEST_STREAM) FILE (WRITE ${PROJECT_BINARY_DIR}/tbinregR.exp "${TEST_STREAM}") ELSE (WIN32 AND NOT MINGW) ADD_CUSTOM_COMMAND ( TARGET h5dump POST_BUILD COMMAND ${CMAKE_COMMAND} - ARGS -E copy_if_different ${HDF5_TOOLS_SOURCE_DIR}/testfiles/tbinregR.exp ${PROJECT_BINARY_DIR}/tbinregR.exp + ARGS -E copy_if_different ${HDF5_TOOLS_SRC_DIR}/testfiles/tbinregR.exp ${PROJECT_BINARY_DIR}/tbinregR.exp ) ENDIF (WIN32 AND NOT MINGW) @@ -450,7 +450,7 @@ IF (BUILD_TESTING) COMMAND ${CMAKE_COMMAND} -E echo "SKIP ${skipresultfile}.xml --xml ${ARGN}" ) ELSE (${testtype} STREQUAL "SKIP") - ADD_H5_TEST (${skipresultfile} ${skipresultcode} ${ARGN}) + ADD_XML_H5_TEST (${skipresultfile} ${skipresultcode} ${ARGN}) ENDIF (${testtype} STREQUAL "SKIP") ENDMACRO (ADD_XML_SKIP_H5_TEST) diff --git a/tools/h5import/CMakeLists.txt b/tools/h5import/CMakeLists.txt index 317456c..3c82492 100644 --- a/tools/h5import/CMakeLists.txt +++ b/tools/h5import/CMakeLists.txt @@ -4,7 +4,7 @@ PROJECT (HDF5_TOOLS_H5IMPORT) #----------------------------------------------------------------------------- # Setup include Directories #----------------------------------------------------------------------------- -INCLUDE_DIRECTORIES (${HDF5_TOOLS_SOURCE_DIR}/lib) +INCLUDE_DIRECTORIES (${HDF5_TOOLS_SRC_DIR}/lib) INCLUDE_DIRECTORIES (${HDF5_PROJECT_DIR}/test) # -------------------------------------------------------------------- diff --git a/tools/h5jam/CMakeLists.txt b/tools/h5jam/CMakeLists.txt index 9c1d09d..61b8c84 100644 --- a/tools/h5jam/CMakeLists.txt +++ b/tools/h5jam/CMakeLists.txt @@ -4,7 +4,7 @@ PROJECT (HDF5_TOOLS_H5JAM) #----------------------------------------------------------------------------- # Setup include Directories #----------------------------------------------------------------------------- -INCLUDE_DIRECTORIES (${HDF5_TOOLS_SOURCE_DIR}/lib) +INCLUDE_DIRECTORIES (${HDF5_TOOLS_SRC_DIR}/lib) INCLUDE_DIRECTORIES (${HDF5_PROJECT_DIR}/test) # -------------------------------------------------------------------- @@ -83,7 +83,7 @@ IF (BUILD_TESTING) # -------------------------------------------------------------------- # Add the h5jam test executables # -------------------------------------------------------------------- - IF (NOT BUILD_SHARED_LIBS) + IF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) ADD_EXECUTABLE (h5jamgentest ${HDF5_TOOLS_H5JAM_SOURCE_DIR}/h5jamgentest.c) H5_NAMING (h5jamgentest) IF (WIN32) @@ -97,7 +97,7 @@ IF (BUILD_TESTING) TARGET_LINK_LIBRARIES (h5jamgentest ${HDF5_LIB_TARGET} ${HDF5_TOOLS_LIB_TARGET}) #ADD_TEST (NAME h5jamgentest COMMAND $<TARGET_FILE:h5jamgentest>) - ENDIF (NOT BUILD_SHARED_LIBS) + ENDIF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) ############################################################################## ############################################################################## diff --git a/tools/h5ls/CMakeLists.txt b/tools/h5ls/CMakeLists.txt index ff6679c..1d2589a 100644 --- a/tools/h5ls/CMakeLists.txt +++ b/tools/h5ls/CMakeLists.txt @@ -4,7 +4,7 @@ PROJECT (HDF5_TOOLS_H5LS) #----------------------------------------------------------------------------- # Setup include Directories #----------------------------------------------------------------------------- -INCLUDE_DIRECTORIES (${HDF5_TOOLS_SOURCE_DIR}/lib) +INCLUDE_DIRECTORIES (${HDF5_TOOLS_SRC_DIR}/lib) INCLUDE_DIRECTORIES (${HDF5_PROJECT_DIR}/test) #----------------------------------------------------------------------------- @@ -119,7 +119,7 @@ IF (BUILD_TESTING) TARGET h5ls POST_BUILD COMMAND ${XLATE_UTILITY} - ARGS ${HDF5_TOOLS_SOURCE_DIR}/testfiles/${ls_file} ${lsdest} -l3 + ARGS ${HDF5_TOOLS_SRC_DIR}/testfiles/${ls_file} ${lsdest} -l3 ) ENDFOREACH (ls_file ${HDF5_REFERENCE_FILES}) @@ -130,7 +130,7 @@ IF (BUILD_TESTING) TARGET h5ls POST_BUILD COMMAND ${CMAKE_COMMAND} - ARGS -E copy_if_different ${HDF5_TOOLS_SOURCE_DIR}/testfiles/${h5_file} ${dest} + ARGS -E copy_if_different ${HDF5_TOOLS_SRC_DIR}/testfiles/${h5_file} ${dest} ) ENDFOREACH (h5_file ${HDF5_REFERENCE_TEST_FILES}) diff --git a/tools/h5repack/CMakeLists.txt b/tools/h5repack/CMakeLists.txt index 1f4d78b..d767de1 100644 --- a/tools/h5repack/CMakeLists.txt +++ b/tools/h5repack/CMakeLists.txt @@ -4,8 +4,8 @@ PROJECT (HDF5_TOOLS_H5REPACK) #----------------------------------------------------------------------------- # Setup include Directories #----------------------------------------------------------------------------- -INCLUDE_DIRECTORIES (${HDF5_TOOLS_SOURCE_DIR}/lib) -INCLUDE_DIRECTORIES (${HDF5_PROJECT_DIR}/test) +INCLUDE_DIRECTORIES (${HDF5_TOOLS_SRC_DIR}/lib) +INCLUDE_DIRECTORIES (${HDF5_TEST_SRC_DIR}) # -------------------------------------------------------------------- # Add h5Repack executables @@ -19,7 +19,7 @@ SET (REPACK_COMMON_SRCS ${HDF5_TOOLS_H5REPACK_SOURCE_DIR}/h5repack_verify.c ${HDF5_TOOLS_H5REPACK_SOURCE_DIR}/h5repack.c ) -INCLUDE_DIRECTORIES (${HDF5_TEST_SOURCE_DIR}) + ADD_EXECUTABLE (h5repack ${REPACK_COMMON_SRCS} ${HDF5_TOOLS_H5REPACK_SOURCE_DIR}/h5repack_main.c) H5_NAMING (h5repack) IF (WIN32) @@ -149,7 +149,7 @@ IF (BUILD_TESTING) TARGET h5repack POST_BUILD COMMAND ${CMAKE_COMMAND} - ARGS -E copy_if_different ${HDF5_TOOLS_SOURCE_DIR}/testfiles/${h5c_file} ${dest} + ARGS -E copy_if_different ${HDF5_TOOLS_SRC_DIR}/testfiles/${h5c_file} ${dest} ) ENDFOREACH (h5c_file ${HDF5_COMMON_TEST_FILES}) diff --git a/tools/h5stat/CMakeLists.txt b/tools/h5stat/CMakeLists.txt index b5a2808..b900afb 100644 --- a/tools/h5stat/CMakeLists.txt +++ b/tools/h5stat/CMakeLists.txt @@ -4,7 +4,7 @@ PROJECT (HDF5_TOOLS_H5STAT) #----------------------------------------------------------------------------- # Setup include Directories #----------------------------------------------------------------------------- -INCLUDE_DIRECTORIES (${HDF5_TOOLS_SOURCE_DIR}/lib) +INCLUDE_DIRECTORIES (${HDF5_TOOLS_SRC_DIR}/lib) INCLUDE_DIRECTORIES (${HDF5_PROJECT_DIR}/test) # -------------------------------------------------------------------- @@ -36,7 +36,7 @@ IF (BUILD_TESTING) # -------------------------------------------------------------------- # Add the h5stat test executables # -------------------------------------------------------------------- - IF (NOT BUILD_SHARED_LIBS) + IF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) ADD_EXECUTABLE (h5stat_gentest ${HDF5_TOOLS_H5STAT_SOURCE_DIR}/h5stat_gentest.c) H5_NAMING (h5stat_gentest) IF (WIN32) @@ -50,7 +50,7 @@ IF (BUILD_TESTING) TARGET_LINK_LIBRARIES (h5stat_gentest ${HDF5_LIB_TARGET} ${HDF5_TOOLS_LIB_TARGET}) #ADD_TEST (NAME h5stat_gentest COMMAND $<TARGET_FILE:h5stat_gentest>) - ENDIF (NOT BUILD_SHARED_LIBS) + ENDIF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) # -------------------------------------------------------------------- # Copy all the HDF5 files from the test directory into the source directory diff --git a/tools/lib/CMakeLists.txt b/tools/lib/CMakeLists.txt index b05ce35..05fd607 100644 --- a/tools/lib/CMakeLists.txt +++ b/tools/lib/CMakeLists.txt @@ -4,7 +4,7 @@ PROJECT (HDF5_TOOLS_LIB) #----------------------------------------------------------------------------- # Define Sources #----------------------------------------------------------------------------- -#INCLUDE_DIRECTORIES (${HDF5_TOOLS_SOURCE_DIR}/lib) +#INCLUDE_DIRECTORIES (${HDF5_TOOLS_SRC_DIR}/lib) #INCLUDE_DIRECTORIES (${HDF5_PROJECT_DIR}/test) SET (H5_TOOLS_LIB_SRCS @@ -61,6 +61,21 @@ INSTALL ( ) #----------------------------------------------------------------------------- +# Because tools are installed into bin/tools we need to make sure the hdf5tools +# library will be installed into the proper location. +#----------------------------------------------------------------------------- +IF (APPLE) + OPTION (HDF5_BUILD_WITH_INSTALL_NAME "Build with library install_name set to the installation path" OFF) + IF (HDF5_BUILD_WITH_INSTALL_NAME) + SET_TARGET_PROPERTIES(${HDF5_TOOLS_LIB_TARGET} PROPERTIES + LINK_FLAGS "-current_version ${HDF5_PACKAGE_VERSION} -compatibility_version ${HDF5_PACKAGE_VERSION}" + INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib/tools" + BUILD_WITH_INSTALL_RPATH ${HDF5_BUILD_WITH_INSTALL_NAME} + ) + ENDIF (HDF5_BUILD_WITH_INSTALL_NAME) +ENDIF (APPLE) + +#----------------------------------------------------------------------------- # Add Target(s) to CMake Install for import into other projects #----------------------------------------------------------------------------- IF (HDF5_EXPORTED_TARGETS) diff --git a/tools/misc/CMakeLists.txt b/tools/misc/CMakeLists.txt index 205f603..8e7e6bf 100644 --- a/tools/misc/CMakeLists.txt +++ b/tools/misc/CMakeLists.txt @@ -4,7 +4,7 @@ PROJECT (HDF5_TOOLS_MISC) #----------------------------------------------------------------------------- # Setup include Directories #----------------------------------------------------------------------------- -INCLUDE_DIRECTORIES (${HDF5_TOOLS_SOURCE_DIR}/lib) +INCLUDE_DIRECTORIES (${HDF5_TOOLS_SRC_DIR}/lib) INCLUDE_DIRECTORIES (${HDF5_PROJECT_DIR}/test) # -------------------------------------------------------------------- @@ -69,7 +69,7 @@ IF (BUILD_TESTING) # -------------------------------------------------------------------- # Add the misc test executables # -------------------------------------------------------------------- - IF (NOT BUILD_SHARED_LIBS) + IF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) ADD_EXECUTABLE (h5repart_gentest ${HDF5_TOOLS_MISC_SOURCE_DIR}/h5repart_gentest.c) H5_NAMING (h5repart_gentest) IF (WIN32) @@ -82,7 +82,7 @@ IF (BUILD_TESTING) ENDIF (WIN32) TARGET_LINK_LIBRARIES (h5repart_gentest ${HDF5_LIB_TARGET} ${HDF5_TOOLS_LIB_TARGET}) #ADD_TEST (NAME h5repart_gentest COMMAND $<TARGET_FILE:h5repart_gentest>) - ENDIF (NOT BUILD_SHARED_LIBS) + ENDIF (HDF5_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS) ADD_EXECUTABLE (h5repart_test ${HDF5_TOOLS_MISC_SOURCE_DIR}/repart_test.c) H5_NAMING (h5repart_test) @@ -129,7 +129,7 @@ IF (BUILD_TESTING) TARGET h5repart POST_BUILD COMMAND ${CMAKE_COMMAND} - ARGS -E copy_if_different ${HDF5_TOOLS_SOURCE_DIR}/testfiles/${h5_file} ${dest} + ARGS -E copy_if_different ${HDF5_TOOLS_SRC_DIR}/testfiles/${h5_file} ${dest} ) ENDFOREACH (h5_file ${HDF5_REFERENCE_TEST_FILES}) @@ -156,7 +156,6 @@ IF (BUILD_TESTING) ADD_TEST (NAME h5repart_test COMMAND $<TARGET_FILE:h5repart_test>) SET (H5_DEP_EXECUTABLES ${H5_DEP_EXECUTABLES} - # h5repart_gentest h5repart_test ) ENDIF (BUILD_TESTING) |