{
int noobs = solv->noobsoletes.size && MAPTST(&solv->noobsoletes, n);
int isinstalled = (installed && s->repo == installed);
- if (s->obsoletes && !noobs)
+ if (s->obsoletes && (!noobs || solv->keepexplicitobsoletes))
{
obsp = s->repo->idarraydata + s->obsoletes;
/* foreach obsoletes */
return solv->addalreadyrecommended;
case SOLVER_FLAG_NO_INFARCHCHECK:
return solv->noinfarchcheck;
+ case SOLVER_FLAG_KEEP_EXPLICIT_OBSOLETES:
+ return solv->keepexplicitobsoletes;
default:
break;
}
case SOLVER_FLAG_NO_INFARCHCHECK:
solv->noinfarchcheck = value;
break;
+ case SOLVER_FLAG_KEEP_EXPLICIT_OBSOLETES:
+ solv->keepexplicitobsoletes = value;
+ break;
default:
break;
}
/* log solver options */
POOL_DEBUG(SOLV_DEBUG_STATS, "solver started\n");
- POOL_DEBUG(SOLV_DEBUG_STATS, "dosplitprovides=%d, noupdateprovide=%d noinfarchcheck=%d\n", solv->dosplitprovides, solv->noupdateprovide, solv->noinfarchcheck);
+ POOL_DEBUG(SOLV_DEBUG_STATS, "dosplitprovides=%d, noupdateprovide=%d, noinfarchcheck=%d\n", solv->dosplitprovides, solv->noupdateprovide, solv->noinfarchcheck);
POOL_DEBUG(SOLV_DEBUG_STATS, "allowuninstall=%d, allowdowngrade=%d, allownamechange=%d, allowarchchange=%d, allowvendorchange=%d\n", solv->allowuninstall, solv->allowdowngrade, solv->allownamechange, solv->allowarchchange, solv->allowvendorchange);
POOL_DEBUG(SOLV_DEBUG_STATS, "promoteepoch=%d, forbidselfconflicts=%d\n", pool->promoteepoch, pool->forbidselfconflicts);
POOL_DEBUG(SOLV_DEBUG_STATS, "obsoleteusesprovides=%d, implicitobsoleteusesprovides=%d, obsoleteusescolors=%d\n", pool->obsoleteusesprovides, pool->implicitobsoleteusesprovides, pool->obsoleteusescolors);
int dontshowinstalledrecommended; /* true: do not show recommended packages that are already installed */
int noinfarchcheck; /* true: do not forbid inferior architectures */
+ int keepexplicitobsoletes; /* true: honor obsoletes during multiinstall */
Map dupmap; /* dup these packages*/
#define SOLVER_FLAG_ADD_ALREADY_RECOMMENDED 8
#define SOLVER_FLAG_NO_INFARCHCHECK 9
#define SOLVER_FLAG_ALLOW_NAMECHANGE 10
+#define SOLVER_FLAG_KEEP_EXPLICIT_OBSOLETES 11
extern Solver *solver_create(Pool *pool);
extern void solver_free(Solver *solv);
POOL_DEBUG(SOLV_DEBUG_RESULT, "installed package %s obsoletes %s provided by %s\n", pool_solvid2str(pool, source), pool_dep2str(pool, dep), pool_solvid2str(pool, target));
return;
case SOLVER_RULE_RPM_IMPLICIT_OBSOLETES:
- POOL_DEBUG(SOLV_DEBUG_RESULT, "package %s implicitely obsoletes %s provided by %s\n", pool_solvid2str(pool, source), pool_dep2str(pool, dep), pool_solvid2str(pool, target));
+ POOL_DEBUG(SOLV_DEBUG_RESULT, "package %s implicitly obsoletes %s provided by %s\n", pool_solvid2str(pool, source), pool_dep2str(pool, dep), pool_solvid2str(pool, target));
return;
case SOLVER_RULE_RPM_PACKAGE_REQUIRES:
POOL_DEBUG(SOLV_DEBUG_RESULT, "package %s requires %s, but none of the providers can be installed\n", pool_solvid2str(pool, source), pool_dep2str(pool, dep));
return pool_tmpappend(pool, s, " provided by ", pool_solvid2str(pool, target));
case SOLVER_RULE_RPM_IMPLICIT_OBSOLETES:
s = pool_tmpjoin(pool, "package ", pool_solvid2str(pool, source), 0);
- s = pool_tmpappend(pool, s, " implicitely obsoletes ", pool_dep2str(pool, dep));
+ s = pool_tmpappend(pool, s, " implicitly obsoletes ", pool_dep2str(pool, dep));
return pool_tmpappend(pool, s, " provided by ", pool_solvid2str(pool, target));
case SOLVER_RULE_RPM_PACKAGE_REQUIRES:
s = pool_tmpjoin(pool, "package ", pool_solvid2str(pool, source), " requires ");