diff --git a/devel/py-grpcio/Makefile b/devel/py-grpcio/Makefile index 15a6fb43573c..b3917063242b 100644 --- a/devel/py-grpcio/Makefile +++ b/devel/py-grpcio/Makefile @@ -1,31 +1,31 @@ PORTNAME= grpcio -PORTVERSION= 1.57.0 +PORTVERSION= 1.58.0 CATEGORIES= devel python MASTER_SITES= PYPI PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} MAINTAINER= vanilla@FreeBSD.org COMMENT= HTTP/2-based RPC framework WWW= https://pypi.org/project/grpcio/ LICENSE= APACHE20 RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}protobuf>=3:devel/py-protobuf@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}six>1:devel/py-six@${PY_FLAVOR} LIB_DEPENDS= libcares.so:dns/c-ares USES= compiler:c++11-lib localbase:ldflags python ssl USE_PYTHON= autoplist cython distutils MAKE_ENV+= GRPC_PYTHON_BUILD_SYSTEM_CARES=true \ GRPC_PYTHON_BUILD_SYSTEM_OPENSSL=true \ GRPC_PYTHON_BUILD_SYSTEM_ZLIB=true LDFLAGS+= -lcares post-patch: @${RM} ${WRKSRC}/src/python/grpcio/grpc/_cython/cygrpc.cpp post-install: ${STRIP_CMD} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/grpc/_cython/cygrpc*.so ${REINPLACE_CMD} -e 's|^.*so$$|${PYTHONPREFIX_SITELIBDIR}/grpc/_cython/cygrpc${PYTHON_EXT_SUFFIX}.so|' ${_PYTHONPKGLIST} .include diff --git a/devel/py-grpcio/distinfo b/devel/py-grpcio/distinfo index bc0509ce86f1..5cc057cd744b 100644 --- a/devel/py-grpcio/distinfo +++ b/devel/py-grpcio/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1691904681 -SHA256 (grpcio-1.57.0.tar.gz) = 4b089f7ad1eb00a104078bab8015b0ed0ebcb3b589e527ab009c53893fd4e613 -SIZE (grpcio-1.57.0.tar.gz) = 24737546 +TIMESTAMP = 1694182572 +SHA256 (grpcio-1.58.0.tar.gz) = 532410c51ccd851b706d1fbc00a87be0f5312bd6f8e5dbf89d4e99c7f79d7499 +SIZE (grpcio-1.58.0.tar.gz) = 24784339 diff --git a/devel/py-grpcio/files/patch-third__party_abseil-cpp_absl_base_internal_sysinfo.cc b/devel/py-grpcio/files/patch-third__party_abseil-cpp_absl_base_internal_sysinfo.cc new file mode 100644 index 000000000000..1eb995321143 --- /dev/null +++ b/devel/py-grpcio/files/patch-third__party_abseil-cpp_absl_base_internal_sysinfo.cc @@ -0,0 +1,33 @@ +--- third_party/abseil-cpp/absl/base/internal/sysinfo.cc.orig 2023-09-08 14:23:50 UTC ++++ third_party/abseil-cpp/absl/base/internal/sysinfo.cc +@@ -34,6 +34,10 @@ + #include + #endif + ++#ifdef __FreeBSD__ ++#include ++#endif ++ + #if defined(__myriad2__) + #include + #endif +@@ -421,14 +425,18 @@ pid_t GetTID() { + return tid; + } + +-#elif defined(__APPLE__) ++#elif defined(__APPLE__) || defined(__FreeBSD__) + + pid_t GetTID() { + uint64_t tid; + // `nullptr` here implies this thread. This only fails if the specified + // thread is invalid or the pointer-to-tid is null, so we needn't worry about + // it. ++#if __FreeBSD__ ++ tid = pthread_getthreadid_np(); ++#else + pthread_threadid_np(nullptr, &tid); ++#endif + return static_cast(tid); + } + diff --git a/devel/py-grpcio/files/patch-third__party_abseil-cpp_absl_time_internal_cctz_src_time__zone__format.cc b/devel/py-grpcio/files/patch-third__party_abseil-cpp_absl_time_internal_cctz_src_time__zone__format.cc new file mode 100644 index 000000000000..e104a9b365cd --- /dev/null +++ b/devel/py-grpcio/files/patch-third__party_abseil-cpp_absl_time_internal_cctz_src_time__zone__format.cc @@ -0,0 +1,11 @@ +--- third_party/abseil-cpp/absl/time/internal/cctz/src/time_zone_format.cc.orig 2023-09-08 14:26:05 UTC ++++ third_party/abseil-cpp/absl/time/internal/cctz/src/time_zone_format.cc +@@ -19,7 +19,7 @@ + #endif + + #if defined(HAS_STRPTIME) && HAS_STRPTIME +-#if !defined(_XOPEN_SOURCE) && !defined(__OpenBSD__) ++#if !defined(_XOPEN_SOURCE) && !defined(__OpenBSD__) && !defined(__FreeBSD__) + #define _XOPEN_SOURCE 500 // Exposes definitions for SUSv2 (UNIX 98). + #endif + #endif diff --git a/devel/py-grpcio/files/patch-third__party_boringssl-with-bazel_src_include_openssl_base.h b/devel/py-grpcio/files/patch-third__party_boringssl-with-bazel_src_include_openssl_base.h index c500bed72df1..94e724e94c7e 100644 --- a/devel/py-grpcio/files/patch-third__party_boringssl-with-bazel_src_include_openssl_base.h +++ b/devel/py-grpcio/files/patch-third__party_boringssl-with-bazel_src_include_openssl_base.h @@ -1,12 +1,12 @@ ---- third_party/boringssl-with-bazel/src/include/openssl/base.h.orig 2022-05-03 21:27:37 UTC +--- third_party/boringssl-with-bazel/src/include/openssl/base.h.orig 2023-09-06 01:32:08 UTC +++ third_party/boringssl-with-bazel/src/include/openssl/base.h -@@ -483,9 +483,6 @@ typedef void *OPENSSL_BLOCK; +@@ -413,9 +413,6 @@ typedef void *OPENSSL_BLOCK; // MSVC doesn't set __cplusplus to 201103 to indicate C++11 support (see // https://connect.microsoft.com/VisualStudio/feedback/details/763051/a-value-of-predefined-macro-cplusplus-is-still-199711l) // so MSVC is just assumed to support C++11. -#if !defined(BORINGSSL_NO_CXX) && __cplusplus < 201103L && !defined(_MSC_VER) -#define BORINGSSL_NO_CXX -#endif #if !defined(BORINGSSL_NO_CXX)