Scons: Update compare_versions() to ignore trailing charecters after an int. This is a fix for a mysql version number that includes a (E.g. 5.0.51a)
This commit is contained in:
parent
fef5a4f49c
commit
9affd7adc6
1 changed files with 1 additions and 1 deletions
|
@ -91,7 +91,7 @@ def compare_versions(v1, v2):
|
|||
if isinstance(v, (list,tuple)):
|
||||
return v
|
||||
elif isinstance(v, str):
|
||||
return map(int, v.split('.'))
|
||||
return map(lambda x: int(re.match('\d+', x).group()), v.split('.'))
|
||||
else:
|
||||
raise TypeError
|
||||
|
||||
|
|
Loading…
Reference in a new issue