Commit c35086dc authored by Timo Teräs's avatar Timo Teräs

solver: purge install_if packages deleted from repositories on upgrade -a

parent 9fa64ca1
...@@ -187,8 +187,6 @@ static void discover_name(struct apk_solver_state *ss, struct apk_name *name) ...@@ -187,8 +187,6 @@ static void discover_name(struct apk_solver_state *ss, struct apk_name *name)
continue; continue;
pkg->ss.seen = 1; pkg->ss.seen = 1;
pkg->ss.iif_failed = (pkg->install_if->num == 0);
name->ss.no_iif &= pkg->ss.iif_failed;
pkg->ss.pinning_allowed = APK_DEFAULT_PINNING_MASK; pkg->ss.pinning_allowed = APK_DEFAULT_PINNING_MASK;
pkg->ss.pinning_preferred = APK_DEFAULT_PINNING_MASK; pkg->ss.pinning_preferred = APK_DEFAULT_PINNING_MASK;
...@@ -201,6 +199,15 @@ static void discover_name(struct apk_solver_state *ss, struct apk_name *name) ...@@ -201,6 +199,15 @@ static void discover_name(struct apk_solver_state *ss, struct apk_name *name)
(pkg->repos & db->available_repos) || (pkg->repos & db->available_repos) ||
pkg->ipkg; pkg->ipkg;
/* Prune install_if packages that are no longer available,
* currently works only if SOLVERF_AVAILABLE is set in the
* global solver flags. */
pkg->ss.iif_failed =
(pkg->install_if->num == 0) ||
((ss->solver_flags_inherit & APK_SOLVERF_AVAILABLE) &&
!pkg->ss.pkg_available);
name->ss.no_iif &= pkg->ss.iif_failed;
repos = get_pkg_repos(db, pkg); repos = get_pkg_repos(db, pkg);
pkg->ss.tag_preferred = pkg->ss.tag_preferred =
(pkg->filename != NULL) || (pkg->filename != NULL) ||
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment