Skip to content
Prev 9999 / 12125 Next

[R-pkg-devel] Status of -mmacosx-version-min

As discussed here before packages should *never* set -mmacosx-version-min or similar flags by hand. As documented in R-exts 1.2 packages should retrieve compiler flags from R (this includes compiling 3rd party dependencies). Incidentally, older versions of R have included -mmacosx-version-min in the CC setting (high-sierra builds) which current ones don't, but complying packages will automatically use the correct compilers and flags regardless of the R version and build. Note that this is important as R can be built for different systems and targets so the package should not assume anything - just ask R.

The implied question was about the target macOS version for CRAN binaries: it is always included in the build name, so high-sierra build was targeting macOS 10.13 (High Sierra) and big-sur build is targeting macOS 11 (Big Sur). It is clearly stated next to the download for each macOS R binary on CRAN: https://cran.r-project.org/bin/macosx/ where the current releases target macOS 11.

Anyone distributing macOS binaries should subscribe to R-SIG-Mac where we discuss details such as repository locations etc. Developers writing packages just need to pay attention to R-exts and CRAN policies (the latter if they want to publish on CRAN). I hope this is now clear enough explanation.

Cheers,
Simon