diff --git a/mesonbuild/dependencies/dev.py b/mesonbuild/dependencies/dev.py index 94f51ff69b12..95ac9c4e1883 100644 --- a/mesonbuild/dependencies/dev.py +++ b/mesonbuild/dependencies/dev.py @@ -584,7 +584,7 @@ def __init__(self, environment: 'Environment', kwargs: JNISystemDependencyKW): self.is_found = False return - if 'version' in kwargs and not version_compare(self.version, kwargs['version']): + if 'version' in kwargs and not version_compare_many(self.version, kwargs['version']): mlog.error(f'Incorrect JDK version found ({self.version}), wanted {kwargs["version"]}') self.is_found = False return diff --git a/mesonbuild/dependencies/misc.py b/mesonbuild/dependencies/misc.py index 6998a2d69b21..3c566c332030 100644 --- a/mesonbuild/dependencies/misc.py +++ b/mesonbuild/dependencies/misc.py @@ -371,7 +371,7 @@ def __init__(self, name: str, env: 'Environment', kwargs: T.Dict[str, T.Any]): req = kwargs.get('version') if req: if self.version: - self.is_found = mesonlib.version_compare(self.version, req) + self.is_found, *_ = mesonlib.version_compare_many(self.version, req) else: mlog.warning('Cannot determine version of curses to compare against.')