]> git.0d.be Git - empathy.git/blob - libempathy/Makefile.am
Add EmpathyAccountManager.
[empathy.git] / libempathy / Makefile.am
1 AM_CPPFLAGS =                                           \
2         -I.                                             \
3         -I$(top_srcdir)                                 \
4         -I$(top_builddir)                               \
5         -DDATADIR=\""$(datadir)"\"                      \
6         -DLOCALEDIR=\""$(datadir)/locale"\"             \
7         $(LIBEMPATHY_CFLAGS)                            \
8         $(WARN_CFLAGS)
9
10 BUILT_SOURCES =                                         \
11         empathy-marshal.h                               \
12         empathy-marshal.c                               \
13         empathy-marshal.list                            \
14         empathy-enum-types.h                            \
15         empathy-enum-types.c
16
17 lib_LTLIBRARIES = libempathy.la
18
19 libempathy_la_SOURCES =                                 \
20         empathy-account-manager.c                       \
21         empathy-chatroom.c                              \
22         empathy-chatroom-manager.c                      \
23         empathy-contact.c                               \
24         empathy-contact-factory.c                       \
25         empathy-contact-groups.c                        \
26         empathy-contact-list.c                          \
27         empathy-contact-manager.c                       \
28         empathy-debug.c                                 \
29         empathy-dispatcher.c                            \
30         empathy-idle.c                                  \
31         empathy-irc-network.c                           \
32         empathy-irc-network-manager.c                   \
33         empathy-irc-server.c                            \
34         empathy-log-manager.c                           \
35         empathy-message.c                               \
36         empathy-status-presets.c                        \
37         empathy-time.c                                  \
38         empathy-tp-call.c                               \
39         empathy-tp-chat.c                               \
40         empathy-tp-contact-factory.c                    \
41         empathy-tp-contact-list.c                       \
42         empathy-tp-file.c                               \
43         empathy-tp-group.c                              \
44         empathy-tp-roomlist.c                           \
45         empathy-tp-tube.c                               \
46         empathy-tube-handler.c                          \
47         empathy-utils.c
48
49 # do not distribute generated files
50 nodist_libempathy_la_SOURCES =\
51         $(BUILT_SOURCES)
52
53 libempathy_la_LIBADD =          \
54         $(top_builddir)/extensions/libemp-extensions.la \
55         $(LIBEMPATHY_LIBS)
56
57 libempathy_la_LDFLAGS =         \
58        -version-info ${LIBEMPATHY_CURRENT}:${LIBEMPATHY_REVISION}:${LIBEMPATHY_AGE} \
59        -export-symbols-regex ^empathy_
60
61 libempathy_headers =                            \
62         empathy-account-manager.h               \
63         empathy-chatroom.h                      \
64         empathy-chatroom-manager.h              \
65         empathy-contact.h                       \
66         empathy-contact-factory.h               \
67         empathy-contact-groups.h                \
68         empathy-contact-list.h                  \
69         empathy-contact-manager.h               \
70         empathy-debug.h                         \
71         empathy-dispatcher.h                    \
72         empathy-idle.h                          \
73         empathy-irc-network.h                   \
74         empathy-irc-network-manager.h           \
75         empathy-irc-server.h                    \
76         empathy-log-manager.h                   \
77         empathy-message.h                       \
78         empathy-status-presets.h                \
79         empathy-time.h                          \
80         empathy-tp-call.h                       \
81         empathy-tp-chat.h                       \
82         empathy-tp-contact-factory.h            \
83         empathy-tp-contact-list.h               \
84         empathy-tp-file.h                       \
85         empathy-tp-group.h                      \
86         empathy-tp-roomlist.h                   \
87         empathy-tp-tube.h                       \
88         empathy-tube-handler.h                  \
89         empathy-utils.h
90
91 libempathy_includedir = $(includedir)/libempathy/
92 libempathy_include_HEADERS =                    \
93         $(libempathy_headers)                   \
94         empathy-enum-types.h
95
96 empathy-marshal.list: $(libempathy_la_SOURCES) Makefile.am
97         ( cd $(srcdir) && \
98         sed -n -e 's/.*empathy_marshal_\([[:upper:][:digit:]]*__[[:upper:][:digit:]_]*\).*/\1/p' \
99         $(libempathy_la_SOURCES) ) \
100         | sed -e 's/__/:/' -e 'y/_/,/' | sort -u > $@.tmp
101         if cmp -s $@.tmp $@; then \
102                 rm $@.tmp; \
103         else \
104                 mv $@.tmp $@; \
105         fi
106
107 %-marshal.h: %-marshal.list Makefile
108         $(GLIB_GENMARSHAL) --header --prefix=_$(subst -,_,$*)_marshal $< > $*-marshal.h
109
110 %-marshal.c: %-marshal.list Makefile
111         echo "#include \"empathy-marshal.h\"" > $@ && \
112         $(GLIB_GENMARSHAL) --body --prefix=_$(subst -,_,$*)_marshal $< >> $*-marshal.c
113
114 empathy-enum-types.h: stamp-empathy-enum-types.h
115         @true
116 stamp-empathy-enum-types.h: $(libempathy_headers) Makefile
117         (cd $(srcdir) \
118         && glib-mkenums \
119                         --fhead "#ifndef __LIBEMPATHY_ENUM_TYPES_H__\n" \
120                         --fhead "#define __LIBEMPATHY_ENUM_TYPES_H__ 1\n\n" \
121                         --fhead "#include <glib-object.h>\n\n" \
122                         --fhead "G_BEGIN_DECLS\n\n" \
123                         --ftail "G_END_DECLS\n\n" \
124                         --ftail "#endif /* __LIBEMPATHY_ENUM_TYPES_H__ */\n" \
125                         --fprod "#include <libempathy/@filename@>\n" \
126                         --eprod "#define EMPATHY_TYPE_@ENUMSHORT@ @enum_name@_get_type()\n" \
127                         --eprod "GType @enum_name@_get_type (void);\n" \
128                 $(libempathy_headers) ) > xgen-gth \
129         && (cmp -s xgen-gth empathy-enum-type.h || cp xgen-gth empathy-enum-types.h) \
130         && rm -f xgen-gth \
131         && echo timestamp > $(@F)
132
133 empathy-enum-types.c: $(libempathy_headers) Makefile
134         (cd $(srcdir) \
135         && glib-mkenums \
136                         --fhead "#include <config.h>\n" \
137                         --fhead "#include <glib-object.h>\n" \
138                         --fhead "#include \"empathy-enum-types.h\"\n\n" \
139                         --fprod "\n/* enumerations from \"@filename@\" */" \
140                         --vhead "static const G@Type@Value _@enum_name@_values[] = {" \
141                         --vprod "  { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
142                         --vtail "  { 0, NULL, NULL }\n};\n\n" \
143                         --vtail "GType\n@enum_name@_get_type (void)\n{\n" \
144                         --vtail "  static GType type = 0;\n\n" \
145                         --vtail "  if (!type)\n" \
146                         --vtail "    type = g_@type@_register_static (\"@EnumName@\", _@enum_name@_values);\n\n" \
147                         --vtail "  return type;\n}\n\n" \
148                 $(libempathy_headers) ) > xgen-gtc \
149         && cp xgen-gtc $(@F) \
150         && rm -f xgen-gtc
151
152 dtddir = $(datadir)/empathy
153 dtd_DATA =                                      \
154         empathy-status-presets.dtd              \
155         empathy-contact-groups.dtd              \
156         empathy-chatroom-manager.dtd            \
157         empathy-irc-networks.dtd
158
159 stylesheetdir = $(datadir)/empathy
160 stylesheet_DATA =               \
161         empathy-log-manager.xsl
162
163 ircnetworksdir = $(datadir)/empathy
164 ircnetworks_DATA =              \
165         irc-networks.xml
166
167 pkgconfigdir = $(libdir)/pkgconfig
168 pkgconfig_DATA = libempathy.pc
169
170 EXTRA_DIST =                    \
171         empathy-marshal.list    \
172         $(stylesheet_DATA)      \
173         $(dtd_DATA)             \
174         $(ircnetworks_DATA)
175
176 CLEANFILES =                            \
177         $(BUILT_SOURCES)                \
178         stamp-empathy-enum-types.h