The grpc_cpp_plugin may failed to be found (#211)
Signed-off-by: Tao He <sighingnow@gmail.com>
This commit is contained in:
parent
6e4b45f986
commit
af0c96f6ba
|
|
@ -119,7 +119,7 @@ if(Protobuf_PROTOC_EXECUTABLE)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
find_package(gRPC QUIET)
|
find_package(gRPC QUIET)
|
||||||
if(gRPC_FOUND)
|
if(gRPC_FOUND AND TARGET gRPC::grpc AND TARGET gRPC::grpc_cpp_plugin)
|
||||||
set(GRPC_LIBRARIES gRPC::gpr gRPC::grpc gRPC::grpc++)
|
set(GRPC_LIBRARIES gRPC::gpr gRPC::grpc gRPC::grpc++)
|
||||||
get_target_property(GRPC_CPP_PLUGIN gRPC::grpc_cpp_plugin LOCATION)
|
get_target_property(GRPC_CPP_PLUGIN gRPC::grpc_cpp_plugin LOCATION)
|
||||||
get_target_property(GRPC_INCLUDE_DIR gRPC::grpc INTERFACE_INCLUDE_DIRECTORIES)
|
get_target_property(GRPC_INCLUDE_DIR gRPC::grpc INTERFACE_INCLUDE_DIRECTORIES)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue