Add configure option --{en,dis}able-unmatched-vfolder.

TODO: Make this a runtime-switchable user configuration option.

diff --git a/camel/camel-vee-store.c b/camel/camel-vee-store.c
index 5e34075..0a32db6 100644
--- a/camel/camel-vee-store.c
+++ b/camel/camel-vee-store.c
@@ -107,7 +107,7 @@ construct (CamelService *service, CamelSession *session, CamelProvider *provider
 	 ((CamelServiceClass *) camel_vee_store_parent)->construct(service, session, provider, url, ex);
 
 	/* Set up unmatched folder */
-#ifndef VEE_UNMATCHED_ENABLE
+#ifndef VEE_UNMATCHED_DISABLE
 	obj->unmatched_uids = g_hash_table_new (g_str_hash, g_str_equal);
 	obj->folder_unmatched = (CamelVeeFolder *)camel_object_new (camel_vee_folder_get_type ());
 	camel_vee_folder_construct (obj->folder_unmatched, store, CAMEL_UNMATCHED_NAME, _("Unmatched"), CAMEL_STORE_FOLDER_PRIVATE);
@@ -339,6 +339,7 @@ vee_get_folder_info(CamelStore *store, const gchar *top, guint32 flags, CamelExc
 	g_ptr_array_free(folders, TRUE);
 	g_hash_table_destroy(infos_hash);
 
+#ifndef VEE_UNMATCHED_DISABLE
 	/* and always add UNMATCHED, if scanning from top/etc */
 	/* FIXME[disk-summary] comment it out well */
 	if ((top == NULL || top[0] == 0 || strncmp(top, CAMEL_UNMATCHED_NAME, strlen(CAMEL_UNMATCHED_NAME)) == 0)) {
@@ -363,6 +364,7 @@ vee_get_folder_info(CamelStore *store, const gchar *top, guint32 flags, CamelExc
 			tail->next = info;
 		}
 	}
+#endif
 
 	return res;
 }
diff --git a/configure.ac b/configure.ac
index 6eb692d..3d79bea 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1425,6 +1425,16 @@ if test "x$GPERF" = "xno"; then
   AC_MSG_ERROR([You need gperf to build evolution-data-server])
 fi
 
+AC_MSG_CHECKING([whether to enable the "Unmatched" mail vfolder])
+AC_ARG_ENABLE([unmatched-vfolder],
+	AS_HELP_STRING([--disable-unmatched-vfolder],
+	[Disable the "Unmatched" mail vfolder]),
+	[],[enable_unmatched_vfolder=yes])
+if test "x$enable_unmatched_vfolder" = "xno"; then
+	AC_DEFINE(VEE_UNMATCHED_DISABLE,1,[Define if the "Unmatched" mail vfolder should be disabled])
+fi
+AC_MSG_RESULT([$enable_unmatched_vfolder])
+
 dnl ******************************
 dnl Makefiles
 dnl ******************************
