From 1a381f9a1bdaca28b39774cac7be93df6cebf4d0 Mon Sep 17 00:00:00 2001 From: Will Ayd Date: Wed, 9 Jul 2025 09:55:28 -0400 Subject: [PATCH 1/5] GH-47039: Bump RapidJSON dependency in Meson configuration --- .../packagefiles/rapidjson/meson.build | 20 +++++++++++++++++++ cpp/subprojects/rapidjson.wrap | 15 ++++++-------- 2 files changed, 26 insertions(+), 9 deletions(-) create mode 100644 cpp/subprojects/packagefiles/rapidjson/meson.build diff --git a/cpp/subprojects/packagefiles/rapidjson/meson.build b/cpp/subprojects/packagefiles/rapidjson/meson.build new file mode 100644 index 00000000000..a407ed79014 --- /dev/null +++ b/cpp/subprojects/packagefiles/rapidjson/meson.build @@ -0,0 +1,20 @@ +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +project('rapidjson', 'cpp') + +rapidjson_dep = declare_dependency(include_directories: 'include') diff --git a/cpp/subprojects/rapidjson.wrap b/cpp/subprojects/rapidjson.wrap index 8295f198525..757a73b4bae 100644 --- a/cpp/subprojects/rapidjson.wrap +++ b/cpp/subprojects/rapidjson.wrap @@ -16,15 +16,12 @@ # under the License. [wrap-file] -directory = rapidjson-1.1.0 -source_url = https://github.com/Tencent/rapidjson/archive/v1.1.0.tar.gz -source_filename = rapidjson-1.1.0.tar.gz -source_hash = bf7ced29704a1e696fbccf2a2b4ea068e7774fa37f6d7dd4039d0787f8bed98e -patch_filename = rapidjson_1.1.0-2_patch.zip -patch_url = https://wrapdb.mesonbuild.com/v2/rapidjson_1.1.0-2/get_patch -patch_hash = c1480d0ecef09dbaa4b4d85d86090205386fb2c7e87f4f158b20dbbda14c9afc -source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/rapidjson_1.1.0-2/rapidjson-1.1.0.tar.gz -wrapdb_version = 1.1.0-2 +directory = rapidjson-232389d4f1012dddec4ef84861face2d2ba85709 +source_url = https://github.com/miloyip/rapidjson/archive/232389d4f1012dddec4ef84861face2d2ba85709.tar.gz +source_filename = rapidjson-232389d4f1012dddec4ef84861face2d2ba85709.tar.gz +source_hash = b9290a9a6d444c8e049bd589ab804e0ccf2b05dc5984a19ed5ae75d090064806 +source_fallback_url = https://apache.jfrog.io/artifactory/arrow/thirdparty/7.0.0/rapidjson-232389d4f1012dddec4ef84861face2d2ba85709.tar.gz +patch_directory = rapidjson [provide] rapidjson = rapidjson_dep From fa45af1d5230ac0e4a549ad1fe7d63a269cf907f Mon Sep 17 00:00:00 2001 From: Will Ayd Date: Wed, 13 Aug 2025 14:26:30 -0400 Subject: [PATCH 2/5] Force use of rapidjson subproject --- cpp/src/arrow/meson.build | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cpp/src/arrow/meson.build b/cpp/src/arrow/meson.build index c1efd9df763..75eca42827b 100644 --- a/cpp/src/arrow/meson.build +++ b/cpp/src/arrow/meson.build @@ -293,7 +293,8 @@ if needs_csv endif if needs_json or needs_integration - rapidjson_dep = dependency('rapidjson', include_type: 'system') + rapidjson_proj = subproject('rapidjson') + rapidjson_dep = rapidjson_proj.get_variable('rapidjson_dep') else rapidjson_dep = disabler() endif From f2f9b35324fa4fba7c68fa2a7bf11a6adcd8a203 Mon Sep 17 00:00:00 2001 From: Will Ayd Date: Wed, 13 Aug 2025 23:59:21 -0400 Subject: [PATCH 3/5] Try system detect with fallback --- cpp/src/arrow/meson.build | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/cpp/src/arrow/meson.build b/cpp/src/arrow/meson.build index 75eca42827b..48c366a7068 100644 --- a/cpp/src/arrow/meson.build +++ b/cpp/src/arrow/meson.build @@ -293,8 +293,11 @@ if needs_csv endif if needs_json or needs_integration - rapidjson_proj = subproject('rapidjson') - rapidjson_dep = rapidjson_proj.get_variable('rapidjson_dep') + rapidjson_dep = dependency( + 'rapidjson', + method: 'system', + fallback: ['rapidjson', 'rapidjson_dep'], + ) else rapidjson_dep = disabler() endif From 926da04c7c4aabc842d79c9092f85de46f6f7cd1 Mon Sep 17 00:00:00 2001 From: Will Ayd Date: Thu, 14 Aug 2025 00:00:08 -0400 Subject: [PATCH 4/5] Fix wrap url --- cpp/subprojects/rapidjson.wrap | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cpp/subprojects/rapidjson.wrap b/cpp/subprojects/rapidjson.wrap index 757a73b4bae..d48fd999ba8 100644 --- a/cpp/subprojects/rapidjson.wrap +++ b/cpp/subprojects/rapidjson.wrap @@ -17,7 +17,7 @@ [wrap-file] directory = rapidjson-232389d4f1012dddec4ef84861face2d2ba85709 -source_url = https://github.com/miloyip/rapidjson/archive/232389d4f1012dddec4ef84861face2d2ba85709.tar.gz +source_url = https://github.com/Tencent/rapidjson/archive/232389d4f1012dddec4ef84861face2d2ba85709.tar.gz source_filename = rapidjson-232389d4f1012dddec4ef84861face2d2ba85709.tar.gz source_hash = b9290a9a6d444c8e049bd589ab804e0ccf2b05dc5984a19ed5ae75d090064806 source_fallback_url = https://apache.jfrog.io/artifactory/arrow/thirdparty/7.0.0/rapidjson-232389d4f1012dddec4ef84861face2d2ba85709.tar.gz From d7d2da2b7bf9852a4c3ca9236a602ee6b35033a5 Mon Sep 17 00:00:00 2001 From: Will Ayd Date: Fri, 15 Aug 2025 12:24:12 -0400 Subject: [PATCH 5/5] Try using system-provided RapidJSON --- cpp/src/arrow/meson.build | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cpp/src/arrow/meson.build b/cpp/src/arrow/meson.build index 48c366a7068..b2eef9d7ed2 100644 --- a/cpp/src/arrow/meson.build +++ b/cpp/src/arrow/meson.build @@ -294,8 +294,7 @@ endif if needs_json or needs_integration rapidjson_dep = dependency( - 'rapidjson', - method: 'system', + 'RapidJSON', fallback: ['rapidjson', 'rapidjson_dep'], ) else