summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAníbal Limón <anibal.limon@linux.intel.com>2015-07-14 19:43:55 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2015-07-23 08:48:37 +0100
commite28c1eb70886248f3ea5407ab0ecbbfde78e41ff (patch)
tree459a34d7f1190211232c88dc0331e1aea1fdd2fe
parent205c39bf78a4a7a4fc0f38510a4adc0ea8347c6b (diff)
downloadpoky-e28c1eb70886248f3ea5407ab0ecbbfde78e41ff.tar.gz
oe/recipeutils.py: get_recipe_upstream_info only use sfx and pfx when exits
Don't use pfx and sfx when not exist because cause formatting errors like 2.9HASH instead of 2.9+gitAUTOINC+HASH. (From OE-Core rev: 382833cc7e7603241838e18e429f69da0c2ee4ac) Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/lib/oe/recipeutils.py13
1 files changed, 10 insertions, 3 deletions
diff --git a/meta/lib/oe/recipeutils.py b/meta/lib/oe/recipeutils.py
index 78d69267ac..16530ee179 100644
--- a/meta/lib/oe/recipeutils.py
+++ b/meta/lib/oe/recipeutils.py
@@ -708,14 +708,21 @@ def get_recipe_upstream_version(rd):
708 if uri_type == 'git': 708 if uri_type == 'git':
709 (pv, pfx, sfx) = get_recipe_pv_without_srcpv(pv, uri_type) 709 (pv, pfx, sfx) = get_recipe_pv_without_srcpv(pv, uri_type)
710 710
711 latest_revision = ud.method.latest_revision(ud, rd, ud.names[0]) 711 revision = ud.method.latest_revision(ud, rd, ud.names[0])
712 712
713 # if contains revision but not pupver use current pv 713 # if contains revision but not pupver use current pv
714 if pupver == '' and latest_revision: 714 if pupver == '' and revision:
715 pupver = pv 715 pupver = pv
716 716
717 if pupver != '': 717 if pupver != '':
718 pupver = pfx + pupver + sfx + latest_revision[:10] 718 tmp = pupver
719 pupver = ''
720
721 if pfx:
722 pupver = pfx
723 pupver = pupver + tmp
724 if sfx:
725 pupver = pupver + sfx + revision[:10]
719 726
720 if pupver != '': 727 if pupver != '':
721 ru['version'] = pupver 728 ru['version'] = pupver