You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Thanks for all the great work on data.table. It's a really fantastic tool.
I've found that the instructions at https://github.com/Rdatatable/data.table/wiki/Installation for building data.table from source to enable OpenMP support on macOS 12.4 Monterey do not produce a working build via the preferred Option 1.1 Install libomp with brew approach.
If, after brew update && brew install libomp the recommended .R/Makevars flags are set (i.e. CPPFLAGS += -Xclang -fopenmp and LDFLAGS += -lomp).
With the documented flags, install.package from source errors out after failing to find omp.h. After a bit of fiddling around I found that the following will produce a working install:
That build does not, however, pass test.data.table() which fails after about 1800 tests citing the absence of libz. To solve this problem I needed to also install pkg-config (i.e. brew install pkg-config). After doing this and reinstalling data.table from source test.data.table() completes all 9999 tests successfully.
As such, for me, on a clean native R arm64 4.2.1 install onto an Apple M1 running on 12.4 with no other brew packages installed what I needed to do for a working OpenMP enabled install of data.table was:
Install data.table from source within R install.packages("data.table", type = "source")
Sorry that I do not have the exact error messages encountered along the way. Given how fussy macOS / OpenMP support has always been I assumed that I was the problem and thus did not keep track of the steps required to fix what I've now come to think could be more general departure of current state brew / xcode build tools (i.e. xcode-select --install) on Apple Silicon from the documentation.
If those who know more believe that the steps I took to get a working build are likely those required I'm not sure how this should be best documented as the current macOS instructions worked well for me on an x86 Mac very recently so I think this may be a case of platform specific differences in brew not just a 'new normal'.
odani, m-muecke, vc77, arbuzovv, tonytrill and 2 morepintoa1-mskcc, shrektan and tonytrillderekschinke, arbuzovv and tonytrill