[OE-core] [PATCH 04/12] bb.utils.explode_dep_versions: Update to ensure we avoid duplicate deps

Richard Purdie richard.purdie at linuxfoundation.org
Mon Oct 1 15:04:02 UTC 2012


On Mon, 2012-10-01 at 09:53 -0500, Mark Hatle wrote:
> On 10/1/12 8:09 AM, Richard Purdie wrote:
> > On Sat, 2012-09-29 at 19:19 -0500, Mark Hatle wrote:
> >> Due to a recent change in bb.utils.explode_dep_version, we need to make
> >> sure that we do not have any duplicates in things that use
> >> explode_dep_versions.
> >>
> >> Signed-off-by: Mark Hatle <mark.hatle at windriver.com>
> >> ---
> >>   meta/classes/insane.bbclass      |   55 +++++++++++++++++++++++++++++++++-
> >>   meta/classes/kernel.bbclass      |   20 +++++++-----
> >>   meta/classes/libc-common.bbclass |   13 ++++++--
> >>   meta/classes/package.bbclass     |   20 ++++++++++--
> >>   meta/classes/package_rpm.bbclass |   61 +++++++++++++++++++++-----------------
> >>   5 files changed, 125 insertions(+), 44 deletions(-)
> >>
> >> diff --git a/meta/classes/insane.bbclass b/meta/classes/insane.bbclass
> >> index 1fb8970..17d887a 100644
> >> --- a/meta/classes/insane.bbclass
> >> +++ b/meta/classes/insane.bbclass
> >> @@ -114,7 +114,7 @@ def package_qa_get_machine_dict():
> >>
> >>   # Currently not being used by default "desktop"
> >>   WARN_QA ?= "ldflags useless-rpaths rpaths unsafe-references-in-binaries unsafe-references-in-scripts staticdev libdir"
> >> -ERROR_QA ?= "dev-so debug-deps dev-deps debug-files arch la2 pkgconfig la perms"
> >> +ERROR_QA ?= "dev-so debug-deps dev-deps debug-files arch la2 pkgconfig la perms dep-cmp"
> >>
> >>   ALL_QA = "${WARN_QA} ${ERROR_QA}"
> >>
> >> @@ -659,6 +659,54 @@ def package_qa_check_rdepends(pkg, pkgdest, skip, d):
> >>
> >>       return sane
> >>
> >> +def package_qa_check_deps(pkg, pkgdest, skip, d):
> >> +    sane = True
> >> +
> >> +    # Copied from package_ipk.bbclass
> >> +    # boiler plate to update the data
> >> +    localdata = bb.data.createCopy(d)
> >> +    root = "%s/%s" % (pkgdest, pkg)
> >> +
> >> +    localdata.setVar('ROOT', '')
> >> +    localdata.setVar('ROOT_%s' % pkg, root)
> >
> >
> > Nothing here uses ROOT or root so these can be removed?
> >
> >> +    pkgname = localdata.getVar('PKG_%s' % pkg, True)
> >> +    if not pkgname:
> >> +        pkgname = pkg
> >> +    localdata.setVar('PKG', pkgname)
> >
> > Again, these look surplus to requirements?
> >
> >> +    localdata.setVar('OVERRIDES', pkg)
> >> +
> >> +    bb.data.update_data(localdata)
> >> +
> 
> I'll get this fixed and resubmitted.

I'm trying to find you on irc as we need to talk a bit more about
things.

With the above, I realised you copy and pasted some other code so I have
a cleanup patch for both now.

I don't think the ValueError is going to cut it, particularly this close
to release. I'm working on replacing the function usage with an improved
one which can cope with the duplicates.

Cheers,

Richard







More information about the Openembedded-core mailing list