]> git.0d.be Git - empathy.git/blob - src/Makefile.am
Port to libnotify 0.7.0
[empathy.git] / src / Makefile.am
1 include $(top_srcdir)/tools/flymake.mk
2
3 CPPFLAGS_COMMON =                                       \
4         $(EMPATHY_CFLAGS)                               \
5         $(EDS_CFLAGS)                                   \
6         $(GTK_CFLAGS)                                   \
7         $(ERROR_CFLAGS)                                 \
8         -I$(top_srcdir)                                 \
9         -DG_LOG_DOMAIN=\"empathy\"                      \
10         -DBIN_DIR=\"$(bindir)\"                         \
11         $(DISABLE_DEPRECATED)                           \
12         $(WARN_CFLAGS)                                  \
13         $(NULL)
14
15 AM_LDFLAGS = -lm
16 AM_CPPFLAGS =                                           \
17         $(CPPFLAGS_COMMON)                              \
18         $(LIBNOTIFY_CFLAGS)                             \
19         $(LIBCHAMPLAIN_CFLAGS)                          \
20         $(WEBKIT_CFLAGS)                                \
21         $(NULL)
22
23 LDADD =                                                         \
24         $(top_builddir)/libempathy-gtk/libempathy-gtk.la        \
25         $(top_builddir)/libempathy/libempathy.la                \
26         $(top_builddir)/extensions/libemp-extensions.la         \
27         $(LIBNOTIFY_LIBS)                                       \
28         $(EMPATHY_LIBS)                                         \
29         $(GTK_LIBS)                                             \
30         $(LIBCHAMPLAIN_LIBS)                                    \
31         $(WEBKIT_LIBS)
32
33 noinst_LTLIBRARIES = libempathy-accounts-common.la
34
35 libempathy_accounts_common_la_SOURCES =                                 \
36         empathy-accounts-common.c empathy-accounts-common.h             \
37         empathy-account-assistant.c empathy-account-assistant.h         \
38         empathy-accounts-dialog.c empathy-accounts-dialog.h             \
39         empathy-auto-salut-account-helper.c empathy-auto-salut-account-helper.h \
40         empathy-import-dialog.c empathy-import-dialog.h                 \
41         empathy-import-pidgin.c empathy-import-pidgin.h                 \
42         empathy-import-widget.c empathy-import-widget.h                 \
43         empathy-import-utils.c empathy-import-utils.h                   \
44         $(NULL)
45
46 libempathy_accounts_common_la_LIBADD =                                  \
47         $(top_builddir)/libempathy-gtk/libempathy-gtk.la                \
48         $(EDS_LIBS)                                                     \
49         $(LIBNOTIFY_LIBS)                                               \
50         $(EMPATHY_LIBS)                                                 \
51         $(LIBCHAMPLAIN_LIBS)                                            \
52         $(WEBKIT_LIBS)                                                  \
53         $(NULL)
54
55 if HAVE_CONTROL_CENTER_EMBEDDING
56 ccmodulesdir = $(CONTROL_CENTER_EXTENSIONDIR)
57 ccmodules_LTLIBRARIES = libempathy-accounts-panel.la
58
59 libempathy_accounts_panel_la_SOURCES =                          \
60         empathy-accounts-module.c                               \
61         cc-empathy-accounts-panel.c                             \
62         cc-empathy-accounts-panel.h                             \
63         $(NULL)
64
65 libempathy_accounts_panel_la_CPPFLAGS =                         \
66         $(CPPFLAGS_COMMON)                                      \
67         $(CONTROL_CENTER_EMBEDDING_CFLAGS)                      \
68         -DLOCALEDIR=\""$(datadir)/locale"\"                     \
69         $(NULL)
70
71 libempathy_accounts_panel_la_LDFLAGS = -export_dynamic -avoid-version -module -no-undefined -export-symbols-regex '^g_io_module_(load|unload)'
72
73 libempathy_accounts_panel_la_LIBADD =                           \
74         $(EMPATHY_LIBS)                                         \
75         $(CONTROL_CENTER_EMBEDDING_LIBS)                        \
76         libempathy-accounts-common.la                           \
77         $(NULL)
78 endif
79
80 bin_PROGRAMS =                  \
81         empathy                 \
82         empathy-accounts        \
83         empathy-debugger        \
84         $(NULL)
85
86 libexec_PROGRAMS = \
87         empathy-av \
88         empathy-auth-client
89
90 BUILT_SOURCES=
91
92 empathy_accounts_SOURCES =                                              \
93         empathy-accounts.c empathy-accounts.h                           \
94         $(NULL)
95
96 empathy_accounts_LDADD =                                                \
97         $(LDADD)                                                        \
98         libempathy-accounts-common.la                                   \
99         $(NULL)
100
101 empathy_debugger_SOURCES =                                              \
102         empathy-debug-window.c empathy-debug-window.h                   \
103         empathy-debugger.c                                              \
104         $(NULL)
105
106 empathy_handwritten_av_source = \
107         empathy-av.c \
108         empathy-call-window-fullscreen.c empathy-call-window-fullscreen.h \
109         empathy-call-window.c empathy-call-window.h      \
110         $(NULL)
111
112 empathy_av_SOURCES =                                            \
113         $(empathy_handwritten_av_source) \
114         ev-sidebar.c ev-sidebar.h
115
116 empathy_auth_client_SOURCES =                                           \
117         empathy-auth-client.c
118
119 empathy_handwritten_source = \
120         empathy-about-dialog.c empathy-about-dialog.h                   \
121         empathy-chat-window.c empathy-chat-window.h                     \
122         empathy-chatrooms-window.c empathy-chatrooms-window.h           \
123         empathy-event-manager.c empathy-event-manager.h                 \
124         empathy-ft-manager.c empathy-ft-manager.h                       \
125         empathy-invite-participant-dialog.c empathy-invite-participant-dialog.h \
126         empathy-main-window.c empathy-main-window.h                     \
127         empathy-migrate-butterfly-logs.c empathy-migrate-butterfly-logs.h \
128         empathy-new-chatroom-dialog.c empathy-new-chatroom-dialog.h     \
129         empathy-preferences.c empathy-preferences.h                     \
130         empathy-status-icon.c empathy-status-icon.h                     \
131         empathy-chat-manager.c empathy-chat-manager.h                   \
132         empathy.c
133
134 empathy_SOURCES =                                                       \
135         $(empathy_handwritten_source)                                   \
136         $(NULL)
137
138 empathy_LDADD =                                                         \
139         libempathy-accounts-common.la                                   \
140         $(top_builddir)/libempathy-gtk/libempathy-gtk.la                \
141         $(top_builddir)/libempathy/libempathy.la                        \
142         $(top_builddir)/extensions/libemp-extensions.la                 \
143         $(LIBNOTIFY_LIBS)                                               \
144         $(EMPATHY_LIBS)                                                 \
145         $(LIBCHAMPLAIN_LIBS)                                            \
146         $(WEBKIT_LIBS)                                                  \
147         $(NULL)
148
149 nodist_empathy_SOURCES = $(BUILT_SOURCES)
150
151 check_c_sources = \
152     $(empathy_handwritten_source) \
153     $(empathy_logs_SOURCES) \
154     $(empathy_handwritten_av_source)
155
156 include $(top_srcdir)/tools/check-coding-style.mk
157 check-local: check-coding-style
158
159 uidir = $(datadir)/empathy
160 ui_DATA =                                       \
161         empathy-accounts-dialog.ui              \
162         empathy-call-window-fullscreen.ui       \
163         empathy-call-window.ui                  \
164         empathy-chat-window.ui                  \
165         empathy-chatrooms-window.ui             \
166         empathy-ft-manager.ui                   \
167         empathy-import-dialog.ui                \
168         empathy-main-window.ui                  \
169         empathy-new-chatroom-dialog.ui          \
170         empathy-preferences.ui                  \
171         empathy-status-icon.ui
172
173 EXTRA_DIST =                    \
174         $(autostart_DATA)       \
175         $(ui_DATA)
176
177 if HAVE_LIBCHAMPLAIN
178 empathy_handwritten_source +=                           \
179         empathy-map-view.c                      \
180         empathy-map-view.h
181
182 ui_DATA +=                                      \
183         empathy-map-view.ui
184 else
185 EXTRA_DIST +=                                   \
186         empathy-map-view.c                      \
187         empathy-map-view.h                      \
188         empathy-map-view.ui
189 endif
190
191 if !HAVE_CONTROL_CENTER_EMBEDDING
192 EXTRA_DIST += $(libempathy_accounts_panel_la_SOURCES)
193 else
194 check_c_sources += $(libempathy_accounts_panel_la_SOURCES)
195 endif
196
197 dist_man_MANS =                 \
198         empathy.1 \
199         empathy-accounts.1
200
201 # rules for making the glib enum objects
202 %-enumtypes.h: %.h Makefile.in
203         $(AM_V_GEN)glib-mkenums \
204         --fhead "#ifndef __$(shell echo $* | tr [:lower:]- [:upper:]_)_ENUM_TYPES_H__\n#define __$(shell echo $* | tr [:lower:]- [:upper:]_)_ENUM_TYPES_H__\n\n#include <glib-object.h>\n\nG_BEGIN_DECLS\n" \
205         --fprod "/* enumerations from \"@filename@\" */\n" \
206         --vhead "GType @enum_name@_get_type (void);\n#define $(shell echo $* | tr [:lower:]- [:upper:]_ | sed 's/_.*//')_TYPE_@ENUMSHORT@ (@enum_name@_get_type())\n"         \
207         --ftail "G_END_DECLS\n\n#endif /* __$(shell echo $* | tr [:lower:]- [:upper:]_)_ENUM_TYPES_H__ */" \
208         $< > $@
209
210 %-enumtypes.c: %.h Makefile.in
211         $(AM_V_GEN)glib-mkenums \
212         --fhead "#include <$*.h>\n#include <$*-enumtypes.h>" \
213         --fprod "\n/* enumerations from \"@filename@\" */" \
214         --vhead "GType\n@enum_name@_get_type (void)\n{\n  static GType etype = 0;\n  if (etype == 0) {\n    static const G@Type@Value values[] = {"     \
215         --vprod "      { @VALUENAME@, \"@VALUENAME@\", \"@VALUENAME@\" }," \
216         --vtail "      { 0, NULL, NULL }\n    };\n    etype = g_@type@_register_static (\"@EnumName@\", values);\n  }\n  return etype;\n}\n" \
217         $< > $@
218
219 CLEANFILES = $(BUILT_SOURCES)
220