Initialize the 0.12 branch
[scons.git] / README
diff --git a/README b/README
index 34e27c8c37df27d0775cefca8870f77d84f83aaf..b20758491b51cb352b7667423f6cb7e787537f4b 100644 (file)
--- a/README
+++ b/README
@@ -1,10 +1,10 @@
-# Copyright (c) 2001, 2002 Steven Knight
+# __COPYRIGHT__
 
                  SCons - a software construction tool
 
-Welcome to the SCons development tree.  The purpose of this tree is
-not just to hack SCons code, but to package SCons for production
-distribution.
+Welcome to the SCons development tree.  The real purpose of this tree is
+to package SCons for production distribution in a variety of formats,
+not just to hack SCons code.
 
 To that extent, the normal development cycle (enforced by Aegis) is not
 to test the code directly, but to package SCons, unpack the package,
@@ -15,8 +15,8 @@ be packaged.
 
 Note that if all you want to do is install and run SCons, it
 will probably be easier for you to download and install the
-scons-{version}.tar.gz package rather than to work with the packaging
-logic in this tree.
+scons-{version}.tar.gz or scons-{version}.zip package rather than to
+work with the packaging logic in this tree.
 
 
 LATEST VERSION
@@ -28,50 +28,140 @@ latest version at the SCons download page:
         http://www.scons.org/download.html
 
 
+EXECUTION REQUIREMENTS
+======================
+
+Running SCons requires Python version 1.5.2 or later.  There should be
+no other dependencies or requirements to run SCons.
+
+The default SCons configuration assumes use of the Microsoft Visual C++
+compiler suite on WIN32 systems, and assumes a C compiler named 'cc',
+a C++ compiler named 'c++', and a Fortran compiler named 'g77' (such
+as found in the GNU C compiler suite) on any other type of system.
+You may, of course, override these default values by appropriate
+configuration of Environment construction variables.
+
+By default, SCons knows how to search for available programming tools
+on various systems--see the SCons man page for details.  You may,
+of course, override the default SCons choices made by appropriate
+configuration of Environment construction variables.
+
+
+INSTALLATION REQUIREMENTS
+=========================
+
+Building and installing SCons from this package requires the Python
+distutils package.  The distutils package was not shipped as a standard
+part of Python until Python version 1.6, so if your system is running
+Python 1.5.2, you may not have distutils installed.  If you are running
+Python version 1.6 or later, you should be fine.
+
+NOTE TO RED HAT USERS:  All Red Hat Linux versions up to 7.3 still ship
+Python 1.5.2 as the default, so you probably do *not* have distutils
+installed, unless you have already done so manually or are running Red
+Hat 8.0 or later.
+
+In this case, your options are:
+
+    --  (Optional.)  Install from a pre-packaged SCons package that
+        does not require distutils:
+
+            Red Hat Linux       scons-0.12-1.noarch.rpm
+
+            Debian GNU/Linux    scons_0.12-1_all.deb
+                                (or use apt-get)
+
+            Windows             scons-0.12.win32.exe
+
+    --  (Recommended.)  Download the latest distutils package from the
+        following URL:
+
+            http://www.python.org/sigs/distutils-sig/download.html
+
+        Install the distutils according to the instructions on the page.
+        You can then proceed to the next section to install SCons from
+        this package.
+
+
 INSTALLATION
 ============
 
-To install SCons from this package, you must first populate the
-build/scons/ directory.  (For an easier way to install SCons, without
-having to populate this directory, use the scons-{version}.tar.gz
-package.)
+Assuming your system satisfies the installation requirements in
+the previous section, install SCons from this package by first
+populating the build/scons/ directory.  (For an easier way to
+install SCons, without having to populate this directory, use the
+scons-{version}.tar.gz or scons-{version}.zip package.)
 
 If you already have an appropriate version of SCons installed on your
 system, populate the build/scons/ directory by running:
 
         $ scons build/scons
 
-If you don't have SCons version 0.04 or later already installed on your
+If you don't have SCons version 0.11 or later already installed on your
 system, you can use SCons itself to populate the build/scons/ directory
-with a little more work:
+with a little more typing:
 
         $ SCONS_LIB_DIR=`pwd`/src/engine python src/script/scons.py build/scons
 
-Either command populates the build/scons/ directory with the necessary
-files and directory structure to use the Python-standard setup script as
-follows:
+Either command will populate the build/scons/ directory with the
+necessary files and directory structure to use the Python-standard setup
+script as follows:
 
         # cd build/scons
         # python setup.py install
 
-This will install the scons script in the default system script
-directory (/usr/bin or C:\Python*\Scripts, for example) and the build
-engine in an appropriate SCons library directory (/usr/lib/scons or
-C:\Python*\SCons, for example).
+If this is the first time you are installing SCons on your system,
+the above command will install the scons script in the default system
+script directory (/usr/bin or C:\Python*\Scripts, for example) and the
+build engine in an appropriate stand-alone SCons library directory
+(/usr/lib/scons or C:\Python*\scons, for example).
+
+Note that, by default, SCons does not install its library in the
+standard Python library directories.  If you want to be able to use the
+SCons library modules (the build engine) in other Python scripts, you
+can run the setup script as follows:
+
+        # cd build/scons
+        # python setup.py install --standard-lib
+
+This will install the build engine in the standard Python
+library directory (/usr/lib/python*/site-packages or
+C:\Python*\Lib\site-packages).
+
+Alternatively, you may want to install multiple versions of SCons
+side-by-side, which you can do as follows:
+
+        # cd build/scons
+        # python setup.py install --version-lib
 
-You should have system installation privileges (that is, "root" or
-"Administrator") when running the setup.py script to install SCons in
-the default system directories.
+This will install the build engine in a version-specific library
+directory (/usr/lib/scons-__VERSION__ or C:\Python*\scons-__VERSION__).
 
-If you don't have system installation privileges, you can use the
---prefix option to specify an alternate installation location, such as
-your home directory:
+If this is not the first time you are installing SCons on your system,
+the setup script will, by default, search for where you have previously
+installed the SCons library, and install this version's library the
+same way--that is, if you previously installed the SCons library in
+the standard Python library, the setup script will install this one
+in the same location.  You may, of course, specify one of the --*-lib
+options described above to select a specific library location, or use
+the following option to explicitly select installation into the default
+standalone library directory (/usr/lib/scons or C:\Python*\scons):
+
+        # cd build/scons
+        # python setup.py install --standalone-lib
+
+Note that, to install SCons in any of the above system directories,
+you should have system installation privileges (that is, "root" or
+"Administrator") when running the setup.py script.  If you don't have
+system installation privileges, you can use the --prefix option to
+specify an alternate installation location, such as your home directory:
 
         $ cd build/scons
         $ python setup.py install --prefix=$HOME
 
-This will install the scons script itself in $HOME/bin and the
-associated library in $HOME/lib/scons
+This will install SCons in the appropriate locations relative to
+$HOME--that is, the scons script itself $HOME/bin and the associated
+library in $HOME/lib/scons, for example.
 
 
 TESTING
@@ -79,11 +169,14 @@ TESTING
 
 Tests are run by the runtest.py script in this directory.
 
-There are two types of tests in this package.  Unit tests for individual
-SCons modules live underneath the src/engine/ subdirectory and are the
-same base name as the module with "Tests.py" appended--for example,
-the unit test for the Builder.py module is the BuilderTests.py script.
-End-to-end tests of SCons live in the test/ subdirectory.
+There are two types of tests in this package:
+
+    Unit tests for individual SCons modules live underneath the
+    src/engine/ subdirectory and are the same base name as the module
+    with "Tests.py" appended--for example, the unit test for the
+    Builder.py module is the BuilderTests.py script.
+
+    End-to-end tests of SCons live in the test/ subdirectory.
 
 You may specifically list one or more tests to be run:
 
@@ -102,39 +195,41 @@ unsuccessful tests.
 
 The above invocations all test directly the files underneath the src/
 subdirectory, and do not require that a build be performed first.  The
-runtest.py script supports supports additional options to run tests
-against unpacked packages in the build/test*/ subdirectories.  This is
-in the process of being reworked for the next release, however, so for
-now, see the comments in the runtest.py script itself if you want to run
-tests against a package.
+runtest.py script supports additional options to run tests against
+unpacked packages in the build/test-*/ subdirectories.  See the "TESTING
+PACKAGES" section below.
 
 
 BUILDING PACKAGES
 =================
 
-We now use SCons (version 0.04 or later) to build its own packages.
+We now use SCons (version 0.11 or later) to build its own packages.
 If you already have an appropriate version of SCons installed on your
 system, you can build everything by simply running it:
 
         $ scons
 
-If you don't have SCons version 0.04 or later already installed on your
+If you don't have SCons version 0.11 or later already installed on your
 system, you can build this version of SCons with itself with a little
-more work:
+more typing:
 
         $ SCONS_LIB_DIR=`pwd`/src/engine python src/script/scons.py
 
 Depending on the utilities installed on your system, any or all of the
 following packages will be built:
 
-        build/dist/scons-0.04-1.noarch.rpm
-        build/dist/scons-0.04-1.src.rpm
-        build/dist/scons-0.04.linux-i686.tar.gz
-        build/dist/scons-0.04.tar.gz
-        build/dist/scons-0.04.win32.exe
-        build/dist/scons-doc-0.04.tar.gz
-        build/dist/scons-src-0.04.tar.gz
-        build/dist/scons_0.04-1_all.deb
+        build/dist/scons-0.12-1.noarch.rpm
+        build/dist/scons-0.12-1.src.rpm
+        build/dist/scons-0.12.linux-i686.tar.gz
+        build/dist/scons-0.12.tar.gz
+        build/dist/scons-0.12.win32.exe
+        build/dist/scons-0.12.zip
+        build/dist/scons-doc-0.12.tar.gz
+        build/dist/scons-local-0.12.tar.gz
+        build/dist/scons-local-0.12.zip
+        build/dist/scons-src-0.12.tar.gz
+        build/dist/scons-src-0.12.zip
+        build/dist/scons_0.12-1_all.deb
 
 The SConstruct file is supposed to be smart enough to avoid trying to
 build packages for which you don't have the proper utilities installed.
@@ -142,12 +237,43 @@ For example, if you don't have Debian packaging tools installed, it
 should just not build the .deb package, not fail the build.
 
 If you receive a build error, please report it to the scons-devel
-mailing list.
+mailing list and open a bug report on the SCons bug tracker.
 
 Note that in addition to creating the above packages, the default build
 will also unpack one or more of the packages for testing.
 
 
+TESTING PACKAGES
+================
+
+A full build will unpack and/or install any .deb, .rpm., .local.tar.gz,
+.local.zip, .src.tar.gz, .src.zip, .tar.gz, and .zip packages into
+separate build/test-*/ subdirectories.  (Of course, if a package was
+not built on your system, it should not try to install it.)  The
+runtest.py script supports a -p option that will run the specified tests
+(individually or collectively via the -a option) against the unpacked
+build/test-/* subdirectory:
+
+        $ python runtest.py -p deb
+
+        $ python runtest.py -p rpm
+
+        $ python runtest.py -p local-tar-gz
+
+        $ python runtest.py -p local-zip
+
+        $ python runtest.py -p src-tar-gz
+
+        $ python runtest.py -p src-zip
+
+        $ python runtest.py -p tar-gz
+
+        $ python runtest.py -p zip
+
+(The canonical invocation is to also use the runtest.py -a option so
+that all tests are run against the specified package.)
+
+
 CONTENTS OF THIS PACKAGE
 ========================
 
@@ -158,16 +284,17 @@ bin/
         there's a copy of the script we use to translate an Aegis change
         into a CVS checkin.
 
+bootstrap.py
+        A build script for use with Aegis.  This collects a current copy
+        of SCons from the Aegis baseline directories in a bootstrap/
+        subdirectory, and then executes SCons with the supplied
+        command-line arguments.
+
 build/
         This doesn't exist yet if you're looking at a vanilla source
         tree.  This is generated as part of our build process, and it's
         where, believe it or not, we *build* everything.
 
-Construct
-        The old "Makefile" Cons-based for the SCons distribution.  This
-        is obsolete as of version 0.04, but it's being left around for a
-        little while, just in case...
-
 config
         The Aegis configuration, governing much of how we use Aegis to
         build, test, control source, etc.
@@ -194,14 +321,30 @@ HOWTO/
         change, releasing a new version).  Maybe other administrative
         stuff in the future.
 
+LICENSE
+        A copy of the copyright and terms under which SCons is
+        distributed (the Open Source Initiative-approved MIT license).
+
+LICENSE-local
+        A copy of the copyright and terms under which SCons is
+        distributed for inclusion in the scons-local-{version} packages.
+        This is the same as LICENSE with a preamble that specifies
+        the licensing terms are for SCons itself, not any other
+        package that includes SCons.
+
 README
         What you're looking at right now.
 
+README-local
+        A README file for inclusion in the scons-local-{version}
+        packages.  Similar to this file, but stripped down and modified
+        for people looking at including SCons in their shipped software.
+
 rpm/
         The .spec file for building our RPM packages.
 
 runtest.py
-        Script for running our tests.  By default, this will run a
+        Script for running SCons tests.  By default, this will run a
         test against the code in the local src/ tree, so you don't
         have to do a build before testing your changes.  Aegis uses
         it with an option that requires that you've done a build
@@ -210,6 +353,15 @@ runtest.py
 SConstruct
         The "Makefile" for the SCons distribution.
 
+        (It has been pointed out that it's hard to find the SCons API
+        in this SConstruct file, and that it looks a lot more like a
+        pure Python script than a build configuration file.  That's
+        mainly because all of the magick we have to perform to deal with
+        all of the different packaging formats requires a lot of pure
+        Python manipulation.  In other words, don't look at this file
+        for an example of how easy it is to use SCons to build "normal"
+        software.)
+
 src/
         Where the actual source code is kept, of course.
 
@@ -242,7 +394,7 @@ LICENSING
 =========
 
 SCons is distributed under the MIT license, a full copy of which is
-available in the LICENSE.txt file. The MIT license is an approved Open
+available in the LICENSE file. The MIT license is an approved Open
 Source license, which means:
 
         This software is OSI Certified Open Source Software.  OSI
@@ -299,9 +451,10 @@ Steven Knight
 knight at baldmt dot com
 http://www.baldmt.com/~knight/
 
-With more than a little help from the SCons Development team:
+With plenty of help from the SCons Development team:
         Chad Austin
         Charles Crain
         Steve Leblanc
         Anthony Roach
+        Terrel Shumway