[pkg-boost-devel] Bug#701377: Bug#701377: boost1.49: ftbfs with GCC-4.8
Daniel Hartwig
mandyke at gmail.com
Fri Mar 1 16:56:41 UTC 2013
On 1 March 2013 23:55, Dmitrijs Ledkovs <xnox at debian.org> wrote:
> On 1 March 2013 14:17, Daniel Hartwig <mandyke at gmail.com> wrote:
>> On 1 March 2013 21:14, Dmitrijs Ledkovs <xnox at debian.org> wrote:
>>> In Ubuntu, instead of applying the full patch against 1.49, we went
>>> for a minimalistic hack/patch to workaround TIME_UTC in eglibc-2.16.
>>> Simply undef TIME_UTC if defined.
>>
>> Is that expected to work for a program that uses both libboost-thread
>> and C11 date and time?
>
> yes, as both have always evaluated to the same constant value on linux.
On glibc, rather. An unsafe assumption, given that C11 does not
define the value any more than a non-zero, positive integer. Boost
does not even specify that much.
These are different APIs, it is not precise to overload a single
macro. The boost macro exists in a distinct namespace and the Ubuntu
patch does not appear to have the feature you claim. From the
attached test case:
$ g++ -o test -lboost_thread test.cc
test.cc: In function ‘int main(int, const char**)’:
test.cc:8:11: error: ‘TIME_UTC’ was not declared in this scope
int x = TIME_UTC;
^
--
Further, #undef is placed outside of the BOOST_XTIME_WEK070601_HPP
header guard; a second include of this header would undefine and not
subsequently redefine the macro.
Regards
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.cc
Type: application/octet-stream
Size: 152 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-boost-devel/attachments/20130302/d940e1b6/attachment.obj>
More information about the pkg-boost-devel
mailing list