[Rcpp-devel] Where is R.h and the other header files?
sorenh at math.aau.dk
Mon Aug 27 00:08:50 CEST 2012
I assume that you compile with
R CMD SHLIB foo.cpp
In that case, it might help to create a Makevars file with the content
PKG_LIBS=`Rscript -e "Rcpp:::LdFlags()"`
PKG_CXXFLAGS=`Rscript -e "Rcpp:::CxxFlags()"`
From: liu lin [mailto:lliu.hsph at gmail.com]
Sent: 26. august 2012 23:56
To: Søren Højsgaard
Subject: Re: [Rcpp-devel] Where is R.h and the other header files?
I just added a line of #include <R.h> in the helloworld.c as a trial. The output from the compilation is birth_death.hpp:24:15: error: R.h: No such file or directory
On Aug 26, 2012, at 5:53 PM, Søren Højsgaard wrote:
> Can you show us the output from the compilation and possibly also the contents of your Makevars file?
> -----Original Message-----
> From: rcpp-devel-bounces at lists.r-forge.r-project.org [mailto:rcpp-devel-bounces at lists.r-forge.r-project.org] On Behalf Of liu lin
> Sent: 26. august 2012 23:32
> To: rcpp-devel at lists.r-forge.r-project.org
> Subject: [Rcpp-devel] Where is R.h and the other header files?
> Dear all,
> I'm trying to write C++ code and call it in R. But after installing the Rcpp package in R, I cannot find where the R.h and the other header file are. When writing code in eclipse, it's really annoying to deal with the errors because of the non-existance of R.h's. Is it a built-in feature of Rcpp or just i'm not on the right track?
> Rcpp-devel mailing list
> Rcpp-devel at lists.r-forge.r-project.org
More information about the Rcpp-devel