From: Darren Hart <dvhart@linux.intel.com>
To: Poky <poky@yoctoproject.org>,
openembedded-core@lists.openembedded.org,
Richard Purdie <richard.purdie@linuxfoundation.org>
Cc: Darren Hart <dvhart@linux.intel.com>,
bitbake-devel@lists.openembedded.org
Subject: [PATCH 1/9] bitbake: fetch2: Print the complete SRCREV variable name when INVALID
Date: Tue, 5 Feb 2013 14:52:43 -0800 [thread overview]
Message-ID: <c3eb52b9dbde2bccc9d3b53340712e445c949d2f.1360104547.git.dvhart@linux.intel.com> (raw)
In-Reply-To: <cover.1360104547.git.dvhart@linux.intel.com>
In-Reply-To: <cover.1360104547.git.dvhart@linux.intel.com>
If a particular SRCREV (say for a particular branch) is missing, the
fetcher will currently just report an obtuse error about the "SRCREV"
being invalid. If there is more information is to be had (say from name,
i.e. branch, and pn) then display that as well.
The new error looks something like this:
ERROR: ExpansionError during parsing /home/dvhart/source/poky/meta/recipes-kernel/linux/linux-yocto_3.4.bb: Failure expanding variable do_patch: ExpansionError: Failure expanding variable SRCPV, expression was ${@bb.fetch2.get_srcrev(d)} which triggered exception FetchError: Fetcher failure for URL: 'git://otcgit.jf.intel.com/dvhart/linux-yocto-minnow-3.4.git;protocol=git;nocheckout=1;branch=standard/minnow,meta,emgd-1.14;name=machine,meta,emgd'. Please set SRCREV_emgd_pn-linux-yocto to a valid value
Note the variable listed as invalid is
"SRCREV_emgd_pn-linux-yocto", making it explicit what is wrong.
Signed-off-by: Darren Hart <dvhart@linux.intel.com>
Cc: bitbake-devel@lists.openembedded.org
---
bitbake/lib/bb/fetch2/__init__.py | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/bitbake/lib/bb/fetch2/__init__.py b/bitbake/lib/bb/fetch2/__init__.py
index 4746356..cba45d0 100644
--- a/bitbake/lib/bb/fetch2/__init__.py
+++ b/bitbake/lib/bb/fetch2/__init__.py
@@ -650,11 +650,14 @@ def srcrev_internal_helper(ud, d, name):
if not rev:
rev = d.getVar("SRCREV_%s" % name, True)
if not rev:
- rev = d.getVar("SRCREV_pn-%s" % pn, True)
+ rev = d.getVar("SRCREV_pn-%s" % pn, True)
if not rev:
rev = d.getVar("SRCREV", True)
if rev == "INVALID":
- raise FetchError("Please set SRCREV to a valid value", ud.url)
+ var = "SRCREV_pn-%s" % pn
+ if name != '':
+ var = "SRCREV_%s_pn-%s" % (name, pn)
+ raise FetchError("Please set %s to a valid value" % var, ud.url)
if rev == "AUTOINC":
rev = ud.method.latest_revision(ud.url, ud, d, name)
--
1.7.5.4
next prev parent reply other threads:[~2013-02-05 23:07 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-05 22:52 [PATCH V2 0/9] Git fetcher and proxy handling updates Darren Hart
2013-02-05 22:52 ` Darren Hart [this message]
2013-02-05 22:52 ` [PATCH 2/9] bitbake: fetch2: Export upper and lower case environment variables Darren Hart
2013-02-05 22:52 ` [PATCH 3/9] bitbake: fetch2: Remove broken git variables from the environment Darren Hart
2013-02-05 22:52 ` [PATCH 4/9] oe-buildenv-internal: Remove GIT variables from BB_ENV_EXTRAWHITE Darren Hart
2013-02-05 22:52 ` [PATCH 5/9] oe-buildenv-internal: Add upper and lower case proxy vars to BB_ENV_EXTRAWHITE Darren Hart
2013-02-05 22:52 ` [PATCH 6/9] base.bbclass: Remove generate_git_config() Darren Hart
2013-02-05 22:52 ` [PATCH 7/9] oe-git-proxy: Add a new comprehensive git proxy script Darren Hart
2013-02-05 23:51 ` Otavio Salvador
2013-02-06 0:04 ` Darren Hart
2013-02-06 0:09 ` Otavio Salvador
2013-02-06 0:16 ` Darren Hart
2013-02-05 22:52 ` [PATCH 8/9] meta-yocto: Document new oe-git-proxy in site.conf.sample Darren Hart
2013-02-06 0:24 ` Otavio Salvador
2013-02-06 0:29 ` Darren Hart
2013-02-05 22:52 ` [PATCH 9/9] oe-git-proxy*: Remove previous git proxy solutions Darren Hart
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=c3eb52b9dbde2bccc9d3b53340712e445c949d2f.1360104547.git.dvhart@linux.intel.com \
--to=dvhart@linux.intel.com \
--cc=bitbake-devel@lists.openembedded.org \
--cc=openembedded-core@lists.openembedded.org \
--cc=poky@yoctoproject.org \
--cc=richard.purdie@linuxfoundation.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox