meson: Fix detection of glib-mkenums under MSYS2

Under MSYS2 glib-mkenums is an executable and has a .exe extension and
the path does not end with "glib-mkenums".

Make the script compare the path without the file extension instead.

https://bugzilla.gnome.org/show_bug.cgi?id=796273
This commit is contained in:
Christoph Reiter 2018-05-20 13:53:31 +02:00 committed by Tim-Philipp Müller
parent cba2c7dd89
commit 7cbbdf3a90

View file

@ -37,7 +37,7 @@ argn = 1
for arg in sys.argv[1:]:
cmd.append(arg)
argn += 1
if arg.endswith('glib-mkenums'):
if os.path.splitext(arg)[0].endswith('glib-mkenums'):
break
ofilename = sys.argv[argn]
headers = sys.argv[argn + 1:]