MUMPS sparse solver
CMake downloads the source tarfile from MUMPS developer websites and builds.
CMake builds MUMPS in parallel faster and more conveniently than the original Makefiles.
CMake allows easy reuse of MUMPS in external projects via CMake
FetchContent
or ExternalProject or cmake --install
.
Many compilers and systems are supported by CMake build system on Windows, MacOS and Linux.
Static (default) or Shared cmake -DBUILD_SHARED_LIBS=on
MUMPS builds are supported.
Platforms known to work with MUMPS and CMake include:
- Windows
- MacOS
- GCC (Homebrew)
- Intel oneAPI
- Linux
- GCC
- Intel oneAPI
- NVIDIA HPC SDK
- Cray
By default PORD ordering is used. For large systems, Scotch and METIS ordering can be used.
The MUMPS project is distinct from this CMake script wrapper. See the MUMPS Users email list and MUMPS User Guide for any questions about MUMPS itself.
Build
From this repo's top directory:
cmake -B build
cmake --build build
With the default options, under the build/ directory this results in library binaries:
# Linux / MacOS / MSYS2
libdmumps.a
libmumps_common.a
libpord.a
libsmumps.a
Intel oneAPI Base Toolkit MKL LAPACK and Intel oneAPI HPC toolkit SCALAPACK are used. Do not try to build Lapack and Scalapack with oneAPI, the build will fail.
If the non-oneAPI compiler doesn't have LAPACK and SCALAPACK, first build and install them:
cmake -S scripts -B scripts/build -DCMAKE_INSTALL_PREFIX=~/mylibs
cmake --build scripts/build -t scalapack
# mumps
cmake -B build -DCMAKE_PREFIX_PATH=~/mylibs
cmake --build build
Numerous MUMPS build options are available.
Self test
Optionally, run self-tests:
ctest --test-dir build