diff --git a/mesonbuild/envconfig.py b/mesonbuild/envconfig.py index cec50599e..011ab5d50 100644 --- a/mesonbuild/envconfig.py +++ b/mesonbuild/envconfig.py @@ -341,8 +341,8 @@ This is probably wrong, it should always point to the native compiler.''' % evar if command is not None: command = shlex.split(command) - # Do not return empty string entries - if command is not None and len(command) == 0: + # Do not return empty or blank string entries + if command is not None and (len(command) == 0 or len(command[0].strip()) == 0): return None return command