scons,python: Stop importing some values in m5.defines.

The compileDate and gem5Version fields are used in only one place,
gem5's python main function. These fields are the remaining difference
between the "fake" defines.py provided by the SimObject importer, and
the real one composed later. It makes sense to exclude them in the
"fake" version since those values come from c++, but it would feel like
an arbitrary and unexpected difference to people trying to use it.

Change-Id: Ie344765bf7c8063197da24f5b55f762379deff94
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/48380
Tested-by: kokoro <noreply+kokoro@google.com>
Reviewed-by: Jason Lowe-Power <power.jg@gmail.com>
Maintainer: Jason Lowe-Power <power.jg@gmail.com>
This commit is contained in:
Gabe Black
2021-07-20 17:36:43 -07:00
parent ad1f240a12
commit a2c42a12b1
2 changed files with 4 additions and 10 deletions

View File

@@ -214,6 +214,7 @@ def _check_tracing():
def main(*args):
import m5
import _m5.core
from . import core
from . import debug
@@ -336,8 +337,8 @@ def main(*args):
print(brief_copyright)
print()
print("gem5 version %s" % defines.gem5Version)
print("gem5 compiled %s" % defines.compileDate)
print("gem5 version %s" % _m5.core.gem5Version)
print("gem5 compiled %s" % _m5.core.compileDate)
print("gem5 started %s" %
datetime.datetime.now().strftime("%b %e %Y %X"))