If your standard library implements the TR1, and you want to make use of
it, rather than use the Boost equivalents, then you will need to take some
explicit action to enable it: this may be a pre-processor define, a special
compiler switch, or a different include path. You will need to consult your
compilers documentation to find out which of these actions you need to take.

Provided Boost is correctly configured,
everything should now "just work", and code written to use Boost.TR1
will include your standard library's native headers rather than the Boost
ones.

There are two ways you can include the Boost.TR1 headers, for example if
you are interested in shared_ptr then you can either use:

#include<boost/tr1/memory.hpp>

or:

#include<memory>

The first option is the preferred method for other Boost libraries to use.
The second option is standard-conforming, but requires that you add boost-install-path/boost/tr1/tr1 to your compiler's include search path.
Note that you must not copy the headers in boost/tr1/tr1 into a directory
called "include", doing so will cause them to cease working.

Important Note #1

The include path order is very important if you want this library to work
correctly. If you get compiler errors then suspect the include paths. The
correct order is:

In this case try defining the macro BOOST_TR1_DISABLE_INCLUDE_NEXT
when building, and if that doesn't work, define the macro BOOST_TR1_GCC_INCLUDE_PATH
to the name of the directory containing gcc's include files: this is likely
to be something like "g++-v4" but unfortunately varies from distribution
to distribution.

Important Note #3: Borland C++ Users

Borland's compiler has a particularly broken form of #include,
that will actually look for a file named array.h if you
#include<array>.
In order to make this library work with Borland's compiler you will need
to set up the include paths as follows:

Sun's compiler has a particularly interesting form of #include,
that will actually look for a file named array.SUNWCCh
if you #include<array>.
What's more it won't include a standard header file that it thinks it's already
seen. In order to make this library work with Sun's compiler you can either
pass the undocumented compiler switch "-Qoption ccfe -nosunwcch"
to the compiler, or else you will need to set up the include paths as follows:

Regardless of how the includes are setup, user code written to work with
Boost.TR1 is exactly the same as code written to use a native tr1 implementation.
That is, references to classes and functions need to explicitly use the
std::tr1 namespace or a usingnamespacestd::tr1 statement.
For example,