mirror of
https://github.com/yann64/haikuports.git
synced 2026-04-22 11:40:06 +02:00
grpc: bump version
This commit is contained in:
@@ -8,7 +8,7 @@ COPYRIGHT="2015-2022 The gRPC Authors"
|
||||
LICENSE="Apache v2"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/grpc/grpc/archive/refs/tags/v$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="64b791c3dad387230f8b46cbd0c474b6ae751f7f805d05cb3bae36ac0ff2a7e7"
|
||||
CHECKSUM_SHA256="b55696fb249669744de3e71acc54a9382bea0dce7cd5ba379b356b12b82d4229"
|
||||
SOURCE_FILENAME="grpc-$portVersion.tar.gz"
|
||||
gtestCommit="0e402173c97aea7a00749e825b194bfede4f2e45"
|
||||
SOURCE_URI_2="https://github.com/google/googletest/archive/$gtestCommit/googletest-$gtestCommit.tar.gz"
|
||||
@@ -19,9 +19,9 @@ PATCHES="grpc-$portVersion.patchset"
|
||||
ARCHITECTURES="all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
libVersion="21.0.0"
|
||||
libVersion="29.0.0"
|
||||
libVersionCompat="$libVersion compat >= ${libVersion%%.*}"
|
||||
libCppVersion="1.46.2"
|
||||
libCppVersion="1.51.1"
|
||||
libCppVersionCompat="$libCppVersion compat >= ${libCppVersion%%.*}"
|
||||
|
||||
PROVIDES="
|
||||
@@ -53,6 +53,7 @@ REQUIRES="
|
||||
lib:libprotoc$secondaryArchSuffix
|
||||
lib:libre2$secondaryArchSuffix
|
||||
lib:libssl$secondaryArchSuffix
|
||||
lib:libstdc++$secondaryArchSuffix
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
@@ -86,11 +87,11 @@ REQUIRES_devel="
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libabsl_cord$secondaryArchSuffix >= 2111.0.0
|
||||
devel:libabsl_status$secondaryArchSuffix >= 2111.0.0
|
||||
devel:libabsl_strings$secondaryArchSuffix >= 2111.0.0
|
||||
devel:libabsl_synchronization$secondaryArchSuffix >= 2111.0.0
|
||||
devel:libabsl_time$secondaryArchSuffix >= 2111.0.0
|
||||
devel:libabsl_cord$secondaryArchSuffix >= 2206.0.0
|
||||
devel:libabsl_status$secondaryArchSuffix >= 2206.0.0
|
||||
devel:libabsl_strings$secondaryArchSuffix >= 2206.0.0
|
||||
devel:libabsl_synchronization$secondaryArchSuffix >= 2206.0.0
|
||||
devel:libabsl_time$secondaryArchSuffix >= 2206.0.0
|
||||
devel:libbenchmark$secondaryArchSuffix
|
||||
devel:libcares$secondaryArchSuffix
|
||||
devel:libprotobuf$secondaryArchSuffix >= 31
|
||||
@@ -120,6 +121,7 @@ BUILD()
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_INSTALL_PREFIX=$prefix \
|
||||
-DCMAKE_CXX_STANDARD=17 \
|
||||
-DCMAKE_CXX_FLAGS="-D_BSD_SOURCE" \
|
||||
-DCMAKE_POSITION_INDEPENDENT_CODE=NO \
|
||||
-DBUILD_SHARED_LIBS=ON \
|
||||
-DgRPC_INSTALL_BINDIR=$relativeBinDir \
|
||||
@@ -1,109 +1,27 @@
|
||||
From bedffa769cda6c4da7e739117a8b0546320e0f11 Mon Sep 17 00:00:00 2001
|
||||
From 1e4b98d4901ef648e76f63441e2e874d996aba9a Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Sat, 16 Oct 2021 21:33:26 +0200
|
||||
Subject: Haiku: port
|
||||
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 5291379..69963d3 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -295,7 +295,7 @@ if (gRPC_XDS_USER_AGENT_IS_CSHARP)
|
||||
add_definitions("-DGRPC_XDS_USER_AGENT_NAME_SUFFIX=\"csharp\"" "-DGRPC_XDS_USER_AGENT_VERSION_SUFFIX=\"2.46.2\"")
|
||||
endif()
|
||||
|
||||
-if(UNIX)
|
||||
+if(UNIX AND NOT HAIKU)
|
||||
# -pthread does more than -lpthread
|
||||
set(THREADS_PREFER_PTHREAD_FLAG ON)
|
||||
find_package(Threads)
|
||||
diff --git a/include/grpc/event_engine/port.h b/include/grpc/event_engine/port.h
|
||||
index 9424586..5ee5327 100644
|
||||
index 3055a66..b1ba91d 100644
|
||||
--- a/include/grpc/event_engine/port.h
|
||||
+++ b/include/grpc/event_engine/port.h
|
||||
@@ -20,7 +20,7 @@
|
||||
#if defined(GPR_ANDROID) || defined(GPR_LINUX) || defined(GPR_APPLE) || \
|
||||
defined(GPR_FREEBSD) || defined(GPR_OPENBSD) || defined(GPR_SOLARIS) || \
|
||||
defined(GPR_AIX) || defined(GPR_NACL) || defined(GPR_FUCHSIA) || \
|
||||
- defined(GRPC_POSIX_SOCKET)
|
||||
+ defined(GPR_HAIKU) || defined(GRPC_POSIX_SOCKET)
|
||||
- defined(GRPC_POSIX_SOCKET) || defined(GPR_NETBSD)
|
||||
+ defined(GRPC_POSIX_SOCKET) || defined(GPR_NETBSD) || defined(GPR_HAIKU)
|
||||
#define GRPC_EVENT_ENGINE_POSIX
|
||||
#include <arpa/inet.h>
|
||||
#include <netdb.h>
|
||||
diff --git a/include/grpc/impl/codegen/port_platform.h b/include/grpc/impl/codegen/port_platform.h
|
||||
index 3227f51..4e2a225 100644
|
||||
--- a/include/grpc/impl/codegen/port_platform.h
|
||||
+++ b/include/grpc/impl/codegen/port_platform.h
|
||||
@@ -404,6 +404,30 @@
|
||||
#define GPR_HAS_PTHREAD_H 1
|
||||
#define GPR_GETPID_IN_UNISTD_H 1
|
||||
#define GRPC_ROOT_PEM_PATH "/config/ssl/cert.pem"
|
||||
+#elif defined(__HAIKU__)
|
||||
+#define GPR_PLATFORM_STRING "haiku"
|
||||
+#ifndef _BSD_SOURCE
|
||||
+#define _BSD_SOURCE
|
||||
+#endif
|
||||
+#define GPR_HAIKU 1
|
||||
+#define GPR_CPU_POSIX 1
|
||||
+#define GPR_GCC_ATOMIC 1
|
||||
+#define GPR_POSIX_LOG 1
|
||||
+#define GPR_POSIX_ENV 1
|
||||
+#define GPR_POSIX_TMPFILE 1
|
||||
+#define GPR_POSIX_STAT 1
|
||||
+#define GPR_POSIX_STRING 1
|
||||
+#define GPR_POSIX_SUBPROCESS 1
|
||||
+#define GPR_POSIX_SYNC 1
|
||||
+#define GPR_POSIX_TIME 1
|
||||
+#define GPR_HAS_PTHREAD_H 1
|
||||
+#define GPR_GETPID_IN_UNISTD_H 1
|
||||
+#define GPR_SUPPORT_CHANNELS_FROM_FD 1
|
||||
+#ifdef _LP64
|
||||
+#define GPR_ARCH_64 1
|
||||
+#else /* _LP64 */
|
||||
+#define GPR_ARCH_32 1
|
||||
+#endif /* _LP64 */
|
||||
#else
|
||||
#error "Could not auto-detect platform"
|
||||
#endif
|
||||
diff --git a/src/core/lib/gpr/tls.h b/src/core/lib/gpr/tls.h
|
||||
index 7ea6598..692180c 100644
|
||||
--- a/src/core/lib/gpr/tls.h
|
||||
+++ b/src/core/lib/gpr/tls.h
|
||||
@@ -151,7 +151,7 @@ class PthreadTlsImpl : TlsTypeConstrainer<T> {
|
||||
#else
|
||||
|
||||
#define GPR_THREAD_LOCAL(type) \
|
||||
- thread_local typename grpc_core::TlsTypeConstrainer<type>::Type
|
||||
+ __thread typename grpc_core::TlsTypeConstrainer<type>::Type
|
||||
|
||||
#endif
|
||||
|
||||
diff --git a/src/core/lib/iomgr/port.h b/src/core/lib/iomgr/port.h
|
||||
index 8762791..82eb34e 100644
|
||||
--- a/src/core/lib/iomgr/port.h
|
||||
+++ b/src/core/lib/iomgr/port.h
|
||||
@@ -177,6 +177,16 @@
|
||||
// TODO(rudominer) Check this does something we want.
|
||||
#define GRPC_POSIX_SOCKETUTILS 1
|
||||
#define GRPC_TIMER_USE_GENERIC 1
|
||||
+#elif defined(GPR_HAIKU)
|
||||
+#define GRPC_HAVE_ARPA_NAMESER 1
|
||||
+#define GRPC_HAVE_IFADDRS 1
|
||||
+#define GRPC_HAVE_IPV6_RECVPKTINFO 1
|
||||
+#define GRPC_HAVE_UNIX_SOCKET 1
|
||||
+#define GRPC_POSIX_FORK 1
|
||||
+#define GRPC_POSIX_NO_SPECIAL_WAKEUP_FD 1
|
||||
+#define GRPC_POSIX_SOCKET 1
|
||||
+#define GRPC_POSIX_SOCKETUTILS 1
|
||||
+#define GRPC_POSIX_WAKEUP_FD 1
|
||||
#elif !defined(GPR_NO_AUTODETECT_PLATFORM)
|
||||
#error "Platform not recognized"
|
||||
#endif
|
||||
--
|
||||
2.30.2
|
||||
2.37.3
|
||||
|
||||
|
||||
From 590791b8346bdf078b3f2686e13060e41bbc7625 Mon Sep 17 00:00:00 2001
|
||||
From d8f7301ff9813891b3a20ebe980f07881ba1cdef Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Fri, 22 Oct 2021 14:54:43 +0200
|
||||
Subject: patch needed to help build and run tests on Haiku
|
||||
@@ -123,10 +41,10 @@ index 2174c00..99dd74e 100755
|
||||
return 'posix'
|
||||
|
||||
diff --git a/tools/run_tests/run_tests.py b/tools/run_tests/run_tests.py
|
||||
index bf1b8d0..9fce0d4 100755
|
||||
index 0327aa1..32d5a44 100755
|
||||
--- a/tools/run_tests/run_tests.py
|
||||
+++ b/tools/run_tests/run_tests.py
|
||||
@@ -303,6 +303,19 @@ class CLanguage(object):
|
||||
@@ -297,6 +297,19 @@ class CLanguage(object):
|
||||
# see https://github.com/grpc/grpc/blob/b5b8578b3f8b4a9ce61ed6677e19d546e43c5c68/tools/run_tests/artifacts/artifact_targets.py#L253
|
||||
self._cmake_configure_extra_args.append('-DOPENSSL_NO_ASM=ON')
|
||||
|
||||
@@ -147,10 +65,10 @@ index bf1b8d0..9fce0d4 100755
|
||||
out = []
|
||||
binaries = get_c_tests(self.args.travis, self.test_lang)
|
||||
--
|
||||
2.30.2
|
||||
2.37.3
|
||||
|
||||
|
||||
From 7dc62c4b29b7d4b40b22b0dd42703c825e206d69 Mon Sep 17 00:00:00 2001
|
||||
From 7c690075f4c36a035d7bd955ea7f56282e65abab Mon Sep 17 00:00:00 2001
|
||||
From: Jerome Duval <jerome.duval@gmail.com>
|
||||
Date: Fri, 26 Nov 2021 20:17:18 +0100
|
||||
Subject: protobuf minimum version 1.16.0
|
||||
@@ -170,5 +88,5 @@ index f23f65d..83fad47 100644
|
||||
# {Protobuf,PROTOBUF}_FOUND is defined based on find_package type ("MODULE" vs "CONFIG").
|
||||
# For "MODULE", the case has also changed between cmake 3.5 and 3.6.
|
||||
--
|
||||
2.30.2
|
||||
2.37.3
|
||||
|
||||
Reference in New Issue
Block a user