summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bitbake/lib/bb/fetch2/git.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/bitbake/lib/bb/fetch2/git.py b/bitbake/lib/bb/fetch2/git.py
index 4a4c30d5e4..fb6125ce3f 100644
--- a/bitbake/lib/bb/fetch2/git.py
+++ b/bitbake/lib/bb/fetch2/git.py
@@ -210,10 +210,12 @@ class Git(FetchMethod):
210 subdir = ud.parm.get("subpath", "") 210 subdir = ud.parm.get("subpath", "")
211 if subdir != "": 211 if subdir != "":
212 readpathspec = ":%s" % (subdir) 212 readpathspec = ":%s" % (subdir)
213 def_destsuffix = "%s/" % os.path.basename(subdir)
213 else: 214 else:
214 readpathspec = "" 215 readpathspec = ""
216 def_destsuffix = "git/"
215 217
216 destsuffix = ud.parm.get("destsuffix", "git/") 218 destsuffix = ud.parm.get("destsuffix", def_destsuffix)
217 destdir = os.path.join(destdir, destsuffix) 219 destdir = os.path.join(destdir, destsuffix)
218 if os.path.exists(destdir): 220 if os.path.exists(destdir):
219 bb.utils.prunedir(destdir) 221 bb.utils.prunedir(destdir)