diff options
author | Chris PeBenito <pebenito@gentoo.org> | 2006-10-05 06:47:07 +0000 |
---|---|---|
committer | Chris PeBenito <pebenito@gentoo.org> | 2006-10-05 06:47:07 +0000 |
commit | b27a537b26a760bba517c53aabd77632ca864685 (patch) | |
tree | 4d3acf82e2d6d64d9db87239a920448678e491ef /sys-apps/policycoreutils | |
parent | Append -fno-strict-aliasing on PPC. Thanks to Andy Botting for reporting, and... (diff) | |
download | gentoo-2-b27a537b26a760bba517c53aabd77632ca864685.tar.gz gentoo-2-b27a537b26a760bba517c53aabd77632ca864685.tar.bz2 gentoo-2-b27a537b26a760bba517c53aabd77632ca864685.zip |
Add SVN snapshot and updated extras in preparation for reference policy.
(Portage version: 2.1.2_pre2-r2)
Diffstat (limited to 'sys-apps/policycoreutils')
5 files changed, 169 insertions, 1 deletions
diff --git a/sys-apps/policycoreutils/ChangeLog b/sys-apps/policycoreutils/ChangeLog index 64d0afb97e3b..f44cd7df7d58 100644 --- a/sys-apps/policycoreutils/ChangeLog +++ b/sys-apps/policycoreutils/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for sys-apps/policycoreutils # Copyright 2000-2006 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/policycoreutils/ChangeLog,v 1.58 2006/07/31 01:30:13 pebenito Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-apps/policycoreutils/ChangeLog,v 1.59 2006/10/05 06:47:07 pebenito Exp $ + +*policycoreutils-1.30.30 (05 Oct 2006) + + 05 Oct 2006; Chris PeBenito <pebenito@gentoo.org> + +files/policycoreutils-1.32-quietlp.diff, +policycoreutils-1.30.30.ebuild: + Add SVN snapshot and updated extras in preparation for reference policy. 31 Jul 2006; Chris PeBenito <pebenito@gentoo.org> policycoreutils-1.30-r1.ebuild: diff --git a/sys-apps/policycoreutils/files/digest-policycoreutils-1.28 b/sys-apps/policycoreutils/files/digest-policycoreutils-1.28 index 5c910d64aed4..8edfb046ef25 100644 --- a/sys-apps/policycoreutils/files/digest-policycoreutils-1.28 +++ b/sys-apps/policycoreutils/files/digest-policycoreutils-1.28 @@ -1,2 +1,6 @@ MD5 45061fa490efac5926ecc8de9e3ef864 policycoreutils-1.28.tgz 74321 +RMD160 0dd32e3e6dd3dcca0c01f3679f956800bcf6868f policycoreutils-1.28.tgz 74321 +SHA256 84df52fe09bac8e7476683e7d796f7388f9ce1986c06a0e7274b51e0fbef5c51 policycoreutils-1.28.tgz 74321 MD5 a0595be9678253715c409c4cbc8756f1 policycoreutils-extra-1.14.tar.bz2 15209 +RMD160 ba63c608883ffdbfd8b4c6cb82e4db836d011b38 policycoreutils-extra-1.14.tar.bz2 15209 +SHA256 f031173ac99808c9bd99ca888464dcf32d25e614161dfccfea537905f36f96b2 policycoreutils-extra-1.14.tar.bz2 15209 diff --git a/sys-apps/policycoreutils/files/digest-policycoreutils-1.30.30 b/sys-apps/policycoreutils/files/digest-policycoreutils-1.30.30 new file mode 100644 index 000000000000..0947c29f3bf9 --- /dev/null +++ b/sys-apps/policycoreutils/files/digest-policycoreutils-1.30.30 @@ -0,0 +1,6 @@ +MD5 2ab5ee943d155af7b0e4827b3053808c policycoreutils-1.30.30.tgz 243624 +RMD160 e651afa6d74369477c99baf46e60d04ba53177db policycoreutils-1.30.30.tgz 243624 +SHA256 501dbdb3be7a191864421132301408f393b73b339da977dca286976be135940a policycoreutils-1.30.30.tgz 243624 +MD5 064d17f1a9c3228fbf9450d7cc0c8776 policycoreutils-extra-1.16.tar.bz2 17022 +RMD160 a3cd953840c51a91254b57e181bd7a46368774a3 policycoreutils-extra-1.16.tar.bz2 17022 +SHA256 fd7a0d3fd2f5e8373c9865fa9df7ebf8144fdbad7d14c933668fa1a112031afc policycoreutils-extra-1.16.tar.bz2 17022 diff --git a/sys-apps/policycoreutils/files/policycoreutils-1.32-quietlp.diff b/sys-apps/policycoreutils/files/policycoreutils-1.32-quietlp.diff new file mode 100644 index 000000000000..1c932bf6cd8d --- /dev/null +++ b/sys-apps/policycoreutils/files/policycoreutils-1.32-quietlp.diff @@ -0,0 +1,16 @@ +Index: load_policy/load_policy.c +=================================================================== +--- load_policy/load_policy.c (revision 1986) ++++ load_policy/load_policy.c (working copy) +@@ -50,11 +50,6 @@ + nargs = argc - optind; + if (nargs > 2) + usage(argv[0]); +- if (nargs >= 1) { +- fprintf(stderr, +- "%s: Warning! Policy file argument (%s) is no longer supported, installed policy is always loaded. Continuing...\n", +- argv[0], argv[optind++]); +- } + if (nargs == 2) { + fprintf(stderr, + "%s: Warning! Boolean file argument (%s) is no longer supported, installed booleans file is always used. Continuing...\n", diff --git a/sys-apps/policycoreutils/policycoreutils-1.30.30.ebuild b/sys-apps/policycoreutils/policycoreutils-1.30.30.ebuild new file mode 100644 index 000000000000..1e2b63c6172e --- /dev/null +++ b/sys-apps/policycoreutils/policycoreutils-1.30.30.ebuild @@ -0,0 +1,136 @@ +# Copyright 1999-2006 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-apps/policycoreutils/policycoreutils-1.30.30.ebuild,v 1.1 2006/10/05 06:47:07 pebenito Exp $ + +IUSE="nls pam" + +inherit eutils python + +EXTRAS_VER="1.16" +SEMNG_VER="1.6.17" +#SELNX_VER="${PV}" +SELNX_VER="1.30.29" + +# BUGFIX_PATCH="${FILESDIR}/policycoreutils-1.30.6.diff" + +DESCRIPTION="SELinux core utilities" +HOMEPAGE="http://www.nsa.gov/selinux" +SRC_URI="http://www.nsa.gov/selinux/archives/${P}.tgz + mirror://gentoo/policycoreutils-extra-${EXTRAS_VER}.tar.bz2" +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=">=sys-libs/libselinux-${SELNX_VER} + >=sys-libs/glibc-2.4 + pam? ( sys-libs/pam ) + =sys-libs/libsemanage-${SEMNG_VER}*" + +DEPEND="${RDEPEND} + nls? ( sys-devel/gettext )" + +S2=${WORKDIR}/policycoreutils-extra + +throw_pam_warning() { + # this is an extremely important message that needs to be seen + # thus it being shown at the beginning and end of the ebuild + + if ! useq pam; then + eerror "PAM is disabled. This is not a supported config for" + eerror "general use. Disabling PAM decreases security with" + eerror "respect to SELinux protection of authentication." + eerror "It also requires policy changes." + ebeep 4 + epause 4 + fi +} + +pkg_setup() { + throw_pam_warning +} + +src_unpack() { + unpack ${A} + cd ${S} + + [ ! -z "${BUGFIX_PATCH}" ] && epatch "${BUGFIX_PATCH}" + + epatch ${FILESDIR}/policycoreutils-1.32-quietlp.diff + + # This warning makes no sense, in this context + sed -i -e '/FILE/ s/;/=NULL;/' ${S}/audit2why/audit2why.c \ + || die "audit2why sed failed" + + # rlpkg is more useful than fixfiles + sed -i -e '/^all/s/fixfiles//' ${S}/scripts/Makefile \ + || die "fixfiles sed 1 failed" + sed -i -e '/fixfiles/d' ${S}/scripts/Makefile \ + || die "fixfiles sed 2 failed" + + if ! useq pam; then + # disable pam + sed -i -e s/-lpam/-lcrypt/ -e s/-lpam_misc// -e s/-DUSE_PAM// \ + ${S}/run_init/Makefile || die "PAM sed 1 failed" + sed -i -e s/-lpam/-lcrypt/ -e s/-lpam_misc// -e s/-DUSE_PAM// \ + ${S}/newrole/Makefile || die "PAM sed 2 failed" + sed -i -e s/-lpam/-lcrypt/ -e s/-lpam_misc// -e s/-DUSE_PAM// \ + ${S2}/src/Makefile || die "PAM sed 3 failed" + fi + + if ! useq nls; then + # disable locale stuff + sed -i -e s/-DUSE_NLS// ${S}/run_init/Makefile \ + || die "NLS sed 1 failed" + sed -i -e s/-DUSE_NLS// ${S}/newrole/Makefile \ + || die "NLS sed 2 failed" + sed -i -e s/-DUSE_NLS// ${S}/load_policy/Makefile \ + || die "NLS sed 3 failed" + sed -i -e 's/ po //' ${S}/Makefile \ + || die "NLS sed 4 failed" + fi + + # fix up to accept Gentoo CFLAGS + local SUBDIRS="`cd ${S} && find -type d | cut -d/ -f2`" + for i in ${SUBDIRS}; do + sed -i -e "s:-Wall:-Wall ${CFLAGS}:g" ${S}/${i}/Makefile \ + || die "${i} Makefile CFLAGS fix failed." + done +} + +src_compile() { + python_version + + einfo "Compiling policycoreutils" + emake -C ${S} PYLIBVER="python${PYVER}" || die + einfo "Compiling policycoreutils-extra" + emake -C ${S2} || die +} + +src_install() { + python_version + + einfo "Installing policycoreutils" + make DESTDIR="${D}" -C ${S} PYLIBVER="python${PYVER}" install || die + einfo "Installing policycoreutils-extra" + make DESTDIR="${D}" -C ${S2} install || die + + # remove redhat-style init script + rm -fR ${D}/etc/rc.d + + # compatibility symlink + dosym /sbin/setfiles /usr/sbin/setfiles + + useq pam || rm -fR ${D}/etc/pam.d +} + +pkg_postinst() { + python_version + python_mod_optimize ${ROOT}usr/lib/python${PYVER}/site-packages + + throw_pam_warning +} + +pkg_postrm() { + python_version + python_mod_cleanup ${ROOT}usr/lib/python${PYVER}/site-packages +} |