diff options
author | Steven Knight <knight@baldmt.com> | 2001-10-17 16:42:21 (GMT) |
---|---|---|
committer | Steven Knight <knight@baldmt.com> | 2001-10-17 16:42:21 (GMT) |
commit | 772ede31d7a5aed0c72943be9230313de687e0be (patch) | |
tree | f017114c2e9f7c7b8530f6216401a07b398d4b5f /test/CC.py | |
parent | 3b884c9421bae33e2c7a204aacc5fdc2d9394423 (diff) | |
download | SCons-772ede31d7a5aed0c72943be9230313de687e0be.zip SCons-772ede31d7a5aed0c72943be9230313de687e0be.tar.gz SCons-772ede31d7a5aed0c72943be9230313de687e0be.tar.bz2 |
Portability fixes for tests on Windows Nt.
Diffstat (limited to 'test/CC.py')
-rw-r--r-- | test/CC.py | 9 |
1 files changed, 6 insertions, 3 deletions
@@ -25,24 +25,27 @@ __revision__ = "__FILE__ __REVISION__ __DATE__ __DEVELOPER__" import os +import sys import TestSCons +python = sys.executable + test = TestSCons.TestSCons() test.write("ccwrapper.py", """import os import string import sys -open('%s', 'w').write("ccwrapper.py\\n") +open('%s', 'wb').write("ccwrapper.py\\n") os.system(string.join(["cc"] + sys.argv[1:], " ")) """ % test.workpath('ccwrapper.out')) test.write('SConstruct', """ foo = Environment() -bar = Environment(CC = 'python ccwrapper.py') +bar = Environment(CC = r'%s ccwrapper.py') foo.Program(target = 'foo', source = 'foo.c') bar.Program(target = 'bar', source = 'bar.c') -""") +""" % python) test.write('foo.c', """ int |