mirror of
https://github.com/OPM/ResInsight.git
synced 2025-01-01 03:37:15 -06:00
Look for protoc and grpc_cpp_plugin in two places.
This commit is contained in:
parent
c57f2d8b4a
commit
5bf3bfde33
@ -91,9 +91,22 @@ else()
|
|||||||
find_package(PkgConfig REQUIRED)
|
find_package(PkgConfig REQUIRED)
|
||||||
pkg_check_modules(GRPC REQUIRED grpc++_unsecure>=1.20 grpc_unsecure gpr
|
pkg_check_modules(GRPC REQUIRED grpc++_unsecure>=1.20 grpc_unsecure gpr
|
||||||
protobuf)
|
protobuf)
|
||||||
set(_PROTOBUF_PROTOC "${RESINSIGHT_GRPC_INSTALL_PREFIX}/bin/protoc")
|
if(EXISTS "${RESINSIGHT_GRPC_INSTALL_PREFIX}/bin/protoc")
|
||||||
set(_GRPC_CPP_PLUGIN_EXECUTABLE
|
set(_PROTOBUF_PROTOC "${RESINSIGHT_GRPC_INSTALL_PREFIX}/bin/protoc")
|
||||||
"${RESINSIGHT_GRPC_INSTALL_PREFIX}/bin/grpc_cpp_plugin")
|
elseif(EXISTS "${RESINSIGHT_GRPC_INSTALL_PREFIX}/tools/protobuf/protoc")
|
||||||
|
set(_PROTOBUF_PROTOC
|
||||||
|
"${RESINSIGHT_GRPC_INSTALL_PREFIX}/tools/protobuf/protoc")
|
||||||
|
else()
|
||||||
|
message(FATAL_ERROR "Could not find the protobuf compiler (protoc)")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if(EXISTS "${RESINSIGHT_GRPC_INSTALL_PREFIX}/bin/grpc_cpp_plugin")
|
||||||
|
set(_GRPC_CPP_PLUGIN_EXECUTABLE
|
||||||
|
"${RESINSIGHT_GRPC_INSTALL_PREFIX}/bin/grpc_cpp_plugin")
|
||||||
|
elseif(EXISTS "${RESINSIGHT_GRPC_INSTALL_PREFIX}/tools/grpc/grpc_cpp_plugin")
|
||||||
|
set(_GRPC_CPP_PLUGIN_EXECUTABLE
|
||||||
|
"${RESINSIGHT_GRPC_INSTALL_PREFIX}/tools/grpc/grpc_cpp_plugin")
|
||||||
|
endif()
|
||||||
include_directories(AFTER ${GRPC_INCLUDE_DIRS})
|
include_directories(AFTER ${GRPC_INCLUDE_DIRS})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user