Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / DarkGDK + stdlib vector class - I can only run in release mode?

Author
Message
jason p sage
17
Years of Service
User Offline
Joined: 10th Jun 2007
Location: Ellington, CT USA
Posted: 10th Feb 2008 18:15
Here is my experimental code:



It works if I compile in release mode but not in debug mode.

Errors:


any suggestions?

Daggeth
17
Years of Service
User Offline
Joined: 3rd May 2007
Location:
Posted: 10th Feb 2008 21:46
I'd do what the compiler is suggesting

Ignore libraries: libcpmt, libcmt under

Project Properties -> Configuration Properties -> Linker -> Input
jason p sage
17
Years of Service
User Offline
Joined: 10th Jun 2007
Location: Ellington, CT USA
Posted: 10th Feb 2008 23:53
I tried the NO DEFAULT lib thing, I tried to ignore libcmt....
Didn't try ignoring the libcpmt though....

I'll revist... meanwhile - I wrote my own dynamic array routine to get by.

Diggsey
18
Years of Service
User Offline
Joined: 24th Apr 2006
Location: On this web page.
Posted: 14th Feb 2008 16:42 Edited at: 14th Feb 2008 16:43
@jason p sage
Go into the project properties, and under 'C++ -> Preprocessor' there is a setting called 'Preprocessor definitions'. _DEBUG should be there, just remove that and it will work (assuming you have already done the other things like setting the run time library to MT and adding msvcrt, libcmtd and atls to the ignore library section) As long as 'Generate debug info' is still set to 'YES' you can still debug it.

theagg
16
Years of Service
User Offline
Joined: 11th Feb 2008
Location:
Posted: 16th Feb 2008 13:44
Ahh, I didn't spot this thread earlier but it has helped solve the problem with vectors I was having too.

Excellent.
jason p sage
17
Years of Service
User Offline
Joined: 10th Jun 2007
Location: Ellington, CT USA
Posted: 17th Feb 2008 15:27 Edited at: 17th Feb 2008 15:29
Here is a home made cheapy Dynamic Array class - doesn't use templates - if someone wants more than integers - and can make a template'd version of this class - feel free - I personally use it for int's and pointers via type casting:

header file .h




the source *.cpp


[edit] The Allocation size in the header is set to "TWO" (2) and that is for debugging - I recommend bigger allocation sizes for actual use.

Login to post a reply

Server time is: 2024-10-08 11:35:38
Your offset time is: 2024-10-08 11:35:38