[oe-commits] Chris Larson : collections.inc: trim off trailing slashes for the entries in COLLECTIONS.

GIT User account git at amethyst.openembedded.net
Wed Apr 8 17:17:12 UTC 2009


Module: openembedded.git
Branch: org.openembedded.dev
Commit: 3b215f7a41ce9e6b1b32cf10b1f0da1a30ae9f26
URL:    http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=3b215f7a41ce9e6b1b32cf10b1f0da1a30ae9f26

Author: Chris Larson <clarson at kergoth.com>
Date:   Wed Apr  8 10:12:51 2009 -0700

collections.inc: trim off trailing slashes for the entries in COLLECTIONS.

Signed-off-by: Chris Larson <clarson at kergoth.com>

---

 conf/collections.inc |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/conf/collections.inc b/conf/collections.inc
index e3f6883..abd9bd3 100644
--- a/conf/collections.inc
+++ b/conf/collections.inc
@@ -91,13 +91,15 @@ def collections_setup(d):
     collectionmap = {}
     namemap = {}
     for collection in collections:
+        if collection.endswith(os.sep):
+            collection = collection[:-1]
         basename = os.path.basename(collection).split(os.path.extsep)[0]
         if namemap.get(basename):
             basename = "%s-%s" % (basename, hash(collection))
         namemap[basename] = collection
         collectionmap[collection] = basename
 
-    for (collection, priority) in izip(collections, xrange(len(collections), 0, -1)):
+    for (collection, priority) in izip(collectionmap, xrange(len(collections), 0, -1)):
         if not os.path.exists(collection):
             bb.fatal("Collection %s does not exist" % collection)
 





More information about the Openembedded-commits mailing list