diff options
Diffstat (limited to 'c++/examples')
-rw-r--r-- | c++/examples/CMakeLists.txt | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/c++/examples/CMakeLists.txt b/c++/examples/CMakeLists.txt index a650db5..053cbd5 100644 --- a/c++/examples/CMakeLists.txt +++ b/c++/examples/CMakeLists.txt @@ -26,6 +26,8 @@ FOREACH (example ${examples}) TARGET_WIN_PROPERTIES (cpp_ex_${example}) TARGET_LINK_LIBRARIES (cpp_ex_${example} ${HDF5_CPP_LIB_TARGET} ${HDF5_LIB_TARGET}) - ADD_TEST (NAME cpp_ex_${example} COMMAND $<TARGET_FILE:cpp_ex_${example}>) + IF (BUILD_TESTING) + ADD_TEST (NAME cpp_ex_${example} COMMAND $<TARGET_FILE:cpp_ex_${example}>) + ENDIF (BUILD_TESTING) ENDFOREACH (example ${examples}) |