2

我正在尝试在 Cloudera 的 CDH4 Hadoop VM 上安装 RHadoop。RHadoop 是一个通过 R 编程接口使用 Hadoop 的框架。安装 RHadoop R 包“rmr”的先决条件之一是另一个名为 Rcpp 的 R 包,它用于从 R 调用 C++ 代码。当我尝试安装该包时,出现以下错误。我联系了 Rcpp 和 RHadoop 社区,都说这是 GCC 问题。当我尝试更新或重新安装 GCC 时,我得到“包 gcc-4.4.6-4.e16.x86_64 已安装且最新版本,无事可做。” 有什么建议么?

这是错误(来自 R 命令行)。

> install.packages("Rcpp")
Installing package(s) into ‘/usr/lib64/R/library’
(as ‘lib’ is unspecified)
--- Please select a CRAN mirror for use in this session ---
Loading Tcl/Tk interface ... done
 trying URL 'http://cran.csdb.cn/src/contrib/Rcpp_0.9.15.tar.gz'
Content type 'application/x-gzip' length 2119769 bytes (2.0 Mb)
opened URL
 ==============================
====================
downloaded 2.0 Mb

* installing *source* package ‘Rcpp’ ...
** package ‘Rcpp’ successfully unpacked and MD5 sums checked
** libs
g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c Date.cpp -o Date.o
 g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c DateVector.cpp -o DateVector.o
 g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c Datetime.cpp -o Datetime.o
 g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c DatetimeVector.cpp -o DatetimeVector.o
 g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c Dimension.cpp -o Dimension.o
 g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c DottedPair.cpp -o DottedPair.o
 g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c Environment.cpp -o Environment.o
 g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c Evaluator.cpp -o Evaluator.o
 g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c Formula.cpp -o Formula.o
 g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c Function.cpp -o Function.o
 g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c Language.cpp -o Language.o
 g++ -m64 -I/usr/include/R -DNDEBUG -I../inst/include/ -I/usr/local/include    -fpic  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -c Module.cpp -o Module.o
 {standard input}: Assembler messages:
{standard input}:10671: Warning: end of file not at end of a line; newline inserted
{standard input}:11544: Error: bad register name `%'
{standard input}:11544: Error: open CFI at the end of file; missing .cfi_endproc directive
 g++: Internal error: Killed (program cc1plus)
Please submit a full bug report.
See <http://bugzilla.redhat.com/bugzilla> for instructions.
make: *** [Module.o] Error 1
 ERROR: compilation failed for package ‘Rcpp’
* removing ‘/usr/lib64/R/library/Rcpp’

The downloaded source packages are in
    ‘/tmp/RtmpGdXO9h/downloaded_packages’
Updating HTML index of packages in '.Library'
 Making packages.html  ... done
Warning message:
In install.packages("Rcpp") :
  installation of package ‘Rcpp’ had non-zero exit status
4

1 回答 1

4

作为 Rcpp 的作者之一,我可以保证错误可能在您的最后,并且可能是 gcc(不太可能)或 CDH。Rcpp 在 CRAN 上构建和重建了无数次(是的,有一些页面总结了 CRANDebian上的构建。该软件包通常不会杀死编译器。

你会用完盒子上的内存吗?

于 2012-10-26T03:06:13.163 回答