Salome HOME
Update icon
[modules/shaper.git] / CMakeLists.txt
index 8006e1506143f474a9ba584648acfe20d46f2771..dfc3a0edbd7580f71b5eed7faa7b2a195bf5e74c 100644 (file)
@@ -1,22 +1,21 @@
-## Copyright (C) 2014-2017  CEA/DEN, EDF R&D
-##
-## This library is free software; you can redistribute it and/or
-## modify it under the terms of the GNU Lesser General Public
-## License as published by the Free Software Foundation; either
-## version 2.1 of the License, or (at your option) any later version.
-##
-## This library is distributed in the hope that it will be useful,
-## but WITHOUT ANY WARRANTY; without even the implied warranty of
-## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-## Lesser General Public License for more details.
-##
-## You should have received a copy of the GNU Lesser General Public
-## License along with this library; if not, write to the Free Software
-## Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-##
-## See http:##www.salome-platform.org/ or
-## email : webmaster.salome@opencascade.com<mailto:webmaster.salome@opencascade.com>
-##
+# Copyright (C) 2014-2019  CEA/DEN, EDF R&D
+#
+# This library is free software; you can redistribute it and/or
+# modify it under the terms of the GNU Lesser General Public
+# License as published by the Free Software Foundation; either
+# version 2.1 of the License, or (at your option) any later version.
+#
+# This library is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this library; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+#
+# See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+#
 
 CMAKE_MINIMUM_REQUIRED(VERSION 2.8.10)
 
@@ -27,10 +26,13 @@ IF(WIN32)
   CMAKE_POLICY(SET CMP0020 OLD) # disable automatic linking to qtmain.lib
 ENDIF(WIN32)
 
-SET (SHAPER_Version 8.5.0)
+SET (SHAPER_Version 9.3.0)
 
 SET(CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/CMakeCommon" ${CMAKE_MODULE_PATH})
-OPTION(SHAPER_BUILD_DOC "Generate SHAPER documentation" ON)
+
+IF (NOT CADBUILDER_BUILD_DOC)
+  OPTION(SHAPER_BUILD_DOC "Generate SHAPER documentation" ON)
+ENDIF(NOT CADBUILDER_BUILD_DOC)
 
 INCLUDE(SalomeMacros)
 
@@ -38,7 +40,6 @@ INCLUDE(FindEclipse)
 INCLUDE(Common)
 INCLUDE(FindSalomeQt5)
 INCLUDE(FindSalome)
-INCLUDE(FindCAS)
 INCLUDE(FindSUIT)
 INCLUDE(FindTInspector)
 
@@ -64,8 +65,11 @@ IF(${HAVE_SALOME})
   FIND_PACKAGE(SalomePythonInterp REQUIRED)
   FIND_PACKAGE(SalomePythonLibs REQUIRED)
 
+  FIND_PACKAGE(SalomeOpenCASCADE REQUIRED)
+
 ELSE(${HAVE_SALOME})
   INCLUDE(FindPython)
+  INCLUDE(FindSalomeOpenCASCADE)
 ENDIF(${HAVE_SALOME})
 
 # Common CMake macros
@@ -99,7 +103,8 @@ IF(${HAVE_SALOME})
     SET(SHAPER_INSTALL_GUI_DOC share/doc/salome/gui/SHAPER CACHE INTERNAL "" FORCE)
     SET(SHAPER_INSTALL_TUI_DOC share/doc/salome/tui/SHAPER CACHE INTERNAL "" FORCE)
     # without SALOME there is another kind of documentation, separated one
-    ADD_SUBDIRECTORY (doc)
+
+    SALOME_INSTALL_SCRIPTS("shaper_test.py" ${SHAPER_INSTALL_PYTHON_FILES})
 ELSE(${HAVE_SALOME})
     SET(SHAPER_INSTALL_ADDONS addons CACHE INTERNAL "" FORCE)
     SET(SHAPER_INSTALL_BIN bin CACHE INTERNAL "" FORCE)
@@ -113,10 +118,11 @@ ELSE(${HAVE_SALOME})
 ENDIF(${HAVE_SALOME})
 
 # Sketcher: Change radius of circular edges while dragging a point on the edge
-SET(SKETCHER_CHANGE_RADIUS_WHEN_MOVE FALSE)
+SET(SKETCHER_CHANGE_RADIUS_WHEN_MOVE TRUE)
 
 ADD_SUBDIRECTORY (src/Config)
 ADD_SUBDIRECTORY (src/Events)
+ADD_SUBDIRECTORY (src/Selector)
 ADD_SUBDIRECTORY (src/Model)
 ADD_SUBDIRECTORY (src/XAO)
 ADD_SUBDIRECTORY (src/GeomAPI)
@@ -143,6 +149,7 @@ ADD_SUBDIRECTORY (src/PartSet)
 ADD_SUBDIRECTORY (src/XGUI)
 ADD_SUBDIRECTORY (src/ExchangePlugin)
 ADD_SUBDIRECTORY (src/GeomValidators)
+ADD_SUBDIRECTORY (src/FiltersPlugin)
 ADD_SUBDIRECTORY (src/InitializationPlugin)
 ADD_SUBDIRECTORY (src/ParametersPlugin)
 ADD_SUBDIRECTORY (src/PythonAddons)
@@ -160,6 +167,7 @@ ADD_SUBDIRECTORY (src/PrimitivesAPI)
 ADD_SUBDIRECTORY (src/SketchAPI)
 ADD_SUBDIRECTORY (src/GDMLAPI)
 ADD_SUBDIRECTORY (src/ConnectorAPI)
+ADD_SUBDIRECTORY (src/FiltersAPI)
 # Tests
 ADD_SUBDIRECTORY (test.API/SHAPER)
 
@@ -172,9 +180,17 @@ ENABLE_TESTING()
 
 IF(ADD_MODELS_TESTS)
   ADD_SUBDIRECTORY (test.models)
-  ADD_CUSTOM_TARGET(run_unit_tests COMMAND ${CMAKE_CTEST_COMMAND} -C "${CMAKE_BUILD_TYPE}" -LE "models_tests")
+  ADD_CUSTOM_TARGET(run_model_tests COMMAND ${CMAKE_CTEST_COMMAND} -C "${CMAKE_BUILD_TYPE}" -LE "models_tests")
 ENDIF(ADD_MODELS_TESTS)
 
+IF(ADD_COMPATIBILITY_TESTS)
+  ADD_SUBDIRECTORY (test.compatibility)
+  ADD_CUSTOM_TARGET(run_compatibility_tests COMMAND ${CMAKE_CTEST_COMMAND} -C "${CMAKE_BUILD_TYPE}" -LE "tests_compatibility")
+ENDIF(ADD_COMPATIBILITY_TESTS)
+
+IF(ADD_HDF_TESTS)
+  ADD_SUBDIRECTORY (test.hdfs)
+ENDIF(ADD_HDF_TESTS)
 
 IF(SHAPER_BUILD_DOC)
     INCLUDE(FindSphinx)