RedHat 6.0下eclipse IDE一朵奇葩
我在RedHat 6.0安装 eclipse juno SR2.并编写class 继承 ACE_TASK:#include "ace/OS.h"
#include "ace/Task.h"
class DBPro : public ACE_Task<ACE_MT_SYNCH>{
public:
DBPro();
virtual ~DBPro();
};
So , Project-->Build All.
在eclipse Console Window 显示:
Invoke:GCC C++ Compiler
g++ -I/usr/include/c++ -I/usr/include/c++/4.4.4 -I/usr/include/c++/4.4.4/x86_64-redhat-linux -I/opt/ACE_wrapper -O0 -g3 -Wall -c -fmessage-length=0 -MMD -MP -MF
"src/DBPro.d" -o "src/DBPro.o" "../src/DBPro.cpp"
Finish building:../src/DBPro.cpp
Build target: Measure System
Invoking: GCC C++ Linker
g++ -L/opt/ACE_wrappers/lib -o "MessageSystem" ./src/DBPro.o ./src/Main.o -lACE
Finish build target: MeasureSystem.
但是在eclipse Problems Window 显示 :
1)Invalid template arguments
Type 'ACE_MT_SYNCH' Could not be resolved
? 为什么 eclipse 报告错误 : Type 'ACE_MT_SYNCH' Could not be resolved????
你查一下那个文件定义了ACE_MT_SYNCH,记得应该包含
#include "ace/Task_t.h"
我查了 ACE_MT_SYNCH,定义在ace/Synch_Traits.h中,
我加入 #include "ace/Synch_Traits.h"也是不成。
现在问题在于:
g++ 编译是成功的,但在eclipse IDE中报错~~~ 我想那应该与eclipse环境相关了。重点检查编译路径
页:
[1]