From 751daf0b374775ade8ae32e40c7931006a0acac8 Mon Sep 17 00:00:00 2001 From: Jonathan Keane Date: Fri, 13 Feb 2026 11:46:42 -0600 Subject: [PATCH 1/3] macos 11 sdk from jonkeane/crossbow --- dev/tasks/r/github.macos.cran.yml | 34 +++++++++++++++++++++++++++++-- 1 file changed, 32 insertions(+), 2 deletions(-) diff --git a/dev/tasks/r/github.macos.cran.yml b/dev/tasks/r/github.macos.cran.yml index dda8ac7fd78..34841c9fb59 100644 --- a/dev/tasks/r/github.macos.cran.yml +++ b/dev/tasks/r/github.macos.cran.yml @@ -21,10 +21,12 @@ jobs: macos-cran: - name: "macOS similar to CRAN" + name: "macOS {{ '${{ matrix.config }}' }}" runs-on: macOS-latest strategy: fail-fast: false + matrix: + config: ["cran-m1", "cran-release"] steps: {{ macros.github_checkout_arrow()|indent }} @@ -58,7 +60,35 @@ jobs: extra-packages: | any::rcmdcheck any::sys - - name: Install + - name: Install MacOSX 11.3 SDK + if: matrix.config == 'cran-release' + env: + SDK_TOKEN: {{ '${{ secrets.JONKEANE_MACOS_11_SDK_DOWNLOAD_TOKEN }}' }} + run: | + # Download, Confirm integrity, expand. This will fail if the hash does not match. + curl -fsSL -H "Authorization: Bearer $SDK_TOKEN" \ + -H "Accept: application/vnd.github+json" \ + https://api.github.com/repos/jonkeane/crossbow_11_sdk/tarball/v0.0.1 \ + -o /tmp/MacOSX11.3.sdk.tar.gz + echo "493570e56d6c6af26128e9096de738822589cc3cdb1b29aa5854f3f4c99756ac /tmp/MacOSX11.3.sdk.tar.gz" | shasum -a 256 -c - + sudo tar -xzf /tmp/MacOSX11.3.sdk.tar.gz -C /Library/Developer/CommandLineTools/SDKs/ + # Move SDK from extracted folder (GitHub archives as {owner}-{repo}-{sha}/) + sudo mv /Library/Developer/CommandLineTools/SDKs/jonkeane-crossbow_11_sdk-*/MacOSX11.3.sdk \ + /Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk + sudo rm -rf /Library/Developer/CommandLineTools/SDKs/jonkeane-crossbow_11_sdk-* + ls -la /Library/Developer/CommandLineTools/SDKs/ + - name: Install (cran-release) + if: matrix.config == 'cran-release' + env: + _R_CHECK_CRAN_INCOMING_: false + SDKROOT: '/Library/Developer/CommandLineTools/SDKs/MacOSX11.3.sdk' + NOT_CRAN: false + run: | + sccache --start-server || echo 'sccache not found' + cd arrow/r + R CMD INSTALL . --install-tests + - name: Install (cran-m1) + if: matrix.config == 'cran-m1' env: _R_CHECK_CRAN_INCOMING_: false CXX: "clang++ -mmacos-version-min=14.6" From 3cf3c711ef7e449500cf2fd23c3ac55908ad706c Mon Sep 17 00:00:00 2001 From: Jonathan Keane Date: Tue, 10 Feb 2026 22:16:31 -0600 Subject: [PATCH 2/3] Workaround on older partially compliant C++20 implementations --- cpp/src/arrow/compute/kernels/hash_aggregate.cc | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/cpp/src/arrow/compute/kernels/hash_aggregate.cc b/cpp/src/arrow/compute/kernels/hash_aggregate.cc index ed50025ef5f..7f2ce123377 100644 --- a/cpp/src/arrow/compute/kernels/hash_aggregate.cc +++ b/cpp/src/arrow/compute/kernels/hash_aggregate.cc @@ -277,8 +277,15 @@ template concept CBooleanConcept = std::same_as; // XXX: Ideally we want to have std::floating_point = true. +// Some older standard library implementations (e.g., macOS 11.x libc++) have partial +// C++20 concepts support with std::same_as but lack std::floating_point. +#if defined(__cpp_lib_concepts) && __cpp_lib_concepts >= 202002L template concept CFloatingPointConcept = std::floating_point || std::same_as; +#else +template +concept CFloatingPointConcept = std::is_floating_point_v || std::same_as; +#endif template concept CDecimalConcept = std::same_as || std::same_as || From 08daa2e74dc9d2c652da3c3f248f641675b0d106 Mon Sep 17 00:00:00 2001 From: Jonathan Keane Date: Fri, 13 Feb 2026 12:18:07 -0600 Subject: [PATCH 3/3] linting Co-Authored-By: Claude Opus 4.6 --- cpp/src/arrow/compute/kernels/hash_aggregate.cc | 3 ++- dev/tasks/r/github.macos.cran.yml | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/cpp/src/arrow/compute/kernels/hash_aggregate.cc b/cpp/src/arrow/compute/kernels/hash_aggregate.cc index 7f2ce123377..3ab7ff065b2 100644 --- a/cpp/src/arrow/compute/kernels/hash_aggregate.cc +++ b/cpp/src/arrow/compute/kernels/hash_aggregate.cc @@ -284,7 +284,8 @@ template concept CFloatingPointConcept = std::floating_point || std::same_as; #else template -concept CFloatingPointConcept = std::is_floating_point_v || std::same_as; +concept CFloatingPointConcept = + std::is_floating_point_v || std::same_as; #endif template diff --git a/dev/tasks/r/github.macos.cran.yml b/dev/tasks/r/github.macos.cran.yml index 34841c9fb59..930f7c5587e 100644 --- a/dev/tasks/r/github.macos.cran.yml +++ b/dev/tasks/r/github.macos.cran.yml @@ -107,6 +107,6 @@ jobs: - name: Save the test output uses: actions/upload-artifact@v4 with: - name: test-output + name: test-output-{{ '${{ matrix.config }}' }} path: arrow-tests/testthat.Rout* if: always()