diff options
author | Peter Seebach <peter.seebach@windriver.com> | 2012-08-10 17:32:56 -0500 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2012-08-15 14:26:40 +0100 |
commit | 13e2effd623aa2c3a864c46e4530cc238c59f0bb (patch) | |
tree | 406b061c28c01e17bfd7dc151b27ca1c9ea39cd2 | |
parent | 533b8b913e881ec9153077355cd7b39129b21302 (diff) | |
download | poky-13e2effd623aa2c3a864c46e4530cc238c59f0bb.tar.gz |
base.bbclass: Expand PNBLACKLIST across multilibs too
The PNBLACKLIST feature does not currently work with multilibs,
because they have different ${PN}. The obvious thing to do is to
do this at the same point that we do the PREFERRED_PROVIDER
and PREFERRED_VERSION fixups. (Making the PNBLACKLIST check
do the for-each-multilib check requires it to do the multilib
list generation repeatedly.)
(From OE-Core rev: 9bc0ca9369d0daee94abf60d3d521cc734c7e8cd)
Signed-off-by: Peter Seebach <peter.seebach@windriver.com>
Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/classes/base.bbclass | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass index 192c77761e..840ddbcc93 100644 --- a/meta/classes/base.bbclass +++ b/meta/classes/base.bbclass | |||
@@ -161,7 +161,8 @@ def pkgarch_mapping(d): | |||
161 | 161 | ||
162 | def preferred_ml_updates(d): | 162 | def preferred_ml_updates(d): |
163 | # If any PREFERRED_PROVIDER or PREFERRED_VERSIONS are set, | 163 | # If any PREFERRED_PROVIDER or PREFERRED_VERSIONS are set, |
164 | # we need to mirror these variables in the multilib case | 164 | # we need to mirror these variables in the multilib case; |
165 | # likewise the PNBLACKLIST flags. | ||
165 | multilibs = d.getVar('MULTILIBS', True) or "" | 166 | multilibs = d.getVar('MULTILIBS', True) or "" |
166 | if not multilibs: | 167 | if not multilibs: |
167 | return | 168 | return |
@@ -174,12 +175,19 @@ def preferred_ml_updates(d): | |||
174 | 175 | ||
175 | versions = [] | 176 | versions = [] |
176 | providers = [] | 177 | providers = [] |
178 | blacklists = d.getVarFlags('PNBLACKLIST') or [] | ||
177 | for v in d.keys(): | 179 | for v in d.keys(): |
178 | if v.startswith("PREFERRED_VERSION_"): | 180 | if v.startswith("PREFERRED_VERSION_"): |
179 | versions.append(v) | 181 | versions.append(v) |
180 | if v.startswith("PREFERRED_PROVIDER_"): | 182 | if v.startswith("PREFERRED_PROVIDER_"): |
181 | providers.append(v) | 183 | providers.append(v) |
182 | 184 | ||
185 | for pkg, reason in blacklists.items(): | ||
186 | for p in prefixes: | ||
187 | newpkg = p + "-" + pkg | ||
188 | if not d.getVarFlag('PNBLACKLIST', newpkg, True): | ||
189 | d.setVarFlag('PNBLACKLIST', newpkg, reason) | ||
190 | |||
183 | for v in versions: | 191 | for v in versions: |
184 | val = d.getVar(v, False) | 192 | val = d.getVar(v, False) |
185 | pkg = v.replace("PREFERRED_VERSION_", "") | 193 | pkg = v.replace("PREFERRED_VERSION_", "") |