File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed
Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -403,6 +403,13 @@ macro (google_cloud_cpp_enable_cleanup)
403403 set (GOOGLE_CLOUD_CPP_ENABLE_REST ON )
404404 endif ()
405405
406+ # We need the REST libraries for the full suite of samples.
407+ if (NOT GOOGLE_CLOUD_CPP_ENABLE_REST
408+ AND BUILD_TESTING
409+ AND GOOGLE_CLOUD_CPP_ENABLE_CXX_EXCEPTIONS)
410+ set (GOOGLE_CLOUD_CPP_ENABLE_REST ON )
411+ endif ()
412+
406413 list (REMOVE_DUPLICATES GOOGLE_CLOUD_CPP_ENABLE)
407414endmacro ()
408415
Original file line number Diff line number Diff line change @@ -68,7 +68,11 @@ if (GOOGLE_CLOUD_CPP_ENABLE_REST AND GOOGLE_CLOUD_CPP_ENABLE_GRPC)
6868 )
6969endif ()
7070
71- if (universe_domain IN_LIST GOOGLE_CLOUD_CPP_ENABLE)
71+ # We need the universe_domain library for the full suite of samples if it isn't
72+ # already enabled.
73+ if (universe_domain IN_LIST GOOGLE_CLOUD_CPP_ENABLE
74+ OR BUILD_TESTING
75+ AND GOOGLE_CLOUD_CPP_ENABLE_CXX_EXCEPTIONS)
7276 include (
7377 "${CMAKE_CURRENT_SOURCE_DIR} /google_cloud_cpp_universe_domain.cmake" )
7478 add_subdirectory (universe_domain)
You can’t perform that action at this time.
0 commit comments