From: Jo-Philipp Wich Date: Mon, 27 Feb 2017 18:24:31 +0000 (+0100) Subject: pkg_depends: propagate virtual provided detail flag to providers X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=0fb3e9f24ffe4fd04da800ca988d60d2ed835457;p=oweals%2Fopkg-lede.git pkg_depends: propagate virtual provided detail flag to providers When the provided abstract package (e.g. "px5g" provided by "px5g-mbedtls") is marked as requiring details, then mark the provider abstract package as well. This ensures that package info for discrete provider packages is acquired and retained if the virtual package they provide is being depended upon by another package requiring details. Signed-off-by: Jo-Philipp Wich --- diff --git a/libopkg/pkg_depends.c b/libopkg/pkg_depends.c index 0883b4f..aa34987 100644 --- a/libopkg/pkg_depends.c +++ b/libopkg/pkg_depends.c @@ -678,6 +678,14 @@ void parse_providelist(pkg_t *pkg, char *list) provided_abpkg = ensure_abstract_pkg_by_name(item); + if (provided_abpkg->state_flag & SF_NEED_DETAIL) { + if (!(ab_pkg->state_flag & SF_NEED_DETAIL)) { + opkg_msg(DEBUG, "propagating provided abpkg flag to " + "provider abpkg %s\n", ab_pkg->name); + ab_pkg->state_flag |= SF_NEED_DETAIL; + } + } + if (!abstract_pkg_vec_contains(provided_abpkg->provided_by, ab_pkg)) abstract_pkg_vec_insert(provided_abpkg->provided_by, ab_pkg);