blob: faa9353f5051eb0393c94f3e0f12ca19aabc29e3 (
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
|
# Copyright 1999-2003 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/net-nds/openldap/openldap-2.0.27-r2.ebuild,v 1.8 2003/06/11 00:49:20 msterret Exp $
inherit eutils
DESCRIPTION="LDAP suite of application and development tools"
SRC_URI="ftp://ftp.OpenLDAP.org/pub/OpenLDAP/openldap-release/${P}.tgz"
HOMEPAGE="http://www.OpenLDAP.org/"
SLOT="0"
KEYWORDS="~x86 ~ppc ~alpha"
LICENSE="OPENLDAP"
IUSE="ssl tcpd readline ipv6 gdbm ldap kerberos odbc"
DEPEND="virtual/glibc
>=sys-apps/sed-4
>=sys-libs/ncurses-5.1
>=sys-libs/db-3
tcpd? ( >=sys-apps/tcp-wrappers-7.6 )
ssl? ( >=dev-libs/openssl-0.9.6 )
readline? ( >=sys-libs/readline-4.1 )
gdbm? ( >=sys-libs/gdbm-1.8.0 )
kerberos? ( >=app-crypt/mit-krb5-1.2.6 )
odbc? ( dev-db/unixODBC )"
RDEPEND="virtual/glibc
>=sys-libs/ncurses-5.1
gdbm? ( >=sys-libs/gdbm-1.8.0 )"
MAKEOPTS="${MAKEOPTS} -j1"
pkg_preinst() {
if ! grep -q ^ldap: /etc/group
then
groupadd -g 439 ldap || die "problem adding group ldap"
fi
if ! grep -q ^ldap: /etc/passwd
then
useradd -u 439 -d /usr/lib/openldap -g ldap -s /dev/null ldap \
|| die "problem adding user ldap"
fi
}
src_unpack() {
unpack ${A}
cd ${S}
epatch ${FILESDIR}/kerberos-2.0.diff.bz2
}
src_compile() {
local myconf
myconf="`use_enable debug`"
use kerberos \
&& myconf="${myconf} --with-kerberos --enable-kpasswd" \
|| myconf="${myconf} --without-kerberos --disable-kpasswd"
use readline \
&& myconf="${myconf} --with-readline" \
|| myconf="${myconf} --without-readline"
use ssl \
&& myconf="${myconf} --with-tls" \
|| myconf="${myconf} --without-tls"
use tcpd \
&& myconf="${myconf} --enable-wrappers" \
|| myconf="${myconf} --disable-wrappers"
use ipv6 \
&& myconf="${myconf} --enable-ipv6" \
|| myconf="${myconf} --disable-ipv6"
use odbc \
&& myconf="${myconf} --enable-sql" \
|| myconf="${myconf} --disable-sql"
econf \
--libexecdir=/usr/lib/openldap \
--enable-crypt \
--enable-modules \
--enable-phonetic \
--enable-dynamic \
--enable-ldap \
--without-cyrus-sasl \
--disable-spasswd \
--enable-passwd \
--enable-shell \
--enable-slurpd \
--enable-ldbm \
--with-ldbm-api=auto \
${myconf} || die "configure failed"
emake depend || die "make depend failed"
emake || die "make failed"
cd tests ; make || die "make tests failed"
}
src_install() {
make DESTDIR=${D} install || die "make install failed"
chown ldap:ldap ${D}/etc/openldap/slapd.conf
dodir /var/lib/openldap-data
chown ldap:ldap ${D}var/lib/openldap-data
dodoc ANNOUNCEMENT CHANGES COPYRIGHT README LICENSE
docinto rfc ; dodoc doc/rfc/*.txt
exeinto /etc/init.d
newexe ${FILESDIR}/slapd-2.1-r1.rc6 slapd
newexe ${FILESDIR}/slurpd-2.1.rc6 slurpd
insinto /etc/conf.d
newins ${FILESDIR}/slapd-2.1.conf slapd.conf
# manually remove /var/tmp references in .la
# because it is packaged with an ancient libtool
for x in ${D}/usr/lib/lib*.la; do
sed -i -e "s:${D}::" ${x}
done
}
|