From 6682c717e263ed3f3465766f9664f3b7ff115841 Mon Sep 17 00:00:00 2001 From: Allen Byrne Date: Wed, 15 Jan 2020 11:38:06 -0600 Subject: HDFFV-11001 Add fine control over testing --- CMakeLists.txt | 48 ++++++++++++++++++++++++++---- c++/examples/CMakeLists.txt | 2 +- c++/test/CMakeLists.txt | 4 ++- examples/CMakeLists.txt | 2 +- fortran/CMakeLists.txt | 9 ++++-- fortran/examples/CMakeLists.txt | 2 +- fortran/test/CMakeLists.txt | 4 ++- fortran/testpar/CMakeLists.txt | 4 ++- hl/CMakeLists.txt | 2 +- hl/c++/CMakeLists.txt | 5 ++-- hl/c++/examples/CMakeLists.txt | 2 +- hl/c++/test/CMakeLists.txt | 4 ++- hl/examples/CMakeLists.txt | 4 +-- hl/fortran/CMakeLists.txt | 5 ++-- hl/fortran/examples/CMakeLists.txt | 2 +- hl/fortran/test/CMakeLists.txt | 4 ++- hl/test/CMakeLists.txt | 4 ++- hl/tools/gif2h5/CMakeLists.txt | 6 ++-- hl/tools/h5watch/CMakeLists.txt | 6 ++-- java/CMakeLists.txt | 2 +- java/examples/datasets/CMakeLists.txt | 2 +- java/examples/datatypes/CMakeLists.txt | 2 +- java/examples/groups/CMakeLists.txt | 2 +- java/examples/intro/CMakeLists.txt | 2 +- test/CMakeLists.txt | 4 ++- test/CMakeVFDTests.cmake | 2 +- testpar/CMakeLists.txt | 4 ++- tools/libtest/CMakeLists.txt | 4 ++- tools/test/h5copy/CMakeLists.txt | 4 ++- tools/test/h5diff/CMakeLists.txt | 4 ++- tools/test/h5diff/CMakeTests.cmake | 2 +- tools/test/h5dump/CMakeLists.txt | 10 ++++--- tools/test/h5format_convert/CMakeLists.txt | 4 ++- tools/test/h5import/CMakeLists.txt | 4 ++- tools/test/h5jam/CMakeLists.txt | 4 ++- tools/test/h5ls/CMakeLists.txt | 6 ++-- tools/test/h5repack/CMakeLists.txt | 4 ++- tools/test/h5stat/CMakeLists.txt | 4 ++- tools/test/perform/CMakeLists.txt | 6 ++-- 39 files changed, 138 insertions(+), 57 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 63c36b0..1466865 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -435,17 +435,29 @@ endif () #----------------------------------------------------------------------------- # Option to Build Shared and Static libs, default is both #----------------------------------------------------------------------------- -option (ONLY_SHARED_LIBS "Only Build Shared Libraries" OFF) -set (H5_ENABLE_STATIC_LIB YES) -if (ONLY_SHARED_LIBS) - set (H5_ENABLE_STATIC_LIB NO) - set (BUILD_SHARED_LIBS ON CACHE BOOL "Build Shared Libraries") -endif () +option (BUILD_STATIC_LIBS "Build Static Libraries" ON) +set (H5_ENABLE_STATIC_LIB NO) option (BUILD_SHARED_LIBS "Build Shared Libraries" ON) set (H5_ENABLE_SHARED_LIB NO) +option (ONLY_SHARED_LIBS "Only Build Shared Libraries" OFF) + +if (BUILD_STATIC_LIBS) + set (H5_ENABLE_STATIC_LIB YES) +endif () if (BUILD_SHARED_LIBS) set (H5_ENABLE_SHARED_LIB YES) endif () + +# Force only shared libraries if all OFF +if (NOT BUILD_STATIC_LIBS AND NOT BUILD_SHARED_LIBS) + set (ONLY_SHARED_LIBS ON CACHE BOOL "Only Build Shared Libraries" FORCE) +endif () + +if (ONLY_SHARED_LIBS) + set (H5_ENABLE_STATIC_LIB NO) + set (BUILD_SHARED_LIBS ON CACHE BOOL "Build Shared Libraries") +endif () + set (CMAKE_POSITION_INDEPENDENT_CODE ON) #----------------------------------------------------------------------------- @@ -860,6 +872,30 @@ if (BUILD_TESTING) include (${HDF5_SOURCE_DIR}/CTestConfig.cmake) configure_file (${HDF_RESOURCES_DIR}/CTestCustom.cmake ${HDF5_BINARY_DIR}/CTestCustom.ctest @ONLY) + option (HDF5_TEST_SERIAL "Execute non-parallel tests" ON) + mark_as_advanced (HDF5_TEST_SERIAL) + + option (HDF5_TEST_TOOLS "Execute tools tests" ON) + mark_as_advanced (HDF5_TEST_TOOLS) + + option (HDF5_TEST_EXAMPLES "Execute tests on examples" ON) + mark_as_advanced (HDF5_TEST_EXAMPLES) + + option (HDF5_TEST_SWMR "Execute SWMR tests" ON) + mark_as_advanced (HDF5_TEST_SWMR) + + option (HDF5_TEST_PARALLEL "Execute parallel tests" ON) + mark_as_advanced (HDF5_TEST_PARALLEL) + + option (HDF5_TEST_FORTRAN "Execute fortran tests" ON) + mark_as_advanced (HDF5_TEST_FORTRAN) + + option (HDF5_TEST_CPP "Execute cpp tests" ON) + mark_as_advanced (HDF5_TEST_CPP) + + option (HDF5_TEST_JAVA "Execute java tests" ON) + mark_as_advanced (HDF5_TEST_JAVA) + if (NOT HDF5_EXTERNALLY_CONFIGURED) if (EXISTS "${HDF5_SOURCE_DIR}/test" AND IS_DIRECTORY "${HDF5_SOURCE_DIR}/test") add_subdirectory (test) diff --git a/c++/examples/CMakeLists.txt b/c++/examples/CMakeLists.txt index 58d85c1..67d84a7 100644 --- a/c++/examples/CMakeLists.txt +++ b/c++/examples/CMakeLists.txt @@ -68,6 +68,6 @@ foreach (example ${tutr_examples}) set_target_properties (cpp_ex_${example} PROPERTIES FOLDER examples/cpp) endforeach () -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_CPP AND HDF5_TEST_EXAMPLES) include (CMakeTests.cmake) endif () diff --git a/c++/test/CMakeLists.txt b/c++/test/CMakeLists.txt index 75efc3b..f6f5187 100644 --- a/c++/test/CMakeLists.txt +++ b/c++/test/CMakeLists.txt @@ -56,4 +56,6 @@ else () endif () set_target_properties (cpp_testhdf5 PROPERTIES FOLDER test/cpp) -include (CMakeTests.cmake) +if (HDF5_TEST_CPP) + include (CMakeTests.cmake) +endif () diff --git a/examples/CMakeLists.txt b/examples/CMakeLists.txt index 9f42f95..89cafc8 100644 --- a/examples/CMakeLists.txt +++ b/examples/CMakeLists.txt @@ -67,6 +67,6 @@ if (H5_HAVE_PARALLEL) set_target_properties (ph5example PROPERTIES FOLDER examples) endif () -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_EXAMPLES) include (CMakeTests.cmake) endif () diff --git a/fortran/CMakeLists.txt b/fortran/CMakeLists.txt index 31edad2..9755963 100644 --- a/fortran/CMakeLists.txt +++ b/fortran/CMakeLists.txt @@ -23,8 +23,11 @@ endif () # Testing #----------------------------------------------------------------------------- if (BUILD_TESTING) - add_subdirectory (test) - if (MPI_Fortran_FOUND) - add_subdirectory (testpar) + if (HDF5_TEST_SERIAL) + add_subdirectory (test) + endif () + if (MPI_Fortran_FOUND AND HDF5_TEST_PARALLEL) + add_subdirectory (testpar) + endif () endif () endif () diff --git a/fortran/examples/CMakeLists.txt b/fortran/examples/CMakeLists.txt index e8dddd3..be98963 100644 --- a/fortran/examples/CMakeLists.txt +++ b/fortran/examples/CMakeLists.txt @@ -173,6 +173,6 @@ if (H5_HAVE_PARALLEL AND MPI_Fortran_FOUND) endif () endif () -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_FORTRAN AND HDF5_TEST_EXAMPLES) include (CMakeTests.cmake) endif () diff --git a/fortran/test/CMakeLists.txt b/fortran/test/CMakeLists.txt index 4efd8a8..97d2ff7 100644 --- a/fortran/test/CMakeLists.txt +++ b/fortran/test/CMakeLists.txt @@ -517,4 +517,6 @@ else () add_dependencies (vol_connector ${HDF5_F90_TEST_LIBSH_TARGET}) endif () -include (CMakeTests.cmake) +if (HDF5_TEST_FORTRAN) + include (CMakeTests.cmake) +endif () diff --git a/fortran/testpar/CMakeLists.txt b/fortran/testpar/CMakeLists.txt index 0fe641f..17aa6c3 100644 --- a/fortran/testpar/CMakeLists.txt +++ b/fortran/testpar/CMakeLists.txt @@ -45,4 +45,6 @@ set_target_properties (parallel_test PROPERTIES ) endif () -include (CMakeTests.cmake) +if (HDF5_TEST_FORTRAN AND HDF5_TEST_PARALLEL) + include (CMakeTests.cmake) +endif () diff --git a/hl/CMakeLists.txt b/hl/CMakeLists.txt index 2a71b47..bef034c 100644 --- a/hl/CMakeLists.txt +++ b/hl/CMakeLists.txt @@ -19,7 +19,7 @@ endif () #-- Build the Unit testing if requested if (NOT HDF5_EXTERNALLY_CONFIGURED) - if (BUILD_TESTING) + if (BUILD_TESTING AND HDF5_TEST_SERIAL) add_subdirectory (test) endif () endif () diff --git a/hl/c++/CMakeLists.txt b/hl/c++/CMakeLists.txt index a62d9d4..aa57b76 100644 --- a/hl/c++/CMakeLists.txt +++ b/hl/c++/CMakeLists.txt @@ -17,6 +17,7 @@ endif () # Add in the unit tests for the packet table c++ wrapper # -------------------------------------------------------------------- -if (BUILD_TESTING) - add_subdirectory (test) +if (BUILD_TESTING AND HDF5_TEST_SERIAL) + add_subdirectory (test) + endif () endif () diff --git a/hl/c++/examples/CMakeLists.txt b/hl/c++/examples/CMakeLists.txt index 50e08e8..a201dea 100644 --- a/hl/c++/examples/CMakeLists.txt +++ b/hl/c++/examples/CMakeLists.txt @@ -23,6 +23,6 @@ else () endif () set_target_properties (ptExampleFL PROPERTIES FOLDER examples/hl/cpp) -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_CPP AND HDF5_TEST_EXAMPLES) include (CMakeTests.cmake) endif () diff --git a/hl/c++/test/CMakeLists.txt b/hl/c++/test/CMakeLists.txt index cfb24a8..03237af 100644 --- a/hl/c++/test/CMakeLists.txt +++ b/hl/c++/test/CMakeLists.txt @@ -24,4 +24,6 @@ else () endif () set_target_properties (hl_ptableTest PROPERTIES FOLDER test/hl/cpp) -include (CMakeTests.cmake) +if (HDF5_TEST_CPP) + include (CMakeTests.cmake) +endif () diff --git a/hl/examples/CMakeLists.txt b/hl/examples/CMakeLists.txt index 86c1770..0f4ad50 100644 --- a/hl/examples/CMakeLists.txt +++ b/hl/examples/CMakeLists.txt @@ -39,8 +39,6 @@ foreach (example ${examples}) set_target_properties (hl_ex_${example} PROPERTIES FOLDER examples/hl) endforeach () -if (BUILD_TESTING) - +if (BUILD_TESTING AND HDF5_TEST_EXAMPLES) include (CMakeTests.cmake) - endif () diff --git a/hl/fortran/CMakeLists.txt b/hl/fortran/CMakeLists.txt index 3c82574..4c38f4a 100644 --- a/hl/fortran/CMakeLists.txt +++ b/hl/fortran/CMakeLists.txt @@ -16,6 +16,7 @@ endif () #----------------------------------------------------------------------------- # Testing #----------------------------------------------------------------------------- -if (BUILD_TESTING) - add_subdirectory (test) +if (BUILD_TESTING AND HDF5_TEST_SERIAL) + add_subdirectory (test) + endif () endif () diff --git a/hl/fortran/examples/CMakeLists.txt b/hl/fortran/examples/CMakeLists.txt index e41b8fe..9961f35 100644 --- a/hl/fortran/examples/CMakeLists.txt +++ b/hl/fortran/examples/CMakeLists.txt @@ -52,6 +52,6 @@ foreach (example ${examples}) endif () endforeach () -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_FORTRAN AND HDF5_TEST_EXAMPLES) include (CMakeTests.cmake) endif () diff --git a/hl/fortran/test/CMakeLists.txt b/hl/fortran/test/CMakeLists.txt index c152142..0c959bb 100644 --- a/hl/fortran/test/CMakeLists.txt +++ b/hl/fortran/test/CMakeLists.txt @@ -61,4 +61,6 @@ foreach (h5_test ${H5_TESTS}) ADD_H5_FORTRAN_EXE(${h5_test}) endforeach () -include (CMakeTests.cmake) +if (HDF5_TEST_FORTRAN) + include (CMakeTests.cmake) +endif () diff --git a/hl/test/CMakeLists.txt b/hl/test/CMakeLists.txt index 2959c6c..69f3dae 100644 --- a/hl/test/CMakeLists.txt +++ b/hl/test/CMakeLists.txt @@ -93,4 +93,6 @@ if (HDF5_BUILD_GENERATORS AND NOT ONLY_SHARED_LIBS) set_target_properties (hl_gen_test_ld PROPERTIES FOLDER test/hl/gen) endif () -include (CMakeTests.cmake) +if (HDF5_TEST_SERIAL) + include (CMakeTests.cmake) +endif () diff --git a/hl/tools/gif2h5/CMakeLists.txt b/hl/tools/gif2h5/CMakeLists.txt index 3cd913f..e12588b 100644 --- a/hl/tools/gif2h5/CMakeLists.txt +++ b/hl/tools/gif2h5/CMakeLists.txt @@ -67,7 +67,7 @@ if (BUILD_SHARED_LIBS) ) endif () -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_SERIAL) # -------------------------------------------------------------------- # This executable can generate the actual test files - Currently not # used in the CMake Build system as we rely on the test files that are @@ -83,7 +83,9 @@ if (BUILD_TESTING) # add_test (NAME hl_h52gifgentest COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $) endif () - include (CMakeTests.cmake) + if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) + endif () endif () #----------------------------------------------------------------------------- diff --git a/hl/tools/h5watch/CMakeLists.txt b/hl/tools/h5watch/CMakeLists.txt index b3d65f7..0ea0af4 100644 --- a/hl/tools/h5watch/CMakeLists.txt +++ b/hl/tools/h5watch/CMakeLists.txt @@ -26,7 +26,7 @@ if (BUILD_SHARED_LIBS) set (H5_DEP_EXECUTABLES ${H5_DEP_EXECUTABLES} h5watch-shared) endif () -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_SWMR) #-- Add swmr_check_compat_vfd program set (hl_swmr_check_compat_vfd_SOURCES ${HDF5_HL_TOOLS_H5WATCH_SOURCE_DIR}/swmr_check_compat_vfd.c @@ -68,7 +68,9 @@ if (BUILD_TESTING) endif () set_target_properties (h5watchgentest PROPERTIES FOLDER generator/tools/hl) - include (CMakeTests.cmake) + if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) + endif () endif () #----------------------------------------------------------------------------- diff --git a/java/CMakeLists.txt b/java/CMakeLists.txt index 56e1695..5bb0f30 100644 --- a/java/CMakeLists.txt +++ b/java/CMakeLists.txt @@ -49,7 +49,7 @@ endif () #----------------------------------------------------------------------------- # Testing #----------------------------------------------------------------------------- -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_JAVA) add_subdirectory (test) endif () diff --git a/java/examples/datasets/CMakeLists.txt b/java/examples/datasets/CMakeLists.txt index 8849524..5281d4e 100644 --- a/java/examples/datasets/CMakeLists.txt +++ b/java/examples/datasets/CMakeLists.txt @@ -71,7 +71,7 @@ foreach (HDFJAVA_JAR ${CMAKE_JAVA_INCLUDE_PATH}) set (CMAKE_JAVA_CLASSPATH "${CMAKE_JAVA_CLASSPATH}${CMAKE_JAVA_INCLUDE_FLAG_SEP}${HDFJAVA_JAR}") endforeach () -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_EXAMPLES) get_property (target_name TARGET ${HDF5_JAVA_JNI_LIB_TARGET} PROPERTY OUTPUT_NAME) set (CMD_ARGS "-Dhdf.hdf5lib.H5.loadLibraryName=${target_name}$<$:${CMAKE_DEBUG_POSTFIX}>;") diff --git a/java/examples/datatypes/CMakeLists.txt b/java/examples/datatypes/CMakeLists.txt index b83da0e..f0d36b2 100644 --- a/java/examples/datatypes/CMakeLists.txt +++ b/java/examples/datatypes/CMakeLists.txt @@ -56,7 +56,7 @@ foreach (HDFJAVA_JAR ${CMAKE_JAVA_INCLUDE_PATH}) set (CMAKE_JAVA_CLASSPATH "${CMAKE_JAVA_CLASSPATH}${CMAKE_JAVA_INCLUDE_FLAG_SEP}${HDFJAVA_JAR}") endforeach () -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_EXAMPLES) get_property (target_name TARGET ${HDF5_JAVA_JNI_LIB_TARGET} PROPERTY OUTPUT_NAME) set (CMD_ARGS "-Dhdf.hdf5lib.H5.loadLibraryName=${target_name}$<$:${CMAKE_DEBUG_POSTFIX}>;") diff --git a/java/examples/groups/CMakeLists.txt b/java/examples/groups/CMakeLists.txt index 9e43087..05ad995 100644 --- a/java/examples/groups/CMakeLists.txt +++ b/java/examples/groups/CMakeLists.txt @@ -55,7 +55,7 @@ foreach (h5_file ${HDF_JAVA_TEST_FILES}) endforeach () add_custom_target(H5Ex_G_Visit_files ALL COMMENT "Copying files needed by H5Ex_G_Visit tests" DEPENDS ${H5Ex_G_Visit_files_list}) -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_EXAMPLES) get_property (target_name TARGET ${HDF5_JAVA_JNI_LIB_TARGET} PROPERTY OUTPUT_NAME) set (CMD_ARGS "-Dhdf.hdf5lib.H5.loadLibraryName=${target_name}$<$:${CMAKE_DEBUG_POSTFIX}>;") diff --git a/java/examples/intro/CMakeLists.txt b/java/examples/intro/CMakeLists.txt index b56e3ad..d39396f 100644 --- a/java/examples/intro/CMakeLists.txt +++ b/java/examples/intro/CMakeLists.txt @@ -45,7 +45,7 @@ foreach (HDFJAVA_JAR ${CMAKE_JAVA_INCLUDE_PATH}) set (CMAKE_JAVA_CLASSPATH "${CMAKE_JAVA_CLASSPATH}${CMAKE_JAVA_INCLUDE_FLAG_SEP}${HDFJAVA_JAR}") endforeach () -if (BUILD_TESTING) +if (BUILD_TESTING AND HDF5_TEST_EXAMPLES) get_property (target_name TARGET ${HDF5_JAVA_JNI_LIB_TARGET} PROPERTY OUTPUT_NAME) set (CMD_ARGS "-Dhdf.hdf5lib.H5.loadLibraryName=${target_name}$<$:${CMAKE_DEBUG_POSTFIX}>;") diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index df2e909..4766680 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -542,4 +542,6 @@ else () endif () set_target_properties (use_disable_mdc_flushes PROPERTIES FOLDER test) -include (CMakeTests.cmake) +if (HDF5_TEST_SERIAL) + include (CMakeTests.cmake) +endif () diff --git a/test/CMakeVFDTests.cmake b/test/CMakeVFDTests.cmake index cf938f5..d4a5ddc 100644 --- a/test/CMakeVFDTests.cmake +++ b/test/CMakeVFDTests.cmake @@ -15,7 +15,7 @@ ### T E S T I N G ### ############################################################################## ############################################################################## -# included from CMakeTEsts.cmake +# included from CMakeTests.cmake set (VFD_LIST sec2 diff --git a/testpar/CMakeLists.txt b/testpar/CMakeLists.txt index 9795c65..3e4957d 100644 --- a/testpar/CMakeLists.txt +++ b/testpar/CMakeLists.txt @@ -79,4 +79,6 @@ foreach (h5_testp ${H5P_TESTS}) ADD_H5P_EXE(${h5_testp}) endforeach () -include (CMakeTests.cmake) +if (HDF5_TEST_PARALLEL) + include (CMakeTests.cmake) +endif () diff --git a/tools/libtest/CMakeLists.txt b/tools/libtest/CMakeLists.txt index f3d28da..5c758d2 100644 --- a/tools/libtest/CMakeLists.txt +++ b/tools/libtest/CMakeLists.txt @@ -15,4 +15,6 @@ else () endif () set_target_properties (h5tools_test_utils PROPERTIES FOLDER tools) -include (CMakeTests.cmake) +if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) +endif () diff --git a/tools/test/h5copy/CMakeLists.txt b/tools/test/h5copy/CMakeLists.txt index 1130ea7..f84b667 100644 --- a/tools/test/h5copy/CMakeLists.txt +++ b/tools/test/h5copy/CMakeLists.txt @@ -43,4 +43,6 @@ if (BUILD_SHARED_LIBS) ) endif () -include (CMakeTests.cmake) +if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) +endif () diff --git a/tools/test/h5diff/CMakeLists.txt b/tools/test/h5diff/CMakeLists.txt index cb4397f..82e09c6 100644 --- a/tools/test/h5diff/CMakeLists.txt +++ b/tools/test/h5diff/CMakeLists.txt @@ -43,4 +43,6 @@ if (BUILD_SHARED_LIBS) ) endif () -include (CMakeTests.cmake) +if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) +endif () diff --git a/tools/test/h5diff/CMakeTests.cmake b/tools/test/h5diff/CMakeTests.cmake index 347f796..904e6ef 100644 --- a/tools/test/h5diff/CMakeTests.cmake +++ b/tools/test/h5diff/CMakeTests.cmake @@ -404,7 +404,7 @@ set_tests_properties (H5DIFF-${resultfile} PROPERTIES DEPENDS ${last_test}) endif () endif () - if (H5_HAVE_PARALLEL) + if (H5_HAVE_PARALLEL AND HDF5_TEST_PARALLEL) ADD_PH5_TEST (${resultfile} ${resultcode} ${ARGN}) endif () endmacro () diff --git a/tools/test/h5dump/CMakeLists.txt b/tools/test/h5dump/CMakeLists.txt index 38f4118..82cada6 100644 --- a/tools/test/h5dump/CMakeLists.txt +++ b/tools/test/h5dump/CMakeLists.txt @@ -43,10 +43,12 @@ if (HDF5_BUILD_GENERATORS AND NOT ONLY_SHARED_LIBS) #add_test (NAME h5dumpgentest COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $) endif () -include (CMakeTests.cmake) +if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) -include (CMakeTestsPBITS.cmake) + include (CMakeTestsPBITS.cmake) -include (CMakeTestsVDS.cmake) + include (CMakeTestsVDS.cmake) -include (CMakeTestsXML.cmake) + include (CMakeTestsXML.cmake) +endif () diff --git a/tools/test/h5format_convert/CMakeLists.txt b/tools/test/h5format_convert/CMakeLists.txt index 55d5623..33a38d4 100644 --- a/tools/test/h5format_convert/CMakeLists.txt +++ b/tools/test/h5format_convert/CMakeLists.txt @@ -25,4 +25,6 @@ if (HDF5_BUILD_GENERATORS AND NOT ONLY_SHARED_LIBS) #add_test (NAME h5fc_gentest COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $) endif () -include (CMakeTests.cmake) +if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) +endif () diff --git a/tools/test/h5import/CMakeLists.txt b/tools/test/h5import/CMakeLists.txt index 9364683..7a75f0d 100644 --- a/tools/test/h5import/CMakeLists.txt +++ b/tools/test/h5import/CMakeLists.txt @@ -15,4 +15,6 @@ else () endif () set_target_properties (h5importtest PROPERTIES FOLDER tools) -include (CMakeTests.cmake) +if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) +endif () diff --git a/tools/test/h5jam/CMakeLists.txt b/tools/test/h5jam/CMakeLists.txt index 6fdf7b0..24836f0 100644 --- a/tools/test/h5jam/CMakeLists.txt +++ b/tools/test/h5jam/CMakeLists.txt @@ -36,4 +36,6 @@ else () endif () set_target_properties (tellub PROPERTIES FOLDER tools) -include (CMakeTests.cmake) +if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) +endif () diff --git a/tools/test/h5ls/CMakeLists.txt b/tools/test/h5ls/CMakeLists.txt index 0da03c5..fefc995 100644 --- a/tools/test/h5ls/CMakeLists.txt +++ b/tools/test/h5ls/CMakeLists.txt @@ -30,6 +30,8 @@ if (BUILD_SHARED_LIBS) ) endif () -include (CMakeTests.cmake) +if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) -include (CMakeTestsVDS.cmake) + include (CMakeTestsVDS.cmake) +endif () diff --git a/tools/test/h5repack/CMakeLists.txt b/tools/test/h5repack/CMakeLists.txt index f81ce4f..a12b04a 100644 --- a/tools/test/h5repack/CMakeLists.txt +++ b/tools/test/h5repack/CMakeLists.txt @@ -98,4 +98,6 @@ if (HDF5_BUILD_GENERATORS AND NOT ONLY_SHARED_LIBS) #add_test (NAME h5repackgentest COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $) endif () -include (CMakeTests.cmake) +if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) +endif () diff --git a/tools/test/h5stat/CMakeLists.txt b/tools/test/h5stat/CMakeLists.txt index 5c17fd5..a1afee5 100644 --- a/tools/test/h5stat/CMakeLists.txt +++ b/tools/test/h5stat/CMakeLists.txt @@ -14,4 +14,6 @@ if (HDF5_BUILD_GENERATORS AND NOT ONLY_SHARED_LIBS) #add_test (NAME h5stat_gentest COMMAND ${CMAKE_CROSSCOMPILING_EMULATOR} $) endif () -include (CMakeTests.cmake) +if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) +endif () diff --git a/tools/test/perform/CMakeLists.txt b/tools/test/perform/CMakeLists.txt index a01a88f..6d26795 100644 --- a/tools/test/perform/CMakeLists.txt +++ b/tools/test/perform/CMakeLists.txt @@ -133,7 +133,7 @@ else () endif () set_target_properties (zip_perf PROPERTIES FOLDER perform) -if (H5_HAVE_PARALLEL AND BUILD_TESTING) +if (H5_HAVE_PARALLEL AND BUILD_TESTING AND HDF5_TEST_PARALLEL) if (UNIX) #-- Adding test for perf - only on unix systems set (perf_SOURCES @@ -191,4 +191,6 @@ if (H5_HAVE_PARALLEL AND BUILD_TESTING) endif () endif () -include (CMakeTests.cmake) +if (HDF5_TEST_TOOLS) + include (CMakeTests.cmake) +endif () -- cgit v0.12