From f6483e7d8ab4f876b7d74e01858454c3a53a27cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20Cumplido?= Date: Tue, 17 Jun 2025 09:09:24 +0200 Subject: [PATCH 1/6] GH-46831: [R] Update SystemRequirements with required CMake >= 3.25 --- r/DESCRIPTION | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/r/DESCRIPTION b/r/DESCRIPTION index 99470a3cc57..16814806322 100644 --- a/r/DESCRIPTION +++ b/r/DESCRIPTION @@ -28,7 +28,7 @@ BugReports: https://github.com/apache/arrow/issues Encoding: UTF-8 Language: en-US SystemRequirements: C++17; for AWS S3 support on Linux, libcurl and openssl (optional); - cmake >= 3.16 (build-time only, and only for full source build) + cmake >= 3.25 (build-time only, and only for full source build) Biarch: true Imports: assertthat, From 1f24aa03181026148647bd5e7e725b24808cba47 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20Cumplido?= Date: Tue, 17 Jun 2025 16:39:56 +0200 Subject: [PATCH 2/6] Update building.rst docs to match CMake version --- docs/source/developers/cpp/building.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/source/developers/cpp/building.rst b/docs/source/developers/cpp/building.rst index 60a9e069415..8fe89712611 100644 --- a/docs/source/developers/cpp/building.rst +++ b/docs/source/developers/cpp/building.rst @@ -41,7 +41,7 @@ Building requires: * A C++17-enabled compiler. On Linux, gcc 7.1 and higher should be sufficient. For Windows, at least Visual Studio VS2017 is required. -* CMake 3.16 or higher +* CMake 3.25 or higher * On Linux and macOS, either ``make`` or ``ninja`` build utilities * At least 1GB of RAM for a minimal build, 4GB for a minimal debug build with tests and 8GB for a full build using @@ -451,7 +451,7 @@ several times with different options if you want to exercise all of them. CMake version requirements ~~~~~~~~~~~~~~~~~~~~~~~~~~ -We support CMake 3.16 and higher. +We support CMake 3.25 and higher. LLVM and Clang Tools ~~~~~~~~~~~~~~~~~~~~ From f0310e6d82b13e8a126439490d78f736c71f3536 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20Cumplido?= Date: Fri, 20 Jun 2025 10:14:05 +0200 Subject: [PATCH 3/6] Get rid of CMake 3.16 references completely --- ci/conan/all/conanfile.py | 4 +++- ci/conan/all/test_package/CMakeLists.txt | 2 +- cpp/cmake_modules/ThirdpartyToolchain.cmake | 10 ---------- cpp/examples/minimal_build/CMakeLists.txt | 2 +- 4 files changed, 5 insertions(+), 13 deletions(-) diff --git a/ci/conan/all/conanfile.py b/ci/conan/all/conanfile.py index 6881ee6f325..32a32ba8d4e 100644 --- a/ci/conan/all/conanfile.py +++ b/ci/conan/all/conanfile.py @@ -268,7 +268,9 @@ def validate(self): raise ConanInvalidConfiguration("arrow:parquet requires arrow:with_thrift") def build_requirements(self): - if Version(self.version) >= "13.0.0": + if Version(self.version) >= "20.0.0": + self.tool_requires("cmake/[>=3.25 <4]") + else: self.tool_requires("cmake/[>=3.16 <4]") def source(self): diff --git a/ci/conan/all/test_package/CMakeLists.txt b/ci/conan/all/test_package/CMakeLists.txt index d85120a6626..f2f658decb1 100644 --- a/ci/conan/all/test_package/CMakeLists.txt +++ b/ci/conan/all/test_package/CMakeLists.txt @@ -20,7 +20,7 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE # SOFTWARE. -cmake_minimum_required(VERSION 3.15) +cmake_minimum_required(VERSION 3.25) project(test_package LANGUAGES CXX) find_package(Arrow REQUIRED CONFIG) diff --git a/cpp/cmake_modules/ThirdpartyToolchain.cmake b/cpp/cmake_modules/ThirdpartyToolchain.cmake index 5264beed783..f24a83d13fb 100644 --- a/cpp/cmake_modules/ThirdpartyToolchain.cmake +++ b/cpp/cmake_modules/ThirdpartyToolchain.cmake @@ -5303,16 +5303,6 @@ endif() # Azure SDK for C++ function(build_azure_sdk) - if(CMAKE_VERSION VERSION_LESS 3.22) - # We can't disable installing Azure SDK for C++ by - # "set_property(DIRECTORY ${azure_sdk_SOURCE_DIR} PROPERTY - # EXCLUDE_FROM_ALL TRUE)" with CMake 3.16. - # - # At least CMake 3.22 on Ubuntu 22.04 works. So we use 3.22 - # here. We may be able to use more earlier version here. - message(FATAL_ERROR "Building Azure SDK for C++ requires at least CMake 3.22. " - "(At least we can't use CMake 3.16)") - endif() message(STATUS "Building Azure SDK for C++ from source") fetchcontent_declare(azure_sdk ${FC_DECLARE_COMMON_OPTIONS} diff --git a/cpp/examples/minimal_build/CMakeLists.txt b/cpp/examples/minimal_build/CMakeLists.txt index 95dad34221a..689dba437e0 100644 --- a/cpp/examples/minimal_build/CMakeLists.txt +++ b/cpp/examples/minimal_build/CMakeLists.txt @@ -15,7 +15,7 @@ # specific language governing permissions and limitations # under the License. -cmake_minimum_required(VERSION 3.16) +cmake_minimum_required(VERSION 3.25) project(ArrowMinimalExample) From f7581de4cb1a786c5736e5aae19188f2d3833564 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20Cumplido?= Date: Fri, 20 Jun 2025 10:47:28 +0200 Subject: [PATCH 4/6] Revert change on ci/conan/all/test_package/CMakeLists.txt --- ci/conan/all/test_package/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/conan/all/test_package/CMakeLists.txt b/ci/conan/all/test_package/CMakeLists.txt index f2f658decb1..d85120a6626 100644 --- a/ci/conan/all/test_package/CMakeLists.txt +++ b/ci/conan/all/test_package/CMakeLists.txt @@ -20,7 +20,7 @@ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE # SOFTWARE. -cmake_minimum_required(VERSION 3.25) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES CXX) find_package(Arrow REQUIRED CONFIG) From e4c22e31a55433e323c5619a96aa3d50c8a3116c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20Cumplido?= Date: Fri, 20 Jun 2025 10:51:20 +0200 Subject: [PATCH 5/6] Revert conan changes to update on a follow up PR --- ci/conan/all/conanfile.py | 4 +--- python/read.py | 12 ++++++++++++ 2 files changed, 13 insertions(+), 3 deletions(-) create mode 100644 python/read.py diff --git a/ci/conan/all/conanfile.py b/ci/conan/all/conanfile.py index 32a32ba8d4e..6881ee6f325 100644 --- a/ci/conan/all/conanfile.py +++ b/ci/conan/all/conanfile.py @@ -268,9 +268,7 @@ def validate(self): raise ConanInvalidConfiguration("arrow:parquet requires arrow:with_thrift") def build_requirements(self): - if Version(self.version) >= "20.0.0": - self.tool_requires("cmake/[>=3.25 <4]") - else: + if Version(self.version) >= "13.0.0": self.tool_requires("cmake/[>=3.16 <4]") def source(self): diff --git a/python/read.py b/python/read.py new file mode 100644 index 00000000000..0d4709f6c97 --- /dev/null +++ b/python/read.py @@ -0,0 +1,12 @@ +import pyarrow.dataset as ds +from time import perf_counter + +dataset = ds.dataset("/home/raulcd/code/pyarrow-issue-isin/BIG_DATASET") +population = [i for i in range(1, 10_000_001)] +filter_expr = ds.field("unit_id").isin(population) + +start = perf_counter() +table = dataset.to_table(filter=filter_expr) +end = perf_counter() +print("=== PYARROW VERSION 20 ===") +print(f"Retrieved {table.num_rows:,} rows in {end - start:.2f} seconds.\n") From 97484ad16a72cff5d0e6fa22029953ba1f399a7e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20Cumplido?= Date: Fri, 20 Jun 2025 10:59:54 +0200 Subject: [PATCH 6/6] Remove stray file --- python/read.py | 12 ------------ 1 file changed, 12 deletions(-) delete mode 100644 python/read.py diff --git a/python/read.py b/python/read.py deleted file mode 100644 index 0d4709f6c97..00000000000 --- a/python/read.py +++ /dev/null @@ -1,12 +0,0 @@ -import pyarrow.dataset as ds -from time import perf_counter - -dataset = ds.dataset("/home/raulcd/code/pyarrow-issue-isin/BIG_DATASET") -population = [i for i in range(1, 10_000_001)] -filter_expr = ds.field("unit_id").isin(population) - -start = perf_counter() -table = dataset.to_table(filter=filter_expr) -end = perf_counter() -print("=== PYARROW VERSION 20 ===") -print(f"Retrieved {table.num_rows:,} rows in {end - start:.2f} seconds.\n")