Update Slovak translation
[empathy-mirror.git] / libempathy / Makefile.am
blobb87b35b944056dc579193943ee2febc714f375f9
1 include $(top_srcdir)/tools/flymake.mk
3 AM_CPPFLAGS =                                           \
4         $(ERROR_CFLAGS)                                 \
5         -I$(top_srcdir)/extensions                      \
6         -I$(top_builddir)                               \
7         -DDATADIR=\""$(datadir)"\"                      \
8         -DLOCALEDIR=\""$(datadir)/locale"\"             \
9         -DG_LOG_DOMAIN=\"empathy\"                      \
10         -DGCR_API_SUBJECT_TO_CHANGE                     \
11         $(EMPATHY_CFLAGS)                               \
12         $(TPAW_CFLAGS)                                  \
13         $(GEOCLUE_CFLAGS)                               \
14         $(GEOCODE_CFLAGS)                               \
15         $(NETWORK_MANAGER_CFLAGS)                       \
16         $(CONNMAN_CFLAGS)                               \
17         $(GOA_CFLAGS)                                   \
18         $(UOA_CFLAGS)                                   \
19         $(WARN_CFLAGS)                                  \
20         $(DISABLE_DEPRECATED)
22 BUILT_SOURCES =                                         \
23         empathy-dtd-resources.c                         \
24         empathy-dtd-resources.h                         \
25         empathy-enum-types.h                            \
26         empathy-enum-types.c
28 libempathy_headers =                            \
29         action-chain-internal.h                 \
30         empathy-auth-factory.h                  \
31         empathy-bus-names.h                     \
32         empathy-chatroom-manager.h              \
33         empathy-chatroom.h                      \
34         empathy-client-factory.h \
35         empathy-connection-aggregator.h         \
36         empathy-contact-groups.h                \
37         empathy-contact.h                       \
38         empathy-debug.h                         \
39         empathy-ft-factory.h                    \
40         empathy-ft-handler.h                    \
41         empathy-gsettings.h                     \
42         empathy-presence-manager.h                              \
43         empathy-individual-manager.h            \
44         empathy-location.h                      \
45         empathy-message.h                       \
46         empathy-pkg-kit.h               \
47         empathy-request-util.h                  \
48         empathy-sasl-mechanisms.h               \
49         empathy-server-sasl-handler.h           \
50         empathy-server-tls-handler.h            \
51         empathy-status-presets.h                \
52         empathy-tls-verifier.h                  \
53         empathy-tp-chat.h                       \
54         empathy-types.h                         \
55         empathy-utils.h
57 libempathy_handwritten_source =                         \
58         $(libempathy_headers)                           \
59         action-chain.c                                  \
60         empathy-auth-factory.c                          \
61         empathy-chatroom-manager.c                      \
62         empathy-chatroom.c                              \
63         empathy-client-factory.c \
64         empathy-connection-aggregator.c         \
65         empathy-contact-groups.c                        \
66         empathy-contact.c                               \
67         empathy-debug.c                                 \
68         empathy-ft-factory.c                            \
69         empathy-ft-handler.c                            \
70         empathy-presence-manager.c                                      \
71         empathy-individual-manager.c                    \
72         empathy-message.c                               \
73         empathy-pkg-kit.c               \
74         empathy-request-util.c                          \
75         empathy-sasl-mechanisms.c                       \
76         empathy-server-sasl-handler.c                   \
77         empathy-server-tls-handler.c                    \
78         empathy-status-presets.c                        \
79         empathy-tls-verifier.c                          \
80         empathy-tp-chat.c                               \
81         empathy-utils.c
83 # these are sources that depend on GOA
84 goa_sources = \
85         empathy-goa-auth-handler.c \
86         empathy-goa-auth-handler.h \
87         $(NULL)
89 # these are sources that depend on Ubuntu Online Accounts
90 uoa_sources = \
91         empathy-uoa-auth-handler.c \
92         empathy-uoa-auth-handler.h \
93         $(NULL)
95 pkglib_LTLIBRARIES = libempathy.la
97 # libempathy's API is not stable and will never be, so use -release to make the
98 # SONAME of the plugin library change with every Empathy release.
99 libempathy_la_LDFLAGS = \
100    -no-undefined \
101    -release $(VERSION) \
102    $(NULL)
104 libempathy_la_SOURCES = \
105         $(libempathy_handwritten_source) \
106         $(NULL)
108 libempathy_la_LIBADD =          \
109         $(top_builddir)/extensions/libemp-extensions.la \
110         $(GCR_LIBS) \
111         $(EMPATHY_LIBS) \
112         $(TPAW_LIBS) \
113         $(GEOCLUE_LIBS) \
114         $(GEOCODE_LIBS) \
115         $(NETWORK_MANAGER_LIBS) \
116         $(CONNMAN_LIBS) \
117         $(UDEV_LIBS) \
118         $(GOA_LIBS) \
119         $(UOA_LIBS) \
120         $(LIBM)
122 dtd_resources_files =                           \
123         empathy-status-presets.dtd              \
124         empathy-contact-groups.dtd              \
125         empathy-chatroom-manager.dtd            \
126         $(NULL)
128 dtd_resource_files: $(shell $(GLIB_COMPILE_RESOURCES) --sourcedir=$(srcdir) --generate-dependencies $(srcdir)/empathy-dtd.gresource.xml)
130 empathy-dtd-resources.c: empathy-dtd.gresource.xml $(dtd_resource_files)
131         $(AM_V_GEN)$(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=$(srcdir) --generate-source $<
133 empathy-dtd-resources.h: empathy-dtd.gresource.xml $(dtd_resource_files)
134         $(AM_V_GEN)$(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=$(srcdir) --generate-header $<
136 EXTRA_DIST =                            \
137         empathy-dtd.gresource.xml       \
138         $(dtd_resources_files)          \
139         $(NULL)
141 CLEANFILES =                            \
142         $(BUILT_SOURCES)                \
143         stamp-empathy-enum-types.h
145 if HAVE_GOA
146 libempathy_la_SOURCES += $(goa_sources)
147 else
148 EXTRA_DIST += $(goa_sources)
149 endif
151 if HAVE_UOA
152 libempathy_la_SOURCES += $(uoa_sources)
153 else
154 EXTRA_DIST += $(uoa_sources)
155 endif
157 # do not distribute generated files
158 nodist_libempathy_la_SOURCES =\
159         $(BUILT_SOURCES)
161 check_c_sources = \
162     $(libempathy_handwritten_source) \
163     $(goa_sources) \
164     $(uoa_sources) \
165     $(NULL)
167 include $(top_srcdir)/tools/check-coding-style.mk
168 check-local: check-coding-style
170 empathy-enum-types.h: stamp-empathy-enum-types.h
171         $(AM_V_GEN)true
172 stamp-empathy-enum-types.h: $(libempathy_headers) Makefile
173         $(AM_V_GEN)(cd $(srcdir) \
174         && glib-mkenums \
175                         --fhead "#ifndef __LIBEMPATHY_ENUM_TYPES_H__\n" \
176                         --fhead "#define __LIBEMPATHY_ENUM_TYPES_H__ 1\n\n" \
177                         --fhead "#include <glib-object.h>\n\n" \
178                         --fhead "G_BEGIN_DECLS\n\n" \
179                         --ftail "G_END_DECLS\n\n" \
180                         --ftail "#endif /* __LIBEMPATHY_ENUM_TYPES_H__ */\n" \
181                         --fprod '#include "@filename@"\n' \
182                         --eprod "#define EMPATHY_TYPE_@ENUMSHORT@ @enum_name@_get_type()\n" \
183                         --eprod "GType @enum_name@_get_type (void);\n" \
184                 $(libempathy_headers) ) > xgen-gth \
185         && (cmp -s xgen-gth empathy-enum-type.h || cp xgen-gth empathy-enum-types.h) \
186         && rm -f xgen-gth \
187         && echo timestamp > $(@F)
189 empathy-enum-types.c: $(libempathy_headers) Makefile
190         $(AM_V_GEN)(cd $(srcdir) \
191         && glib-mkenums \
192                         --fhead "#include <config.h>\n" \
193                         --fhead "#include <glib-object.h>\n" \
194                         --fhead "#include \"empathy-enum-types.h\"\n\n" \
195                         --fprod "\n/* enumerations from \"@filename@\" */" \
196                         --vhead "static const G@Type@Value _@enum_name@_values[] = {" \
197                         --vprod "  { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
198                         --vtail "  { 0, NULL, NULL }\n};\n\n" \
199                         --vtail "GType\n@enum_name@_get_type (void)\n{\n" \
200                         --vtail "  static GType type = 0;\n\n" \
201                         --vtail "  if (!type)\n" \
202                         --vtail "    type = g_@type@_register_static (\"@EnumName@\", _@enum_name@_values);\n\n" \
203                         --vtail "  return type;\n}\n\n" \
204                 $(libempathy_headers) ) > xgen-gtc \
205         && cp xgen-gtc $(@F) \
206         && rm -f xgen-gtc