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

Diff of /eclass/base.eclass

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

Revision 1.32 Revision 1.34
1# Copyright 1999-2004 Gentoo Foundation 1# Copyright 1999-2008 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/base.eclass,v 1.32 2008/02/12 23:51:51 betelgeuse Exp $ 3# $Header: /var/cvsroot/gentoo-x86/eclass/base.eclass,v 1.34 2008/07/17 09:49:14 pva Exp $
4
5# @ECLASS: base.eclass
6# @MAINTAINER:
7# ???
4# 8#
5# Author Dan Armak <danarmak@gentoo.org> (nowadays retired) 9# Original author Dan Armak <danarmak@gentoo.org>
6# 10# @BLURB: The base eclass defines some default functions and variables.
11# @DESCRIPTION:
7# The base eclass defines some default functions and variables. Nearly everything 12# The base eclass defines some default functions and variables. Nearly
8# else inherits from here. 13# everything else inherits from here.
14
9 15
10inherit eutils 16inherit eutils
11 17
12DESCRIPTION="Based on the $ECLASS eclass" 18DESCRIPTION="Based on the $ECLASS eclass"
13 19
20# @FUNCTION: base_src_unpack
21# @USAGE: [ unpack ] [ patch ] [ autopatch ] [ all ]
22# @DESCRIPTION:
23# The base src_unpack function, which is exported. If no argument is given,
24# "all" is assumed.
14base_src_unpack() { 25base_src_unpack() {
15 26
16 debug-print-function $FUNCNAME $* 27 debug-print-function $FUNCNAME $*
17 [ -z "$1" ] && base_src_unpack all 28 [ -z "$1" ] && base_src_unpack all
18 29
32 ;; 43 ;;
33 autopatch) 44 autopatch)
34 debug-print-section autopatch 45 debug-print-section autopatch
35 debug-print "$FUNCNAME: autopatch: PATCHES=$PATCHES, PATCHES1=$PATCHES1" 46 debug-print "$FUNCNAME: autopatch: PATCHES=$PATCHES, PATCHES1=$PATCHES1"
36 cd "${S}" 47 cd "${S}"
37 for x in $PATCHES $PATCHES1; do 48 if [[ ${#PATCHES[@]} -gt 1 ]]; then
49 for x in "${PATCHES[@]}"; do
38 debug-print "$FUNCNAME: autopatch: patching from ${x}" 50 debug-print "$FUNCNAME: autopatch: patching from ${x}"
39 epatch ${x} 51 epatch "${x}"
40 done 52 done
53 else
54 for x in ${PATCHES} ${PATCHES1}; do
55 debug-print "$FUNCNAME: autopatch: patching from ${x}"
56 epatch "${x}"
57 done
58 fi
41 ;; 59 ;;
42 all) 60 all)
43 debug-print-section all 61 debug-print-section all
44 base_src_unpack unpack autopatch 62 base_src_unpack unpack autopatch
45 ;; 63 ;;
48 shift 66 shift
49 done 67 done
50 68
51} 69}
52 70
71# @FUNCTION: base_src_compile
72# @USAGE: [ configure ] [ make ] [ all ]
73# @DESCRIPTION:
74# The base src_compile function, which is exported. If no argument is given,
75# "all" is asasumed.
53base_src_compile() { 76base_src_compile() {
54 77
55 debug-print-function $FUNCNAME $* 78 debug-print-function $FUNCNAME $*
56 [ -z "$1" ] && base_src_compile all 79 [ -z "$1" ] && base_src_compile all
57 80
77 shift 100 shift
78 done 101 done
79 102
80} 103}
81 104
105# @FUNCTION: base_src_install
106# @USAGE: [ make ] [ all ]
107# @DESCRIPTION:
108# The base src_install function, which is exported. If no argument is given,
109# "all" is assumed.
82base_src_install() { 110base_src_install() {
83 111
84 debug-print-function $FUNCNAME $* 112 debug-print-function $FUNCNAME $*
85 [ -z "$1" ] && base_src_install all 113 [ -z "$1" ] && base_src_install all
86 114

Legend:
Removed from v.1.32  
changed lines
  Added in v.1.34

  ViewVC Help
Powered by ViewVC 1.1.20