Skip to content

how to compile a c++ program #91

Closed Answered by scivision
xiaorong117 asked this question in Q&A
Discussion options

You must be logged in to vote

No, I added an example at the bottom of Readme.md just now


To build the example, first "install" the MUMPS package-the default install location is under the MUMPS build/local directory:

cmake --install build

cmake -S example -B example/build -DMUMPS_ROOT=build/local

cmake --build example/build

Using binary libraries

Linking the MUMPS binaries into a user-program is project-dependant.
An example using the examples in this project with GNU GCC, using the "mpicxx" MPI compiler wrapper:

mpicxx ./example/d_example.cpp -I./build/local/include -L./build/local/lib -ldmumps -lmumps_common -lpord -lscalapack -lblacs -llapack -lblas -lgfortran

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@scivision
Comment options

Answer selected by xiaorong117
@xiaorong117
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #88 on July 09, 2024 14:51.