summaryrefslogtreecommitdiff
path: root/portato/backend
diff options
context:
space:
mode:
Diffstat (limited to 'portato/backend')
-rw-r--r--portato/backend/flags.py3
-rw-r--r--portato/backend/portage/package.py3
-rw-r--r--portato/backend/portage/system.py7
3 files changed, 8 insertions, 5 deletions
diff --git a/portato/backend/flags.py b/portato/backend/flags.py
index 6c2a159..dd1e462 100644
--- a/portato/backend/flags.py
+++ b/portato/backend/flags.py
@@ -13,6 +13,7 @@
import os
import os.path
from subprocess import Popen, PIPE # needed for grep
+from gettext import lgettext as _
from portato.helper import *
from portato.backend import system
@@ -478,7 +479,7 @@ def new_masking_status (cpv):
for file, line in list[cpv]:
_ret = (int(line) == -1)
if ret is not None and _ret != ret:
- error("Conflicting values for masking status: %s", list)
+ error(_("Conflicting values for masking status: %s"), list)
else:
ret = _ret
return ret
diff --git a/portato/backend/portage/package.py b/portato/backend/portage/package.py
index a1bf433..7ab1713 100644
--- a/portato/backend/portage/package.py
+++ b/portato/backend/portage/package.py
@@ -18,6 +18,7 @@ import portage, portage_dep
from portage_util import unique_array
import os.path
+from gettext import lgettext as _
class PortagePackage (Package):
"""This is a class abstracting a normal package which can be installed for the portage-system."""
@@ -89,7 +90,7 @@ class PortagePackage (Package):
if status == "masked": return True
elif status == "unmasked": return False
else:
- error("BUG in flags.new_masking_status. It returns \'%s\'", status)
+ error(_("BUG in flags.new_masking_status. It returns \'%s\'"), status)
else: # we have not touched the status
if self._status and ("profile" in self._status or "package.mask" in self._status):
return True
diff --git a/portato/backend/portage/system.py b/portato/backend/portage/system.py
index 44ac404..bf1b821 100644
--- a/portato/backend/portage/system.py
+++ b/portato/backend/portage/system.py
@@ -12,6 +12,7 @@
import re, os
import types
+from gettext import lgettext as _
import portage
import package
@@ -282,7 +283,7 @@ class PortageSystem (SystemInterface):
best_p = self.find_best_match(p)
if best_p is None:
- warning("No best match for %s. It seems not to be in the tree anymore." % p)
+ warning(_("No best match for %s. It seems not to be in the tree anymore.") % p)
continue
if len(inst) > 1:
@@ -339,7 +340,7 @@ class PortageSystem (SystemInterface):
oldList = self.sort_package_list(self.find_installed_packages(p.get_cp()))
if not oldList:
if add_not_installed:
- info("Found a not installed dependency: %s." % p.get_cpv())
+ info(_("Found a not installed dependency: %s.") % p.get_cpv())
oldList = [p]
else:
return
@@ -379,7 +380,7 @@ class PortageSystem (SystemInterface):
raw_checked.append(i)
bm = self.get_new_packages([i])
if not bm:
- warning("Bug? No best match could be found for '%s'. Needed by: '%s'.", i, p.get_cpv())
+ warning(_("Bug? No best match could be found for '%(package)s'. Needed by: '%(cpv)s'."), {"package" : i, "cpv": p.get_cpv()})
else:
for pkg in bm:
if not pkg: continue