X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FPartSet%2FCMakeLists.txt;h=ebc905b4251303ca0ec6c2422c2e55bbdd14cb42;hb=c575ad28dd7f9087e727b675f43bbbc9ad3446f6;hp=37575cf725c28525a1f7541c0224ba880c0130a6;hpb=7074394f8f08413d885f63be01df6bd5007b868c;p=modules%2Fshaper.git diff --git a/src/PartSet/CMakeLists.txt b/src/PartSet/CMakeLists.txt index 37575cf72..ebc905b42 100644 --- a/src/PartSet/CMakeLists.txt +++ b/src/PartSet/CMakeLists.txt @@ -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 -## +# Copyright (C) 2014-2021 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 +# INCLUDE(Common) INCLUDE(UseQtExt) @@ -25,7 +24,9 @@ INCLUDE(UseQtExt) INCLUDE_DIRECTORIES(${QT_INCLUDES}) # additional preprocessor / compiler flags -ADD_DEFINITIONS(${QT_DEFINITIONS}) +ADD_DEFINITIONS(${QT_DEFINITIONS} ${OpenCASCADE_DEFINITIONS}) + +SET(UPDATE_TRANSLATION OFF) SET(PROJECT_HEADERS PartSet.h @@ -41,12 +42,12 @@ SET(PROJECT_HEADERS PartSet_OperationPrs.h PartSet_OverconstraintListener.h PartSet_PreviewPlanes.h + PartSet_PreviewSketchPlane.h PartSet_ResultSketchPrs.h PartSet_SketcherMgr.h PartSet_SketcherReentrantMgr.h PartSet_Tools.h PartSet_Validators.h - PartSet_WidgetChoice.h PartSet_WidgetEditor.h PartSet_WidgetFeaturePointSelector.h PartSet_WidgetFileSelector.h @@ -58,6 +59,10 @@ SET(PROJECT_HEADERS PartSet_WidgetSketchLabel.h PartSet_CenterPrs.h PartSet_ExternalPointsMgr.h + PartSet_TreeNodes.h + PartSet_FieldStepPrs.h + PartSet_WidgetBSplinePoints.h + PartSet_BSplineWidget.h ) SET(PROJECT_MOC_HEADERS @@ -66,7 +71,6 @@ SET(PROJECT_MOC_HEADERS PartSet_Module.h PartSet_SketcherMgr.h PartSet_SketcherReentrantMgr.h - PartSet_WidgetChoice.h PartSet_WidgetEditor.h PartSet_WidgetFeaturePointSelector.h PartSet_WidgetFileSelector.h @@ -76,7 +80,9 @@ SET(PROJECT_MOC_HEADERS PartSet_WidgetShapeSelector.h PartSet_WidgetSketchCreator.h PartSet_WidgetSketchLabel.h + PartSet_WidgetBSplinePoints.h PartSet_ExternalPointsMgr.h + PartSet_BSplineWidget.h ) SET(PROJECT_SOURCES @@ -90,6 +96,7 @@ SET(PROJECT_SOURCES PartSet_OperationPrs.cpp PartSet_OverconstraintListener.cpp PartSet_PreviewPlanes.cpp + PartSet_PreviewSketchPlane.cpp PartSet_ResultSketchPrs.cpp PartSet_SketcherMgr.cpp PartSet_SketcherReentrantMgr.cpp @@ -106,26 +113,32 @@ SET(PROJECT_SOURCES PartSet_WidgetSketchLabel.cpp PartSet_CenterPrs.cpp PartSet_ExternalPointsMgr.cpp + PartSet_TreeNodes.cpp + PartSet_FieldStepPrs.cpp + PartSet_WidgetBSplinePoints.cpp + PartSet_BSplineWidget.cpp ) SET(PROJECT_RESOURCES PartSet_icons.qrc ) -#SET(TEXT_RESOURCES -# PartSet_msg_fr.ts -#) +SET(TEXT_RESOURCES + PartSet_msg_fr.ts +) SET(PROJECT_LIBRARIES ModuleBase ModelGeomAlgo Config + Locale GeomAPI GeomDataAPI SketcherPrs ${QT_LIBRARIES} - ${CAS_KERNEL} - ${CAS_SHAPE} + ${OpenCASCADE_FoundationClasses_LIBRARIES} + ${OpenCASCADE_ApplicationFramework_LIBRARIES} + ${OCCViewer} ) # sources / moc wrappings @@ -133,21 +146,27 @@ QT_WRAP_MOC(PROJECT_AUTOMOC ${PROJECT_MOC_HEADERS}) # sources / rcc wrappings QT_ADD_RESOURCES(PROJECT_COMPILED_RESOURCES ${PROJECT_RESOURCES}) -#QT4_ADD_TRANSLATION(QM_RESOURCES ${TEXT_RESOURCES}) -#QT4_CREATE_TRANSLATION(QM_RESOURCES -# ${PROJECT_SOURCES} -# ${TEXT_RESOURCES} -# OPTIONS -extensions cpp -no-recursive -# ) - -#SOURCE_GROUP ("Generated Files" FILES ${PROJECT_AUTOMOC} ${PROJECT_COMPILED_RESOURCES} ${QM_RESOURCES}) -SOURCE_GROUP ("Generated Files" FILES ${PROJECT_AUTOMOC} ${PROJECT_COMPILED_RESOURCES}) -#SOURCE_GROUP ("Resource Files" FILES ${TEXT_RESOURCES} ${PROJECT_RESOURCES}) -SOURCE_GROUP ("Resource Files" FILES ${PROJECT_RESOURCES}) + +IF (${UPDATE_TRANSLATION}) + SET(PROJECT_FILES ${PROJECT_SOURCES} ${PROJECT_HEADERS} ) + QT5_CREATE_TRANSLATION(QM_RESOURCES + ${PROJECT_FILES} + ${TEXT_RESOURCES} + OPTIONS -extensions cpp -no-recursive -locations none + ) +ELSE(${UPDATE_TRANSLATION}) + IF(${MAKE_TRANSLATION}) + QT5_ADD_TRANSLATION(QM_RESOURCES ${TEXT_RESOURCES}) + ENDIF(${MAKE_TRANSLATION}) +ENDIF(${UPDATE_TRANSLATION}) + +SOURCE_GROUP ("Generated Files" FILES ${PROJECT_AUTOMOC} ${PROJECT_COMPILED_RESOURCES} ${QM_RESOURCES}) +SOURCE_GROUP ("Resource Files" FILES ${TEXT_RESOURCES} ${PROJECT_RESOURCES}) INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/XGUI ${PROJECT_SOURCE_DIR}/src/Config ${PROJECT_SOURCE_DIR}/src/Events + ${PROJECT_SOURCE_DIR}/src/Locale ${PROJECT_SOURCE_DIR}/src/ModuleBase ${PROJECT_SOURCE_DIR}/src/ModelAPI ${PROJECT_SOURCE_DIR}/src/ModelGeomAlgo @@ -159,25 +178,23 @@ INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/src/XGUI ${PROJECT_SOURCE_DIR}/src/FeaturesPlugin ${PROJECT_SOURCE_DIR}/src/PartSetPlugin ${PROJECT_SOURCE_DIR}/src/GeomAPI - ${CAS_INCLUDE_DIRS} + ${PROJECT_SOURCE_DIR}/src/CollectionPlugin + ${OpenCASCADE_INCLUDE_DIR} ${SUIT_INCLUDE} ) -IF(${HAVE_SALOME}) - INCLUDE_DIRECTORIES(${SALOME_KERNEL_INCLUDE}) -ELSE(${HAVE_SALOME}) +IF(NOT ${HAVE_SALOME}) INCLUDE_DIRECTORIES(${APPELEMENTS_INCLUDE_DIR}) -ENDIF(${HAVE_SALOME}) - +ENDIF() -ADD_DEFINITIONS(-DPARTSET_EXPORTS ${CAS_DEFINITIONS}) +ADD_DEFINITIONS(-DPARTSET_EXPORTS ${OpenCASCADE_DEFINITIONS}) ADD_LIBRARY(PartSet SHARED ${PROJECT_SOURCES} ${PROJECT_HEADERS} ${PROJECT_COMPILED_RESOURCES} ${PROJECT_AUTOMOC} -# ${TEXT_RESOURCES} -# ${QM_RESOURCES} + ${TEXT_RESOURCES} + ${QM_RESOURCES} ) # The Qt5Widgets_LIBRARIES variable also includes QtGui and QtCore @@ -186,4 +203,4 @@ TARGET_LINK_LIBRARIES(PartSet ${PROJECT_LIBRARIES} XGUI ModelAPI GeomAlgoAPI) ADD_DEPENDENCIES(PartSet ModuleBase) INSTALL(TARGETS PartSet DESTINATION ${SHAPER_INSTALL_BIN}) -#INSTALL(FILES ${QM_RESOURCES} DESTINATION bin) +INSTALL(FILES ${QM_RESOURCES} DESTINATION ${SHAPER_INSTALL_QM_RESOURCES})