eschnett / MPItrampoline

A forwarding MPI implementation that can use any other MPI implementation via an MPI ABI
MIT License
44 stars 4 forks source link

Incomplete installation #10

Closed spoutn1k closed 2 years ago

spoutn1k commented 2 years ago

Hello ! I am looking at installing MPItrampoline, and following the steps outlined in the README.md, I cannot access files later referenced.

For instance, on Summit at ORNL, using the following script:

INSTALLDIR=$HOME/mpiwrapper

module load cmake/3.18
module load gcc

cmake -S . -B build -DMPIEXEC_EXECUTABLE=mpiexec \
                               -DCMAKE_BUILD_TYPE=RelWithDebInfo \
                               -DCMAKE_INSTALL_PREFIX=$INSTALLDIR
cmake --build build
cmake --install build

The following installation is generated:

$ tree mpiwrapper/
mpiwrapper/
|-- bin
|   |-- mpicc
|   |-- mpicxx
|   |-- mpiexec
|   |-- mpifc
|   `-- mpifort
|-- include
|   |-- mpi.h
|   |-- mpi.mod
|   |-- mpi_declarations.h
|   |-- mpi_declarations_fortran.h
|   |-- mpi_declarations_fortran90.h
|   |-- mpi_defaults.h
|   |-- mpi_f08.mod
|   |-- mpi_version.h
|   |-- mpiabi.h
|   |-- mpiabif.h
|   |-- mpif.h
|   `-- mpio.h
|-- lib
|   |-- cmake
|   |   `-- MPItrampoline
|   |       |-- MPItrampolineConfig.cmake
|   |       |-- MPItrampolineConfigVersion.cmake
|   |       |-- MPItrampolineTargets-relwithdebinfo.cmake
|   |       `-- MPItrampolineTargets.cmake
|   `-- pkgconfig
|       `-- MPItrampoline.pc
`-- lib64
    |-- libmpi.a
    `-- libmpifort.a

7 directories, 24 files

The README.md dictates to use the wrapped libraries, but no shared libraries are available here. I looked through the options of the CMakeLists.txt but the only one defined in the project is the fortran flag.

Am I missing something ?

eschnett commented 2 years ago

There are two different libraries, MPItrampoline and MPIwrapper.

When you run your application, you need to set an environment variable to point towards (one of) the MPIwrapper you installed.

Thus, on Summit you would:

It seems you accidentally combined both steps.

spoutn1k commented 2 years ago

Oh I see, I indeed understood the wrapper should be installed from the MPItrampoline directory. Maybe it is just me, but making that clear in the README could help, just linking to MPIwrapper as to highlight this isn't a two in one package.

Edit: it is linked above ! My bad.