[R] Embed R code in C++
mans
m.chouaha at hotmail.com
Mon Mar 22 21:29:56 CET 2010
Hi thanks for your help but
I tried to install the pakage but i have got a installing error:
nstalling to library ‘/Library/Frameworks/R.framework/Resources/library’
* installing *source* package ‘RInside’ ...
** libs
** arch - x86_64
Error in loadNamespace(name) : there is no package called 'Rcpp'
Calls: ::: ... tryCatch -> tryCatchList -> tryCatchOne -> <Anonymous>
Execution halted
/Library/Frameworks/R.framework/Resources/bin/R --vanilla --slave <
tools/RInsideEnvVars.r > RInsideEnvVars.h
/Library/Frameworks/R.framework/Resources/bin/R --vanilla --slave <
tools/RInsideAutoloads.r > RInsideAutoloads.h
g++-4.2 -arch x86_64 -I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/x86_64 -Wall
-I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/x86_64 -fPIC -I.
-I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/x86_64 -mtune=core2 -g
-O2 -c MemBuf.cpp -o MemBuf.o
g++-4.2 -arch x86_64 -I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/x86_64 -Wall
-I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/x86_64 -fPIC -I.
-I/Library/Frameworks/R.framework/Resources/include
-I/Library/Frameworks/R.framework/Resources/include/x86_64 -mtune=core2 -g
-O2 -c RInside.cpp -o RInside.o
In file included from RInside.cpp:23:
RInside.h:27:18: error: Rcpp.h: No such file or directory
In file included from RInside.cpp:23:
RInside.h:41: error: ‘Rcpp’ has not been declared
RInside.h:41: error: ISO C++ forbids declaration of ‘Environment’ with no
type
RInside.h:41: error: expected ‘;’ before ‘global_env’
RInside.h:65: error: ‘Rcpp’ has not been declared
RInside.h:65: error: ISO C++ forbids declaration of ‘Binding’ with no type
RInside.h:65: error: expected ‘;’ before ‘operator’
RInside.h: In member function ‘void RInside::assign(const T&, const
std::string&)’:
RInside.h:58: error: ‘global_env’ was not declared in this scope
RInside.cpp: In member function ‘void RInside::initialize(int, const char*
const*)’:
RInside.cpp:70: error: ‘runtime_error’ is not a member of ‘std’
RInside.cpp:100: error: ‘global_env’ was not declared in this scope
RInside.cpp:105: error: ‘Rcpp’ has not been declared
RInside.cpp:105: error: expected `;' before ‘s_argv’
RInside.cpp:106: error: ‘s_argv’ was not declared in this scope
RInside.cpp: In member function ‘void RInside::init_tempdir()’:
RInside.cpp:131: error: ‘runtime_error’ is not a member of ‘std’
RInside.cpp: In member function ‘void RInside::autoloads()’:
RInside.cpp:188: error: ‘Rcpp’ has not been declared
RInside.cpp:188: error: expected `;' before ‘delayed_assign_call’
RInside.cpp:194: error: ‘Rcpp’ has not been declared
RInside.cpp:194: error: expected `;' before ‘delayed_assign_name’
RInside.cpp:196: error: ‘Rcpp’ has not been declared
RInside.cpp:196: error: expected `;' before ‘autoloader_call’
RInside.cpp:200: error: ‘Rcpp’ has not been declared
RInside.cpp:200: error: expected `;' before ‘autoloader_name’
RInside.cpp:201: error: ‘Rcpp’ has not been declared
RInside.cpp:201: error: expected `;' before ‘autoloader_pack’
RInside.cpp:202: error: ‘delayed_assign_call’ was not declared in this scope
RInside.cpp:202: error: ‘autoloader_call’ was not declared in this scope
RInside.cpp:208: error: ‘autoloader_pack’ was not declared in this scope
RInside.cpp:214: error: ‘autoloader_name’ was not declared in this scope
RInside.cpp:217: error: ‘delayed_assign_name’ was not declared in this scope
RInside.cpp:228: error: ‘runtime_error’ is not a member of ‘std’
RInside.cpp: In member function ‘int RInside::parseEval(const std::string&,
SEXPREC*&)’:
RInside.cpp:234: error: ‘ParseStatus’ was not declared in this scope
RInside.cpp:234: error: expected `;' before ‘status’
RInside.cpp:243: error: ‘status’ was not declared in this scope
RInside.cpp:243: error: ‘R_ParseVector’ was not declared in this scope
RInside.cpp:246: error: ‘PARSE_OK’ was not declared in this scope
RInside.cpp:261: error: ‘PARSE_INCOMPLETE’ was not declared in this scope
RInside.cpp:264: error: ‘PARSE_NULL’ was not declared in this scope
RInside.cpp:269: error: ‘PARSE_ERROR’ was not declared in this scope
RInside.cpp:274: error: ‘PARSE_EOF’ was not declared in this scope
RInside.cpp: In member function ‘void RInside::parseEvalQ(const
std::string&)’:
RInside.cpp:291: error: ‘runtime_error’ is not a member of ‘std’
RInside.cpp: In member function ‘SEXPREC* RInside::parseEval(const
std::string&)’:
RInside.cpp:299: error: ‘runtime_error’ is not a member of ‘std’
RInside.cpp: At global scope:
RInside.cpp:304: error: ‘Rcpp’ has not been declared
RInside.cpp:304: error: expected constructor, destructor, or type conversion
before ‘RInside’
make: *** [RInside.o] Error 1
ERROR: compilation failed for package ‘RInside’
* removing ‘/Library/Frameworks/R.framework/Resources/library/RInside’
I do not understand what's going on to be honest.
Anyone can help me?
By the way i subscribed to the xcode forum for R
and i sent a message to : r-sig-mac at stat.math.ethz.ch.
But the message is replied to me without any answer.
Any Idea of what's going on?
--
View this message in context: http://n4.nabble.com/Embed-R-code-in-C-tp1677784p1678236.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help
mailing list