'paraview.0017-ParaView_protobuf_crash.patch',
'paraview.0015-Paraview_VTKM_ioss.patch'
'paraview.0018-spns-26351-autoconvert.patch',
- 'paraview.0019-spns-26344-VTK-OpenMP.patch'
+ 'paraview.0019-spns-26344-VTK-OpenMP.patch',
+ 'paraview.0020.findMPI.patch'
]
}
env.set('MPI_ROOT_DIR', prereq_dir)
env.set('OPENMPIDIR', prereq_dir)
env.set('MPI_ROOT', prereq_dir)
- env.set('MPI_C_FOUND', os.path.join(prereq_dir,'lib','libmpi.so'))
+ mpiclib_dir=prereq_dir
+ try:
+ if "debian" in distro.name().lower() and any(version in distro.version() for version in ["10"]) :
+ mpiclib_dir='/usr/lib/x86_64-linux-gnu/openmpi'
+ except:
+ pass
+ env.set('MPI_C_FOUND', os.path.join(mpiclib_dir,'lib','libmpi.so'))
env.prepend('PATH', os.path.join(prereq_dir, 'bin'))
env.prepend('LD_LIBRARY_PATH', os.path.join(prereq_dir,'lib'))
--- /dev/null
+diff -Naur ParaView_ref/VTK/CMake/patches/3.17/FindMPI.cmake ParaView_new/VTK/CMake/patches/3.17/FindMPI.cmake
+--- ParaView_ref/VTK/CMake/patches/3.17/FindMPI.cmake 2022-02-02 10:45:40.273534527 +0100
++++ ParaView_new/VTK/CMake/patches/3.17/FindMPI.cmake 2022-02-02 12:20:19.005537074 +0100
+@@ -1727,6 +1727,10 @@
+ list(APPEND _MPI_REQ_VARS "MPI_MPICXX_FOUND")
+ endif()
+
++if(DEFINED ENV{MPI_C_FOUND})
++ set(MPI_C_FOUND $ENV{MPI_C_FOUND})
++endif()
++
+ find_package_handle_standard_args(MPI
+ REQUIRED_VARS ${_MPI_REQ_VARS}
+ VERSION_VAR ${_MPI_MIN_VERSION}