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 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232
|
<html>
<head>
<meta http-equiv="Content-Language" content="en-us">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 5.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>Building Boost Libraries</title>
</head>
<body bgcolor="#FFFFFF" text="#000000">
<h1>
<img src="../../c++boost.gif" alt="c++boost.gif (8819 bytes)" align= "center" width="277" height="86">Building
Boost Libraries</h1>
<table border="1" cellpadding="5" width="656">
<tr>
<td width="638"><font size="5" color="#FF0000"><b>Read This
First!</b></font> <p>Boost.Build is fairly new as yet. Some features
are missing or incomplete. Instructions for accomplishing basic tasks
(this page) are rudimentary. But enough functionality is working
well to make using Boost.Build worthwhile. The important
bits-and-pieces are all there - what's left is some of the relatively
minor glue to make the system smooth and easy to use. Secondary tasks like
copying libraries to installation specific directories are weak.</p> <p>If
there isn't a configuration file (see <a href="#Tools">Tools</a>) available
for your favorite compiler, consider contributing one. </p> <p>Note
that the underlying Boost.Jam build engine is mature software, and the
original Jam build engine has been
widely used for many years. The Boost specific extensions are well
on their way to becoming stable, and have begun to attract interest and
use outside of Boost.</td>
</tr>
</table>
<p><a href="#Introduction">Introduction</a><br>
<a href="#Preliminaries">Preliminaries</a><br>
<a href="#Building">Building Boost Libraries</a><br>
<a href="#Moretools">More on using the tools</a><br>
<a href="#Tools">Tools available</a><br>
<a href="#Jam">Boost.Jam executable</a></p>
<h2><a name="Introduction">Introduction</a></h2>
<p>These instructions explain how to accomplish common tasks using <b>Boost.Build</b>,
the Boost Build System. The build system uses <a href="build_system.htm">
Boost.Jam</a>, an extension of the
<a href="http://www.perforce.com/jam/jam.html">Perforce Jam</a> portable <i>make</i>
replacement.</p>
<p>For tasks not covered here, see the full <a href="build_system.htm">build
system documentation</a>.</p>
<p>Note that many Boost libraries are implemented entirely within their headers,
and so can be used without building object libraries. Libraries that do
require building object libraries first include the Boost Python, Regular
Expression, and Thread libraries.</p>
<h2><a name="Preliminaries">Preliminaries</a></h2>
<ul>
<li><a href="../../more/download.html">Download Boost</a>, and unpack the full
directory structure into some root directory.</li>
<li>Install the <a href="#Jam">Boost.Jam executable</a> if needed. <a href="#Jam">
Pre-builts</a> are available. Make sure it's in your path. (Note: Boost
requires an enhanced version of Jam; the basic version won't work.)</li>
<li>Set any environment variables required to run your compiler and related
tools from the command line. (It might be a good idea to verify your command
line compiler is working if you don't use it regularly.) If you don't want
to clutter your environment, see <a href="#Moretools">More on using the
tools</a> for alternatives.</li>
</ul>
<h2><a name="Building">Building</a> Boost Libraries</h2>
<p>Using your operating system's command line interpreter, execute the following
steps. The sample commands given will work for both UNIX and Windows.</p>
<ul>
<li>Change to the Boost root directory. (The directory you unpacked the
distribution into. Among others, it contains the file c++boost.gif,
and subdirectories boost, libs, more, etc.)</li>
<blockquote>
<p><code>chdir my_boost</code></p>
</blockquote>
<li>Build the Boost libraries for your <a href="#Tools">tools</a>. The example
is for the GNU and Metrowerks compilers.</li>
<blockquote>
<p><code>jam -sBOOST_ROOT=. -sTOOLS="gcc metrowerks"</code></p>
</blockquote>
<li>If you don't want to specify <code>BOOST_ROOT</code> on the command-line,
you can instead set the <code>BOOST_ROOT</code> environment variable (an
absolute path is recommended).
</ul>
<h2><a name="Moretools">More on using the tools</a></h2>
<p>The build system's toolsets are designed to work in either of two ways:</p>
<ol>
<li>The user sets up all of the environment for each toolset he wants to use,
in the normal way. For example, for Microsoft VC++, ...vc98/bin is in the
path, vcvars32.bat or equivalent has been invoked, etc. For Metrowerks
CodeWarrior, cwenv.bat or equivalent has been called and ...Other Metrowerks
Tools/Command Line Tools is in the path.<br>
<br>
</li>
<li>The user doesn't want his environment cluttered with this junk and wants
to avoid the many other things done by the vendor's script files. Instead,
he or she sets variables which point to the toolset installation directories
(possibly in the Jamrules, or a user-setup.jam file invoked by the Jamrules).
These variables are used by the build system to locate the tools and invoke
the necessary setup. They are described in the comments in each toolset's
.jam file.</li>
</ol>
<h2><a name="Tools">Tools</a> available</h2>
<table border="1" cellpadding="5">
<tr>
<td><b>TOOLS Name</b></td>
<td><b>Description</b></td>
</tr>
<tr>
<td><code>borland</code></td>
<td>Borland command line compiler tools</td>
</tr>
<tr>
<td><code>como</code></td>
<td>Comeau command line compiler tools</td>
</tr>
<tr>
<td><code>gcc</code></td>
<td>GNU GCC command line compiler tools</td>
</tr>
<tr>
<td><code>gcc-stlport</code></td>
<td>GNU GCC command line compiler tools, using the STLport library</td>
</tr>
<tr>
<td><code>intel-win32</code></td>
<td>Intel command line compiler tools under Win32 using the
Microsoft library</td>
</tr>
<tr>
<td><code>intel-linux</code></td>
<td>Intel command line compiler tools under Linux</td>
</tr>
<tr>
<td><code>kcc</code></td>
<td>KAI command line compiler tools</td>
</tr>
<tr>
<td><code>metrowerks</code></td>
<td>Metrowerks CodeWarrior command line compiler tools</td>
</tr>
<tr>
<td><code>msvc</code></td>
<td>Microsoft Visual C++ command line compiler tools</td>
</tr>
<tr>
<td><code>msvc-stlport</code></td>
<td>Microsoft Visual C++ command line compiler tools, using the STLport library</td>
</tr>
<tr>
<td><code>vacpp</code></td>
<td>IBM Visual Age C++ command line compiler tools</td>
</tr>
</table>
<p>Unless otherwise specified, the library is assumed to be the one shipped with
the compiler.</p>
<p>Additional tools can be supplied by adding an appropriate xxxx-tools.jam file
to the tools/build subdirectory, where xxxx is the name of the tool being
added. If you write an additional toolset file, please submit it to Boost
so others may benefit from your work.</p>
<h2>Boost.<a name="Jam">Jam</a> executable</h2>
<p>Pre-built Boost.Jam executables are available for the following platforms:</p>
<ul>
<li><a href="http://boost.sourceforge.net/jam-executables/bin.aix/jam.gz">
IBM Aix</a> </li>
<li>
<a href="http://boost.sourceforge.net/jam-executables/bin.linuxx86/jam.gz">
Linux-x86</a> </li>
<li>
<a href="http://boost.sourceforge.net/jam-executables/boost-build.win.zip">
Microsoft Windows</a> (includes Boost.Build files and boost-build helper
program).</li>
<li><a href="http://boost.sourceforge.net/jam-executables/bin.irix/jam.gz">
SGI Irix</a> </li>
<li>
<a href="http://boost.sourceforge.net/jam-executables/bin.solaris/jam.gz">
SUN Solaris</a> </li>
<li>
<a href="http://boost.sourceforge.net/jam-executables/bin.osf/jam.gz">
Compaq Tru64</a> </li>
</ul>
<p>RedHat Linux RPM packages are available:</p>
<ul>
<li>
<a href="http://boost.sourceforge.net/jam-executables/boost-jam-3.0-1.i386.rpm">
Boost.Jam rpm</a> </li>
<li>
<a href="http://boost.sourceforge.net/jam-executables/boost-build-1.0-1.i386.rpm">
Boost.Build rpm</a> </li>
<li>
<a href="http://boost.sourceforge.net/jam-executables/boost-jam-3.0-1.src.rpm">
Boost.Jam source rpm </a></li>
<li>
<a href="http://boost.sourceforge.net/jam-executables/boost-build-1.0-1.src.rpm">
Boost.Build source rpm</a></li>
</ul>
<p>The Boost.Jam source files are included in the Boost distribution, so you can build
the Boost.Jam executable yourself:</p>
<ul>
<li>For most Unix variants, you can build Boost.Jam by simply invoking
<tt>make</tt> in the <tt>tools/build/jam_src</tt> subdirectory of your
boost installation.
<li><a href="http://public.perforce.com/public/jam/src/README">Build
Instructions</a> are the same as for "<a
href="http://www.perforce.com/jam/jam.html">Classic Jam</a>", if
you need them.
<li>Your new Boost.Jam executable will be located in a newly-created
<tt>tools/build/jam_src/bin.</tt><i>platform</i> subdirectory.
<li>If you build Boost.Jam for a new platform using the same boost
installation, be sure to first remove all object files, executables, and
libraries created by the initial make in the <tt>jam_src</tt> directory.
</ul>
<hr>
<p>Revised <!--webbot bot="Timestamp" S-Type="EDITED" S-Format="%d %B, %Y" startspan -->28 November, 2001<!--webbot bot="Timestamp" i-checksum="39367" endspan -->
</p>
<p> Copyright 2001 Beman Dawes</p>
<p> </p>
</body>
</html>
|