if BUILD_DEMO_PLUGIN
-demodir = demo
+demo_dir = demo
endif
if BUILD_SPAMASSASSIN_PLUGIN
-spamassasssindir = spamassassin
+spamassasssin_dir = spamassassin
endif
-SUBDIRS = $(demodir) $(spamassasssindir)
+if BUILD_MATHML_VIEWER_PLUGIN
+mathml_viewer_dir = mathml_viewer
+endif
+
+if BUILD_DILLO_VIEWER_PLUGIN
+dillo_viewer_dir = dillo_viewer
+endif
+
+if BUILD_TRAYICON_PLUGIN
+trayicon_dir = trayicon
+endif
+
+if BUILD_CLAMAV_PLUGIN
+clamav_dir = clamav
+endif
+
+if BUILD_PGPCORE_PLUGIN
+pgpcore_dir = pgpcore
+if BUILD_PGPMIME_PLUGIN
+pgpmime_dir = pgpmime
+endif
+if BUILD_PGPINLINE_PLUGIN
+pgpinline_dir = pgpinline
+endif
+endif
+SUBDIRS = $(demo_dir) \
+ $(spamassasssin_dir) \
+ $(mathml_viewer_dir) \
+ $(dillo_viewer_dir) \
+ $(trayicon_dir) \
+ $(clamav_dir) \
+ $(pgpcore_dir) \
+ $(pgpmime_dir) \
+ $(pgpinline_dir)