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

Diff of /eclass/base.eclass

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

Revision 1.5 Revision 1.11
1# Copyright 1999-2000 Gentoo Technologies, Inc. 1# Copyright 1999-2000 Gentoo Technologies, Inc.
2# Distributed under the terms of the GNU General Public License, v2 or later 2# Distributed under the terms of the GNU General Public License, v2 or later
3# Author Dan Armak <danarmak@gentoo.org> 3# Author Dan Armak <danarmak@gentoo.org>
4# $Header: /var/cvsroot/gentoo-x86/eclass/base.eclass,v 1.5 2001/10/01 11:04:22 danarmak Exp $ 4# $Header: /var/cvsroot/gentoo-x86/eclass/base.eclass,v 1.11 2002/02/07 18:52:18 danarmak Exp $
5# The base eclass defines some default functions and variables. Nearly everything 5# The base eclass defines some default functions and variables. Nearly everything
6# else inherits from here. 6# else inherits from here.
7. /usr/portage/eclass/inherit.eclass || die 7inherit functions
8inherit virtual || die
9ECLASS=base 8ECLASS=base
10 9
11S=${WORKDIR}/${P} 10S=${WORKDIR}/${P}
12DESCRIPTION="Based on the $ECLASS eclass" 11DESCRIPTION="Based on the $ECLASS eclass"
13 12
14base_src_unpack() { 13base_src_unpack() {
15 14
16 echo "in base_src_unpack, 1st parameter is $1" 15 debug-print-function $FUNCNAME $*
17 [ -z "$1" ] && base_src_unpack all 16 [ -z "$1" ] && base_src_unpack all
18 17
19 while [ "$1" ]; do 18 while [ "$1" ]; do
20 19
21 case $1 in 20 case $1 in
22 unpack) 21 unpack)
23 echo "in base_src_unpack, action unpack" 22 debug-print-section unpack
24 unpack ${A} 23 unpack ${A}
25 ;; 24 ;;
26 patch) 25 patch)
26 debug-print-section patch
27 cd ${S} 27 cd ${S}
28 patch -p0 < ${FILESDIR}/${P}-gentoo.diff 28 patch -p0 < ${FILESDIR}/${P}-gentoo.diff
29 ;; 29 ;;
30 all) 30 all)
31 echo "in base_src_unpack, action all" 31 debug-print-section all
32 base_src_unpack unpack 32 base_src_unpack unpack
33 ;; 33 ;;
34 esac 34 esac
35 35
36 shift 36 shift
37 done 37 done
38 38
39} 39}
40 40
41base_src_compile() { 41base_src_compile() {
42 42
43 echo "in base_src_compile, 1st parameter is $1" 43 debug-print-function $FUNCNAME $*
44 [ -z "$1" ] && base_src_compile all 44 [ -z "$1" ] && base_src_compile all
45 45
46 while [ "$1" ]; do 46 while [ "$1" ]; do
47 47
48 case $1 in 48 case $1 in
49 configure) 49 configure)
50 echo "in base_src_compile, action configure" 50 debug-print-section configure
51 ./configure || die 51 ./configure || die "died running ./configure, $FUNCNAME:configure"
52 ;; 52 ;;
53 make) 53 make)
54 echo "in base_src_compile, action make" 54 debug-print-section make
55 make || die 55 make || die "died running make, $FUNCNAME:make"
56 ;; 56 ;;
57 all) 57 all)
58 echo "in base_src_compile, action all" 58 debug-print-section all
59 base_src_compile configure make 59 base_src_compile configure make
60 ;; 60 ;;
61 esac 61 esac
62 62
63 shift 63 shift
65 65
66} 66}
67 67
68base_src_install() { 68base_src_install() {
69 69
70 echo "in base_src_install, 1st parameter is $1" 70 debug-print-function $FUNCNAME $*
71 [ -z "$1" ] && base_src_install all 71 [ -z "$1" ] && base_src_install all
72 72
73 while [ "$1" ]; do 73 while [ "$1" ]; do
74 74
75 case $1 in 75 case $1 in
76 make) 76 make)
77 echo "in base_src_install, action make" 77 debug-print-section make
78 make DESTDIR=${D} install || die 78 make DESTDIR=${D} install || die "died running make install, $FUNCNAME:make"
79 ;; 79 ;;
80 all) 80 all)
81 echo "in base_src_install, action all" 81 debug-print-section all
82 base_src_install make 82 base_src_install make
83 ;; 83 ;;
84 esac 84 esac
85 85
86 shift 86 shift
87 done 87 done
88 88
89} 89}
90 90
91EXPORT_FUNCTIONS src_unpack src_compile src_install 91EXPORT_FUNCTIONS src_unpack src_compile src_install
92 92

Legend:
Removed from v.1.5  
changed lines
  Added in v.1.11

  ViewVC Help
Powered by ViewVC 1.1.20