Distribute .in files too
[claws.git] / src / plugins / vcalendar / Makefile.am
1 # Makefile.am for "src/plugins/vcalendar" directory
2 # This file is part of Claws Mail package.
3 # See COPYING file for license details.
4
5 appdata_in_files = claws-mail-vcalendar.metainfo.xml.in
6 appdatadir=$(datadir)/appdata
7 appdata_DATA = $(appdata_in_files:.xml.in=.xml)
8
9 @INTLTOOL_XML_RULE@
10
11 SUBDIRS = libical
12 EXTRA_DIST = claws.def plugin.def version.rc $(appdata_DATA) $(appdata_in_files)
13
14 IFLAGS = \
15         -I$(top_srcdir)/src \
16         -I$(top_srcdir)/src/common \
17         -I$(top_builddir)/src/common \
18         -I$(top_srcdir)/src/gtk \
19         -I$(top_srcdir)/src/plugins/vcalendar/libical/libical
20
21 if OS_WIN32
22
23 LTRCCOMPILE = $(LIBTOOL) --mode=compile --tag=RC $(RC) \
24      `echo $(DEFS) $(DEFAULT_INCLUDES) $(IFLAGS) | \
25      sed -e 's/-I/--include-dir /g;s/-D/--define /g'`
26
27 %.lo : %.rc
28         $(LTRCCOMPILE) -i $< -o $@
29
30 plugin_res = version.lo
31 plugin_res_ldflag = -Wl,.libs/version.o
32
33 export_symbols = -export-symbols $(srcdir)/plugin.def
34
35 plugin_deps = libclaws.a $(plugin_res) plugin.def
36
37 libclaws.a: claws.def
38         $(DLLTOOL) --output-lib $@ --def $<
39
40 plugin_ldadd = -L. -lclaws
41
42 else
43 plugin_res =
44 plugin_res_ldflag =
45 export_symbols =
46 plugin_deps =
47 plugin_ldadd =
48 endif
49
50 if PLATFORM_WIN32
51 no_undefined = -no-undefined
52 else
53 no_undefined =
54 endif
55
56 if CYGWIN
57 cygwin_export_lib = -L$(top_builddir)/src -lclaws-mail
58 else
59 cygwin_export_lib = 
60 endif
61
62 plugindir = $(pkglibdir)/plugins
63
64 if BUILD_VCALENDAR_PLUGIN
65 plugin_LTLIBRARIES = vcalendar.la
66 endif
67
68 vcalendar_la_SOURCES = \
69         plugin.c \
70         vcalendar.c vcalendar.h \
71         vcal_manager.c vcal_manager.h \
72         vcal_folder.c vcal_folder.h \
73         vcal_meeting_gtk.c vcal_meeting_gtk.h \
74         vcal_prefs.c vcal_prefs.h \
75         vcal_dbus.c vcal_dbus.h \
76         icaltime_as_local.c icaltime_as_local.h \
77         common-views.c common-views.h \
78         day-view.c month-view.c
79
80 vcalendarincludedir = $(includedir)/claws-mail/plugins/vcalendar
81 vcalendarinclude_HEADERS = \
82         vcal_interface.h
83  
84 vcalendar_la_LDFLAGS = \
85         $(plugin_res_ldflag) $(no_undefined) $(export_symbols) \
86         -avoid-version -module \
87         $(GTK_LIBS)
88
89 vcalendar_la_DEPENDENCIES = $(plugin_deps)
90
91 vcalendar_la_LIBADD = $(plugin_ldadd) $(cygwin_export_lib) \
92         $(GTK_LIBS) \
93         $(CURL_LIBS) \
94         $(top_builddir)/src/plugins/vcalendar/libical/libical/libical.la
95
96 vcalendar_la_CPPFLAGS = \
97         $(IFLAGS) \
98         $(GLIB_CFLAGS) \
99         $(GTK_CFLAGS) \
100         $(CURL_CFLAGS)
101
102 clean-local:
103         rm -f libclaws.a