Gentoo Archives: gentoo-commits

From: "Sven Vermeulen (swift)" <swift@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in sys-libs/libsemanage: libsemanage-2.1.6.ebuild ChangeLog
Date: Sat, 31 Mar 2012 11:03:25
Message-Id: 20120331110300.C25632004B@flycatcher.gentoo.org
1 swift 12/03/31 11:03:00
2
3 Modified: ChangeLog
4 Added: libsemanage-2.1.6.ebuild
5 Log:
6 Updating SELinux userspace utilities to support pending 2.20120215 policies
7
8 (Portage version: 2.1.10.49/cvs/Linux x86_64)
9
10 Revision Changes Path
11 1.45 sys-libs/libsemanage/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-libs/libsemanage/ChangeLog?rev=1.45&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-libs/libsemanage/ChangeLog?rev=1.45&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-libs/libsemanage/ChangeLog?r1=1.44&r2=1.45
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/sys-libs/libsemanage/ChangeLog,v
20 retrieving revision 1.44
21 retrieving revision 1.45
22 diff -u -r1.44 -r1.45
23 --- ChangeLog 12 Nov 2011 16:58:49 -0000 1.44
24 +++ ChangeLog 31 Mar 2012 11:03:00 -0000 1.45
25 @@ -1,6 +1,11 @@
26 # ChangeLog for sys-libs/libsemanage
27 -# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/sys-libs/libsemanage/ChangeLog,v 1.44 2011/11/12 16:58:49 swift Exp $
29 +# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
30 +# $Header: /var/cvsroot/gentoo-x86/sys-libs/libsemanage/ChangeLog,v 1.45 2012/03/31 11:03:00 swift Exp $
31 +
32 +*libsemanage-2.1.6 (31 Mar 2012)
33 +
34 + 31 Mar 2012; <swift@g.o> +libsemanage-2.1.6.ebuild:
35 + Bump to version 2.1.6
36
37 12 Nov 2011; <swift@g.o> -libsemanage-2.0.45.ebuild,
38 -libsemanage-2.0.46.ebuild:
39
40
41
42 1.1 sys-libs/libsemanage/libsemanage-2.1.6.ebuild
43
44 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-libs/libsemanage/libsemanage-2.1.6.ebuild?rev=1.1&view=markup
45 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-libs/libsemanage/libsemanage-2.1.6.ebuild?rev=1.1&content-type=text/plain
46
47 Index: libsemanage-2.1.6.ebuild
48 ===================================================================
49 # Copyright 1999-2012 Gentoo Foundation
50 # Distributed under the terms of the GNU General Public License v2
51 # $Header: /var/cvsroot/gentoo-x86/sys-libs/libsemanage/libsemanage-2.1.6.ebuild,v 1.1 2012/03/31 11:03:00 swift Exp $
52
53 EAPI="3"
54 # Support for 4 depends on python.eclass
55 PYTHON_DEPEND="python? *"
56 SUPPORT_PYTHON_ABIS="1"
57 RESTRICT_PYTHON_ABIS="*-jython"
58
59 inherit multilib python toolchain-funcs eutils
60
61 SEPOL_VER="2.1.4"
62 SELNX_VER="2.1.9"
63
64 DESCRIPTION="SELinux kernel and policy management library"
65 HOMEPAGE="http://userspace.selinuxproject.org"
66 SRC_URI="http://userspace.selinuxproject.org/releases/20120216/${P}.tar.gz
67 http://dev.gentoo.org/~swift/patches/libsemanage/libsemanage-2.1.6-nolevel.patch.gz"
68
69 LICENSE="GPL-2"
70 SLOT="0"
71 KEYWORDS="~amd64 ~x86"
72 IUSE="python ruby"
73
74 RDEPEND=">=sys-libs/libsepol-${SEPOL_VER}
75 >=sys-libs/libselinux-${SELNX_VER}
76 dev-libs/ustr
77 ruby? ( dev-lang/ruby )"
78 DEPEND="${RDEPEND}
79 sys-devel/bison
80 sys-devel/flex
81 ruby? ( dev-lang/swig )
82 python? ( dev-lang/swig )"
83
84 # tests are not meant to be run outside of the
85 # full SELinux userland repo
86 RESTRICT="test"
87
88 pkg_setup() {
89 if use python; then
90 python_pkg_setup
91 fi
92 }
93
94 src_prepare() {
95 echo "# Set this to true to save the linked policy." >> "${S}/src/semanage.conf"
96 echo "# This is normally only useful for analysis" >> "${S}/src/semanage.conf"
97 echo "# or debugging of policy." >> "${S}/src/semanage.conf"
98 echo "save-linked=false" >> "${S}/src/semanage.conf"
99 echo >> "${S}/src/semanage.conf"
100 echo "# Set this to 0 to disable assertion checking." >> "${S}/src/semanage.conf"
101 echo "# This should speed up building the kernel policy" >> "${S}/src/semanage.conf"
102 echo "# from policy modules, but may leave you open to" >> "${S}/src/semanage.conf"
103 echo "# dangerous rules which assertion checking" >> "${S}/src/semanage.conf"
104 echo "# would catch." >> "${S}/src/semanage.conf"
105 echo "expand-check=1" >> "${S}/src/semanage.conf"
106 echo >> "${S}/src/semanage.conf"
107 echo "# Modules in the module store can be compressed" >> "${S}/src/semanage.conf"
108 echo "# with bzip2. Set this to the bzip2 blocksize" >> "${S}/src/semanage.conf"
109 echo "# 1-9 when compressing. The higher the number," >> "${S}/src/semanage.conf"
110 echo "# the more memory is traded off for disk space." >> "${S}/src/semanage.conf"
111 echo "# Set to 0 to disable bzip2 compression." >> "${S}/src/semanage.conf"
112 echo "bzip-blocksize=0" >> "${S}/src/semanage.conf"
113 echo >> "${S}/src/semanage.conf"
114 echo "# Reduce memory usage for bzip2 compression and" >> "${S}/src/semanage.conf"
115 echo "# decompression of modules in the module store." >> "${S}/src/semanage.conf"
116 echo "bzip-small=true" >> "${S}/src/semanage.conf"
117
118 # Apply patch to support non-leveled types (like strict or targeted)
119 epatch "${DISTDIR}/libsemanage-2.1.6-nolevel.patch.gz"
120 }
121
122 src_compile() {
123 emake AR="$(tc-getAR)" CC="$(tc-getCC)" all || die
124
125 if use python; then
126 python_copy_sources src
127 building() {
128 emake CC="$(tc-getCC)" PYLIBVER="python$(python_get_version)" PYPREFIX="python-$(python_get_version)" "$@"
129 }
130 python_execute_function -s --source-dir src building -- swigify
131 python_execute_function -s --source-dir src building -- pywrap
132 fi
133
134 if use ruby; then
135 emake -C src CC="$(tc-getCC)" rubywrap || die
136 fi
137 }
138
139 src_install() {
140 emake \
141 DESTDIR="${D}" \
142 LIBDIR="${D}usr/$(get_libdir)" \
143 SHLIBDIR="${D}$(get_libdir)" \
144 install || die
145 dosym "../../$(get_libdir)/libsemanage.so.1" "/usr/$(get_libdir)/libsemanage.so" || die
146
147 if use python; then
148 installation() {
149 emake \
150 DESTDIR="${D}" \
151 PYLIBVER="python$(python_get_version)" \
152 PYPREFIX="python-$(python_get_version)" \
153 LIBDIR="${D}usr/$(get_libdir)" \
154 install-pywrap
155 }
156 python_execute_function -s --source-dir src installation
157 fi
158
159 if use ruby; then
160 emake -C src \
161 DESTDIR="${D}" \
162 LIBDIR="${D}usr/$(get_libdir)" \
163 install-rubywrap || die
164 fi
165 }
166
167 pkg_postinst() {
168 if use python; then
169 python_mod_optimize semanage.py
170 fi
171 }
172
173 pkg_postrm() {
174 if use python; then
175 python_mod_cleanup semanage.py
176 fi
177 }