This blog entry by Dirk Edelbuettel states:
Rcpp, as a CRAN package, follows CRAN policy in not (yet at least) supporting this standard [C++11] for its purported non-portable status.
The blog entry is two years old, and I've been wondering if this is still true (both with regard to the CRAN policies, where I did not find any hint about C++11, and Rcpp support).
Moreover, I would like to know what this means exactly. I used a CXX_STD = CXX11
statement in the src/MAKEVARS
file (rather than Sys.setenv("PKG_CXXFLAGS"="-std=c++11")
as proposed in the blog entry). This seems to work with the C++11 features I am using (mainly the tgamma function), Rcpp, and R. But will I get ripleyed when I submit my package to CRAN? Will the package not be available for some operating systems?
All of the above comments, and try:
// [[Rcpp::plugins(cpp11)]]
There are several packages which require C++11, search CRAN for SystemRequirements: C++11
, and Rcpp
. E.g. http://cran.us.r-project.org/web/packages/contoureR/index.html which has about the simplest possible package configuration without using Rcpp::plugins(cpp11)
.
My case is peculiar because, for obscure CRAN maintainer reasons, on esoteric platforms, OpenMP and C++11 don't go together (see https://github.com/jackwasey/icd for how to accomplish this with a configure script).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With