Red Hat Bugzilla – Bug 1471512
openmpi-devel package does not properly install pkg-config files
Last modified: 2017-07-19 20:57:26 EDT
The openmpi-devel package does not properly install pkg-config files, making it difficult to compile mpi-using software without fiddling with fedora-specific paths.
I am using Fedora 25 with the openmpi-devel package in version 1.10.5.
How to reproduce: after installing `openmpi-devel`, `pkg-config --cflags ompi` prints:
> Package ompi was not found in the pkg-config search path.
> Perhaps you should add the directory containing `ompi.pc'
> to the PKG_CONFIG_PATH environment variable
> No package 'ompi' found
However, notice that `rpm -ql openmpi-devel | grep pkgconfig` returns the following, which suggests that pkg-config integration *was* planned for this package:
People on the web document ugly workaround for the lack of pkg-config support. See http://www.cybaea.net/journal/2009/06/12/R-tips-Installing-Rmpi-on-Fedora-Linux/ for example.
Note: this seems closely related to the bug 221343, back in 2007-2008, which reported that no "openmpi" package was available, and was closed on a claim that Fedora 8 fixed the issue. There is no "openmpi" package on my machine (try with `pkg-config --cflags openmpi`), and upstream seems to use "ompi" as the pkg-config name now:
Well, you're expected to load the module first:
# module load mpi/openmpi-x86_64
# pkg-config --cflags ompi
-pthread -I/usr/include/openmpi-x86_64 -I/usr/include/openmpi-x86_64/
But it is true that since the pkgconfig modules are named "ompi*" and "orte", there is no conflict with the other MPI implementations, and we could have them in the main pkgconfig directory.