[R-SIG-Mac] configure tests for OpenMP fail when building CRAN binary packages
Ivan Krylov
|kry|ov @end|ng |rom d|@root@org
Mon Dec 29 23:09:42 CET 2025
Hello,
Some packages that use a configure test for OpenMP support now don't
detect it when being compiled for macOS:
https://www.r-project.org/nosvn/R.check/r-release-macos-arm64/RcppArmadillo-00install.html
https://www.r-project.org/nosvn/R.check/r-release-macos-x86_64/data.table-00install.html
The test for working OpenMP support used by these two packages is
PKG_CFLAGS='-Xclang -fopenmp' PKG_LIBS=-lomp R CMD SHLIB test.c
...completing with an exit status of 0. (Where test.c contains some
valid OpenMP directives.) It's not ideal, but it's prone to false
positives, not false negatives.
The problem does not happen on the macOS builder.
Could the CRAN builder be possibly missing some configuration
pertaining to libomp.dylib? Is there anything I could do to help
diagnose the problem?
--
Best regards,
Ivan
More information about the R-SIG-Mac
mailing list