-
Notifications
You must be signed in to change notification settings - Fork 267
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Programatic procedure to retrieve the output path of a test #478
Comments
Are you aware that the output path is accessible as an attribute on the post_check and pre_config hooks as well? Depending on the use case this might be what you need rather than having it written in the export-json file. |
No, I was not. And I can very probably use it to retrieve the path in the |
It will only be accessible when running the pre config hook before simulation. So you need to run the simulation. |
I think I should be able to 'run the simulation' as |
That would work. |
I implemented it in #568 as follows: def preconf(output_path):
global opath
opath = output_path
return True
for tb in lib.get_test_benches(pattern='*', allow_empty=False):
tb.set_pre_config(preconf)
ui.set_sim_option("ghdl.elab_e", True)
ui._args.elaborate = True
try:
ui.main()
except SystemExit as exc:
if exc.code is not 0:
exit(exc.code)
args = [line.rstrip('\n') for line in open(join(opath, 'ghdl', 'args.txt'))] |
Ref #467.
The text was updated successfully, but these errors were encountered: