]> git.0d.be Git - empathy.git/blob - libempathy-gtk/Makefile.am
baa5a556cdcf208cb768721b3d2c52b78be02539
[empathy.git] / libempathy-gtk / Makefile.am
1 SUBDIRS = egg-list-box
2
3 include $(top_srcdir)/tools/flymake.mk
4
5 AM_CPPFLAGS =                                           \
6         $(ERROR_CFLAGS)                                 \
7         -I$(top_srcdir)/libempathy                      \
8         -I$(top_srcdir)/extensions                      \
9         -DDATADIR=\""$(datadir)"\"                      \
10         -DPKGDATADIR=\""$(pkgdatadir)"\"                \
11         -DGCR_API_SUBJECT_TO_CHANGE                     \
12         $(EMPATHY_CFLAGS)                               \
13         $(TPAW_CFLAGS)                                  \
14         $(YELL_CFLAGS)                                  \
15         $(ENCHANT_CFLAGS)                               \
16         $(LIBCHAMPLAIN_CFLAGS)                          \
17         $(GEOCLUE_CFLAGS)                               \
18         $(GEOCODE_CFLAGS)                               \
19         $(MEEGO_CFLAGS)                                 \
20         $(CHEESE_CFLAGS)                                \
21         $(EGGLISTBOX_CFLAGS)                                    \
22         $(WARN_CFLAGS)                                  \
23         $(DISABLE_DEPRECATED)
24
25 BUILT_SOURCES =                                         \
26         empathy-gtk-enum-types.h                        \
27         empathy-gtk-enum-types.c
28
29 libempathy_gtk_handwritten_source =             \
30         empathy-account-chooser.c               \
31         empathy-account-selector-dialog.c               \
32         empathy-avatar-image.c                  \
33         empathy-bad-password-dialog.c           \
34         empathy-base-password-dialog.c          \
35         empathy-call-utils.c                    \
36         empathy-cell-renderer-activatable.c     \
37         empathy-cell-renderer-expander.c        \
38         empathy-cell-renderer-text.c            \
39         empathy-chat.c                          \
40         empathy-contact-blocking-dialog.c       \
41         empathy-contact-chooser.c               \
42         empathy-contact-search-dialog.c         \
43         empathy-contact-widget.c                \
44         empathy-dialpad-widget.c                \
45         empathy-dialpad-button.c                \
46         empathy-geometry.c                      \
47         empathy-groups-widget.c                 \
48         empathy-individual-dialogs.c            \
49         empathy-individual-edit-dialog.c        \
50         empathy-individual-information-dialog.c \
51         empathy-individual-menu.c               \
52         empathy-individual-store.c              \
53         empathy-individual-store-channel.c              \
54         empathy-individual-store-manager.c              \
55         empathy-individual-view.c               \
56         empathy-individual-widget.c             \
57         empathy-input-text-view.c               \
58         empathy-local-xmpp-assistant-widget.c \
59         empathy-log-window.c                    \
60         empathy-new-account-dialog.c            \
61         empathy-new-message-dialog.c            \
62         empathy-new-call-dialog.c               \
63         empathy-notify-manager.c                \
64         empathy-password-dialog.c               \
65         empathy-presence-chooser.c              \
66         empathy-protocol-chooser.c              \
67         empathy-roster-contact.c                        \
68         empathy-roster-group.c                  \
69         empathy-roster-model.c                  \
70         empathy-roster-model-aggregator.c                       \
71         empathy-roster-model-manager.c                  \
72         empathy-roster-view.c                   \
73         empathy-search-bar.c                    \
74         empathy-share-my-desktop.c              \
75         empathy-smiley-manager.c                \
76         empathy-sound-manager.c                 \
77         empathy-spell.c                         \
78         empathy-status-preset-dialog.c          \
79         empathy-string-parser.c                 \
80         empathy-subscription-dialog.c   \
81         empathy-theme-manager.c                 \
82         empathy-tls-dialog.c                    \
83         empathy-ui-utils.c                      \
84         empathy-plist.c                         \
85         empathy-theme-adium.c                   \
86         empathy-webkit-utils.c                  \
87         $(NULL)
88
89 libempathy_gtk_headers =                        \
90         empathy-account-chooser.h               \
91         empathy-account-selector-dialog.h               \
92         empathy-avatar-image.h                  \
93         empathy-bad-password-dialog.h           \
94         empathy-base-password-dialog.h          \
95         empathy-call-utils.h                    \
96         empathy-cell-renderer-activatable.h     \
97         empathy-cell-renderer-expander.h        \
98         empathy-cell-renderer-text.h            \
99         empathy-chat.h                          \
100         empathy-contact-blocking-dialog.h       \
101         empathy-contact-chooser.h               \
102         empathy-contact-search-dialog.h         \
103         empathy-contact-widget.h                \
104         empathy-dialpad-widget.h                \
105         empathy-dialpad-button.h                \
106         empathy-geometry.h                      \
107         empathy-groups-widget.h                 \
108         empathy-images.h                        \
109         empathy-individual-dialogs.h            \
110         empathy-individual-edit-dialog.h        \
111         empathy-individual-information-dialog.h \
112         empathy-individual-menu.h               \
113         empathy-individual-store.h              \
114         empathy-individual-store-channel.h              \
115         empathy-individual-store-manager.h              \
116         empathy-individual-view.h               \
117         empathy-individual-widget.h             \
118         empathy-input-text-view.h               \
119         empathy-local-xmpp-assistant-widget.h \
120         empathy-log-window.h                    \
121         empathy-new-account-dialog.h            \
122         empathy-new-message-dialog.h            \
123         empathy-new-call-dialog.h               \
124         empathy-notify-manager.h                \
125         empathy-password-dialog.h               \
126         empathy-presence-chooser.h              \
127         empathy-protocol-chooser.h              \
128         empathy-roster-contact.h                        \
129         empathy-roster-group.h                  \
130         empathy-roster-model.h                  \
131         empathy-roster-model-aggregator.h                       \
132         empathy-roster-model-manager.h                  \
133         empathy-roster-view.h                   \
134         empathy-search-bar.h                    \
135         empathy-share-my-desktop.h              \
136         empathy-smiley-manager.h                \
137         empathy-sound-manager.h                 \
138         empathy-spell.h                         \
139         empathy-status-preset-dialog.h          \
140         empathy-string-parser.h                 \
141         empathy-subscription-dialog.h   \
142         empathy-theme-manager.h                 \
143         empathy-tls-dialog.h                    \
144         empathy-ui-utils.h                      \
145         empathy-plist.h                         \
146         empathy-theme-adium.h                   \
147         empathy-webkit-utils.h                  \
148         $(NULL)
149
150 pkglib_LTLIBRARIES = libempathy-gtk.la
151
152 # libempathy-gtk's API is not stable and will never be, so use -release to make the
153 # SONAME of the plugin library change with every Empathy release.
154 libempathy_gtk_la_LDFLAGS = \
155    -no-undefined \
156    -release $(VERSION) \
157    $(NULL)
158
159 libempathy_gtk_la_SOURCES =                     \
160         $(libempathy_gtk_handwritten_source)    \
161         $(libempathy_gtk_headers)               \
162         $(NULL)
163
164 # do not distribute generated files
165 nodist_libempathy_gtk_la_SOURCES =\
166         $(BUILT_SOURCES)
167
168 libempathy_gtk_la_LIBADD =                      \
169         $(EMPATHY_LIBS)                 \
170         $(EMPATHY_LIBS)                 \
171         $(TPAW_LIBS)                    \
172         $(GTK_LIBS)                     \
173         $(LIBNOTIFY_LIBS)                       \
174         $(CANBERRA_LIBS) \
175         $(ENCHANT_LIBS)                         \
176         $(LIBCHAMPLAIN_LIBS)                    \
177         $(GEOCLUE_LIBS)                         \
178         $(GEOCODE_LIBS)                         \
179         $(GCR_LIBS)                             \
180         $(MEEGO_LIBS)                           \
181         $(CHEESE_LIBS)                          \
182         $(top_builddir)/libempathy-gtk/egg-list-box/libegglistbox.la \
183         $(top_builddir)/libempathy/libempathy.la
184
185 check_c_sources = \
186     $(libempathy_gtk_handwritten_source) \
187     $(libempathy_gtk_headers)
188 include $(top_srcdir)/tools/check-coding-style.mk
189 check-local: check-coding-style
190
191 account_widgets_ui_files =                      \
192         empathy-account-widget-generic.ui       \
193         empathy-account-widget-jabber.ui        \
194         empathy-account-widget-msn.ui           \
195         empathy-account-widget-sip.ui           \
196         empathy-account-widget-local-xmpp.ui    \
197         empathy-account-widget-irc.ui           \
198         empathy-account-widget-icq.ui           \
199         empathy-account-widget-yahoo.ui         \
200         empathy-account-widget-groupwise.ui     \
201         empathy-account-widget-aim.ui           \
202         $(NULL)
203
204 uidir = $(datadir)/empathy
205 ui_DATA =                                       \
206         empathy-contact-widget.ui               \
207         empathy-contact-blocking-dialog.ui      \
208         empathy-status-preset-dialog.ui         \
209         empathy-log-window.ui                   \
210         empathy-chat.ui                         \
211         empathy-search-bar.ui                   \
212         empathy-individual-widget.ui
213
214 empathy-gtk-enum-types.h: stamp-empathy-gtk-enum-types.h
215         $(AM_V_GEN)true
216 stamp-empathy-gtk-enum-types.h: Makefile $(libempathy_gtk_headers)
217         $(AM_V_GEN)(cd $(srcdir) \
218         && glib-mkenums \
219                         --fhead "#ifndef __LIBEMPATHY_GTK_ENUM_TYPES_H__\n" \
220                         --fhead "#define __LIBEMPATHY_GTK_ENUM_TYPES_H__ 1\n\n" \
221                         --fhead "#include <glib-object.h>\n\n" \
222                         --fhead "G_BEGIN_DECLS\n\n" \
223                         --ftail "G_END_DECLS\n\n" \
224                         --ftail "#endif /* __LIBEMPATHY_GTK_ENUM_TYPES_H__ */\n" \
225                         --fprod '#include "@filename@"\n' \
226                         --eprod "#define EMPATHY_TYPE_@ENUMSHORT@ @enum_name@_get_type()\n" \
227                         --eprod "GType @enum_name@_get_type (void);\n" \
228                 $(libempathy_gtk_headers) ) > xgen-gth \
229         && (cmp -s xgen-gth empathy-gtk-enum-type.h || cp xgen-gth empathy-gtk-enum-types.h) \
230         && rm -f xgen-gth \
231         && echo timestamp > $(@F)
232
233 empathy-gtk-enum-types.c: Makefile $(libempathy_gtk_headers)
234         $(AM_V_GEN)(cd $(srcdir) \
235         && glib-mkenums \
236                         --fhead "#include <config.h>\n" \
237                         --fhead "#include <glib-object.h>\n" \
238                         --fhead "#include \"empathy-gtk-enum-types.h\"\n\n" \
239                         --fprod "\n/* enumerations from \"@filename@\" */" \
240                         --vhead "static const G@Type@Value _@enum_name@_values[] = {" \
241                         --vprod "  { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
242                         --vtail "  { 0, NULL, NULL }\n};\n\n" \
243                         --vtail "GType\n@enum_name@_get_type (void)\n{\n" \
244                         --vtail "  static GType type = 0;\n\n" \
245                         --vtail "  if (!type)\n" \
246                         --vtail "    type = g_@type@_register_static (\"@EnumName@\", _@enum_name@_values);\n\n" \
247                         --vtail "  return type;\n}\n\n" \
248                 $(libempathy_gtk_headers) ) > xgen-gtc \
249         && cp xgen-gtc $(@F) \
250         && rm -f xgen-gtc
251
252 EXTRA_DIST =                                    \
253         $(ui_DATA)
254
255 if HAVE_GEOCLUE
256 geoclue-interface.c: geoclue-interface.h
257 geoclue-interface.h: Makefile.am
258         gdbus-codegen                                           \
259                 --interface-prefix org.freedesktop.GeoClue2.    \
260                 --c-namespace GClue                             \
261                 --generate-c-code geoclue-interface             \
262                 $(GEOCLUE_XML_FILE)
263
264 BUILT_SOURCES += \
265         geoclue-interface.h \
266         geoclue-interface.c
267
268 libempathy_gtk_handwritten_source +=            \
269         empathy-location-manager.c \
270         empathy-geoclue-helper.c
271
272 libempathy_gtk_headers +=                       \
273         empathy-location-manager.h \
274         empathy-geoclue-helper.h
275
276 else
277 EXTRA_DIST +=                                   \
278         empathy-location-manager.c              \
279         empathy-location-manager.h
280 endif
281
282 CLEANFILES =                            \
283         $(BUILT_SOURCES)                \
284         stamp-empathy-gtk-enum-types.h