Gentoo Archives: gentoo-commits

From: "Zac Medico (zmedico)" <zmedico@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in sys-apps/portage: portage-2.1.11.4.ebuild ChangeLog
Date: Mon, 02 Jul 2012 22:04:32
Message-Id: 20120702220421.E7C6E2004B@flycatcher.gentoo.org
1 zmedico 12/07/02 22:04:21
2
3 Modified: ChangeLog
4 Added: portage-2.1.11.4.ebuild
5 Log:
6 2.1.11.4 version bump. This fixes abug #156282 (support
7 FEATURES=unmerge-backup), bug #424275 (support FEATURES=downgrade-backup),
8 bug #424259 (don't use SIGUSR1 under Jython), and bug #424489 (fix incorrect
9 evaluation of EAPI 4-slot-abi deps that have USE conditionals).
10 Bug #423075 tracks all bugs fixed since portage-2.1.10.65.
11
12 (Portage version: 2.2.0_alpha115/cvs/Linux i686)
13
14 Revision Changes Path
15 1.1050 sys-apps/portage/ChangeLog
16
17 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/portage/ChangeLog?rev=1.1050&view=markup
18 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/portage/ChangeLog?rev=1.1050&content-type=text/plain
19 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/portage/ChangeLog?r1=1.1049&r2=1.1050
20
21 Index: ChangeLog
22 ===================================================================
23 RCS file: /var/cvsroot/gentoo-x86/sys-apps/portage/ChangeLog,v
24 retrieving revision 1.1049
25 retrieving revision 1.1050
26 diff -u -r1.1049 -r1.1050
27 --- ChangeLog 1 Jul 2012 21:26:25 -0000 1.1049
28 +++ ChangeLog 2 Jul 2012 22:04:21 -0000 1.1050
29 @@ -1,6 +1,15 @@
30 # ChangeLog for sys-apps/portage
31 # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
32 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/ChangeLog,v 1.1049 2012/07/01 21:26:25 zmedico Exp $
33 +# $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/ChangeLog,v 1.1050 2012/07/02 22:04:21 zmedico Exp $
34 +
35 +*portage-2.1.11.4 (02 Jul 2012)
36 +
37 + 02 Jul 2012; Zac Medico <zmedico@g.o> +portage-2.1.11.4.ebuild:
38 + 2.1.11.4 version bump. This fixes abug #156282 (support FEATURES=unmerge-
39 + backup), bug #424275 (support FEATURES=downgrade-backup), bug #424259 (don't
40 + use SIGUSR1 under Jython), and bug #424489 (fix incorrect evaluation of EAPI 4
41 + -slot-abi deps that have USE conditionals). Bug #423075 tracks all bugs fixed
42 + since portage-2.1.10.65.
43
44 01 Jul 2012; Zac Medico <zmedico@g.o> -portage-2.1.10.49.ebuild,
45 -portage-2.2.0_alpha89.ebuild:
46
47
48
49 1.1 sys-apps/portage/portage-2.1.11.4.ebuild
50
51 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/portage/portage-2.1.11.4.ebuild?rev=1.1&view=markup
52 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sys-apps/portage/portage-2.1.11.4.ebuild?rev=1.1&content-type=text/plain
53
54 Index: portage-2.1.11.4.ebuild
55 ===================================================================
56 # Copyright 1999-2012 Gentoo Foundation
57 # Distributed under the terms of the GNU General Public License v2
58 # $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/portage-2.1.11.4.ebuild,v 1.1 2012/07/02 22:04:21 zmedico Exp $
59
60 # Require EAPI 2 since we now require at least python-2.6 (for python 3
61 # syntax support) which also requires EAPI 2.
62 EAPI=2
63 inherit eutils multilib python
64
65 DESCRIPTION="Portage is the package management and distribution system for Gentoo"
66 HOMEPAGE="http://www.gentoo.org/proj/en/portage/index.xml"
67 LICENSE="GPL-2"
68 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd"
69 SLOT="0"
70 IUSE="build doc epydoc +ipc linguas_pl pypy1_9 python2 python3 selinux xattr"
71
72 # Import of the io module in python-2.6 raises ImportError for the
73 # thread module if threading is disabled.
74 python_dep="python3? ( =dev-lang/python-3* )
75 !pypy1_9? ( !python2? ( !python3? (
76 || ( >=dev-lang/python-2.7 dev-lang/python:2.6[threads] )
77 ) ) )
78 pypy1_9? ( !python2? ( !python3? ( dev-python/pypy:1.9[bzip2] ) ) )
79 python2? ( !python3? ( || ( dev-lang/python:2.7 dev-lang/python:2.6[threads] ) ) )"
80
81 # The pysqlite blocker is for bug #282760.
82 DEPEND="${python_dep}
83 !build? ( >=sys-apps/sed-4.0.5 )
84 doc? ( app-text/xmlto ~app-text/docbook-xml-dtd-4.4 )
85 epydoc? ( >=dev-python/epydoc-2.0 !<=dev-python/pysqlite-2.4.1 )"
86 # Require sandbox-2.2 for bug #288863.
87 # For xattr, we can spawn getfattr and setfattr from sys-apps/attr, but that's
88 # quite slow, so it's not considered in the dependencies as an alternative to
89 # to python-3.3 / pyxattr. Also, xattr support is only tested with Linux, so
90 # for now, don't pull in xattr deps for other kernels.
91 RDEPEND="${python_dep}
92 !build? ( >=sys-apps/sed-4.0.5
93 >=app-shells/bash-3.2_p17
94 >=app-admin/eselect-1.2 )
95 elibc_FreeBSD? ( sys-freebsd/freebsd-bin )
96 elibc_glibc? ( >=sys-apps/sandbox-2.2 )
97 elibc_uclibc? ( >=sys-apps/sandbox-2.2 )
98 >=app-misc/pax-utils-0.1.17
99 xattr? ( kernel_linux? ( || ( >=dev-lang/python-3.3_pre20110902 dev-python/pyxattr ) ) )
100 selinux? ( || ( >=sys-libs/libselinux-2.0.94[python] <sys-libs/libselinux-2.0.94 ) )
101 !<app-shells/bash-3.2_p17
102 !<app-admin/logrotate-3.8.0"
103 PDEPEND="
104 !build? (
105 >=net-misc/rsync-2.6.4
106 userland_GNU? ( >=sys-apps/coreutils-6.4 )
107 )"
108 # coreutils-6.4 rdep is for date format in emerge-webrsync #164532
109 # NOTE: FEATURES=install-sources requires debugedit and rsync
110
111 SRC_ARCHIVES="http://dev.gentoo.org/~zmedico/portage/archives"
112
113 prefix_src_archives() {
114 local x y
115 for x in ${@}; do
116 for y in ${SRC_ARCHIVES}; do
117 echo ${y}/${x}
118 done
119 done
120 }
121
122 PV_PL="2.1.2"
123 PATCHVER_PL=""
124 TARBALL_PV=$PV
125 SRC_URI="mirror://gentoo/${PN}-${TARBALL_PV}.tar.bz2
126 $(prefix_src_archives ${PN}-${TARBALL_PV}.tar.bz2)
127 linguas_pl? ( mirror://gentoo/${PN}-man-pl-${PV_PL}.tar.bz2
128 $(prefix_src_archives ${PN}-man-pl-${PV_PL}.tar.bz2) )"
129
130 PATCHVER=
131 [[ $TARBALL_PV = $PV ]] || PATCHVER=$PV
132 if [ -n "${PATCHVER}" ]; then
133 SRC_URI="${SRC_URI} mirror://gentoo/${PN}-${PATCHVER}.patch.bz2
134 $(prefix_src_archives ${PN}-${PATCHVER}.patch.bz2)"
135 fi
136
137 S="${WORKDIR}"/${PN}-${TARBALL_PV}
138 S_PL="${WORKDIR}"/${PN}-${PV_PL}
139
140 compatible_python_is_selected() {
141 [[ $(/usr/bin/python -c 'import sys ; sys.stdout.write(sys.hexversion >= 0x2060000 and "good" or "bad")') = good ]]
142 }
143
144 current_python_has_xattr() {
145 [[ $(/usr/bin/python -c 'import sys ; sys.stdout.write(sys.hexversion >= 0x3030000 and "yes" or "no")') = yes ]] || \
146 /usr/bin/python -c 'import xattr' 2>/dev/null
147 }
148
149 pkg_setup() {
150 # Bug #359731 - Die early if get_libdir fails.
151 [[ -z $(get_libdir) ]] && \
152 die "get_libdir returned an empty string"
153
154 if use python2 && use python3 ; then
155 ewarn "Both python2 and python3 USE flags are enabled, but only one"
156 ewarn "can be in the shebangs. Using python3."
157 fi
158 if use pypy1_9 && use python3 ; then
159 ewarn "Both pypy1_9 and python3 USE flags are enabled, but only one"
160 ewarn "can be in the shebangs. Using python3."
161 fi
162 if use pypy1_9 && use python2 ; then
163 ewarn "Both pypy1_9 and python2 USE flags are enabled, but only one"
164 ewarn "can be in the shebangs. Using python2"
165 fi
166 if ! use pypy1_9 && ! use python2 && ! use python3 && \
167 ! compatible_python_is_selected ; then
168 ewarn "Attempting to select a compatible default python interpreter"
169 local x success=0
170 for x in /usr/bin/python2.* ; do
171 x=${x#/usr/bin/python2.}
172 if [[ $x -ge 6 ]] 2>/dev/null ; then
173 eselect python set python2.$x
174 if compatible_python_is_selected ; then
175 elog "Default python interpreter is now set to python-2.$x"
176 success=1
177 break
178 fi
179 fi
180 done
181 if [ $success != 1 ] ; then
182 eerror "Unable to select a compatible default python interpreter!"
183 die "This version of portage requires at least python-2.6 to be selected as the default python interpreter (see \`eselect python --help\`)."
184 fi
185 fi
186
187 if use python3; then
188 python_set_active_version 3
189 elif use python2; then
190 python_set_active_version 2
191 elif use pypy1_9; then
192 python_set_active_version 2.7-pypy-1.9
193 fi
194 }
195
196 src_prepare() {
197 if [ -n "${PATCHVER}" ] ; then
198 if [[ -L $S/bin/ebuild-helpers/portageq ]] ; then
199 rm "$S/bin/ebuild-helpers/portageq" \
200 || die "failed to remove portageq helper symlink"
201 fi
202 epatch "${WORKDIR}/${PN}-${PATCHVER}.patch"
203 fi
204 einfo "Setting portage.VERSION to ${PVR} ..."
205 sed -e "s/^VERSION=.*/VERSION=\"${PVR}\"/" -i pym/portage/__init__.py || \
206 die "Failed to patch portage.VERSION"
207 sed -e "1s/VERSION/${PVR}/" -i doc/fragment/version || \
208 die "Failed to patch VERSION in doc/fragment/version"
209 sed -e "1s/VERSION/${PVR}/" -i man/* || \
210 die "Failed to patch VERSION in man page headers"
211
212 if ! use ipc ; then
213 einfo "Disabling ipc..."
214 sed -e "s:_enable_ipc_daemon = True:_enable_ipc_daemon = False:" \
215 -i pym/_emerge/AbstractEbuildProcess.py || \
216 die "failed to patch AbstractEbuildProcess.py"
217 fi
218
219 if use xattr && use kernel_linux ; then
220 einfo "Adding FEATURES=xattr to make.globals ..."
221 echo -e '\nFEATURES="${FEATURES} xattr"' >> cnf/make.globals \
222 || die "failed to append to make.globals"
223 fi
224
225 if use python3; then
226 einfo "Converting shebangs for python3..."
227 python_convert_shebangs -r 3 .
228 elif use python2; then
229 einfo "Converting shebangs for python2..."
230 python_convert_shebangs -r 2 .
231 elif use pypy1_9; then
232 einfo "Converting shebangs for pypy-c1.9..."
233 python_convert_shebangs -r 2.7-pypy-1.9 .
234 fi
235
236 cd "${S}/cnf" || die
237 if [ -f "make.conf.${ARCH}".diff ]; then
238 patch make.conf "make.conf.${ARCH}".diff || \
239 die "Failed to patch make.conf.example"
240 else
241 eerror ""
242 eerror "Portage does not have an arch-specific configuration for this arch."
243 eerror "Please notify the arch maintainer about this issue. Using generic."
244 eerror ""
245 fi
246
247 # BSD and OSX need a sed wrapper so that find/xargs work properly
248 if use userland_GNU; then
249 rm -f "${S}"/bin/ebuild-helpers/sed || \
250 die "Failed to remove sed wrapper"
251 fi
252 }
253
254 src_compile() {
255 if use doc; then
256 emake docbook || die
257 fi
258
259 if use epydoc; then
260 einfo "Generating api docs"
261 emake epydoc || die
262 fi
263 }
264
265 src_test() {
266 emake test || die
267 }
268
269 src_install() {
270 emake DESTDIR="${D}" \
271 sysconfdir="/etc" \
272 prefix="/usr" \
273 libdir="/usr/$(get_libdir)" \
274 install || die
275
276 # Use dodoc for compression, since the Makefile doesn't do that.
277 dodoc "${S}"/{ChangeLog,NEWS,RELEASE-NOTES} || die
278
279 if use linguas_pl; then
280 doman -i18n=pl "${S_PL}"/man/pl/*.[0-9] || die
281 doman -i18n=pl_PL.UTF-8 "${S_PL}"/man/pl_PL.UTF-8/*.[0-9] || die
282 fi
283 }
284
285 pkg_preinst() {
286 if [[ $ROOT == / ]] ; then
287 # Run some minimal tests as a sanity check.
288 local test_runner=$(find "$D" -name runTests)
289 if [[ -n $test_runner && -x $test_runner ]] ; then
290 einfo "Running preinst sanity tests..."
291 "$test_runner" || die "preinst sanity tests failed"
292 fi
293 fi
294
295 if use xattr && ! current_python_has_xattr ; then
296 ewarn "For optimal performance in xattr handling, install"
297 ewarn "dev-python/pyxattr, or install >=dev-lang/python-3.3 and"
298 ewarn "enable USE=python3 for $CATEGORY/$PN."
299 fi
300
301 if ! use build && ! has_version dev-python/pycrypto && \
302 ! has_version '>=dev-lang/python-2.6[ssl]' ; then
303 ewarn "If you are an ebuild developer and you plan to commit ebuilds"
304 ewarn "with this system then please install dev-python/pycrypto or"
305 ewarn "enable the ssl USE flag for >=dev-lang/python-2.6 in order"
306 ewarn "to enable RMD160 hash support."
307 ewarn "See bug #198398 for more information."
308 fi
309 if [[ ! -L "${ROOT}/etc/make.globals" && -f "${ROOT}/etc/make.globals" ]]; then
310 rm "${ROOT}/etc/make.globals"
311 fi
312
313 if [[ -d ${ROOT}var/log/portage && \
314 $(ls -ld "${ROOT}var/log/portage") != *" portage portage "* ]] && \
315 has_version '<sys-apps/portage-2.1.10.11' ; then
316 # Initialize permissions for bug #378451 and bug #377177, since older
317 # portage does not create /var/log/portage with the desired default
318 # permissions.
319 einfo "Applying portage group permission to ${ROOT}var/log/portage for bug #378451"
320 chown portage:portage "${ROOT}var/log/portage"
321 chmod g+ws "${ROOT}var/log/portage"
322 fi
323
324 if has_version '<sys-apps/portage-2.1.10.61' ; then
325 ewarn "FEATURES=config-protect-if-modified is now enabled by default."
326 ewarn "This causes the CONFIG_PROTECT behavior to be skipped for"
327 ewarn "files that have not been modified since they were installed."
328 fi
329 }
330
331 pkg_postinst() {
332 # Compile all source files recursively. Any orphans
333 # will be identified and removed in postrm.
334 python_mod_optimize /usr/$(get_libdir)/portage/pym
335 }
336
337 pkg_postrm() {
338 python_mod_cleanup /usr/$(get_libdir)/portage/pym
339 }