summaryrefslogtreecommitdiff
blob: 1dd22b9343bcc38716a9a0e39e5e4fbccba953e5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
# Copyright 1999-2001 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License, v2 or later
# Author First Last <your email>
# $Header: /var/cvsroot/gentoo-x86/skel.build,v 1.7 2001/08/25 21:15:08 chadh Exp $

#Remeber to add the proper Author line, above.  Don't worry about the
# fourth line; it'll get automatically fixed when the ebuild is checked in

#Source directory; the dir where the sources can be found (automatically
# unpacked) inside ${WORKDIR}
S=${WORKDIR}/${P}

#Short one-line description
DESCRIPTION="This is a sample skeleton ebuild file"

#Point to any required sources; these will be automatically downloaded
# by Portage
SRC_URI="ftp://foo.bar.com/${P}.tar.gz"

#Homepage, not used by Portage directly but handy for developer reference
HOMEPAGE="http://"

#build-time dependencies
DEPEND=""

#run-time dependencies, same as DEPEND if RDEPEND isn't defined:
#RDEPEND=""

src_compile() {
    #the "try" command will stop the build process if the specified
    #command fails.  Prefix critical
	#commands with "try"
	./configure --infodir=/usr/share/info --mandir=/usr/share/man --prefix=/usr --host=${CHOST} || die
    #Note the use of --infodir and --mandir, above.  This is to make
    # this package FHS 2.2-compliant
	#(/usr/share is used for info and man now).
	
	emake || die
	#emake (previously known as pmake) is a script that calls the standard
	# GNU make with parallel
	#building options for speedier builds on SMP systems.  Use emake first;
	# it might not work.  If not, then replace the line above with:

	#make || die
}

src_install () {
	#you must *personally verify* that this trick doesn't install
	#anything outside of DESTDIR; do this by reading and understanding
	#the install part of the Makefiles.  Also note that this will often
	#also work for autoconf stuff (usually much more often than DESTDIR,
	#which is actually quite rare.
	
	make prefix=${D}/usr install || die

    make DESTDIR=${D} install || die
	#again, verify the Makefiles!  We don't want anything falling outside
	#of ${D}.
}