diff options
author | Joshua Lock <joshua.g.lock@intel.com> | 2016-09-21 20:35:36 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-09-21 22:02:16 +0100 |
commit | cd47b648af422a979477df70e1e5f195ff24c6ec (patch) | |
tree | 640a8b6949548ac2b9aa68cf1f14209d09fc5bc9 /scripts/runqemu | |
parent | 7ab74d8b9a625644c5368a1f28eb253586243f6d (diff) | |
download | poky-cd47b648af422a979477df70e1e5f195ff24c6ec.tar.gz |
runqemu: validate paths and attempt to infer unset paths
We need to validate and ensure all paths are set regardless of
whether runqemu was invoked with a .qemuboot.conf file or
otherwise. Split this logic out into a separate method called
during check_and_set()
(From OE-Core rev: e843b2d49a151c1fe0d2a7ba00c41d2a35775736)
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/runqemu')
-rwxr-xr-x | scripts/runqemu | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/scripts/runqemu b/scripts/runqemu index 08dc306921..5170d87570 100755 --- a/scripts/runqemu +++ b/scripts/runqemu | |||
@@ -536,6 +536,7 @@ class BaseConfig(object): | |||
536 | 536 | ||
537 | def check_and_set(self): | 537 | def check_and_set(self): |
538 | """Check configs sanity and set when needed""" | 538 | """Check configs sanity and set when needed""" |
539 | self.validate_paths() | ||
539 | check_tun() | 540 | check_tun() |
540 | # Check audio | 541 | # Check audio |
541 | if self.audio_enabled: | 542 | if self.audio_enabled: |
@@ -598,6 +599,8 @@ class BaseConfig(object): | |||
598 | k_upper = k.upper() | 599 | k_upper = k.upper() |
599 | self.set(k_upper, v) | 600 | self.set(k_upper, v) |
600 | 601 | ||
602 | def validate_paths(self): | ||
603 | """Ensure all relevant path variables are set""" | ||
601 | # When we're started with a *.qemuboot.conf arg assume that image | 604 | # When we're started with a *.qemuboot.conf arg assume that image |
602 | # artefacts are relative to that file, rather than in whatever | 605 | # artefacts are relative to that file, rather than in whatever |
603 | # directory DEPLOY_DIR_IMAGE in the conf file points to. | 606 | # directory DEPLOY_DIR_IMAGE in the conf file points to. |