summaryrefslogtreecommitdiff
path: root/test/genini.py
diff options
context:
space:
mode:
authorRon Dreslinski <rdreslin@umich.edu>2005-02-09 12:56:24 -0500
committerRon Dreslinski <rdreslin@umich.edu>2005-02-09 12:56:24 -0500
commit230a5a608dfb2204e2886a795e6bd8a30224b84f (patch)
tree81d312257237c4d13ad44836d55d2f192a479036 /test/genini.py
parentd9317dd348f3acd853d1e6a09c09f2a27ad5d707 (diff)
parentc4089562d5add225cd8275b59456eb7eb559b988 (diff)
downloadgem5-230a5a608dfb2204e2886a795e6bd8a30224b84f.tar.xz
Merger
cpu/simple_cpu/simple_cpu.hh: Merge --HG-- extra : convert_revision : 1b6003ac731051fefacb7d7a30c317553b4bf1bc
Diffstat (limited to 'test/genini.py')
-rw-r--r--test/genini.py12
1 files changed, 7 insertions, 5 deletions
diff --git a/test/genini.py b/test/genini.py
index e96d7069c..0dac0d409 100644
--- a/test/genini.py
+++ b/test/genini.py
@@ -26,12 +26,14 @@
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
import getopt, os, os.path, sys
+from os.path import join as joinpath, realpath
-sys.path.append('..')
-sys.path.append('../configs/kernel')
-sys.path.append('../sim/pyconfig')
+mypath = sys.path[0]
+sys.path.append(joinpath(mypath, '..'))
+sys.path.append(joinpath(mypath, '../configs/kernel'))
+sys.path.append(joinpath(mypath, '../sim/pyconfig'))
-from importer import mpy_exec, AddToPath
+from importer import mpy_exec, mpy_execfile, AddToPath
from m5config import *
try:
@@ -51,7 +53,7 @@ except getopt.GetoptError:
for arg in args:
AddToPath(os.path.dirname(arg))
- mpy_exec(file(arg, 'r'), globals())
+ mpy_execfile(arg)
if globals().has_key('root') and isinstance(root, type) \
and issubclass(root, Root):