You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What version of gRPC and what language are you using?
Tried "master" and "v1.67.0" with C++
What operating system (Linux, Windows,...) and version?
Linux, Ubuntu22.04
What runtime / compiler are you using (e.g. python version or version of gcc)
gcc11.4.0
What did you do?
I want to build absl, Protobuf, and grpc statically by FetchContenet_Declare , Now i face the issue as #35922 said. I can provide more details:
The grpc trying to get the _gRPC_PROTOBUF_WELLKNOWN_INCLUDE_DIR from libprotoc
since libprotoc link libprotobuf, and the libprotobuf do:
target_include_directories(libprotobuf PUBLIC
$<BUILD_INTERFACE:${protobuf_SOURCE_DIR}/src>
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
)
Now _gRPC_PROTOBUF_WELLKNOWN_INCLUDE_DIR is a "generator expression"
The protobuf_generate_grpc_cpp_with_import_path_correction in CMakeLists.txt will get that:
function(protobuf_generate_grpc_cpp_with_import_path_correction FILE_LOCATION IMPORT_PATH)
if(NOT FILE_LOCATION)
message(SEND_ERROR "Error: PROTOBUF_GENERATE_GRPC_CPP() called without any proto files")
return()
endif()
# Sets the include path for ProtoBuf filesset(_protobuf_include_path -I . -I ${_gRPC_PROTOBUF_WELLKNOWN_INCLUDE_DIR})
...
Now the _gRPC_PROTOBUF_WELLKNOWN_INCLUDE_DIR is a "list", with "INSTALL_INTERFACE" an empty string, cause all the protobuf_generate_grpc_cpp_with_import_path_correction call fails
What did you expect to see?
The _gRPC_PROTOBUF_WELLKNOWN_INCLUDE_DIR should be a single dir or list without any empty string.
You seem to have passed an empty string as one of the arguments to /xxx/build/Debug/_deps/protobuf-build/protoc-28.2.0. This is actually sort of hard to do. Congrats. Unfortunately it is not valid input so the program is going to die now.
Anything else we should know about your project / environment?
Protobuf version: v5.28.2, absl is from "master"
CMake version: 3.30
I use FetchContenet_Declare for all 3 projects and set all dependencies for grpc as "package"
The text was updated successfully, but these errors were encountered:
What version of gRPC and what language are you using?
Tried "
master
" and "v1.67.0
" withC++
What operating system (Linux, Windows,...) and version?
Linux, Ubuntu22.04
What runtime / compiler are you using (e.g. python version or version of gcc)
gcc11.4.0
What did you do?
I want to build absl, Protobuf, and grpc statically by
FetchContenet_Declare
, Now i face the issue as #35922 said. I can provide more details:grpc
trying to get the_gRPC_PROTOBUF_WELLKNOWN_INCLUDE_DIR
fromlibprotoc
libprotoc
linklibprotobuf
, and the libprotobuf do:_gRPC_PROTOBUF_WELLKNOWN_INCLUDE_DIR
is a "generator expression"protobuf_generate_grpc_cpp_with_import_path_correction
in CMakeLists.txt will get that:_gRPC_PROTOBUF_WELLKNOWN_INCLUDE_DIR
is a "list", with "INSTALL_INTERFACE" an empty string, cause all theprotobuf_generate_grpc_cpp_with_import_path_correction
call failsWhat did you expect to see?
The
_gRPC_PROTOBUF_WELLKNOWN_INCLUDE_DIR
should be a single dir or list without any empty string.What did you see instead?
In my case, this WRONG cmake command would be:
the complain from
protoc
:Anything else we should know about your project / environment?
The text was updated successfully, but these errors were encountered: