Skip to content

Commit

Permalink
XX
Browse files Browse the repository at this point in the history
Signed-off-by: Matthew Ballance <matt.ballance@gmail.com>
  • Loading branch information
mballance committed Sep 6, 2024
1 parent 80620cf commit 80b594c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/pytest_fv/flow_sim.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def __init__(self, dirconfig : DirConfig, sim_id = None):
self.addSubPhase(PhasePrePost("generate"))
self.addSubPhase(PhasePrePost("build"))
self.addSubPhase(PhasePrePost("run"))
self.sim = HdlSim.create(dirconfig.builddir(), sim_id)
self.sim : HdlSim = HdlSim.create(dirconfig.builddir(), sim_id)
self.addTool(self.sim, "sim")
self.addTaskToPhase("build.main", self.sim.mkBuildTask())

Expand Down
4 changes: 2 additions & 2 deletions src/pytest_fv/fv_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@ def getHdlSim(self):

if "PYTEST_FV_HDLSIM" in os.environ.keys() and os.environ["PYTEST_FV_HDLSIM"] != "":
return os.environ["PYTEST_FV_HDLSIM"]
elif "tool.hdlsim" in pytest_hdl.keys():
return pytest_hdl["tool.hdlsim"]
elif "hdlsim" in pytest_hdl.keys():
return pytest_hdl["hdlsim"]
else:
return FvConfig.DEFAULT_TOOL_HDLSIM

Expand Down
3 changes: 3 additions & 0 deletions src/pytest_fv/tool/hdl/sim/sim_verilator.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,9 @@ async def build(self):
if not os.path.isabs(logfile):
logfile = os.path.join(self.builddir, logfile)

if not os.path.isdir(os.path.dirname(logfile)):
os.makedirs(os.path.dirname(logfile))

print("cmd: %s" % str(cmd))
with open(logfile, "w") as log:
log.write("** Compile\n")
Expand Down

0 comments on commit 80b594c

Please sign in to comment.