Salome HOME
Fix for the issue #19726 : Placement failed because of wrong name in face selection.
[modules/shaper.git] / src / ExchangePlugin / CMakeLists.txt
index 3c6692e59eb3a8ab31d25c336d76c6f069337ae7..f6c615e96a1eedcc9d95643713b4060594a201e2 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright (C) 2014-2019  CEA/DEN, EDF R&D
+# Copyright (C) 2014-2020  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
@@ -42,6 +42,7 @@ SET(PROJECT_HEADERS
     ExchangePlugin_Dump.h
     ExchangePlugin_ImportPart.h
     ExchangePlugin_ExportPart.h
+    ExchangePlugin_Import.h
 )
 
 SET(PROJECT_SOURCES
@@ -53,6 +54,7 @@ SET(PROJECT_SOURCES
     ExchangePlugin_Dump.cpp
     ExchangePlugin_ImportPart.cpp
     ExchangePlugin_ExportPart.cpp
+    ExchangePlugin_Import.cpp
 )
 
 SET(XML_RESOURCES
@@ -65,6 +67,9 @@ SET(TEXT_RESOURCES
     ExchangePlugin_msg_fr.ts
 )
 
+SOURCE_GROUP ("XML Files" FILES ${XML_RESOURCES})
+SOURCE_GROUP ("Resource Files" FILES ${TEXT_RESOURCES})
+
 SET(PROJECT_LIBRARIES
     Events
     Config
@@ -75,9 +80,22 @@ SET(PROJECT_LIBRARIES
     GeomValidators
     XAOShaper
 )
-SOURCE_GROUP ("Resource Files" FILES ${TEXT_RESOURCES})
+
+# default dump approaches (will be set if not initialized)
+SET(PYTHONDUMP_NAMING ON  CACHE BOOL "Dump named references to shapes")
+SET(PYTHONDUMP_GEO    ON  CACHE BOOL "Dump references to shapes by the geometric properties")
+SET(PYTHONDUMP_WEAK   OFF CACHE BOOL "Dump weak named references to shapes")
 
 ADD_DEFINITIONS(-DEXCHANGEPLUGIN_EXPORTS)
+IF(${PYTHONDUMP_NAMING})
+  ADD_DEFINITIONS(-DEXCHANGEPLUGIN_DUMP_NAMING)
+ENDIF()
+IF(${PYTHONDUMP_GEO})
+  ADD_DEFINITIONS(-DEXCHANGEPLUGIN_DUMP_GEO)
+ENDIF()
+IF(${PYTHONDUMP_WEAK})
+  ADD_DEFINITIONS(-DEXCHANGEPLUGIN_DUMP_WEAK)
+ENDIF()
 ADD_LIBRARY(ExchangePlugin MODULE ${PROJECT_SOURCES} ${PROJECT_HEADERS} ${XML_RESOURCES} ${TEXT_RESOURCES})
 
 TARGET_LINK_LIBRARIES(ExchangePlugin ${PROJECT_LIBRARIES})
@@ -92,6 +110,7 @@ ADD_UNIT_TESTS(
   TestExport.py
   Test2290.py
   Test2459.py
+  Test18710.py
   TestExportToXAOWithFields.py
   TestExportToXAOWithGroupNotUpdated.py
   TestExport_FiniteValidator.py