rhipe安装错误:包'Rhipe'

时间:2015-10-29 09:03:12

标签: r

我是新手,我正在尝试在centos 6.2上安装Rhipe-0.74。我收到了以下错误。

    [root@hadoop-master Rhipe]# R CMD INSTALL Rhipe_0.74.0.tar.gz 
* installing to library ‘/usr/lib64/R/library’
* installing *source* package ‘Rhipe’ ...
** libs
g++ -m64 -I/usr/include/R -DNDEBUG  -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  -I.  -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic  -DUSEAUTOSHORT -DHAVE_UINTPTR_T    `/usr/lib64/R/bin/R CMD config --cppflags` `pkg-config --cflags protobuf` -c rexp.pb.cc -o rexp.pb.o
In file included from rexp.pb.cc:4:
rexp.pb.h:17:2: error: #error This file was generated by an older version of protoc which is
rexp.pb.h:18:2: error: #error incompatible with your Protocol Buffer headers. Please
rexp.pb.h:19:2: error: #error regenerate this file with a newer version of protoc.
In file included from rexp.pb.cc:4:
rexp.pb.h: In member function ‘void REXP::clear_rawvalue()’:
rexp.pb.h:672: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h: In member function ‘void REXP::set_rawvalue(const std::string&)’:
rexp.pb.h:682: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h: In member function ‘void REXP::set_rawvalue(const char*)’:
rexp.pb.h:689: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h: In member function ‘void REXP::set_rawvalue(const void*, size_t)’:
rexp.pb.h:696: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h: In member function ‘std::string* REXP::mutable_rawvalue()’:
rexp.pb.h:703: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h: In member function ‘std::string* REXP::release_rawvalue()’:
rexp.pb.h:710: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h:714: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h: In member function ‘void STRING::clear_strval()’:
rexp.pb.h:853: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h: In member function ‘void STRING::set_strval(const std::string&)’:
rexp.pb.h:863: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h: In member function ‘void STRING::set_strval(const char*)’:
rexp.pb.h:870: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h: In member function ‘void STRING::set_strval(const char*, size_t)’:
rexp.pb.h:877: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h: In member function ‘std::string* STRING::mutable_strval()’:
rexp.pb.h:884: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h: In member function ‘std::string* STRING::release_strval()’:
rexp.pb.h:891: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.h:895: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.cc: In member function ‘void REXP::SharedCtor()’:
rexp.pb.cc:256: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.cc: In member function ‘void REXP::SharedDtor()’:
rexp.pb.cc:265: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.cc: In member function ‘virtual void REXP::Clear()’:
rexp.pb.cc:296: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.cc: In member function ‘void STRING::SharedCtor()’:
rexp.pb.cc:905: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.cc: In member function ‘void STRING::SharedDtor()’:
rexp.pb.cc:915: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
rexp.pb.cc: In member function ‘virtual void STRING::Clear()’:
rexp.pb.cc:945: error: ‘kEmptyString’ is not a member of ‘google::protobuf::internal’
make: *** [rexp.pb.o] Error 1
ERROR: compilation failed for package ‘Rhipe’
* removing ‘/usr/lib64/R/library/Rhipe’

据我所知,问题是由于多个protobuf安装造成的。我用Google搜索但仍然无法解决问题。请帮我解决这个问题。任何帮助将不胜感激。提前谢谢。

1 个答案:

答案 0 :(得分:0)

也许有点晚了,但我遇到了同样的问题,并设法通过在CentOS 7中使用protobuf版本2.5.0和RHipe v0.75.1.3来安装它。

您可以从here下载此版本的protobuf。复制/usr/local/lib中的tar.gz并按照自述文件中的说明进行操作(基本上,解压缩并执行./configuremakemake install)。

之后,设置所需的hadoop环境变量(PKG_CONFIG_PATH需要指向/usr/local/lib/pkgconfig,或者指向安装Protobuf的文件夹)。最后,安装RHipe包。您可以从here下载旧版本的RHipe。

干杯。