diff options
Diffstat (limited to 'bitbake/lib/bblayers/query.py')
-rw-r--r-- | bitbake/lib/bblayers/query.py | 28 |
1 files changed, 6 insertions, 22 deletions
diff --git a/bitbake/lib/bblayers/query.py b/bitbake/lib/bblayers/query.py index 29491163c2..5def7179ce 100644 --- a/bitbake/lib/bblayers/query.py +++ b/bitbake/lib/bblayers/query.py | |||
@@ -5,8 +5,6 @@ import sys | |||
5 | import os | 5 | import os |
6 | import re | 6 | import re |
7 | 7 | ||
8 | import bb.cache | ||
9 | import bb.providers | ||
10 | import bb.utils | 8 | import bb.utils |
11 | 9 | ||
12 | from bblayers.common import LayerPlugin | 10 | from bblayers.common import LayerPlugin |
@@ -122,15 +120,13 @@ skipped recipes will also be listed, with a " (skipped)" suffix. | |||
122 | sys.exit(1) | 120 | sys.exit(1) |
123 | 121 | ||
124 | pkg_pn = self.tinfoil.cooker.recipecaches[''].pkg_pn | 122 | pkg_pn = self.tinfoil.cooker.recipecaches[''].pkg_pn |
125 | (latest_versions, preferred_versions) = bb.providers.findProviders(self.tinfoil.config_data, self.tinfoil.cooker.recipecaches[''], pkg_pn) | 123 | (latest_versions, preferred_versions) = self.tinfoil.find_providers() |
126 | allproviders = bb.providers.allProviders(self.tinfoil.cooker.recipecaches['']) | 124 | allproviders = self.tinfoil.get_all_providers() |
127 | 125 | ||
128 | # Ensure we list skipped recipes | 126 | # Ensure we list skipped recipes |
129 | # We are largely guessing about PN, PV and the preferred version here, | 127 | # We are largely guessing about PN, PV and the preferred version here, |
130 | # but we have no choice since skipped recipes are not fully parsed | 128 | # but we have no choice since skipped recipes are not fully parsed |
131 | skiplist = list(self.tinfoil.cooker.skiplist.keys()) | 129 | skiplist = list(self.tinfoil.cooker.skiplist.keys()) |
132 | skiplist.sort( key=lambda fileitem: self.tinfoil.cooker.collection.calc_bbfile_priority(fileitem) ) | ||
133 | skiplist.reverse() | ||
134 | for fn in skiplist: | 130 | for fn in skiplist: |
135 | recipe_parts = os.path.splitext(os.path.basename(fn))[0].split('_') | 131 | recipe_parts = os.path.splitext(os.path.basename(fn))[0].split('_') |
136 | p = recipe_parts[0] | 132 | p = recipe_parts[0] |
@@ -265,10 +261,7 @@ Lists recipes with the bbappends that apply to them as subitems. | |||
265 | def show_appends_for_pn(self, pn): | 261 | def show_appends_for_pn(self, pn): |
266 | filenames = self.tinfoil.cooker_data.pkg_pn[pn] | 262 | filenames = self.tinfoil.cooker_data.pkg_pn[pn] |
267 | 263 | ||
268 | best = bb.providers.findBestProvider(pn, | 264 | best = self.tinfoil.find_best_provider(pn) |
269 | self.tinfoil.config_data, | ||
270 | self.tinfoil.cooker_data, | ||
271 | self.tinfoil.cooker_data.pkg_pn) | ||
272 | best_filename = os.path.basename(best[3]) | 265 | best_filename = os.path.basename(best[3]) |
273 | 266 | ||
274 | return self.show_appends_output(filenames, best_filename) | 267 | return self.show_appends_output(filenames, best_filename) |
@@ -336,10 +329,7 @@ NOTE: .bbappend files can impact the dependencies. | |||
336 | deps = self.tinfoil.cooker_data.deps[f] | 329 | deps = self.tinfoil.cooker_data.deps[f] |
337 | for pn in deps: | 330 | for pn in deps: |
338 | if pn in self.tinfoil.cooker_data.pkg_pn: | 331 | if pn in self.tinfoil.cooker_data.pkg_pn: |
339 | best = bb.providers.findBestProvider(pn, | 332 | best = self.tinfoil.find_best_provider(pn) |
340 | self.tinfoil.config_data, | ||
341 | self.tinfoil.cooker_data, | ||
342 | self.tinfoil.cooker_data.pkg_pn) | ||
343 | self.check_cross_depends("DEPENDS", layername, f, best[3], args.filenames, ignore_layers) | 333 | self.check_cross_depends("DEPENDS", layername, f, best[3], args.filenames, ignore_layers) |
344 | 334 | ||
345 | # The RDPENDS | 335 | # The RDPENDS |
@@ -352,14 +342,11 @@ NOTE: .bbappend files can impact the dependencies. | |||
352 | sorted_rdeps[k2] = 1 | 342 | sorted_rdeps[k2] = 1 |
353 | all_rdeps = sorted_rdeps.keys() | 343 | all_rdeps = sorted_rdeps.keys() |
354 | for rdep in all_rdeps: | 344 | for rdep in all_rdeps: |
355 | all_p = bb.providers.getRuntimeProviders(self.tinfoil.cooker_data, rdep) | 345 | all_p, best = self.tinfoil.get_runtime_providers(rdep) |
356 | if all_p: | 346 | if all_p: |
357 | if f in all_p: | 347 | if f in all_p: |
358 | # The recipe provides this one itself, ignore | 348 | # The recipe provides this one itself, ignore |
359 | continue | 349 | continue |
360 | best = bb.providers.filterProvidersRunTime(all_p, rdep, | ||
361 | self.tinfoil.config_data, | ||
362 | self.tinfoil.cooker_data)[0][0] | ||
363 | self.check_cross_depends("RDEPENDS", layername, f, best, args.filenames, ignore_layers) | 350 | self.check_cross_depends("RDEPENDS", layername, f, best, args.filenames, ignore_layers) |
364 | 351 | ||
365 | # The RRECOMMENDS | 352 | # The RRECOMMENDS |
@@ -372,14 +359,11 @@ NOTE: .bbappend files can impact the dependencies. | |||
372 | sorted_rrecs[k2] = 1 | 359 | sorted_rrecs[k2] = 1 |
373 | all_rrecs = sorted_rrecs.keys() | 360 | all_rrecs = sorted_rrecs.keys() |
374 | for rrec in all_rrecs: | 361 | for rrec in all_rrecs: |
375 | all_p = bb.providers.getRuntimeProviders(self.tinfoil.cooker_data, rrec) | 362 | all_p, best = self.tinfoil.get_runtime_providers(rrec) |
376 | if all_p: | 363 | if all_p: |
377 | if f in all_p: | 364 | if f in all_p: |
378 | # The recipe provides this one itself, ignore | 365 | # The recipe provides this one itself, ignore |
379 | continue | 366 | continue |
380 | best = bb.providers.filterProvidersRunTime(all_p, rrec, | ||
381 | self.tinfoil.config_data, | ||
382 | self.tinfoil.cooker_data)[0][0] | ||
383 | self.check_cross_depends("RRECOMMENDS", layername, f, best, args.filenames, ignore_layers) | 367 | self.check_cross_depends("RRECOMMENDS", layername, f, best, args.filenames, ignore_layers) |
384 | 368 | ||
385 | # The inherit class | 369 | # The inherit class |