blob: f0b4f6dfb0d6596090a26e724c8a9ab84f918d91 (
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
61
62
63
64
65
66
67
68
69
70
71
72
|
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-mail/procmail/procmail-3.22-r5.ebuild,v 1.12 2003/06/17 21:02:15 gmsoft Exp $
S=${WORKDIR}/${P}
DESCRIPTION="Mail delivery agent/filter"
SRC_URI="http://www.procmail.org/${P}.tar.gz"
HOMEPAGE="http://www.procmail.org/"
IUSE=""
DEPEND="virtual/glibc
virtual/mta"
RDEPEND="virtual/glibc"
PROVIDE="virtual/mda"
SLOT="0"
LICENSE="Artistic | GPL-2"
KEYWORDS="x86 ppc sparc alpha arm hppa"
src_compile() {
cp Makefile Makefile.orig
# Added a -O2 at the end of CFLAGS to overcome what seems to be a
# gcc-3.1 strstr() bug with more aggressive optimization flags
# The order of the flags matters as the last flag passed clobbers
# the first flag. i.e. if -O2 was placed before ${CFLAGS},
# whatever optimization that is in ${CFLAGS} would clobber -O2
sed -e "s:CFLAGS0 = -O:CFLAGS0 = ${CFLAGS} -O2:" \
-e "s:LOCKINGTEST=__defaults__:#LOCKINGTEST=__defaults__:" \
-e "s:#LOCKINGTEST=/tmp:LOCKINGTEST=/tmp:" Makefile.orig > Makefile
if [ -z "`use mbox`" ];
then
echo "# Use maildir-style mailbox in user's home directory" > ${S}/procmailrc
echo 'DEFAULT=$HOME/.maildir/' >> ${S}/procmailrc
cd ${S}
patch -p1 <${FILESDIR}/gentoo-maildir.diff
else
echo '# Use mbox-style mailbox in /var/spool/mail' > ${S}/procmail
echo 'DEFAULT=/var/spool/mail/$LOGNAME' >> ${S}/procmailrc
fi
emake || die
}
src_install () {
cd ${S}/new
insinto /usr/bin
insopts -m 6755
doins procmail
insopts -m 2755
doins lockfile
dobin formail mailstat
doman *.1 *.5
cd ${S}
dodoc Artistic COPYING FAQ FEATURES HISTORY INSTALL KNOWN_BUGS README
insinto /etc
doins procmailrc
docinto examples
dodoc examples/*
}
|