]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
If MPI2 is available container launches MPI_Init et MPI_Finalize for the future use...
authorageay <ageay>
Thu, 19 Aug 2004 11:07:20 +0000 (11:07 +0000)
committerageay <ageay>
Thu, 19 Aug 2004 11:07:20 +0000 (11:07 +0000)
src/Container/SALOME_Container.cxx

index 921c3ce26c2d3cb362e0164a3a6980dfc17d7299..1217b2bd72bc6934cf49b2c3d68829d5a8a733f9 100644 (file)
@@ -42,6 +42,10 @@ using namespace std;
 #include <Utils_Timer.hxx>
 #endif
 
+#ifdef HAVE_MPI2
+#include <mpi.h>
+#endif
+
 #include <Python.h>
 
 static PyMethodDef MethodPyVoidMethod[] =
@@ -60,7 +64,9 @@ int main(int argc, char* argv[])
 
   try
     {
-    
+#ifdef HAVE_MPI2
+      MPI_Init(&argc,&argv);
+#endif
       // Initialise the ORB.
       ORB_INIT &init = *SINGLETON_<ORB_INIT>::Instance() ;
       ASSERT(SINGLETON_<ORB_INIT>::IsAlreadyExisting()) ;
@@ -227,6 +233,9 @@ int main(int argc, char* argv[])
     {
       INFOS("Caught unknown exception.")
        }
+#ifdef HAVE_MPI2
+  MPI_Finalize();
+#endif
   END_OF(argv[0]);
 }