Salome HOME
Replacing DISABLE_PARASMESH with WIN32 yan/disable_parasmesh_win
authorYoann Audouin <yoann.audouin@edf.fr>
Wed, 26 Oct 2022 14:20:19 +0000 (16:20 +0200)
committerYoann Audouin <yoann.audouin@edf.fr>
Wed, 26 Oct 2022 14:20:19 +0000 (16:20 +0200)
src/SMESH/SMESH_Gen.cxx
src/SMESH/SMESH_Mesh.cxx
src/SMESH/SMESH_Mesh.hxx

index 4297420f8e9951218c4d3d665aa70497e9459f2a..61d4fc010092a442bad28ac641216f65df412ddd 100644 (file)
@@ -28,7 +28,7 @@
 
 //#define CHRONODEF
 //
-#ifndef DISABLE_PARAMESH
+#ifndef WIN32
 #include <boost/asio.hpp>
 #endif
 #include "SMESH_Gen.hxx"
@@ -350,7 +350,7 @@ bool SMESH_Gen::parallelComputeSubMeshes(
       smToCompute->ComputeStateEngine( SMESH_subMesh::CHECK_COMPUTE_STATE );
       continue;
     }
-#ifdef DISABLE_PARASMESH
+#ifdef WIN32
     compute_function(smToCompute, computeEvent,
                       shapeSM, aShapeOnly, allowedSubShapes,
                       aShapesId);
index edff014cdc7fe85b372b79e6d0dac4c31a85e582..fb373c5932ae01ae20422fcbdd2ec9afbe2ff88c 100644 (file)
@@ -239,7 +239,7 @@ SMESH_Mesh::~SMESH_Mesh()
     int result=pthread_create(&thread, NULL, deleteMeshDS, (void*)_meshDS);
 #endif
   }
-#ifndef DISABLE_PARASMESH
+#ifndef WIN32
   if(_pool)
     DeletePoolThreads();
 #endif
index deed18d6b8111d97f182ea2b1a3a433db950cb00..a59f7228a3ffc80d9fd9b33c84ed2bd84215b242 100644 (file)
@@ -50,7 +50,7 @@
 #include <ostream>
 
 #include <boost/filesystem.hpp>
-#ifndef DISABLE_PARASMESH
+#ifndef WIN32
 #include <boost/asio/thread_pool.hpp>
 #include <boost/thread.hpp>
 #endif
@@ -391,7 +391,7 @@ class SMESH_EXPORT SMESH_Mesh
 
   // Parallel computation functions
 
-#ifdef DISABLE_PARASMESH
+#ifdef WIN32
   void Lock() {};
   void Unlock() {};
 
@@ -420,7 +420,7 @@ class SMESH_EXPORT SMESH_Mesh
 
   // Temporary folder used during parallel Computation
   boost::filesystem::path tmp_folder;
-  #ifndef DISABLE_PARASMESH
+  #ifndef WIN32
   boost::asio::thread_pool *     _pool = nullptr; //thread pool for computation
   #endif
 
@@ -472,7 +472,7 @@ protected:
   TCallUp*                    _callUp;
 
   // Mutex for multhitreading write in SMESH_Mesh
-#ifndef DISABLE_PARASMESH
+#ifndef WIN32
   boost::mutex _my_lock;
 #endif
   int _NbThreads=0;