diff options
Diffstat (limited to 'test/Fortran/F77.py')
-rw-r--r-- | test/Fortran/F77.py | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/test/Fortran/F77.py b/test/Fortran/F77.py index 1c27def..682cfb0 100644 --- a/test/Fortran/F77.py +++ b/test/Fortran/F77.py @@ -29,7 +29,7 @@ import string import sys import TestSCons -python = TestSCons.python +_python_ = TestSCons._python_ _exe = TestSCons._exe test = TestSCons.TestSCons() @@ -88,10 +88,10 @@ sys.exit(0) """) test.write('SConstruct', """ -env = Environment(LINK = r'%s mylink.py', +env = Environment(LINK = r'%(_python_)s mylink.py', LINKFLAGS = [], - F77 = r'%s myfortran.py g77', - FORTRAN = r'%s myfortran.py fortran') + F77 = r'%(_python_)s myfortran.py g77', + FORTRAN = r'%(_python_)s myfortran.py fortran') env.Program(target = 'test01', source = 'test01.f') env.Program(target = 'test02', source = 'test02.F') env.Program(target = 'test03', source = 'test03.for') @@ -106,9 +106,9 @@ 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') -env2 = Environment(LINK = r'%s mylink.py', +env2 = Environment(LINK = r'%(_python_)s mylink.py', LINKFLAGS = [], - F77 = r'%s myfortran.py g77') + F77 = r'%(_python_)s myfortran.py g77') env2.Program(target = 'test21', source = 'test21.f') env2.Program(target = 'test22', source = 'test22.F') env2.Program(target = 'test23', source = 'test23.for') @@ -119,7 +119,7 @@ env2.Program(target = 'test27', source = 'test27.fpp') env2.Program(target = 'test28', source = 'test28.FPP') env2.Program(target = 'test29', source = 'test29.f77') env2.Program(target = 'test30', source = 'test30.F77') -""" % (python, python, python, 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") @@ -191,12 +191,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('F77') -bar = foo.Copy(F77 = r'%s wrapper.py ' + f77) +bar = foo.Copy(F77 = r'%(_python_)s wrapper.py ' + f77) 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 |