General Development

Release Build Vs Debug Build – luke

luke

Member

Posts: 311
From: I use your computer as my second Linux box
Registered: 10-30-2005
Ok, the title basically says it all; I recently tried building my project in release mode just for kicks, and I got a bunch of errors :

Object3D.cpp(127) : fatal error C1010: unexpected end of file while looking for precompiled header directive
Main.cpp
Main.cpp(40) : error C2065: 'IDS_APP_TITLE' : undeclared identifier
Main.cpp(41) : error C2065: 'IDC_DXUTIL' : undeclared identifier
Main.cpp(50) : error C3861: 'IDC_DXUTIL': identifier not found, even with argument-dependent lookup
Main.cpp(139) : error C2065: 'IDI_DXUTIL' : undeclared identifier
Main.cpp(142) : error C3861: 'IDC_DXUTIL': identifier not found, even with argument-dependent lookup
Main.cpp(144) : error C2065: 'IDI_SMALL' : undeclared identifier
Main.cpp(222) : error C2065: 'IDM_ABOUT' : undeclared identifier
Main.cpp(222) : error C2051: case expression not constant
Main.cpp(223) : error C2065: 'IDD_ABOUTBOX' : undeclared identifier
Main.cpp(225) : error C2065: 'IDM_EXIT' : undeclared identifier
Main.cpp(225) : error C2051: case expression not constant
Main.cpp(230) : warning C4065: switch statement contains 'default' but no 'case' labels
DXUtil.cpp
DXUtil.cpp(241) : fatal error C1010: unexpected end of file while looking for precompiled header directive
DXGeomBuffer.cpp
DXGeomBuffer.cpp(237) : fatal error C1010: unexpected end of file while looking for precompiled header directive
Generating Code...

and all that undefined stuff is in a file called Resource.h, and they are all defined like this : #define name_here (int)
Now I have no clue what Resource.h is for, or how to use it... I also am wondering why my build in debug works just fine when I run it from the IDE, but when I open up the exe like any other app, I just get that "x app has experienced an error, please send a report..." from MS.

------------------
If you can see Chuck Norris, He can see You.
If you Can't see Chuck Norris, you may be seconds away from death.

fearless

Member

Posts: 91
From: Romania, Tg Mures
Registered: 11-26-2005
I don't know what IDE you're using but usually you have separate settings for each mode. Make sure your release settings match the debug settings(i.e. same paths in Include, Lib, Bin, etc.).

[This message has been edited by fearless (edited August 24, 2006).]

Jari

Member

Posts: 1471
From: Helsinki, Finland
Registered: 03-11-2005
Hi luke. I think you need to include stdafx.h or whatever is the name of the precompiled header file to Object3D.cpp

Does that solve the problem?

------------------
2Co 7:10 For godly sorrow worketh repentance to salvation not to be repented of: but the sorrow of the world worketh death.

[VoHW] (Help needed) [Blog] - Truedisciple (mp3)

luke

Member

Posts: 311
From: I use your computer as my second Linux box
Registered: 10-30-2005
Sorry, but no that actually 'created' more errors, and btw I dont use that file at all nor any other 'default' win32 files except the one with winmain in it, which I barely touch; with the only objective of transfering the code control out of that and into my hands.,,

------------------
If you can see Chuck Norris, He can see You.
If you Can't see Chuck Norris, you may be seconds away from death.

Jari

Member

Posts: 1471
From: Helsinki, Finland
Registered: 03-11-2005
Ok I just thought that could be the issue because it says "Object3D.cpp(127) : fatal error C1010: unexpected end of file while looking for precompiled header directive Main.cpp"

I suppose the use of precompiled headers can be toggled on/off from your IDE's project settings. It's so in VS express.

------------------
2Co 7:10 For godly sorrow worketh repentance to salvation not to be repented of: but the sorrow of the world worketh death.

[VoHW] (Help needed) [Blog] - Truedisciple (mp3)

[This message has been edited by jari (edited August 25, 2006).]

Seven7
Member

Posts: 50
From: USA
Registered: 03-16-2005

[I realize this is an old post but for future refreance]

Be sure to "#include "Resource.h" in your project (assume "main.cpp"), if you've done this be sure that you have your .rc file. Note: your .rc file
is just a text file, just open it up and edit. (Be sure to back it up first!)

Cheers.