[grpc] grpc v1.30.2 (#12920)

This commit is contained in:
Jozef Izso 2020-08-22 10:16:03 +02:00 committed by GitHub
parent d355b3fae0
commit 78b66ad5b9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 75 additions and 65 deletions

View File

@ -1,5 +1,5 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 8561c67..84de29f 100644
index be695c20e3..dd9ffd95f9 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -150,6 +150,9 @@ if(UNIX)
@ -12,7 +12,7 @@ index 8561c67..84de29f 100644
endif()
# Use C99 standard
@@ -174,6 +177,9 @@ if(MSVC)
@@ -188,6 +191,9 @@ if(MSVC)
set(_gRPC_C_CXX_FLAGS "${_gRPC_C_CXX_FLAGS} /wd4267")
# TODO(jtattermusch): needed to build boringssl with VS2017, revisit later
set(_gRPC_C_CXX_FLAGS "${_gRPC_C_CXX_FLAGS} /wd4987 /wd4774 /wd4819 /wd4996 /wd4619")
@ -20,9 +20,9 @@ index 8561c67..84de29f 100644
+ add_definitions(-DGRPC_ARES=0)
+ endif()
endif()
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${_gRPC_C_CXX_FLAGS}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${_gRPC_C_CXX_FLAGS}")
@@ -237,6 +243,10 @@ file(MAKE_DIRECTORY ${_gRPC_PROTO_GENS_DIR})
if (MINGW)
add_definitions(-D_WIN32_WINNT=0x600)
@@ -254,6 +260,10 @@ file(MAKE_DIRECTORY ${_gRPC_PROTO_GENS_DIR})
# ``.proto`` files
#
function(protobuf_generate_grpc_cpp)
@ -33,7 +33,7 @@ index 8561c67..84de29f 100644
if(NOT ARGN)
message(SEND_ERROR "Error: PROTOBUF_GENERATE_GRPC_CPP() called without any proto files")
return()
@@ -309,6 +319,7 @@ if (gRPC_BUILD_GRPC_RUBY_PLUGIN)
@@ -326,6 +336,7 @@ if (gRPC_BUILD_GRPC_RUBY_PLUGIN)
list(APPEND _gRPC_PLUGIN_LIST grpc_ruby_plugin)
endif ()
@ -41,7 +41,7 @@ index 8561c67..84de29f 100644
add_custom_target(plugins
DEPENDS ${_gRPC_PLUGIN_LIST}
)
@@ -327,6 +338,7 @@ add_custom_target(tools_cxx
@@ -344,6 +355,7 @@ add_custom_target(tools_cxx
add_custom_target(tools
DEPENDS tools_c tools_cxx)
@ -50,10 +50,10 @@ index 8561c67..84de29f 100644
protobuf_generate_grpc_cpp(
src/proto/grpc/channelz/channelz.proto
diff --git a/src/core/lib/iomgr/resource_quota.cc b/src/core/lib/iomgr/resource_quota.cc
index 0fc0279..aaf2b09 100644
index b5df53ecdb..4099d0b63e 100644
--- a/src/core/lib/iomgr/resource_quota.cc
+++ b/src/core/lib/iomgr/resource_quota.cc
@@ -945,7 +945,7 @@ bool grpc_resource_user_alloc(grpc_resource_user* resource_user, size_t size,
@@ -943,7 +943,7 @@ bool grpc_resource_user_alloc(grpc_resource_user* resource_user, size_t size,
void grpc_resource_user_free(grpc_resource_user* resource_user, size_t size) {
gpr_mu_lock(&resource_user->mu);
grpc_resource_quota* resource_quota = resource_user->resource_quota;
@ -63,7 +63,7 @@ index 0fc0279..aaf2b09 100644
bool was_zero_or_negative = resource_user->free_pool <= 0;
resource_user->free_pool += static_cast<int64_t>(size);
diff --git a/src/core/lib/security/credentials/alts/check_gcp_environment_windows.cc b/src/core/lib/security/credentials/alts/check_gcp_environment_windows.cc
index 59432cf..fed574d 100644
index 59432cff36..fed574d5bc 100644
--- a/src/core/lib/security/credentials/alts/check_gcp_environment_windows.cc
+++ b/src/core/lib/security/credentials/alts/check_gcp_environment_windows.cc
@@ -39,6 +39,7 @@ bool check_bios_data(const char*) { return false; }

View File

@ -1,16 +1,16 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 84de29f..0c6dc0e 100644
index dd9ffd95f9..9f35ad3f6c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -165,6 +165,11 @@ set(CMAKE_CXX_EXTENSIONS OFF)
set(CMAKE_POSITION_INDEPENDENT_CODE TRUE)
@@ -180,6 +180,11 @@ if (NOT DEFINED CMAKE_POSITION_INDEPENDENT_CODE)
endif()
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules")
+
+if (gRPC_STATIC_LINKING AND NOT _gRPC_PLATFORM_WINDOWS)
+ # Force to static link
+ set(CMAKE_EXE_LINKER_FLAGS "-Bstatic")
+endif()
+
if(MSVC)
include(cmake/msvc_static_runtime.cmake)
add_definitions(-D_WIN32_WINNT=0x600 -D_SCL_SECURE_NO_WARNINGS -D_CRT_SECURE_NO_WARNINGS -D_WINSOCK_DEPRECATED_NO_WARNINGS)

View File

@ -1,11 +1,11 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index c4057b3..a6a0f23 100644
index 9f35ad3f6c..bdadbc9867 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -220,7 +220,7 @@ elseif(UNIX)
@@ -246,7 +246,7 @@ elseif(UNIX)
endif()
if(WIN32 AND MSVC)
if(WIN32)
- set(_gRPC_BASELIB_LIBRARIES wsock32 ws2_32 crypt32)
+ set(_gRPC_BASELIB_LIBRARIES wsock32 ws2_32 crypt32 gdi32)
endif()

View File

@ -1,5 +1,5 @@
diff --git a/src/core/lib/slice/slice.cc b/src/core/lib/slice/slice.cc
index c0e2164..331e54c 100644
index c0e21648f7..331e54c45a 100644
--- a/src/core/lib/slice/slice.cc
+++ b/src/core/lib/slice/slice.cc
@@ -214,6 +214,7 @@ grpc_slice grpc_slice_from_moved_buffer(grpc_core::UniquePtr<char> p,
@ -11,10 +11,10 @@ index c0e2164..331e54c 100644
slice.refcount = nullptr;
slice.data.inlined.length = len;
diff --git a/src/core/lib/surface/server.cc b/src/core/lib/surface/server.cc
index 998eb6d..a6e26d3 100644
index d22b52ad6f..203112e87b 100644
--- a/src/core/lib/surface/server.cc
+++ b/src/core/lib/surface/server.cc
@@ -1095,7 +1095,7 @@ grpc_call_error queue_call_request(grpc_server* server, size_t cq_idx,
@@ -1230,7 +1230,7 @@ grpc_call_error queue_call_request(grpc_server* server, size_t cq_idx,
GRPC_ERROR_CREATE_FROM_STATIC_STRING("Server Shutdown"));
return GRPC_CALL_OK;
}

View File

@ -1,5 +1,5 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5ec669e..f71a212 100644
index bdadbc9867..f2b1dd774a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -81,6 +81,9 @@ set_property(CACHE gRPC_SSL_PROVIDER PROPERTY STRINGS "module" "package")
@ -12,7 +12,7 @@ index 5ec669e..f71a212 100644
set(gRPC_PROTOBUF_PACKAGE_TYPE "" CACHE STRING "Algorithm for searching protobuf package")
set_property(CACHE gRPC_PROTOBUF_PACKAGE_TYPE PROPERTY STRINGS "CONFIG" "MODULE")
@@ -1765,7 +1768,6 @@ target_link_libraries(grpc
@@ -1791,7 +1794,6 @@ target_link_libraries(grpc
${_gRPC_ALLTARGETS_LIBRARIES}
gpr
address_sorting
@ -20,7 +20,7 @@ index 5ec669e..f71a212 100644
absl::optional
absl::strings
absl::inlined_vector
@@ -1844,7 +1846,6 @@ target_link_libraries(grpc_csharp_ext
@@ -1870,7 +1872,6 @@ target_link_libraries(grpc_csharp_ext
grpc
gpr
address_sorting
@ -28,7 +28,7 @@ index 5ec669e..f71a212 100644
)
@@ -2351,7 +2352,6 @@ target_link_libraries(grpc_unsecure
@@ -2386,7 +2387,6 @@ target_link_libraries(grpc_unsecure
${_gRPC_ALLTARGETS_LIBRARIES}
gpr
address_sorting
@ -36,7 +36,7 @@ index 5ec669e..f71a212 100644
absl::optional
absl::strings
absl::inlined_vector
@@ -2545,7 +2545,6 @@ target_link_libraries(grpc++
@@ -2580,7 +2580,6 @@ target_link_libraries(grpc++
grpc
gpr
address_sorting
@ -44,7 +44,7 @@ index 5ec669e..f71a212 100644
)
foreach(_hdr
@@ -2821,7 +2820,6 @@ target_link_libraries(grpc++_alts
@@ -2856,7 +2855,6 @@ target_link_libraries(grpc++_alts
grpc
gpr
address_sorting
@ -52,7 +52,7 @@ index 5ec669e..f71a212 100644
)
foreach(_hdr
@@ -2889,7 +2887,6 @@ target_link_libraries(grpc++_error_details
@@ -2924,7 +2922,6 @@ target_link_libraries(grpc++_error_details
grpc
gpr
address_sorting
@ -60,7 +60,7 @@ index 5ec669e..f71a212 100644
)
foreach(_hdr
@@ -2962,7 +2959,6 @@ target_link_libraries(grpc++_reflection
@@ -2997,7 +2994,6 @@ target_link_libraries(grpc++_reflection
grpc
gpr
address_sorting
@ -68,7 +68,7 @@ index 5ec669e..f71a212 100644
)
foreach(_hdr
@@ -3239,7 +3235,6 @@ target_link_libraries(grpc++_unsecure
@@ -3274,7 +3270,6 @@ target_link_libraries(grpc++_unsecure
grpc_unsecure
gpr
address_sorting
@ -76,7 +76,7 @@ index 5ec669e..f71a212 100644
)
foreach(_hdr
@@ -3586,7 +3581,6 @@ target_link_libraries(grpcpp_channelz
@@ -3621,7 +3616,6 @@ target_link_libraries(grpcpp_channelz
grpc
gpr
address_sorting
@ -84,7 +84,7 @@ index 5ec669e..f71a212 100644
)
foreach(_hdr
@@ -3613,6 +3607,7 @@ endif()
@@ -3648,6 +3642,7 @@ endif()
endif()
@ -92,7 +92,7 @@ index 5ec669e..f71a212 100644
add_library(upb
third_party/upb/upb/decode.c
third_party/upb/upb/encode.c
@@ -3662,7 +3657,7 @@ if(gRPC_INSTALL)
@@ -3697,7 +3692,7 @@ if(gRPC_INSTALL)
ARCHIVE DESTINATION ${gRPC_INSTALL_LIBDIR}
)
endif()
@ -102,7 +102,7 @@ index 5ec669e..f71a212 100644
add_executable(check_epollexclusive
diff --git a/cmake/gRPCConfig.cmake.in b/cmake/gRPCConfig.cmake.in
index 5bfa73c..db0865e 100644
index 5bfa73c291..db0865ee57 100644
--- a/cmake/gRPCConfig.cmake.in
+++ b/cmake/gRPCConfig.cmake.in
@@ -7,6 +7,7 @@ list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_LIST_DIR}/modules)
@ -114,7 +114,7 @@ index 5bfa73c..db0865e 100644
# Targets
include(${CMAKE_CURRENT_LIST_DIR}/gRPCTargets.cmake)
diff --git a/cmake/upb.cmake b/cmake/upb.cmake
index 2c0ab84..07dd613 100644
index 2c0ab84e67..07dd613a78 100644
--- a/cmake/upb.cmake
+++ b/cmake/upb.cmake
@@ -12,9 +12,18 @@

View File

@ -1,8 +1,8 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index f71a212..77cf3de 100644
index f2b1dd774a..e9adc1ae27 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1771,6 +1771,8 @@ target_link_libraries(grpc
@@ -1797,6 +1797,8 @@ target_link_libraries(grpc
absl::optional
absl::strings
absl::inlined_vector
@ -11,7 +11,7 @@ index f71a212..77cf3de 100644
)
if(_gRPC_PLATFORM_IOS OR _gRPC_PLATFORM_MAC)
target_link_libraries(grpc "-framework CoreFoundation")
@@ -2355,6 +2357,8 @@ target_link_libraries(grpc_unsecure
@@ -2390,6 +2392,8 @@ target_link_libraries(grpc_unsecure
absl::optional
absl::strings
absl::inlined_vector
@ -21,7 +21,7 @@ index f71a212..77cf3de 100644
if(_gRPC_PLATFORM_IOS OR _gRPC_PLATFORM_MAC)
target_link_libraries(grpc_unsecure "-framework CoreFoundation")
diff --git a/cmake/abseil-cpp.cmake b/cmake/abseil-cpp.cmake
index 078d495..b6f50bd 100644
index 078d495417..b6f50bd14c 100644
--- a/cmake/abseil-cpp.cmake
+++ b/cmake/abseil-cpp.cmake
@@ -37,4 +37,7 @@ elseif(gRPC_ABSL_PROVIDER STREQUAL "package")

View File

@ -1,8 +1,8 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 77cf3de..8bceae6 100644
diff --git a/CMakeLists.txt b/CMakeLists.txt
index e9adc1ae27..d1f5a3f93e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1812,10 +1812,14 @@ endif()
@@ -1838,10 +1838,14 @@ endif()
if(gRPC_BUILD_CSHARP_EXT)
@ -18,11 +18,11 @@ index 77cf3de..8bceae6 100644
set_target_properties(grpc_csharp_ext PROPERTIES
VERSION ${gRPC_CORE_VERSION}
SOVERSION ${gRPC_CORE_SOVERSION}
@@ -1829,6 +1833,12 @@ if(WIN32 AND MSVC)
@@ -1855,6 +1859,12 @@ if(WIN32 AND MSVC)
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/grpc_csharp_ext.pdb
DESTINATION ${gRPC_INSTALL_LIBDIR} OPTIONAL
)
+
+
+ install(TARGETS grpc_csharp_ext
+ RUNTIME DESTINATION ${gRPC_INSTALL_BINDIR}
+ LIBRARY DESTINATION ${gRPC_INSTALL_LIBDIR}

View File

@ -1,6 +1,5 @@
Source: grpc
Version: 1.29.1
Port-Version: 1
Version: 1.30.2
Build-Depends: zlib, openssl, protobuf, c-ares (!uwp), upb, abseil
Homepage: https://github.com/grpc/grpc
Description: An RPC library and framework

View File

@ -5,8 +5,8 @@ endif()
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO grpc/grpc
REF 7d89dbb311f049b43bda7bbf6f7d7bf1b4c24419 #v1.29.1
SHA512 403fa5e3f012786bb17ca32c760b6dfb22c5a5cfb473ba7fad657e26ab3986eb0203f7cbb501a8647fd5ef2571e5f4ee08c2c97d1dfda18ec5ab6a92c9fc3263
REF de6defa6fff08de20e36f9168f5b277e292daf46 #v1.30.2
SHA512 e77ba43fdce5c2257abb957908b94f3132b191d930c3c1ab1350bdf6d859aaf76f0afb067f4af6abb3c8428de20dd47596f316262eb5d8569ebb2ffa13b50054
HEAD_REF master
PATCHES
00001-fix-uwp.patch
@ -57,7 +57,7 @@ vcpkg_configure_cmake(
-DgRPC_GFLAGS_PROVIDER=none
-DgRPC_BENCHMARK_PROVIDER=none
-DgRPC_INSTALL_CSHARP_EXT=OFF
-DgRPC_INSTALL_BINDIR:STRING=tools/grpc
-DgRPC_INSTALL_BINDIR:STRING=bin
-DgRPC_INSTALL_LIBDIR:STRING=lib
-DgRPC_INSTALL_INCLUDEDIR:STRING=include
-DgRPC_INSTALL_CMAKEDIR:STRING=share/gRPC
@ -68,10 +68,21 @@ vcpkg_install_cmake(ADD_BIN_TO_PATH)
vcpkg_fixup_cmake_targets(CONFIG_PATH share/gRPC TARGET_PATH share/gRPC)
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/grpc RENAME copyright)
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
vcpkg_copy_tool_dependencies(${CURRENT_PACKAGES_DIR}/tools/grpc)
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/tools")
if (gRPC_BUILD_CODEGEN)
vcpkg_copy_tools(
AUTO_CLEAN
TOOL_NAMES
grpc_php_plugin
grpc_python_plugin
grpc_node_plugin
grpc_objective_c_plugin
grpc_csharp_plugin
grpc_cpp_plugin
grpc_ruby_plugin
)
endif()
# Ignore the C# extension DLL in bin/
SET(VCPKG_POLICY_EMPTY_PACKAGE enabled)

View File

@ -1,12 +1,12 @@
diff --git a/src/core/tsi/alts/crypt/aes_gcm.cc b/src/core/tsi/alts/crypt/aes_gcm.cc
index c638ce7..3dc3b2e 100644
--- a/src/core/tsi/alts/crypt/aes_gcm.cc
+++ b/src/core/tsi/alts/crypt/aes_gcm.cc
@@ -28,6 +28,7 @@
#include <openssl/evp.h>
#include <openssl/hmac.h>
#include <string.h>
+#include <cstdio>
#include <grpc/support/alloc.h>
diff --git a/src/core/tsi/alts/crypt/aes_gcm.cc b/src/core/tsi/alts/crypt/aes_gcm.cc
index 02b1ac4492..191f462277 100644
--- a/src/core/tsi/alts/crypt/aes_gcm.cc
+++ b/src/core/tsi/alts/crypt/aes_gcm.cc
@@ -26,6 +26,7 @@
#include <openssl/evp.h>
#include <openssl/hmac.h>
#include <string.h>
+#include <cstdio>
#include <grpc/support/alloc.h>