Small fixes for fetch2
cover Small fixes for fetch2
The following changes since commit 2d5c71ae78b13e935548fe6ff5174b1c09b3077d:
fetch2: export LD_LIBRARY_PATH (2011-09-16 09:27:12 +0200)
are available in the git repository at:
git://gitorious.org/shr/bitbake jansa/pull
Martin Jansa (3):
fetch2/git: fix typo logggin/logger
fetch2/git: be more carefull in _contains_ref when checking git log
output
fetch2: export LD_LIBRARY_PATH
lib/bb/fetch2/__init__.py | 2 +- lib/bb/fetch2/git.py | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-)
Signature · 1 line
1.7.6.1
PATCH 1/3 fetch2/git: fix typo logggin/logger
--- lib/bb/fetch2/git.py | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
lib/bb/fetch2/git.py +1 -1
@@ -280,7 +280,7 @@ class Git(FetchMethod): # Check if we have the rev already if not os.path.exists(ud.clonedir): - logging.debug("GIT repository for %s does not exist in %s. \ + logger.debug(1, "GIT repository for %s does not exist in %s. \ Downloading.", url, ud.clonedir) self.download(None, ud, d) if not os.path.exists(ud.clonedir):
Signature · 1 line
1.7.6.1
PATCH 2/3 fetch2/git: be more carefull in _contains_ref when checking git log output
* in some cases there could be output like this
ERROR: ld.so: object 'libpseudo.so' from LD_PRELOAD cannot be preloaded: ignored. before wc -l output and returned 'output.split()[0] != 0' is always True
--- lib/bb/fetch2/git.py | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-)
lib/bb/fetch2/git.py +4 -1
@@ -239,7 +239,10 @@ class Git(FetchMethod): def _contains_ref(self, tag, d): basecmd = data.getVar("FETCHCMD_git", d, True) or "git" - output = runfetchcmd("%s log --pretty=oneline -n 1 %s -- 2> /dev/null | wc -l" % (basecmd, tag), d, quiet=True) + cmd = "%s log --pretty=oneline -n 1 %s -- 2> /dev/null | wc -l" % (basecmd, tag) + output = runfetchcmd(cmd, d, quiet=True) + if len(output.split()) > 1: + raise bb.fetch2.FetchError("The command '%s' gave output with more then 1 line unexpectedly, output: '%s'" % (cmd, output)) return output.split()[0] != "0" def _revision_key(self, url, ud, d, name):
Signature · 1 line
1.7.6.1
Richard Purdie
AppliedRe: [PATCH 2/3] fetch2/git: be more carefull in _contains_ref when checking git log output
Quoted 8 lines · Martin Jansa
* in some cases there could be output like this
ERROR: ld.so: object 'libpseudo.so' fromLD_PRELOADcannot be preloaded: ignored. before wc -l output and returned 'output.split()[0] != 0' is always TrueSigned-off-by Martin Jansa <[email protected]>--- lib/bb/fetch2/git.py | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-)
Merged to master, thanks.
Richard
PATCH 3/3 fetch2: export LD_LIBRARY_PATH
In reply to Martin Jansa* in some cases git calls omits extra output like this
ERROR: ld.so: object 'libpseudo.so' from LD_PRELOAD cannot be preloaded: ignored. and because runfetchcmd redirects stderr to stdout it ends in output which we're parsing ie in _contains_ref
--- lib/bb/fetch2/__init__.py | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
lib/bb/fetch2/__init__.py +1 -1
@@ -385,7 +385,7 @@ def runfetchcmd(cmd, d, quiet = False, cleanup = []): exportvars = ['PATH', 'GIT_PROXY_COMMAND', 'GIT_PROXY_HOST', 'GIT_PROXY_PORT', 'GIT_CONFIG', 'http_proxy', 'ftp_proxy', 'https_proxy', 'no_proxy', 'ALL_PROXY', 'all_proxy', - 'SSH_AUTH_SOCK', 'SSH_AGENT_PID', 'HOME'] + 'SSH_AUTH_SOCK', 'SSH_AGENT_PID', 'HOME', 'LD_LIBRARY_PATH'] for var in exportvars: val = bb.data.getVar(var, d, True)
Signature · 1 line
1.7.6.1
Quoted 13 lines · Martin Jansa
The following changes since commit
2d5c71ae78b13e935548fe6ff5174b1c09b3077d:fetch2: export
LD_LIBRARY_PATH(2011-09-16 09:27:12 +0200)are available in the git repository at:
git://gitorious.org/shr/bitbakejansa/pullMartin Jansa (3):
fetch2/git: fix typo logggin/logger
fetch2/git: be more carefull in_contains_refwhen checking git log
output
fetch2: exportLD_LIBRARY_PATH
Quoted 3 lines
lib/bb/fetch2/__init__.py | 2 +- lib/bb/fetch2/git.py | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-)
Hi,
Is there any reason why this wasn't merged and this
http://git.openembedded.org/cgit.cgi/bitbake/commit/?id=38a598731b49c8a0ba0ede570adc33eb1e848235
was merged instead?
Notice missing debug level as first param..
Regards,
Signature · 1 line
Martin 'JaMa' Jansa jabber: [email protected]
PATCH 1/1 fetch2/git: fix logger.debug
* logging/logger typo was fixed in 38a598731b49c8a0ba0ede570adc33eb1e848235 but debug level is still missing
--- lib/bb/fetch2/git.py | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
lib/bb/fetch2/git.py +1 -1
@@ -280,7 +280,7 @@ class Git(FetchMethod): # Check if we have the rev already if not os.path.exists(ud.clonedir): - logger.debug("GIT repository for %s does not exist in %s. \ + logger.debug(1, "GIT repository for %s does not exist in %s. \ Downloading.", url, ud.clonedir) self.download(None, ud, d) if not os.path.exists(ud.clonedir):
Signature · 1 line
1.7.6.1
Richard Purdie
AppliedRe: [PATCH] fetch2/git: fix logger.debug
Quoted 7 lines · Martin Jansa
* logging/logger typo was fixed in
38a598731b49c8a0ba0ede570adc33eb1e848235but debug level is still missingSigned-off-by Martin Jansa <[email protected]>--- lib/bb/fetch2/git.py | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
Merged to master, thanks.
Richard
Quoted 18 lines · Martin Jansa
Quoted 13 lines · Martin Jansa
The following changes since commit
2d5c71ae78b13e935548fe6ff5174b1c09b3077d:fetch2: export
LD_LIBRARY_PATH(2011-09-16 09:27:12 +0200)are available in the git repository at:
git://gitorious.org/shr/bitbakejansa/pullMartin Jansa (3):
fetch2/git: fix typo logggin/logger
fetch2/git: be more carefull in_contains_refwhen checking git log
output
fetch2: exportLD_LIBRARY_PATHQuoted 3 lines
lib/bb/fetch2/__init__.py | 2 +- lib/bb/fetch2/git.py | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-)
Quoted 5 lines
Hi,
Is there any reason why this wasn't merged and this
http://git.openembedded.org/cgit.cgi/bitbake/commit/?id=38a598731b49c8a0ba0ede570adc33eb1e848235
was merged instead?
I wasn't seeing emails to bitbake-devel due to some mail filtering issues after the LinuxFoundation email redirection changes. Those are fixed now and I've fixed my broken commit.
Cheers,
Richard