Salome HOME
CMake:
authormpa <mpa@opencascade.com>
Wed, 13 Nov 2013 12:25:02 +0000 (12:25 +0000)
committermpa <mpa@opencascade.com>
Wed, 13 Nov 2013 12:25:02 +0000 (12:25 +0000)
- delete kernel dependency because options are local now
- enable cmake testing for have message "No tests were
found" if module has not tests

CMakeLists.txt
SalomePYHELLOConfig.cmake.in

index 5394f6164f63243de7ec134ccfbd1f4f391c1c31..b133f415de9b0dfd51ad8c56194b4dc6e46431df 100755 (executable)
@@ -58,11 +58,13 @@ SET(BUILD_SHARED_LIBS TRUE)
 LIST(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/adm_local/cmake_files")
 
 # User options
-# (some options have already been defined in KERNEL) 
 # ============
-# OPTION(SALOME_BUILD_TESTS "Build SALOME tests" ON) For use in the future
+OPTION(SALOME_BUILD_TESTS "Build SALOME tests" ON)
 OPTION(SALOME_BUILD_DOC "Generate SALOME PYHELLO documentation" ON)
 
+IF(SALOME_BUILD_TESTS)
+  ENABLE_TESTING()
+ENDIF()
 IF(SALOME_BUILD_DOC)
   FIND_PACKAGE(SalomeDoxygen)
   SALOME_LOG_OPTIONAL_PACKAGE(Doxygen SALOME_BUILD_DOC)
index 93d9a6848f2a222aeef19caca488f039493e4963..8750e55a0ca004ea0356a0c984abfb3bf6a3e8f1 100644 (file)
@@ -53,8 +53,8 @@ ENDIF()
 #### Now the specificities
 
 # Options exported by the package:
-#SET(SALOME_PYHELLO_BUILD_TESTS @SALOME_BUILD_TESTS@)
-SET(SALOME_PYHELLO_BUILD_DOC    @SALOME_BUILD_DOC@)
+SET(SALOME_PYHELLO_BUILD_TESTS @SALOME_BUILD_TESTS@)
+SET(SALOME_PYHELLO_BUILD_DOC   @SALOME_BUILD_DOC@)
 
 # Level 1 prerequisites:
 SET_AND_CHECK(GUI_ROOT_DIR_EXP "@PACKAGE_GUI_ROOT_DIR@")