summaryrefslogtreecommitdiff
path: root/more/getting_started/detail/header-only.rst
blob: db0056a7e87c8fe1831205dcb9049f96f0565108 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
.. Copyright David Abrahams 2006. Distributed under the Boost
.. Software License, Version 1.0. (See accompanying
.. file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

Header-Only Libraries
=====================

The first thing many people want to know is, “how do I build
Boost?”  The good news is that often, there's nothing to build.

.. admonition:: Nothing to Build?

  Most Boost libraries are **header-only**: they consist *entirely
  of header files* containing templates and inline functions, and
  require no separately-compiled library binaries or special
  treatment when linking.

.. .. _separate: 

The only Boost libraries that *must* be built separately are:

* Boost.Chrono_
* Boost.Context_
* Boost.Filesystem_
* Boost.GraphParallel_
* Boost.IOStreams_
* Boost.Locale_
* Boost.Log_ (see `build documentation`__)
* Boost.MPI_
* Boost.ProgramOptions_
* Boost.Python_ (see the `Boost.Python build documentation`__
  before building and installing it)
* Boost.Regex_
* Boost.Serialization_
* Boost.Signals_
* Boost.System_
* Boost.Thread_
* Boost.Timer_
* Boost.Wave_

__ ../../libs/log/doc/html/log/installation/config.html
__ ../../libs/python/doc/html/building.html

A few libraries have optional separately-compiled binaries:

* Boost.DateTime_ has a binary component that is only needed if
  you're using its ``to_string``\ /\ ``from_string`` or serialization
  features, or if you're targeting Visual C++ 6.x or Borland.

* Boost.Graph_ also has a binary component that is only needed if
  you intend to `parse GraphViz files`__.

* Boost.Math_ has binary components for the TR1 and C99
  cmath functions.

* Boost.Random_ has a binary component which is only needed if
  you're using ``random_device``.

* Boost.Test_ can be used in “header-only” or “separately compiled”
  mode, although **separate compilation is recommended for serious
  use**.

* Boost.Exception_ provides non-intrusive implementation of
  exception_ptr for 32-bit _MSC_VER==1310 and _MSC_VER==1400
  which requires a separately-compiled binary. This is enabled by
  #define BOOST_ENABLE_NON_INTRUSIVE_EXCEPTION_PTR.

__ ../../libs/graph/doc/read_graphviz.html