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?
gRPC v1.62.0
C++
What operating system (Linux, Windows,...) and version?
Ubuntu 22.04.1 LTS
What runtime / compiler are you using (e.g. python version or version of gcc)
cmake version 3.22.1
gcc and g++ (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
What did you do?
Followed the instructions at 'https://grpc.io/docs/languages/cpp/quickstart/' with updated cmake options to build gRPC dependencies from source with static linking. Specifically the following commands were executed as root:
The gRPC/protobuf build and install above are successful. All good so far.
Next, I compile my application and attempt to link its libraries, but I get this linking error:
/usr/bin/ld: /opt/grpc/grpc-1.62.0/lib/libgrpc.a(ssl_transport_security.cc.o): undefined reference to symbol 'SSL_CTX_set_keylog_callback@@OPENSSL_3.0.0'
/usr/bin/ld: /lib/x86_64-linux-gnu/libssl.so.3: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
What did you expect to see?
100% successful gRPC/protobuf build and install (yes, I saw this).
100% successful build for custom Ubuntu 22.04 gRPC/protobuf application (no, I did not see this).
What did you see instead?
Unexpected linker errors in my custom Ubuntu 22 gRPC/protobuf application, specifically:
/usr/bin/ld: /opt/grpc/grpc-1.62.0/lib/libgrpc.a(ssl_transport_security.cc.o): undefined reference to symbol 'SSL_CTX_set_keylog_callback@@OPENSSL_3.0.0'
/usr/bin/ld: /lib/x86_64-linux-gnu/libssl.so.3: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
Given that I built gRPC with shared-libs off, why is libssl.so.3 needed?
Anything else we should know about your project / environment?
My custom application is being ported from Ubuntu 16 to Ubuntu 22. No issues exist on Ubuntu 16 using gPRC v1.54.0. After experiencing this linking issue with v1.54.0 on Ubuntu 22, I upgraded gRPC to v1.62.0 but the issue remains. Has anyone else encountered a similar linking issue? How did you resolve it?
I see a similar issue here (googleapis/google-cloud-cpp#9063) but the original poster in that case was compiling gRPC using packages rather than source (modules).
If I search libssl.so.3 for its symbols, I see the undefined symbol:
I believe the issue described above may have been related to older/out-of-date libraries that were on my development platform at alternative/additional library search paths. Performing some clean-up on my development platform enabled me to resolve/get-past this issue.
What version of gRPC and what language are you using?
gRPC v1.62.0
C++
What operating system (Linux, Windows,...) and version?
Ubuntu 22.04.1 LTS
What runtime / compiler are you using (e.g. python version or version of gcc)
cmake version 3.22.1
gcc and g++ (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
What did you do?
Followed the instructions at 'https://grpc.io/docs/languages/cpp/quickstart/' with updated cmake options to build gRPC dependencies from source with static linking. Specifically the following commands were executed as root:
The gRPC/protobuf build and install above are successful. All good so far.
Next, I compile my application and attempt to link its libraries, but I get this linking error:
What did you expect to see?
100% successful gRPC/protobuf build and install (yes, I saw this).
100% successful build for custom Ubuntu 22.04 gRPC/protobuf application (no, I did not see this).
What did you see instead?
Unexpected linker errors in my custom Ubuntu 22 gRPC/protobuf application, specifically:
Given that I built gRPC with shared-libs off, why is libssl.so.3 needed?
Anything else we should know about your project / environment?
My custom application is being ported from Ubuntu 16 to Ubuntu 22. No issues exist on Ubuntu 16 using gPRC v1.54.0. After experiencing this linking issue with v1.54.0 on Ubuntu 22, I upgraded gRPC to v1.62.0 but the issue remains. Has anyone else encountered a similar linking issue? How did you resolve it?
I see a similar issue here (googleapis/google-cloud-cpp#9063) but the original poster in that case was compiling gRPC using packages rather than source (modules).
If I search libssl.so.3 for its symbols, I see the undefined symbol:
Any suggestions for next steps in debugging or added visibility into the issue?
The text was updated successfully, but these errors were encountered: