585fe4b33dd18bd0505dd65738c6796726eb5c9e
[claws.git] / src / plugins / spam_report / Makefile.am
1 EXTRA_DIST = claws.def plugin.def version.rc
2
3 IFLAGS = \
4         -I$(top_srcdir)/src \
5         -I$(top_srcdir)/src/common \
6         -I$(top_builddir)/src/common \
7         -I$(top_srcdir)/src/gtk
8
9 if OS_WIN32
10
11 LTRCCOMPILE = $(LIBTOOL) --mode=compile --tag=RC $(RC) \
12      `echo $(DEFS) $(DEFAULT_INCLUDES) $(IFLAGS) | \
13      sed -e 's/-I/--include-dir /g;s/-D/--define /g'`
14
15 %.lo : %.rc
16         $(LTRCCOMPILE) -i $< -o $@
17
18 plugin_res = version.lo
19 plugin_res_ldflag = -Wl,.libs/version.o
20
21 export_symbols = -export-symbols $(srcdir)/plugin.def
22
23 plugin_deps = libclaws.a $(plugin_res) plugin.def
24
25 libclaws.a: claws.def
26         $(DLLTOOL) --output-lib $@ --def $<
27
28 plugin_ldadd = -L. -lclaws
29
30 else
31 plugin_res =
32 plugin_res_ldflag =
33 export_symbols =
34 plugin_deps =
35 plugin_ldadd =
36 endif
37
38 if PLATFORM_WIN32
39 no_undefined = -no-undefined
40 else
41 no_undefined =
42 endif
43
44 if CYGWIN
45 cygwin_export_lib = -L$(top_builddir)/src -lclaws-mail
46 else
47 cygwin_export_lib = 
48 endif
49
50 plugindir = $(pkglibdir)/plugins
51
52 if BUILD_SPAM_REPORT_PLUGIN
53 plugin_LTLIBRARIES = spamreport.la
54 endif
55
56 spamreport_la_SOURCES = \
57          spam_report.c \
58          spam_report_prefs.c \
59          spam_report_prefs.h
60
61 spamreport_la_LDFLAGS = \
62         $(plugin_res_ldflag) $(no_undefined) $(export_symbols) \
63         -avoid-version -module \
64         $(GTK_LIBS)
65
66 spamreport_la_LIBADD = $(plugin_ldadd) $(cygwin_export_lib) \
67         $(CURL_LIBS) \
68         $(GTK_LIBS)
69
70 spamreport_la_DEPENDENCIES = $(plugin_deps)
71
72 IFLAGS = \
73         -I$(top_srcdir)/src \
74         -I$(top_srcdir)/src/common \
75         -I$(top_builddir)/src/common \
76         -I$(top_srcdir)/src/gtk
77
78 spamreport_la_CPPFLAGS = \
79         $(IFLAGS) \
80         $(GLIB_CFLAGS) \
81         $(CURL_CFLAGS) \
82         $(GTK_CFLAGS)