Sometimes it is desirable to use arbitrary version of QEMU executable when running OSv on it. The scripts/run.py takes the '--qemu-path' already but there are other scripts like upload_manifest.py or scripts/build that delegate to run.py but either do not accept qemu path argument or do not pass it to run.py.
So instead, we allow one set an environment variable QEMU_PATH which would be used if set or exported in the shell invoking run.py or other scripts calling it. Signed-off-by: Waldemar Kozaczuk <jwkozac...@gmail.com> --- scripts/run.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/run.py b/scripts/run.py index c7464bda..3165b264 100755 --- a/scripts/run.py +++ b/scripts/run.py @@ -271,7 +271,7 @@ def start_osv_qemu(options): qemu_env = os.environ.copy() qemu_env['OSV_BRIDGE'] = options.bridge - qemu_path = options.qemu_path or ('qemu-system-%s' % options.arch) + qemu_path = options.qemu_path or qemu_env['QEMU_PATH'] or ('qemu-system-%s' % options.arch) cmdline = [qemu_path] + args if options.dry_run: print(format_args(cmdline)) -- 2.29.2 -- You received this message because you are subscribed to the Google Groups "OSv Development" group. To unsubscribe from this group and stop receiving emails from it, send an email to osv-dev+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/osv-dev/20210207185027.1108177-1-jwkozaczuk%40gmail.com.