VC++ 6 project settings - help needed

For help with anything that CEGUI doesn't offer straight out-of-the-box, e.g.:
- Implementation of new features, such as new Core classes, widgets, WindowRenderers, etc. ...
- Modification of any existing features for specific purposes
- Integration of CEGUI in new engines or frameworks and writing of new plugins (Renderer, Parser, ...) or modules

Moderators: CEGUI MVP, CEGUI Team

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

VC++ 6 project settings - help needed

Postby CrazyEddie » Sat Jul 31, 2004 11:16

Okay, this is what I have done this morning.

Using Ogre CVS from this morning, CEGUI CVS from this morning, pre-built VC6 dependencies for cegui and STLport 4.5.3. Plus Demo 7 source, using the project files for VC6 I sent you the other day.

I first built everything as-is, then started checking the dependencies for all of the components. Everything was as it should have been except the fact that the debug build of Ogre under VC6 was not using the debug C++ runtime (that is, all the Ogre projects are missing the definition for _STLP_DEBUG). This was causing exceptions due to memory checking, since CEGUI (using debug runtime) and Ogre (using non-debug runtime) were operating using different heaps. I added this definition (then the /Zm200 switch due to compiler errors in some projects) and recompiled - everything okay (just got some warnings about truncated symbol names).

With this issue resolved, I then found that changes in the CEGUI code since the release of Demo 7 required me to copy the updated XML schemas from the 'cegui_mk2/XMLRefSchema' directory into the demo .exe directory, and also the updated TaharezImageset.xml file.

Having done all this, the system does run normally under the Debug build without any issues at all.

My advice here then, would normally be that the Ogre projects should be recompiled with _SLTP_DEBUG defined. However, the exceptions you were getting were not the same as the ones I was getting, therefore it seems that somehow you're already getting the correct runtimes linked in (though this is very strange if none of the projects have been modified).

So now I must ask, what is the exact exception you are getting (also whether it is a C++ thrown exception, or is it a processor exception). Also can you post the contents of your CEGUI.log.

Thanks,

CE.

User avatar
saetrum
Quite a regular
Quite a regular
Posts: 55
Joined: Wed Jan 12, 2005 12:06
Location: Albuquerque, NM USA

VC++ 6 project settings - help needed

Postby saetrum » Sat Jul 31, 2004 16:47

^^^^^^That was me

By the way, what #defines do you use in stlport when you compile it? Maybe I'm not doing this correctly.
There are 10 types of people in the world: those that understand binary and those that don't.

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

VC++ 6 project settings - help needed

Postby CrazyEddie » Sat Jul 31, 2004 17:24

No defines for STLport. I just do:

Code: Select all

nmake -f vc6.mak all

from within the STLport ./src directory.

Getting a processor error is certainly strange, what I may do is get you to send me the binaries you have built for investigation. But see how you go on Monday. :)

User avatar
saetrum
Quite a regular
Quite a regular
Posts: 55
Joined: Wed Jan 12, 2005 12:06
Location: Albuquerque, NM USA

VC++ 6 project settings - help needed

Postby saetrum » Sat Jul 31, 2004 18:38

OK, I'll try to recompile stlport without the extra flags I have set. That may be the root of the problem. I have the reentrant flag(multi-threaded programs) set as well as another flag (can't remember the name) for iostream namespace collision resolution. I read the documentation for stlport and thought those were the correct flags for what I was doing, but obviously they aren't required if no one else uses them.

Edit: The reason I wasn't getting the other errors you were was I was setting the _STLP_DEBUG flag in stlport before compiling stlport. That was resolving the debug issue with Ogre not having that set.

edit2: The name of the stlport file I set these flags in is :stl_user_config.h (found in the stlport directory under the STLport-4.5.3 directory). The config.html file under the doc subdirectory gives the other flags you can set in the user_config file. Maybe I shouldn't have read so much about stlport, and just have compiled it :lol: :roll:
There are 10 types of people in the world: those that understand binary and those that don't.

User avatar
saetrum
Quite a regular
Quite a regular
Posts: 55
Joined: Wed Jan 12, 2005 12:06
Location: Albuquerque, NM USA

VC++ 6 project settings - help needed

Postby saetrum » Mon Aug 02, 2004 15:28

Success! :D

Thank you CE for sticking with me and helping me figure the issues out. I apologize for taking up your time with helping me get set up. Following the settings you listed fixed the issues I was having (I think missing the updated .xsd files was what was causing the exception I was getting).

Thanks again.
There are 10 types of people in the world: those that understand binary and those that don't.

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

VC++ 6 project settings - help needed

Postby CrazyEddie » Mon Aug 02, 2004 17:50

Cool :D

Glad it's working for you now :)

I had no problem helping out, because you were willing to stick it out and work at it until you got it to work. The only time I have to draw a line is if someone comes on here and says, "I can't get this to work. Do it for me!". :shock: Yeah, right! :lol:

CE.

User avatar
Nihilus
Just popping in
Just popping in
Posts: 15
Joined: Wed Jan 12, 2005 12:06
Location: Tampa, FL. USA

VC++ 6 project settings - help needed

Postby Nihilus » Thu Sep 02, 2004 20:41

I've gotten the cegui_mk2 from cvs to compile (with older dependancy packages) but when I try to compile the demo, I get a link error:

Code: Select all

LINK: fatal error LNK1104: cannot open file "libboost_signals-vc6-mt-sgdp-1_31.lib"


Based on the boost auto-linking, this should be expected. Do you compile your demos with the static library (I'd guess not from the size of the binary distribution), or is there some project setting I'm missing to make it look for the dynamic library?

From the boost header, the only setting that should work is _DLL, but this seems to be wrong because I'm not making a DLL in this case?


[/code]

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

VC++ 6 project settings - help needed

Postby CrazyEddie » Fri Sep 03, 2004 08:38

No, as you guessed, everything is dynamically linked.

You have to adjust the runtime setting for your project to be Multithreaded DLL for the release build and Debug Multithreaded DLL for the debug build.

Errrm... The setting is in Project Settings, on the C++ tab, code generation option (or something like that, I don't have a VC6 install at the moment so can't check).

HTH

CE.

User avatar
Nihilus
Just popping in
Just popping in
Posts: 15
Joined: Wed Jan 12, 2005 12:06
Location: Tampa, FL. USA

VC++ 6 project settings - help needed

Postby Nihilus » Fri Sep 03, 2004 15:27

No, as you guessed, everything is dynamically linked.

You have to adjust the runtime setting for your project to be Multithreaded DLL for the release build and Debug Multithreaded DLL for the debug build.

Errrm... The setting is in Project Settings, on the C++ tab, code generation option (or something like that, I don't have a VC6 install at the moment so can't check).

HTH

CE.


These are the settings used when compiling the demo application (which isn't a DLL)?

I'm compiling the cegui dll's fine (as far as I can tell), it's compiling demo7 that is causing the link error.

User avatar
Nihilus
Just popping in
Just popping in
Posts: 15
Joined: Wed Jan 12, 2005 12:06
Location: Tampa, FL. USA

VC++ 6 project settings - help needed

Postby Nihilus » Fri Sep 03, 2004 19:20

Yep, that's right, you use those setting when compiling the demo .exe project. The settings relate to the c/c++ runtime to be used and do not affect the way the project is built in itself (other than to ensure correct linkage).

HTH

CE.


Thanks, that worked! I had improperly created the project as a console application, and was getting an unresolved symbol _main when I set it to debug multithread dll so that threw me off. I fixed that and everything compiles nicely.

Thanks again for the help!


Return to “Modifications / Integrations / Customisations”

Who is online

Users browsing this forum: No registered users and 6 guests