apache / arrow-nanoarrow

Helpers for Arrow C Data & Arrow C Stream interfaces
https://arrow.apache.org/nanoarrow
Apache License 2.0
149 stars 34 forks source link

fix(r): Avoid flatcc aligned_alloc() call when compiling R package #494

Closed paleolimbot closed 1 month ago

paleolimbot commented 1 month ago

Closes #493.

We could be fancier and check for the presence of aligned_alloc() or guard it in a define based on the C standard; however, I don't think we use it at all right now and even when write support is added I don't think it will matter for how we use flatbuffers in the IPC format.

paleolimbot commented 1 month ago

@barracuda156 Does this fix the install on PowerPC?

barracuda156 commented 1 month ago

Thank you! Passing that flag is what I added for older macOS for now: https://github.com/macports/macports-ports/blob/master/R/R-nanoarrow/files/patch-fix-aligned_alloc.diff So yes, that should work. The problem is not specific to macOS PowerPC, it affects also much more recent Intel systems (something around Darwin 16?).