blob: 96c5b171050899d4b405b2795fd192ccdbaea8f2 (
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
|
#!/bin/sh
NAME="imap"
DESC="An IMAP/POP server"
MAKEDEPS="openssl"
PKG_VER=2007f
SOURCE="http://ftp.ntua.gr/pub/net/mail/imap/imap-$PKG_VER.tar.gz"
ADDITIONAL="
1006_openssl1.1_autoverify.patch
2014_openssl1.1.1_sni.patch
c-client-2006k_KOLAB_Annotations.patch
fix-linking.patch
"
prepare() {
apply_patches
sed -e "s:-g -fno-omit-frame-pointer -O6:\${CFLAGS}:" \
-e "s:SSLDIR=/usr/local/ssl:SSLDIR=/usr:" \
-e "s:SSLCERTS=\$(SSLDIR)/certs:SSLCERTS=/etc/ssl/certs:" \
-e "s:^CC=.*:CC=${CC:-cc}:" \
-i src/osdep/unix/Makefile
}
build() {
cd $BUILD_ROOT
export GCCCFLAGS="$CFLAGS"
yes "y" | make slx SPECIALAUTHENTICATORS=ssl SSLTYPE=unix \
EXTRACFLAGS="$CFLAGS -fPIC" \
EXTRALDFLAGS="$LDFLAGS"
}
package() {
cd $BUILD_ROOT
mkdir -p $PKG_DEST/usr/sbin
install -D -m755 imapd/imapd $PKG_DEST/usr/sbin/imapd
install -D -m755 ipopd/ipop2d $PKG_DEST/usr/sbin/ipop2d
install -D -m755 ipopd/ipop3d $PKG_DEST/usr/sbin/ipop3d
for i in c-client mail imap4r1 rfc822 linkage misc smtp nntp osdep \
env_unix env fs ftl nl tcp sslio utf8 utf8aux; do
install -D -m644 c-client/$i.h \
"$PKG_DEST"/usr/include/imap/$i.h
done
install -m644 c-client/linkage.c "$PKG_DEST"/usr/include/imap/linkage.c
install -Dm755 c-client/libc-client.so.1.0.0 \
"$PKG_DEST"/usr/lib/libc-client.so.1.0.0
ln -s libc-client.so.1.0.0 "$PKG_DEST"/usr/lib/libc-client.so.1
ln -s libc-client.so.1.0.0 "$PKG_DEST"/usr/lib/libc-client.so
}
|