Fixed compilation for neither-boost-nor-c++11 case.

There were several compilation errors when I tried to compile
example.cpp with command line:
    g++ -Iinclude example.cpp