cmake: fix reading version from changelog

Fix version regex to allow version numbers without text and revision.

Signed-off-by: Rafael Kitover <rkitover@gmail.com>
This commit is contained in:
Rafael Kitover 2019-10-05 20:32:46 +00:00
parent 699d0c3724
commit ec7d1b15b1
No known key found for this signature in database
GPG Key ID: 08AB596679D86240
1 changed files with 1 additions and 1 deletions

View File

@ -9,7 +9,7 @@ function(changelog_version version revision version_release)
return()
endif()
string(REGEX MATCH "\n## +\\[([0-9.]+)(-([^] ]+))?\\] +.* +[0-9][0-9]?/" match_out "${changelog_file}")
string(REGEX MATCH "\n## +\\[([0-9.]+)(-([^] ]+))?\\] *.* *[0-9][0-9]?/" match_out "${changelog_file}")
set(changelog_version "${CMAKE_MATCH_1}")