[Rcpp-devel] Compile problem on Win x64 resolved with -std=c++0x
Dirk Eddelbuettel
edd at debian.org
Tue Jul 17 15:10:21 CEST 2012
On 17 July 2012 at 07:41, Smith, Dale wrote:
| Hi all,
|
| I had the "long long unsigned int" problem today on Win x64. I passed
| --no-multiarch to R CMD build after making a package using
| Rcpp.package.skeleton. The error message in part was
|
| ***
| C:/R/R-2.15.1/library/Rcpp/include/Rcpp/internal/wrap.h:433:11: error:
| invalid conversion from 'long long unsigned int' to 'SEXP'
| [-fpermissive]
| make: *** [stdVector.o] Error 1
| ***
Right. I think it actually only bites on 32bit, but as R defaults to 32 and
64 on Windows now, it is a binding constraint/
|
| I resolved the problem using
|
| PKG_CXXFLAGS = "-std=c++0x"
|
| in my Makevars files.
|
| gcc 4.6.3 (from Rtools215) apparently doesn't support "c++11". Based on
Correct. I may have been sloppy in some posts here.
The main story is
-- C++ itself does not have 'long long' and 'unsigned long long' as per the
older 2003 standard
-- yet older g++ release silently supported it
-- but newer g++ releases got stricter and require explicit switching of
the new / upcoming / ratified standard
| the list traffic I've seen, I suspect c++0x is not supported by CRAN,
| but I haven't looked into it, so YMMV.
Correct. We cannot use -std=c++0x in uploads to CRAN (yet, and/or for the
next few years).
I suspect that g++ 4.8, or maybe 4.9, may make some of this standard and by
then we're fine.
Until then, feel free to use this on in-house code but not on uploads to
CRAN.
Dirk
|
| Thanks,
| Dale Smith, Ph.D.
| Senior Financial Quantitative Analyst
| Risk & Compliance
| Fiserv.
| 107 Technology Park
| Norcross, GA 30092
| Office: 678-375-5315
| Mail: dale.smith at fiserv.com
| www.fiserv.com
|
| _______________________________________________
| Rcpp-devel mailing list
| Rcpp-devel at lists.r-forge.r-project.org
| https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel
--
Dirk Eddelbuettel | edd at debian.org | http://dirk.eddelbuettel.com
More information about the Rcpp-devel
mailing list