summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2014-05-01 15:39:56 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2014-05-02 20:46:58 +0100
commit96ce3f278c60e1ea5b56a805255ebfb80cbd1ff4 (patch)
tree459705a737386bd7ed1d22d0c5a20f4436708ee0
parentcf4d30f5b4316a9b91a7e32927192e41f32af713 (diff)
downloadpoky-96ce3f278c60e1ea5b56a805255ebfb80cbd1ff4.tar.gz
base.bbclass: Silence PREFERRED_PROVIDER warnings for sdk builds
Unfortunately expandKeys() notices overlap between the SDK and TARGET PREFERRED_PROVIDERS entries when we set things up for the SDK recipes. To avoid this, delete one of the sets of keys to avoid supurious warnings. (From OE-Core rev: 9068a65baf4a28d04efad9297b16a2883ac42689) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/classes/base.bbclass14
1 files changed, 13 insertions, 1 deletions
diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
index 2468b03cce..10cb84ac91 100644
--- a/meta/classes/base.bbclass
+++ b/meta/classes/base.bbclass
@@ -284,7 +284,7 @@ def buildcfg_neededvars(d):
284 bb.fatal('The following variable(s) were not set: %s\nPlease set them directly, or choose a MACHINE or DISTRO that sets them.' % ', '.join(pesteruser)) 284 bb.fatal('The following variable(s) were not set: %s\nPlease set them directly, or choose a MACHINE or DISTRO that sets them.' % ', '.join(pesteruser))
285 285
286addhandler base_eventhandler 286addhandler base_eventhandler
287base_eventhandler[eventmask] = "bb.event.ConfigParsed bb.event.BuildStarted" 287base_eventhandler[eventmask] = "bb.event.ConfigParsed bb.event.BuildStarted bb.event.RecipePreFinalise"
288python base_eventhandler() { 288python base_eventhandler() {
289 if isinstance(e, bb.event.ConfigParsed): 289 if isinstance(e, bb.event.ConfigParsed):
290 e.data.setVar("NATIVELSBSTRING", lsb_distro_identifier(e.data)) 290 e.data.setVar("NATIVELSBSTRING", lsb_distro_identifier(e.data))
@@ -309,6 +309,18 @@ python base_eventhandler() {
309 309
310 statusheader = e.data.getVar('BUILDCFG_HEADER', True) 310 statusheader = e.data.getVar('BUILDCFG_HEADER', True)
311 bb.plain('\n%s\n%s\n' % (statusheader, '\n'.join(statuslines))) 311 bb.plain('\n%s\n%s\n' % (statusheader, '\n'.join(statuslines)))
312
313 # This code is to silence warnings where the SDK variables overwrite the
314 # target ones and we'd see dulpicate key names overwriting each other
315 # for various PREFERRED_PROVIDERS
316 if isinstance(e, bb.event.RecipePreFinalise):
317 if e.data.getVar("TARGET_PREFIX", True) == e.data.getVar("SDK_PREFIX", True):
318 e.data.delVar("PREFERRED_PROVIDER_virtual/${TARGET_PREFIX}binutils")
319 e.data.delVar("PREFERRED_PROVIDER_virtual/${TARGET_PREFIX}gcc-initial")
320 e.data.delVar("PREFERRED_PROVIDER_virtual/${TARGET_PREFIX}gcc")
321 e.data.delVar("PREFERRED_PROVIDER_virtual/${TARGET_PREFIX}g++")
322 e.data.delVar("PREFERRED_PROVIDER_virtual/${TARGET_PREFIX}compilerlibs")
323
312} 324}
313 325
314addtask configure after do_patch 326addtask configure after do_patch