Mac OS X, c++11 build fixes.

Changes to fix builds in Mac OS X with clang++ and C++11. Tested with Boost 1.55.0.