Building B2000++

Thanks to Thomas Rothermel and others from the DLR the B2000++ package build process of B2000++ has been converted from the autotools to cmake.

cmake has some distinct advantages for the user that wants to build a program:

  • Better checks and error reports if any required packages are missing.

  • Better mechanisms for finding required libraries, includes, etc.

  • Fast make files configuration process.

However, programming cmake is not easy.

To build B2000++ without any options is straightforward (see also the top-level CMakeListst.txt file for a list of options). Go to the path where the git checked out package is located:

cd $SMR_SRC/b2000pp
mkdir -p _build       # create the build directory
cd _build
rm -rf *              # clean up
cmake ..              # Create the make files
make [-j <n>] install # -j option submits at most <n> parallel compile jobs

If you want to compile B2000++ with MPI activated for the MUMPS solver:

cd $SMR_SRC/b2000pp
mkdir -p _build       # create the build directory
cd _build
rm -rf *              # clean up
cmake -DUSE_MPI=ON .. # Create the make files, compile with MPI
make [-j <n>] install # -j option submits at most <n> parallel compile jobs

B2000++ examples and verification test cases are, by default not installed. If you want them installed, add the -DBUILD_B2TESTDATA=ON to the cmake command. The B2000++ examples and verification test cases will the be installed in $SMR_PREFIX/share/b2000pp_data.