Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#11405 closed Bugs (fixed)

Version detection fails for libstdc++ 4.6 with clang

Reported by: Etienne Laurin <etienne@…> Owned by: John Maddock
Milestone: To Be Determined Component: config
Version: Boost 1.57.0 Severity: Problem
Keywords: Cc:

Description

boost/config/stdlib/libstdcpp3.hpp sets BOOST_LIBSTDCXX_VERSION to 40700.

That causes BOOST_NO_CXX11_ALLOCATOR to be undefined.

This is reproducible on Ubuntu Lucid:

$ apt-get install g++ clang
$ cat test.cc
#include <boost/shared_ptr.hpp>
$ clang++ -isystem boost_1_58_0 -c -std=c++0x test.cc
boost_1_58_0/boost/smart_ptr/detail/shared_count.hpp:231:31: error: no type named 'allocator_traits' in namespace 'std'
$ clang++ -isystem boost_1_58_0 -c -std=c++11 test.cc -DBOOST_NO_CXX11_ALLOCATOR
# No error

Change History (5)

comment:1 by viboes, 7 years ago

Component: Noneconfig
Owner: set to John Maddock

comment:2 by John Maddock, 7 years ago

What is the actual GCC/libstdc++ version being used?

comment:3 by etienne@…, 7 years ago

I have GCC and libstdc++ version 4.6.3

comment:4 by John Maddock, 7 years ago

Resolution: fixed
Status: newclosed

Thanks, I believe this should fix it: https://github.com/boostorg/config/commit/15d56c9cff20e9643f508639517846a423fb948c

Please let me know if not.

comment:5 by Etienne Laurin <etienne@…>, 7 years ago

Thanks, that patch seems to work.

Note: See TracTickets for help on using tickets.