Graham Walsh
unread,Jul 22, 2024, 11:16:34 AM7/22/24Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Protocol Buffers
Hi,
Im trying to build an example protoc plugin... the abseil dependencies are a nightmare. (link order).
How do I build the example protocol buffer plugin? I need the link order for the abseil libs... here....
g++ -I../protobuf/third_party/abseil-cpp -I../protobuf/src/ ./my_prot
oc_plugin.cc -o my_protoc_plugin ../protobuf/build/libprotoc.a ../protobuf/build/libprotobuf.a abseil/libabsl_base.a
abseil/libabsl_strings.a abseil/libabsl_flags_internal.a abseil/libabsl_hash.a -ldl -lpthread
Chasing these down (adding various abseil static libs) ... just takes me down a rabbit hole.
What the exact link order to use abseil static libs protoc plugin (please dont say bezel) I need the command line and link order for the static libs.
/usr/bin/ld: /tmp/cco7kRJk.o: in function `absl::lts_20240116::container_internal::EmptyGroup()':
my_protoc_plugin.cc:(.text._ZN4absl12lts_2024011618container_internal10EmptyGroupEv[_ZN4absl12lts_2024011618container_internal10EmptyGroupEv]+0xb): undefined reference to `absl::lts_20240116::container_internal::kEmptyGroup'
/usr/bin/ld: /tmp/cco7kRJk.o: in function `absl::lts_20240116::container_internal::AssertIsFull(absl::lts_20240116::container_internal::ctrl_t const*, unsigned char, unsigned char const*, char const*)':
my_protoc_plugin.cc:(.text._ZN4absl12lts_2024011618container_internal12AssertIsFullEPKNS1_6ctrl_tEhPKhPKc[_ZN4absl12lts_2024011618container_internal12AssertIsFullEPKNS1_6ctrl_tEhPKhPKc]+0x70): undefined reference to `absl::lts_20240116::raw_log_internal::RawLog(absl::lts_20240116::LogSeverity, char const*, int, char const*, ...)'
/usr/bin/ld: my_protoc_plugin.cc:(.text._ZN4absl12lts_2024011618container_internal12AssertIsFullE