boost-cmake / boost

Cmake-based build of boost
Boost Software License 1.0
58 stars 24 forks source link

Handling of missing build dependencies #2

Closed rleigh-codelibre closed 7 years ago

rleigh-codelibre commented 7 years ago
-- Could NOT find MPI_C (missing:  MPI_C_LIBRARIES MPI_C_INCLUDE_PATH)                         
-- Could NOT find MPI_CXX (missing:  MPI_CXX_LIBRARIES MPI_CXX_INCLUDE_PATH)

Currently it seems that missing build dependencies results in a build failure, rather than skipping of optional components. Has this been discussed previously? Strategies could include:

pfultz2 commented 7 years ago

Ideally, I am thinking of doing find_package(MPI) in the top-level cmake, and then if its missing just skip those the MPI libraries.

rleigh-codelibre commented 7 years ago

That would make complete sense. The top-level has the overview of the whole build, and it would fit there.

pfultz2 commented 7 years ago

So this has been updated to make this optional.