在Ubuntu上安装rpy2 [英] rpy2 installation on Ubuntu
问题描述
我对Linux很陌生,在安装Rpy2时遇到了一些严重的麻烦.我的突触包管理器安装了较旧的Rpy2版本,但我需要一个更新的版本并将其删除(如Rpy2文档中所述,Rpy2目录中的所有文件). 我下载了tar.gz.从SourceForge并运行以下代码:
I'm pretty new to Linux and I'm having some serious trouble installing Rpy2. I had an older versions of Rpy2 installed by the synaptic package manager, but I needed an updated version and removed it (all files in the Rpy2 directory as described in the Rpy2 documentation). I downloaded the tar.gz. from SourceForge and ran this code:
tar -xzf rpy2-2.1.8.tar.gz
cd rpy2-2.1.8
python setup.py build install
似乎正在复制文件,但是随后出现多页错误消息(突出显示为粗体):
It appeared to be copying files as it should, but then multiple pages of error messages (highlighted in bold) just start floating:
running build_ext
Configuration for R as a library:
include_dirs: ('/usr/share/R/include',)
libraries: ('lapack', 'blas', 'R')
library_dirs: ('/usr/lib/R/lib',)
extra_link_args: ()
# OSX-specific (included in extra_link_args)
framework_dirs: ()
frameworks: ()
building 'rpy2.rinterface.rinterface' extension
creating build/temp.linux-i686-2.6
creating build/temp.linux-i686-2.6/rpy
creating build/temp.linux-i686-2.6/rpy/rinterface
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes
-fPIC -DR_INTERFACE_PTRS=1 -DHAVE_POSIX_S
IGJMP=1 -DCSTACK_DEFNS=1 -DRIF_HAS_RSIGHAND=1 -Irpy/rinterface -I/usr/include/python2.6 -I/usr/share/R/include -c rpy/rinterface/rinterface.c -o build/temp.linux-i686-2.6/rpy/rinterface/rinterface.o
**rpy/rinterface/rinterface.c:55:20: error: Python.h: No such file or directory**
In file included from rpy/rinterface/rinterface.c:74:
/usr/share/R/include/R_ext/Rdynload.h:26: warning: function declaration isn’t a prototype
希望您能帮助我.
谢谢,拉瑟
推荐答案
系统上似乎没有python-dev
软件包.
It looks like you do not have python-dev
package on your system.
这篇关于在Ubuntu上安装rpy2的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!