Gentoo Archives: gentoo-commits

From: "Marius Mauch (genone)" <genone@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in sys-apps/portage: ChangeLog portage-2.2_pre6.ebuild
Date: Mon, 05 May 2008 11:27:45
Message-Id: E1Jsyr8-00027R-5n@stork.gentoo.org
1 genone 08/05/05 11:27:42
2
3 Modified: ChangeLog
4 Added: portage-2.2_pre6.ebuild
5 Log:
6 New testrelease including rewritten preserve-libs support
7 (Portage version: 2.2_pre6)
8
9 Revision Changes Path
10 1.511 sys-apps/portage/ChangeLog
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-apps/portage/ChangeLog?rev=1.511&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-apps/portage/ChangeLog?rev=1.511&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-apps/portage/ChangeLog?r1=1.510&r2=1.511
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/sys-apps/portage/ChangeLog,v
19 retrieving revision 1.510
20 retrieving revision 1.511
21 diff -u -r1.510 -r1.511
22 --- ChangeLog 21 Apr 2008 21:11:21 -0000 1.510
23 +++ ChangeLog 5 May 2008 11:27:41 -0000 1.511
24 @@ -1,6 +1,12 @@
25 # ChangeLog for sys-apps/portage
26 # Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/ChangeLog,v 1.510 2008/04/21 21:11:21 zmedico Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/ChangeLog,v 1.511 2008/05/05 11:27:41 genone Exp $
29 +
30 +*portage-2.2_pre6 (05 May 2008)
31 +
32 + 05 May 2008; Marius Mauch <genone@g.o> +portage-2.2_pre6.ebuild:
33 + New testrelease including rewritten support for FEATURES=preserve-libs and
34 + several updates regarding package set handling
35
36 *portage-2.1.5_rc6 (21 Apr 2008)
37
38
39
40
41 1.1 sys-apps/portage/portage-2.2_pre6.ebuild
42
43 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-apps/portage/portage-2.2_pre6.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/sys-apps/portage/portage-2.2_pre6.ebuild?rev=1.1&content-type=text/plain
45
46 Index: portage-2.2_pre6.ebuild
47 ===================================================================
48 # Copyright 1999-2008 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/sys-apps/portage/portage-2.2_pre6.ebuild,v 1.1 2008/05/05 11:27:41 genone Exp $
51
52 inherit toolchain-funcs eutils flag-o-matic multilib python
53
54 DESCRIPTION="Portage is the package management and distribution system for Gentoo"
55 HOMEPAGE="http://www.gentoo.org/proj/en/portage/index.xml"
56 LICENSE="GPL-2"
57 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~sparc-fbsd ~x86 ~x86-fbsd"
58 PROVIDE="virtual/portage"
59 SLOT="0"
60 IUSE="build doc epydoc selinux linguas_pl"
61 DEPEND=">=dev-lang/python-2.4
62 !build? ( >=sys-apps/sed-4.0.5 )
63 doc? ( app-text/xmlto ~app-text/docbook-xml-dtd-4.4 )
64 epydoc? ( =dev-python/epydoc-2* )"
65 RDEPEND=">=dev-lang/python-2.4
66 !build? ( >=sys-apps/sed-4.0.5
67 >=app-shells/bash-3.2_p17
68 >=app-admin/eselect-news-20071201 )
69 elibc_FreeBSD? ( sys-freebsd/freebsd-bin )
70 elibc_glibc? ( >=sys-apps/sandbox-1.2.17 !mips? ( >=sys-apps/sandbox-1.2.18.1-r2 ) )
71 elibc_uclibc? ( >=sys-apps/sandbox-1.2.17 !mips? ( >=sys-apps/sandbox-1.2.18.1-r2 ) )
72 >=app-misc/pax-utils-0.1.13
73 selinux? ( >=dev-python/python-selinux-2.16 )"
74 PDEPEND="
75 !build? (
76 >=net-misc/rsync-2.6.4
77 userland_GNU? ( >=sys-apps/coreutils-6.4 )
78 || ( >=dev-lang/python-2.5 >=dev-python/pycrypto-2.0.1-r6 )
79 )"
80 # coreutils-6.4 rdep is for date format in emerge-webrsync #164532
81 # rsync-2.6.4 rdep is for the --filter option #167668
82
83 SRC_ARCHIVES="http://dev.gentoo.org/~zmedico/portage/archives http://dev.gentoo.org/~genone/distfiles"
84
85 prefix_src_archives() {
86 local x y
87 for x in ${@}; do
88 for y in ${SRC_ARCHIVES}; do
89 echo ${y}/${x}
90 done
91 done
92 }
93
94 PV_PL="2.1.2"
95 PATCHVER_PL=""
96 SRC_URI="mirror://gentoo/${P}.tar.bz2
97 $(prefix_src_archives ${P}.tar.bz2)
98 linguas_pl? ( mirror://gentoo/${PN}-man-pl-${PV_PL}.tar.bz2
99 $(prefix_src_archives ${PN}-man-pl-${PV_PL}.tar.bz2) )"
100
101 PATCHVER=""
102 if [ -n "${PATCHVER}" ]; then
103 SRC_URI="${SRC_URI} mirror://gentoo/${PN}-${PATCHVER}.patch.bz2
104 $(prefix_src_archives ${PN}-${PATCHVER}.patch.bz2)"
105 fi
106
107 S="${WORKDIR}"/${P}
108 S_PL="${WORKDIR}"/${PN}-${PV_PL}
109
110 pkg_setup() {
111 MINOR_UPGRADE=$(has_version '>=sys-apps/portage-2.2_alpha' && echo true)
112 MIGRATION_UPGRADE=$(has_version '<=sys-apps/portage-2.2_pre5' && echo true)
113 }
114
115 src_unpack() {
116 unpack ${A}
117 cd "${S}"
118 if [ -n "${PATCHVER}" ]; then
119 cd "${S}"
120 epatch "${WORKDIR}/${PN}-${PATCHVER}.patch"
121 fi
122 einfo "Setting portage.VERSION to ${PVR} ..."
123 sed -i "s/^VERSION=.*/VERSION=\"${PVR}\"/" pym/portage/__init__.py || \
124 die "Failed to patch portage.VERSION"
125 }
126
127 src_compile() {
128 append-lfs-flags
129
130 cd "${S}"/src
131 $(tc-getCC) ${CFLAGS} ${LDFLAGS} -o tbz2tool tbz2tool.c || \
132 die "Failed to build tbz2tool"
133
134 if use doc; then
135 cd "${S}"/doc
136 touch fragment/date
137 make xhtml xhtml-nochunks || die "failed to make docs"
138 fi
139
140 if use epydoc; then
141 einfo "Generating api docs"
142 mkdir "${WORKDIR}"/api
143 local my_modules
144 my_modules="$(find "${S}/pym" -name "*.py" \
145 | sed -e 's:/__init__.py$::' -e 's:\.py$::' -e "s:^${S}/pym/::" \
146 -e 's:/:.:g' | sort)" || die "error listing modules"
147 PYTHONPATH="${S}/pym:${PYTHONPATH}" epydoc -o "${WORKDIR}"/api \
148 -qqqqq --no-frames --show-imports \
149 --name "${PN}" --url "${HOMEPAGE}" \
150 ${my_modules} || die "epydoc failed"
151 fi
152 }
153
154 src_test() {
155 ./pym/portage/tests/runTests || \
156 die "test(s) failed"
157 }
158
159 src_install() {
160 local libdir=$(get_libdir)
161 local portage_base="/usr/${libdir}/portage"
162 local portage_share_config=/usr/share/portage/config
163
164 cd "${S}"/cnf
165 insinto /etc
166 doins etc-update.conf dispatch-conf.conf
167
168 dodir "${portage_share_config}"
169 insinto "${portage_share_config}"
170 doins "${S}/cnf/"{sets.conf,make.globals}
171 if [ -f "make.conf.${ARCH}".diff ]; then
172 patch make.conf "make.conf.${ARCH}".diff || \
173 die "Failed to patch make.conf.example"
174 newins make.conf make.conf.example
175 else
176 eerror ""
177 eerror "Portage does not have an arch-specific configuration for this arch."
178 eerror "Please notify the arch maintainer about this issue. Using generic."
179 eerror ""
180 newins make.conf make.conf.example
181 fi
182
183 dosym ..${portage_share_config}/make.globals /etc/make.globals
184
185 insinto /etc/logrotate.d
186 doins "${S}"/cnf/logrotate.d/elog-save-summary
187
188 dodir ${portage_base}/bin
189 exeinto ${portage_base}/bin
190
191 # BSD and OSX need a sed wrapper so that find/xargs work properly
192 if use userland_GNU; then
193 rm "${S}"/bin/sed || die "Failed to remove sed wrapper"
194 fi
195
196 cd "${S}"/bin
197 doexe *
198 doexe "${S}"/src/tbz2tool
199 dosym newins ${portage_base}/bin/donewins
200
201 local symlinks
202 for mydir in $(find "${S}"/pym -type d | sed -e "s:^${S}/::") ; do
203 dodir ${portage_base}/${mydir}
204 insinto ${portage_base}/${mydir}
205 cd "${S}"/${mydir}
206 doins *.py
207 symlinks=$(find -mindepth 1 -maxdepth 1 -type l)
208 [ -n "${symlinks}" ] && cp -P ${symlinks} "${D}${portage_base}/${mydir}"
209 done
210
211 # Symlinks to directories cause up/downgrade issues and the use of these
212 # modules outside of portage is probably negligible.
213 for x in "${D}${portage_base}/pym/"{cache,elog_modules} ; do
214 [ ! -L "${x}" ] && continue
215 die "symlink to directory will cause upgrade/downgrade issues: '${x}'"
216 done
217
218 exeinto ${portage_base}/pym/portage/tests
219 doexe "${S}"/pym/portage/tests/runTests
220
221 doman "${S}"/man/*.[0-9]
222 if use linguas_pl; then
223 doman -i18n=pl "${S_PL}"/man/pl/*.[0-9]
224 doman -i18n=pl_PL.UTF-8 "${S_PL}"/man/pl_PL.UTF-8/*.[0-9]
225 fi
226
227 dodoc "${S}"/{ChangeLog,NEWS,RELEASE-NOTES}
228 use doc && dohtml -r "${S}"/doc/*
229 use epydoc && dohtml -r "${WORKDIR}"/api
230
231 dodir /usr/bin
232 for x in ebuild emerge portageq repoman tbz2tool xpak; do
233 dosym ../${libdir}/portage/bin/${x} /usr/bin/${x}
234 done
235
236 dodir /usr/sbin
237 local my_syms="archive-conf
238 dispatch-conf
239 emaint
240 emerge-webrsync
241 env-update
242 etc-update
243 fixpackages
244 quickpkg
245 regenworld"
246 local x
247 for x in ${my_syms}; do
248 dosym ../${libdir}/portage/bin/${x} /usr/sbin/${x}
249 done
250 dosym env-update /usr/sbin/update-env
251 dosym etc-update /usr/sbin/update-etc
252
253 dodir /etc/portage
254 keepdir /etc/portage
255 }
256
257 pkg_preinst() {
258 if ! use build && ! has_version dev-python/pycrypto && \
259 has_version '>=dev-lang/python-2.5' ; then
260 if ! built_with_use '>=dev-lang/python-2.5' ssl ; then
261 ewarn "If you are an ebuild developer and you plan to commit ebuilds"
262 ewarn "with this system then please install dev-python/pycrypto or"
263 ewarn "enable the ssl USE flag for >=dev-lang/python-2.5 in order"
264 ewarn "to enable RMD160 hash support."
265 ewarn "See bug #198398 for more information."
266 fi
267 fi
268 if [ -f "${ROOT}/etc/make.globals" ]; then
269 rm "${ROOT}/etc/make.globals"
270 fi
271 }
272
273 pkg_postinst() {
274 # Compile all source files recursively. Any orphans
275 # will be identified and removed in postrm.
276 python_mod_optimize "${ROOT}usr/$(get_libdir)/portage/pym"
277
278 if [ -n "${MIGRATION_UPGRADE}" ]; then
279 einfo "moving set references from the worldfile into world_sets"
280 cd "${ROOT}/var/lib/portage/"
281 grep "^@" world >> world_sets
282 sed -i -e '/^@/d' world
283
284 einfo "converting NEEDED files to new syntax"
285 cd "${ROOT}/var/db/pkg"
286 for cpv in */*; do
287 if [ -f "${cpv}/NEEDED" -a ! -f "${cpv}/NEEDED.ELF.2" ]; then
288 while read line; do
289 filename=${line% *}
290 needed=${line#* }
291 newline=$(scanelf -BF "%a;%F;%S;$needed;%r" $filename)
292 echo "${newline:3}" >> "${cpv}/NEEDED.ELF.2"
293 done < "${cpv}/NEEDED"
294 fi
295 done
296 fi
297
298 elog
299 elog "For help with using portage please consult the Gentoo Handbook"
300 elog "at http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=3"
301 elog
302
303 if [ -z "${MINOR_UPGRADE}" ]; then
304 elog "If you're upgrading from a pre-2.2 version of portage you might"
305 elog "want to remerge world (emerge -e world) to take full advantage"
306 elog "of some of the new features in 2.2."
307 elog "This is not required however for portage to function properly."
308 elog
309 fi
310
311 if [ -z "${PV/*_pre*}" ]; then
312 elog "If you always want to use the latest development version of portage"
313 elog "please read http://www.gentoo.org/proj/en/portage/doc/testing.xml"
314 elog
315 fi
316 }
317
318 pkg_postrm() {
319 python_mod_cleanup "${ROOT}usr/$(get_libdir)/portage/pym"
320 }
321
322
323
324 --
325 gentoo-commits@l.g.o mailing list