diff options
author | Steven Knight <knight@baldmt.com> | 2008-04-21 06:38:31 (GMT) |
---|---|---|
committer | Steven Knight <knight@baldmt.com> | 2008-04-21 06:38:31 (GMT) |
commit | b6b2ec2e51c69753c187f8712ad4c0bb6dfa6d9a (patch) | |
tree | 512353b30aa2af47f79bcd816ea27ac65cf1303f /src/engine | |
parent | a31e3ee17cd9fed32ca0cf1c7a14aff318c8608a (diff) | |
download | SCons-b6b2ec2e51c69753c187f8712ad4c0bb6dfa6d9a.zip SCons-b6b2ec2e51c69753c187f8712ad4c0bb6dfa6d9a.tar.gz SCons-b6b2ec2e51c69753c187f8712ad4c0bb6dfa6d9a.tar.bz2 |
Merged revisions 2880-2883,2885-2895 via svnmerge from
http://scons.tigris.org/svn/scons/branches/core
........
r2885 | stevenknight | 2008-04-18 21:38:59 -0700 (Fri, 18 Apr 2008) | 2 lines
Update troubleshooting appendix for new Taskmaster output.
........
r2886 | bdbaddog | 2008-04-19 15:15:03 -0700 (Sat, 19 Apr 2008) | 5 lines
Fix infinite loop in Fortran tool initialization.
Bug 2017.
Steven fixed, I tested.
........
r2887 | garyo | 2008-04-20 17:44:46 -0700 (Sun, 20 Apr 2008) | 1 line
Added this in two sections; simple one when discussing simple builds, and an example in the VariantDir section showing how it still works there.
........
r2888 | stevenknight | 2008-04-20 21:33:01 -0700 (Sun, 20 Apr 2008) | 4 lines
Accomodate test/MSVC/msvc.py's reliance on the Windows Platform SDK
(for now) by making use of the user's %INCLUDE% and %LIB% variables.
Split some independent embedded subtests into their own test scripts.
........
r2889 | stevenknight | 2008-04-20 21:38:05 -0700 (Sun, 20 Apr 2008) | 2 lines
Windows portability fix (line endings).
........
r2890 | stevenknight | 2008-04-20 21:44:24 -0700 (Sun, 20 Apr 2008) | 2 lines
Update Windows portion of if:-elif: block for a variable name change.
........
r2891 | stevenknight | 2008-04-20 21:52:41 -0700 (Sun, 20 Apr 2008) | 3 lines
On Windows, escape backslashes on the --interactive command line input,
so people can build targets in other directories.
........
r2892 | stevenknight | 2008-04-20 21:56:50 -0700 (Sun, 20 Apr 2008) | 3 lines
Fix ripple effects on Windows from redefining how $CXXFLAGS gets
added to C++ command lines.
........
r2893 | stevenknight | 2008-04-20 22:04:50 -0700 (Sun, 20 Apr 2008) | 4 lines
Handle a ripple effect from redefining the file() and open() builtin
functions by explicitly restoring the originals whenever we reset
the global state between tests.
........
r2894 | stevenknight | 2008-04-20 23:17:23 -0700 (Sun, 20 Apr 2008) | 2 lines
Remove by-hand backslash escaping, now that --interactive mode is handling it.
........
r2895 | stevenknight | 2008-04-20 23:23:04 -0700 (Sun, 20 Apr 2008) | 2 lines
Mention the fix for the Fortran suffix out-of-memory bug
........
Diffstat (limited to 'src/engine')
-rw-r--r-- | src/engine/SCons/ActionTests.py | 3 | ||||
-rw-r--r-- | src/engine/SCons/SConfTests.py | 16 | ||||
-rw-r--r-- | src/engine/SCons/Script/Interactive.py | 2 | ||||
-rw-r--r-- | src/engine/SCons/Tool/FortranCommon.py | 7 |
4 files changed, 22 insertions, 6 deletions
diff --git a/src/engine/SCons/ActionTests.py b/src/engine/SCons/ActionTests.py index f25f232..a503981 100644 --- a/src/engine/SCons/ActionTests.py +++ b/src/engine/SCons/ActionTests.py @@ -1003,7 +1003,8 @@ class CommandActionTestCase(unittest.TestCase): # NT treats execs of directories and non-executable files # as "file not found" errors expect_nonexistent = 1 - expect_nonexecutable = 1 + expect_nonexecutable_file = 1 + expect_nonexecutable_dir = 1 elif sys.platform == 'cygwin': expect_nonexistent = 127 # Newer cygwin seems to return 126 for following diff --git a/src/engine/SCons/SConfTests.py b/src/engine/SCons/SConfTests.py index 25c89d2..ba9f2f5e 100644 --- a/src/engine/SCons/SConfTests.py +++ b/src/engine/SCons/SConfTests.py @@ -88,7 +88,21 @@ class SConfTestCase(unittest.TestCase): if self.scons_env['CXX'] == 'g++': global existing_lib existing_lib = 'm' - + + if sys.platform in ['cygwin', 'win32']: + # On Windows, SCons.Platform.win32 redefines the builtin + # file() and open() functions to close the file handles. + # This interferes with the unittest.py infrastructure in + # some way. Just sidestep the issue by restoring the + # original builtin functions whenever we have to reset + # all of our global state. + + import __builtin__ + import SCons.Platform.win32 + + __builtin__.file = SCons.Platform.win32._builtin_file + __builtin__.open = SCons.Platform.win32._builtin_open + def _baseTryXXX(self, TryFunc): # TryCompile and TryLink are much the same, so we can test them # in one method, we pass the function as a string ('TryCompile', diff --git a/src/engine/SCons/Script/Interactive.py b/src/engine/SCons/Script/Interactive.py index b1774eb..9510892 100644 --- a/src/engine/SCons/Script/Interactive.py +++ b/src/engine/SCons/Script/Interactive.py @@ -145,6 +145,8 @@ class SConsInteractiveCmd(cmd.Cmd): line = 'shell ' + line[1:] elif line[0] == '?': line = 'help ' + line[1:] + if os.sep == '\\': + line = string.replace(line, '\\', '\\\\') argv = shlex.split(line) argv[0] = self.synonyms.get(argv[0], argv[0]) if not argv[0]: diff --git a/src/engine/SCons/Tool/FortranCommon.py b/src/engine/SCons/Tool/FortranCommon.py index 579b4dd..82a5a6c 100644 --- a/src/engine/SCons/Tool/FortranCommon.py +++ b/src/engine/SCons/Tool/FortranCommon.py @@ -92,12 +92,11 @@ def ComputeFortranSuffixes(suffixes, ppsuffixes): assert len(suffixes) > 0 s = suffixes[0] sup = string.upper(s) + upper_suffixes = map(string.upper, suffixes) if SCons.Util.case_sensitive_suffixes(s, sup): - for i in suffixes: - ppsuffixes.append(string.upper(i)) + ppsuffixes.extend(upper_suffixes) else: - for i in suffixes: - suffixes.append(string.upper(i)) + suffixes.extend(upper_suffixes) def CreateDialectActions(dialect): """Create dialect specific actions.""" |