It uses the gcc version to detect the libstdc++ version but clang always claims to be 4.2.1. See https://svn.boost.org/trac/boost/ticket/7473 and https://github.com/mongodb/mongo/blob/master/src/third_party/boost-1.56.0/boost/config/stdlib/libstdcpp3.hpp#L94-L114
This was fixed in 1.57 and a patch will not be needed when we upgrade to 1.60: https://github.com/boostorg/config/blob/boost-1.60.0/include/boost/config/stdlib/libstdcpp3.hpp#L115-L141