1
0
mirror of https://git.yoctoproject.org/poky synced 2026-05-07 16:59:22 +00:00

recipeutils.py: get_recipe_pv_without_srcpv remove prefixes from pv

Some recipes uses v or r prefixes in versions that makes wrong
comparisions over recipes like lz4 r123 > 128.

(From OE-Core rev: f7d250c97f40a737df9020180852d2ee87ca06b3)

Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Aníbal Limón
2015-07-14 19:43:57 -05:00
committed by Richard Purdie
parent 74240ccbfa
commit 6deffe1258
+6
View File
@@ -645,6 +645,12 @@ def get_recipe_pv_without_srcpv(pv, uri_type):
pv = m.group('ver')
pfx = m.group('pfx')
sfx = m.group('sfx')
else:
regex = re.compile("(?P<pfx>(v|r|))(?P<ver>((\d+[\.\-_]*)+))")
m = regex.match(pv)
if m:
pv = m.group('ver')
pfx = m.group('pfx')
return (pv, pfx, sfx)