[grpc] fix generated pkg-config file (#19174)

gRPC uses `upb`, but normally it vendors-in the dependency. The
vendored-in version uses a single library artifact, and the generated
pkg-config file simply adds `-lupb`.  In `vcpkg` we use the `upb`
package. This has more libraries, and thus more `-lupb_*` options are
needed.  Ideally we would use a `upb.pc` file, but that does not exist.
This commit is contained in:
Carlos O'Ryan 2021-07-27 15:29:44 -07:00 committed by GitHub
parent 7dbc05515b
commit dc35791a56
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 21 additions and 2 deletions

View File

@ -0,0 +1,13 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3808016..059a16b 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -15516,7 +15516,7 @@ generate_pkgconfig(
"high performance general RPC framework"
"${gRPC_CORE_VERSION}"
"gpr openssl"
- "-lgrpc -laddress_sorting -lre2 -lupb -lcares -lz -labsl_statusor -labsl_status -labsl_raw_hash_set -labsl_hashtablez_sampler -labsl_synchronization -labsl_time -labsl_time_zone -labsl_civil_time -labsl_graphcycles_internal -labsl_symbolize -labsl_demangle_internal -labsl_malloc_internal -labsl_stacktrace -labsl_debugging_internal -labsl_exponential_biased -labsl_cord -labsl_str_format_internal -labsl_hash -labsl_bad_variant_access -labsl_bad_optional_access -labsl_strings -labsl_strings_internal -labsl_base -labsl_spinlock_wait -labsl_int128 -labsl_city -labsl_throw_delegate -labsl_raw_logging_internal -labsl_log_severity"
+ "-lgrpc -laddress_sorting -lre2 -lupb_fastdecode -lupb_json -lupb_pb -lupb_handlers -lupb_textformat -lupb_reflection -lupb -lcares -lz -labsl_statusor -labsl_status -labsl_raw_hash_set -labsl_hashtablez_sampler -labsl_synchronization -labsl_time -labsl_time_zone -labsl_civil_time -labsl_graphcycles_internal -labsl_symbolize -labsl_demangle_internal -labsl_malloc_internal -labsl_stacktrace -labsl_debugging_internal -labsl_exponential_biased -labsl_cord -labsl_str_format_internal -labsl_hash -labsl_bad_variant_access -labsl_bad_optional_access -labsl_strings -labsl_strings_internal -labsl_base -labsl_spinlock_wait -labsl_int128 -labsl_city -labsl_throw_delegate -labsl_raw_logging_internal -labsl_log_severity"
""
"grpc.pc")

View File

@ -20,6 +20,7 @@ vcpkg_from_github(
snprintf.patch
00012-fix-use-cxx17.patch
00013-build-upbdefs.patch
00014-pkgconfig-upbdefs.patch
)
if(NOT TARGET_TRIPLET STREQUAL HOST_TRIPLET)

View File

@ -1,7 +1,7 @@
{
"name": "grpc",
"version-semver": "1.37.0",
"port-version": 2,
"port-version": 3,
"description": "An RPC library and framework",
"homepage": "https://github.com/grpc/grpc",
"dependencies": [

View File

@ -2418,7 +2418,7 @@
},
"grpc": {
"baseline": "1.37.0",
"port-version": 2
"port-version": 3
},
"grppi": {
"baseline": "0.4.0",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "38a2b1bc9dd5fca170489b616d33efae6dd43158",
"version-semver": "1.37.0",
"port-version": 3
},
{
"git-tree": "9bcee29de46cc5f1edbe016d192f243f65e64a5f",
"version-semver": "1.37.0",