ubuntu 16.04安装时报错

iftqt5_la-moc__TQTcpServer.Tpo -c src/thrift/qt/moc__TQTcpServer.cpp  -fPIC -DPIC -o src/thrift/qt/.libs/libthriftqt5_la-moc__TQTcpServer.o
src/thrift/qt/moc__TQTcpServer.cpp:13:2: error: #error "This file was generated using the moc from 4.8.7. It"
 #error "This file was generated using the moc from 4.8.7. It"
  ^
src/thrift/qt/moc__TQTcpServer.cpp:14:2: error: #error "cannot be used with the include files from this version of Qt."
 #error "cannot be used with the include files from this version of Qt."
  ^
src/thrift/qt/moc__TQTcpServer.cpp:15:2: error: #error "(The moc has changed too much.)"
 #error "(The moc has changed too much.)"
  ^
src/thrift/qt/moc__TQTcpServer.cpp:63:7: error: ‘QMetaObjectExtraData’ does not name a type
 const QMetaObjectExtraData apache::thrift::async::TQTcpServer::staticMetaObjectExtraData = {
       ^
src/thrift/qt/moc__TQTcpServer.cpp:65:2: warning: extra ‘;’ [-Wpedantic]
 };
  ^
src/thrift/qt/moc__TQTcpServer.cpp:69:57: error: ‘staticMetaObjectExtraData’ was not declared in this scope
       qt_meta_data_apache__thrift__async__TQTcpServer, &staticMetaObjectExtraData }
                                                         ^
src/thrift/qt/moc__TQTcpServer.cpp: In member function ‘virtual const QMetaObject* apache::thrift::async::TQTcpServer::metaObject() const’:
src/thrift/qt/moc__TQTcpServer.cpp:78:71: error: conditional expression between distinct pointer types ‘QDynamicMetaObjectData*’ and ‘const QMetaObject*’ lacks a cast
     return QObject::d_ptr->metaObject ? QObject::d_ptr->metaObject : &staticMetaObject;
                                                                       ^

问题根源:

thrift使用的qt版本有4.X和 5.x,版本不兼容导致。

 

解决方案:

禁用qt5

./configure --with-qt5=no

posted @   hbg-rohens  阅读(289)  评论(0编辑  收藏  举报
编辑推荐:
· Linux系列:如何用heaptrack跟踪.NET程序的非托管内存泄露
· 开发者必知的日志记录最佳实践
· SQL Server 2025 AI相关能力初探
· Linux系列:如何用 C#调用 C方法造成内存泄露
· AI与.NET技术实操系列(二):开始使用ML.NET
阅读排行:
· 被坑几百块钱后,我竟然真的恢复了删除的微信聊天记录!
· 没有Manus邀请码?试试免邀请码的MGX或者开源的OpenManus吧
· 【自荐】一款简洁、开源的在线白板工具 Drawnix
· 园子的第一款AI主题卫衣上架——"HELLO! HOW CAN I ASSIST YOU TODAY
· Docker 太简单,K8s 太复杂?w7panel 让容器管理更轻松!
点击右上角即可分享
微信分享提示