eclipse-cdt

Warning: corrupt .drectve at end of def file

好久不见. 提交于 2019-12-23 07:57:18
问题 I installed glew, glfw and glm in eclipse cdt(c++) with the gcc/mingw, all statically. All works fine, but I don't like the warning in the output console of eclipse: Warning: corrupt .drectve at end of def file How I can fix and hide this warning ? What does it mean ? And what I noticed is, that this warning comes only, if I call the 'glewInit' function. 回答1: When I ran into this problem it was because I was linking against incompatible MSVC libs. A comment by keltar helped me through this

What is the meaning of this decorated folder icon in Eclipse/CDT project explorer?

纵饮孤独 提交于 2019-12-23 07:05:03
问题 What does this special folder icon in CDT/Eclipse project explorer mean? The bluish thingy looks like a key or screw or some kind of tool. I guess it has something to do with CVS. I couldn't find the info in the Preferences > Appearance > Label Decorations settings. 回答1: The wrench icon over a folder or file means that it is overriding some of the build settings inherited from its parent. If it's there by accident, you most likely right-clicked that folder instead of the entire project and

How to do static analysis for C++ code with Eclipse cdt?

99封情书 提交于 2019-12-23 05:59:15
问题 I need to get the static information of C++ program with CDT. No need to build the project, just to get the basic information(namespace, class, extends relation, method, call, field) and save them to database. Is there any code examples or opensource plugin? thx! I have tried a lot of methods but they do not work very well. someone says that codan is a choice, but it doesn't work on my environment... PS: CDT is necessary. I use Eclipse Indigo. 回答1: Eclipse CDT has already built-in tools for

How to do static analysis for C++ code with Eclipse cdt?

╄→尐↘猪︶ㄣ 提交于 2019-12-23 05:58:49
问题 I need to get the static information of C++ program with CDT. No need to build the project, just to get the basic information(namespace, class, extends relation, method, call, field) and save them to database. Is there any code examples or opensource plugin? thx! I have tried a lot of methods but they do not work very well. someone says that codan is a choice, but it doesn't work on my environment... PS: CDT is necessary. I use Eclipse Indigo. 回答1: Eclipse CDT has already built-in tools for

Eclipse Debug run and console run of the same program give different outputs

旧城冷巷雨未停 提交于 2019-12-23 05:44:12
问题 So this is in reference to my older question which I fixed. Now the issue is that when I run my program (code as follows)... #include <stdio.h> #include <memory.h> #include <string> #include <iostream> using namespace std; #include "timesync.h" FILE * CTimeSync::pipe = NULL; int CTimeSync::TimeSyncCheck() { char szPipeBuffer [200]; string strPipeOutput; memset( szPipeBuffer, 0, sizeof(szPipeBuffer) ); CTimeSync::pipe = popen( "ntpq -np", "r" ); if ( CTimeSync::pipe ) { while ( !feof(

Eclipse not finding std c++ libraries

耗尽温柔 提交于 2019-12-22 09:24:27
问题 I have a Windows8 machine with mingw installed in c:\mingw Eclipse does successfully compile programs, but it considers lines to contain errors that are fine when compiled. Eclipse is not finding the libraries itself. When I first build a project in eclipse with the CDT components install, it shows errors on every #include and every line using an object. Example: #include <iostream> using namespace std; int main() { cout << "hello\n"; } The above code shows errors on the include, the using

How can I do the instruction level debugging with CDT

我怕爱的太早我们不能终老 提交于 2019-12-22 07:07:31
问题 I am using CDT for developing C programs. When the debugger stops on a break point and I do "Step Over" or "Step Into" the debugger behaviour is based on the source line level but not on the instruction level. Can I do debugging on the instruction level in CDT? 回答1: In the Debug window (Debug perspective) there is an Instruction Stepping Mode button: It looks like a small i with an arrow i=> ). You can also set breakpoints on specific instructions in the Disassembly window. 回答2: As far as I

How can I do the instruction level debugging with CDT

。_饼干妹妹 提交于 2019-12-22 07:07:10
问题 I am using CDT for developing C programs. When the debugger stops on a break point and I do "Step Over" or "Step Into" the debugger behaviour is based on the source line level but not on the instruction level. Can I do debugging on the instruction level in CDT? 回答1: In the Debug window (Debug perspective) there is an Instruction Stepping Mode button: It looks like a small i with an arrow i=> ). You can also set breakpoints on specific instructions in the Disassembly window. 回答2: As far as I

cmake and eclipse: default include paths?

╄→гoц情女王★ 提交于 2019-12-22 04:07:59
问题 I have a project that builds with CMake system, and I like to import it in Eclipse. However, when I generate eclipse project files with 'cmake -G "Eclipse CDT4 - Unix Makefiles"' there are no default include paths in Eclipse project(such as /usr/include' or the gcc path for standard headers). How to fix that in most right way? System: linux gcc 4.3.3 cmake 2.6.4 eclipse 3.5.1 回答1: You have to go to the project properties (right button over the project), "C/C++ include paths and symbols" and

Eclipse CDT syntax error on __attribute__ keyword

醉酒当歌 提交于 2019-12-21 23:56:34
问题 I would like to know if there is a way to get rid of CDT syntax error warnings when using gcc's " __attribute__ " keyword. It goes without saying that I would not like to switch off CDT syntax check. 回答1: The "ECLIPSE_THINKS_THIS_IS_SET_BUT_GCC_DOESNT" definition (from ams 's answer) really extsts and it called __CDT_PARSER__ . For example: #ifdef __CDT_PARSER__ #define __FILE__ "<file>" #define __LINE__ (-1) #define __DATE__ "<date>" #define __TIME__ "<time>" #endif // #ifdef __CDT_PARSER__