2

我首先提出了一个配置命令:

我懂了:

milind@ubuntu:~/scribe$ ./configure CPPFLAGS="-DHAVE_INTTYPES_H -DHAVE_NETINET_IN_H -    DBOOST_FILESYSTEM_VERSION=2 -DHAVE_NETDB_H=1 -fpermissive"

checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... no
checking for mawk... mawk
checking whether make sets $(MAKE)... yes
checking for style of include used by make... GNU    
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking dependency style of gcc... gcc3
checking dependency style of gcc... (cached) gcc3
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking dependency style of g++... (cached) gcc3
checking for ranlib... ranlib
checking for bash... /bin/sh
checking for perl... /usr/bin/perl
checking for python... /usr/bin/python
checking for ar... /usr/bin/ar
checking for ant... no
checking Checking EXTERNAL_PATH set to... /home/milind/scribe
checking whether to enable optimized build... yes
checking whether to enable static mode... yes
checking whether to enable FACEBOOK... no
checking whether to enable USE_SCRIBE_HDFS... no
checking Checking thrift_home set to... /usr/local
checking Checking fb303_home set to... /usr/local
checking Checking smc_home set to... /home/milind/scribe/services/trunk/src
checking Checking fb_home set to... /home/milind/scribe/libfacebook
checking Checking hadoop_home set to... /usr/local
checking for boostlib >= 1.36... yes
checking build system type... i686-pc-linux-gnu
checking whether the Boost::System library is available... yes
checking for exit in -lboost_system-mt... yes
checking whether the Boost::Filesystem library is available... yes
checking for exit in -lboost_filesystem-mt... yes
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating lib/py/Makefile
config.status: executing depfiles commands
EXTERNAL_PATH /home/milind/scribe

现在,当我运行 make 命令时,输出显示:

milind@ubuntu:~/scribe$ make
make  all-recursive
make[1]: Entering directory `/home/milind/scribe'
Making all in .
make[2]: Entering directory `/home/milind/scribe'
make[2]: Nothing to be done for `all-am'.
make[2]: Leaving directory `/home/milind/scribe'
Making all in src
make[2]: Entering directory `/home/milind/scribe/src'
make  all-am
make[3]: Entering directory `/home/milind/scribe/src'
g++ -DPACKAGE_NAME=\"scribe\" -DPACKAGE_TARNAME=\"scribe\" -DPACKAGE_VERSION=\"1.5.0\" -DPACKAGE_STRING=\"scribe\ 1.5.0\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE_URL=\"\" -DPACKAGE=\"scribe\" -DVERSION=\"1.5.0\" -DHAVE_BOOST=/\*\*/ -DHAVE_BOOST_SYSTEM=/\*\*/ -DHAVE_BOOST_FILESYSTEM=/\*\*/ -I.  -I.. -I/usr/local/include -I/usr/local/include/thrift -I/usr/local/include/thrift -I/usr/local/include/thrift/fb303 -I/usr/local/include -I/usr/include   -DHAVE_INTTYPES_H -DHAVE_NETINET_IN_H -DBOOST_FILESYSTEM_VERSION=2 -DHAVE_NETDB_H=1 -fpermissive  -Wall -O3 -MT store.o -MD -MP -MF .deps/store.Tpo -c -o store.o store.cpp
In file included from store.cpp:27:
scribe_server.h:45: error: conflicting return type specified for ‘virtual     scribe::thrift::ResultCode scribeHandler::Log(const std::vector<scribe::thrift::LogEntry, std::allocator<scribe::thrift::LogEntry> >&)’
../src/gen-cpp/scribe.h:19: error:   overriding ‘virtual    scribe::thrift::ResultCode::type scribe::thrift::scribeIf::Log(const std::vector<scribe::thrift::LogEntry, std::allocator<scribe::thrift::LogEntry> >&)’
store.cpp: In member function ‘bool   FileStore::writeMessages(boost::shared_ptr<std::vector<boost::shared_ptr<scribe::thrift::LogEntry>, std::allocator<boost::shared_ptr<scribe::thrift::LogEntry> > > >, boost::shared_ptr<FileInterface>)’:
store.cpp:786: warning: format ‘%lu’ expects type ‘long unsigned int’, but argument 5 has type ‘size_t’
store.cpp: In member function ‘virtual bool  FileStore::readOldest(boost::shared_ptr<std::vector<boost::shared_ptr<scribe::thrift::LogEntry>, std::allocator<boost::shared_ptr<scribe::thrift::LogEntry> > > >, tm*)’:
store.cpp:916: warning: format ‘%lu’ expects type ‘long unsigned int’, but argument 5 has type ‘size_t’
store.cpp: In member function ‘virtual bool ThriftFileStore::openInternal(bool, tm*)’:
store.cpp:1109: warning: ignoring return value of ‘int symlink(const char*, const char*)’, declared with attribute warn_unused_result
store.cpp: In member function ‘virtual void BufferStore::periodicCheck()’:
store.cpp:1411: warning: format ‘%lu’ expects type ‘long unsigned int’, but argument 5 has type ‘size_t’
make[3]: *** [store.o] Error 1
make[3]: Leaving directory `/home/milind/scribe/src'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/home/milind/scribe/src'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/milind/scribe'
make: *** [all] Error 2

我安装了所有依赖包,如 libevent-dev、boost 并且它们位于默认路径中。即使在明确指定了各个路径之后,它也不起作用。我在某处读到这可能发生在旧版本的 thrift 上,但我使用的是最新的稳定版本。

有人可以帮忙吗?

4

0 回答 0