- removed comment
ExternalLibraries/MPI does not auto-detect openmpi on Debian/testing
Issue #1598
closed
configure.sh expects to find libmpi.a in $MPI_DIR/lib however Debian no longer delivers a static libmpi.a but only libmpi.so so the tests fails. The fix is likely similar to what HDF5 already does (ie accept any of .a .so .dylib as extensions for libraries). The fix is a bit complex though, so (given that Debian/stable is still fine) this is a reminder for after the release. Explictly specifying MPI_DIR, MPI_INC_DIRS, MPI_LIB_DIRS and MPI_LIBS allows this to be worked around in the current release.
For reference, the fragment from HDF5 looks like this:
# We look in these directories
DIRS="/usr /usr/local /usr/local/hdf5 /usr/local/packages/hdf5 /usr/local/apps/hdf5 /opt/local ${HOME} ${HOME}/hdf5 c:/packages/hdf5"
# look into each directory
for dir in $DIRS; do
# libraries might have different file extensions
for libext in a so dylib; do
# libraries can be in /lib or /lib64
for libdir in lib64 lib; do
# These files must exist
FILES="include/hdf5.h $(for lib in ${HDF5_CXX_LIBS} ${HDF5_FORTRAN_LIBS} ${HDF5_C_LIBS}; do echo ${libdir}/lib${lib}.${libext}; done)"
# assume this is the one and check all needed files
HDF5_DIR="$dir"
for file in $FILES; do
# discard this directory if one file was not found
if [ ! -r "$dir/$file" ]; then
unset HDF5_DIR
break
fi
done
# don't look further if all files have been found
if [ -n "$HDF5_DIR" ]; then
break
fi
done
# don't look further if all files have been found
if [ -n "$HDF5_DIR" ]; then
break
fi
done
# don't look further if all files have been found
if [ -n "$HDF5_DIR" ]; then
break
fi
done
Keyword: MPI
Comments (3)
-
-
reporter - changed status to resolved
- removed comment
The new mechanism detects OpenMPI correctly since mpicxx is in the PATH.
-
reporter - edited description
- changed status to closed
- Log in to comment
Is this still the case with the new MPI auto-detection mechanism?