summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWilliam Deegan <bill@baddogconsulting.com>2017-04-23 17:01:16 -0700
committerWilliam Deegan <bill@baddogconsulting.com>2017-04-23 17:01:16 -0700
commit8bf16ddea63ef3405bf00ba1fb26da0cd60b7b08 (patch)
treed097f3b49745e04332c786c32fcb16201fd40a7c
parentd9cc4fd395a610f3eaaee77ae81eb98d2792e3fa (diff)
downloadscons-git-8bf16ddea63ef3405bf00ba1fb26da0cd60b7b08.tar.gz
py2/3 Allow SConfTests.py to function when pywin32 is not installed.
-rw-r--r--src/engine/SCons/SConfTests.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/engine/SCons/SConfTests.py b/src/engine/SCons/SConfTests.py
index 0daf31ca7..f4c6f899a 100644
--- a/src/engine/SCons/SConfTests.py
+++ b/src/engine/SCons/SConfTests.py
@@ -102,8 +102,11 @@ class SConfTestCase(unittest.TestCase):
import SCons.Platform.win32
- file = SCons.Platform.win32._builtin_file
- open = SCons.Platform.win32._builtin_open
+ try:
+ file = SCons.Platform.win32._builtin_file
+ open = SCons.Platform.win32._builtin_open
+ except AttributeError:
+ pass
def _baseTryXXX(self, TryFunc):
# TryCompile and TryLink are much the same, so we can test them