[oe-commits] Robert Yang : oe-pkgdata-util: avoid returning skipped packages

git at git.openembedded.org git at git.openembedded.org
Thu Sep 24 16:55:54 UTC 2015


Module: openembedded-core.git
Branch: master
Commit: 5040481f33b356d9acfd29a778b13544e27e7bb7
URL:    http://git.openembedded.org/?p=openembedded-core.git&a=commit;h=5040481f33b356d9acfd29a778b13544e27e7bb7

Author: Robert Yang <liezhi.yang at windriver.com>
Date:   Tue Sep 15 19:04:10 2015 -0700

oe-pkgdata-util: avoid returning skipped packages

The skipped packages may be pulled in by another package, for example,
when libc6-dbg is already installed and should be skipped, but it would
be pulled in by libsegfault, this patch fixes the issue.

Signed-off-by: Robert Yang <liezhi.yang at windriver.com>
Signed-off-by: Richard Purdie <richard.purdie at linuxfoundation.org>

---

 scripts/oe-pkgdata-util | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/scripts/oe-pkgdata-util b/scripts/oe-pkgdata-util
index b075775..116cfae 100755
--- a/scripts/oe-pkgdata-util
+++ b/scripts/oe-pkgdata-util
@@ -60,6 +60,7 @@ def glob(args):
         skipval += "|" + args.exclude
     skipregex = re.compile(skipval)
 
+    skippedpkgs = set()
     mappedpkgs = set()
     with open(args.pkglistfile, 'r') as f:
         for line in f:
@@ -73,6 +74,7 @@ def glob(args):
             # Skip packages for which there is no point applying globs
             if skipregex.search(pkg):
                 logger.debug("%s -> !!" % pkg)
+                skippedpkgs.add(pkg)
                 continue
 
             # Skip packages that already match the globs, so if e.g. a dev package
@@ -84,6 +86,7 @@ def glob(args):
                     already = True
                     break
             if already:
+                skippedpkgs.add(pkg)
                 logger.debug("%s -> !" % pkg)
                 continue
 
@@ -152,7 +155,7 @@ def glob(args):
 
     logger.debug("------")
 
-    print("\n".join(mappedpkgs))
+    print("\n".join(mappedpkgs - skippedpkgs))
 
 def read_value(args):
     # Handle both multiple arguments and multiple values within an arg (old syntax)



More information about the Openembedded-commits mailing list