-
Notifications
You must be signed in to change notification settings - Fork 187
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
编译遇到问题 #17
Comments
您好,我们是使用的thrift 0.8
…------------------ Original message ------------------
From: "Xuejian";
Sendtime: Saturday, Apr 25, 2020 9:19 PM
To: "Meituan-Dianping/octo-rpc";
Cc: "Subscribed";
Subject: [Meituan-Dianping/octo-rpc] 编译遇到问题 (#17)
你好,我在尝试用c++编译whale,遇到了一个问题,编译error如下:
octoidl/include/octoidl/ServiceAgent.h:705:55: error: invalid covariant return type for 'virtual boost::shared_ptr meituan_mns::ServiceAgentProcessorFactory::getProcessor(const apache::thrift::TConnectionInfo
&)'
::boost::shared_ptr< ::apache::thrift::TProcessor > getProcessor(const ::apache::thrift::TConnectionInfo& connInfo);
^
In file included from external/cpp3rd_lib/thrift/include/thrift/transport/TFileTransport.h:25:0,
from external/cpp3rd_lib/thrift/include/thrift/transport/TTransportUtils.h:30,
from whale/cthrift/util/cthrift_common.h:54,
from whale/cthrift/util/cthrift_common.cc:26:
external/cpp3rd_lib/thrift/include/thrift/TProcessor.h:215:42: error: overriding 'virtual std::shared_ptrapache::thrift::TProcessor apache::thrift::TProcessorFactory::getProcessor(const apache::thrift::TConnectionInfo&)'
virtual stdcxx::shared_ptr getProcessor(const TConnectionInfo& connInfo) = 0;
好像是因为我用的thrift0.12是采用的c++11标准,智能指针用的标准库。你们这个用的boost。你们的octoidl源码公开了嘛?这里只有静态库没有源代码。你们工程中thrift用的哪个版本?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
谢谢,现在我应该遇到了编译的最后一个问题了,error描述如下: |
thrift版本的问题,我们使用的是0.8.0版本,如果thrift高于这个版本比如 0.9.2 或者 0.10.0等在编译的时候会遇到这种问题 |
cd thrift-0.9.3/0.14.0 vim ./lib/cpp/src/thrift/transport/TSocket.h /**
* Constructs a new socket. Note that this does NOT actually connect the
* socket.
*
* @param host An IP address or hostname to connect to
* @param port The port to connect on
*/
//TSocket(const std::string& host, int port);
TSocket(std::string host, int port); // for jianrong 0.8.0 对应 TSocket.cpp 也改一下;
[root@863ef6858c3a thrift-0.9.3.2]# ./configure --with-qt4=no --with-c_glib=no --with-csharp=no --with-erlang=no --with-perl=no --with-ruby=no --with-haskell=no --with-java=no --enable-tests=no --enable-tutorial=no && make -j 4 && make install |
你好,我在尝试用c++编译whale,遇到了一个问题,编译error如下:
octoidl/include/octoidl/ServiceAgent.h:705:55: error: invalid covariant return type for 'virtual boost::shared_ptr meituan_mns::ServiceAgentProcessorFactory::getProcessor(const apache::thrift::TConnectionInfo
&)'
::boost::shared_ptr< ::apache::thrift::TProcessor > getProcessor(const ::apache::thrift::TConnectionInfo& connInfo);
^
In file included from external/cpp3rd_lib/thrift/include/thrift/transport/TFileTransport.h:25:0,
from external/cpp3rd_lib/thrift/include/thrift/transport/TTransportUtils.h:30,
from whale/cthrift/util/cthrift_common.h:54,
from whale/cthrift/util/cthrift_common.cc:26:
external/cpp3rd_lib/thrift/include/thrift/TProcessor.h:215:42: error: overriding 'virtual std::shared_ptrapache::thrift::TProcessor apache::thrift::TProcessorFactory::getProcessor(const apache::thrift::TConnectionInfo&)'
virtual stdcxx::shared_ptr getProcessor(const TConnectionInfo& connInfo) = 0;
好像是因为我用的thrift0.12是采用的c++11标准,智能指针用的标准库。你们这个用的boost。你们的octoidl源码公开了嘛?这里只有静态库没有源代码。你们工程中thrift用的哪个版本?
The text was updated successfully, but these errors were encountered: