diff options
author | Benjamin Esquivel <benjamin.esquivel@linux.intel.com> | 2017-01-19 15:55:52 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-01-23 12:05:22 +0000 |
commit | 44ac2995b88410aa1456e91c0ec913e3b5335010 (patch) | |
tree | 68f99ad324ac1bacaf7b467ef6056d7520f52c9f /scripts | |
parent | 45ae1e9684b3fdc338b47dfe48935e2c128a5f72 (diff) | |
download | poky-44ac2995b88410aa1456e91c0ec913e3b5335010.tar.gz |
selftest: automatically add the meta-selftest layer
adding the meta-selftest layer is a small bump you always encounter
when you want to run selftest. Adding an automatic procedure to include
the layer if it is not yet present.
(From OE-Core rev: b5000dd7b1d74d5dfede869ffa75ed87f5a8553c)
Signed-off-by: Benjamin Esquivel <benjamin.esquivel@linux.intel.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/oe-selftest | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/scripts/oe-selftest b/scripts/oe-selftest index 0baf572c10..58d3b1ef8a 100755 --- a/scripts/oe-selftest +++ b/scripts/oe-selftest | |||
@@ -131,8 +131,16 @@ def preflight_check(): | |||
131 | os.chdir(builddir) | 131 | os.chdir(builddir) |
132 | 132 | ||
133 | if not "meta-selftest" in get_bb_var("BBLAYERS"): | 133 | if not "meta-selftest" in get_bb_var("BBLAYERS"): |
134 | log.error("You don't seem to have the meta-selftest layer in BBLAYERS") | 134 | log.warn("meta-selftest layer not found in BBLAYERS, adding it") |
135 | return False | 135 | meta_selftestdir = os.path.join( |
136 | get_bb_var("BBLAYERS_FETCH_DIR"), | ||
137 | 'meta-selftest') | ||
138 | if os.path.isdir(meta_selftestdir): | ||
139 | runCmd("bitbake-layers add-layer %s" %meta_selftestdir) | ||
140 | else: | ||
141 | log.error("could not locate meta-selftest in:\n%s" | ||
142 | %meta_selftestdir) | ||
143 | return False | ||
136 | 144 | ||
137 | if "buildhistory.bbclass" in get_bb_var("BBINCLUDED"): | 145 | if "buildhistory.bbclass" in get_bb_var("BBINCLUDED"): |
138 | log.error("You have buildhistory enabled already and this isn't recommended for selftest, please disable it first.") | 146 | log.error("You have buildhistory enabled already and this isn't recommended for selftest, please disable it first.") |