Fix build when product.version is mangled (#679)
Strip line breaks when reading product.version, as Git can mangle the line breaks if autocrlf is configured, resulting in `SM_BUILD_TAG` getting defined with a linebreak.
This commit is contained in:
parent
3d461ecea1
commit
79ba2835f6
@ -50,7 +50,7 @@ def output_version_headers():
|
||||
count, shorthash, longhash = get_git_version()
|
||||
|
||||
with open(os.path.join(SourceFolder, 'product.version')) as fp:
|
||||
contents = fp.read()
|
||||
contents = fp.read().strip()
|
||||
m = re.match('(\d+)\.(\d+)\.(\d+)-?(.*)', contents)
|
||||
if m == None:
|
||||
raise Exception('Could not detremine product version')
|
||||
|
Loading…
Reference in New Issue
Block a user