'function0' : is not a member of 'boost'

A place for users of OGRE to discuss ideas and experiences of utilitising OGRE in their games / demos / applications.
Post Reply
igorvlassov
Halfling
Posts: 89
Joined: Thu Apr 22, 2004 11:22 am
x 1
Contact:

'function0' : is not a member of 'boost'

Post by igorvlassov »

Hello,

I tried to compile ogre v.1.6.3 with OGRE_THREAD_SUPPORT=1 and boost v.1.40.0
and I got comilation error:
ogreresourcebackgroundqueue.cpp(91) : error C2039: 'function0' : is not a member of 'boost'
Is it version problem or boost configuration problem may be?
If first, what version of boost must I use?

thanks,
Igor
User avatar
KungFooMasta
OGRE Contributor
OGRE Contributor
Posts: 2087
Joined: Thu Mar 03, 2005 7:11 am
Location: WA, USA
x 16
Contact:

Re: 'function0' : is not a member of 'boost'

Post by KungFooMasta »

I ran into this same problem, function0 is there, but you need to make sure to include the correct header:

Code: Select all

#include <boost/function/function0.hpp>
For reference here is my own scenario where I ran into it, if it helps at all:
http://www.ogre3d.org/addonforums/viewt ... 98&start=0
Creator of QuickGUI!
Van
Hobgoblin
Posts: 512
Joined: Fri Nov 19, 2004 3:56 am
Contact:

Re: 'function0' : is not a member of 'boost'

Post by Van »

We too stumbled upon this problem as well. Following KungFooMasta advice we added

Code: Select all

    #include <boost/function/function0.hpp>
to the top of OgreResourceBackgroundQueue.cpp as so

Code: Select all

...

#include "OgreRoot.h"
#include "OgreRenderSystem.h"

#include <boost/function/function0.hpp>

namespace Ogre {

...
Stop Global Whining.
Post Reply