Public Group

# Debugging With Dev-C++

This topic is 3646 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

What do I need to know to debug my games in Dev-C++? I have no previous experience with stuff like this, and just need a push in the right direction, thanks.

##### Share on other sites
My recommended first step: Dump Dev-C++, move to MSVC++ (Express Edition is free). Then learn to use the MSVC debugger.

##### Share on other sites
I second that notion.

##### Share on other sites
It was a pain trying to set up SDL with VS so I figured ignorance is bliss. So I'll just stick with Dev-C++. Is it enough to just know GDB keywords?

##### Share on other sites
Have you considered following some instructions? It would be a shame to dump the awesome Visual Studio debugger (which you will use regularly) just because its hard to set up SDL (which you learn to do once).

[Edited by - rip-off on June 19, 2008 1:03:18 PM]

##### Share on other sites
Setting up SDL with MSVC:

Open MSVC's include folder
copy SDL's include files there (better to be inside an SDL folder, though, so you dont get their headers mixed with the regular MSVC headers)
copy SDL's .lib and .dll files to the lib folder (so you have a place for the DLL aswell)

Done, you may use SDL now.

##### Share on other sites
Quote:
 Original post by nuno_silva_ptSetting up SDL with MSVC:Open MSVC's include foldercopy SDL's include files there (better to be inside an SDL folder, though, so you dont get their headers mixed with the regular MSVC headers)copy SDL's .lib and .dll files to the lib folder (so you have a place for the DLL aswell)Done, you may use SDL now.

That will work, however IMHO all that does is pollute the standard directories.

It is trivial to add additional header and library lookup paths to your project. I prefer to keep the libraries I link against in the same directory as my project or solution.

##### Share on other sites
Quote:
 Original post by Kenny77It was a pain trying to set up SDL with VS so I figured ignorance is bliss. So I'll just stick with Dev-C++. Is it enough to just know GDB keywords?

But since you seem to want to learn *anyway*, how about you learn to use a tool that's actually been maintained for the last 3 years?

##### Share on other sites
If you do drop Dev-C++ and go with MSVC, I wrote an article on how to use the debugger. Even if you don't go with MSVC you may still find it useful as the terminology tends to be the same in most debuggers.

##### Share on other sites
Quote:
 Original post by superpigIf you do drop Dev-C++ and go with MSVC, I wrote an article on how to use the debugger. Even if you don't go with MSVC you may still find it useful as the terminology tends to be the same in most debuggers.

Thanks, I have that one printed.

I've gone through all the steps on Lazy Foo's site (the test program compiled), but still get complaints:

GameEngine.obj : error LNK2019: unresolved external symbol __imp___CrtDbgReportW referenced in function "public: class GameState * const & __thiscall std::_Vector_const_iterator >::operator*(void)const " (??D?$_Vector_const_iterator@PAVGameState@@V?$allocator@PAVGameState@@@std@@@std@@QBEABQAVGameState@@XZ)
IntroState.obj : error LNK2001: unresolved external symbol __imp___CrtDbgReportW
MenuState.obj : error LNK2001: unresolved external symbol __imp___CrtDbgReportW
C:\Documents and Settings\...\My Documents\Visual Studio 2005\Projects\Compeletely Original Game

This compiled under Dev-C++ so I don't think it's anything wrong with the code

• 33
• 12
• 10
• 9
• 9
• ### Forum Statistics

• Total Topics
631352
• Total Posts
2999484
×