pub fn analyze_dependencies<S: BuildHasher>(
deps: &[String],
installed: &HashSet<String, S>,
provided: &HashSet<String, S>,
) -> Vec<DependencyDelta>Expand description
What: Analyze dependency specs against the host environment.
Inputs:
deps: Dependency specs as declared (may include version requirements or optdependspkg: descriptionannotations).installed: Set of installed package names.provided: Set of names provided by installed packages.
Output:
- One
DependencyDeltaper spec (local packages are skipped).
Details:
- Membership is checked via
deps::is_package_installed_or_provided. - Version constraints are parsed with
deps::parse_dep_specand checked withdeps::version_satisfiesagainst thepacman -Qversion — an improvement over Pacsea, which passed the full spec as the requirement (never failing the check). - Installed local packages are filtered out, matching Pacsea (they are not relevant for build-preflight analysis).
- Host state (versions, foreign packages) is queried in two batched pacman invocations up front and degrades gracefully when pacman is unavailable.