diff options
Diffstat (limited to 'meta/lib')
-rw-r--r-- | meta/lib/oe/recipeutils.py | 19 | ||||
-rw-r--r-- | meta/lib/oeqa/utils/commands.py | 2 |
2 files changed, 11 insertions, 10 deletions
diff --git a/meta/lib/oe/recipeutils.py b/meta/lib/oe/recipeutils.py index c77664f135..e7dd8afb08 100644 --- a/meta/lib/oe/recipeutils.py +++ b/meta/lib/oe/recipeutils.py | |||
@@ -27,16 +27,16 @@ list_vars = ['SRC_URI', 'LIC_FILES_CHKSUM'] | |||
27 | meta_vars = ['SUMMARY', 'DESCRIPTION', 'HOMEPAGE', 'BUGTRACKER', 'SECTION'] | 27 | meta_vars = ['SUMMARY', 'DESCRIPTION', 'HOMEPAGE', 'BUGTRACKER', 'SECTION'] |
28 | 28 | ||
29 | 29 | ||
30 | def pn_to_recipe(cooker, pn): | 30 | def pn_to_recipe(cooker, pn, mc=''): |
31 | """Convert a recipe name (PN) to the path to the recipe file""" | 31 | """Convert a recipe name (PN) to the path to the recipe file""" |
32 | import bb.providers | 32 | import bb.providers |
33 | 33 | ||
34 | if pn in cooker.recipecache.pkg_pn: | 34 | if pn in cooker.recipecaches[mc].pkg_pn: |
35 | best = bb.providers.findBestProvider(pn, cooker.data, cooker.recipecache, cooker.recipecache.pkg_pn) | 35 | best = bb.providers.findBestProvider(pn, cooker.data, cooker.recipecaches[mc], cooker.recipecaches[mc].pkg_pn) |
36 | return best[3] | 36 | return best[3] |
37 | elif pn in cooker.recipecache.providers: | 37 | elif pn in cooker.recipecaches[mc].providers: |
38 | filenames = cooker.recipecache.providers[pn] | 38 | filenames = cooker.recipecaches[mc].providers[pn] |
39 | eligible, foundUnique = bb.providers.filterProviders(filenames, pn, cooker.expanded_data, cooker.recipecache) | 39 | eligible, foundUnique = bb.providers.filterProviders(filenames, pn, cooker.expanded_data, cooker.recipecaches[mc]) |
40 | filename = eligible[0] | 40 | filename = eligible[0] |
41 | return filename | 41 | return filename |
42 | else: | 42 | else: |
@@ -50,13 +50,14 @@ def get_unavailable_reasons(cooker, pn): | |||
50 | return taskdata.get_reasons(pn) | 50 | return taskdata.get_reasons(pn) |
51 | 51 | ||
52 | 52 | ||
53 | def parse_recipe(fn, appendfiles, d): | 53 | def parse_recipe(cooker, fn, appendfiles): |
54 | """ | 54 | """ |
55 | Parse an individual recipe file, optionally with a list of | 55 | Parse an individual recipe file, optionally with a list of |
56 | bbappend files. | 56 | bbappend files. |
57 | """ | 57 | """ |
58 | import bb.cache | 58 | import bb.cache |
59 | envdata = bb.cache.Cache.loadDataFull(fn, appendfiles, d) | 59 | parser = bb.cache.NoCache(cooker.databuilder) |
60 | envdata = parser.loadDataFull(fn, appendfiles) | ||
60 | return envdata | 61 | return envdata |
61 | 62 | ||
62 | 63 | ||
@@ -79,7 +80,7 @@ def parse_recipe_simple(cooker, pn, d, appends=True): | |||
79 | appendfiles = cooker.collection.get_file_appends(recipefile) | 80 | appendfiles = cooker.collection.get_file_appends(recipefile) |
80 | else: | 81 | else: |
81 | appendfiles = None | 82 | appendfiles = None |
82 | return parse_recipe(recipefile, appendfiles, d) | 83 | return parse_recipe(cooker, recipefile, appendfiles) |
83 | 84 | ||
84 | 85 | ||
85 | def get_var_files(fn, varlist, d): | 86 | def get_var_files(fn, varlist, d): |
diff --git a/meta/lib/oeqa/utils/commands.py b/meta/lib/oeqa/utils/commands.py index a8e184d0c3..5cd0f7477b 100644 --- a/meta/lib/oeqa/utils/commands.py +++ b/meta/lib/oeqa/utils/commands.py | |||
@@ -223,7 +223,7 @@ def runqemu(pn, ssh=True): | |||
223 | tinfoil.config_data.setVar("TEST_QEMUBOOT_TIMEOUT", "1000") | 223 | tinfoil.config_data.setVar("TEST_QEMUBOOT_TIMEOUT", "1000") |
224 | import oe.recipeutils | 224 | import oe.recipeutils |
225 | recipefile = oe.recipeutils.pn_to_recipe(tinfoil.cooker, pn) | 225 | recipefile = oe.recipeutils.pn_to_recipe(tinfoil.cooker, pn) |
226 | recipedata = oe.recipeutils.parse_recipe(recipefile, [], tinfoil.config_data) | 226 | recipedata = oe.recipeutils.parse_recipe(tinfoil.cooker, recipefile, []) |
227 | 227 | ||
228 | # The QemuRunner log is saved out, but we need to ensure it is at the right | 228 | # The QemuRunner log is saved out, but we need to ensure it is at the right |
229 | # log level (and then ensure that since it's a child of the BitBake logger, | 229 | # log level (and then ensure that since it's a child of the BitBake logger, |