diff options
author | Jackie Huang <jackie.huang@windriver.com> | 2014-09-29 06:09:10 -0400 |
---|---|---|
committer | Martin Jansa <Martin.Jansa@gmail.com> | 2014-10-10 12:47:34 +0200 |
commit | eb65ab684d824be1d12524cb307d9e59925147c1 (patch) | |
tree | 875253c57eaa7e86e70d21b58cc396fb9c2de342 /meta-oe/recipes-support | |
parent | 17ff23b4a4a0e5ed7efde107fb00296f1ebd5fdd (diff) | |
download | meta-openembedded-eb65ab684d824be1d12524cb307d9e59925147c1.tar.gz |
openldap: update version to 2.4.39
Changed:
* Move slapd from ${libexecdir} to ${sbin}:
Installing slapd under ${sbin} is more FHS and LSB compliance
* Manage init script by inheriting update-rc.d, than postinst
* Add status for initscript
* Rename the patch named with commit id to
gnutls-Avoid-use-of-deprecated-function.patch
* Add a patch for CVE-2013-4449
* Add a patch to use /dev/urandom for entropy
* Allow tls obtains random bits from /dev/urandom:
The URANDOM_DEVICE is undefined for cross-compiling, define it as
/dev/urandom to allow tls obtains random bits from /dev/urandom.
* Add PACKAGECONFIG for mdb, ndb, relay and sock
* Remove unsupported config for ldbm
* Add license file
Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Diffstat (limited to 'meta-oe/recipes-support')
-rw-r--r-- | meta-oe/recipes-support/openldap/openldap-2.4.39/ITS-7723-fix-reference-counting.patch | 38 | ||||
-rw-r--r-- | meta-oe/recipes-support/openldap/openldap-2.4.39/gnutls-Avoid-use-of-deprecated-function.patch (renamed from meta-oe/recipes-support/openldap/openldap-2.4.23/0205e83f4670d10ad3c6ae4b8fc5ec1d0c7020c0.patch) | 0 | ||||
-rw-r--r-- | meta-oe/recipes-support/openldap/openldap-2.4.39/initscript (renamed from meta-oe/recipes-support/openldap/openldap-2.4.23/initscript) | 10 | ||||
-rw-r--r-- | meta-oe/recipes-support/openldap/openldap-2.4.39/install-strip.patch (renamed from meta-oe/recipes-support/openldap/openldap-2.4.23/install-strip.patch) | 0 | ||||
-rw-r--r-- | meta-oe/recipes-support/openldap/openldap-2.4.39/kill-icu.patch (renamed from meta-oe/recipes-support/openldap/openldap-2.4.23/kill-icu.patch) | 0 | ||||
-rw-r--r-- | meta-oe/recipes-support/openldap/openldap-2.4.39/openldap-2.4.28-gnutls-gcrypt.patch (renamed from meta-oe/recipes-support/openldap/openldap-2.4.23/openldap-2.4.28-gnutls-gcrypt.patch) | 0 | ||||
-rw-r--r-- | meta-oe/recipes-support/openldap/openldap-2.4.39/openldap-m4-pthread.patch (renamed from meta-oe/recipes-support/openldap/openldap-2.4.23/openldap-m4-pthread.patch) | 0 | ||||
-rw-r--r-- | meta-oe/recipes-support/openldap/openldap-2.4.39/use-urandom.patch | 38 | ||||
-rw-r--r-- | meta-oe/recipes-support/openldap/openldap_2.4.39.bb (renamed from meta-oe/recipes-support/openldap/openldap_2.4.23.bb) | 81 |
9 files changed, 125 insertions, 42 deletions
diff --git a/meta-oe/recipes-support/openldap/openldap-2.4.39/ITS-7723-fix-reference-counting.patch b/meta-oe/recipes-support/openldap/openldap-2.4.39/ITS-7723-fix-reference-counting.patch new file mode 100644 index 000000000..9a0f4cb14 --- /dev/null +++ b/meta-oe/recipes-support/openldap/openldap-2.4.39/ITS-7723-fix-reference-counting.patch | |||
@@ -0,0 +1,38 @@ | |||
1 | From 59688044386dfeee0c837a15133f4e878f1bb661 Mon Sep 17 00:00:00 2001 | ||
2 | From: Jan Synacek <jsynacek@redhat.com> | ||
3 | Date: Wed, 13 Nov 2013 09:06:54 +0100 | ||
4 | Subject: [PATCH] ITS#7723 fix reference counting | ||
5 | |||
6 | Upstream-Status: Backport | ||
7 | |||
8 | Commit 59688044386dfeee0c837a15133f4e878f1bb661 upstream | ||
9 | |||
10 | Signed-off-by: Yue Tao <Yue.Tao@windriver.com> | ||
11 | Signed-off-by: Jackie Huang <jackie.huang@windriver.com> | ||
12 | --- | ||
13 | libraries/librewrite/session.c | 2 ++ | ||
14 | 1 files changed, 2 insertions(+), 0 deletions(-) | ||
15 | |||
16 | diff --git a/libraries/librewrite/session.c b/libraries/librewrite/session.c | ||
17 | index fcc7698..02fc054 100644 | ||
18 | --- a/libraries/librewrite/session.c | ||
19 | +++ b/libraries/librewrite/session.c | ||
20 | @@ -161,6 +161,7 @@ rewrite_session_find( | ||
21 | #ifdef USE_REWRITE_LDAP_PVT_THREADS | ||
22 | if ( session ) { | ||
23 | ldap_pvt_thread_mutex_lock( &session->ls_mutex ); | ||
24 | + session->ls_count++; | ||
25 | } | ||
26 | ldap_pvt_thread_rdwr_runlock( &info->li_cookies_mutex ); | ||
27 | #endif /* USE_REWRITE_LDAP_PVT_THREADS */ | ||
28 | @@ -178,6 +179,7 @@ rewrite_session_return( | ||
29 | ) | ||
30 | { | ||
31 | assert( session != NULL ); | ||
32 | + session->ls_count--; | ||
33 | ldap_pvt_thread_mutex_unlock( &session->ls_mutex ); | ||
34 | } | ||
35 | |||
36 | -- | ||
37 | 1.7.5.4 | ||
38 | |||
diff --git a/meta-oe/recipes-support/openldap/openldap-2.4.23/0205e83f4670d10ad3c6ae4b8fc5ec1d0c7020c0.patch b/meta-oe/recipes-support/openldap/openldap-2.4.39/gnutls-Avoid-use-of-deprecated-function.patch index dffd3ca51..dffd3ca51 100644 --- a/meta-oe/recipes-support/openldap/openldap-2.4.23/0205e83f4670d10ad3c6ae4b8fc5ec1d0c7020c0.patch +++ b/meta-oe/recipes-support/openldap/openldap-2.4.39/gnutls-Avoid-use-of-deprecated-function.patch | |||
diff --git a/meta-oe/recipes-support/openldap/openldap-2.4.23/initscript b/meta-oe/recipes-support/openldap/openldap-2.4.39/initscript index 1395f7256..08d1067a7 100644 --- a/meta-oe/recipes-support/openldap/openldap-2.4.23/initscript +++ b/meta-oe/recipes-support/openldap/openldap-2.4.39/initscript | |||
@@ -5,8 +5,10 @@ | |||
5 | # > update-rc.d openldap defaults 60 | 5 | # > update-rc.d openldap defaults 60 |
6 | # | 6 | # |
7 | 7 | ||
8 | # Source function library. | ||
9 | . /etc/init.d/functions | ||
8 | 10 | ||
9 | slapd=/usr/libexec/slapd | 11 | slapd=/usr/sbin/slapd |
10 | test -x "$slapd" || exit 0 | 12 | test -x "$slapd" || exit 0 |
11 | 13 | ||
12 | 14 | ||
@@ -21,8 +23,12 @@ case "$1" in | |||
21 | start-stop-daemon --stop --quiet --pidfile /var/run/slapd.pid | 23 | start-stop-daemon --stop --quiet --pidfile /var/run/slapd.pid |
22 | echo "." | 24 | echo "." |
23 | ;; | 25 | ;; |
26 | status) | ||
27 | status $slapd; | ||
28 | exit $? | ||
29 | ;; | ||
24 | *) | 30 | *) |
25 | echo "Usage: /etc/init.d/openldap {start|stop}" | 31 | echo "Usage: /etc/init.d/openldap {start|stop|status}" |
26 | exit 1 | 32 | exit 1 |
27 | esac | 33 | esac |
28 | 34 | ||
diff --git a/meta-oe/recipes-support/openldap/openldap-2.4.23/install-strip.patch b/meta-oe/recipes-support/openldap/openldap-2.4.39/install-strip.patch index 2992b7030..2992b7030 100644 --- a/meta-oe/recipes-support/openldap/openldap-2.4.23/install-strip.patch +++ b/meta-oe/recipes-support/openldap/openldap-2.4.39/install-strip.patch | |||
diff --git a/meta-oe/recipes-support/openldap/openldap-2.4.23/kill-icu.patch b/meta-oe/recipes-support/openldap/openldap-2.4.39/kill-icu.patch index dcf541137..dcf541137 100644 --- a/meta-oe/recipes-support/openldap/openldap-2.4.23/kill-icu.patch +++ b/meta-oe/recipes-support/openldap/openldap-2.4.39/kill-icu.patch | |||
diff --git a/meta-oe/recipes-support/openldap/openldap-2.4.23/openldap-2.4.28-gnutls-gcrypt.patch b/meta-oe/recipes-support/openldap/openldap-2.4.39/openldap-2.4.28-gnutls-gcrypt.patch index c7b1552c1..c7b1552c1 100644 --- a/meta-oe/recipes-support/openldap/openldap-2.4.23/openldap-2.4.28-gnutls-gcrypt.patch +++ b/meta-oe/recipes-support/openldap/openldap-2.4.39/openldap-2.4.28-gnutls-gcrypt.patch | |||
diff --git a/meta-oe/recipes-support/openldap/openldap-2.4.23/openldap-m4-pthread.patch b/meta-oe/recipes-support/openldap/openldap-2.4.39/openldap-m4-pthread.patch index b669b7254..b669b7254 100644 --- a/meta-oe/recipes-support/openldap/openldap-2.4.23/openldap-m4-pthread.patch +++ b/meta-oe/recipes-support/openldap/openldap-2.4.39/openldap-m4-pthread.patch | |||
diff --git a/meta-oe/recipes-support/openldap/openldap-2.4.39/use-urandom.patch b/meta-oe/recipes-support/openldap/openldap-2.4.39/use-urandom.patch new file mode 100644 index 000000000..e7b988faf --- /dev/null +++ b/meta-oe/recipes-support/openldap/openldap-2.4.39/use-urandom.patch | |||
@@ -0,0 +1,38 @@ | |||
1 | openldap: assume /dev/urandom exists | ||
2 | |||
3 | When we are cross-compiling, we want to assume | ||
4 | that /dev/urandom exists. We could change the source | ||
5 | code to look for it, but this is the easy way out. | ||
6 | |||
7 | Upstream-Status: pending | ||
8 | |||
9 | Signed-off-by: Joe Slater <jslater@windriver.com> | ||
10 | |||
11 | |||
12 | --- a/configure.in | ||
13 | +++ b/configure.in | ||
14 | @@ -2142,8 +2142,8 @@ fi | ||
15 | |||
16 | dnl ---------------------------------------------------------------- | ||
17 | dnl Check for entropy sources | ||
18 | +dev=no | ||
19 | if test $cross_compiling != yes && test "$ac_cv_mingw32" != yes ; then | ||
20 | - dev=no | ||
21 | if test -r /dev/urandom ; then | ||
22 | dev="/dev/urandom"; | ||
23 | elif test -r /idev/urandom ; then | ||
24 | @@ -2156,9 +2156,11 @@ if test $cross_compiling != yes && test | ||
25 | dev="/idev/random"; | ||
26 | fi | ||
27 | |||
28 | - if test $dev != no ; then | ||
29 | - AC_DEFINE_UNQUOTED(URANDOM_DEVICE,"$dev",[set to urandom device]) | ||
30 | - fi | ||
31 | +elif test $cross_compiling == yes ; then | ||
32 | + dev="/dev/urandom"; | ||
33 | +fi | ||
34 | +if test $dev != no ; then | ||
35 | + AC_DEFINE_UNQUOTED(URANDOM_DEVICE,"$dev",[set to urandom device]) | ||
36 | fi | ||
37 | |||
38 | dnl ---------------------------------------------------------------- | ||
diff --git a/meta-oe/recipes-support/openldap/openldap_2.4.23.bb b/meta-oe/recipes-support/openldap/openldap_2.4.39.bb index b2693b5b0..243e38f39 100644 --- a/meta-oe/recipes-support/openldap/openldap_2.4.23.bb +++ b/meta-oe/recipes-support/openldap/openldap_2.4.39.bb | |||
@@ -1,5 +1,6 @@ | |||
1 | # OpenLDAP, a license free (see http://www.OpenLDAP.org/license.html) | 1 | # OpenLDAP, a license free (see http://www.OpenLDAP.org/license.html) |
2 | # | 2 | # |
3 | SUMMARY = "OpenLDAP Directory Service" | ||
3 | DESCRIPTION = "OpenLDAP Software is an open source implementation of the Lightweight Directory Access Protocol." | 4 | DESCRIPTION = "OpenLDAP Software is an open source implementation of the Lightweight Directory Access Protocol." |
4 | HOMEPAGE = "http://www.OpenLDAP.org/license.html" | 5 | HOMEPAGE = "http://www.OpenLDAP.org/license.html" |
5 | # The OpenLDAP Public License - see the HOMEPAGE - defines | 6 | # The OpenLDAP Public License - see the HOMEPAGE - defines |
@@ -8,7 +9,9 @@ HOMEPAGE = "http://www.OpenLDAP.org/license.html" | |||
8 | # basically BSD. opensource.org does not record this license | 9 | # basically BSD. opensource.org does not record this license |
9 | # at present (so it is apparently not OSI certified). | 10 | # at present (so it is apparently not OSI certified). |
10 | LICENSE = "OpenLDAP" | 11 | LICENSE = "OpenLDAP" |
11 | LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=3d82d3085f228af211a6502c7ea7c3c7" | 12 | LIC_FILES_CHKSUM = "file://COPYRIGHT;md5=f2bdbaa4f50199a00b6de2ca7ec1db05 \ |
13 | file://LICENSE;md5=153d07ef052c4a37a8fac23bc6031972 \ | ||
14 | " | ||
12 | SECTION = "libs" | 15 | SECTION = "libs" |
13 | 16 | ||
14 | LDAP_VER = "${@'.'.join(d.getVar('PV',1).split('.')[0:2])}" | 17 | LDAP_VER = "${@'.'.join(d.getVar('PV',1).split('.')[0:2])}" |
@@ -16,22 +19,23 @@ LDAP_VER = "${@'.'.join(d.getVar('PV',1).split('.')[0:2])}" | |||
16 | SRC_URI = "ftp://ftp.openldap.org/pub/OpenLDAP/openldap-release/${BP}.tgz \ | 19 | SRC_URI = "ftp://ftp.openldap.org/pub/OpenLDAP/openldap-release/${BP}.tgz \ |
17 | file://openldap-m4-pthread.patch \ | 20 | file://openldap-m4-pthread.patch \ |
18 | file://kill-icu.patch \ | 21 | file://kill-icu.patch \ |
19 | file://0205e83f4670d10ad3c6ae4b8fc5ec1d0c7020c0.patch \ | 22 | file://gnutls-Avoid-use-of-deprecated-function.patch \ |
20 | file://openldap-2.4.28-gnutls-gcrypt.patch \ | 23 | file://openldap-2.4.28-gnutls-gcrypt.patch \ |
24 | file://ITS-7723-fix-reference-counting.patch \ | ||
25 | file://use-urandom.patch \ | ||
21 | file://initscript \ | 26 | file://initscript \ |
22 | " | 27 | " |
23 | SRC_URI[md5sum] = "90150b8c0d0192e10b30157e68844ddf" | 28 | SRC_URI[md5sum] = "b0d5ee4b252c841dec6b332d679cf943" |
24 | SRC_URI[sha256sum] = "5a5ede91d5e8ab3c7f637620aa29a3b96eb34318a8b26c8eef2d2c789fc055e3" | 29 | SRC_URI[sha256sum] = "8267c87347103fef56b783b24877c0feda1063d3cb85d070e503d076584bf8a7" |
25 | 30 | ||
26 | DEPENDS = "util-linux groff-native" | 31 | DEPENDS = "util-linux groff-native" |
27 | 32 | ||
28 | PR = "r1" | ||
29 | # The original top.mk used INSTALL, not INSTALL_STRIP_PROGRAM when | 33 | # The original top.mk used INSTALL, not INSTALL_STRIP_PROGRAM when |
30 | # installing .so and executables, this fails in cross compilation | 34 | # installing .so and executables, this fails in cross compilation |
31 | # environments | 35 | # environments |
32 | SRC_URI += "file://install-strip.patch" | 36 | SRC_URI += "file://install-strip.patch" |
33 | 37 | ||
34 | inherit autotools-brokensep | 38 | inherit autotools-brokensep update-rc.d |
35 | 39 | ||
36 | # CV SETTINGS | 40 | # CV SETTINGS |
37 | # Required to work round AC_FUNC_MEMCMP which gets the wrong answer | 41 | # Required to work round AC_FUNC_MEMCMP which gets the wrong answer |
@@ -47,7 +51,7 @@ EXTRA_OECONF += "--with-yielding-select=yes" | |||
47 | EXTRA_OECONF += "--enable-dynamic" | 51 | EXTRA_OECONF += "--enable-dynamic" |
48 | 52 | ||
49 | PACKAGECONFIG ??= "gnutls modules \ | 53 | PACKAGECONFIG ??= "gnutls modules \ |
50 | ldap meta monitor null passwd shell proxycache dnssrv \ | 54 | bdb hdb ldap meta monitor null passwd shell proxycache dnssrv \ |
51 | " | 55 | " |
52 | #--with-tls with TLS/SSL support auto|openssl|gnutls [auto] | 56 | #--with-tls with TLS/SSL support auto|openssl|gnutls [auto] |
53 | PACKAGECONFIG[gnutls] = "--with-tls=gnutls,,gnutls libgcrypt" | 57 | PACKAGECONFIG[gnutls] = "--with-tls=gnutls,,gnutls libgcrypt" |
@@ -64,14 +68,9 @@ EXTRA_OECONF += "--enable-crypt" | |||
64 | # SLAPD BACKEND | 68 | # SLAPD BACKEND |
65 | # | 69 | # |
66 | # The backend must be set by the configuration. This controls the | 70 | # The backend must be set by the configuration. This controls the |
67 | # required database, the default database, bdb, is turned off but | 71 | # required database. |
68 | # can be turned back on again and it *is* below! The monitor backend | ||
69 | # is also disabled. If you try to change the backends but fail to | ||
70 | # enable a single one the build will fail in an obvious way. | ||
71 | # | ||
72 | EXTRA_OECONF += "--disable-bdb --disable-hdb --disable-monitor" | ||
73 | # | 72 | # |
74 | # Backends="bdb dnssrv hdb ldap ldbm meta monitor null passwd perl shell sql" | 73 | # Backends="bdb dnssrv hdb ldap mdb meta monitor ndb null passwd perl relay shell sock sql" |
75 | # | 74 | # |
76 | # Note that multiple backends can be built. The ldbm backend requires a | 75 | # Note that multiple backends can be built. The ldbm backend requires a |
77 | # build-time choice of database API. The bdb backend forces this to be | 76 | # build-time choice of database API. The bdb backend forces this to be |
@@ -82,27 +81,19 @@ md = "${libexecdir}/openldap" | |||
82 | #--enable-bdb enable Berkeley DB backend no|yes|mod yes | 81 | #--enable-bdb enable Berkeley DB backend no|yes|mod yes |
83 | # The Berkely DB is the standard choice. This version of OpenLDAP requires | 82 | # The Berkely DB is the standard choice. This version of OpenLDAP requires |
84 | # the version 4 implementation or better. | 83 | # the version 4 implementation or better. |
85 | PACKAGECONFIG[bdb] = "--enable-bdb=mod,--enable-bdb=no,db" | 84 | PACKAGECONFIG[bdb] = "--enable-bdb=yes,--enable-bdb=no,db" |
86 | 85 | ||
87 | #--enable-dnssrv enable dnssrv backend no|yes|mod no | 86 | #--enable-dnssrv enable dnssrv backend no|yes|mod no |
88 | PACKAGECONFIG[dnssrv] = "--enable-dnssrv=mod,--enable-dnssrv=no" | 87 | PACKAGECONFIG[dnssrv] = "--enable-dnssrv=mod,--enable-dnssrv=no" |
89 | 88 | ||
90 | #--enable-hdb enable Hierarchical DB backend no|yes|mod no | 89 | #--enable-hdb enable Hierarchical DB backend no|yes|mod no |
91 | # This forces ldbm to use Berkeley too, remove to use gdbm | 90 | PACKAGECONFIG[hdb] = "--enable-hdb=yes,--enable-hdb=no,db" |
92 | PACKAGECONFIG[hdb] = "--enable-hdb=mod,--enable-hdb=no,db" | ||
93 | 91 | ||
94 | #--enable-ldap enable ldap backend no|yes|mod no | 92 | #--enable-ldap enable ldap backend no|yes|mod no |
95 | PACKAGECONFIG[ldap] = "--enable-ldap=mod,--enable-ldap=no," | 93 | PACKAGECONFIG[ldap] = "--enable-ldap=mod,--enable-ldap=no," |
96 | 94 | ||
97 | #--enable-ldbm enable ldbm backend no|yes|mod no | 95 | #--enable-mdb enable mdb database backend no|yes|mod [yes] |
98 | # ldbm requires further specification of the underlying database API, because | 96 | PACKAGECONFIG[mdb] = "--enable-mdb=mod,--enable-mdb=no," |
99 | # bdb is enabled above this must be set to berkeley, however the config | ||
100 | # defaults this correctly so --with-ldbm-api is *not* set. The build will | ||
101 | # fail if bdb is removed, but no database is built to provide the | ||
102 | # support for ldbm | ||
103 | # guide.html:<P>back-ldbm was both slow and unreliable. Its byzantine indexing code was prone to spontaneous corruption, as were the underlying database libraries that were commonly used (e.g. GDBM or NDBM). back-bdb and back-hdb are superior in every aspect, with simplified indexing to avoid index corruption, fine-grained locking for greater concurrency, hierarchical caching for greater performance, streamlined on-disk format for greater efficiency and portability, and full transaction support for greater reliability.</P> | ||
104 | # configure: WARNING: unrecognized options: --disable-silent-rules, --enable-ldbm, --with-ldbm-api | ||
105 | #PACKAGECONFIG[ldbm] = "--enable-ldbm=mod --with-ldbm-api=gdbm,--enable-ldbm-no,gdbm" | ||
106 | 97 | ||
107 | #--enable-meta enable metadirectory backend no|yes|mod no | 98 | #--enable-meta enable metadirectory backend no|yes|mod no |
108 | PACKAGECONFIG[meta] = "--enable-meta=mod,--enable-meta=no," | 99 | PACKAGECONFIG[meta] = "--enable-meta=mod,--enable-meta=no," |
@@ -110,6 +101,9 @@ PACKAGECONFIG[meta] = "--enable-meta=mod,--enable-meta=no," | |||
110 | #--enable-monitor enable monitor backend no|yes|mod yes | 101 | #--enable-monitor enable monitor backend no|yes|mod yes |
111 | PACKAGECONFIG[monitor] = "--enable-monitor=mod,--enable-monitor=no," | 102 | PACKAGECONFIG[monitor] = "--enable-monitor=mod,--enable-monitor=no," |
112 | 103 | ||
104 | #--enable-ndb enable MySQL NDB Cluster backend no|yes|mod [no] | ||
105 | PACKAGECONFIG[ndb] = "--enable-ndb=mod,--enable-ndb=no," | ||
106 | |||
113 | #--enable-null enable null backend no|yes|mod no | 107 | #--enable-null enable null backend no|yes|mod no |
114 | PACKAGECONFIG[null] = "--enable-null=mod,--enable-null=no," | 108 | PACKAGECONFIG[null] = "--enable-null=mod,--enable-null=no," |
115 | 109 | ||
@@ -122,10 +116,16 @@ PACKAGECONFIG[passwd] = "--enable-passwd=mod,--enable-passwd=no," | |||
122 | # up the build machine perl - not good (inherit perlnative?) | 116 | # up the build machine perl - not good (inherit perlnative?) |
123 | PACKAGECONFIG[perl] = "--enable-perl=mod,--enable-perl=no,perl" | 117 | PACKAGECONFIG[perl] = "--enable-perl=mod,--enable-perl=no,perl" |
124 | 118 | ||
119 | #--enable-relay enable relay backend no|yes|mod [yes] | ||
120 | PACKAGECONFIG[relay] = "--enable-relay=mod,--enable-relay=no," | ||
121 | |||
125 | #--enable-shell enable shell backend no|yes|mod no | 122 | #--enable-shell enable shell backend no|yes|mod no |
126 | # configure: WARNING: Use of --without-threads is recommended with back-shell | 123 | # configure: WARNING: Use of --without-threads is recommended with back-shell |
127 | PACKAGECONFIG[shell] = "--enable-shell=mod --without-threads,--enable-shell=no," | 124 | PACKAGECONFIG[shell] = "--enable-shell=mod --without-threads,--enable-shell=no," |
128 | 125 | ||
126 | #--enable-sock enable sock backend no|yes|mod [no] | ||
127 | PACKAGECONFIG[sock] = "--enable-sock=mod,--enable-sock=no," | ||
128 | |||
129 | #--enable-sql enable sql backend no|yes|mod no | 129 | #--enable-sql enable sql backend no|yes|mod no |
130 | # sql requires some sql backend which provides sql.h, sqlite* provides | 130 | # sql requires some sql backend which provides sql.h, sqlite* provides |
131 | # sqlite.h (which may be compatible but hasn't been tried.) | 131 | # sqlite.h (which may be compatible but hasn't been tried.) |
@@ -141,7 +141,10 @@ PACKAGECONFIG[proxycache] = "--enable-proxycache=mod,--enable-proxycache=no," | |||
141 | FILES_${PN}-overlay-proxycache = "${md}/pcache-*.so.*" | 141 | FILES_${PN}-overlay-proxycache = "${md}/pcache-*.so.*" |
142 | PACKAGES += "${PN}-overlay-proxycache" | 142 | PACKAGES += "${PN}-overlay-proxycache" |
143 | 143 | ||
144 | CPPFLAGS_append = " -D_GNU_SOURCE" | 144 | # Append URANDOM_DEVICE='/dev/urandom' to CPPFLAGS: |
145 | # This allows tls to obtain random bits from /dev/urandom, by default | ||
146 | # it was disabled for cross-compiling. | ||
147 | CPPFLAGS_append = " -D_GNU_SOURCE -DURANDOM_DEVICE=\'/dev/urandom\'" | ||
145 | 148 | ||
146 | do_configure() { | 149 | do_configure() { |
147 | cp ${STAGING_DATADIR_NATIVE}/libtool/config/ltmain.sh ${S}/build | 150 | cp ${STAGING_DATADIR_NATIVE}/libtool/config/ltmain.sh ${S}/build |
@@ -176,23 +179,21 @@ do_install_append() { | |||
176 | chmod 755 ${D}${sysconfdir}/init.d/openldap | 179 | chmod 755 ${D}${sysconfdir}/init.d/openldap |
177 | # This is duplicated in /etc/openldap and is for slapd | 180 | # This is duplicated in /etc/openldap and is for slapd |
178 | rm -f ${D}${localstatedir}/openldap-data/DB_CONFIG.example | 181 | rm -f ${D}${localstatedir}/openldap-data/DB_CONFIG.example |
182 | |||
183 | # Installing slapd under ${sbin} is more FHS and LSB compliance | ||
184 | mv ${D}${libexecdir}/slapd ${D}/${sbindir}/slapd | ||
185 | SLAPTOOLS="slapadd slapcat slapdn slapindex slappasswd slaptest slapauth slapacl slapschema" | ||
186 | cd ${D}/${sbindir}/ | ||
187 | rm -f ${SLAPTOOLS} | ||
188 | for i in ${SLAPTOOLS}; do ln -sf slapd $i; done | ||
189 | |||
179 | rmdir "${D}${localstatedir}/run" | 190 | rmdir "${D}${localstatedir}/run" |
180 | rmdir --ignore-fail-on-non-empty "${D}${localstatedir}" | 191 | rmdir --ignore-fail-on-non-empty "${D}${localstatedir}" |
181 | } | 192 | } |
182 | 193 | ||
183 | pkg_postinst_${PN}-slapd () { | 194 | INITSCRIPT_PACKAGES = "${PN}-slapd" |
184 | if test -n "${D}"; then | 195 | INITSCRIPT_NAME_${PN}-slapd = "openldap" |
185 | D="-r $D" | 196 | INITSCRIPT_PARAMS_${PN}-slapd = "defaults" |
186 | fi | ||
187 | update-rc.d $D openldap defaults | ||
188 | } | ||
189 | |||
190 | pkg_prerm_${PN}-slapd () { | ||
191 | if test -n "${D}"; then | ||
192 | D="-r $D" | ||
193 | fi | ||
194 | update-rc.d $D openldap remove | ||
195 | } | ||
196 | 197 | ||
197 | PACKAGES_DYNAMIC += "^openldap-backends.* ^openldap-backend-.*" | 198 | PACKAGES_DYNAMIC += "^openldap-backends.* ^openldap-backend-.*" |
198 | 199 | ||