Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: downloads/boost_1_34_1/libs/iostreams/doc/installation.html @ 33

Last change on this file since 33 was 29, checked in by landauf, 16 years ago

updated boost from 1_33_1 to 1_34_1

File size: 8.5 KB
Line 
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2<HTML>
3<HEAD>
4    <TITLE>Installation</TITLE>
5    <LINK REL="stylesheet" HREF="../../../boost.css">
6    <LINK REL="stylesheet" HREF="theme/iostreams.css">
7</HEAD>
8<BODY>
9
10<!-- Begin Banner -->
11
12    <H1 CLASS="title">Installation</H1>
13    <HR CLASS="banner">
14
15<!-- End Banner -->
16
17<DL class="page-index">
18    <DT><A HREF="#overview">Overview</A>
19    <DT><A HREF="#ide">Building with an IDE or Makefile</A>
20    <DT><A HREF="#bjam">Building with Boost.Build</A>
21</DL>
22
23<A NAME="overview"></A>
24<H2>Overview</H2>
25
26<P>
27    Most of Boost.Iostreams can be used simply by including appropriate headers. This is true, for instance, of all the <A HREF="quick_reference.html#core">core components</A> &#8212; including <A HREF="guide/generic_streams.html#stream"><CODE>stream</CODE></A>, <A HREF="guide/generic_streams.html#stream_buffer"><CODE>stream_buffer</CODE></A>, <A HREF="classes/filtering_stream.html"><CODE>filtering_stream</CODE></A> and <A HREF="classes/filtering_streambuf.html"><CODE>filtering_streambuf</CODE></A> &#8212; and of about two thirds of the concrete <A HREF="quick_reference.html#filters">Filters</A> and <A HREF="quick_reference.html#devices">Devices</A>.
28    Some components, however, are implemented in <CODE>.cpp</CODE> files; in addition, the <A HREF="classes/regex_filter.html">regular expression filters</A> depend on <A HREF="../../regex/index.html" TARGET="_top">Boost.Regex</A>, and the compressions filters rely on the third-party libraries zlib (<A CLASS='bib_ref' NAME='gailly' HREF="bibliography.html#gailly"'>[Gailly]</A>) and libbz2 (<A CLASS='bib_ref' NAME='seward' HREF="bibliography.html#seward"'>[Seward]</A>). To obatin zlib and libbz2, see the instructions <A HREF="classes/zlib.html#installation">here</A> and <A HREF="classes/bzip2.html#installation">here</A>.
29</P>
30
31<P>
32    The components which are implemented in <CODE>.cpp</CODE> or which rely on external libraries can be built in two ways: by adding the appropriate <CODE>.cpp</CODE> files to your IDE project or makefile, or by using <A HREF="../../../tools/build/index.html" TARGET="_top">Boost.Build</A>.
33</P>
34
35<A NAME="ide"></A>
36<H2>Building with an IDE or Makefile</H2>
37
38<P>
39    The following table shows which headers contain components defined in <CODE>.cpp</CODE> files. If your application includes one of these headers, you'll need to add the corresponding <CODE>.cpp</CODE> files to you IDE project or makefile, and to define the preprocessor symbol <CODE>BOOST_IOSTREAMS_NO_LIB</CODE>. In addition, if the <CODE>.cpp</CODE> file depends on an external library, you'll have to build it from the source or link to a pre-built binary.
40</P>
41
42<TABLE CELLPADDING=5 BORDER=1>
43<TR><TH>Header</TH><TH>Source File</TH><TH WIDTH=200>External Library</TH></TR>
44<TR>
45    <TD><A HREF="../../../boost/iostreams/device/file_descriptor.hpp"><CODE>boost/iostreams/device/file_descriptor.hpp</CODE></A></TD> <TD><A HREF="../../../libs/iostreams/src/file_descriptor.cpp"><CODE>file_descriptor.cpp</CODE></A></TD>
46    <TD STYLE='padding-left:1.5em'>-</TD>
47</TR>
48<TR>
49    <TD><A HREF="../../../boost/iostreams/device/mapped_file.hpp"><CODE>boost/iostreams/device/mapped_file.hpp</CODE></A></TD> 
50    <TD><A HREF="../../../libs/iostreams/src/mapped_file.cpp"><CODE>mapped_file.cpp</CODE></A></TD>
51    <TD STYLE='padding-left:1.5em'>-</TD>
52</TR>
53<TR>
54    <TD><A HREF="../../../boost/iostreams/filter/bzip2.hpp"><CODE>boost/iostreams/filter/bzip2.hpp</CODE></A></TD> 
55    <TD><A HREF="../../../libs/iostreams/src/bzip2.cpp"><CODE>bzip2.cpp</CODE></A></TD>
56    <TD STYLE='padding-left:1.5em'>libbz2</TD>
57</TR>
58<TR>
59    <TD><A HREF="../../../boost/iostreams/filter/gzip.hpp"><CODE>boost/iostreams/filter/gzip.hpp</CODE></A></TD> 
60    <TD><A HREF="../../../libs/iostreams/src/zlib.cpp"><CODE>zlib.cpp</CODE></A></TD>
61    <TD STYLE='padding-left:1.5em'>zlib</TD>
62</TR>
63<TR>
64    <TD><A HREF="../../../boost/iostreams/filter/regex.hpp"><CODE>boost/iostreams/filter/regex.hpp</CODE></A></TD> 
65    <TD STYLE='padding-left:1em'>-</TD>
66    <TD STYLE='padding-left:1.5em'><A HREF="../../regex/index.html" TARGET="_top">Boost.Regex</A></TD>
67</TR>
68<TR>
69    <TD><A HREF="../../../boost/iostreams/filter/zlib.hpp"><CODE>boost/iostreams/filter/zlib.hpp</CODE></A></TD> 
70    <TD><A HREF="../../../libs/iostreams/src/zlib.cpp"><CODE>zlib.cpp</CODE></A></TD>
71    <TD STYLE='padding-left:1.5em'>zlib</TD>
72</TR>
73</TABLE>
74
75<A NAME="bjam"></A>
76<H2>Building with Boost.Build</H2>
77
78<P>
79    To build with <A HREF="../../../tools/build/v1/build_system.htm" TARGET="_top">Boost.Build</A>, run <I>bjam</I> from the directory <CODE>libs/iostreams/build</CODE>, or from the Boost root directory. If you want to use the compression filters, you may need to set several Boost.Build variables indicating where the source files or pre-built binaries are located. These variables are summarized in the following table.
80</P>
81<P>
82    On most UNIX systems, it should not be necessary to set any of these variables, since the zlib and libbz2 headers and binaries are already installed in locations where they will be found automatically. On Windows, the zlib and bzip2 filters are disabled by default; to enable support for these filters, you will need to set variables indicating the location of the source files, if building from the source, or the location of the headers and binaries, if using pre-built binaries.
83</P>
84
85<TABLE STYLE="margin-bottom:1em" BORDER="1" CELLPADDING="6" CELLSPACING="1">
86<TR>
87    <TH>Variable</TH><TH>Interpretation</TH><TH>Default</TH>
88</TR>
89<TR>
90    <TD><CODE>NO_COMPRESSION</CODE></TD>
91    <TD>
92        Disable support for compression filters.
93    </TD>
94    <TD ALIGN="center">-</TD>
95</TR>
96<TR>
97    <TD><CODE>NO_BZIP2</CODE></TD>
98    <TD>
99        Disable support for the bzip2 filters.
100    </TD>
101    <TD><CODE>1</CODE> (Windows)</TD>
102</TR>
103<TR>
104    <TD><CODE>BZIP2_BINARY</CODE></TD>
105    <TD>
106        Name of the libbz2 binary, not including the file extension, or the "lib" prefix on UNIX. On Windows, if linking with a dynamic build of libbz2, specify the name of the import library.
107    </TD>
108    <TD><CODE>bz2</CODE>&nbsp;(UNIX)<BR><CODE>libbz2</CODE>&nbsp;(Windows)</TD>
109</TR>
110<TR>
111    <TD><CODE>BZIP2_INCLUDE</CODE></TD>
112    <TD>
113        Path to the libbz2 headers, if they're not in a location where they'll be found automatically.
114    </TD>
115    <TD><CODE>BZIP2_SOURCE</CODE></TD>
116</TR>
117<TR>
118    <TD><CODE>BZIP2_LIBPATH</CODE></TD>
119    <TD>
120        Path to the libbz2 binary, if it's not in a location where it will be found automatically. On Windows, if linking with a dynamic build of libbz2, specify the path to the import library.
121    </TD>
122    <TD ALIGN="center">-</TD>
123</TR>
124<TR>
125    <TD><CODE>BZIP2_SOURCE</CODE></TD>
126    <TD>
127        Path to the libbz2 source files, if they're not in a location where they'll be found automatically.
128    </TD>
129    <TD ALIGN="center">-</TD>
130</TR>
131<TR>
132    <TD><CODE>NO_ZLIB</CODE></TD>
133    <TD>
134        Disable support for the zlib filters.
135    </TD>
136    <TD><CODE>1</CODE> (Windows)</TD>
137</TR>
138<TR>
139    <TD><CODE>ZLIB_BINARY</CODE></TD>
140    <TD>
141        Name of the zlib binary, not including the file extension, or the "lib" prefix on UNIX. On Windows, if linking with a dynamic build of zlib, specify the name of the import library.
142    </TD>
143    <TD><CODE>z</CODE>&nbsp;(UNIX)<BR><CODE>zdll</CODE>&nbsp;(Windows)</TD>
144</TR>
145<TR>
146    <TD><CODE>ZLIB_INCLUDE</CODE></TD>
147    <TD>
148        Path to the zlib headers, if they're not in a location where they'll be found automatically.
149    </TD>
150    <TD><CODE>ZLIB_SOURCE</CODE></TD>
151</TR>
152<TR>
153    <TD><CODE>ZLIB_LIBPATH</CODE></TD>
154    <TD>
155        Path to the zlib binary, if it's not in a location where it will be found automatically. On Windows, if linking with a dynamic build of zlib, specify the path to the import library.
156    </TD>
157    <TD ALIGN="center">-</TD>
158</TR>
159<TR>
160    <TD><CODE>ZLIB_SOURCE</CODE></TD>
161    <TD>
162        Path to the zlib source files, if they're not in a location where they'll be found automatically.
163    </TD>
164    <TD ALIGN="center">-</TD>
165</TR>
166</TABLE>
167
168<!-- End Footnotes -->
169
170<!-- Begin Footer -->
171
172<HR>
173<P CLASS="copyright">Revised
174<!--webbot bot="Timestamp" S-Type="EDITED" S-Format="%d %B, %Y" startspan -->
17520 May, 2004
176<!--webbot bot="Timestamp" endspan i-checksum="38504" -->
177</P>
178
179<P CLASS="copyright">&copy; Copyright <A HREF="http://www.kangaroologic.com" TARGET="_top">Jonathan Turkanis</A>, 2004</P>
180<P CLASS="copyright"> 
181    Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at <A HREF="http://www.boost.org/LICENSE_1_0.txt">http://www.boost.org/LICENSE_1_0.txt</A>)
182</P>
183
184<!-- End Footer -->
185
186</BODY>
Note: See TracBrowser for help on using the repository browser.