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

Diff of /eclass/base.eclass

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

Revision 1.2 Revision 1.4
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.2 2001/09/28 19:30:09 danarmak Exp $ 4# $Header: /var/cvsroot/gentoo-x86/eclass/base.eclass,v 1.4 2001/09/29 12:35:38 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 7. /usr/portage/eclass/inherit.eclass || die
8inherit virtual || die 8inherit virtual || die
9ECLASS=base 9ECLASS=base
11S=${WORKDIR}/${P} 11S=${WORKDIR}/${P}
12DESCRIPTION="Based on the $ECLASS eclass" 12DESCRIPTION="Based on the $ECLASS eclass"
13 13
14base_src_unpack() { 14base_src_unpack() {
15 15
16 echo "in base_src_unpack, 1st parameter is $1"
17 [ -z "$1" ] && base_src_unpack all
18
16 while [ "$1" ]; do 19 while [ "$1" ]; do
17 20
18 case $1 in 21 case $1 in
19 unpack) 22 unpack)
23 echo "in base_src_unpack, action unpack"
20 unpack ${A} 24 unpack ${A}
21 ;; 25 ;;
22 all) 26 all)
27 echo "in base_src_unpack, action all"
23 base_src_unpack unpack 28 base_src_unpack unpack
24 ;; 29 ;;
25 esac 30 esac
26 31
27 shift 32 shift
28 done 33 done
29 34
30} 35}
31 36
32base_src_compile() { 37base_src_compile() {
38
39 echo "in base_src_compile, 1st parameter is $1"
40 [ -z "$1" ] && base_src_compile all
33 41
34 while [ "$1" ]; do 42 while [ "$1" ]; do
35 43
36 case $1 in 44 case $1 in
37 configure) 45 configure)
46 echo "in base_src_compile, action configure"
38 configure || die 47 ./configure || die
39 ;; 48 ;;
40 make) 49 make)
50 echo "in base_src_compile, action make"
41 make || die 51 make || die
42 ;; 52 ;;
43 all) 53 all)
54 echo "in base_src_compile, action all"
44 base_src_compile configure make 55 base_src_compile configure make
45 ;; 56 ;;
46 esac 57 esac
47 58
48 shift 59 shift
50 61
51} 62}
52 63
53base_src_install() { 64base_src_install() {
54 65
66 echo "in base_src_install, 1st parameter is $1"
67 [ -z "$1" ] && base_src_install all
68
55 while [ "$1" ]; do 69 while [ "$1" ]; do
56 70
57 case $1 in 71 case $1 in
58 make) 72 make)
73 echo "in base_src_install, action make"
59 make DESTDIR=${D} install || die 74 make DESTDIR=${D} install || die
60 ;; 75 ;;
61 all) 76 all)
77 echo "in base_src_install, action all"
62 base_src_install make 78 base_src_install make
63 ;; 79 ;;
64 esac 80 esac
65 81
66 shift 82 shift
67 done 83 done
68 84
69} 85}
70 86
71EXPORT_FUNCTIONS 87EXPORT_FUNCTIONS src_unpack src_compile src_install
72 88

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.4

  ViewVC Help
Powered by ViewVC 1.1.20