/* Initialize */
cnid_init();
- sl_mod_load(_PATH_AFPDUAMPATH "mod_spotlight.so");
+ if (obj.options.flags & OPTION_SPOTLIGHT)
+ sl_mod_load(_PATH_AFPDUAMPATH "mod_spotlight.so");
/* watch atp, dsi sockets and ipc parent/child file descriptor. */
#define OPTION_NOZEROCONF (1 << 9)
#define OPTION_KEEPSESSIONS (1 << 10) /* preserve sessions across master afpd restart with SIGQUIT */
#define OPTION_SHARE_RESERV (1 << 11) /* whether to use Solaris fcntl F_SHARE locks */
-
+#define OPTION_SPOTLIGHT (1 << 12) /* whether to enable Spotlight support */
#define PASSWD_NONE 0
#define PASSWD_SET (1 << 0)
#define PASSWD_NOSAVE (1 << 1)
options->flags |= OPTION_SHARE_RESERV;
if (iniparser_getboolean(config, INISEC_GLOBAL, "afp read locks", 0))
options->flags |= OPTION_AFP_READ_LOCK;
+ if (iniparser_getboolean(config, INISEC_GLOBAL, "spotlight", 0))
+ options->flags |= OPTION_SPOTLIGHT;
if (!iniparser_getboolean(config, INISEC_GLOBAL, "save password", 1))
options->passwdbits |= PASSWD_NOSAVE;
if (iniparser_getboolean(config, INISEC_GLOBAL, "set password", 0))