Skip to content

Patch auto-downloaded arrow for C++ for latest macos libtool#12749

Open
nikolaseu wants to merge 1 commit into
rerun-io:mainfrom
nikolaseu:chore-arrow-macos-latest-libtool
Open

Patch auto-downloaded arrow for C++ for latest macos libtool#12749
nikolaseu wants to merge 1 commit into
rerun-io:mainfrom
nikolaseu:chore-arrow-macos-latest-libtool

Conversation

@nikolaseu
Copy link
Copy Markdown
Contributor

Related

Closes #12748

What

Latest macOS's libtool returns the version with a slightly different format so the regex used by arrow fails to recognize it, and aborts as if GNU's libtool is being used (which is not supported).

See apache/arrow#49370

@nikolaseu nikolaseu marked this pull request as draft May 1, 2026 12:06
@Wumpf Wumpf marked this pull request as ready for review May 4, 2026 09:56
Copy link
Copy Markdown
Member

@Wumpf Wumpf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for looking into this and upstreaming your solution. See no reason not to take that in, other than needing to document it a bit better so we remove the patch!

That said, the version we pinned on arrow here is getting quite old, we should soon look into picking up a newer one. Afaik they switched to a newer C++ version and I'd like us to be C++17 compatible for a bit longer, so options might be a bit limited. (either way that's for a different iteration ofc)

Comment on lines 96 to 97
# Apply patch after checkout but before configure
# TODO(apache/arrow#45985): Arrow can't support CMake 4.0 yet
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

docs need to move to the actual patch and should also document the new patch (why it's needed, what version would make it go away etc.)

@nikolaseu
Copy link
Copy Markdown
Contributor Author

nikolaseu commented May 4, 2026

Hi Andreas, thanks for taking a look.

I will check and continue with this again later. I marked it as draft because I can't really get it working locally, it seems like the patch was not being applied, but it didn't fail either. I'm not sure what was going on.

@Wumpf Wumpf marked this pull request as draft May 4, 2026 11:00
@rerun-rmack
Copy link
Copy Markdown
Contributor

I suspect copying lines 94-146 from latest BuildUtils.cmake to replace lines 100-121 would be an effective fix but I don't have a machine to test that on.

@nikolaseu
Copy link
Copy Markdown
Contributor Author

I suspect copying lines 94-146 from latest BuildUtils.cmake to replace lines 100-121 would be an effective fix but I don't have a machine to test that on.

Sorry, I was not clear. The patch works when applied manually, but something is maybe wrong in the setup or my changes in rerun_cpp/download_and_build_arrow.cmake

There's no need to patch a lot more than this in the currently used version of arrow, even if latest arrow changed a lot more.

@nikolaseu nikolaseu force-pushed the chore-arrow-macos-latest-libtool branch from 7a3dfff to 6245414 Compare May 14, 2026 15:13
@nikolaseu nikolaseu marked this pull request as ready for review May 14, 2026 15:14
@nikolaseu
Copy link
Copy Markdown
Contributor Author

@Wumpf the issue was that the patches were not being applied, they were just skipped by git. The previous setup was not working, so I guess the mimalloc issue was not an issue anymore.

@Wumpf Wumpf changed the title Patch arrow for latest macos libtool Patch auto-downloaded arrow for C++ for latest macos libtool May 18, 2026
@Wumpf Wumpf added 📺 re_viewer affects re_viewer itself sdk-cpp C/C++ API specific include in changelog and removed 📺 re_viewer affects re_viewer itself labels May 18, 2026
set(ARROW_PATCHES
# TODO(apache/arrow#45985): Arrow can't support CMake 4.0 yet
${CMAKE_CURRENT_LIST_DIR}/patches/mimalloc_cmake4.patch
# TODO update to arrow 24 and remove this patch
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

our CI flags TODO notes without ticket or name references.

Also, do you know whether this is fixed in earlier arrow versions as well? I checked and it looks like arrow 23 starts requiring C++20, so anything prior to that would be easier to upgrade for us.

Comment on lines +99 to +100
# Since this is downloading a release tarball, we need to init a git repository in order to apply the patches.
PATCH_COMMAND git init && git apply --check ${ARROW_PATCHES} && git apply ${ARROW_PATCHES} || true
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

afaik that's not entirely true, but the problem is rather that we're more likely than not already in an existing git repo

Digging a bit: at the time of the introducing PR #11223 it still did a full git clone, but at the same time I can build with cmake4 just fine off main for me :/. probably still best to leave the patch for now, cc @ntjohnson1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

c++: arrow + latest macos issue

3 participants