[policycoreutils/f18] Remove dwalsh at redhat.com from man pages

Daniel J Walsh dwalsh at fedoraproject.org
Wed Oct 17 14:23:49 UTC 2012


commit 0490cb73e523029a18813fa821bbb5c0e945d354
Author: rhatdan <dwalsh at redhat.com>
Date:   Wed Oct 17 10:23:22 2012 -0400

    Remove dwalsh at redhat.com from man pages
    
    - Fix spec file for sepolicy generate

 policycoreutils-rhat.patch |   46 +++++++++++++++++++++++++++----------------
 policycoreutils.spec       |    6 ++++-
 2 files changed, 34 insertions(+), 18 deletions(-)
---
diff --git a/policycoreutils-rhat.patch b/policycoreutils-rhat.patch
index 7e118b1..728b55c 100644
--- a/policycoreutils-rhat.patch
+++ b/policycoreutils-rhat.patch
@@ -339531,10 +339531,10 @@ index 0000000..8ba41c3
 +            return out
 diff --git a/policycoreutils/sepolicy/sepolicy/manpage.py b/policycoreutils/sepolicy/sepolicy/manpage.py
 new file mode 100755
-index 0000000..75270b1
+index 0000000..d5dd71d
 --- /dev/null
 +++ b/policycoreutils/sepolicy/sepolicy/manpage.py
-@@ -0,0 +1,1005 @@
+@@ -0,0 +1,1018 @@
 +#! /usr/bin/python -Es
 +# Copyright (C) 2012 Red Hat 
 +# AUTHOR: Dan Walsh <dwalsh at redhat.com>
@@ -339565,7 +339565,7 @@ index 0000000..75270b1
 +import selinux
 +import sepolicy
 +import commands
-+import sys, os, re
++import sys, os, re, time
 +
 +equiv_dict={ "smbd" : "samba" }
 +
@@ -339810,9 +339810,20 @@ index 0000000..75270b1
 +            if f.startswith(self.short_name):
 +                self.ptypes.append(f)
 +
++    def __whoami(self):
++	    import pwd
++	    fd = open("/proc/self/loginuid", "r")
++	    uid = int(fd.read())
++	    fd.close()
++	    pw = pwd.getpwuid(uid)
++	    if len(pw.pw_gecos) > 0:
++		    return pw.pw_gecos
++	    else:
++		    return pw.pw_name
++
 +    def _header(self):
-+        self.fd.write('.TH  "%(domainname)s_selinux"  "8"  "%(domainname)s" "dwalsh at redhat.com" "%(domainname)s SELinux Policy documentation"'
-+                 % {'domainname':self.domainname})
++        self.fd.write('.TH  "%(domainname)s_selinux"  "8"  "%(date)s" "%(domainname)s" "SELinux Policy documentation for %(domainname)s"'
++                 % {'domainname':self.domainname, 'date': time.strftime("%y-%m-%d")})
 +        self.fd.write(r"""
 +.SH "NAME"
 +%(domainname)s_selinux \- Security Enhanced Linux Policy for the %(domainname)s processes
@@ -340190,11 +340201,13 @@ index 0000000..75270b1
 +is a GUI tool available to customize SELinux policy settings.
 +
 +.SH AUTHOR	
-+This manual page was auto-generated by genman.py.
++This manual page was auto-generated using 
++.B "sepolicy manpage"
++by %s.
 +
 +.SH "SEE ALSO"
-+selinux(8), %s(8), semanage(8), restorecon(8), chcon(1)
-+""" % self.domainname)
++selinux(8), %s(8), semanage(8), restorecon(8), chcon(1), sepolicy(8)
++""" % (self.__whoami(), self.domainname))
 +
 +        if self.booltext != "":        
 +            self.fd.write(", setsebool(8)")
@@ -340853,7 +340866,7 @@ index 0000000..dcf445e
 +"""
 diff --git a/policycoreutils/sepolicy/sepolicy/templates/executable.py b/policycoreutils/sepolicy/sepolicy/templates/executable.py
 new file mode 100644
-index 0000000..824fddd
+index 0000000..fd89671
 --- /dev/null
 +++ b/policycoreutils/sepolicy/sepolicy/templates/executable.py
 @@ -0,0 +1,450 @@
@@ -341076,7 +341089,7 @@ index 0000000..824fddd
 +
 +########################################
 +## <summary>
-+##	Transition to TEMPLATETYPE.
++##	Execute TEMPLATE in the TEMPLATETYPE domin.
 +## </summary>
 +## <param name=\"domain\">
 +## <summary>
@@ -341762,10 +341775,10 @@ index 0000000..f77e50e
 +"""
 diff --git a/policycoreutils/sepolicy/sepolicy/templates/spec.py b/policycoreutils/sepolicy/sepolicy/templates/spec.py
 new file mode 100644
-index 0000000..ca109aa
+index 0000000..a0562ef
 --- /dev/null
 +++ b/policycoreutils/sepolicy/sepolicy/templates/spec.py
-@@ -0,0 +1,72 @@
+@@ -0,0 +1,71 @@
 +header_comment_section="""\
 +# vim: sw=4:ts=4:et
 +"""
@@ -341797,13 +341810,12 @@ index 0000000..ca109aa
 +This package installs and sets up the  SELinux policy security module for MODULENAME.
 +
 +%install
-+# Install SELinux interfaces
-+install -d %{buildroot}%{_datadir}/selinux/devel/include/contrib
-+install -m 644 MODULENAME.if %{buildroot}%{_datadir}/selinux/devel/include/contrib/MODULENAME.if
 +install -d %{buildroot}%{_datadir}/selinux/packages
-+install -m 644 MODULENAME.pp %{buildroot}%{_datadir}/selinux/packages/
++install -m 644 %{SOURCE0} %{buildroot}%{_datadir}/selinux/packages
++install -d %{buildroot}%{_datadir}/selinux/devel/include/contrib
++install -m 644 %{SOURCE1} %{buildroot}%{_datadir}/selinux/devel/include/contrib/
 +install -d %{buildroot}%{_mandir}/man8/
-+install -m 644 MODULENAME_selinux.8 %{buildroot}%{_mandir}/man8/
++install -m 644 %{SOURCE2} %{buildroot}%{_mandir}/man8/
 +
 +%post
 +if /usr/sbin/selinuxenabled ; then
diff --git a/policycoreutils.spec b/policycoreutils.spec
index 8331039..b756a45 100644
--- a/policycoreutils.spec
+++ b/policycoreutils.spec
@@ -7,7 +7,7 @@
 Summary: SELinux policy core utilities
 Name:	 policycoreutils
 Version: 2.1.13
-Release: 12%{?dist}
+Release: 13%{?dist}
 License: GPLv2
 Group:	 System Environment/Base
 # Based on git repository with tag 20101221
@@ -330,6 +330,10 @@ The policycoreutils-restorecond package contains the restorecond service.
 %{_bindir}/systemctl try-restart restorecond.service >/dev/null 2>&1 || :
 
 %changelog
+* Wed Oct 17 2012 Dan Walsh <dwalsh at redhat.com> - 2.1.12-13
+- Remove dwalsh at redhat.com from man pages
+- Fix spec file for sepolicy generate
+
 * Wed Oct 17 2012 Dan Walsh <dwalsh at redhat.com> - 2.1.12-12
 - Add missing spec.py from templates directory needed for sepolicy generate
 - Add /var/tmp as collection point for sandbox apps.


More information about the scm-commits mailing list