[Dovecot] Very minor feature request
Andrey Panin
pazke at donpac.ru
Tue Aug 30 15:17:07 EEST 2005
On 242, 08 30, 2005 at 10:50:57AM +0200, Steffen Kaiser wrote:
> Hello,
>
> I'd suggest a way to get to know the "capabilities" of a compiled Dovecot.
You can try the attached patch.
> The background is that I've run the sequence
>
> ./configure --with-ldap && make && make install
>
> twice, all three commands tell me that all is fine (ldap is listed in the
> modules), but still dovecot told me that ldap is no Usedb module.
>
> A "make clean" before solved the problem -- well, something one should
> anyway.
>
> Besides, the "dovecot --capabilities" should also list all the defaults.
>
> Bye,
>
> --
> Steffen Kaiser
>
--
Andrey Panin | Linux and UNIX system administrator
pazke at donpac.ru | PGP key: wwwkeys.pgp.net
-------------- next part --------------
diff -urdpNX /usr/share/dontdiff dovecot-1.0-test80.vanilla/src/master/main.c dovecot-1.0-test80/src/master/main.c
--- dovecot-1.0-test80.vanilla/src/master/main.c 2005-08-15 02:07:35.000000000 +0400
+++ dovecot-1.0-test80/src/master/main.c 2005-08-30 15:09:21.000000000 +0400
@@ -572,6 +572,95 @@ static void print_help(void)
printf("Usage: dovecot [-F] [-c <config file>]\n");
}
+static void print_capabilities(void)
+{
+ printf("Build options:"
+#ifdef IOLOOP_EPOLL
+ " ioloop=epoll"
+#endif
+#ifdef IOLOOP_POLL
+ " ioloop=poll"
+#endif
+#ifdef IOLOOP_SELECT
+ " ioloop=select"
+#endif
+#ifdef IOLOOP_NOTIFY_DNOTIFY
+ " dnotify"
+#endif
+#ifdef IOLOOP_NOTIFY_INOTIFY
+ " inotify"
+#endif
+#ifdef HAVE_IPV6
+ " ipv6"
+#endif
+#ifdef HAVE_GNUTLS
+ " gnutls"
+#endif
+#ifdef HAVE_OPENSSL
+ " openssl"
+#endif
+#ifdef HAVE_MYSQL
+ " mysql"
+#endif
+#ifdef HAVE_PGSQL
+ " postgresql"
+#endif
+ "\nPassdb: "
+#ifdef PASSDB_BSDAUTH
+ "bsdauth "
+#endif
+#ifdef PASSDB_CHECKPASSWORD
+ "checkpassword "
+#endif
+#ifdef PASSDB_LDAP
+ "ldap "
+#endif
+#ifdef PASSDB_PAM
+ "pam "
+#endif
+#ifdef PASSDB_PASSWD
+ "passwd "
+#endif
+#ifdef PASSDB_PASSWD_FILE
+ "passwd-file "
+#endif
+#ifdef PASSDB_SHADOW
+ "shadow "
+#endif
+#ifdef PASSDB_SQL
+ "sql "
+#endif
+#ifdef PASSDB_VPOPMAIL
+ "vpopmail "
+#endif
+ "\nUserdb: "
+#ifdef USERDB_CHECKPASSWORD
+ "checkpassword "
+#endif
+#ifdef USERDB_LDAP
+ "ldap "
+#endif
+#ifdef USERDB_PASSDB
+ "passdb "
+#endif
+#ifdef USERDB_PASSWD
+ "passwd "
+#endif
+#ifdef USERDB_PASSWD_FILE
+ "passwd-file "
+#endif
+#ifdef USERDB_SQL
+ "sql "
+#endif
+#ifdef USERDB_STATIC
+ "static "
+#endif
+#ifdef USERDB_VPOPMAIL
+ "vpopmail "
+#endif
+ "\n");
+}
+
int main(int argc, char *argv[])
{
/* parse arguments */
@@ -606,6 +695,9 @@ int main(int argc, char *argv[])
} else if (strcmp(argv[i], "--version") == 0) {
printf("%s\n", VERSION);
return 0;
+ } else if (strcmp(argv[i], "--capabilities") == 0) {
+ print_capabilities();
+ return 0;
} else {
print_help();
i_fatal("Unknown argument: %s", argv[1]);
More information about the dovecot
mailing list