Set explicit Boost/GMP discovery only if we build Boost/GMP, respectively.