mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-06 01:16:17 +01:00
Use python3 as the shebang on Windows
Since commit 013980d8
, Python tools like gdbus-codegen, glib-genmarshal,
glib-mkenums, etc. have a shebang with the full path to the python binary.
Shebangs cannot be shell-quoted (most utilities just do not expect that),
but since shebangs can have arguments, the path to the interpreter must not
have spaces. This is a problem on Windows, where Python is commonly installed
under the "Program Files" folder.
Moreover, by using the full path to the interpreter (at build time), the bundle
is not relocatable, which is the norm on Windows. It means that the bundle
cannot be moved between directories or different systems
This commit is contained in:
parent
3dcf1ea13d
commit
3f9f07f473
@ -31,7 +31,7 @@ gdbus_codegen_conf = configuration_data()
|
||||
gdbus_codegen_conf.set('VERSION', glib_version)
|
||||
gdbus_codegen_conf.set('MAJOR_VERSION', major_version)
|
||||
gdbus_codegen_conf.set('MINOR_VERSION', minor_version)
|
||||
gdbus_codegen_conf.set('PYTHON', python.full_path())
|
||||
gdbus_codegen_conf.set('PYTHON', host_system != 'windows' ? python.full_path() : 'python3')
|
||||
gdbus_codegen_conf.set('DATADIR', glib_datadir)
|
||||
|
||||
# Install gdbus-codegen executable
|
||||
|
@ -501,7 +501,7 @@ endif
|
||||
|
||||
report_conf = configuration_data()
|
||||
report_conf.set('GLIB_VERSION', glib_version)
|
||||
report_conf.set('PYTHON', python.full_path())
|
||||
report_conf.set('PYTHON', host_system != 'windows' ? python.full_path() : 'python3')
|
||||
configure_file(
|
||||
input: 'gtester-report.in',
|
||||
output: 'gtester-report',
|
||||
|
@ -85,7 +85,7 @@ python_tools = [
|
||||
|
||||
python_tools_conf = configuration_data()
|
||||
python_tools_conf.set('VERSION', glib_version)
|
||||
python_tools_conf.set('PYTHON', python.full_path())
|
||||
python_tools_conf.set('PYTHON', host_system != 'windows' ? python.full_path() : 'python3')
|
||||
|
||||
foreach tool: python_tools
|
||||
tool_bin = configure_file(
|
||||
|
Loading…
Reference in New Issue
Block a user