/[gentoo-x86]/eclass/subversion.eclass
Gentoo

Diff of /eclass/subversion.eclass

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.81 Revision 1.83
1# Copyright 1999-2012 Gentoo Foundation 1# Copyright 1999-2012 Gentoo Foundation
2# Distributed under the terms of the GNU General Public License v2 2# Distributed under the terms of the GNU General Public License v2
3# $Header: /var/cvsroot/gentoo-x86/eclass/subversion.eclass,v 1.81 2012/07/29 04:26:10 hattya Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/subversion.eclass,v 1.83 2012/07/29 05:54:17 hattya Exp $
4 4
5# @ECLASS: subversion.eclass 5# @ECLASS: subversion.eclass
6# @MAINTAINER: 6# @MAINTAINER:
7# Akinori Hattori <hattya@gentoo.org> 7# Akinori Hattori <hattya@gentoo.org>
8# @AUTHOR: 8# @AUTHOR:
17ESVN="${ECLASS}" 17ESVN="${ECLASS}"
18 18
19case "${EAPI:-0}" in 19case "${EAPI:-0}" in
20 0|1) 20 0|1)
21 EXPORT_FUNCTIONS src_unpack pkg_preinst 21 EXPORT_FUNCTIONS src_unpack pkg_preinst
22 DEPEND="dev-vcs/subversion"
22 ;; 23 ;;
23 *) 24 *)
24 EXPORT_FUNCTIONS src_unpack src_prepare pkg_preinst 25 EXPORT_FUNCTIONS src_unpack src_prepare pkg_preinst
26 DEPEND="|| ( dev-vcs/subversion[webdav-neon] dev-vcs/subversion[webdav-serf] )"
25 ;; 27 ;;
26esac 28esac
27 29
28DEPEND="dev-vcs/subversion 30DEPEND+=" net-misc/rsync"
29 net-misc/rsync"
30 31
31# @ECLASS-VARIABLE: ESVN_STORE_DIR 32# @ECLASS-VARIABLE: ESVN_STORE_DIR
32# @DESCRIPTION: 33# @DESCRIPTION:
33# subversion sources store directory. Users may override this in /etc/make.conf 34# subversion sources store directory. Users may override this in /etc/make.conf
34[[ -z ${ESVN_STORE_DIR} ]] && ESVN_STORE_DIR="${PORTAGE_ACTUAL_DISTDIR:-${DISTDIR}}/svn-src" 35[[ -z ${ESVN_STORE_DIR} ]] && ESVN_STORE_DIR="${PORTAGE_ACTUAL_DISTDIR:-${DISTDIR}}/svn-src"
58# @DESCRIPTION: 59# @DESCRIPTION:
59# repository uri 60# repository uri
60# 61#
61# e.g. http://foo/trunk, svn://bar/trunk, svn://bar/branch/foo@1234 62# e.g. http://foo/trunk, svn://bar/trunk, svn://bar/branch/foo@1234
62# 63#
63# supported protocols: 64# supported URI schemes:
64# http:// 65# http://
65# https:// 66# https://
66# svn:// 67# svn://
67# svn+ssh:// 68# svn+ssh://
69# file://
68# 70#
69# to peg to a specific revision, append @REV to the repo's uri 71# to peg to a specific revision, append @REV to the repo's uri
70ESVN_REPO_URI="${ESVN_REPO_URI:-}" 72ESVN_REPO_URI="${ESVN_REPO_URI:-}"
71 73
72# @ECLASS-VARIABLE: ESVN_REVISION 74# @ECLASS-VARIABLE: ESVN_REVISION
185 die "${ESVN}: ESVN_REPO_URI (or specified URI) is empty." 187 die "${ESVN}: ESVN_REPO_URI (or specified URI) is empty."
186 fi 188 fi
187 189
188 [[ -n "${ESVN_REVISION}" ]] && revision="${ESVN_REVISION}" 190 [[ -n "${ESVN_REVISION}" ]] && revision="${ESVN_REVISION}"
189 191
190 # check for the protocol 192 # check for the scheme
191 local protocol="${repo_uri%%:*}" 193 local scheme="${repo_uri%%:*}"
192 case "${protocol}" in 194 case "${scheme}" in
193 http|https) 195 http|https)
194 if ! built_with_use -o dev-vcs/subversion webdav-neon webdav-serf; then
195 echo
196 eerror "In order to emerge this package, you need to"
197 eerror "reinstall Subversion with support for WebDAV."
198 eerror "Subversion requires either Neon or Serf to support WebDAV."
199 echo
200 die "${ESVN}: reinstall Subversion with support for WebDAV."
201 fi
202 ;; 196 ;;
203 svn|svn+ssh) 197 svn|svn+ssh)
204 ;; 198 ;;
199 file)
200 ;;
205 *) 201 *)
206 die "${ESVN}: fetch from '${protocol}' is not yet implemented." 202 die "${ESVN}: fetch from '${scheme}' is not yet implemented."
207 ;; 203 ;;
208 esac 204 esac
209 205
210 addread "/etc/subversion" 206 addread "/etc/subversion"
211 addwrite "${ESVN_STORE_DIR}" 207 addwrite "${ESVN_STORE_DIR}"

Legend:
Removed from v.1.81  
changed lines
  Added in v.1.83

  ViewVC Help
Powered by ViewVC 1.1.20