昨天下载了最最新的qterm-0.5.2,可是怎么编译都是报错,意思是说找不到abs函数,可abs函数明明就是在stdlib.h中阿。
报错信息如下:
[64%]BuildingCXXobjectsrc/CMakeFiles/qterm.dir/qtermbbs.o
/rocrocket/PSB/software/src/qterm-0.5.2/src/qtermbbs.cpp:Inmemberfunction‘boolQTerm::BBS::checkUrl(QRect&,QRect&,bool)’:
/rocrocket/PSB/software/src/qterm-0.5.2/src/qtermbbs.cpp:459:warning:suggestexplicitbracestoavoidambiguous‘else’
[65%]BuildingCXXobjectsrc/CMakeFiles/qterm.dir/qtermbuffer.o
/rocrocket/PSB/software/src/qterm-0.5.2/src/qtermbuffer.cpp:Inmemberfunction‘voidQTerm::Buffer::shiftStr(int,int,int,int)’:
/rocrocket/PSB/software/src/qterm-0.5.2/src/qtermbuffer.cpp:284:error:‘abs’wasnotdeclaredinthisscope
/rocrocket/PSB/software/src/qterm-0.5.2/src/qtermbuffer.cpp:Inmemberfunction‘QRectQTerm::Buffer::getSelectRect(int,bool)’:
/rocrocket/PSB/software/src/qterm-0.5.2/src/qtermbuffer.cpp:640:error:‘abs’wasnotdeclaredinthisscope
make[2]:***[src/CMakeFiles/qterm.dir/qtermbuffer.o]Error1
make[1]:***[src/CMakeFiles/qterm.dir/all]Error2
make:***[all]Error2
解决办法:
将qtermbuffer.cpp中的abs都替换为qAbs即可!
两个教训:
一是“一定仔细看出错信息”!
二是“别以为源码包没有错”!!
出自Linux,ThoughtsandLifes-rocrocket
解决fedora9中编译安装qterm-0.5.2的故障解决fedora9中编译安装qterm-0.5.2的故障解决fedora9中编译安装qterm-0.5.2的故障解决fedora9中编译安装qterm-0.5.2的故障解决fedora9中编译安装qterm-0.5.2的故障解决fedora9中编译安装qterm-0.5.2的故障解决fedora9中编译安装qterm-0.5.2的故障解决fedora9中编译安装qterm-0.5.2的故障解决fedora9中编译安装qterm-0.5.2的故障解决fedora9中编译安装qterm-0.5.2的故障
阅读(206) | 评论(0) | 转发(0) |