Based on the output, this looks like OpenMPI 2.1, which unfortunately isn’t supported by the example yet. Per the README for the current production release, the options for the MPI implementation are:
OpenMPI 1.8.1
MPICH 3.2
Intel MPI 5.0.1
so I would see if you can install one of these. If you’re on a cluster supporting MPI, it’s highly likely that one or more of these is available.
The MPI example is in need of maintenance, and longer term integration in the core toolkit. Unfortunately we don’t have the manpower to do this right now.
Hi,
I am having some issues while trying to install G4mpi libraries so I thought of posting here. On our cluster, when I type “make”, I get an error message:
error: ‘MPI’ does not name a type; did you mean ‘M_PI’?
const MPI::Intracomm* GetComm() const { return &COMM_G4COMMAND_; }
On my MacBook (Monterey 12.3.1), I get a similar error:
error: use of undeclared identifier ‘MPI’
const MPI::Intracomm* GetComm() const { return &COMM_G4COMMAND_; }
I would really appreciate any help regarding this.
Apologies for the delay in replying - as noted above G4mpi is only known to work with OpenMPI 1.8.1 due to the deprecation of the C++ interface. Unfortunately, we don’t have any available FTE to work on updates or further support for MPI use at the moment.
I was able to install G4mpi libraries using Intel MPI. But I cannot build an example (exMPI04). I tried using the intel MPI compiler wrapper by setting the environment as “export I_MPI_CXX=icpc” but the build fails. I tried other compilers like igxx, icxx etc without success. I am not sure what the issue is so I’m going to attach the error message below. Thank you.
Here’s the build command: cmake -DGeant4_DIR=/path to Geant4-11.0.1 -DG4mpi_DIR=/path to G4mpi-11.0.1 /path to source
– Could NOT find MPI_C (missing: MPI_C_WORKS)
– Could NOT find MPI_CXX (missing: MPI_CXX_WORKS)
CMake Error at /usr/local/biotools/cmake/cmake-3.22.2/share/cmake-3.22/Modules/FindPackageHandleStandardArgs.cmake:230 (message):
Could NOT find MPI (missing: MPI_C_FOUND MPI_CXX_FOUND)
Call Stack (most recent call first):
/usr/local/biotools/cmake/cmake-3.22.2/share/cmake-3.22/Modules/FindPackageHandleStandardArgs.cmake:594 (_FPHSA_FAILURE_MESSAGE)
/usr/local/biotools/cmake/cmake-3.22.2/share/cmake-3.22/Modules/FindMPI.cmake:1830 (find_package_handle_standard_args)
/research/labs/radonc/beltranc/m254407/Particle/MPI/build/lib64/G4mpi-11.0.1/G4mpiConfig.cmake:36 (find_package)
CMakeLists.txt:23 (find_package)