depends: revert to functional style
When iterating over the package results, an entry can be a `pkgname`, a
`provides`, or both. Return to the functional style in aurutils <=17.3
using `map` (iteration variable `$_`) to reflect this.
Compared to the old code using `map`:
1. the `Self` dependency is added in `chain_mod` instead of `chain`
2. `None` dependencies are only added if either `--show-all` is set,
or they are a virtual target (provided by an AUR target in some
dependency level)
3. `RequiredBy` is a flat dictionary as in v18.x
Issue #1112