diff options
Diffstat (limited to 'test/genini.py')
-rwxr-xr-x | test/genini.py | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/test/genini.py b/test/genini.py index f4d1575db..b8eda5d46 100755 --- a/test/genini.py +++ b/test/genini.py @@ -30,12 +30,12 @@ from os.path import join as joinpath, realpath mypath = sys.path[0] sys.path.append(joinpath(mypath, '..')) +sys.path.append(joinpath(mypath, '../python')) sys.path.append(joinpath(mypath, '../util/pbs')) -sys.path.append(joinpath(mypath, '../sim/pyconfig')) -from importer import AddToPath, LoadMpyFile +pathlist = [ '.' ] -AddToPath('.') +m5_build_env = {} try: opts, args = getopt.getopt(sys.argv[1:], '-E:I:') @@ -44,17 +44,21 @@ try: offset = arg.find('=') if offset == -1: name = arg - value = True + value = '1' else: name = arg[:offset] value = arg[offset+1:] os.environ[name] = value + m5_build_env[name] = value if opt == '-I': - AddToPath(arg) + pathlist.append(arg) except getopt.GetoptError: sys.exit('Improper Usage') -from m5config import * +from m5 import * + +for path in pathlist: + AddToPath(path) for arg in args: LoadMpyFile(arg) |