Boost logo

Boost Users :

From: Eric (eric-public_at_[hidden])
Date: 2005-05-30 00:34:08

Thanks Robert. This partially worked... Your comment about putting the
BOOST_CLASS_EXPORT macro into the header keyed me into something.
I am using the BOOST_CLASS_EXPORT(derived) macro, but I've been placing them
into the source (cpp) file instead of the header (h) file. With my system,
when I put BOOST_CLASS_EXPORT(derived) into the header file, I get a
multiply-defined error at link time (the offending code is
boost::archive::detail::guid_initializer<class,...> since the header is
included multiple times when I use the class.
As a test, I setup a sandbox with a stripped down system and was able to get
it to work when I put the BOOST_CLASS_EXPORT in the header, but not when it
is in the cpp file.
Q: Why does the location of the BOOST_CLASS_EXPORT matter? Is it doing
order-depended initialization upon bringing up the system?
Q: How do I avoid the mutiple defined error in the linker?
Thanks again for your help and the library :)

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at