diff options
author | Steven Knight <knight@baldmt.com> | 2003-06-17 20:54:43 (GMT) |
---|---|---|
committer | Steven Knight <knight@baldmt.com> | 2003-06-17 20:54:43 (GMT) |
commit | 9789be004e64007438c3dae0669ef8f08f2e5adb (patch) | |
tree | d9fb46f32d60eeb787fba06be3aa958ef4621b0d | |
parent | ba5e0ae491d9078daa733ab0de6732db11a5c852 (diff) | |
download | SCons-9789be004e64007438c3dae0669ef8f08f2e5adb.zip SCons-9789be004e64007438c3dae0669ef8f08f2e5adb.tar.gz SCons-9789be004e64007438c3dae0669ef8f08f2e5adb.tar.bz2 |
When linking long command lines, use a '.lnk' suffix on the temporary file name. (Charles Crain)
-rw-r--r-- | src/CHANGES.txt | 44 | ||||
-rw-r--r-- | src/engine/SCons/Platform/win32.py | 31 |
2 files changed, 9 insertions, 66 deletions
diff --git a/src/CHANGES.txt b/src/CHANGES.txt index 6cb5ed8..1222d44 100644 --- a/src/CHANGES.txt +++ b/src/CHANGES.txt @@ -10,21 +10,11 @@ RELEASE 0.15 - XXX - From Chad Austin: - - - Fix the _concat() documentation, and add a test for it. - - - Portability fixes for non-GNU versions of lex and yacc. - From Matt Balvin: - Fix handling of library prefixes when the subdirectory matches the prefix. - From Timothee Bessett: - - - Add an M4 Builder. - From Charles Crain: - Use '.lnk' as the suffix on the temporary file for linking long @@ -36,51 +26,19 @@ RELEASE 0.15 - XXX must have the same form as valid Python identifiers. - Fix man page bugs: remove duplicate AddPostAction() description; - document no_import_lib; mention that CPPFLAGS does not contain - $_CPPINCFLAGS; mention that F77FLAGS does not contain $_F77INCFLAGS; - mention that LINKFLAGS and SHLINKFLAGS contains neither $_LIBFLAGS - nor $_LIBDIRFLAGS. + document no_import_lib. - Eliminate a dependency on the distutils.fancy_getopt module by copying and pasting its wrap_text() function directly. - - Make the Script.Options() subclass match the underlying base class - implementation. - From Steve Leblanc: - Don't update the .sconsign files when run with -n. - From Gary Oberbrunner: - - - Add support for the Intel C Compiler (icl.exe). - - From Anthony Roach - - - Fix Import('*'). - - From David Snopek - - - Fix use of SConf in paths with white space in them. - - - Add CheckFunc and CheckType functionality to SConf. - - - Fix use of SConf with Builders that return a list of nodes. - From David Snopek and Christoph Wiedemann - Fix use of the SConf subsystem with SConscriptChdir(). - From Greg Spencer - - - Check for the existence of MS Visual Studio on disk before using it, - to avoid getting fooled by leftover junk in the registry. - - - Add support for MSVC++ .NET. - - - Add support for MS Visual Studio project files (DSP, DSW, - SLN and VCPROJ files). - RELEASE 0.14 - Wed, 21 May 2003 05:16:32 -0500 diff --git a/src/engine/SCons/Platform/win32.py b/src/engine/SCons/Platform/win32.py index 6aafa95..6874d01 100644 --- a/src/engine/SCons/Platform/win32.py +++ b/src/engine/SCons/Platform/win32.py @@ -68,7 +68,11 @@ class TempFileMunge: # a bug in Win32 that will use a forward slash as a path # delimiter. Win32's link mistakes that for a command line # switch and barfs. - tmp = os.path.normpath(tempfile.mktemp()) + # + # We use the .lnk suffix for the benefit of the Phar Lap + # linkloc linker, which likes to append an .lnk suffix if + # none is given. + tmp = os.path.normpath(tempfile.mktemp('.lnk')) native_tmp = SCons.Util.get_native_path(tmp) # The sh shell will try to escape the backslashes in the @@ -156,8 +160,9 @@ def spawn(sh, escape, cmd, args, env): sys.stderr.write("scons: %s: %s\n" % (cmd, e[1])) return ret -# Windows does not allow special characters in file names anyway, so -# no need for a complex escape function, we will just quote the arg. +# Windows does not allow special characters in file names +# anyway, so no need for an escape function, we will just quote +# the arg. escape = lambda x: '"' + x + '"' # Get the windows system directory name @@ -228,30 +233,10 @@ def generate(env): cmd_interp = os.path.join(val, 'command.com') except: pass - - # For the special case of not having access to the registry, we - # use a temporary path and pathext to attempt to find the command - # interpreter. If we fail, we try to find the interpreter through - # the env's PATH. The problem with that is that it might not - # contain an ENV and a PATH. - if not cmd_interp: - systemroot = r'C:\Windows' - if os.environ.has_key('SYSTEMROOT'): - systemroot = os.environ['SYSTEMROOT'] - tmp_path = systemroot + os.pathsep + \ - os.path.join(systemroot,'System32') - tmp_pathext = '.com;.exe;.bat;.cmd' - if os.environ.has_key('PATHEXT'): - tmp_pathext = os.environ['PATHEXT'] - cmd_interp = SCons.Util.WhereIs('cmd', tmp_path, tmp_pathext) - if not cmd_interp: - cmd_interp = SCons.Util.WhereIs('command', tmp_path, tmp_pathext) - if not cmd_interp: cmd_interp = env.Detect('cmd') if not cmd_interp: cmd_interp = env.Detect('command') - if not env.has_key('ENV'): env['ENV'] = {} |