File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
libmpdata++/concurr/detail Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -108,13 +108,13 @@ namespace libmpdataxx
108108#if !defined(USE_MPI)
109109 if (
110110 // mvapich2
111- std::getenv (" MV2_COMM_WORLD_RANK" ) != NULL ||
111+ std::getenv (" MV2_COMM_WORLD_RANK" ) != NULL && std::atoi ( std::getenv ( " MV2_COMM_WORLD_SIZE " )) > 1 ||
112112 // mpich
113- std::getenv (" PMI_RANK" ) != NULL ||
113+ std::getenv (" PMI_RANK" ) != NULL && std::atoi ( std::getenv ( " PMI_SIZE " )) > 1 ||
114114 // openmpi
115- std::getenv (" OMPI_COMM_WORLD_RANK" ) != NULL ||
115+ std::getenv (" OMPI_COMM_WORLD_RANK" ) != NULL && std::atoi ( std::getenv ( " OMPI_COMM_WORLD_SIZE " )) > 1 ||
116116 // lam
117- std::getenv (" LAMRANK" ) != NULL
117+ std::getenv (" LAMRANK" ) != NULL && std::atoi ( std::getenv ( " LAMSIZE " )) > 1
118118 ) throw std::runtime_error (" mpirun environment variable detected but libmpdata++ was compiled with MPI disabled" );
119119#else
120120 // init mpi here, since distmem is constructed before hdf5
You can’t perform that action at this time.
0 commit comments