*: Regenerate.
[gcc.git] / libstdc++-v3 / doc / html / manual / setup.html
1 <html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>Chapter 2. Setup</title><meta name="generator" content="DocBook XSL-NS Stylesheets V1.76.1"><meta name="keywords" content="
2 ISO C++
3 ,
4 library
5 "><meta name="keywords" content="
6 ISO C++
7 ,
8 runtime
9 ,
10 library
11 "><link rel="home" href="../index.html" title="The GNU C++ Library"><link rel="up" href="intro.html" title="Part I.  Introduction"><link rel="prev" href="bugs.html" title="Bugs"><link rel="next" href="configure.html" title="Configure"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter 2. Setup</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="bugs.html">Prev</a> </td><th width="60%" align="center">Part I. 
12 Introduction
13
14 </th><td width="20%" align="right"> <a accesskey="n" href="configure.html">Next</a></td></tr></table><hr></div><div class="chapter" title="Chapter 2. Setup"><div class="titlepage"><div><div><h2 class="title"><a name="manual.intro.setup"></a>Chapter 2. Setup</h2></div></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><span class="section"><a href="setup.html#manual.intro.setup.prereq">Prerequisites</a></span></dt><dt><span class="section"><a href="configure.html">Configure</a></span></dt><dt><span class="section"><a href="make.html">Make</a></span></dt></dl></div><p>To transform libstdc++ sources into installed include files
15 and properly built binaries useful for linking to other software is
16 a multi-step process. Steps include getting the sources,
17 configuring and building the sources, testing, and installation.
18 </p><p>The general outline of commands is something like:
19 </p><pre class="programlisting">
20 <span class="emphasis"><em>get gcc sources</em></span>
21 <span class="emphasis"><em>extract into gccsrcdir</em></span>
22 mkdir <span class="emphasis"><em>gccbuilddir</em></span>
23 cd <span class="emphasis"><em>gccbuilddir</em></span>
24 <span class="emphasis"><em>gccsrcdir</em></span>/configure --prefix=<span class="emphasis"><em>destdir</em></span> --other-opts...
25 make
26 make check
27 make install
28 </pre><p>
29 Each step is described in more detail in the following sections.
30 </p><div class="section" title="Prerequisites"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="manual.intro.setup.prereq"></a>Prerequisites</h2></div></div></div><p>
31 Because libstdc++ is part of GCC, the primary source for
32 installation instructions is
33 <a class="link" href="http://gcc.gnu.org/install/" target="_top">the GCC install page</a>.
34 In particular, list of prerequisite software needed to build the library
35 <a class="link" href="http://gcc.gnu.org/install/prerequisites.html" target="_top">
36 starts with those requirements.</a> The same pages also list
37 the tools you will need if you wish to modify the source.
38 </p><p>
39 Additional data is given here only where it applies to libstdc++.
40 </p><p>As of GCC 4.0.1 the minimum version of binutils required to build
41 libstdc++ is <code class="code">2.15.90.0.1.1</code>. You can get snapshots
42 (as well as releases) of binutils from
43 <a class="link" href="ftp://sources.redhat.com/pub/binutils/" target="_top">
44 ftp://sources.redhat.com/pub/binutils</a>.
45 Older releases of libstdc++ do not require such a recent version,
46 but to take full advantage of useful space-saving features and
47 bug-fixes you should use a recent binutils whenever possible.
48 The configure process will automatically detect and use these
49 features if the underlying support is present.
50 </p><p>
51 To generate the API documentation from the sources you will need
52 Doxygen, see <a class="link" href="documentation_hacking.html" title="Writing and Generating Documentation">Documentation
53 Hacking</a> in the appendix for full details.
54 </p><p>
55 Finally, a few system-specific requirements:
56 </p><div class="variablelist"><dl><dt><span class="term">linux</span></dt><dd><p>
57 If GCC 3.1.0 or later on is being used on GNU/Linux, an attempt
58 will be made to use "C" library functionality necessary for
59 C++ named locale support. For GCC 4.6.0 and later, this
60 means that glibc 2.3 or later is required.
61 </p><p>
62 If the 'gnu' locale model is being used, the following
63 locales are used and tested in the libstdc++ testsuites.
64 The first column is the name of the locale, the second is
65 the character set it is expected to use.
66 </p><pre class="programlisting">
67 de_DE ISO-8859-1
68 de_DE@euro ISO-8859-15
69 en_GB ISO-8859-1
70 en_HK ISO-8859-1
71 en_PH ISO-8859-1
72 en_US ISO-8859-1
73 en_US.ISO-8859-1 ISO-8859-1
74 en_US.ISO-8859-15 ISO-8859-15
75 en_US.UTF-8 UTF-8
76 es_ES ISO-8859-1
77 es_MX ISO-8859-1
78 fr_FR ISO-8859-1
79 fr_FR@euro ISO-8859-15
80 is_IS UTF-8
81 it_IT ISO-8859-1
82 ja_JP.eucjp EUC-JP
83 ru_RU.ISO-8859-5 ISO-8859-5
84 ru_RU.UTF-8 UTF-8
85 se_NO.UTF-8 UTF-8
86 ta_IN UTF-8
87 zh_TW BIG5
88 </pre><p>Failure to have installed the underlying "C" library
89 locale information for any of the above regions means that
90 the corresponding C++ named locale will not work: because of
91 this, the libstdc++ testsuite will skip named locale tests
92 which need missing information. If this isn't an issue, don't
93 worry about it. If a named locale is needed, the underlying
94 locale information must be installed. Note that rebuilding
95 libstdc++ after "C" locales are installed is not necessary.
96 </p><p>
97 To install support for locales, do only one of the following:
98 </p><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem"><p>install all locales</p></li><li class="listitem"><p>install just the necessary locales</p><div class="itemizedlist"><ul class="itemizedlist" type="circle"><li class="listitem"><p>with Debian GNU/Linux:</p><p> Add the above list, as shown, to the file
99 <code class="code">/etc/locale.gen</code> </p><p> run <code class="code">/usr/sbin/locale-gen</code> </p></li><li class="listitem"><p>on most Unix-like operating systems:</p><p><code class="code"> localedef -i de_DE -f ISO-8859-1 de_DE </code></p><p>(repeat for each entry in the above list) </p></li><li class="listitem"><p>
100 Instructions for other operating systems solicited.
101 </p></li></ul></div></li></ul></div></dd></dl></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="bugs.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="intro.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="configure.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Bugs </td><td width="20%" align="center"><a accesskey="h" href="../index.html">Home</a></td><td width="40%" align="right" valign="top"> Configure</td></tr></table></div></body></html>