forked from jengelh/openldap2
f83edd3df7
(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
58 lines
1.6 KiB
Plaintext
58 lines
1.6 KiB
Plaintext
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
|
|
|