嗨,我正在尝试在 mac osx 上编译和运行简单的 RInside 示例。我正在使用 R 安装形式的 macports 和通过 R 安装的 RInside 以及所有库的最新版本,这是我的 R 信息
R version 2.15.1 (2012-06-22) -- "Roasted Marshmallows"
Copyright (C) 2012 The R Foundation for Statistical Computing
Platform: x86_64-apple-darwin11.4.0/x86_64 (64-bit)
这是我尝试编译示例的方法
g++-mp-4.7 -I/opt/local/lib/R/library/RInside/include/
-I/opt/local/lib/R/library/Rcpp/include/ -I/opt/local/lib/R/include/ -L/opt/local/lib/R/library/RInside/libs/ -L/opt/local/lib/R/library/Rcpp/libs/ -lRInside -lRcpp test.cpp -o test
这是我的错误
In file included from /opt/local/lib/R/library/Rcpp/include/RcppCommon.h:155:0,
from /opt/local/lib/R/library/Rcpp/include/Rcpp.h:27,
from /opt/local/lib/R/library/RInside/include/RInsideCommon.h:31,
from /opt/local/lib/R/library/RInside/include/RInside.h:26,
from thread_safe_test.cpp:5:
/opt/local/lib/R/include/R.h:34:21: fatal error: Rconfig.h: No such file or directory
compilation terminated.
有什么建议么