diff options
Diffstat (limited to 'mesonbuild/environment.py')
-rw-r--r-- | mesonbuild/environment.py | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py index d9146eb..9045007 100644 --- a/mesonbuild/environment.py +++ b/mesonbuild/environment.py @@ -325,14 +325,10 @@ class Environment: return self.coredata def get_build_command(self, unbuffered=False): - # If running an executable created with cx_freeze, - # Python might not be installed so don't prefix - # the command with it. - if sys.executable.endswith('meson.exe'): - return [sys.executable] - if unbuffered: - [sys.executable, '-u', self.meson_script_launcher] - return [sys.executable, self.meson_script_launcher] + cmd = mesonlib.meson_command[:] + if unbuffered and 'python' in cmd[0]: + cmd = [cmd[0],'-u'] + cmd[1:] + return cmd def is_header(self, fname): return is_header(fname) |