From bf204ec2de3747c2ee8023a968bb89dc2c613e4e Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Mon, 14 Dec 2009 20:34:44 -0500 Subject: [PATCH] OSX: Don't try add plugin dependencies. It just breaks plugin loading. --HG-- branch : HEAD --- configure.in | 6 ++++++ src/plugins/fts-solr/Makefile.am | 6 +++++- src/plugins/fts-squat/Makefile.am | 2 ++ src/plugins/imap-acl/Makefile.am | 2 ++ src/plugins/imap-quota/Makefile.am | 2 ++ src/plugins/mail-log/Makefile.am | 2 ++ src/plugins/trash/Makefile.am | 2 ++ 7 files changed, 21 insertions(+), 1 deletion(-) diff --git a/configure.in b/configure.in index 51fcffb081..3ff4555351 100644 --- a/configure.in +++ b/configure.in @@ -580,6 +580,7 @@ if test $i_cv_posix_fallocate_works = yes; then fi dnl * OS specific options +have_plugin_deps=yes case "$host_os" in hpux*) CFLAGS="$CFLAGS -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED" @@ -591,9 +592,14 @@ case "$host_os" in linux*) AC_DEFINE(PROCTITLE_HACK,, Define if process title can be changed by modifying argv) ;; + darwin*) + # OSX loads the plugins twice, which breaks stuff + have_plugin_deps=no + ;; *) ;; esac +AM_CONDITIONAL(PLUGIN_DEPS, test "$have_plugin_deps" = "yes") AC_CHECK_SIZEOF(int) AC_CHECK_SIZEOF(long) diff --git a/src/plugins/fts-solr/Makefile.am b/src/plugins/fts-solr/Makefile.am index f09a6663be..4cc74db481 100644 --- a/src/plugins/fts-solr/Makefile.am +++ b/src/plugins/fts-solr/Makefile.am @@ -11,8 +11,12 @@ lib21_fts_solr_plugin_la_LDFLAGS = -module -avoid-version module_LTLIBRARIES = \ lib21_fts_solr_plugin.la +if PLUGIN_DEPS +fts_plugin_dep = ../fts/lib20_fts_plugin.la +endif + lib21_fts_solr_plugin_la_LIBADD = \ - ../fts/lib20_fts_plugin.la \ + $(fts_plugin_dep) \ $(CURL_LIBS) -lexpat lib21_fts_solr_plugin_la_SOURCES = \ diff --git a/src/plugins/fts-squat/Makefile.am b/src/plugins/fts-squat/Makefile.am index e9296f0409..f1393baefb 100644 --- a/src/plugins/fts-squat/Makefile.am +++ b/src/plugins/fts-squat/Makefile.am @@ -10,8 +10,10 @@ lib21_fts_squat_plugin_la_LDFLAGS = -module -avoid-version module_LTLIBRARIES = \ lib21_fts_squat_plugin.la +if PLUGIN_DEPS lib21_fts_squat_plugin_la_LIBADD = \ ../fts/lib20_fts_plugin.la +endif lib21_fts_squat_plugin_la_SOURCES = \ fts-squat-plugin.c \ diff --git a/src/plugins/imap-acl/Makefile.am b/src/plugins/imap-acl/Makefile.am index 82dade93ee..d778c2a5d0 100644 --- a/src/plugins/imap-acl/Makefile.am +++ b/src/plugins/imap-acl/Makefile.am @@ -14,8 +14,10 @@ lib02_imap_acl_plugin_la_LDFLAGS = -module -avoid-version imap_module_LTLIBRARIES = \ lib02_imap_acl_plugin.la +if PLUGIN_DEPS lib02_imap_acl_plugin_la_LIBADD = \ ../acl/lib01_acl_plugin.la +endif lib02_imap_acl_plugin_la_SOURCES = \ imap-acl-plugin.c diff --git a/src/plugins/imap-quota/Makefile.am b/src/plugins/imap-quota/Makefile.am index 2a81ec2677..c459398201 100644 --- a/src/plugins/imap-quota/Makefile.am +++ b/src/plugins/imap-quota/Makefile.am @@ -13,8 +13,10 @@ lib11_imap_quota_plugin_la_LDFLAGS = -module -avoid-version imap_module_LTLIBRARIES = \ lib11_imap_quota_plugin.la +if PLUGIN_DEPS lib11_imap_quota_plugin_la_LIBADD = \ ../quota/lib10_quota_plugin.la +endif lib11_imap_quota_plugin_la_SOURCES = \ imap-quota-plugin.c diff --git a/src/plugins/mail-log/Makefile.am b/src/plugins/mail-log/Makefile.am index c0a0706f0b..59863b5699 100644 --- a/src/plugins/mail-log/Makefile.am +++ b/src/plugins/mail-log/Makefile.am @@ -13,8 +13,10 @@ lib20_mail_log_plugin_la_LDFLAGS = -module -avoid-version module_LTLIBRARIES = \ lib20_mail_log_plugin.la +if PLUGIN_DEPS lib20_mail_log_plugin_la_LIBADD = \ ../notify/lib15_notify_plugin.la +endif lib20_mail_log_plugin_la_SOURCES = \ mail-log-plugin.c diff --git a/src/plugins/trash/Makefile.am b/src/plugins/trash/Makefile.am index cf719a0e53..710c8a9869 100644 --- a/src/plugins/trash/Makefile.am +++ b/src/plugins/trash/Makefile.am @@ -10,8 +10,10 @@ lib11_trash_plugin_la_LDFLAGS = -module -avoid-version module_LTLIBRARIES = \ lib11_trash_plugin.la +if PLUGIN_DEPS lib11_trash_plugin_la_LIBADD = \ ../quota/lib10_quota_plugin.la +endif lib11_trash_plugin_la_SOURCES = \ trash-plugin.c -- 2.47.3