python: fix tracing after Python 3 refactor
authorCiro Santilli <ciro.santilli@arm.com>
Mon, 15 Apr 2019 13:08:49 +0000 (14:08 +0100)
committerCiro Santilli <ciro.santilli@arm.com>
Tue, 23 Apr 2019 10:21:46 +0000 (10:21 +0000)
gem5.opt --debug-flags ExecAll

was failing with:

ImportError: No module named defines

on Python 2.

Change-Id: I06959d6e0ccb7c661c7c749af3392632dac779f3
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/18108
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
src/python/m5/main.py

index fae04e76c452d3e2d949e2c97e77677aaab3e1b9..fd1f6a0db6d4e75d2d3780a8a542bcdf3fae96af 100644 (file)
@@ -193,7 +193,7 @@ def interact(scope):
 
 
 def _check_tracing():
-    import defines
+    from . import defines
 
     if defines.TRACING_ON:
         return