blob: 93da08d3e2a907b18b62205ed1f0afd63db40df9 (
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
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
|
#!/bin/sh
CWD=`pwd`
NAME=exim
VERSION=4.43
ARCH=i586
BUILD=1
PKGNAME=$NAME
PKGVER=$VERSION
BASEDIR=$PKGNAME-$PKGVER
ARCHIVE=$BASEDIR.tar.bz2
#FAQ=FAQ.txt.gz
#SAMPLES=config.samples.tar.gz
REPOSITORY=ftp://ftp.csx.cam.ac.uk/pub/software/email/exim/exim4
FLAGS="-O2 -march=pentium -mcpu=pentium -fno-strength-reduce \
-fomit-frame-pointer -ffast-math"
PKG=/tmp/package-$NAME
rm -rf $PKG
mkdir -p $PKG
# Obtain sources
if [ ! -e $ARCHIVE ]; then
if `wget "$REPOSITORY/$ARCHIVE"`; then
true
else
exit 1
fi
fi
#if [ ! -e $FAQ ]; then
# if `wget "$REPOSITORY/$FAQ"`; then
# true
# else
# exit 1
# fi
#fi
#if [ ! -e $SAMPLES ]; then
# if `wget "$REPOSITORY/$SAMPLES"`; then
# true
# else
# exit 1
# fi
#fi
# Compile
cd /tmp
tar jxvf $CWD/$ARCHIVE
cd $BASEDIR
bzcat $CWD/$NAME-$VERSION-heimdal.patch.bz2 | patch -p1 -s
make
# Install
make install DESTDIR=$PKG
mkdir -p $PKG/install $PKG/usr/doc/$NAME-$VERSION $PKG/etc/rc.d \
$PKG/etc/logrotate.d $PKG/var/spool/exim $PKG/var/log/exim $PKG/usr/man/man8
cat > $PKG/install/slack-desc <<EOF
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|' on
# the right side marks the last column you can put a character in. You must make
# exactly 11 lines for the formatting to be correct. It's also customary to
# leave one space after the ':'.
|-----handy-ruler------------------------------------------------------|
exim: exim (mail transfer agent)
exim:
exim: Exim is a full featured MTA (Mail Transport Agent) that is rather
exim: easy to configure compared to smail, sendmail and qmail. It is a
exim: drop-in replacement for sendmail/mailq/rsmtp.
exim:
exim: This particular package is compiled with TLS encryption (OpenSSL)
exim: and CRAM-MD5 SMTP authentication.
exim:
exim:
exim:
EOF
cat > $PKG/install/slack-required <<EOF
openssl-solibs >= 0.9.7d-i486-1
EOF
install -m644 -g0 -o0 doinst.sh $PKG/install
# Documentation
install -m444 -g0 -o0 doc/exim.8 $PKG/usr/man/man8
(
cd doc
mv README README.doc
rm -f exim.8
)
install -m644 -g0 -o0 ACKNOWLEDGMENTS LICENCE NOTICE README* \
doc/* $PKG/usr/doc/$NAME-$VERSION
gzip -9nf \
$PKG/usr/doc/$NAME-$VERSION/ACKNOWLEDGMENTS \
$PKG/usr/doc/$NAME-$VERSION/README* \
$PKG/usr/doc/$NAME-$VERSION/LICENCE \
$PKG/usr/doc/$NAME-$VERSION/ChangeLog \
$PKG/usr/doc/$NAME-$VERSION/*.upgrade \
$PKG/usr/doc/$NAME-$VERSION/*.txt \
$PKG/usr/doc/$NAME-$VERSION/NewStuff
# don't forget faq / samples!
#install -m644 -g0 -o0 $CWD/$FAQ $PKG/usr/doc/$NAME-$VERSION
#install -m644 -g0 -o0 $CWD/$SAMPLES $PKG/usr/doc/$NAME-$VERSION
# End Documentation
# Configuration
install -m644 -g0 -o0 exim.logrotate $PKG/etc/logrotate.d/exim
install -m644 -g0 -o0 rc.exim $PKG/etc/rc.d/rc.exim.new
mv $PKG/etc/aliases $PKG/etc/aliases.sample
mv $PKG/etc/mail/exim.conf $PKG/etc/mail/exim.conf.sample
# End Configuration
chmod 444 $PKG/usr/man/man?/*.?
gzip -9nf $PKG/usr/man/man?/*.?
strip $PKG/usr/sbin/* || :
chown -R root.root $PKG
chown mail.mail $PKG/var/spool/exim $PKG/var/log/exim
chgrp bin $PKG/usr/sbin/* $PKG/usr/sbin
# Make package
cd $PKG
cat install/slack-desc | grep "$NAME:" > /tmp/$NAME-$VERSION-$ARCH-$BUILD.txt
makepkg -l y -c n /tmp/$NAME-$VERSION-$ARCH-$BUILD.tgz
|