Boost logo

Boost Users :

From: Jalon, Arnon (Arnon.Jalon_at_[hidden])
Date: 2005-03-28 20:46:26


Hi, I am new to the list. Appologies in advance if I'm posting
something that's been already addressed, but I was unable to find
anything related to it while searching the archives.

I'm trying to use the date_time serialization headers in my application.
I'm actually using the boost headers and libraries that came with the
fedora core 3 linux distribution, and compiling with gcc 3.4.2.

Including boost/date_time/time_serialize.hpp in my source gives me
several compilation errors. I perused the time_serialize.hpp and
greg_serialize.hpp headers and found places where the typename keyword
was being used in front of class types that were simply qualified by
namespace, as well functions where variables were used that weren't
declared.

I modified the headers to get it to compile, but would like to see if
anyone else has been able to work around the problem in a less intrusive
way? If need be I can post the patch files I created to a proper place.

Below are the errors I was getting:
g++ -g -I. -c parseAccessLog.cpp
In file included from
/usr/include/boost/date_time/posix_time/time_serialize.hpp
:13,
                 from logobject.hpp:11,
                 from parseAccessLog.cpp:19:
/usr/include/boost/date_time/gregorian/greg_serialize.hpp: In function
`void boost::serialization::save(Archive&, const
boost::gregorian::date_period&, unsigned int)':
/usr/include/boost/date_time/gregorian/greg_serialize.hpp:150: error: no
class template named `date' in `boost::gregorian'
/usr/include/boost/date_time/gregorian/greg_serialize.hpp:150: error:
invalid type in declaration before '=' token
.
.
Repeated several times for similar condition through out
greg_serialize.hpp
.
.
/usr/include/boost/date_time/gregorian/greg_serialize.hpp: In function
`void boost::serialization::load_construct_data(Archive&,
boost::gregorian::nth_kday_of_month*, unsigned int)':
/usr/include/boost/date_time/gregorian/greg_serialize.hpp:336: error:
`pd' undeclared (first use this function)
/usr/include/boost/date_time/gregorian/greg_serialize.hpp:336: error:
(Each undeclared identifier is reported only once for each function it
appears in.)
.
.
Also repeated several times for similar condition
.
.
In file included from logobject.hpp:11,
                 from parseAccessLog.cpp:19:
/usr/include/boost/date_time/posix_time/time_serialize.hpp: In function
`void boost::serialization::save(Archive&, const
boost::posix_time::time_period&, unsigned int)':
/usr/include/boost/date_time/posix_time/time_serialize.hpp:131: error:
no class template named `ptime' in `boost::posix_time'
/usr/include/boost/date_time/posix_time/time_serialize.hpp:131: error:
invalid type in declaration before '(' token
.
.


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net