CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   SU2 Installation (https://www.cfd-online.com/Forums/su2-installation/)
-   -   Error when compiling SU2 on Raspberry Pi Cluster (https://www.cfd-online.com/Forums/su2-installation/243388-error-when-compiling-su2-raspberry-pi-cluster.html)

George5610 June 15, 2022 10:13

Error when compiling SU2 on Raspberry Pi Cluster
 
I am attempting to install SU2 on a raspberry pi cluster with openmpi.
I have the SU2 source in a file share and ran meson.py with using
Code:

./meson.py -Dcustom-mpi=true -Dextra-deps=ompi build
meson had an output of this
I added the export lines to bashrc then ran ninja with
Code:

./ninja -C build install
However it fails as it cant find mpi.h.


Ninja output link



Can anyone shed some light on this error?


Let me know if i can include any more files or logs.


Thanks

bigfootedrockmidget June 16, 2022 17:54

The first thing to check is if mpi.h is actually installed somewhere. It is part of a specific package, if you use a package manager, the package that provides it is probably called something like libopenmpi-dev. Usually, the ***-dev packages in linux are the packages that provide the header files.


When you have installed mpi.h, you can first check with a simple hello-world kind of test to see if you can compile and run an openmpi program.

For instance: https://mpitutorial.com/tutorials/mpi-hello-world/

George5610 June 17, 2022 08:35

I have already run C and python in parallel on the cluster using the mpi header file and it works, i have run hello world and a Pi approximation script.



Because it's a raspberry pi they are installed in a non ordinary location.


Code:

mpicc -show
returns this results
Code:

gcc -I/usr/lib/aarch64-linux-gnu/openmpi/include/openmpi -I/usr/lib/aarch64-linux-gnu/openmpi/include -pthread -L/usr/lib/aarch64-linux-gnu/openmpi/lib -lmpi
The mpi header file is located in
Code:

/usr/lib/aarch64-linux-gnu/openmpi/include
Is ninja looking in a different location for the file?

pcg June 19, 2022 13:40

Try doing
export CC=mpicc
export CXX=mpicxx
Before calling ./meson.py (delete the build folder first)

George5610 June 21, 2022 08:53

Thanks
This solved the problem.


All times are GMT -4. The time now is 04:03.