meson: Substitute the Python shebang

Just like we do with Autotools. This allows building glib-mkenums and
glib-genmarshal on older platforms that only have Python 2.
This commit is contained in:
Emmanuele Bassi 2017-07-14 20:43:19 +01:00
parent 1eda0627f3
commit 0f18a2ebda
3 changed files with 4 additions and 2 deletions

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python3 #!@PYTHON@
# pylint: disable=too-many-lines, missing-docstring, invalid-name # pylint: disable=too-many-lines, missing-docstring, invalid-name

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python3 #!@PYTHON@
# If the code below looks horrible and unpythonic, do not panic. # If the code below looks horrible and unpythonic, do not panic.
# #

View File

@ -68,6 +68,7 @@ libgobject_dep = declare_dependency(link_with : libgobject,
glib_mkenums_conf = configuration_data() glib_mkenums_conf = configuration_data()
glib_mkenums_conf.set('GLIB_VERSION', glib_version) glib_mkenums_conf.set('GLIB_VERSION', glib_version)
glib_mkenums_conf.set('PYTHON', python.path())
# FIXME: Set permissions # FIXME: Set permissions
glib_mkenums = configure_file(input : 'glib-mkenums.in', glib_mkenums = configure_file(input : 'glib-mkenums.in',
@ -87,6 +88,7 @@ gmarshal_strings = custom_target('gmarshal.strings',
glib_genmarshal_conf = configuration_data() glib_genmarshal_conf = configuration_data()
glib_genmarshal_conf.set('VERSION', glib_version) glib_genmarshal_conf.set('VERSION', glib_version)
glib_genmarshal_conf.set('PYTHON', python.path())
glib_genmarshal = configure_file(input : 'glib-genmarshal.in', glib_genmarshal = configure_file(input : 'glib-genmarshal.in',
output : 'glib-genmarshal', output : 'glib-genmarshal',