hpack_parser.h compiler error

94 views
Skip to first unread message

Fridolin Siegmund

unread,
Jan 17, 2022, 10:15:15 AM1/17/22
to grpc.io
Hi!
I want to integrate a grpc client in an existing c project. As an standalone example (in C!)  it compiles and works fine (cmake with FetchConent to fetch grpc [https://github.com/grpc/grpc/tree/master/src/cpp#fetchcontent]). But included in the existing project (cmake too, part to fetch/include grpc is the same) hpack_parser.h throws 28 errors.
For example:
- _deps/grpc-src/src/core/ext/transport/chttp2/transport/hpack_parser.h:39:5: note: in expansion of macro ‘None’

- _deps/grpc-src/src/core/ext/transport/chttp2/transport/hpack_parser.h:48:5: note: in expansion of macro ‘None’

- _deps/grpc-src/src/core/ext/transport/chttp2/transport/hpack_parser.h:67:16: error: expected constructor, destructor, or type conversion before ‘;’ token  HPackParser();

- _deps/grpc-src/src/core/ext/transport/chttp2/transport/hpack_parser.h:70:21: error: ‘HPackParser’ does not name a type
   HPackParser(const HPackParser&) = delete;
                     ^~~~~~~~~~~

I know if its working standalone the error must be on my side, but maybe there is some known issue regarding hpack_parser when included in other projects. I already tried to run the standalone example with the same compiler flags as in the c project and it worked well, so this shouldn't be the problem.

Thanks and Greetings

veb...@google.com

unread,
May 26, 2022, 6:22:23 PM5/26/22
to grpc.io
gRPC Core needs C++ to build it.
Reply all
Reply to author
Forward
0 new messages