Merge pull request #4622 from mwichmann/doc/repository
[scons.git] / doc / python10 / install.xml
blobc00b100ddd35283073c6495cb0acf57f9bd6096c
1 <?xml version='1.0'?>
2 <!DOCTYPE sconsdoc [
3     <!ENTITY % scons SYSTEM "../scons.mod">
4     %scons;
5 ]>
7 <section id="sect-install"
8          xmlns="http://www.scons.org/dbxsd/v1.0"
9          xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10          xsi:schemaLocation="http://www.scons.org/dbxsd/v1.0 http://www.scons.org/dbxsd/v1.0/scons.xsd">
11 <title>Installation</title>
13 <!--
15   __COPYRIGHT__
17   Permission is hereby granted, free of charge, to any person obtaining
18   a copy of this software and associated documentation files (the
19   "Software"), to deal in the Software without restriction, including
20   without limitation the rights to use, copy, modify, merge, publish,
21   distribute, sublicense, and/or sell copies of the Software, and to
22   permit persons to whom the Software is furnished to do so, subject to
23   the following conditions:
25   The above copyright notice and this permission notice shall be included
26   in all copies or substantial portions of the Software.
28   THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
29   KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
30   WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
31   NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
32   LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
33   OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
34   WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
36 -->
38 <para>
40   Initial installation of a new utility provides the first, lasting
41   impression of how well the software is likely to perform. From the
42   start, &SCons; has made clean installation a priority.
44 </para>
46 <section>
47   <title>Version Control</title>
49   <para>
51     Distributing an application like &SCons; that depends
52     on a package normally found in a library poses a
53     problem. If the &scons; script and the &SCons; Build Engine
54     are installed separately, it could be easy
55     to introduce a version mismatch between the Build Engine
56     installed in
57     <filename>/usr/lib/python*/site-packages</filename>
58     and the &scons; script installed in
59     <filename>/usr/bin</filename>.
60     Such a mismatch
61     could possible mean exceptions that prevent builds, or even worse,
62     silently unreliable builds.
64   </para>
66   <para>
68     To reduce the possibility of a version mismatch,
69     the &scons; script looks first for its
70     imported modules in <filename>/usr/lib/scons-{version}/</filename>,
71     then in <filename>/usr/lib/scons/</filename>,
72     and then in the normal &PYTHONPATH; locations,
73     including <filename>/usr/lib/python*/site-packages</filename>).
74     Searching in a version-specific library directory first
75     makes it convenient to install and use multiple
76     side-by-side versions of &SCons;,
77     which is sometimes important
78     when verifying that a new version does not introduce any
79     errors into the local build process.
80     Searching next in an &SCons;-specific library directory
81     makes it convenient for other software to find
82     the &SCons; Build Engine without having to worry about
83     installing separate copies for
84     multiple versions of Python.
86   </para>
88 </section>
90 <section>
91   <title>Packages</title>
93   <para>
95     &SCons; is currently distributed in the following packages:
97   </para>
99   <table>
100   <title></title>
101   <tgroup cols="2">
102     <tbody>
104     <row valign="top">
105       <entry>
106         <literal>scons-</literal><emphasis>version</emphasis><literal>.tar.gz</literal>
107       </entry>
108       <entry><para>
110         The traditional <literal>.tar.gz</literal> file,
111         installable by running <filename>setup.py</filename>.
113       </para></entry>
114     </row>
116     <row valign="top">
117       <entry>
118         <literal>scons-</literal><emphasis>version</emphasis><literal>.noarch.rpm</literal>
119       </entry>
120       <entry><para>
122         An RPM file for typical installation.
124       </para></entry>
125     </row>
127     <row valign="top">
128       <entry>
129         <literal>scons-</literal><emphasis>version</emphasis><literal>_all.deb</literal>
130       </entry>
131       <entry><para>
133         A Debian package.
135       </para></entry>
136     </row>
138     <row valign="top">
139       <entry>
140         <literal>scons-</literal><emphasis>version</emphasis><literal>.win32.exe</literal>
141       </entry>
142       <entry><para>
144         A Windows installer.
146       </para></entry>
147     </row>
149     <row valign="top">
150       <entry>
151         <literal>scons-</literal><emphasis>version</emphasis><literal>.src.rpm</literal>
152       </entry>
153       <entry><para>
155         A source RPM file.
157       </para></entry>
158     </row>
160     <row valign="top">
161       <entry>
162         <literal>scons-src-</literal><emphasis>version</emphasis><literal>.tar.gz</literal>
163       </entry>
164       <entry><para>
166         A tarball of the &SCons; source tree,
167         including the full set of regression tests.
169       </para></entry>
170     </row>
172     </tbody>
173   </tgroup>
174   </table>
176   <para>
178     Like other software written in Python, &SCons; benefits greatly from
179     the tremendous effort put into the <literal>distutils</literal> by
180     Greg Ward and others. These take care of 90% of the work by making
181     it almost trivial to generate the appropriate RPM files, Debian
182     packages, and Windows installer.
184   </para>
186 </section>
188 <section>
189   <title>Default Builder Objects</title>
191   <para>
193     As part of the installation process, &SCons; runs a set of scripts
194     that look for popular compilers and other tools and set up
195     appropriate default &Builder; objects for the tools found. These
196     &Builder; objects are then used to initialize the default &consenv;
197     values.
199   </para>
201 </section>
203 <section>
204   <title>Default Scanner Objects</title>
206   <para>
208     Additionally, &SCons; comes with a stock set of &Scanner; objects
209     for the various file types that it supports out of the box. Any
210     unusal &Scanner; objects required for a specific tool will be
211     detected at installation time and associated with the appropriate
212     &Builder; object for the tool.
214   </para>
216 </section>
218 </section>