UoB-HPC / cloverleaf_sycl

Other
4 stars 1 forks source link

CMake updates for special MPI edge cases causes by Cray #3

Closed tom91136 closed 4 years ago

tom91136 commented 4 years ago
tom91136 commented 4 years ago

To add some background: CMake has a FindMPI macro which is activated by: find_package(MPI REQUIRED), there are conflicting information regarding whether setting C/CXX to the compiler wrapper is OK. Regardless, if I set the compiler to CC, which is what Cray provides, CMake detects the correct MPI implementation but then did not add the correct paths for the MPI headers hence the code won't compile.
Manually adding the include directory made it compile but then actually links to the wrong MPI library so the executable won't start.

This entire issue is specific to cray and their gnu environment as the regular gcc/mpi combo worked fine.