mirror of
https://gitlab.com/qemu-project/meson.git
synced 2025-11-08 23:10:00 +08:00
cargo: avoid AttributeError if cargolock is None
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
committed by
Dylan Baker
parent
6c88d99921
commit
ae311ae85c
@ -258,6 +258,8 @@ class Interpreter:
|
||||
def _fetch_package_from_subproject(self, package_name: str, meson_depname: str) -> PackageState:
|
||||
subp_name, _ = self.environment.wrap_resolver.find_dep_provider(meson_depname)
|
||||
if subp_name is None:
|
||||
if self.cargolock is None:
|
||||
raise MesonException(f'Dependency {meson_depname!r} not found in any wrap files.')
|
||||
# If Cargo.lock has a different version, this could be a resolution
|
||||
# bug, but maybe also a version mismatch? I am not sure yet...
|
||||
similar_deps = [pkg.subproject
|
||||
|
||||
Reference in New Issue
Block a user