Skip to content

Commit 1deceed

Browse files
committed
GH-51675: [Python][Packaging] Apply upstream fix to UriParser from vcpkg and force Windows image rebuild to fix builds on wheels (#51676)
### Rationale for this change We have bumped UriParser from a vendored version to be built from external sources. We have to rebuild Windows wheels and we have to apply a fix for older GLIBC see the following upstream commit: - uriparser/uriparser@072a97c ### What changes are included in this PR? Apply to vcpkg the upstream commit to fix older GLIBC. ### Are these changes tested? Yes via archery wheels builds ### Are there any user-facing changes? No ### Was AI used for this PR? In accordance to the [AI generation guidelines](https://arrow.apache.org/docs/dev/developers/overview.html#ai-generated-code), please disclose below whether and how AI was used in this PR. **PR code and description written by:** - [x] Human - [x] AI I've used AI to analyze the errors. Changes have been added and applied by me locally. **Reviewed before submission by:** - [x] Human - [ ] AI - [ ] Not reviewed * GitHub Issue: #51675 Authored-by: Raúl Cumplido <[email protected]> Signed-off-by: Sutou Kouhei <[email protected]>
1 parent cca44b5 commit 1deceed

2 files changed

Lines changed: 35 additions & 1 deletion

File tree

‎.env‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,6 @@ VCPKG="9b965a116838c6cdcd36bca60d1b81b030c8ab8d" # 2026.05.27 (not release, u
9898
# ci/docker/python-*-windows-*.dockerfile or the vcpkg config.
9999
# This is a workaround for our CI problem that "archery docker build" doesn't
100100
# use pulled built images in dev/tasks/python-wheels/github.windows.yml.
101-
PYTHON_WHEEL_WINDOWS_IMAGE_REVISION=2026-09-09
101+
PYTHON_WHEEL_WINDOWS_IMAGE_REVISION=2026-10-01
102102
PYTHON_WHEEL_WINDOWS_TEST_IMAGE_REVISION=2026-09-14
103103

‎ci/vcpkg/ports.patch‎

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,3 +80,37 @@ index 278bc17a1c..d47d859360 100644
8080
)
8181
file(GLOB modules "${SOURCE_PATH}/cmake_modules/Find*.cmake")
8282
file(REMOVE ${modules} "${SOURCE_PATH}/c++/libs/libhdfspp/libhdfspp.tar.gz")
83+
diff --git a/ports/uriparser/fix-glibc-2.28-reallocarray.diff b/ports/uriparser/fix-glibc-2.28-reallocarray.diff
84+
new file mode 100644
85+
index 0000000..57adef4
86+
--- /dev/null
87+
+++ b/ports/uriparser/fix-glibc-2.28-reallocarray.diff
88+
@@ -0,0 +1,15 @@
89+
+diff --git a/src/UriMemory.c b/src/UriMemory.c
90+
+--- a/src/UriMemory.c
91+
++++ b/src/UriMemory.c
92+
+@@ -50,6 +50,11 @@
93+
+ # define _DEFAULT_SOURCE 1
94+
+ # endif
95+
+
96+
++// For glibc <2.29
97+
++# if !defined(_GNU_SOURCE)
98+
++# define _GNU_SOURCE 1
99+
++# endif
100+
++
101+
+ // For NetBSD (stdlib.h revision 1.122 of 2020-05-26)
102+
+ # if defined(__NetBSD__) && !defined(_OPENBSD_SOURCE)
103+
+ # define _OPENBSD_SOURCE 1
104+
diff --git a/ports/uriparser/portfile.cmake b/ports/uriparser/portfile.cmake
105+
index 5df5e94..225e5fb 100644
106+
--- a/ports/uriparser/portfile.cmake
107+
+++ b/ports/uriparser/portfile.cmake
108+
@@ -4,6 +4,8 @@ vcpkg_from_github(
109+
REF "uriparser-${VERSION}"
110+
SHA512 1e4c397418e71e705b5712de2dc3ea6e95163c9d95bfbaa5f7d2fd2344d34eaf167d7d9389ab9671cfb314af026621b56e632ea34b681c2f4d7951a1b32a98b4
111+
HEAD_REF master
112+
+ PATCHES
113+
+ fix-glibc-2.28-reallocarray.diff
114+
)
115+
116+
if("tool" IN_LIST FEATURES)

0 commit comments

Comments
 (0)