add explicit branch for PROVIDER=none

pull/20976/head
Jan Tattermusch 5 years ago
parent 6c07619fe4
commit 6d07e196e1
  1. 3
      cmake/benchmark.cmake
  2. 3
      cmake/gflags.cmake

@ -32,5 +32,6 @@ elseif(gRPC_BENCHMARK_PROVIDER STREQUAL "package")
set(_gRPC_BENCHMARK_LIBRARIES benchmark::benchmark) set(_gRPC_BENCHMARK_LIBRARIES benchmark::benchmark)
endif() endif()
set(_gRPC_FIND_BENCHMARK "if(NOT benchmark_FOUND)\n find_package(benchmark CONFIG)\nendif()") set(_gRPC_FIND_BENCHMARK "if(NOT benchmark_FOUND)\n find_package(benchmark CONFIG)\nendif()")
elseif(gRPC_BENCHMARK_PROVIDER STREQUAL "none")
# Benchmark is a test-only dependency and can be avoided if we're not building tests.
endif() endif()

@ -29,5 +29,6 @@ elseif(gRPC_GFLAGS_PROVIDER STREQUAL "package")
set(_gRPC_GFLAGS_LIBRARIES gflags::gflags) set(_gRPC_GFLAGS_LIBRARIES gflags::gflags)
endif() endif()
set(_gRPC_FIND_GFLAGS "if(NOT gflags_FOUND)\n find_package(gflags CONFIG)\nendif()") set(_gRPC_FIND_GFLAGS "if(NOT gflags_FOUND)\n find_package(gflags CONFIG)\nendif()")
elseif(gRPC_GFLAGS_PROVIDER STREQUAL "none")
# gflags is a test-only dependency and can be avoided if we're not building tests.
endif() endif()

Loading…
Cancel
Save