在构建成功时,Eclipse(CDT)中出现错误的错误消息 [英] Dubious error messages in Eclipse (CDT) while build succeeds

查看:579
本文介绍了在构建成功时,Eclipse(CDT)中出现错误的错误消息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

使用 g ++ 4.1.2 (位于)上的 Eclipse IDE for C / C ++ Linux Developers (版本: Indigo 科学Linux CERN 5 = RHEL 5),我目前正在开发一个项目,其中我使用 Qt4 GUI以及Apache的 log4cxx 框架和一些C ++标准类。
我已经安装了诺基亚的Qt Eclipse Integration for C ++插件,它自动配置Qt工具链支持(qmake等)。

Using the Eclipse IDE for C/C++ Linux Developers (Version: Indigo Release) with g++ 4.1.2 (on Scientific Linux CERN 5 = RHEL 5), I currently work on a project where I make use of a Qt4 GUI as well as Apache's log4cxx framework and of some C++ standard classes. I have installed Nokia's "Qt Eclipse Integration for C++" plugin, which automatically configured Qt toolchain support (qmake, etc.).

到目前为止,我一切都在运行。我的程序编译得很好。除了一些警告(这是合理的),我观察到一个成功的构建过程在Eclipse的控制台。
不幸的是,同时我在问题窗口中收到大约150条错误消息。

Up until now I got everything running. My program compiles well. Except for some warnings (which are reasonable), I observe a successful build process on Eclipse's console. Unfortunatetly, at the same time I get about 150 error messages in the "Problems" window.

例如:

using namespace log4cxx;

我得到

Symbol log4cxx could not be resolved

std::vector<View*>& Model::GetRegisteredViews() { ... }

我得到

Symbol vector could not be resolved

Member declaration not found  
    (-> of GetRegisteredViews() although the decl. is available,  
    code compiles!)

所有错误消息也在编辑器窗口中标注了注释符号,这是相当恼人。

All error messages are also marked with annotation symbols in the editor window, which is quite annoying.

从stackoverflow论坛我了解到,它可能与我有两个版本的gcc安装的事实,即 4.1.2 4.4 。我已经卸载了4.4(使用RHEL的包管理系统,yum) - 没有成功。

From the stackoverflow forums I have learned that it might have to do with the fact that I had two versions of gcc installed, namely 4.1.2 and 4.4. I have already uninstalled 4.4 (using the package management system of RHEL, yum) - without success.

它可能也与索引器有关,但坦率地说,我没有从哪里开始解决这个问题。

It might also have to do with the indexer, but frankly I have no idea where to start fixing this problem.

对我来说,看起来Eclipse缺少一些include或者库路径条目,但是这两个都在Qt pro文件中提及,以及在Eclipse的项目设置...

To me, it looks like Eclipse misses some include or library path entries, but both are mentioned in the Qt pro file as well as in Eclipse's project settings...

您的帮助将非常感谢,
谢谢您的意见!

Your help would be highly appreciated, thank you for your comments!

推荐答案

这不是Qt 本身 - 这是CDT Indexer和Qt Eclipse集成插件战斗。我发现执行干净有时重置CDT项目设置中的包含列表(只有这与Qt集成插件运行),但是因为Qt使用.pro文件 - 编译成功,但CDT的CODAN(使用Eclipse项目设置)抛出一个合适。

It's not Qt per se - it's the CDT Indexer and the Qt Eclipse Integration plugin fighting. I find that performing a clean sometimes 'resets' the includes list in CDT project settings (only does this with Qt integration plugin running), but because Qt uses the .pro file - the compilation succeeds but CDT's CODAN (which uses the Eclipse project settings) throws a fit.

这是激烈的刺激,我还没有找到一个修复。还有Qt没有更新Qt Eclipse集成一段时间,他们希望人们使用Qt Creator - 但它是可怕的一般开发。

It's intensely irritating, and I haven't found a fix. Also Qt haven't updated the Qt Eclipse Integration for awhile, they want people to use Qt Creator - but it's awful for general development.

这篇关于在构建成功时,Eclipse(CDT)中出现错误的错误消息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆