Oh, turns out I had to solve it by changing the header of MyNode.h to:
#include <boost/any.hpp>
#define BOOST_ANY_HPP // fool Vizard's boost::any
#include <VizExtensionOSGNode.h>
Maybe the best solution is for your any to life in a different namespace? Then mixing different versions of boost will be just fine as your any will only affect your code (its header only so it shouldn't lead to any linking trouble).
EDIT:
urgh, spoke too fast, compilation wasn't finished yet. Turns out even this doesn't solve things:
1>MyExtension.cpp
1>c:\dat\C\projects\Dependency\boost\boost/any.hpp(36) : error C2011: 'boost::any' : 'struct' type redefinition
1> c:\dat\C\projects\Dependency\Vizard4_SDK\include\v iz/any(230) : see declaration of 'boost::any'
1>c:\dat\C\projects\Dependency\boost\boost/any.hpp(165) : error C2011: 'boost::bad_any_cast' : 'struct' type redefinition
1> c:\dat\C\projects\Dependency\Vizard4_SDK\include\v iz/any(32) : see declaration of 'boost::bad_any_cast'
1>c:\dat\C\projects\Dependency\boost\boost/any.hpp(186) : error C2995: 'T *boost::any_cast(boost::any *)' : function template has already been defined
1> c:\dat\C\projects\Dependency\Vizard4_SDK\include\v iz/any(390) : see declaration of 'boost::any_cast'
1>c:\dat\C\projects\Dependency\boost\boost/any.hpp(192) : error C2995: 'const T *boost::any_cast(const boost::any *)' : function template has already been defined
Best,
Dee
Last edited by dcnieho; 05-21-2011 at 01:30 AM.
|