From 1a381dc3c09bee6d5a6e4845e5e19ebf08260968 Mon Sep 17 00:00:00 2001 From: eschnett Date: Sat, 21 Jul 2012 10:35:11 +0000 Subject: Move MPI support from flesh to a thorn Move MPI support from flesh to thorn ExternalLibraries/MPI. This also requires thorns that call MPI directly to declare this in their configuration.ccl. Existing configurations using MPI need to include ExternalLibraries/MPI into their thorn list. * Declare that the flesh optionally uses MPI (because it needs to call MPI_Init) * Update test case mechanism to find out whether MPI is used * Handle configuration bindings for flesh * Don't special-case Crays any more when configuring Linux git-svn-id: http://svn.cactuscode.org/flesh/trunk@4847 17b73243-c579-4c4c-a9d2-2d5706c11dac --- src/comm/CactusDefaultComm.c | 3 ++- src/configuration.ccl | 3 +++ src/main/ProcessEnvironment.c | 3 ++- src/main/ShutdownCactus.c | 3 ++- 4 files changed, 9 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/comm/CactusDefaultComm.c b/src/comm/CactusDefaultComm.c index b3d341c9..330cdcbe 100644 --- a/src/comm/CactusDefaultComm.c +++ b/src/comm/CactusDefaultComm.c @@ -9,6 +9,7 @@ @@*/ +#include "cctk_Capabilities.h" #include "cctk_Flesh.h" #include "cctk_Groups.h" #include "cctk_Constants.h" @@ -29,7 +30,7 @@ #endif #ifdef CCTK_MPI -#include "mpi.h" +# include #endif static const char *rcsid = "$Header$"; diff --git a/src/configuration.ccl b/src/configuration.ccl index e69de29b..3b95dd47 100644 --- a/src/configuration.ccl +++ b/src/configuration.ccl @@ -0,0 +1,3 @@ +OPTIONAL MPI +{ +} diff --git a/src/main/ProcessEnvironment.c b/src/main/ProcessEnvironment.c index 64be6f14..97ec4e2e 100644 --- a/src/main/ProcessEnvironment.c +++ b/src/main/ProcessEnvironment.c @@ -11,10 +11,11 @@ #include #include +#include "cctk_Capabilities.h" #include "cctk_Flesh.h" #ifdef CCTK_MPI -#include "mpi.h" +# include #endif static const char *rcsid = "$Header$"; diff --git a/src/main/ShutdownCactus.c b/src/main/ShutdownCactus.c index 1e61224c..df7a347e 100644 --- a/src/main/ShutdownCactus.c +++ b/src/main/ShutdownCactus.c @@ -13,13 +13,14 @@ #include #include +#include "cctk_Capabilities.h" #include "cctk_Flesh.h" #include "cctk_Misc.h" #include "cctk_Parameters.h" #include "cctk_Schedule.h" #ifdef CCTK_MPI -#include "mpi.h" +# include "mpi.h" #endif static const char *rcsid = "$Header$"; -- cgit v1.2.3