libgrpc: Update to 1.44.0
This commit is contained in:
parent
5cef28de6c
commit
fb660e016f
@ -2,15 +2,15 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index f6de091a0c..d21e04a24d 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -205,7 +205,7 @@ if(_gRPC_PLATFORM_MAC OR _gRPC_PLATFORM_IOS)
|
||||
elseif(_gRPC_PLATFORM_ANDROID)
|
||||
set(_gRPC_ALLTARGETS_LIBRARIES ${CMAKE_DL_LIBS} m)
|
||||
elseif(UNIX)
|
||||
- set(_gRPC_ALLTARGETS_LIBRARIES ${CMAKE_DL_LIBS} rt m pthread)
|
||||
+ set(_gRPC_ALLTARGETS_LIBRARIES ${CMAKE_DL_LIBS} m)
|
||||
@@ -301,7 +301,7 @@ if(UNIX)
|
||||
find_package(Threads)
|
||||
set(_gRPC_ALLTARGETS_LIBRARIES ${CMAKE_DL_LIBS} m Threads::Threads)
|
||||
if(_gRPC_PLATFORM_LINUX OR _gRPC_PLATFORM_POSIX)
|
||||
- set(_gRPC_ALLTARGETS_LIBRARIES ${_gRPC_ALLTARGETS_LIBRARIES} rt)
|
||||
+ set(_gRPC_ALLTARGETS_LIBRARIES ${_gRPC_ALLTARGETS_LIBRARIES})
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(WIN32 AND MSVC)
|
||||
@@ -1432,12 +1432,6 @@ target_link_libraries(gpr
|
||||
absl::strings
|
||||
absl::optional
|
||||
|
@ -3,9 +3,8 @@ TERMUX_PKG_DESCRIPTION="High performance, open source, general RPC framework tha
|
||||
TERMUX_PKG_LICENSE="Apache-2.0"
|
||||
TERMUX_PKG_MAINTAINER="@termux"
|
||||
TERMUX_PKG_SRCURL=https://github.com/grpc/grpc.git
|
||||
TERMUX_PKG_VERSION=1.38.1
|
||||
TERMUX_PKG_REVISION=1
|
||||
TERMUX_PKG_DEPENDS="libc++, openssl, protobuf, c-ares, zlib"
|
||||
TERMUX_PKG_VERSION=1.44.0
|
||||
TERMUX_PKG_DEPENDS="ca-certificates, libc++, libre2, openssl, protobuf, c-ares, zlib"
|
||||
TERMUX_PKG_BREAKS="libgrpc-dev"
|
||||
TERMUX_PKG_REPLACES="libgrpc-dev"
|
||||
TERMUX_PKG_BUILD_DEPENDS="gflags, gflags-static, libprotobuf"
|
||||
@ -18,6 +17,7 @@ TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
|
||||
-DgRPC_CARES_PROVIDER=package
|
||||
-DgRPC_PROTOBUF_PROVIDER=package
|
||||
-DgRPC_SSL_PROVIDER=package
|
||||
-DgRPC_RE2_PROVIDER=package
|
||||
-DgRPC_ZLIB_PROVIDER=package
|
||||
-DgRPC_GFLAGS_PROVIDER=package
|
||||
-DRUN_HAVE_POSIX_REGEX=0
|
||||
@ -51,6 +51,7 @@ termux_step_host_build() {
|
||||
}
|
||||
|
||||
termux_step_pre_configure() {
|
||||
export PATH=$TERMUX_PKG_HOSTBUILD_DIR/bin:$PATH
|
||||
sed "s|@PATH_TO_PLUGIN@|$TERMUX_PKG_HOSTBUILD_DIR/bin/grpc_cpp_plugin|g" \
|
||||
$TERMUX_PKG_BUILDER_DIR/CMakeLists.txt.diff \
|
||||
| patch -p1
|
||||
|
11
packages/libgrpc/src-core-lib-gpr-tmpfile_posix.cc.patch
Normal file
11
packages/libgrpc/src-core-lib-gpr-tmpfile_posix.cc.patch
Normal file
@ -0,0 +1,11 @@
|
||||
--- a/src/core/lib/gpr/tmpfile_posix.cc
|
||||
+++ b/src/core/lib/gpr/tmpfile_posix.cc
|
||||
@@ -39,7 +39,7 @@
|
||||
|
||||
if (tmp_filename != nullptr) *tmp_filename = nullptr;
|
||||
|
||||
- gpr_asprintf(&filename_template, "/tmp/%s_XXXXXX", prefix);
|
||||
+ gpr_asprintf(&filename_template, "@TERMUX_PREFIX@/tmp/%s_XXXXXX", prefix);
|
||||
GPR_ASSERT(filename_template != nullptr);
|
||||
|
||||
fd = mkstemp(filename_template);
|
@ -1,12 +0,0 @@
|
||||
diff -u -r ../cache/checkout-1.12.0/src/core/lib/gpr/wrap_memcpy.cc ./src/core/lib/gpr/wrap_memcpy.cc
|
||||
--- ../cache/checkout-1.12.0/src/core/lib/gpr/wrap_memcpy.cc 2018-05-22 13:07:29.307092222 +0000
|
||||
+++ ./src/core/lib/gpr/wrap_memcpy.cc 2018-05-23 22:21:40.602239126 +0000
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
extern "C" {
|
||||
#ifdef __linux__
|
||||
-#if defined(__x86_64__) && !defined(GPR_MUSL_LIBC_COMPAT)
|
||||
+#if defined(__x86_64__) && !defined(GPR_MUSL_LIBC_COMPAT) && !defined(__ANDROID__)
|
||||
__asm__(".symver memcpy,memcpy@GLIBC_2.2.5");
|
||||
void* __wrap_memcpy(void* destination, const void* source, size_t num) {
|
||||
return memcpy(destination, source, num);
|
@ -0,0 +1,17 @@
|
||||
--- a/src/core/lib/security/security_connector/load_system_roots_linux.cc
|
||||
+++ b/src/core/lib/security/security_connector/load_system_roots_linux.cc
|
||||
@@ -52,12 +52,9 @@
|
||||
namespace {
|
||||
|
||||
const char* kLinuxCertFiles[] = {
|
||||
- "/etc/ssl/certs/ca-certificates.crt", "/etc/pki/tls/certs/ca-bundle.crt",
|
||||
- "/etc/ssl/ca-bundle.pem", "/etc/pki/tls/cacert.pem",
|
||||
- "/etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem"};
|
||||
+ "@TERMUX_PREFIX@/etc/tls/cert.pem"};
|
||||
const char* kLinuxCertDirectories[] = {
|
||||
- "/etc/ssl/certs", "/system/etc/security/cacerts", "/usr/local/share/certs",
|
||||
- "/etc/pki/tls/certs", "/etc/openssl/certs"};
|
||||
+ "@TERMUX_PREFIX@/etc/tls/certs"};
|
||||
|
||||
grpc_slice GetSystemRootCerts() {
|
||||
grpc_slice valid_bundle_slice = grpc_empty_slice();
|
@ -0,0 +1,14 @@
|
||||
--- a/src/core/lib/security/security_connector/ssl_utils.cc
|
||||
+++ b/src/core/lib/security/security_connector/ssl_utils.cc
|
||||
@@ -45,9 +45,9 @@
|
||||
static const char* installed_roots_path = GRPC_ROOT_PEM_PATH;
|
||||
#elif defined(INSTALL_PREFIX)
|
||||
static const char* installed_roots_path =
|
||||
- INSTALL_PREFIX "/usr/share/grpc/roots.pem";
|
||||
+ INSTALL_PREFIX "/share/grpc/roots.pem";
|
||||
#else
|
||||
-static const char* installed_roots_path = "/usr/share/grpc/roots.pem";
|
||||
+static const char* installed_roots_path = "@TERMUX_PREFIX@/share/grpc/roots.pem";
|
||||
#endif
|
||||
|
||||
#ifndef TSI_OPENSSL_ALPN_SUPPORT
|
Loading…
Reference in New Issue
Block a user