e1071安装R 3.1.2

时间:2014-12-21 22:59:29

标签: r libsvm

我正在尝试在R 3.1.2中安装e1071软件包。我的系统是linux 3.10.0-123.13.1.el7.x86_64。我尝试使用install.packages(" e1071",type =" source")从源代码安装,但它没有帮助。有没有人有建议?

* installing *source* package 'e1071' ...
** package 'e1071' successfully unpacked and MD5 sums checked
checking for C++ compiler default output file name... a.out
checking whether the C++ compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables... 
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
** libs
gcc -std=gnu99 -I/opt/local/stow/R-3.1.2/lib64/R/include -DNDEBUG  -I/usr/local/include    -fpic  -g -O2  -c Rsvm.c -o Rsvm.o
gcc -std=gnu99 -I/opt/local/stow/R-3.1.2/lib64/R/include -DNDEBUG  -I/usr/local/include    -fpic  -g -O2  -c cmeans.c -o cmeans.o
gcc -std=gnu99 -I/opt/local/stow/R-3.1.2/lib64/R/include -DNDEBUG  -I/usr/local/include    -fpic  -g -O2  -c cshell.c -o cshell.o
gcc -std=gnu99 -I/opt/local/stow/R-3.1.2/lib64/R/include -DNDEBUG  -I/usr/local/include    -fpic  -g -O2  -c floyd.c -o floyd.o
g++ -I/opt/local/stow/R-3.1.2/lib64/R/include -DNDEBUG  -I/usr/local/include    -fpic  -g -O2  -c svm.cpp -o svm.o
In file included from /usr/include/stdio.h:934:0,
                 from /opt/local/stow/R-3.1.2/lib64/R/include/R.h:29,
                 from svm.cpp:1:
/usr/include/bits/stdio.h: In function '__ssize_t getline(char**, size_t*, FILE*)':
/usr/include/bits/stdio.h:117:52: error: '__getdelim' was not declared in this scope
make: *** [svm.o] Error 1
ERROR: compilation failed for package 'e1071'

Warning message:
In install.packages("e1071", dep = T) :
  installation of package 'e1071' had non-zero exit status

1 个答案:

答案 0 :(得分:0)

尝试

sudo yum install R-devel

sudo apt-get install R-devel

第一