--- claws-mail-extra-plugins-3.0.1.orig/build_cygwin.sh	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/build_cygwin.sh	2007-09-18 22:32:06.000000000 +0800
@@ -0,0 +1,95 @@
+#!/bin/sh
+prefix=/usr/local
+
+#pkgname=claws-mail-extra-plugins
+#version=3.0.0
+foo=`basename $(pwd)`
+pkgname=`echo $foo | sed -e 's/\-[0-9\.\/]*$//'`
+version=`echo $foo | sed -e "s/${pkgname}\-//" -e 's/\-[^\-]*$//'`
+
+rel=1
+
+TOPDIR=$(pwd)
+DESTDIR=${TOPDIR}/.inst
+DOCDIR=${prefix}/share/doc/${pkgname}
+
+export PKG_CONFIG_PATH=${prefix}/lib/pkgconfig:$PKG_CONFIG_PATH
+
+plugin=""
+
+patch()
+{
+    cd ${TOPDIR}/$plugin* && \
+	/usr/bin/patch -p1 -b < ../CYGWIN-PATCHES/${plugin}.patch
+}
+
+conf()
+{
+   cd ${TOPDIR}/$plugin* && \
+	CFLAGS=-O2 ./configure --prefix=$prefix
+}
+
+build()
+{
+   cd ${TOPDIR}/$plugin* && \
+       make   
+}
+
+install()
+{
+   cd ${TOPDIR}/$plugin* && \
+        make DESTDIR=${TOPDIR}/.inst install &&
+	( [ -d ${TOPDIR}/.inst${DOCDIR} ] || mkdir -p ${TOPDIR}/.inst${DOCDIR}
+	  cp README ${TOPDIR}/.inst${DOCDIR}/README.$plugin
+	)
+}
+
+
+build_plugin()
+{
+   plugin=`echo $1 | sed -e 's/\-[0-9\.\/]*$//'`
+   echo "===== start building plugin $plugin ===="
+   #read foo
+   shift
+  
+  if [ $# -eq 0 ]; then
+     ( patch && conf && build && install )
+  else
+    for action in $*; do
+      case "_$action" in
+        _patch)	patch	;;
+        _conf)	conf	;;
+        _make|_build)	build	;;
+        _install)	install	;;
+        _conf+) (conf && build && install)   ;;
+        _make+) (build && install)   ;;
+        _build+) (build && install)  ;;
+        _|_all)  ( patch && conf && build && install)	;;
+      esac
+    done
+  fi
+}
+
+make_package()
+{
+	echo "Striping DLLs..." && (find $DESTDIR -name '*.dll' | xargs strip )
+	cp README ${TOPDIR}/.inst${DOCDIR}/README
+	tarball=${pkgname}-${version}-${rel}.tar.bz2
+	echo "Packaging files to $tarball ..." && cd $DESTDIR && tar cjf ../$tarball  .${prefix}
+}
+
+
+if [ $# -eq 0 ]; then
+    echo "Usage: $0 all"
+    echo "       $0 plugin [action1 action2]       (Note: don't specify verion number)"
+elif [ foo$1 == foopackage ]; then
+	make_package
+elif [ foo$1 == fooall ]; then    
+	for p in CYGWIN-PATCHES/*.patch; do
+	   b=`basename $p .patch` 
+	   build_plugin $b
+	done
+else
+    build_plugin $*
+fi    	
+
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/att_remover.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/att_remover.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/att_remover.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/att_remover.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,15 @@
+diff -Nurp att_remover-1.0/src/Makefile.in att_remover-1.0/src/Makefile.in
+--- att_remover-1.0/src/Makefile.in	2006-04-06 16:34:50.000000000 +0800
++++ att_remover-1.0/src/Makefile.in	2006-04-23 23:41:22.000000000 +0800
+@@ -197,9 +197,9 @@ att_remover_la_SOURCES = \
+ 	plugin_version.h
+ 
+ att_remover_la_LDFLAGS = \
+-	-avoid-version -module
++	-avoid-version -module -no-undefined
+ 
+-att_remover_la_LIBADD = \
++att_remover_la_LIBADD = -L$(prefix)/lib -lclaws-mail \
+ 	$(GTK_LIBS)
+ 
+ INCLUDES = \
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/attachwarner.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/attachwarner.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/attachwarner.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/attachwarner.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,13 @@
+--- attachwarner-0.2.4/src/Makefile.in.orig	2007-01-17 23:02:48.000000000 +0800
++++ attachwarner-0.2.4/src/Makefile.in	2007-01-17 23:03:24.000000000 +0800
+@@ -210,7 +210,9 @@ target_alias = @target_alias@
+ plugindir = $(CLAWS_MAIL_PLUGINDIR)
+ plugin_LTLIBRARIES = attachwarner.la
+ attachwarner_la_LDFLAGS = \
+-	-avoid-version -module \
++	-avoid-version -module -no-undefined
++
++attachwarner_la_LIBADD = -L${prefix}/lib -lclaws-mail \
+ 	$(GTK_LIBS)
+ 
+ AM_CPPFLAGS = \
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/cachesaver.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/cachesaver.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/cachesaver.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/cachesaver.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,15 @@
+diff -Nurp cachesaver-0.7/src/Makefile.in cachesaver-0.7/src/Makefile.in
+--- cachesaver-0.7/src/Makefile.in	2006-04-06 16:35:34.000000000 +0800
++++ cachesaver-0.7/src/Makefile.in	2006-04-23 23:41:44.000000000 +0800
+@@ -193,7 +193,10 @@ cachesaver_la_SOURCES = \
+ 	plugin_version.h
+ 
+ cachesaver_la_LDFLAGS = \
+-	-avoid-version -module
++	-avoid-version -module -no-undefined
++
++cachesaver_la_LIBADD = -L$(prefix)/lib -lclaws-mail \
++	$(GTK_LIBS)
+ 
+ cachesaver_la_CPPFLAGS = \
+ 	$(SYLPHEED_CLAWS_CFLAGS) \
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/etpan-privacy.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/etpan-privacy.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/etpan-privacy.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/etpan-privacy.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,14 @@
+--- etpan-privacy-0.15.5/src/Makefile.in.orig	2007-01-15 16:58:48.000000000 +0800
++++ etpan-privacy-0.15.5/src/Makefile.in	2007-01-17 23:05:06.000000000 +0800
+@@ -204,7 +204,10 @@ etpan_privacy_la_SOURCES = \
+ 	prefs_privacy.c prefs_privacy.h
+ 
+ etpan_privacy_la_LDFLAGS = \
+-	-avoid-version -module
++	-avoid-version -module -no-undefined
++
++etpan_privacy_la_LIBADD = -L{prefix} -lclaws-mail \
++	$(GTK_LIBS)
+ 
+ etpan_privacy_la_CPPFLAGS = \
+ 	$(CLAWS_MAIL_CFLAGS) \
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/fetchinfo-plugin.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/fetchinfo-plugin.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/fetchinfo-plugin.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/fetchinfo-plugin.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,13 @@
+--- fetchinfo-plugin-0.4.18/src/Makefile.in.orig	2007-01-15 16:59:40.000000000 +0800
++++ fetchinfo-plugin-0.4.18/src/Makefile.in	2007-01-17 23:11:58.000000000 +0800
+@@ -201,7 +201,9 @@ fetchinfo_plugin_la_SOURCES = \
+ 	fetchinfo_plugin_gtk.c
+ 
+ fetchinfo_plugin_la_LDFLAGS = \
+-	-avoid-version -module \
++	-avoid-version -module -no-undefined
++
++fetchinfo_plugin_la_LIBADD = -L${prefix}/lib -lclaws-mail \
+ 	$(GTK_LIBS)
+ 
+ AM_CPPFLAGS = \
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/gtkhtml2_viewer.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/gtkhtml2_viewer.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/gtkhtml2_viewer.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/gtkhtml2_viewer.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,19 @@
+diff -Nurp gtkhtml2_viewer-0.10.1/src/Makefile.in gtkhtml2_viewer-0.10.1/src/Makefile.in
+--- gtkhtml2_viewer-0.10.1/src/Makefile.in	2006-06-12 19:09:52.000000000 +0800
++++ gtkhtml2_viewer-0.10.1/src/Makefile.in	2006-06-17 15:20:58.000000000 +0800
+@@ -217,9 +217,12 @@ gtkhtml2_viewer_la_SOURCES = \
+ 	 gtkhtml2_prefs.h
+ 
+ gtkhtml2_viewer_la_LDFLAGS = \
+-	-avoid-version -module \
+-	$(GTK_LIBS) \
+-	$(GTKHTML2_LIBS)
++	-avoid-version -module -no-undefined
++
++gtkhtml2_viewer_la_LIBADD = \
++	-L$(prefix)/lib -lclaws-mail  \
++	$(GTKHTML2_LIBS)	\
++	$(GTK_LIBS)
+ 
+ INCLUDES = \
+ 	-I$(top_srcdir)/src \
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/maildir.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/maildir.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/maildir.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/maildir.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,38 @@
+diff -Nurp maildir-0.20/src/Makefile.in maildir-0.20/src/Makefile.in
+--- maildir-0.20/src/Makefile.in	2006-04-06 16:39:28.000000000 +0800
++++ maildir-0.20/src/Makefile.in	2006-04-23 23:42:38.000000000 +0800
+@@ -199,10 +199,10 @@ maildir_la_SOURCES = \
+ 	uiddb.c uiddb.h
+ 
+ maildir_la_LDFLAGS = \
+-	-avoid-version -module
++	-avoid-version -module -no-undefined
+ 
+-maildir_la_LIBADD = \
+-	$(DBLIB) 
++maildir_la_LIBADD = -L$(prefix)/lib -lclaws-mail \
++	$(GTK_LIBS) $(DBLIB) 
+ 
+ maildir_la_CPPFLAGS = \
+ 	$(SYLPHEED_CLAWS_CFLAGS) \
+@@ -214,6 +214,9 @@ maildir_gtk_la_CPPFLAGS = \
+ 	$(GLIB_CFLAGS) \
+ 	$(GTK_CFLAGS)
+ 
++maildir_gtk_la_LIBADD = -L$(prefix)/lib -lclaws-mail \
++	$(GTK_LIBS) $(DBLIB)
++
+ AM_CPPFLAGS = \
+ 	$(SYLPHEED_CLAWS_CFLAGS) \
+ 	$(GLIB_CFLAGS) \
+diff -Nurp maildir-0.20/src/maildir.c maildir-0.20/src/maildir.c
+--- maildir-0.20/src/maildir.c	2005-12-08 15:42:08.000000000 +0800
++++ maildir-0.20/src/maildir.c	2006-04-23 23:42:32.000000000 +0800
+@@ -25,6 +25,7 @@
+ 
+ #include <sys/types.h>
+ #include <sys/stat.h>
++#include <sys/time.h>
+ #include <fcntl.h>
+ #include <glob.h>
+ #include <unistd.h>
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/mailmbox.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/mailmbox.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/mailmbox.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/mailmbox.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,15 @@
+diff -Nurp mailmbox-1.11/src/Makefile.in mailmbox-1.11/src/Makefile.in
+--- mailmbox-1.11/src/Makefile.in	2006-04-06 16:40:22.000000000 +0800
++++ mailmbox-1.11/src/Makefile.in	2006-04-23 23:42:48.000000000 +0800
+@@ -215,9 +215,9 @@ mailmbox_la_SOURCES = \
+ 	plugin_version.h plugin_gtk.h
+ 
+ mailmbox_la_LDFLAGS = \
+-	-avoid-version -module
++	-avoid-version -module -no-undefined
+ 
+-mailmbox_la_LIBADD = \
++mailmbox_la_LIBADD = -L$(prefix)/lib -lclaws-mail \
+ 	$(GTK_LIBS)
+ 
+ mailmbox_la_CPPFLAGS = \
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/newmail.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/newmail.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/newmail.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/newmail.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,15 @@
+diff -Nurp newmail-0.0.3/src/Makefile.in newmail-0.0.3/src/Makefile.in
+--- newmail-0.0.3/src/Makefile.in	2006-04-06 16:41:20.000000000 +0800
++++ newmail-0.0.3/src/Makefile.in	2006-04-23 23:43:02.000000000 +0800
+@@ -198,7 +198,10 @@ newmail_la_SOURCES = \
+ 	plugin_version.h
+ 
+ newmail_la_LDFLAGS = \
+-	-avoid-version -module
++	-avoid-version -module -no-undefined
++
++newmail_la_LIBADD = -L$(prefix)/lib -lclaws-mail \
++	$(GTK_LIBS)
+ 
+ AM_CPPFLAGS = \
+         $(SYLPHEED_CLAWS_CFLAGS) \
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/notification_plugin.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/notification_plugin.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/notification_plugin.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/notification_plugin.patch	2007-09-14 23:17:02.000000000 +0800
@@ -0,0 +1,28 @@
+--- notification_plugin-0.4/src/Makefile.in.orig	2006-09-26 01:15:14.000000000 +0800
++++ notification_plugin-0.4/src/Makefile.in	2006-09-28 00:20:08.000000000 +0800
+@@ -218,10 +218,11 @@ notification_plugin_la_SOURCES = \
+ 	raw_sylpheed_claws_logo_64x64.h
+ 
+ notification_plugin_la_LDFLAGS = \
+-	-avoid-version -module
++	-avoid-version -module -no-undefined
+ 
+-notification_plugin_la_LIBADD = \
+-	$(libnotify_LIBS)
++notification_plugin_la_LIBADD = -L$(prefix)/lib -lclaws-mail \
++	$(libnotify_LIBS)					\
++	$(GTK_LIBS)
+ 
+ notification_plugin_la_CPPFLAGS = \
+ 	$(NOTIFY_CFLAGS) \
+--- notification_plugin-0.12/src/notification_lcdproc.c.orig	2007-09-14 23:11:20.000000000 +0800
++++ notification_plugin-0.12/src/notification_lcdproc.c	2007-09-14 23:11:38.000000000 +0800
+@@ -108,7 +108,7 @@ void notification_lcdproc_connect(void)
+ void notification_lcdproc_disconnect(void)
+ {
+   if(sock) {
+-#ifndef G_OS_WIN32
++#ifndef G_PLATFORM_WIN32
+     shutdown(sock->sock, SHUT_RDWR);
+ #endif
+     sock_close(sock);
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/pdf_viewer.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/pdf_viewer.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/pdf_viewer.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/pdf_viewer.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,14 @@
+--- pdf_viewer-0.2/src/Makefile.in.orig	2007-03-02 00:35:46.000000000 +0800
++++ pdf_viewer-0.2/src/Makefile.in	2007-03-02 00:37:16.000000000 +0800
+@@ -221,7 +221,10 @@ pdf_viewer_la_SOURCES = \
+ 	 gettext.h
+ 
+ pdf_viewer_la_LDFLAGS = \
+-	-avoid-version -module \
++	-avoid-version -module -no-undefined 
++
++pdf_viewer_la_LIBADD = \
++	-L$(prefix)/lib -lclaws-mail \
+ 	$(GTK_LIBS) \
+ 	$(POPPLER_LIBS)
+ 
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/rssyl.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/rssyl.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/rssyl.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/rssyl.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,14 @@
+diff -Nurp rssyl-0.4cvs6/src/Makefile.in rssyl-0.4cvs6/src/Makefile.in
+--- rssyl-0.4cvs6/src/Makefile.in	2006-04-06 16:55:58.000000000 +0800
++++ rssyl-0.4cvs6/src/Makefile.in	2006-04-23 23:43:30.000000000 +0800
+@@ -208,7 +208,9 @@ target_alias = @target_alias@
+ plugindir = $(SYLPHEED_CLAWS_PLUGINDIR)
+ plugin_LTLIBRARIES = rssyl.la
+ rssyl_la_LDFLAGS = \
+-	-avoid-version -module \
++	-avoid-version -module -no-undefined
++	
++rssyl_la_LIBADD = -L$(prefix)/lib -lclaws-mail \
+ 	$(GTK_LIBS)
+ 
+ AM_CPPFLAGS = \
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/smime.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/smime.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/smime.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/smime.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,16 @@
+diff -Nurp smime-0.5/src/Makefile.in smime-0.5/src/Makefile.in
+--- smime-0.5/src/Makefile.in	2006-04-07 01:42:46.000000000 +0800
++++ smime-0.5/src/Makefile.in	2006-04-23 23:43:38.000000000 +0800
+@@ -202,9 +202,10 @@ smime_la_SOURCES = \
+ 	plugin_version.h
+ 
+ smime_la_LDFLAGS = \
+-	-avoid-version -module
++	-avoid-version -module -no-undefined
+ 
+-smime_la_LIBADD = \
++smime_la_LIBADD = -L$(prefix)/lib -lclaws-mail \
++	$(prefix)/lib/claws-mail/plugins/pgpcore.la \
+ 	$(GTK_LIBS) \
+ 	$(GPGME_LIBS)
+ 
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/spam_report.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/spam_report.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/spam_report.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/spam_report.patch	2007-09-14 22:44:36.000000000 +0800
@@ -0,0 +1,13 @@
+--- spam_report-0.2/src/Makefile.in.orig	2007-09-14 22:29:00.000000000 +0800
++++ spam_report-0.2/src/Makefile.in	2007-09-14 22:29:56.000000000 +0800
+@@ -220,7 +220,9 @@ spamreport_la_SOURCES = \
+ 	 gettext.h
+ 
+ spamreport_la_LDFLAGS = \
+-	-avoid-version -module \
++	-avoid-version -module -no-undefined
++
++spamreport_la_LIBADD = -L$(prefix)/lib -lclaws-mail \
+ 	$(GTK_LIBS)
+ 
+ INCLUDES = \
diff -Nurp claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/vcalendar.patch claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/vcalendar.patch
--- claws-mail-extra-plugins-3.0.1.orig/CYGWIN-PATCHES/vcalendar.patch	1970-01-01 08:00:00.000000000 +0800
+++ claws-mail-extra-plugins-3.0.1/CYGWIN-PATCHES/vcalendar.patch	2007-09-14 21:56:36.000000000 +0800
@@ -0,0 +1,18 @@
+--- vcalendar-1.94/src/Makefile.in.orig	2007-02-27 01:57:52.000000000 +0800
++++ vcalendar-1.94/src/Makefile.in	2007-03-02 00:09:08.000000000 +0800
+@@ -236,11 +236,12 @@ vcalendar_la_SOURCES = \
+ 	gettext.h
+ 
+ vcalendar_la_LDFLAGS = \
+-	-avoid-version -module \
+-	$(GTK_LIBS)
++	-avoid-version -module -no-undefined
+ 
+ vcalendar_la_LIBADD = \
+-        $(top_srcdir)/libical/libical/libical.la
++        $(top_srcdir)/libical/libical/libical.la \
++	-L$(prefix)/lib -lclaws-mail \
++	$(GTK_LIBS)
+ 
+ AM_CPPFLAGS = \
+ 	$(CLAWS_MAIL_CFLAGS) \
