Anonymous avatar Anonymous committed 4def4dd

Change the copyright statement to reflect ownership by the foundation. Add and fix statements where needed. Update scripts accordingly.

Comments (0)

Files changed (20)

+__COPYRIGHT__
+
 Here you'll find plain text documentation of how to handle various SCons
 project procedures.  Files contained herein:
 
         distributing aedist change sets, and updating the CVS repository
         on SourceForge.
 
+new-platform.txt
+        Steps to add a new Platform/*.py file.  This is probably out
+        of date.
+
+new-script.txt
+        Steps to add a new script or utility (like scons and sconsign)
+        to what we ship.
+
+new-tool.txt
+        Steps to add a new Tool/*.py file.  This is probably out of date.
+
 release.txt
 	Steps to go through when releasing a new version of SCons.
+
+subrelease.txt
+	Steps to go through when releasing a new subsidiary version
+	of SCons--for example, 0.95.1 after we've released 0.95.
+	So far, we've only done this to get some early testing on major
+	refactorings.
+__COPYRIGHT__
+
 Handling a change set:
 
     --	Start the change:

HOWTO/new-platform.txt

+__COPYRIGHT__
+
 Adding a new Platform to the SCons distribution:
 
     --  Add the following files (aenf):

HOWTO/new-script.txt

+__COPYRIGHT__
+
 Steps for adding a new script/utility to the SCons packages.  Assume
 that you're creating a new man page, too.  In the template steps
 below, "newscript" is the name of the new script/utility being added.

HOWTO/new-tool.txt

+__COPYRIGHT__
+
 Adding a new Tool to the SCons distribution:
 
     --  Add the following files (aenf):

HOWTO/release.txt

+__COPYRIGHT__
+
 This document covers how to prepare major releases of SCons--that is,
 releases numbered with X.Y format, such as 0.93, 1.0, etc.
 
                 aecp rpm/scons.spec.in
                 vi rpm/scons.spec.in
 
+                aecp src/copyrightTests.py
+                vi src/copyrightTests.py
+
                 aecp src/setupTests.py
                 vi src/setupTests.py
 
 
 project = 'scons'
 default_version = '0.95'
-copyright = "Copyright (c) %s Steven Knight" % copyright_years
+copyright = "Copyright (c) %s The SCons Foundation" % copyright_years
 
 Default('.')
 
 #!/usr/bin/env python
 #
+# __COPYRIGHT__
+#
 # Count statistics about SCons test and source files.  This must be run
 # against a fully-populated tree (for example, one that's been freshly
 # checked out).
 #
-# A test file is anything under the src/ directory that ends in
-# 'Tests.py', or anything under the test/ directory that ends in '.py'.
+# A test file is anything under the src/ directory that begins with
+# 'test_' or ends in 'Tests.py', or anything under the test/ directory
+# that ends in '.py'.  Note that runtest.py script does *not*, by default,
+# consider the files that begin with 'test_' to be tests, because they're
+# tests of SCons packaging and installation, not functional tests of
+# SCons code.
 #
 # A source file is anything under the src/engine/ or src/script/
-# directories that ends in '.py' but does NOT end in 'Tests.py'.  (We
-# should probably ignore the stuff in src/engine/SCons/Optik, since it
-# doesn't originate with SCons, but what the hell.)
+# directories that ends in '.py' but does NOT begin with 'test_'
+# or end in 'Tests.py'.  (We should probably ignore the stuff in
+# src/engine/SCons/Optik, since it doesn't originate with SCons, but
+# what the hell.)
 #
 # We report the number of tests and sources, the total number of lines
 # in each category, the number of non-blank lines, and the number of
 # interesting one for most purposes.
 #
 
+__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
+
 import os.path
 import string
 
 tests = []
 sources = []
 
+def is_test(x):
+    return x[:5] == 'test_' or x[-8:] == 'Tests.py'
+def is_python(x):
+    return x[-3:] == '.py'
+
 def t(arg, dirname, names):
-    names = filter(lambda n: n[-8:] == 'Tests.py', names)
+    names = filter(is_test, names)
     arg.extend(map(lambda n, d=dirname: os.path.join(d, n), names))
 os.path.walk('src', t, tests)
 
 def p(arg, dirname, names):
-    names = filter(lambda n: n[-3:] == '.py', names)
+    names = filter(is_python, names)
     arg.extend(map(lambda n, d=dirname: os.path.join(d, n), names))
 os.path.walk('test', p, tests)
 
 def s(arg, dirname, names):
-    names = filter(lambda n: n[-3:] == '.py' and n[-8:] != 'Tests.py', names)
+    names = filter(lambda n: is_python(n) and not is_test(n), names)
     arg.extend(map(lambda n, d=dirname: os.path.join(d, n), names))
 os.path.walk('src/engine', s, sources)
 os.path.walk('src/script', s, sources)
 """
 
 #
-# Copyright (c) 2001, 2002, 2003 Steven Knight
+# __COPYRIGHT__
 #
 # Permission is hereby granted, free of charge, to any person obtaining
 # a copy of this software and associated documentation files (the
 #
 
 #
-# Copyright (c) 2001, 2002, 2003 Steven Knight
+# __COPYRIGHT__
 #
 # Permission is hereby granted, free of charge, to any person obtaining
 # a copy of this software and associated documentation files (the
 .fi
 .RE
 ..
-.TH SCONS 1 "November 2003"
+.TH SCONS 1 "August 2004"
 .SH NAME
 scons \- a software construction tool
 .SH SYNOPSIS

doc/man/sconsign.1

-.\" Copyright (c) 2001, 2002, 2003 Steven Knight
+.\" __COPYRIGHT__
 .\"
 .\" Permission is hereby granted, free of charge, to any person obtaining
 .\" a copy of this software and associated documentation files (the
 .\" OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 .\" WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 .\"
-.\" doc/man/scons.1 0.90.D006 2003/07/02 09:02:19 knight
+.\" __FILE__ __REVISION__ __DATE__ __DEVELOPER__
 .\"
 .\" ES - Example Start - indents and turns off line fill
 .de ES
 .RE
 .fi
 ..
-.TH SCONSIGN 1 "September 2003"
+.TH SCONSIGN 1 "August 2004"
 .SH NAME
 sconsign \- print SCons .sconsign file information
 .SH SYNOPSIS

rpm/scons.spec.in

 Version: %{version}
 Release: %{release}
 Source0: %{name}-%{version}.tar.gz
-#Copyright: Steven Knight
+#Copyright: The SCons Foundation
 License: MIT, freely distributable
 Group: Development/Tools
 BuildRoot: %{_tmppath}/%{name}-buildroot
 #!/usr/bin/env python
 #
+# __COPYRIGHT__
+#
 # runtest.py - wrapper script for running SCons tests
 #
 # This script mainly exists to set PYTHONPATH to the right list of
             for g in glob.glob(a):
                 tests.append(Test(g))
 elif all:
+    # Find all of the SCons functional tests in the local directory
+    # tree.  This is anything under the 'src' subdirectory that ends
+    # with 'Tests.py', or any Python script (*.py) under the 'test'
+    # subdirectory.
+    #
+    # Note that there are some tests under 'src' that *begin* with
+    # 'test_', but they're packaging and installation tests, not
+    # functional tests, so we don't execute them by default.  (They can
+    # still be executed by hand, though, and are routinely executed
+    # by the Aegis packaging build to make sure that we're building
+    # things correctly.)
     tdict = {}
 
-    def find_Test_py(arg, dirname, names, tdict=tdict):
+    def find_Tests_py(arg, dirname, names, tdict=tdict):
         for n in filter(lambda n: n[-8:] == "Tests.py", names):
             t = os.path.join(dirname, n)
             if not tdict.has_key(t):
                 tdict[t] = Test(t)
-    os.path.walk('src', find_Test_py, 0)
+    os.path.walk('src', find_Tests_py, 0)
 
     def find_py(arg, dirname, names, tdict=tdict):
         for n in filter(lambda n: n[-3:] == ".py", names):

src/engine/SCons/Tool/aixc++.py

 selection method.
 
 """
-__revision__ = ""
+
+#
+# __COPYRIGHT__
+#
+# Permission is hereby granted, free of charge, to any person obtaining
+# a copy of this software and associated documentation files (the
+# "Software"), to deal in the Software without restriction, including
+# without limitation the rights to use, copy, modify, merge, publish,
+# distribute, sublicense, and/or sell copies of the Software, and to
+# permit persons to whom the Software is furnished to do so, subject to
+# the following conditions:
+#
+# The above copyright notice and this permission notice shall be included
+# in all copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
+# KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
+# WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+#
+
+__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
 
 import os.path
 

src/engine/SCons/Tool/sunc++.py

 selection method.
 
 """
-__revision__ = ""
+
+#
+# __COPYRIGHT__
+#
+# Permission is hereby granted, free of charge, to any person obtaining
+# a copy of this software and associated documentation files (the
+# "Software"), to deal in the Software without restriction, including
+# without limitation the rights to use, copy, modify, merge, publish,
+# distribute, sublicense, and/or sell copies of the Software, and to
+# permit persons to whom the Software is furnished to do so, subject to
+# the following conditions:
+#
+# The above copyright notice and this permission notice shall be included
+# in all copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
+# KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
+# WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+#
+
+__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
 
 import os.path
 

src/script/scons.bat

+REM __COPYRIGHT__
+REM __FILE__ __REVISION__ __DATE__ __DEVELOPER__
 @echo off
 if "%OS%" == "Windows_NT" goto WinNT
 REM for 9x/Me you better not have more than 9 args

src/setupTests.py

-#!/usr/bin/env python
-#
-# __COPYRIGHT__
-#
-# Permission is hereby granted, free of charge, to any person obtaining
-# a copy of this software and associated documentation files (the
-# "Software"), to deal in the Software without restriction, including
-# without limitation the rights to use, copy, modify, merge, publish,
-# distribute, sublicense, and/or sell copies of the Software, and to
-# permit persons to whom the Software is furnished to do so, subject to
-# the following conditions:
-#
-# The above copyright notice and this permission notice shall be included
-# in all copies or substantial portions of the Software.
-#
-# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
-# KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
-# WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
-# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
-# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
-# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
-#
-
-__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
-
-"""
-Test how the setup.py script installs SCons (specifically, its libraries).
-"""
-
-import os
-import os.path
-import shutil
-import string
-import sys
-
-import TestSCons
-
-python = TestSCons.python
-
-class MyTestSCons(TestSCons.TestSCons):
-    def installed(self, lib):
-        lines = string.split(self.stdout(), '\n')
-        return ('Installed SCons library modules into %s' % lib) in lines
-
-try:
-    cwd = os.environ['SCONS_CWD']
-except KeyError:
-    cwd = os.getcwd()
-
-#try:
-#    version = os.environ['SCONS_VERSION']
-#except KeyError:
-#    version = '__VERSION__'
-version = '0.95'
-
-scons_version = 'scons-%s' % version
-
-tar_gz = os.path.join(cwd, 'build', 'dist', '%s.tar.gz' % scons_version)
-
-test = MyTestSCons()
-
-if not os.path.isfile(tar_gz):
-    print "Did not find an SCons package `%s'." % tar_gz
-    print "Cannot test package installation."
-    test.no_result(1)
-
-test.subdir('root', 'prefix')
-
-root = test.workpath('root')
-prefix = test.workpath('prefix')
-
-lib_dir = os.path.join(root + sys.prefix, 'lib')
-standard_lib = os.path.join(lib_dir,
-                            'python%s' % sys.version[:3],
-                            'site-packages/')
-standalone_lib = os.path.join(lib_dir, 'scons')
-version_lib = os.path.join(lib_dir, scons_version)
-
-os.system("gunzip -c %s | tar xf -" % tar_gz)
-
-# Verify that a virgin installation installs the standalone library.
-test.run(chdir = scons_version,
-         program = python,
-         arguments = 'setup.py install --root=%s' % root,
-         stderr = None)
-test.fail_test(not test.installed(standalone_lib))
-
-# Verify that --standard-lib installs into the Python standard library.
-test.run(chdir = scons_version,
-         program = python,
-         arguments = 'setup.py install --root=%s --standard-lib' % root,
-         stderr = None)
-lines = string.split(test.stdout(), '\n')
-test.fail_test(not test.installed(standard_lib))
-
-# Verify that --standalone-lib installs the standalone library.
-test.run(chdir = scons_version,
-         program = python,
-         arguments = 'setup.py install --root=%s --standalone-lib' % root,
-         stderr = None)
-test.fail_test(not test.installed(standalone_lib))
-
-# Verify that --version-lib installs into a version-specific library directory.
-test.run(chdir = scons_version,
-         program = python,
-         arguments = 'setup.py install --root=%s --version-lib' % root,
-         stderr = None)
-test.fail_test(not test.installed(version_lib))
-
-# Now that all of the libraries are in place,
-# verify that a default installation finds the version-specific library first.
-test.run(chdir = scons_version,
-         program = python,
-         arguments = 'setup.py install --root=%s' % root,
-         stderr = None)
-test.fail_test(not test.installed(version_lib))
-
-shutil.rmtree(version_lib)
-
-# Now with only the standard and standalone libraries in place,
-# verify that a default installation finds the standalone library first.
-test.run(chdir = scons_version,
-         program = python,
-         arguments = 'setup.py install --root=%s' % root,
-         stderr = None)
-test.fail_test(not test.installed(standalone_lib))
-
-shutil.rmtree(standalone_lib)
-
-# Now with only the standard libraries in place,
-# verify that a default installation installs the standard library.
-test.run(chdir = scons_version,
-         program = python,
-         arguments = 'setup.py install --root=%s' % root,
-         stderr = None)
-test.fail_test(not test.installed(standard_lib))
-
-# Verify that we're not warning about the directory in which
-# we've installed the modules when using a non-standard prefix.
-test.run(chdir = scons_version,
-         program = python,
-         arguments = 'setup.py install --prefix=%s' % prefix,
-         stderr = None)
-test.fail_test(string.find(test.stderr(),
-                           "you'll have to change the search path yourself")
-               != -1)
-
-# All done.
-test.pass_test()

src/test_copyrights.py

+#!/usr/bin/env python
+#
+# __COPYRIGHT__
+#
+# Permission is hereby granted, free of charge, to any person obtaining
+# a copy of this software and associated documentation files (the
+# "Software"), to deal in the Software without restriction, including
+# without limitation the rights to use, copy, modify, merge, publish,
+# distribute, sublicense, and/or sell copies of the Software, and to
+# permit persons to whom the Software is furnished to do so, subject to
+# the following conditions:
+#
+# The above copyright notice and this permission notice shall be included
+# in all copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
+# KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
+# WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+#
+
+__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
+
+"""
+Verify that we have proper Copyright notices on all the right files
+in our distributions.
+
+Note that this is a packaging test, not a functional test, so the
+name of this script doesn't end in *Tests.py.
+"""
+
+import os
+import os.path
+import re
+import string
+
+import TestSCons
+
+test = TestSCons.TestSCons()
+
+try:
+    cwd = os.environ['SCONS_CWD']
+except KeyError:
+    cwd = os.getcwd()
+
+class Collect:
+    expression = re.compile('Copyright.*The SCons Foundation')
+    def __init__(self, remove_list):
+        self.copyright = []
+        self.no_copyright = []
+        self.remove_list = remove_list
+
+def visit(collect, dirname, names):
+    for r in collect.remove_list:
+        try:
+            names.remove(r)
+        except ValueError:
+            pass
+    for name in map(lambda n, d=dirname: os.path.join(d, n), names):
+        if not os.path.isfile(name):
+            continue
+        if collect.expression.search(open(name, 'r').read()):
+            collect.copyright.append(name)
+        else:
+            collect.no_copyright.append(name)
+
+remove_list = [
+        'build',
+        'debian',
+        'dist',
+        'Optik',
+        'dblite.py',
+        'Conftest.py',
+        'os_spawnv_fix.diff',
+        'setup.cfg',
+]
+
+# XXX Remove '*-stamp' when we get rid of those.
+scons = Collect(remove_list + ['MANIFEST', 'build-stamp', 'configure-stamp'])
+# XXX Remove '.sconsign' when we start using SConsignFile() for SCons builds.
+local = Collect(remove_list + ['.sconsign'])
+# XXX Remove 'doc' when we take care of those Copyright statements.
+src = Collect(remove_list + ['bin', 'doc', 'etc', 'gentoo', 'config', 'MANIFEST.in'])
+
+build_scons = os.path.join(cwd, 'build', 'scons')
+build_local = os.path.join(cwd, 'build', 'scons-local')
+build_src = os.path.join(cwd, 'build', 'scons-src')
+
+no_result = []
+
+if os.path.exists(build_scons):
+    os.path.walk(build_scons, visit, scons)
+else:
+    no_result.append(build_scons)
+
+if os.path.exists(build_local):
+    os.path.walk(build_local, visit, local)
+else:
+    no_result.append(build_local)
+
+if os.path.exists(build_src):
+    os.path.walk(build_src, visit, src)
+else:
+    no_result.append(build_src)
+
+no_copyright = scons.no_copyright + local.no_copyright + src.no_copyright
+
+if no_copyright:
+    print "Found the following files with no copyrights:"
+    print "\t" + string.join(no_copyright, "\n\t")
+    test.fail_test(1)
+
+if no_result:
+    print "Cannot check copyrights, the following have apparently not been built:"
+    print "\t" + string.join(no_result, "\n\t")
+    test.no_result(1)
+
+# All done.
+test.pass_test()

src/test_setup.py

+#!/usr/bin/env python
+#
+# __COPYRIGHT__
+#
+# Permission is hereby granted, free of charge, to any person obtaining
+# a copy of this software and associated documentation files (the
+# "Software"), to deal in the Software without restriction, including
+# without limitation the rights to use, copy, modify, merge, publish,
+# distribute, sublicense, and/or sell copies of the Software, and to
+# permit persons to whom the Software is furnished to do so, subject to
+# the following conditions:
+#
+# The above copyright notice and this permission notice shall be included
+# in all copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY
+# KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
+# WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+# NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+# LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+# OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+# WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+#
+
+__revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__"
+
+"""
+Test how the setup.py script installs SCons (specifically, its libraries).
+
+Note that this is an installation test, not a functional test, so the
+name of this script doesn't end in *Tests.py.
+"""
+
+import os
+import os.path
+import shutil
+import string
+import sys
+
+import TestSCons
+
+python = TestSCons.python
+
+class MyTestSCons(TestSCons.TestSCons):
+    def installed(self, lib):
+        lines = string.split(self.stdout(), '\n')
+        return ('Installed SCons library modules into %s' % lib) in lines
+
+try:
+    cwd = os.environ['SCONS_CWD']
+except KeyError:
+    cwd = os.getcwd()
+
+#try:
+#    version = os.environ['SCONS_VERSION']
+#except KeyError:
+#    version = '__VERSION__'
+version = '0.95'
+
+scons_version = 'scons-%s' % version
+
+tar_gz = os.path.join(cwd, 'build', 'dist', '%s.tar.gz' % scons_version)
+
+test = MyTestSCons()
+
+if not os.path.isfile(tar_gz):
+    print "Did not find an SCons package `%s'." % tar_gz
+    print "Cannot test package installation."
+    test.no_result(1)
+
+test.subdir('root', 'prefix')
+
+root = test.workpath('root')
+prefix = test.workpath('prefix')
+
+lib_dir = os.path.join(root + sys.prefix, 'lib')
+standard_lib = os.path.join(lib_dir,
+                            'python%s' % sys.version[:3],
+                            'site-packages/')
+standalone_lib = os.path.join(lib_dir, 'scons')
+version_lib = os.path.join(lib_dir, scons_version)
+
+os.system("gunzip -c %s | tar xf -" % tar_gz)
+
+# Verify that a virgin installation installs the standalone library.
+test.run(chdir = scons_version,
+         program = python,
+         arguments = 'setup.py install --root=%s' % root,
+         stderr = None)
+test.fail_test(not test.installed(standalone_lib))
+
+# Verify that --standard-lib installs into the Python standard library.
+test.run(chdir = scons_version,
+         program = python,
+         arguments = 'setup.py install --root=%s --standard-lib' % root,
+         stderr = None)
+lines = string.split(test.stdout(), '\n')
+test.fail_test(not test.installed(standard_lib))
+
+# Verify that --standalone-lib installs the standalone library.
+test.run(chdir = scons_version,
+         program = python,
+         arguments = 'setup.py install --root=%s --standalone-lib' % root,
+         stderr = None)
+test.fail_test(not test.installed(standalone_lib))
+
+# Verify that --version-lib installs into a version-specific library directory.
+test.run(chdir = scons_version,
+         program = python,
+         arguments = 'setup.py install --root=%s --version-lib' % root,
+         stderr = None)
+test.fail_test(not test.installed(version_lib))
+
+# Now that all of the libraries are in place,
+# verify that a default installation finds the version-specific library first.
+test.run(chdir = scons_version,
+         program = python,
+         arguments = 'setup.py install --root=%s' % root,
+         stderr = None)
+test.fail_test(not test.installed(version_lib))
+
+shutil.rmtree(version_lib)
+
+# Now with only the standard and standalone libraries in place,
+# verify that a default installation finds the standalone library first.
+test.run(chdir = scons_version,
+         program = python,
+         arguments = 'setup.py install --root=%s' % root,
+         stderr = None)
+test.fail_test(not test.installed(standalone_lib))
+
+shutil.rmtree(standalone_lib)
+
+# Now with only the standard libraries in place,
+# verify that a default installation installs the standard library.
+test.run(chdir = scons_version,
+         program = python,
+         arguments = 'setup.py install --root=%s' % root,
+         stderr = None)
+test.fail_test(not test.installed(standard_lib))
+
+# Verify that we're not warning about the directory in which
+# we've installed the modules when using a non-standard prefix.
+test.run(chdir = scons_version,
+         program = python,
+         arguments = 'setup.py install --prefix=%s' % prefix,
+         stderr = None)
+test.fail_test(string.find(test.stderr(),
+                           "you'll have to change the search path yourself")
+               != -1)
+
+# All done.
+test.pass_test()
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.