0

ubuntu でスクライブ サーバーをコンパイルしているときに、次のエラーが発生します。

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:18: 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 ‘virtual bool ThriftFileStore::openInternal(bool, tm*)’

thrift 0.7.0 で scribe 2.2 を使用しています。thrift のインストール中にエラーは発生しませんでした。

また、古いバージョンのthriftを使用しているときにこのエラーが発生するという投稿を1つ読みました。しかし、私はthriftの最新バージョンを使用しています。

4

1 に答える 1

0

倹約からの問題のようです。

解決策: thrift 安定版を使用する

Ying-Yi Liang の言葉を文字通りコピーする:

「この問題は、thrift の最近の変更 (git dev バージョン) と関係があると思います。thrift スニペットの場合: enum X { ... } X foo(); thrift は、foo のこのプロトタイプを生成するために使用されます: X foo(); ですが、「X::type foo();」が生成され、発生したエラーが発生します。」

ここで回答: http://groups.google.com/group/scribe-server/msg/b17bda3b80706558

于 2011-12-21T00:26:36.730 に答える