summaryrefslogtreecommitdiff
path: root/lib/libalpm/deps.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libalpm/deps.c')
-rw-r--r--lib/libalpm/deps.c47
1 files changed, 25 insertions, 22 deletions
diff --git a/lib/libalpm/deps.c b/lib/libalpm/deps.c
index 794fbdbc..591e5a87 100644
--- a/lib/libalpm/deps.c
+++ b/lib/libalpm/deps.c
@@ -140,7 +140,7 @@ alpm_list_t *_alpm_sortbydeps(alpm_list_t *targets, pmtranstype_t mode)
return(NULL);
}
- _alpm_log(PM_LOG_DEBUG, _("started sorting dependencies"));
+ _alpm_log(PM_LOG_DEBUG, "started sorting dependencies");
/* We create the vertices */
for(i = targets; i; i = i->next) {
@@ -203,7 +203,7 @@ alpm_list_t *_alpm_sortbydeps(alpm_list_t *targets, pmtranstype_t mode)
}
}
- _alpm_log(PM_LOG_DEBUG, _("sorting dependencies finished"));
+ _alpm_log(PM_LOG_DEBUG, "sorting dependencies finished");
if(mode == PM_TRANS_TYPE_REMOVE) {
/* we're removing packages, so reverse the order */
@@ -246,12 +246,12 @@ alpm_list_t *_alpm_checkdeps(pmdb_t *db, pmtranstype_t op,
pmpkg_t *newpkg = i->data;
pmpkg_t *oldpkg;
if(newpkg == NULL) {
- _alpm_log(PM_LOG_DEBUG, _("null package found in package list"));
+ _alpm_log(PM_LOG_DEBUG, "null package found in package list");
continue;
}
if((oldpkg = _alpm_db_get_pkgfromcache(db, alpm_pkg_get_name(newpkg))) == NULL) {
- _alpm_log(PM_LOG_DEBUG, _("cannot find package installed '%s'"),
+ _alpm_log(PM_LOG_DEBUG, "cannot find package installed '%s'",
alpm_pkg_get_name(newpkg));
continue;
}
@@ -284,7 +284,7 @@ alpm_list_t *_alpm_checkdeps(pmdb_t *db, pmtranstype_t op,
pmpkg_t *pkg = l->data;
if(alpm_depcmp(pkg, depend)) {
- _alpm_log(PM_LOG_DEBUG, _("checkdeps: dependency '%s' has moved from '%s' to '%s'"),
+ _alpm_log(PM_LOG_DEBUG, "checkdeps: dependency '%s' has moved from '%s' to '%s'",
depend->name, alpm_pkg_get_name(oldpkg), alpm_pkg_get_name(pkg));
satisfied = 1;
break;
@@ -300,7 +300,7 @@ alpm_list_t *_alpm_checkdeps(pmdb_t *db, pmtranstype_t op,
if(alpm_depcmp(pkg, depend) && !_alpm_pkg_find(alpm_pkg_get_name(pkg), packages)) {
/* we ignore packages that will be updated because we know
* that the updated ones don't satisfy depend */
- _alpm_log(PM_LOG_DEBUG, _("checkdeps: dependency '%s' satisfied by installed package '%s'"),
+ _alpm_log(PM_LOG_DEBUG, "checkdeps: dependency '%s' satisfied by installed package '%s'",
depend->name, alpm_pkg_get_name(pkg));
satisfied = 1;
break;
@@ -309,7 +309,7 @@ alpm_list_t *_alpm_checkdeps(pmdb_t *db, pmtranstype_t op,
}
if(!satisfied) {
- _alpm_log(PM_LOG_DEBUG, _("checkdeps: updated '%s' won't satisfy a dependency of '%s'"),
+ _alpm_log(PM_LOG_DEBUG, "checkdeps: updated '%s' won't satisfy a dependency of '%s'",
alpm_pkg_get_name(oldpkg), alpm_pkg_get_name(p));
miss = _alpm_depmiss_new(p->name, PM_DEP_TYPE_DEPEND, depend->mod,
depend->name, depend->version);
@@ -330,7 +330,7 @@ alpm_list_t *_alpm_checkdeps(pmdb_t *db, pmtranstype_t op,
for(i = packages; i; i = i->next) {
pmpkg_t *tp = i->data;
if(tp == NULL) {
- _alpm_log(PM_LOG_DEBUG, _("null package found in package list"));
+ _alpm_log(PM_LOG_DEBUG, "null package found in package list");
continue;
}
@@ -358,7 +358,7 @@ alpm_list_t *_alpm_checkdeps(pmdb_t *db, pmtranstype_t op,
/* else if still not found... */
if(!found) {
- _alpm_log(PM_LOG_DEBUG, _("missing dependency '%s' for package '%s'"),
+ _alpm_log(PM_LOG_DEBUG, "missing dependency '%s' for package '%s'",
depend->name, alpm_pkg_get_name(tp));
miss = _alpm_depmiss_new(alpm_pkg_get_name(tp), PM_DEP_TYPE_DEPEND, depend->mod,
depend->name, depend->version);
@@ -377,7 +377,7 @@ alpm_list_t *_alpm_checkdeps(pmdb_t *db, pmtranstype_t op,
pmpkg_t *rmpkg = alpm_list_getdata(i);
if(rmpkg == NULL) {
- _alpm_log(PM_LOG_DEBUG, _("null package found in package list"));
+ _alpm_log(PM_LOG_DEBUG, "null package found in package list");
continue;
}
for(j = alpm_pkg_get_requiredby(rmpkg); j; j = j->next) {
@@ -404,7 +404,7 @@ alpm_list_t *_alpm_checkdeps(pmdb_t *db, pmtranstype_t op,
for(l = _alpm_db_get_pkgcache(db); l; l = l->next) {
pmpkg_t *pkg = l->data;
if(alpm_depcmp(pkg, depend) && !_alpm_pkg_find(alpm_pkg_get_name(pkg), packages)) {
- _alpm_log(PM_LOG_DEBUG, _("checkdeps: dependency '%s' satisfied by installed package '%s'"),
+ _alpm_log(PM_LOG_DEBUG, "checkdeps: dependency '%s' satisfied by installed package '%s'",
depend->name, alpm_pkg_get_name(pkg));
satisfied = 1;
break;
@@ -412,7 +412,7 @@ alpm_list_t *_alpm_checkdeps(pmdb_t *db, pmtranstype_t op,
}
if(!satisfied) {
- _alpm_log(PM_LOG_DEBUG, _("checkdeps: found %s which requires %s"),
+ _alpm_log(PM_LOG_DEBUG, "checkdeps: found %s which requires %s",
alpm_pkg_get_name(p), alpm_pkg_get_name(rmpkg));
miss = _alpm_depmiss_new(alpm_pkg_get_name(p),
PM_DEP_TYPE_DEPEND, depend->mod, depend->name,
@@ -495,7 +495,8 @@ static int can_remove_package(pmdb_t *db, pmpkg_t *pkg, alpm_list_t *targets)
/* see if it was explicitly installed */
if(alpm_pkg_get_reason(pkg) == PM_PKG_REASON_EXPLICIT) {
- _alpm_log(PM_LOG_DEBUG, _("excluding %s -- explicitly installed"), alpm_pkg_get_name(pkg));
+ _alpm_log(PM_LOG_DEBUG, "excluding %s -- explicitly installed",
+ alpm_pkg_get_name(pkg));
return(0);
}
@@ -542,7 +543,7 @@ alpm_list_t *_alpm_removedeps(pmdb_t *db, alpm_list_t *targs)
alpm_list_t *provides = _alpm_db_whatprovides(db, depend->name);
if(!provides) {
/* Not found, that's fine, carry on */
- _alpm_log(PM_LOG_DEBUG, _("cannot find package \"%s\" or anything that provides it!"), depend->name);
+ _alpm_log(PM_LOG_DEBUG, "cannot find package \"%s\" or anything that provides it!", depend->name);
continue;
}
for(k = provides; k; k = k->next) {
@@ -550,7 +551,8 @@ alpm_list_t *_alpm_removedeps(pmdb_t *db, alpm_list_t *targs)
if(can_remove_package(db, provpkg, newtargs)) {
pmpkg_t *pkg = _alpm_pkg_dup(provpkg);
- _alpm_log(PM_LOG_DEBUG, _("adding '%s' to the targets"), alpm_pkg_get_name(pkg));
+ _alpm_log(PM_LOG_DEBUG, "adding '%s' to the targets",
+ alpm_pkg_get_name(pkg));
/* add it to the target list */
newtargs = alpm_list_add(newtargs, pkg);
@@ -561,7 +563,8 @@ alpm_list_t *_alpm_removedeps(pmdb_t *db, alpm_list_t *targs)
} else if(can_remove_package(db, deppkg, newtargs)) {
pmpkg_t *pkg = _alpm_pkg_dup(deppkg);
- _alpm_log(PM_LOG_DEBUG, _("adding '%s' to the targets"), alpm_pkg_get_name(pkg));
+ _alpm_log(PM_LOG_DEBUG, "adding '%s' to the targets",
+ alpm_pkg_get_name(pkg));
/* add it to the target list */
newtargs = alpm_list_add(newtargs, pkg);
@@ -593,7 +596,7 @@ int _alpm_resolvedeps(pmdb_t *local, alpm_list_t *dbs_sync, pmpkg_t *syncpkg,
return(-1);
}
- _alpm_log(PM_LOG_DEBUG, _("started resolving dependencies"));
+ _alpm_log(PM_LOG_DEBUG, "started resolving dependencies");
targ = alpm_list_add(NULL, syncpkg);
deps = _alpm_checkdeps(local, PM_TRANS_TYPE_ADD, targ);
alpm_list_free(targ);
@@ -611,7 +614,7 @@ int _alpm_resolvedeps(pmdb_t *local, alpm_list_t *dbs_sync, pmpkg_t *syncpkg,
for(j = list; j && !found; j = j->next) {
pmpkg_t *sp = j->data;
if(alpm_list_find_str(alpm_pkg_get_provides(sp), miss->depend.name)) {
- _alpm_log(PM_LOG_DEBUG, _("%s provides dependency %s -- skipping"),
+ _alpm_log(PM_LOG_DEBUG, "%s provides dependency %s -- skipping",
alpm_pkg_get_name(sp), miss->depend.name);
found = 1;
}
@@ -657,7 +660,7 @@ int _alpm_resolvedeps(pmdb_t *local, alpm_list_t *dbs_sync, pmpkg_t *syncpkg,
}
if(_alpm_pkg_find(alpm_pkg_get_name(sync), list)) {
/* this dep is already in the target list */
- _alpm_log(PM_LOG_DEBUG, _("dependency %s is already in the target list -- skipping"),
+ _alpm_log(PM_LOG_DEBUG, "dependency %s is already in the target list -- skipping",
alpm_pkg_get_name(sync));
continue;
}
@@ -677,7 +680,7 @@ int _alpm_resolvedeps(pmdb_t *local, alpm_list_t *dbs_sync, pmpkg_t *syncpkg,
if(_alpm_resolvedeps(local, dbs_sync, sync, list, trail, trans, data)) {
goto error;
}
- _alpm_log(PM_LOG_DEBUG, _("pulling dependency %s (needed by %s)"),
+ _alpm_log(PM_LOG_DEBUG, "pulling dependency %s (needed by %s)",
alpm_pkg_get_name(sync), alpm_pkg_get_name(syncpkg));
list = alpm_list_add(list, sync);
} else {
@@ -697,11 +700,11 @@ int _alpm_resolvedeps(pmdb_t *local, alpm_list_t *dbs_sync, pmpkg_t *syncpkg,
}
} else {
/* cycle detected -- skip it */
- _alpm_log(PM_LOG_DEBUG, _("dependency cycle detected: %s"), sync->name);
+ _alpm_log(PM_LOG_DEBUG, "dependency cycle detected: %s", sync->name);
}
}
- _alpm_log(PM_LOG_DEBUG, _("finished resolving dependencies"));
+ _alpm_log(PM_LOG_DEBUG, "finished resolving dependencies");
FREELIST(deps);