-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CMake configuration file missing dependency to MPI::MPI_C #17
Comments
Yes, adding a test will certainly be a required part of the solution. |
As for now, there still might be a problem with open MPI: When including mpi.h, most the OpenMPI distribution I've found so far insist on detecting a C++ compiler, thus including the legacy C++ headers, which in turn brings in some (unused) C++ MPI symbols. And I think OpenMPI is the most widespread MPI implementation. I'm planing to explicitly prohibit that by default (#73) but untill then... (I'll try to do it this we at least on develop). I have no experience with boostorg/boost_install yet. |
I'll transfer this issue to boost_install. |
As far as I can see, what's needed is 63c74f6. It's not possible to use PUBLIC for an imported library, only INTERFACE linking is allowed, but I hope CMake does the right thing with those. I don't have a way to test that at present; it's on the |
I had a look at Boost.Iostreams that also have dependencies to third party libraries (zlib, bzip2) and it looks like it might have the same issue. I have open an issue #18 (in parallel to your issue transfer).
I think it does the right thing. |
Looking at the documentation of FindMPI,
|
Yes, |
Almost done; the MPI tests just fail because of boostorg/mpi@8619d7b#commitcomment-35672247. |
Merged to develop. |
@pdimov Thank you very much! I'll try to find some time to contribute a test. |
It already has a test: https://github.com/boostorg/boost_install/tree/develop/test/mpi |
The CMake configuration files generated at installation with boostorg/boost_install have an imported target that is missing a dependency to the underlying MPI library. The symptoms are an invalid linking order and the associated undefined symbols errors.
@pdimov, what would be the right way to have something like
find_dependency(MPI)
andtarget_link_libraries(Boost::mpi PUBLIC MPI::MPI_C)
added to the config file? Shall we add a test for MPI to the boost_install test suite?The text was updated successfully, but these errors were encountered: