summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2010-06-22 19:04:20 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2010-06-22 19:04:20 (GMT)
commitf747973a518b5b4b7424e6a0293e7673c1055525 (patch)
tree04344793d66c58cc01500262ac32cb5dcf457808
parentbbba3fbf7bf89fd2d00c0b13e6d80d740d1eb15d (diff)
downloadhdf5-f747973a518b5b4b7424e6a0293e7673c1055525.zip
hdf5-f747973a518b5b4b7424e6a0293e7673c1055525.tar.gz
hdf5-f747973a518b5b4b7424e6a0293e7673c1055525.tar.bz2
[svn-r19027] Add testing files to cmake resources.
Added code coverage option to cmake. Tested: local linux
-rw-r--r--CMakeLists.txt10
-rwxr-xr-xResources/CTestCustom.ctest2
-rwxr-xr-xResources/cacheinit.cmake35
3 files changed, 47 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index a9f42ec..627f8b6 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -229,6 +229,16 @@ ELSE (BUILD_SHARED_LIBS)
ENDIF (BUILD_SHARED_LIBS)
#-----------------------------------------------------------------------------
+# Option to use code coverage
+#-----------------------------------------------------------------------------
+OPTION (HDF5_ENABLE_COVERAGE "Enable code coverage for Libraries and Programs" OFF)
+IF (HDF5_ENABLE_COVERAGE)
+ SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -g -O0 -fprofile-arcs -ftest-coverage")
+ SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -O0 -fprofile-arcs -ftest-coverage")
+ SET (LDFLAGS "${LDFLAGS} -fprofile-arcs -ftest-coverage")
+ENDIF (HDF5_ENABLE_COVERAGE)
+
+#-----------------------------------------------------------------------------
# Set the target names of all the libraries
#-----------------------------------------------------------------------------
SET (HDF5_LIB_TARGET ${HDF5_LIB_CORENAME})
diff --git a/Resources/CTestCustom.ctest b/Resources/CTestCustom.ctest
new file mode 100755
index 0000000..23b4163
--- /dev/null
+++ b/Resources/CTestCustom.ctest
@@ -0,0 +1,2 @@
+SET (CTEST_CUSTOM_MAXIMUM_NUMBER_OF_WARNINGS 1500)
+
diff --git a/Resources/cacheinit.cmake b/Resources/cacheinit.cmake
new file mode 100755
index 0000000..23e6aed
--- /dev/null
+++ b/Resources/cacheinit.cmake
@@ -0,0 +1,35 @@
+# This is the CMakeCache file.
+
+########################
+# EXTERNAL cache entries
+########################
+
+SET (BUILD_SHARED_LIBS ON CACHE BOOL "Build Shared Libraries" FORCE)
+
+SET (BUILD_TESTING ON CACHE BOOL "Build HDF5 Unit Testing" FORCE)
+
+SET (HDF5_BUILD_CPP_LIB ON CACHE BOOL "Build HDF5 C++ Library" FORCE)
+
+SET (HDF5_BUILD_EXAMPLES ON CACHE BOOL "Build HDF5 Library Examples" FORCE)
+
+SET (HDF5_BUILD_FORTRAN ON CACHE BOOL "Build FORTRAN support" FORCE)
+
+SET (HDF5_BUILD_HL_LIB ON CACHE BOOL "Build HIGH Level HDF5 Library" FORCE)
+
+SET (HDF5_BUILD_TOOLS ON CACHE BOOL "Build HDF5 Tools" FORCE)
+
+SET (HDF5_DISABLE_COMPILER_WARNINGS OFF CACHE BOOL "Disable compiler warnings" FORCE)
+
+SET (HDF5_ENABLE_HSIZET ON CACHE BOOL "Enable datasets larger than memory" FORCE)
+
+SET (HDF5_ENABLE_PARALLEL OFF CACHE BOOL "Enable parallel build (requires MPI)" FORCE)
+
+SET (HDF5_ENABLE_SZIP_ENCODING ON CACHE BOOL "Use SZip Encoding" FORCE)
+
+SET (HDF5_ENABLE_SZIP_SUPPORT ON CACHE BOOL "Use SZip Filter" FORCE)
+
+SET (HDF5_ENABLE_Z_LIB_SUPPORT ON CACHE BOOL "Enable Zlib Filters" FORCE)
+
+SET (HDF5_USE_H5DUMP_PACKED_BITS ON CACHE BOOL "Use the PACKED BITS feature in h5dump" FORCE)
+
+SET (HDF5_ENABLE_COVERAGE OFF CACHE BOOL "Enable code coverage for Libraries and Programs" FORCE)