summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteven Knight <knight@baldmt.com>2005-08-11 02:16:07 (GMT)
committerSteven Knight <knight@baldmt.com>2005-08-11 02:16:07 (GMT)
commit0a34420780fe0f7fb3f7a8d9f13eccb8ac1f2738 (patch)
tree454b681bb493584c369999ce8cf966f7401d1e67
parente533041b779711bb840eb5b7121bd8f9509830f3 (diff)
downloadSCons-0a34420780fe0f7fb3f7a8d9f13eccb8ac1f2738.zip
SCons-0a34420780fe0f7fb3f7a8d9f13eccb8ac1f2738.tar.gz
SCons-0a34420780fe0f7fb3f7a8d9f13eccb8ac1f2738.tar.bz2
Win32 portability fixes.
-rw-r--r--src/engine/SCons/dblite.py4
-rw-r--r--test/import.py32
2 files changed, 23 insertions, 13 deletions
diff --git a/src/engine/SCons/dblite.py b/src/engine/SCons/dblite.py
index 18a1202..505a793 100644
--- a/src/engine/SCons/dblite.py
+++ b/src/engine/SCons/dblite.py
@@ -78,7 +78,9 @@ class dblite:
f = _open(self._tmp_name, "wb", self._mode)
cPickle.dump(self._dict, f, 1)
f.close()
- # Win32 doesn't allow renaming if the file exists, so unlink it first.
+ # Win32 doesn't allow renaming if the file exists, so unlink it first,
+ # chmod'ing it to make sure we can do so.
+ os.chmod(self._file_name, 0777)
os.unlink(self._file_name)
os.rename(self._tmp_name, self._file_name)
self._needs_sync = 00000
diff --git a/test/import.py b/test/import.py
index 9c25ada..0c790ba 100644
--- a/test/import.py
+++ b/test/import.py
@@ -135,22 +135,30 @@ tools = [
'zip',
]
-intel_warnings = [
- # License warning.
- """
-scons: warning: Intel license dir was not found. Tried using the INTEL_LICENSE_FILE environment variable (), the registry () and the default path (C:\Program Files\Common Files\Intel\Licenses). Using the default path as a last resort.
-File "SConstruct", line 1, in ?
-""",
- # No top dir warning, 32 bit version.
- """
+# Intel no top dir warning, 32 bit version.
+intel_no_top_dir_32_warning = """
scons: warning: Can't find Intel compiler top dir for version='None', abi='ia32'
File "SConstruct", line 1, in ?
-""",
- # No top dir warning, 64 bit version.
- """
+"""
+
+# Intel no top dir warning, 64 bit version.
+intel_no_top_dir_64_warning = """
scons: warning: Can't find Intel compiler top dir for version='None', abi='x86_64'
File "SConstruct", line 1, in ?
-""",
+"""
+
+# Intel no license directory warning
+intel_license_warning = """
+scons: warning: Intel license dir was not found. Tried using the INTEL_LICENSE_FILE environment variable (), the registry () and the default path (C:\Program Files\Common Files\Intel\Licenses). Using the default path as a last resort.
+File "SConstruct", line 1, in ?
+"""
+
+intel_warnings = [
+ intel_license_warning,
+ intel_no_top_dir_32_warning,
+ intel_no_top_dir_32_warning + intel_license_warning,
+ intel_no_top_dir_64_warning,
+ intel_no_top_dir_64_warning + intel_license_warning,
]
moc = test.where_is('moc')