[OE-core] [PATCH] package.bbclass: allow shell-style wildcards in PRIVATE_LIBS

Quentin Schulz quentin.schulz at streamunlimited.com
Wed Sep 4 14:57:24 UTC 2019


Hi Alex,

On Wed, Sep 04, 2019 at 04:52:10PM +0200, Alexander Kanavin wrote:
> On Wed, 4 Sep 2019 at 14:55, Quentin Schulz <
> quentin.schulz at streamunlimited.com> wrote:
> 
> > So we just need to invert the logic actually.
> >
> > matched = False
> > for pattern in private_libs:
> >         if fnmatch.fnmatch(this_soname, pattern)]) == 0:
> >                 matched = True
> >                 break
> >
> > if not matched:
> >         sonames.add(prov)
> >
> 
> I think you are looking for the "for...else" feature in Python :) Still,

I'm discovering this one, thanks!

> the original code is not adding any lines at all while yours adds eight so
> I'd just keep the patch as it is.
> 

Added lines vs added execution time.

Anyway, glad to have this feature one day in Yocto, I was about to use
it in some project and was upset for having to name each and every lib
in the package.

Thanks!
Quentin
-- 
StreamUnlimited Engineering GmbH
High Tech Campus Vienna, Gutheil-Schoder-Gasse 10, 1100 Vienna, Austria
quentin.schulz at streamunlimited.com, www.streamunlimited.com


More information about the Openembedded-core mailing list