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

Diff of /eclass/cvs.eclass

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

Revision 1.61 Revision 1.65
1# Copyright 1999-2004 Gentoo Foundation 1# Copyright 1999-2006 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/cvs.eclass,v 1.61 2005/09/21 23:22:56 vapier Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/cvs.eclass,v 1.65 2006/10/14 20:27:21 swegener Exp $
4#
5# Maintainer: vapier@gentoo.org (and anyone who wants to help)
4 6
5inherit eutils 7inherit eutils
6 8
7# This eclass provides the generic cvs fetching functions. To use 9# This eclass provides the generic cvs fetching functions. To use
8# this from an ebuild, set the `ebuild-configurable settings' as 10# this from an ebuild, set the `ebuild-configurable settings' as
62 64
63 65
64# ECVS_TOP_DIR -- The directory under which CVS modules are checked 66# ECVS_TOP_DIR -- The directory under which CVS modules are checked
65# out. 67# out.
66 68
67[ -z "$ECVS_TOP_DIR" ] && ECVS_TOP_DIR="${DISTDIR}/cvs-src" 69[ -z "$ECVS_TOP_DIR" ] && ECVS_TOP_DIR="${PORTAGE_ACTUAL_DISTDIR-${DISTDIR}}/cvs-src"
68 70
69# ECVS_SERVER -- CVS path 71# ECVS_SERVER -- CVS path
70# 72#
71# The format is "server:/dir", e.g. "anoncvs.kde.org:/home/kde". 73# The format is "server:/dir", e.g. "anoncvs.kde.org:/home/kde".
72# Remove the other parts of the full CVSROOT, which might look like 74# Remove the other parts of the full CVSROOT, which might look like
483 [ -z "$ECVS_MODULE" ] && die "ERROR: CVS module not set, cannot continue." 485 [ -z "$ECVS_MODULE" ] && die "ERROR: CVS module not set, cannot continue."
484 486
485 local ECVS_LOCALNAME="${ECVS_LOCALNAME}" 487 local ECVS_LOCALNAME="${ECVS_LOCALNAME}"
486 488
487 if [ -z "$ECVS_LOCALNAME" ]; then 489 if [ -z "$ECVS_LOCALNAME" ]; then
488 ECVS_LOCALNAME="$ECVS_MODULE" 490 ECVS_LOCALNAME="$ECVS_MODULE"
489 fi 491 fi
490 492
491 if [ "$ECVS_SERVER" == "offline" ]; then 493 local offline_pkg_var="ECVS_OFFLINE_${PN}"
494 if [ "${!offline_pkg_var}" == "1" -o "$ECVS_OFFLINE" == "1" -o "$ECVS_SERVER" == "offline" ]; then
492 # We're not required to fetch anything; the module already 495 # We're not required to fetch anything; the module already
493 # exists and shouldn't be updated. 496 # exists and shouldn't be updated.
494 if [ -d "${ECVS_TOP_DIR}/${ECVS_LOCALNAME}" ]; then 497 if [ -d "${ECVS_TOP_DIR}/${ECVS_LOCALNAME}" ]; then
495 debug-print "$FUNCNAME: offline mode" 498 debug-print "$FUNCNAME: offline mode"
496 else 499 else
497 debug-print "$FUNCNAME: Offline mode specified but directory ${ECVS_TOP_DIR}/${ECVS_LOCALNAME} not found, exiting with error" 500 debug-print "$FUNCNAME: Offline mode specified but directory ${ECVS_TOP_DIR}/${ECVS_LOCALNAME} not found, exiting with error"
498 die "ERROR: Offline mode specified, but directory ${ECVS_TOP_DIR}/${ECVS_LOCALNAME} not found. Aborting." 501 die "ERROR: Offline mode specified, but directory ${ECVS_TOP_DIR}/${ECVS_LOCALNAME} not found. Aborting."
499 fi 502 fi

Legend:
Removed from v.1.61  
changed lines
  Added in v.1.65

  ViewVC Help
Powered by ViewVC 1.1.20