[bitbake-devel] [PATCH] Remove a possible trailing '/' in subpath
Anders Darander
anders at chargestorm.se
Fri Apr 17 05:49:42 UTC 2015
If the subpath parameter to the git fetcher ends with a trailing '/',
bb.utils.prunedir() will be called on '/'...
Fixes [YOCTO #7620].
Signed-off-by: Anders Darander <anders at chargestorm.se>
---
lib/bb/fetch2/git.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/bb/fetch2/git.py b/lib/bb/fetch2/git.py
index 44fc271..0fd9bee 100644
--- a/lib/bb/fetch2/git.py
+++ b/lib/bb/fetch2/git.py
@@ -246,7 +246,7 @@ class Git(FetchMethod):
subdir = ud.parm.get("subpath", "")
if subdir != "":
readpathspec = ":%s" % (subdir)
- def_destsuffix = "%s/" % os.path.basename(subdir)
+ def_destsuffix = "%s/" % os.path.basename(subdir.rstrip('/'))
else:
readpathspec = ""
def_destsuffix = "git/"
--
2.1.4
More information about the bitbake-devel
mailing list