- int i;
- pkg_t *pkg;
- abstract_pkg_t *ab_pkg = (abstract_pkg_t *)entry;
- opkg_conf_t *conf = (opkg_conf_t *)data;
- abstract_pkg_t ** dependents = ab_pkg->depended_upon_by;
- fprintf(stdout, "%s\n", ab_pkg->name);
- i = 0;
- if (dependents != NULL)
- while (dependents [i] != NULL)
- printf ("\tdepended upon by - %s\n", dependents [i ++]->name);
- dependents = ab_pkg->provided_by->pkgs;
- i = 0;
- if (dependents != NULL)
- while (dependents [i] != NULL && i < ab_pkg->provided_by->len)
- printf ("\tprovided by - %s\n", dependents [i ++]->name);
- pkg = pkg_hash_fetch_best_installation_candidate_by_name (conf, ab_pkg->name, NULL);
- if (pkg) {
- i = 0;
- while (i < pkg->depends_count)
- printf ("\tdepends on - %s\n", pkg->depends_str [i ++]);
- }