Salome HOME
bos #26460 Add SSL mode
[modules/hexablock.git] / src / HEXABLOCKGUI / CMakeLists.txt
index 36b3c13519bc71df03333fcdb838d1a777538926..448579f804c7a792e443c18829cb73c4d079da5d 100644 (file)
@@ -1,9 +1,9 @@
-# Copyright (C) 2012-2013  CEA/DEN, EDF R&D, OPEN CASCADE
+# Copyright (C) 2012-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.
+# 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
@@ -19,7 +19,7 @@
 
 ADD_SUBDIRECTORY(MyDlgRef)
 
-INCLUDE(UseQt4Ext)
+INCLUDE(UseQtExt)
 
 # --- options ---
 # additional include directories
@@ -29,8 +29,7 @@ INCLUDE_DIRECTORIES(
   ${OMNIORB_INCLUDE_DIR}
   ${LIBXML2_INCLUDE_DIR}
   ${Boost_INCLUDE_DIRS}
-  ${CAS_INCLUDE_DIRS}
-  ${VTK_INCLUDE_DIRS}
+  ${OpenCASCADE_INCLUDE_DIR}
   ${KERNEL_INCLUDE_DIRS}
   ${GUI_INCLUDE_DIRS}
   ${GEOM_INCLUDE_DIRS}
@@ -47,10 +46,14 @@ INCLUDE_DIRECTORIES(
 ADD_DEFINITIONS(
   ${BOOST_DEFINITIONS}
   ${OMNIORB_DEFINITIONS}
-  ${CAS_DEFINITIONS}
+  ${OpenCASCADE_DEFINITIONS}
   ${KERNEL_DEFINITIONS}
 )
 
+IF(WIN32)
+ ADD_DEFINITIONS(-DNOGDI -DNOMINMAX)
+ENDIF(WIN32)
+
 # libraries to link to
 SET(_link_LIBRARIES
   ${CORBA_LIBS}
@@ -70,7 +73,6 @@ SET(_moc_HEADERS
   HEXABLOCKGUI.hxx
   HEXABLOCKGUI_VtkDocumentGraphicView.hxx
   HEXABLOCKGUI_DocumentPanel.hxx
-  HEXABLOCKGUI_DocumentDelegate.hxx
   HEXABLOCKGUI_DocumentSelectionModel.hxx
   HEXABLOCKGUI_DocumentModel.hxx
   kmodelindexproxymapper.hxx
@@ -88,7 +90,7 @@ SET(HEXABLOCK_HEADERS
 # --- sources ---
 
 # sources / moc wrappings
-QT4_WRAP_CPP(_moc_SOURCES ${_moc_HEADERS})
+QT_WRAP_MOC(_moc_SOURCES ${_moc_HEADERS})
 
 # sources / static
 SET(_other_SOURCES
@@ -114,8 +116,6 @@ SET(_other_SOURCES
   HEXABLOCKGUI_DocumentSelectionModel.cxx
   HEXABLOCKGUI_DocumentItem.hxx
   HEXABLOCKGUI_DocumentItem.cxx
-  HEXABLOCKGUI_DocumentDelegate.hxx
-  HEXABLOCKGUI_DocumentDelegate.cxx
   HEXABLOCKGUI_DocumentPanel.hxx
   HEXABLOCKGUI_DocumentPanel.cxx
   HEXABLOCKGUI_SalomeTools.hxx
@@ -165,10 +165,11 @@ SET(_pyuic_files
   MakeHemiSphere_QTD.ui
   ModelInfo_QTD.ui
   AddShapeDialog_QTD.ui
+  ComputeMesh_QTD.ui
 )
 
 # scripts / pyuic wrappings
-QT4_WRAP_UI(_uic_HEADERS ${_pyuic_files})
+QT_WRAP_UIC(_uic_HEADERS ${_pyuic_files})
 
 # sources / to compile
 SET(HEXABLOCK_SOURCES ${_other_SOURCES} ${_moc_SOURCES} ${_uic_HEADERS})
@@ -179,15 +180,16 @@ SET(HEXABLOCK_SOURCES ${_other_SOURCES} ${_moc_SOURCES} ${_uic_HEADERS})
 SET(_ts_RESOURCES
   resources/HEXABLOCK_msg_en.ts
   resources/HEXABLOCK_msg_fr.ts
+  resources/HEXABLOCK_msg_ja.ts
   resources/HEXABLOCK_icons.ts
 ) 
 
 SALOME_CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/resources/SalomeApp.xml.in ${CMAKE_CURRENT_BINARY_DIR}/resources/SalomeApp.xml INSTALL ${SALOME_HEXABLOCK_INSTALL_RES_DATA})
+SALOME_CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/resources/SalomeApp.xml.in ${CMAKE_CURRENT_BINARY_DIR}/resources/SalomeAppSL.xml INSTALL ${SALOME_HEXABLOCK_INSTALL_RES_DATA})
 SALOME_CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/resources/HEXABLOCKCatalog.xml.in ${CMAKE_CURRENT_BINARY_DIR}/resources/HEXABLOCKCatalog.xml INSTALL ${SALOME_HEXABLOCK_INSTALL_RES_DATA})
 
 # resource files / static
 SET(_other_RESOURCES
-  resources/LightApp.xml
   resources/ModuleHexablock.png
   resources/ModuleHexablock15x15.png
   resources/new_document.png
@@ -243,11 +245,12 @@ SET(_other_RESOURCES
 
 ADD_LIBRARY(HEXABLOCK ${HEXABLOCK_SOURCES})
 TARGET_LINK_LIBRARIES(HEXABLOCK ${_link_LIBRARIES} )
+SET_TARGET_PROPERTIES(HEXABLOCK PROPERTIES COMPILE_DEFINITIONS QT_DISABLE_DEPRECATED_BEFORE=0 )
 INSTALL(TARGETS HEXABLOCK EXPORT ${PROJECT_NAME}TargetGroup DESTINATION ${SALOME_INSTALL_LIBS})
 
 INSTALL(FILES ${HEXABLOCK_HEADERS} DESTINATION ${SALOME_INSTALL_HEADERS})
 
-QT4_INSTALL_TS_RESOURCES("${_ts_RESOURCES}" "${SALOME_HEXABLOCK_INSTALL_RES_DATA}")
+QT_INSTALL_TS_RESOURCES("${_ts_RESOURCES}" "${SALOME_HEXABLOCK_INSTALL_RES_DATA}")
 
 INSTALL(FILES ${_other_RESOURCES}
         DESTINATION ${SALOME_HEXABLOCK_INSTALL_RES_DATA})