Fix sepolicy/__init__.py to handle _()
This commit is contained in:
parent
c80e41cce5
commit
5ffa11c17a
@ -338436,10 +338436,10 @@ index 0000000..2647bbc
|
|||||||
+ sys.exit(0)
|
+ sys.exit(0)
|
||||||
diff --git a/policycoreutils/sepolicy/sepolicy/__init__.py b/policycoreutils/sepolicy/sepolicy/__init__.py
|
diff --git a/policycoreutils/sepolicy/sepolicy/__init__.py b/policycoreutils/sepolicy/sepolicy/__init__.py
|
||||||
new file mode 100644
|
new file mode 100644
|
||||||
index 0000000..96a7251
|
index 0000000..e43a2fb
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/policycoreutils/sepolicy/sepolicy/__init__.py
|
+++ b/policycoreutils/sepolicy/sepolicy/__init__.py
|
||||||
@@ -0,0 +1,124 @@
|
@@ -0,0 +1,136 @@
|
||||||
+#!/usr/bin/env python
|
+#!/usr/bin/env python
|
||||||
+
|
+
|
||||||
+# Author: Thomas Liu <tliu@redhat.com>
|
+# Author: Thomas Liu <tliu@redhat.com>
|
||||||
@ -338447,6 +338447,18 @@ index 0000000..96a7251
|
|||||||
+
|
+
|
||||||
+import _policy
|
+import _policy
|
||||||
+import selinux
|
+import selinux
|
||||||
|
+PROGNAME="policycoreutils"
|
||||||
|
+import gettext
|
||||||
|
+gettext.bindtextdomain(PROGNAME, "/usr/share/locale")
|
||||||
|
+gettext.textdomain(PROGNAME)
|
||||||
|
+try:
|
||||||
|
+ gettext.install(PROGNAME,
|
||||||
|
+ localedir="/usr/share/locale",
|
||||||
|
+ unicode=False,
|
||||||
|
+ codeset = 'utf-8')
|
||||||
|
+except IOError:
|
||||||
|
+ import __builtin__
|
||||||
|
+ __builtin__.__dict__['_'] = unicode
|
||||||
+
|
+
|
||||||
+TYPE = _policy.TYPE
|
+TYPE = _policy.TYPE
|
||||||
+ROLE = _policy.ROLE
|
+ROLE = _policy.ROLE
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
Summary: SELinux policy core utilities
|
Summary: SELinux policy core utilities
|
||||||
Name: policycoreutils
|
Name: policycoreutils
|
||||||
Version: 2.1.13
|
Version: 2.1.13
|
||||||
Release: 35%{?dist}
|
Release: 36%{?dist}
|
||||||
License: GPLv2
|
License: GPLv2
|
||||||
Group: System Environment/Base
|
Group: System Environment/Base
|
||||||
# Based on git repository with tag 20101221
|
# Based on git repository with tag 20101221
|
||||||
@ -338,6 +338,9 @@ The policycoreutils-restorecond package contains the restorecond service.
|
|||||||
%{_bindir}/systemctl try-restart restorecond.service >/dev/null 2>&1 || :
|
%{_bindir}/systemctl try-restart restorecond.service >/dev/null 2>&1 || :
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Nov 27 2012 Dan Walsh <dwalsh@redhat.com> - 2.1.12-36
|
||||||
|
- Fix sepolicy/__init__.py to handle _()
|
||||||
|
|
||||||
* Wed Nov 21 2012 Dan Walsh <dwalsh@redhat.com> - 2.1.12-35
|
* Wed Nov 21 2012 Dan Walsh <dwalsh@redhat.com> - 2.1.12-35
|
||||||
- Add Miroslav Grepl patch to create etc_rw_t sock files policy
|
- Add Miroslav Grepl patch to create etc_rw_t sock files policy
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user