aboutsummaryrefslogtreecommitdiffstats
path: root/main/openldap/APKBUILD
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2010-02-24 13:39:50 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2010-02-24 13:58:34 +0000
commita816d230e1457f50eb5752c4bf34b422f30b258c (patch)
tree75bd61e1b5c3b7201ce3aa8fb616d267dfdb2fcf /main/openldap/APKBUILD
parent88208f61cb8e5abf9e664174020e826ba379a562 (diff)
downloadaports-a816d230e1457f50eb5752c4bf34b422f30b258c.tar.bz2
aports-a816d230e1457f50eb5752c4bf34b422f30b258c.tar.xz
main/openldap: use dynamic backend modules
create subpackage for the biggest backends
Diffstat (limited to 'main/openldap/APKBUILD')
-rw-r--r--main/openldap/APKBUILD37
1 files changed, 28 insertions, 9 deletions
diff --git a/main/openldap/APKBUILD b/main/openldap/APKBUILD
index 5b440336c8..b0cdbbbab5 100644
--- a/main/openldap/APKBUILD
+++ b/main/openldap/APKBUILD
@@ -1,13 +1,16 @@
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=openldap
pkgver=2.4.19
-pkgrel=3
+pkgrel=4
pkgdesc="LDAP Server"
url="http://www.openldap.org/"
license="custom"
depends=
-makedepends="db-dev openssl-dev groff unixodbc-dev"
-subpackages="$pkgname-dev $pkgname-doc libldap"
+makedepends="db-dev openssl-dev groff unixodbc-dev libtool"
+subpackages="$pkgname-dev $pkgname-doc libldap $pkgname-back-sql:sql
+ $pkgname-back-bdb:bdb $pkgname-back-hdb:hdb $pkgname-back-ldap:ldap
+ $pkgname-back-meta:meta $pkgname-back-monitor:monitor"
+
install="$pkgname.pre-install $pkgname.post-install"
source="ftp://ftp.$pkgname.org/pub/OpenLDAP/$pkgname-release/$pkgname-$pkgver.tgz
openldap-2.4-ppolicy.patch
@@ -27,16 +30,16 @@ build () {
done
./configure --prefix=/usr \
- --libexecdir=/usr/sbin \
+ --libexecdir=/usr/lib \
--sysconfdir=/etc \
--mandir=/usr/share/man \
--localstatedir=/var/lib/openldap \
--enable-slapd \
- --enable-bdb \
- --enable-hdb \
- --enable-sql \
--enable-crypt \
+ --enable-modules \
--enable-dynamic \
+ --enable-bdb=mod \
+ --enable-hdb=mod \
--enable-dnssrv=mod \
--enable-ldap=mod \
--enable-meta=mod \
@@ -46,6 +49,7 @@ build () {
--enable-relay=mod \
--enable-shell=mod \
--enable-sock=mod \
+ --enable-sql=mod \
--with-tls=openssl
make || return 1
@@ -59,6 +63,7 @@ package() {
sed -i -e 's:/var/lib/openldap/run:/var/run/openldap:g' \
"$pkgdir"/etc/openldap/slapd.conf
+ mv "$pkgdir"/usr/lib/slapd "$pkgdir"/usr/sbin/
chmod g+r "$pkgdir"/etc/openldap/slapd.conf
install -Dm755 ../slapd.initd "$pkgdir"/etc/init.d/slapd
install -Dm755 ../slapd.confd "$pkgdir"/etc/conf.d/slapd
@@ -69,11 +74,25 @@ libldap() {
pkgdesc="OpenLDAP libraries"
depends=
install=
- mkdir -p "$subpkgdir"/usr "$subpkgdir"/etc/openldap
- mv "$pkgdir"/usr/lib "$subpkgdir"/usr/
+ mkdir -p "$subpkgdir"/usr/lib "$subpkgdir"/etc/openldap
+ mv "$pkgdir"/usr/lib/*.so* "$subpkgdir"/usr/lib/
mv "$pkgdir"/etc/openldap/ldap.conf "$subpkgdir"/etc/openldap/
}
+_backend() {
+ pkgdesc="OpenLDAP ${2:-$1} backend"
+ mkdir -p "$subpkgdir"/usr/lib/openldap
+ mv "$pkgdir"/usr/lib/openldap/back_$1* "$subpkgdir"/usr/lib/openldap/
+}
+
+bdb() { _backend bdb ; }
+hdb() { _backend hdb ; }
+sql() { _backend sql ODBC; }
+ldap() { _backend ldap LDAP; }
+meta() { _backend meta; }
+monitor() { _backend monitor; }
+
+
md5sums="4a6dab2711fcf141f19bb680bc335887 openldap-2.4.19.tgz
2524e490ba334a760fa57057c16da7a9 openldap-2.4-ppolicy.patch
d19d0502f046078ecd737e29e7552fa8 openldap-2.4.11-libldap_r.patch