Don't use version to check for a not-found fallback

In _find_cached_fallback_dep(), actually check if dependency is not found,
rather than using a specific version as a proxy for that.
pull/4035/head
Jon Turney 7 years ago
parent 6a4c2d63d7
commit 0f568cc8d5
No known key found for this signature in database
GPG Key ID: C7C86F0370285C81
  1. 2
      mesonbuild/interpreter.py

@ -2822,7 +2822,7 @@ external dependencies (including libraries) must go to "dependencies".''')
return False
found = dep.version_method([], {})
# Don't do a version check if the dependency is not found and not required
if found == 'none' and not required:
if not dep.found_method([], {}) and not required:
subproj_path = os.path.join(self.subproject_dir, dirname)
mlog.log('Dependency', mlog.bold(name), 'from subproject',
mlog.bold(subproj_path), 'found:', mlog.red('NO'), '(cached)')

Loading…
Cancel
Save