- Backported -VVV commandline switch for slapd from HEAD

(to list enabled static overlays)
- Build all overlays except syncprov and ppolicy as dynamic modules
  (Fixes bnc#648479)
- Added README.dynamic-overlays to point out some details dynamice
  overlays

OBS-URL: https://build.opensuse.org/package/show/network:ldap/openldap2?expand=0&rev=55
This commit is contained in:
Ralf Haferkamp 2010-11-10 15:39:43 +00:00 committed by Git OBS Bridge
parent f886e9d5b0
commit f83edd3df7
7 changed files with 168 additions and 15 deletions

View File

@ -1,9 +1,8 @@
From 2a6dda988ea0b14931427cce835e8a6da5c3488e Mon Sep 17 00:00:00 2001 From 5ea89a18adad1c9e03fc8792dd95a4ad80603025 Mon Sep 17 00:00:00 2001
From: Ralf Haferkamp <rhafer@suse.de> From: Ralf Haferkamp <rhafer@suse.de>
Date: Wed, 16 Jun 2010 14:04:07 +0200 Date: Wed, 16 Jun 2010 14:04:07 +0200
Subject: build-adjustments Subject: [PATCH 01/11] build-adjustments
- Don't strip binaries
- Adjusted modules path - Adjusted modules path
- don't use automake macro - don't use automake macro

View File

@ -0,0 +1,57 @@
From 79ebaf1aab14b130ef980f593afb9ac6f9bfeb06 Mon Sep 17 00:00:00 2001
From: Ralf Haferkamp <rhafer@suse.de>
Date: Tue, 9 Nov 2010 16:26:24 +0100
Subject: [PATCH 09/11] List static overlays/backends when with -VVV
1 files changed, 20 insertions(+), 1 deletions(-)
diff --git a/servers/slapd/main.c b/servers/slapd/main.c
index 6990e91..0cb0de1 100644
--- a/servers/slapd/main.c
+++ b/servers/slapd/main.c
@@ -99,6 +99,9 @@ const char Versionstr[] =
OPENLDAP_PACKAGE " " OPENLDAP_VERSION " Standalone LDAP Server (slapd)";
#endif
+extern OverlayInit slap_oinfo[];
+extern BackendInfo slap_binfo[];
+
#define CHECK_NONE 0x00
#define CHECK_CONFIG 0x01
#define CHECK_LOGLEVEL 0x02
@@ -340,7 +343,8 @@ usage( char *name )
#if defined(HAVE_SETUID) && defined(HAVE_SETGID)
"\t-u user\t\tUser (id or name) to run as\n"
#endif
- "\t-V\t\tprint version info (-VV only)\n"
+ "\t-V\t\tprint version info (-VV exit afterwards, -VVV print\n"
+ "\t\t\tinfo about static overlays and backends)\n"
);
}
@@ -684,6 +688,21 @@ unhandled_option:;
if ( version ) {
fprintf( stderr, "%s\n", Versionstr );
+ if ( version > 2 ) {
+ if ( slap_oinfo[0].ov_type ) {
+ fprintf( stderr, "Included static overlays:\n");
+ for ( i= 0 ; slap_oinfo[i].ov_type; i++ ) {
+ fprintf( stderr, " %s\n", slap_oinfo[i].ov_type );
+ }
+ }
+ if ( slap_binfo[0].bi_type ) {
+ fprintf( stderr, "Included static backends:\n");
+ for ( i= 0 ; slap_binfo[i].bi_type; i++ ) {
+ fprintf( stderr, " %s\n", slap_binfo[i].bi_type );
+ }
+ }
+ }
+
if ( version > 1 ) goto stop;
}
--
1.7.1

19
README.dynamic-overlays Normal file
View File

@ -0,0 +1,19 @@
Most of the OpenLDAP overlays are now compiled as dynamic modules in our
packages. If you want to use any of these in your setup make sure to put
the correct "olcModuleLoad" or "moduleload" statements in your configuration.
For details please see the slapd-config(5) and slapd.conf(5) manpages
(depending on which config mechanism you use).
For a list of the list of included dynamic modules see the
"/usr/lib/openldap/modules/" directory.
For convenience and backwards compatibility some overlays are are still
compiled statically into the slapd binary. To see which overlays that are
call "/usr/lib/openldap/slapd -VVV". Currently these are:
syncprov (the provider part of syncrepl replication)
ppolicy (a LDAP Password Policy implementation)
Documentations for the overlays can be found in the respective man pages
(named "slapo-<overlay-name>") or the OpenLDAP Administration Guide which
is part of the "openldap2-doc" package.

View File

@ -1,8 +1,14 @@
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Nov 9 15:10:53 UTC 2010 - rhafer@novell.com Wed Nov 10 15:35:43 UTC 2010 - rhafer@novell.com
- Surpress gcc warnings about extra format string arguments. - Surpress gcc warnings about extra format string arguments.
- Split-off openldap2-doc (noarch) package (Admin Guide and IDs) - Split-off openldap2-doc (noarch) package (Admin Guide and IDs)
- Backported -VVV commandline switch for slapd from HEAD
(to list enabled static overlays)
- Build all overlays except syncprov and ppolicy as dynamic modules
(Fixes bnc#648479)
- Added README.dynamic-overlays to point out some details dynamice
overlays
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Oct 5 14:39:46 UTC 2010 - rhafer@novell.com Tue Oct 5 14:39:46 UTC 2010 - rhafer@novell.com

View File

@ -51,7 +51,8 @@ Source2: addonschema.tar.gz
Source3: DB_CONFIG Source3: DB_CONFIG
Source4: sasl-slapd.conf Source4: sasl-slapd.conf
Source5: README.update Source5: README.update
Source6: schema2ldif Source6: README.dynamic-overlays
Source7: schema2ldif
Source100: openldap-2.3.37.tar.bz2 Source100: openldap-2.3.37.tar.bz2
Patch1: 0001-build-adjustments.dif Patch1: 0001-build-adjustments.dif
Patch2: 0002-slapd.conf.dif Patch2: 0002-slapd.conf.dif
@ -61,6 +62,7 @@ Patch5: 0005-pie-compile.dif
Patch6: 0006-assorted-fixes-for-back-config-DELETE-support.dif Patch6: 0006-assorted-fixes-for-back-config-DELETE-support.dif
Patch7: 0007-No-Build-date-and-time-in-binaries.dif Patch7: 0007-No-Build-date-and-time-in-binaries.dif
Patch8: 0008-Recover-on-DB-version-change.dif Patch8: 0008-Recover-on-DB-version-change.dif
Patch9: 0009-List-static-overlays-backends-when-with-VVV.dif
Patch100: openldap-2.3.37.dif Patch100: openldap-2.3.37.dif
Patch200: slapd_getaddrinfo_dupl.dif Patch200: slapd_getaddrinfo_dupl.dif
BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRoot: %{_tmppath}/%{name}-%{version}-build
@ -217,10 +219,12 @@ Authors:
%patch6 -p1 %patch6 -p1
%patch7 -p1 %patch7 -p1
%patch8 -p1 %patch8 -p1
%patch9 -p1
%if %suse_version == 1100 %if %suse_version == 1100
%patch200 -p1 %patch200 -p1
%endif %endif
cp %{SOURCE5} . cp %{SOURCE5} .
cp %{SOURCE6} .
cd ../openldap-2.3.37 cd ../openldap-2.3.37
%patch100 %patch100
@ -253,7 +257,9 @@ export STRIP=""
--enable-perl=mod \ --enable-perl=mod \
--enable-sql=mod \ --enable-sql=mod \
--enable-slp \ --enable-slp \
--enable-overlays=yes \ --enable-overlays=mod \
--enable-syncprov=yes \
--enable-ppolicy=yes \
%else %else
--disable-slapd \ --disable-slapd \
%endif %endif
@ -340,7 +346,15 @@ install -d $RPM_BUILD_ROOT/%{DOCDIR}/adminguide \
install -m 644 doc/guide/admin/* $RPM_BUILD_ROOT/%{DOCDIR}/adminguide install -m 644 doc/guide/admin/* $RPM_BUILD_ROOT/%{DOCDIR}/adminguide
install -m 644 doc/guide/images/*.gif $RPM_BUILD_ROOT/%{DOCDIR}/images install -m 644 doc/guide/images/*.gif $RPM_BUILD_ROOT/%{DOCDIR}/images
install -m 644 doc/drafts/* $RPM_BUILD_ROOT/%{DOCDIR}/drafts install -m 644 doc/drafts/* $RPM_BUILD_ROOT/%{DOCDIR}/drafts
install -m 644 ANNOUNCEMENT COPYRIGHT INSTALL LICENSE README CHANGES README.update $RPM_BUILD_ROOT/%{DOCDIR} install -m 644 ANNOUNCEMENT \
COPYRIGHT \
INSTALL \
LICENSE \
README \
CHANGES \
%{SOURCE5} \
%{SOURCE6} \
$RPM_BUILD_ROOT/%{DOCDIR}
rm -f $RPM_BUILD_ROOT/etc/openldap/DB_CONFIG.example rm -f $RPM_BUILD_ROOT/etc/openldap/DB_CONFIG.example
rm -f $RPM_BUILD_ROOT/etc/openldap/schema/README rm -f $RPM_BUILD_ROOT/etc/openldap/schema/README
rm -f $RPM_BUILD_ROOT/var/run/slapd/openldap-data/DB_CONFIG.example rm -f $RPM_BUILD_ROOT/var/run/slapd/openldap-data/DB_CONFIG.example
@ -380,6 +394,24 @@ cat >openldap2.filelist <<EOF
%config(noreplace) /etc/sasl2/slapd.conf %config(noreplace) /etc/sasl2/slapd.conf
%dir /usr/lib/openldap %dir /usr/lib/openldap
%dir /usr/lib/openldap/modules %dir /usr/lib/openldap/modules
/usr/lib/openldap/modules/accesslog*
/usr/lib/openldap/modules/auditlog*
/usr/lib/openldap/modules/collect*
/usr/lib/openldap/modules/constraint*
/usr/lib/openldap/modules/dds*
/usr/lib/openldap/modules/deref*
/usr/lib/openldap/modules/dyngroup*
/usr/lib/openldap/modules/dynlist*
/usr/lib/openldap/modules/memberof*
/usr/lib/openldap/modules/pcache*
/usr/lib/openldap/modules/refint*
/usr/lib/openldap/modules/retcode*
/usr/lib/openldap/modules/rwm*
/usr/lib/openldap/modules/seqmod*
/usr/lib/openldap/modules/sssvlv*
/usr/lib/openldap/modules/translucent*
/usr/lib/openldap/modules/unique*
/usr/lib/openldap/modules/valsort*
/usr/lib/openldap/slapd /usr/lib/openldap/slapd
%dir %attr(0700, ldap, ldap) /var/lib/ldap %dir %attr(0700, ldap, ldap) /var/lib/ldap
%dir %attr(0755, ldap, ldap) %ghost /var/run/slapd %dir %attr(0755, ldap, ldap) %ghost /var/run/slapd
@ -394,13 +426,13 @@ cat >openldap2.filelist <<EOF
%doc %{_mandir}/man5/slapd-monitor.* %doc %{_mandir}/man5/slapd-monitor.*
%doc %{_mandir}/man5/slapd-relay.* %doc %{_mandir}/man5/slapd-relay.*
%doc %{_mandir}/man5/slapo-* %doc %{_mandir}/man5/slapo-*
%dir %{DOCDIR}
%doc %{DOCDIR}/ANNOUNCEMENT %doc %{DOCDIR}/ANNOUNCEMENT
%doc %{DOCDIR}/COPYRIGHT %doc %{DOCDIR}/COPYRIGHT
%doc %{DOCDIR}/INSTALL %doc %{DOCDIR}/INSTALL
%doc %{DOCDIR}/LICENSE %doc %{DOCDIR}/LICENSE
%doc %{DOCDIR}/README %doc %{DOCDIR}/README*
%doc %{DOCDIR}/CHANGES %doc %{DOCDIR}/CHANGES
%doc %{DOCDIR}/README.update
EOF EOF
%if %suse_version < 1130 %if %suse_version < 1130
cat >>openldap2.filelist <<EOF cat >>openldap2.filelist <<EOF
@ -461,6 +493,7 @@ cat > openldap2-back-sql.filelist <<EOF
%doc servers/slapd/back-sql/docs/install %doc servers/slapd/back-sql/docs/install
EOF EOF
cat >openldap2-doc.filelist <<EOF cat >openldap2-doc.filelist <<EOF
%dir %{DOCDIR}
%doc %{DOCDIR}/drafts %doc %{DOCDIR}/drafts
%doc %{DOCDIR}/adminguide %doc %{DOCDIR}/adminguide
%doc %{DOCDIR}/images %doc %{DOCDIR}/images

View File

@ -1,8 +1,14 @@
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Nov 9 15:10:53 UTC 2010 - rhafer@novell.com Wed Nov 10 15:35:43 UTC 2010 - rhafer@novell.com
- Surpress gcc warnings about extra format string arguments. - Surpress gcc warnings about extra format string arguments.
- Split-off openldap2-doc (noarch) package (Admin Guide and IDs) - Split-off openldap2-doc (noarch) package (Admin Guide and IDs)
- Backported -VVV commandline switch for slapd from HEAD
(to list enabled static overlays)
- Build all overlays except syncprov and ppolicy as dynamic modules
(Fixes bnc#648479)
- Added README.dynamic-overlays to point out some details dynamice
overlays
------------------------------------------------------------------- -------------------------------------------------------------------
Tue Oct 5 14:39:46 UTC 2010 - rhafer@novell.com Tue Oct 5 14:39:46 UTC 2010 - rhafer@novell.com

View File

@ -51,7 +51,8 @@ Source2: addonschema.tar.gz
Source3: DB_CONFIG Source3: DB_CONFIG
Source4: sasl-slapd.conf Source4: sasl-slapd.conf
Source5: README.update Source5: README.update
Source6: schema2ldif Source6: README.dynamic-overlays
Source7: schema2ldif
Source100: openldap-2.3.37.tar.bz2 Source100: openldap-2.3.37.tar.bz2
Patch1: 0001-build-adjustments.dif Patch1: 0001-build-adjustments.dif
Patch2: 0002-slapd.conf.dif Patch2: 0002-slapd.conf.dif
@ -61,6 +62,7 @@ Patch5: 0005-pie-compile.dif
Patch6: 0006-assorted-fixes-for-back-config-DELETE-support.dif Patch6: 0006-assorted-fixes-for-back-config-DELETE-support.dif
Patch7: 0007-No-Build-date-and-time-in-binaries.dif Patch7: 0007-No-Build-date-and-time-in-binaries.dif
Patch8: 0008-Recover-on-DB-version-change.dif Patch8: 0008-Recover-on-DB-version-change.dif
Patch9: 0009-List-static-overlays-backends-when-with-VVV.dif
Patch100: openldap-2.3.37.dif Patch100: openldap-2.3.37.dif
Patch200: slapd_getaddrinfo_dupl.dif Patch200: slapd_getaddrinfo_dupl.dif
BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRoot: %{_tmppath}/%{name}-%{version}-build
@ -217,10 +219,12 @@ Authors:
%patch6 -p1 %patch6 -p1
%patch7 -p1 %patch7 -p1
%patch8 -p1 %patch8 -p1
%patch9 -p1
%if %suse_version == 1100 %if %suse_version == 1100
%patch200 -p1 %patch200 -p1
%endif %endif
cp %{SOURCE5} . cp %{SOURCE5} .
cp %{SOURCE6} .
cd ../openldap-2.3.37 cd ../openldap-2.3.37
%patch100 %patch100
@ -253,7 +257,9 @@ export STRIP=""
--enable-perl=mod \ --enable-perl=mod \
--enable-sql=mod \ --enable-sql=mod \
--enable-slp \ --enable-slp \
--enable-overlays=yes \ --enable-overlays=mod \
--enable-syncprov=yes \
--enable-ppolicy=yes \
%else %else
--disable-slapd \ --disable-slapd \
%endif %endif
@ -340,7 +346,15 @@ install -d $RPM_BUILD_ROOT/%{DOCDIR}/adminguide \
install -m 644 doc/guide/admin/* $RPM_BUILD_ROOT/%{DOCDIR}/adminguide install -m 644 doc/guide/admin/* $RPM_BUILD_ROOT/%{DOCDIR}/adminguide
install -m 644 doc/guide/images/*.gif $RPM_BUILD_ROOT/%{DOCDIR}/images install -m 644 doc/guide/images/*.gif $RPM_BUILD_ROOT/%{DOCDIR}/images
install -m 644 doc/drafts/* $RPM_BUILD_ROOT/%{DOCDIR}/drafts install -m 644 doc/drafts/* $RPM_BUILD_ROOT/%{DOCDIR}/drafts
install -m 644 ANNOUNCEMENT COPYRIGHT INSTALL LICENSE README CHANGES README.update $RPM_BUILD_ROOT/%{DOCDIR} install -m 644 ANNOUNCEMENT \
COPYRIGHT \
INSTALL \
LICENSE \
README \
CHANGES \
%{SOURCE5} \
%{SOURCE6} \
$RPM_BUILD_ROOT/%{DOCDIR}
rm -f $RPM_BUILD_ROOT/etc/openldap/DB_CONFIG.example rm -f $RPM_BUILD_ROOT/etc/openldap/DB_CONFIG.example
rm -f $RPM_BUILD_ROOT/etc/openldap/schema/README rm -f $RPM_BUILD_ROOT/etc/openldap/schema/README
rm -f $RPM_BUILD_ROOT/var/run/slapd/openldap-data/DB_CONFIG.example rm -f $RPM_BUILD_ROOT/var/run/slapd/openldap-data/DB_CONFIG.example
@ -380,6 +394,24 @@ cat >openldap2.filelist <<EOF
%config(noreplace) /etc/sasl2/slapd.conf %config(noreplace) /etc/sasl2/slapd.conf
%dir /usr/lib/openldap %dir /usr/lib/openldap
%dir /usr/lib/openldap/modules %dir /usr/lib/openldap/modules
/usr/lib/openldap/modules/accesslog*
/usr/lib/openldap/modules/auditlog*
/usr/lib/openldap/modules/collect*
/usr/lib/openldap/modules/constraint*
/usr/lib/openldap/modules/dds*
/usr/lib/openldap/modules/deref*
/usr/lib/openldap/modules/dyngroup*
/usr/lib/openldap/modules/dynlist*
/usr/lib/openldap/modules/memberof*
/usr/lib/openldap/modules/pcache*
/usr/lib/openldap/modules/refint*
/usr/lib/openldap/modules/retcode*
/usr/lib/openldap/modules/rwm*
/usr/lib/openldap/modules/seqmod*
/usr/lib/openldap/modules/sssvlv*
/usr/lib/openldap/modules/translucent*
/usr/lib/openldap/modules/unique*
/usr/lib/openldap/modules/valsort*
/usr/lib/openldap/slapd /usr/lib/openldap/slapd
%dir %attr(0700, ldap, ldap) /var/lib/ldap %dir %attr(0700, ldap, ldap) /var/lib/ldap
%dir %attr(0755, ldap, ldap) %ghost /var/run/slapd %dir %attr(0755, ldap, ldap) %ghost /var/run/slapd
@ -394,13 +426,13 @@ cat >openldap2.filelist <<EOF
%doc %{_mandir}/man5/slapd-monitor.* %doc %{_mandir}/man5/slapd-monitor.*
%doc %{_mandir}/man5/slapd-relay.* %doc %{_mandir}/man5/slapd-relay.*
%doc %{_mandir}/man5/slapo-* %doc %{_mandir}/man5/slapo-*
%dir %{DOCDIR}
%doc %{DOCDIR}/ANNOUNCEMENT %doc %{DOCDIR}/ANNOUNCEMENT
%doc %{DOCDIR}/COPYRIGHT %doc %{DOCDIR}/COPYRIGHT
%doc %{DOCDIR}/INSTALL %doc %{DOCDIR}/INSTALL
%doc %{DOCDIR}/LICENSE %doc %{DOCDIR}/LICENSE
%doc %{DOCDIR}/README %doc %{DOCDIR}/README*
%doc %{DOCDIR}/CHANGES %doc %{DOCDIR}/CHANGES
%doc %{DOCDIR}/README.update
EOF EOF
%if %suse_version < 1130 %if %suse_version < 1130
cat >>openldap2.filelist <<EOF cat >>openldap2.filelist <<EOF
@ -461,6 +493,7 @@ cat > openldap2-back-sql.filelist <<EOF
%doc servers/slapd/back-sql/docs/install %doc servers/slapd/back-sql/docs/install
EOF EOF
cat >openldap2-doc.filelist <<EOF cat >openldap2-doc.filelist <<EOF
%dir %{DOCDIR}
%doc %{DOCDIR}/drafts %doc %{DOCDIR}/drafts
%doc %{DOCDIR}/adminguide %doc %{DOCDIR}/adminguide
%doc %{DOCDIR}/images %doc %{DOCDIR}/images