Skip to content

Commit

Permalink
backends: Avoid whitespace in passed --target-glib
Browse files Browse the repository at this point in the history
To support e.g. '>=x' vs. '>= x' without passing a strange-looking value
in the latter case. The Vala compiler handles it, but it easily causes
confusion when debugging build system issues.
  • Loading branch information
oleavr committed May 2, 2024
1 parent 307e104 commit 8138e35
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mesonbuild/backend/backends.py
Original file line number Diff line number Diff line change
Expand Up @@ -1050,7 +1050,7 @@ def generate_basic_compiler_args(self, target: build.BuildTarget, compiler: 'Com
if dep.name == 'glib-2.0' and dep.version_reqs is not None:
for req in dep.version_reqs:
if req.startswith(('>=', '==')):
commands += ['--target-glib', req[2:]]
commands += ['--target-glib', req[2:].lstrip()]
break
commands += ['--pkg', dep.name]
elif isinstance(dep, dependencies.ExternalLibrary):
Expand Down

0 comments on commit 8138e35

Please sign in to comment.