Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: downloads/boost_1_33_1/doc/html/bbv2/advanced/builtins/features.html @ 12

Last change on this file since 12 was 12, checked in by landauf, 18 years ago

added boost

File size: 9.2 KB
Line 
1<html>
2<head>
3<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
4<title>Builtin features</title>
5<link rel="stylesheet" href="../../../boostbook.css" type="text/css">
6<meta name="generator" content="DocBook XSL Stylesheets V1.69.1">
7<style type="text/css">
8body { background-image: url('http://docbook.sourceforge.net/release/images/draft.png');
9       background-repeat: no-repeat;
10       background-position: top left;
11       /* The following properties make the watermark "fixed" on the page. */
12       /* I think that's just a bit too distracting for the reader... */
13       /* background-attachment: fixed; */
14       /* background-position: center center; */
15     }</style>
16<link rel="start" href="../../../index.html" title="The Boost C++ Libraries">
17<link rel="up" href="../../advanced.html" title="Chapter 24. User documentation">
18<link rel="prev" href="targets.html" title="Builtin target types">
19<link rel="next" href="../differences_to_v1.html" title="Differences to Boost.Build V1">
20</head>
21<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
22<table cellpadding="2" width="100%">
23<td valign="top"><img alt="boost.png (6897 bytes)" width="277" height="86" src="../../../../../boost.png"></td>
24<td align="center"><a href="../../../../../index.htm">Home</a></td>
25<td align="center"><a href="../../../../../libs/libraries.htm">Libraries</a></td>
26<td align="center"><a href="../../../../../people/people.htm">People</a></td>
27<td align="center"><a href="../../../../../more/faq.htm">FAQ</a></td>
28<td align="center"><a href="../../../../../more/index.htm">More</a></td>
29</table>
30<hr>
31<div class="spirit-nav">
32<a accesskey="p" href="targets.html"><img src="../../../images/prev.png" alt="Prev"></a><a accesskey="u" href="../../advanced.html"><img src="../../../images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../images/home.png" alt="Home"></a><a accesskey="n" href="../differences_to_v1.html"><img src="../../../images/next.png" alt="Next"></a>
33</div>
34<div class="section" lang="en">
35<div class="titlepage"><div><div><h2 class="title" style="clear: both">
36<a name="bbv2.advanced.builtins.features"></a>Builtin features</h2></div></div></div>
37<div class="variablelist"><dl>
38<dt><span class="term"><code class="literal">variant</code></span></dt>
39<dd>
40<p>
41            A feature that combines several low-level features, making
42            it easy to request common build configurations.
43          </p>
44<p><span class="bold"><strong>Allowed values:</strong></span><code class="literal">debug</code>, <code class="literal">release</code>,
45            <code class="literal">profile</code></p>
46<p>The value <code class="literal">debug</code> expands to</p>
47<pre class="programlisting">
48            &lt;optimization&gt;off &lt;debug-symbols&gt;on &lt;inlining&gt;off &lt;runtime-debugging&gt;on
49          </pre>
50<p>The value <code class="literal">release</code> expands to</p>
51<pre class="programlisting">
52            &lt;optimization&gt;speed &lt;debug-symbols&gt;off &lt;inlining&gt;full &lt;runtime-debugging&gt;off
53          </pre>
54<p>The value <code class="literal">profile</code> expands to the same as
55            <code class="literal">release</code>, plus:</p>
56<pre class="programlisting">
57            &lt;profiling&gt;on &lt;debug-symbols&gt;on
58          </pre>
59<p><span class="bold"><strong>Rationale:</strong></span> Runtime
60          debugging is on in debug builds to suit the expectations of
61          people used to various IDEs.
62         
63          It's assumed other folks don't
64          have any specific expectation in this point.
65          </p>
66</dd>
67<dt>
68<a name="bbv2.advanced.builtins.features.link"></a><span class="term"><code class="literal">link</code></span>
69</dt>
70<dd>
71<p>
72            A feature that controls how libraries are built.
73          </p>
74<p><span class="bold"><strong>Allowed values:</strong></span><code class="literal">shared</code>,
75            <code class="literal">static</code></p>
76</dd>
77<dt><span class="term"><code class="literal">source</code></span></dt>
78<dd>
79            The <code class="computeroutput">&lt;source&gt;X</code> feature has the same effect on building a target
80            as putting X in the list of sources. The feature
81            is sometimes more convenient:
82           
83            you can put <code class="computeroutput">&lt;source&gt;X</code> in the
84            requirements for a project and <code class="filename">X</code> will
85            be included as a source in all of the project's main
86            targets.
87            </dd>
88<dt><span class="term"><code class="literal">library</code></span></dt>
89<dd>
90            This feature is equivalent to the &lt;source&gt; feature, and exists
91            for backward compatibility reasons.
92          </dd>
93<dt><span class="term"><a name="bbv2.builtin.features.dependency"></a><code class="literal">dependency</code></span></dt>
94<dd>
95            Introduces a dependency on the target named by the
96            value of this feature (so it will be brought
97            up-to-date whenever the target being declared is), and
98            adds its usage requirements to the build properties
99           
100            of the target being declared.  The dependency is not used
101            in any other way. The primary use case is when you want
102            the usage requirements (such as <code class="computeroutput">#include</code> paths) of some
103            library to be applied, but don't want to link to it.
104            </dd>
105<dt><span class="term"><a name="bbv2.builtin.features.use"></a><code class="literal">use</code></span></dt>
106<dd>
107            Introduces a dependency on the target named by the
108            value of this feature (so it will be brought
109            up-to-date whenever the target being declared is), and
110            adds its usage requirements to the build properties
111           
112            of the target being declared.  The dependency is not used
113            in any other way. The primary use case is when you want
114            the usage requirements (such as <code class="computeroutput">#include</code> paths) of some
115            library to be applied, but don't want to link to it.
116            </dd>
117<dt><span class="term"><code class="literal">dll-path</code></span></dt>
118<dd>
119            Specify an additional directory where the system should
120            look for shared libraries when the executable or shared
121            library is run. This feature only affects Unix
122            compilers. Plase see <a href="../../faq/dll-path.html" title="Why are the dll-path and
123    hardcode-dll-paths properties useful?
124    ">the section called &#8220;Why are the <code class="computeroutput">dll-path</code> and
125    <code class="computeroutput">hardcode-dll-paths</code> properties useful?
126    &#8221;</a>
127            in <a href="../../faq.html" title="Chapter 27. Frequently Asked Questions">Chapter 27, <i>Frequently Asked Questions</i></a> for details.
128          </dd>
129<dt><span class="term"><code class="literal">hardcode-dll-paths</code></span></dt>
130<dd>
131<p>
132            Controls automatic generation of dll-path properties.
133          </p>
134<p><span class="bold"><strong>Allowed values:</strong></span><code class="literal">true</code>, <code class="literal">false</code>.  This property
135            is specific to Unix systems. If an executable is built with
136            <code class="computeroutput">&lt;hardcode-dll-paths&gt;true</code>, the generated binary
137            will contain the list of all the paths to the used shared
138            libraries. As the result, the executable can be run without
139            changing system paths to shared libraries or installing the
140            libraries to system paths. This
141           
142            is very convenient during
143            development. Plase see the <a href="../../faq/dll-path.html" title="Why are the dll-path and
144    hardcode-dll-paths properties useful?
145    ">FAQ entry</a> for details.
146            Note that on Mac OSX, the paths are unconditionally hardcoded by
147            the linker, and it's not possible to disable that behaviour.
148          </p>
149</dd>
150<dt>
151<span class="term"><code class="literal">cflags</code>, </span><span class="term"><code class="literal">cxxflags</code>, </span><span class="term"><code class="literal">linkflags</code></span>
152</dt>
153<dd>
154            The value of those features is passed without modification to the
155            corresponding tools. For <code class="computeroutput">cflags</code> that's both C and C++
156            compilers, for <code class="computeroutput">cxxflags</code> that's C++ compiler and for
157            <code class="computeroutput">linkflags</code> that's linker. The features are handy when
158            you're trying to do something special that cannot be achieved by
159            higher-level feature in Boost.Build.
160          </dd>
161</dl></div>
162</div>
163<table width="100%"><tr>
164<td align="left"></td>
165<td align="right"><small></small></td>
166</tr></table>
167<hr>
168<div class="spirit-nav">
169<a accesskey="p" href="targets.html"><img src="../../../images/prev.png" alt="Prev"></a><a accesskey="u" href="../../advanced.html"><img src="../../../images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../images/home.png" alt="Home"></a><a accesskey="n" href="../differences_to_v1.html"><img src="../../../images/next.png" alt="Next"></a>
170</div>
171</body>
172</html>
Note: See TracBrowser for help on using the repository browser.