graph: support DEPENDS, OPTDEPENDS, CHECKDEPENDS, MAKEDEPENDS

Closes #882
pull/1014/head
Alad Wenter 3 months ago
parent 666149c87d
commit 09062cb402
  1. 20
      lib/aur-graph

@ -48,10 +48,24 @@ function get_vercmp(ver1, ver2, op) {
}
}
/^\t(make|check)?depends/ {
if (!in_split_pkg) {
# POSIX array of arrays!
/^\tdepends/ {
if ((!length(DEPENDS) || DEPENDS == 1) && !in_split_pkg)
pkg_deps[pkgbase, ++dep_counts[pkgbase]] = $3 # versioned
}
/^\tmakedepends/ {
if ((!length(MAKEDEPENDS) || MAKEDEPENDS == 1) && !in_split_pkg)
pkg_deps[pkgbase, ++dep_counts[pkgbase]] = $3
}
/^\tcheckdepends/ {
if ((!length(CHECKDEPENDS) || CHECKDEPENDS == 1) && !in_split_pkg)
pkg_deps[pkgbase, ++dep_counts[pkgbase]] = $3
}
/^\toptdepends/ {
if (OPTDEPENDS == 1 && !in_split_pkg) {
pkg_deps[pkgbase, ++dep_counts[pkgbase]] = $3
}
}

Loading…
Cancel
Save