diff mbox series

[meta-python,040/105] python3-grpcio-tools: upgrade 1.84.1 -> 1.85.1

Message ID 20261116175359.342679-40-khem.raj@oss.qualcomm.com
State New
Headers show
Series [meta-python,001/105] python3-absl: upgrade 2.1.0 -> 2.5.1 | expand

Commit Message

Khem Raj Nov. 16, 2026, 5:52 p.m. UTC
Backport the abseil fix for clang rejecting a direct <bmi2intrin.h>
include (needed for x86-64-v3) to the bundled abseil.

Changes:
- Follows grpcio 1.85: Cython unpinned for source builds, OpenSSL 4
  support and OpenSSL 1.0.2 support removed in the bundled gRPC core.
- Security: gRPC core 1.85.1 fixes denial of service in Health Watch
  RPC and HPACK host/:authority handling (no CVE ID published).

AI-Generated: Uses Claude Code
Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
---
 ...set-include-immintrin.h-instead-of-b.patch | 36 +++++++++++++++++++
 ...84.1.bb => python3-grpcio-tools_1.85.1.bb} |  3 +-
 2 files changed, 38 insertions(+), 1 deletion(-)
 create mode 100644 meta-python/recipes-devtools/python/python3-grpcio-tools/0001-abseil-raw_hash_set-include-immintrin.h-instead-of-b.patch
 rename meta-python/recipes-devtools/python/{python3-grpcio-tools_1.84.1.bb => python3-grpcio-tools_1.85.1.bb} (77%)
diff mbox series

Patch

diff --git a/meta-python/recipes-devtools/python/python3-grpcio-tools/0001-abseil-raw_hash_set-include-immintrin.h-instead-of-b.patch b/meta-python/recipes-devtools/python/python3-grpcio-tools/0001-abseil-raw_hash_set-include-immintrin.h-instead-of-b.patch
new file mode 100644
index 0000000000..7b31540ead
--- /dev/null
+++ b/meta-python/recipes-devtools/python/python3-grpcio-tools/0001-abseil-raw_hash_set-include-immintrin.h-instead-of-b.patch
@@ -0,0 +1,36 @@ 
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Tue, 24 Jun 2026 00:00:00 +0000
+Subject: [PATCH] abseil: raw_hash_set: include <immintrin.h> instead of <bmi2intrin.h>
+
+Clang refuses a direct include of <bmi2intrin.h> and errors out with:
+
+  error: "Never use <bmi2intrin.h> directly; include <immintrin.h> instead."
+
+This is hit whenever __BMI2__ is defined, e.g. when building with
+-march=x86-64-v3. Mirror upstream and include the umbrella <immintrin.h>
+header guarded by an x86 check, which transitively provides the BMI2
+intrinsics (_bzhi_u32/_bzhi_u64) used in mask().
+
+Upstream-Status: Backport [https://github.com/abseil/abseil-cpp/commit/d851fdd768b27c02b3fb786fd0987faddd279ece]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ third_party/abseil-cpp/absl/container/internal/raw_hash_set.h | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/third_party/abseil-cpp/absl/container/internal/raw_hash_set.h
++++ b/third_party/abseil-cpp/absl/container/internal/raw_hash_set.h
+@@ -225,9 +225,9 @@
+ #include <ranges>  // NOLINT(build/c++20)
+ #endif
+
+-#ifdef __BMI2__
+-#include <bmi2intrin.h>
+-#endif  // __BMI2__
++#if defined(__i386__) || defined(__x86_64__)
++#include <immintrin.h>
++#endif
+
+ namespace absl {
+ ABSL_NAMESPACE_BEGIN
diff --git a/meta-python/recipes-devtools/python/python3-grpcio-tools_1.84.1.bb b/meta-python/recipes-devtools/python/python3-grpcio-tools_1.85.1.bb
similarity index 77%
rename from meta-python/recipes-devtools/python/python3-grpcio-tools_1.84.1.bb
rename to meta-python/recipes-devtools/python/python3-grpcio-tools_1.85.1.bb
index 91d14f719a..af3f662755 100644
--- a/meta-python/recipes-devtools/python/python3-grpcio-tools_1.84.1.bb
+++ b/meta-python/recipes-devtools/python/python3-grpcio-tools_1.85.1.bb
@@ -9,7 +9,8 @@  inherit pypi python_setuptools_build_meta cython
 
 DEPENDS += "python3-grpcio python3-wheel-native"
 
-SRC_URI[sha256sum] = "ca8a326df3441127d6709d992774844bb496db30b08f76ed5d1a912089e03f2c"
+SRC_URI += "file://0001-abseil-raw_hash_set-include-immintrin.h-instead-of-b.patch"
+SRC_URI[sha256sum] = "d6f1ee213a07de9462c90ee5debe4a78dff20306a0fb394a65d48b2f94fe31a1"
 
 RDEPENDS:${PN} = "python3-grpcio"