2011-08-29 [colin] 3.7.10cvs6
[claws.git] / src / plugins / pgpmime / Makefile.am
1 EXTRA_DIST = version.rc plugin.def claws.def mypgpcore.def pgpmime.deps
2
3 if OS_WIN32
4
5 LTRCCOMPILE = $(LIBTOOL) --mode=compile $(RC) \
6      `echo $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) | \
7      sed -e 's/-I/--include-dir /g;s/-D/--define /g'`
8
9 %.lo : %.rc
10         $(LTRCCOMPILE) -i $< -o $@
11
12 plugin_res = version.lo
13 plugin_res_ldflag = -Wl,.libs/version.o
14
15 export_symbols = -export-symbols $(srcdir)/plugin.def
16
17 plugin_deps = libclaws.a libmypgpcore.a $(plugin_res) plugin.def
18
19 libclaws.a: claws.def
20         $(DLLTOOL) --output-lib $@ --def $<
21
22 libmypgpcore.a: mypgpcore.def
23         $(DLLTOOL) --output-lib $@ --def $<
24
25 plugin_ldadd = -L. -lclaws -lmypgpcore
26
27 else
28 plugin_res =
29 plugin_res_ldflag =
30 export_symbols =
31 plugin_deps =
32 plugin_ldadd =
33 endif
34
35 if PLATFORM_WIN32
36 no_undefined = -no-undefined
37 else
38 no_undefined =
39 endif
40
41 if CYGWIN
42 cygwin_export_lib = -L$(top_builddir)/src -lclaws-mail
43 pgpcore_lib = ../pgpcore/pgpcore.la
44 else
45 pgpcore_lib = 
46 endif
47
48 plugindir = $(pkglibdir)/plugins
49 plugin_DATA=pgpmime.deps
50
51 plugin_LTLIBRARIES = pgpmime.la
52
53
54 pgpmime_la_SOURCES = \
55         plugin.c \
56         pgpmime.c
57
58 pluginincludedir = $(pkgincludedir)/plugins/pgpmime
59 plugininclude_HEADERS = \
60         pgpmime.h 
61
62 pgpmime_la_LDFLAGS = \
63         $(plugin_res_ldflag) $(no_undefined) $(export_symbols) \
64         -avoid-version -module 
65 pgpmime_la_DEPENDENCIES = $(plugin_deps)
66 pgpmime_la_LIBADD = $(plugin_ldadd) $(pgpcore_lib) $(cygwin_export_lib) \
67         $(GTK_LIBS) \
68         $(GPGME_LIBS) \
69         $(MAEMO_LIBS) \
70         $(CONIC_LIBS) \
71         $(ENCHANT_LIBS)
72
73 INCLUDES = \
74         -I$(top_srcdir)/src \
75         -I$(top_srcdir)/src/common \
76         -I$(top_builddir)/src/common \
77         -I$(top_srcdir)/src/gtk
78
79 AM_CPPFLAGS = \
80         $(GLIB_CFLAGS) \
81         $(GTK_CFLAGS) \
82         $(GPGME_CFLAGS) \
83         $(MAEMO_CFLAGS) \
84         $(CONIC_CFLAGS) \
85         $(ENCHANT_CFLAGS) \
86         -Wno-deprecated-declarations
87
88 clean-local:
89         rm -f libclaws.a