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

Contents of /eclass/base.eclass

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.13 - (show annotations) (download)
Sat Mar 30 12:52:14 2002 UTC (12 years, 3 months ago) by danarmak
Branch: MAIN
Changes since 1.12: +3 -3 lines
make base_src_compile() use econf() and emake() from the default src_compile() in ebuild.sh

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

  ViewVC Help
Powered by ViewVC 1.1.20