Warning in compilation

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
daesdemon
Quite a regular
Quite a regular
Posts: 60
Joined: Fri Mar 11, 2005 21:19
Contact:

Warning in compilation

Postby daesdemon » Sat Apr 09, 2005 16:08

Hello all

I am using CEGUI with Ogre.

I include cegui.h before ogre to avoir error manager errors.

At first it work ok but i changed the order of something in my predefinate.h and now i get loads of warning (1 per file) like this:

Code: Select all

f:\dev\3D\Dependencies\include\CEGUI\CEGUILogger.h(150) : warning C4251: 'CEGUI::Logger::d_cache' :
class 'std::vector<_Ty>' nécessite une interface DLL pour être utilisé(e) par les clients de class 'CEGUI::Logger'


In english it should be:

Code: Select all

f:\dev\3D\Dependencies\include\CEGUI\CEGUILogger.h(150) : warning C4251: 'CEGUI::Logger::d_cache' :
class 'std::vector<_Ty>' need a DLL interface to be used by clients of class 'CEGUI::Logger'



It is not a problem , but it pollutes my compilation ;)

Do someone have an idea??

My header is:

Code: Select all

 
#include <CEGUI/CEGUI.h>
#include <OgreCEGUIRenderer.h>
#include <OgreCEGUIResourceProvider.h>
#include <OgreSingleton.h>

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

Re: Warning in compilation

Postby CrazyEddie » Sat Apr 09, 2005 17:35

The only solution that I know of is to disable the warning. You always get this when building a DLL with classes that make use of other classes which are not exported from the DLL.

CEGUI makes heavy use of disabling this warning ;)

P.S. If anybody asks, I was never here :lol:

User avatar
daesdemon
Quite a regular
Quite a regular
Posts: 60
Joined: Fri Mar 11, 2005 21:19
Contact:

Re: Warning in compilation

Postby daesdemon » Sat Apr 09, 2005 18:00

ok , normal behavior so, no problem.

Thx Eddie

PS: No problems I haven't seen you, Eddie ;)

User avatar
daesdemon
Quite a regular
Quite a regular
Posts: 60
Joined: Fri Mar 11, 2005 21:19
Contact:

Re: Warning in compilation

Postby daesdemon » Sun Apr 10, 2005 12:32

Code: Select all

#pragma warning( disable : 4251 )
for those who are interested by on VS2003

User avatar
osb1842
Just popping in
Just popping in
Posts: 7
Joined: Tue May 03, 2005 17:29
Location: Monterey, CA
Contact:

Re: Warning in compilation

Postby osb1842 » Tue May 03, 2005 17:36

Shouldn't the #pragma be placed in the CEGUILogger.h file itself, so we don't need to use a hacked version of CEGUI?

Something like...

#if defined(_MSC_VER)
# pragma warning(push)
# pragma warning(disable : 4251)
# pragma warning(disable : 4275)
#endif


Return to “Modifications / Integrations / Customisations”

Who is online

Users browsing this forum: No registered users and 9 guests