From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: openembedded-core@lists.openembedded.org
Subject: [PATCH] recipe_sanity: Drop rename overwrite detection
Date: Thu, 20 Aug 2026 23:51:45 +0100 [thread overview]
Message-ID: <20260820225145.3460875-1-richard.purdie@linuxfoundation.org> (raw)
Bitbake itself checks for probelmatic renames now during key expansion so this
check shouldn't be needed anymore (it dates from pre 2011).
(https://git.openembedded.org/bitbake/tree/lib/bb/data.py#n96 in expandKeys())
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
meta/classes/recipe_sanity.bbclass | 21 ---------------------
1 file changed, 21 deletions(-)
diff --git a/meta/classes/recipe_sanity.bbclass b/meta/classes/recipe_sanity.bbclass
index a5cc4315fb8..3c763de1f20 100644
--- a/meta/classes/recipe_sanity.bbclass
+++ b/meta/classes/recipe_sanity.bbclass
@@ -34,13 +34,6 @@ def req_vars(cfgdata, d):
elif val == cfgval:
__note("%s should be defined to something other than default (%s)" % (var, cfgval), d)
-def var_renames_overwrite(cfgdata, d):
- renames = d.getVar("__recipe_sanity_renames", False)
- if renames:
- for (key, newkey, oldvalue, newvalue) in renames:
- if oldvalue != newvalue and oldvalue != cfgdata.get(newkey):
- __note("rename of variable '%s' to '%s' overwrote existing value '%s' with '%s'." % (key, newkey, oldvalue, newvalue), d)
-
def incorrect_nonempty_PACKAGES(cfgdata, d):
if bb.data.inherits_class("native", d) or \
bb.data.inherits_class("cross", d):
@@ -113,7 +106,6 @@ python do_recipe_sanity () {
__note(msg, d)
can_delete_others(p, cfgdata, d)
- var_renames_overwrite(cfgdata, d)
req_vars(cfgdata, d)
bad_runtime_vars(cfgdata, d)
}
@@ -137,19 +129,6 @@ python recipe_sanity_eh () {
d.setVar("__recipe_sanity_cfgdata", cfgdata)
#d.setVar("__recipe_sanity_cfgdata", d)
-
- # Sick, very sick..
- from bb.data_smart import DataSmart
- old = DataSmart.renameVar
- def myrename(self, key, newkey):
- oldvalue = self.getVar(newkey, 0)
- old(self, key, newkey)
- newvalue = self.getVar(newkey, 0)
- if oldvalue:
- renames = self.getVar("__recipe_sanity_renames", 0) or set()
- renames.add((key, newkey, oldvalue, newvalue))
- self.setVar("__recipe_sanity_renames", renames)
- DataSmart.renameVar = myrename
}
addhandler recipe_sanity_eh
recipe_sanity_eh[eventmask] = "bb.event.ConfigParsed"
reply other threads:[~2026-08-20 22:51 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260820225145.3460875-1-richard.purdie@linuxfoundation.org \
--to=richard.purdie@linuxfoundation.org \
--cc=openembedded-core@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox