diff options
Diffstat (limited to 'test/Fortran/FORTRANFLAGS.py')
-rw-r--r-- | test/Fortran/FORTRANFLAGS.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/test/Fortran/FORTRANFLAGS.py b/test/Fortran/FORTRANFLAGS.py index 8d77d63..6dd27d7 100644 --- a/test/Fortran/FORTRANFLAGS.py +++ b/test/Fortran/FORTRANFLAGS.py @@ -29,7 +29,7 @@ import string import sys import TestSCons -python = TestSCons.python +_python_ = TestSCons._python_ test = TestSCons.TestSCons() _exe = TestSCons._exe @@ -90,9 +90,9 @@ sys.exit(0) test.write('SConstruct', """ -env = Environment(LINK = r'%s mylink.py', +env = Environment(LINK = r'%(_python_)s mylink.py', LINKFLAGS = [], - FORTRAN = r'%s myfortran.py', + FORTRAN = r'%(_python_)s myfortran.py', FORTRANFLAGS = '-x') env.Program(target = 'test01', source = 'test01.f') env.Program(target = 'test02', source = 'test02.F') @@ -108,7 +108,7 @@ env.Program(target = 'test11', source = 'test11.f90') env.Program(target = 'test12', source = 'test12.F90') env.Program(target = 'test13', source = 'test13.f95') env.Program(target = 'test14', source = 'test14.F95') -""" % (python, python)) +""" % locals()) test.write('test01.f', "This is a .f file.\n#link\n#fortran\n") test.write('test02.F', "This is a .F file.\n#link\n#fortran\n") @@ -158,12 +158,12 @@ os.system(string.join(sys.argv[1:], " ")) """ % string.replace(test.workpath('wrapper.out'), '\\', '\\\\')) test.write('SConstruct', """ -foo = Environment(LIBS = %s) +foo = Environment(LIBS = %(FTN_LIB)s) f77 = foo.Dictionary('FORTRAN') -bar = foo.Copy(FORTRAN = r'%s wrapper.py ' + f77, FORTRANFLAGS = '-Ix') +bar = foo.Copy(FORTRAN = r'%(_python_)s wrapper.py ' + f77, FORTRANFLAGS = '-Ix') foo.Program(target = 'foo', source = 'foo.f') bar.Program(target = 'bar', source = 'bar.f') -""" % (FTN_LIB, python)) +""" % locals()) test.write('foo.f', r""" PROGRAM FOO |