Jason Lowe-Power has submitted this change and it was merged. (
https://gem5-review.googlesource.com/c/public/gem5/+/17454 )
Change subject: tests: Use full path for DownloadedProgram
......................................................................
tests: Use full path for DownloadedProgram
Change-Id: I1dceca80a425293d64f81b06ddff499363f18bc0
Signed-off-by: Jason Lowe-Power <ja...@lowepower.com>
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/17454
Reviewed-by: Andreas Sandberg <andreas.sandb...@arm.com>
---
M tests/gem5/fixture.py
1 file changed, 13 insertions(+), 2 deletions(-)
Approvals:
Andreas Sandberg: Looks good to me, approved
Jason Lowe-Power: Looks good to me, approved
diff --git a/tests/gem5/fixture.py b/tests/gem5/fixture.py
index c4fd12f..97aab46 100644
--- a/tests/gem5/fixture.py
+++ b/tests/gem5/fixture.py
@@ -221,12 +221,23 @@
urlbase = "http://gem5.org/dist/current/"
def __init__(self, path, program, **kwargs):
+ """
+ path: string
+ The path to the directory containing the binary relative to
+ $GEM5_BASE/tests
+ program: string
+ The name of the binary file
+ """
super(DownloadedProgram, self).__init__("download-" + program,
build_once=True, **kwargs)
self.program_dir = path
- self.path = joinpath(self.program_dir, program)
- self.url = self.urlbase + self.path
+ relative_path = joinpath(self.program_dir, program)
+ self.url = self.urlbase + relative_path
+ self.path = os.path.realpath(
+ joinpath(absdirpath(__file__), '../',
relative_path)
+ )
+
def _download(self):
import urllib
import errno
--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/17454
To unsubscribe, or for help writing mail filters, visit
https://gem5-review.googlesource.com/settings
Gerrit-Project: public/gem5
Gerrit-Branch: master
Gerrit-Change-Id: I1dceca80a425293d64f81b06ddff499363f18bc0
Gerrit-Change-Number: 17454
Gerrit-PatchSet: 3
Gerrit-Owner: Jason Lowe-Power <ja...@lowepower.com>
Gerrit-Reviewer: Andreas Sandberg <andreas.sandb...@arm.com>
Gerrit-Reviewer: Anthony Gutierrez <anthony.gutier...@amd.com>
Gerrit-Reviewer: Giacomo Travaglini <giacomo.travagl...@arm.com>
Gerrit-Reviewer: Jason Lowe-Power <ja...@lowepower.com>
Gerrit-Reviewer: Sean Wilson <spwils...@wisc.edu>
Gerrit-MessageType: merged
_______________________________________________
gem5-dev mailing list
gem5-dev@gem5.org
http://m5sim.org/mailman/listinfo/gem5-dev