Skip to content
Snippets Groups Projects
Commit cc8e2943 authored by Jan David Mol's avatar Jan David Mol
Browse files

Task #2680: Fixed for MPI platforms

parent a3d5c4c4
No related branches found
No related tags found
No related merge requests found
...@@ -28,6 +28,11 @@ ...@@ -28,6 +28,11 @@
#include <Stream/NullStream.h> #include <Stream/NullStream.h>
#include <cstdlib> #include <cstdlib>
#if defined HAVE_MPI
#define MPICH_IGNORE_CXX_SEEK
#include <mpi.h>
#endif
using namespace LOFAR; using namespace LOFAR;
using namespace LOFAR::RTCP; using namespace LOFAR::RTCP;
...@@ -39,7 +44,13 @@ Stream *createIONstream(unsigned channel, const LocationInfo &locationInfo) ...@@ -39,7 +44,13 @@ Stream *createIONstream(unsigned channel, const LocationInfo &locationInfo)
return new NullStream(); return new NullStream();
} }
int main() { int main(int argc, char **argv) {
#if defined HAVE_MPI
MPI_Init(&argc, &argv);
#else
argc = argc; argv = argv; // Keep compiler happy ;-)
#endif
setenv("NR_PSETS", "64", 1); setenv("NR_PSETS", "64", 1);
setenv("PSET_SIZE", "64", 1); setenv("PSET_SIZE", "64", 1);
...@@ -66,6 +77,10 @@ int main() { ...@@ -66,6 +77,10 @@ int main() {
// postprocess // postprocess
delete proc; delete proc;
#if defined HAVE_MPI
MPI_Finalize();
#endif
return 0; return 0;
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment