mirror of
https://github.com/X11Libre/xserver.git
synced 2026-04-14 17:18:09 +00:00
meson: Fix build with three-component version numbers
Otherwise: include/meson.build:5:0: ERROR: Index 3 out of bounds of array of size 3. Signed-off-by: Adam Jackson <ajax@redhat.com>
This commit is contained in:
@@ -2,7 +2,11 @@ version_split = meson.project_version().split('.')
|
||||
major = version_split[0].to_int()
|
||||
minor = version_split[1].to_int()
|
||||
patch = version_split[2].to_int()
|
||||
subpatch = version_split[3].to_int()
|
||||
if version_split.length() == 4
|
||||
subpatch = version_split[3].to_int()
|
||||
else
|
||||
subpatch = 0
|
||||
endif
|
||||
|
||||
release = major * 10000000 + minor * 100000 + patch * 1000 + subpatch
|
||||
|
||||
|
||||
Reference in New Issue
Block a user