Patchwork RFC One recipe with two git repository as sources

login
register
mail settings
Submitter Holger Freyther
Date July 1, 2011, 1:37 p.m.
Message ID <4E0DCD9A.4030508@freyther.de>
Download mbox | patch
Permalink /patch/6845/
State New, archived
Headers show

Comments

Holger Freyther - July 1, 2011, 1:37 p.m.
On 06/23/2011 01:21 PM, Phil Blundell wrote:
> On Thu, 2011-06-23 at 13:18 +0200, Holger Freyther wrote:
>> -        destdir = os.path.join(destdir, "git/")
>> +        destsuffix = ud.parm.get("destsuffix", "git/")
>> +        print destsuffix
>> +        destdir = os.path.join(destdir, destsuffix)
> 
> I think that "print" might be extraneous, but other than this your patch
> looks awesome.  I think this would resolve the problem that I was having
> in
> http://lists.linuxtogo.org/pipermail/openembedded-core/2011-June/004375.html and to which I never found a solution which didn't involve patching bitbake.
> 

Hi all,

updated patch without the debug print statement in it. what do you think?
could this be applied to the bitbake repository?

holger

Patch

From 5f58446bd2022c149b58a9f8faf738d1b56597a6 Mon Sep 17 00:00:00 2001
From: Holger Hans Peter Freyther <zecke@selfish.org>
Date: Thu, 23 Jun 2011 04:50:13 +0800
Subject: [PATCH] fetch2/git: Allow to specify the name of the checkout directory

Signed-off-by: Holger Hans Peter Freyther <holger@moiji-mobile.com>
---
 lib/bb/fetch2/git.py |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/lib/bb/fetch2/git.py b/lib/bb/fetch2/git.py
index f3bc793..534c87d 100644
--- a/lib/bb/fetch2/git.py
+++ b/lib/bb/fetch2/git.py
@@ -212,7 +212,8 @@  class Git(FetchMethod):
         else:
             readpathspec = ""
 
-        destdir = os.path.join(destdir, "git/")
+        destsuffix = ud.parm.get("destsuffix", "git/")
+        destdir = os.path.join(destdir, destsuffix)
         if os.path.exists(destdir):
             bb.utils.prunedir(destdir)
 
-- 
1.7.4.1