Gentoo Archives: gentoo-commits

From: "Arfrever Frehtes Taifersar Arahesis (arfrever)" <arfrever@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-util/subversion: metadata.xml ChangeLog subversion-1.5.6.ebuild
Date: Sat, 21 Mar 2009 00:45:34
Message-Id: E1LkpL9-0006yX-UC@stork.gentoo.org
1 arfrever 09/03/21 00:45:31
2
3 Modified: metadata.xml ChangeLog
4 Added: subversion-1.5.6.ebuild
5 Log:
6 Version bump (bug #260636).
7 (Portage version: 13139-svn/cvs/Linux x86_64)
8
9 Revision Changes Path
10 1.8 dev-util/subversion/metadata.xml
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/subversion/metadata.xml?rev=1.8&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/subversion/metadata.xml?rev=1.8&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/subversion/metadata.xml?r1=1.7&r2=1.8
15
16 Index: metadata.xml
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/dev-util/subversion/metadata.xml,v
19 retrieving revision 1.7
20 retrieving revision 1.8
21 diff -u -r1.7 -r1.8
22 --- metadata.xml 23 Aug 2008 05:52:45 -0000 1.7
23 +++ metadata.xml 21 Mar 2009 00:45:31 -0000 1.8
24 @@ -2,15 +2,15 @@
25 <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
26 <pkgmetadata>
27 <maintainer>
28 + <email>Arfrever@g.o</email>
29 + <name>Arfrever Frehtes Taifersar Arahesis</name>
30 + <description>Gentoo Subversion maintainer and Subversion upstream representative</description>
31 + </maintainer>
32 + <maintainer>
33 <email>hollow@g.o</email>
34 <name>Benedikt Böhm</name>
35 <description>Gentoo Subversion maintainer</description>
36 </maintainer>
37 - <maintainer>
38 - <email>Arfrever.FTA@×××××.Com</email>
39 - <name>Arfrever Frehtes Taifersar Arahesis</name>
40 - <description>Subversion upstream representative</description>
41 - </maintainer>
42 <use>
43 <flag name="dso">Enable runtime module search</flag>
44 <flag name="extras">Install extras scripts (examples, tools, hooks)</flag>
45
46
47
48 1.351 dev-util/subversion/ChangeLog
49
50 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/subversion/ChangeLog?rev=1.351&view=markup
51 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/subversion/ChangeLog?rev=1.351&content-type=text/plain
52 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/subversion/ChangeLog?r1=1.350&r2=1.351
53
54 Index: ChangeLog
55 ===================================================================
56 RCS file: /var/cvsroot/gentoo-x86/dev-util/subversion/ChangeLog,v
57 retrieving revision 1.350
58 retrieving revision 1.351
59 diff -u -r1.350 -r1.351
60 --- ChangeLog 6 Mar 2009 01:47:09 -0000 1.350
61 +++ ChangeLog 21 Mar 2009 00:45:31 -0000 1.351
62 @@ -1,6 +1,12 @@
63 # ChangeLog for dev-util/subversion
64 # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
65 -# $Header: /var/cvsroot/gentoo-x86/dev-util/subversion/ChangeLog,v 1.350 2009/03/06 01:47:09 jer Exp $
66 +# $Header: /var/cvsroot/gentoo-x86/dev-util/subversion/ChangeLog,v 1.351 2009/03/21 00:45:31 arfrever Exp $
67 +
68 +*subversion-1.5.6 (21 Mar 2009)
69 +
70 + 21 Mar 2009; Arfrever Frehtes Taifersar Arahesis <Arfrever@g.o>
71 + +subversion-1.5.6.ebuild:
72 + Version bump (bug #260636).
73
74 06 Mar 2009; Jeroen Roovers <jer@g.o> subversion-1.5.5.ebuild:
75 Stable for HPPA (bug #259046).
76
77
78
79 1.1 dev-util/subversion/subversion-1.5.6.ebuild
80
81 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/subversion/subversion-1.5.6.ebuild?rev=1.1&view=markup
82 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-util/subversion/subversion-1.5.6.ebuild?rev=1.1&content-type=text/plain
83
84 Index: subversion-1.5.6.ebuild
85 ===================================================================
86 # Copyright 1999-2009 Gentoo Foundation
87 # Distributed under the terms of the GNU General Public License v2
88 # $Header: /var/cvsroot/gentoo-x86/dev-util/subversion/subversion-1.5.6.ebuild,v 1.1 2009/03/21 00:45:31 arfrever Exp $
89
90 EAPI="1"
91 WANT_AUTOMAKE="none"
92
93 inherit autotools bash-completion confutils depend.apache elisp-common eutils flag-o-matic java-pkg-opt-2 libtool multilib perl-module python
94
95 DESCRIPTION="Advanced version control system"
96 HOMEPAGE="http://subversion.tigris.org/"
97 SRC_URI="http://subversion.tigris.org/downloads/${P/_/-}.tar.bz2"
98
99 LICENSE="Subversion"
100 SLOT="0"
101 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~sparc-fbsd ~x86 ~x86-fbsd"
102 IUSE="apache2 berkdb debug doc +dso emacs extras java nls perl python ruby sasl vim-syntax +webdav-neon webdav-serf"
103 RESTRICT="test"
104
105 CDEPEND=">=dev-libs/apr-1.2.8
106 >=dev-libs/apr-util-1.2.8
107 dev-libs/expat
108 sys-libs/zlib
109 berkdb? ( =sys-libs/db-4* )
110 emacs? ( virtual/emacs )
111 ruby? ( >=dev-lang/ruby-1.8.2 )
112 sasl? ( dev-libs/cyrus-sasl )
113 webdav-neon? ( >=net-misc/neon-0.28 )
114 webdav-serf? ( net-libs/serf )"
115
116 RDEPEND="${CDEPEND}
117 java? ( >=virtual/jre-1.5 )
118 nls? ( virtual/libintl )
119 perl? ( dev-perl/URI )"
120
121 DEPEND="${CDEPEND}
122 doc? ( app-doc/doxygen )
123 java? ( >=virtual/jdk-1.5 )
124 nls? ( sys-devel/gettext )"
125
126 want_apache
127
128 S="${WORKDIR}"/${P/_/-}
129
130 # Allow for custom repository locations.
131 # This can't be in pkg_setup because the variable needs to be available to
132 # pkg_config.
133 : ${SVN_REPOS_LOC:=/var/svn}
134
135 pkg_setup() {
136 confutils_use_depend_built_with_all berkdb dev-libs/apr-util berkdb
137 java-pkg-opt-2_pkg_setup
138
139 if ! use webdav-neon && ! use webdav-serf; then
140 ewarn
141 ewarn "WebDAV support is disabled. You need WebDAV to"
142 ewarn "access repositories through the HTTP protocol."
143 ewarn
144 ewarn "WebDAV support needs one of the following USE flags enabled:"
145 ewarn " webdav-neon webdav-serf"
146 ewarn
147 ewarn "You can do this by enabling one of these flags in /etc/portage/package.use:"
148 ewarn " =${CATEGORY}/${PF} webdav-neon webdav-serf"
149 ewarn
150 ebeep
151 fi
152 }
153
154 src_unpack() {
155 unpack ${A}
156 cd "${S}"
157
158 epatch "${FILESDIR}"/1.5.0/disable-unneeded-linking.patch
159
160 sed -i \
161 -e "s/\(BUILD_RULES=.*\) bdb-test\(.*\)/\1\2/g" \
162 -e "s/\(BUILD_RULES=.*\) test\(.*\)/\1\2/g" configure.ac
163
164 sed -e 's:@bindir@/svn-contrib:@libdir@/subversion/bin:' \
165 -e 's:@bindir@/svn-tools:@libdir@/subversion/bin:' \
166 -i Makefile.in
167
168 eautoconf
169 elibtoolize
170 }
171
172 src_compile() {
173 local myconf
174
175 if use python || use perl || use ruby; then
176 myconf="${myconf} --with-swig"
177 else
178 myconf="${myconf} --without-swig"
179 fi
180
181 if use debug; then
182 append-cppflags -DSVN_DEBUG -DAP_DEBUG
183 fi
184
185 append-flags -fno-strict-aliasing
186
187 econf ${myconf} \
188 $(use_with apache2 apxs "${APXS}") \
189 $(use_with berkdb berkeley-db) \
190 $(use_enable dso runtime-module-search) \
191 $(use_enable java javahl) \
192 $(use_with java jdk "${JAVA_HOME}") \
193 $(use_enable nls) \
194 $(use_with sasl) \
195 $(use_with webdav-neon neon /usr) \
196 $(use_with webdav-serf serf /usr) \
197 --with-apr=/usr/bin/apr-1-config \
198 --with-apr-util=/usr/bin/apu-1-config \
199 --disable-experimental-libtool \
200 --without-jikes \
201 --without-junit \
202 --disable-mod-activation \
203 --disable-neon-version-check
204
205 emake local-all || die "Building of core Subversion failed"
206
207 if use python; then
208 emake swig-py || die "Building of Subversion Python bindings failed"
209 fi
210
211 if use perl; then
212 emake -j1 swig-pl || die "Building of Subversion Perl bindings failed"
213 fi
214
215 if use ruby; then
216 emake swig-rb || die "Building of Subversion Ruby bindings failed"
217 fi
218
219 if use java; then
220 make JAVAC_FLAGS="$(java-pkg_javac-args) -encoding iso8859-1" javahl \
221 || die "Building of Subversion JavaHL library failed"
222 fi
223
224 if use emacs; then
225 elisp-compile contrib/client-side/emacs/{dsvn,psvn,vc-svn}.el \
226 doc/svn-doc.el doc/tools/svnbook.el \
227 || die "Compilation of Emacs modules failed"
228 fi
229
230 if use extras; then
231 emake contrib || die "Building of contrib failed"
232 emake tools || die "Building of tools failed"
233 fi
234
235 if use doc; then
236 doxygen doc/doxygen.conf || die "Building of Subversion HTML documentation failed"
237
238 if use java; then
239 emake doc-javahl || die "Building of Subversion JavaHL library HTML documentation failed"
240 fi
241 fi
242 }
243
244 src_install() {
245 python_version
246 PYTHON_DIR=/usr/$(get_libdir)/python${PYVER}
247
248 emake -j1 DESTDIR="${D}" local-install || die "Installation of core of Subversion failed"
249
250 if use python; then
251 emake -j1 DESTDIR="${D}" DISTUTIL_PARAM="--prefix=${D}" LD_LIBRARY_PATH="-L${D}/usr/$(get_libdir)" install-swig-py \
252 || die "Installation of Subversion Python bindings failed"
253
254 # Move Python bindings.
255 dodir "${PYTHON_DIR}/site-packages"
256 mv "${D}"/usr/$(get_libdir)/svn-python/svn "${D}${PYTHON_DIR}/site-packages"
257 mv "${D}"/usr/$(get_libdir)/svn-python/libsvn "${D}${PYTHON_DIR}/site-packages"
258 rm -Rf "${D}"/usr/$(get_libdir)/svn-python
259 fi
260
261 if use perl; then
262 emake -j1 DESTDIR="${D}" INSTALLDIRS="vendor" install-swig-pl || die "Installation of Subversion Perl bindings failed"
263 fixlocalpod
264 fi
265
266 if use ruby; then
267 emake -j1 DESTDIR="${D}" install-swig-rb || die "Installation of Subversion Ruby bindings failed"
268 fi
269
270 if use java; then
271 emake -j1 DESTDIR="${D}" install-javahl || die "Installation of Subversion JavaHL library failed"
272 java-pkg_regso "${D}"/usr/$(get_libdir)/libsvnjavahl*.so
273 java-pkg_dojar "${D}"/usr/$(get_libdir)/svn-javahl/svn-javahl.jar
274 rm -Rf "${D}"/usr/$(get_libdir)/svn-javahl/*.jar
275 fi
276
277 # Install Apache module configuration.
278 if use apache2; then
279 dodir "${APACHE_MODULES_CONFDIR}"
280 cat <<EOF >"${D}/${APACHE_MODULES_CONFDIR}"/47_mod_dav_svn.conf
281 <IfDefine SVN>
282 LoadModule dav_svn_module modules/mod_dav_svn.so
283 <IfDefine SVN_AUTHZ>
284 LoadModule authz_svn_module modules/mod_authz_svn.so
285 </IfDefine>
286
287 # Example configuration:
288 #<Location /svn/repos>
289 # DAV svn
290 # SVNPath ${SVN_REPOS_LOC}/repos
291 # AuthType Basic
292 # AuthName "Subversion repository"
293 # AuthUserFile ${SVN_REPOS_LOC}/conf/svnusers
294 # Require valid-user
295 #</Location>
296 </IfDefine>
297 EOF
298 fi
299
300 # Install Bash Completion, bug 43179.
301 dobashcompletion tools/client-side/bash_completion subversion
302 rm -f tools/client-side/bash_completion
303
304 # Install hot backup script, bug 54304.
305 newbin tools/backup/hot-backup.py svn-hot-backup
306 rm -fr tools/backup
307
308 # Install svn_load_dirs.pl.
309 if use perl; then
310 newbin contrib/client-side/svn_load_dirs/svn_load_dirs.pl svn-load-dirs
311 fi
312 rm -f contrib/client-side/svn_load_dirs/svn_load_dirs.pl
313
314 # Install svnserve init-script and xinet.d snippet, bug 43245.
315 newinitd "${FILESDIR}"/svnserve.initd svnserve
316 if use apache2; then
317 newconfd "${FILESDIR}"/svnserve.confd svnserve
318 else
319 newconfd "${FILESDIR}"/svnserve.confd2 svnserve
320 fi
321 insinto /etc/xinetd.d
322 newins "${FILESDIR}"/svnserve.xinetd svnserve
323
324 # Install documentation.
325 dodoc CHANGES COMMITTERS README
326 dohtml www/hacking.html
327 dodoc tools/xslt/svnindex.{css,xsl}
328 rm -fr tools/xslt
329
330 # Install Vim syntax files.
331 if use vim-syntax; then
332 insinto /usr/share/vim/vimfiles/syntax
333 doins contrib/client-side/vim/svn.vim
334 fi
335 rm -f contrib/client-side/vim/svn.vim
336
337 # Install Emacs Lisps.
338 if use emacs; then
339 elisp-install ${PN} contrib/client-side/emacs/{dsvn,psvn}.{el,elc} \
340 doc/svn-doc.{el,elc} doc/tools/svnbook.{el,elc} \
341 || die "Installation of Emacs modules failed"
342 elisp-install ${PN}/compat contrib/client-side/emacs/vc-svn.{el,elc} \
343 || die "Installation of Emacs modules failed"
344 touch "${D}${SITELISP}/${PN}/compat/.nosearch"
345 elisp-site-file-install "${FILESDIR}"/1.5.0/70svn-gentoo.el \
346 || die "Installation of Emacs site-init file failed"
347 fi
348 rm -fr contrib/client-side/emacs
349
350 # Install extra files.
351 if use extras; then
352 doenvd "${FILESDIR}"/1.5.0/80subversion-extras
353
354 emake DESTDIR="${D}" install-contrib || die "Installation of contrib failed"
355 emake DESTDIR="${D}" install-tools || die "Installation of tools failed"
356
357 find contrib tools '(' -name "*.bat" -o -name "*.in" -o -name ".libs" ')' -print0 | xargs -0 rm -fr
358 rm -fr contrib/client-side/{svn-push,svnmucc}
359 rm -fr tools/server-side/{svn-populate-node-origins-index,svnauthz-validate}*
360 rm -fr tools/{buildbot,dev,diff,po}
361
362 insinto /usr/share/${PN}
363 doins -r contrib tools
364 fi
365
366 if use doc; then
367 dohtml doc/doxygen/html/*
368
369 insinto /usr/share/doc/${PF}
370 doins -r notes
371 ecompressdir /usr/share/doc/${PF}/notes
372
373 if use java; then
374 java-pkg_dojavadoc doc/javadoc
375 fi
376 fi
377 }
378
379 pkg_preinst() {
380 # Compare versions of Berkeley DB, bug 122877.
381 if use berkdb && [[ -f "${ROOT}usr/bin/svn" ]] ; then
382 OLD_BDB_VERSION="$(scanelf -nq "${ROOT}usr/$(get_libdir)/libsvn_subr-1.so.0" | grep -Eo "libdb-[[:digit:]]+\.[[:digit:]]+" | sed -e "s/libdb-\(.*\)/\1/")"
383 NEW_BDB_VERSION="$(scanelf -nq "${D}usr/$(get_libdir)/libsvn_subr-1.so.0" | grep -Eo "libdb-[[:digit:]]+\.[[:digit:]]+" | sed -e "s/libdb-\(.*\)/\1/")"
384 if [[ "${OLD_BDB_VERSION}" != "${NEW_BDB_VERSION}" ]] ; then
385 CHANGED_BDB_VERSION=1
386 fi
387 fi
388 }
389
390 pkg_postinst() {
391 use emacs && elisp-site-regen
392 use perl && perl-module_pkg_postinst
393
394 elog "Subversion Server Notes"
395 elog "-----------------------"
396 elog
397 elog "If you intend to run a server, a repository needs to be created using"
398 elog "svnadmin (see man svnadmin) or the following command to create it in"
399 elog "${SVN_REPOS_LOC}:"
400 elog
401 elog " emerge --config =${CATEGORY}/${PF}"
402 elog
403 elog "Subversion has multiple server types, take your pick:"
404 elog
405 elog " - svnserve daemon: "
406 elog " 1. Edit /etc/conf.d/svnserve"
407 elog " 2. Fix the repository permissions (see \"Fixing the repository permissions\")"
408 elog " 3. Start daemon: /etc/init.d/svnserve start"
409 elog " 4. Make persistent: rc-update add svnserve default"
410 elog
411 elog " - svnserve via xinetd:"
412 elog " 1. Edit /etc/xinetd.d/svnserve (remove disable line)"
413 elog " 2. Fix the repository permissions (see \"Fixing the repository permissions\")"
414 elog " 3. Restart xinetd.d: /etc/init.d/xinetd restart"
415 elog
416 elog " - svn over ssh:"
417 elog " 1. Fix the repository permissions (see \"Fixing the repository permissions\")"
418 elog " Additionally run:"
419 elog " groupadd svnusers"
420 elog " chown -R root:svnusers ${SVN_REPOS_LOC}/repos"
421 elog " 2. Create an svnserve wrapper in /usr/local/bin to set the umask you"
422 elog " want, for example:"
423 elog " #!/bin/bash"
424 elog " . /etc/conf.d/svnserve"
425 elog " umask 007"
426 elog " exec /usr/bin/svnserve \${SVNSERVE_OPTS} \"\$@\""
427 elog
428
429 if use apache2; then
430 elog " - http-based server:"
431 elog " 1. Edit /etc/conf.d/apache2 to include both \"-D DAV\" and \"-D SVN\""
432 elog " 2. Create an htpasswd file:"
433 elog " htpasswd2 -m -c ${SVN_REPOS_LOC}/conf/svnusers USERNAME"
434 elog " 3. Fix the repository permissions (see \"Fixing the repository permissions\")"
435 elog " 4. Restart Apache: /etc/init.d/apache2 restart"
436 elog
437 fi
438
439 elog " Fixing the repository permissions:"
440 elog " chmod -Rf go-rwx ${SVN_REPOS_LOC}/conf"
441 elog " chmod -Rf g-w,o-rwx ${SVN_REPOS_LOC}/repos"
442 elog " chmod -Rf g+rw ${SVN_REPOS_LOC}/repos/db"
443 elog " chmod -Rf g+rw ${SVN_REPOS_LOC}/repos/locks"
444 elog
445
446 elog "If you intend to use svn-hot-backup, you can specify the number of"
447 elog "backups to keep per repository by specifying an environment variable."
448 elog "If you want to keep e.g. 2 backups, do the following:"
449 elog "echo '# hot-backup: Keep that many repository backups around' > /etc/env.d/80subversion"
450 elog "echo 'SVN_HOTBACKUP_BACKUPS_NUMBER=2' >> /etc/env.d/80subversion"
451 elog
452
453 if [[ -n "${CHANGED_BDB_VERSION}" ]] ; then
454 ewarn "You upgraded from an older version of Berkeley DB and may experience"
455 ewarn "problems with your repository. Run the following commands as root to fix it:"
456 ewarn " db4_recover -h ${SVN_REPOS_LOC}/repos"
457 ewarn " chown -Rf apache:apache ${SVN_REPOS_LOC}/repos"
458 fi
459 }
460
461 pkg_postrm() {
462 use emacs && elisp-site-regen
463 use perl && perl-module_pkg_postrm
464 }
465
466 pkg_config() {
467 if [[ ! -x "${ROOT}usr/bin/svnadmin" ]] ; then
468 die "You seem to only have built the Subversion client"
469 fi
470
471 einfo ">>> Initializing the database in ${ROOT}${SVN_REPOS_LOC} ..."
472 if [[ -e "${ROOT}${SVN_REPOS_LOC}/repos" ]] ; then
473 echo "A Subversion repository already exists and I will not overwrite it."
474 echo "Delete \"${ROOT}${SVN_REPOS_LOC}/repos\" first if you're sure you want to have a clean version."
475 else
476 mkdir -p "${ROOT}${SVN_REPOS_LOC}/conf"
477
478 einfo ">>> Populating repository directory ..."
479 # Create initial repository.
480 "${ROOT}usr/bin/svnadmin" create "${ROOT}${SVN_REPOS_LOC}/repos"
481
482 einfo ">>> Setting repository permissions ..."
483 SVNSERVE_USER="$(. "${ROOT}etc/conf.d/svnserve" ; echo "${SVNSERVE_USER}")"
484 SVNSERVE_GROUP="$(. "${ROOT}etc/conf.d/svnserve" ; echo "${SVNSERVE_GROUP}")"
485 if use apache2 ; then
486 [[ -z "${SVNSERVE_USER}" ]] && SVNSERVE_USER="apache"
487 [[ -z "${SVNSERVE_GROUP}" ]] && SVNSERVE_GROUP="apache"
488 else
489 [[ -z "${SVNSERVE_USER}" ]] && SVNSERVE_USER="svn"
490 [[ -z "${SVNSERVE_GROUP}" ]] && SVNSERVE_GROUP="svnusers"
491 enewgroup "${SVNSERVE_GROUP}"
492 enewuser "${SVNSERVE_USER}" -1 -1 "${SVN_REPOS_LOC}" "${SVNSERVE_GROUP}"
493 fi
494 chown -Rf "${SVNSERVE_USER}:${SVNSERVE_GROUP}" "${ROOT}${SVN_REPOS_LOC}/repos"
495 chmod -Rf go-rwx "${ROOT}${SVN_REPOS_LOC}/conf"
496 chmod -Rf o-rwx "${ROOT}${SVN_REPOS_LOC}/repos"
497 fi
498 }