Second round at Gtk-Doc-ifying public methods.
[mmediamanager.git] / src / Makefile.am
blob75c89effc7a7484c96a234bfaa09ce1b660faa1f
1 AM_CPPFLAGS =                   \
2         -I.                     \
3         -I$(top_srcdir)         \
4         -I$(top_builddir)
6 AM_CFLAGS =     \
7         -Wall   \
8         -Werror \
9         -g
11 INCLUDES = \
12         -DMMEDIAMANAGER_EXTENSIONDIR=\""$(libdir)/mmediamanager/extensions"\"
13   
14 bin_PROGRAMS = \
15         mm-dbus-manager
17 lib_LTLIBRARIES = \
18         libmmanager.la
20 mm_dbus_manager_headers = \
21         mm-dbus-manager.h
23 mm_dbus_manager_SOURCES = \
24         mm-dbus-manager-main.c \
25         mm-dbus-manager.c \
26         mm-dbus-manager-type-builtins.c \
27         mm-dbus-manager-type-builtins.h \
28         $(mm_dbus_manager_headers)
30 mm_dbus_manager_CFLAGS = \
31         $(DBUS_CFLAGS) \
32         $(MMEDIAMANAGER_CFLAGS)
34 mm_dbus_manager_LDADD = \
35         libmmanager.la \
36         $(DBUS_LIBS) \
37         $(MMEDIAMANAGER_LIBS)
39 libmmanager_la_includedir=$(includedir)/libmmanager
41 libmmanager_la_headers =                \
42         mm.h                            \
43         mm-application.h                \
44         mm-dbus-application.h           \
45         mm-so-application.h             \
46         mm-application-provider.h       \
47         mm-category.h                   \
48         mm-dbus-category.h              \
49         mm-so-category.h                \
50         mm-category-provider.h          \
51         mm-hit.h                        \
52         mm-hit-collection.h             \
53         mm-hit-collection-provider.h    \
54         mm-manager.h                    \
55         mm-module-manager.h             \
56         mm-filter.h                     \
57         mm-attribute.h                  \
58         mm-base-attributes.h            \
59         mm-filter-param.h               \
60         mm-attribute-manager.h          \
61         mm-attribute-base-manager.h     \
62         mm-module.h                     \
63         mm-string-utils.h               \
64         mm-utils.h                      \
65         mm-types.h                      \
66         mm-error.h
68 libmmanager_la_include_HEADERS =        \
69         $(libmmanager_la_headers)       \
70         mm-type-builtins.h
72 libmmanager_la_SOURCES =                \
73         mm-application.c                \
74         mm-dbus-application.c           \
75         mm-so-application.c             \
76         mm-application-provider.c       \
77         mm-category.c                   \
78         mm-dbus-category.c              \
79         mm-so-category.c                \
80         mm-category-provider.c          \
81         mm-hit.c                        \
82         mm-hit-collection.c             \
83         mm-hit-collection-provider.c    \
84         mm-manager.c                    \
85         mm-module.c                     \
86         mm-module-manager.c             \
87         mm-type-builtins.c              \
88         mm-filter.c                     \
89         mm-attribute.c                  \
90         mm-filter-param.c               \
91         mm-attribute-manager.c          \
92         mm-string-utils.c               \
93         mm-utils.c                      \
94         mm-attribute-base-manager.c
96 libmmanager_la_CFLAGS =                 \
97         $(MMEDIAMANAGER_CFLAGS)         \
98         $(DBUS_CFLAGS)
100 libmmanager_la_LIBADD =                 \
101         $(MMEDIAMANAGER_LIBS)           \
102         $(DBUS_LIBS)
104 BUILT_SOURCES =                                 \
105         mm-type-builtins.c                      \
106         mm-type-builtins.h                      \
107         mm-dbus-manager-client-bindings.h       \
108         mm-dbus-manager-server-bindings.h       \
109         mm-dbus-manager-type-builtins.c         \
110         mm-dbus-manager-type-builtins.h
112 stamp_files =                                   \
113         stamp-mm-type-builtins.c                \
114         stamp-mm-type-builtins.h                \
115         stamp-mm-dbus-manager-client-bindings.h \
116         stamp-mm-dbus-manager-server-bindings.h \
117         stamp-mm-dbus-manager-type-builtins.c   \
118         stamp-mm-dbus-manager-type-builtins.h
120 mm-type-builtins.c: stamp-mm-type-builtins.c Makefile
121         @true
122 stamp-mm-type-builtins.c: Makefile $(libmmanager_la_headers)
123         $(GLIB_MKENUMS) \
124                 --fhead "#include <config.h>\n\n" \
125                 --fhead "#include \"mm-type-builtins.h\"\n\n" \
126                 --fprod "\n/* enumerations from \"@filename@\" */" \
127                 --fprod "\n#include \"@filename@\"" \
128                 --vhead "GType\n@enum_name@_get_type (void)\n{\n" \
129                 --vhead "  static GType type = 0;\n\n" \
130                 --vhead "  if (G_UNLIKELY (type == 0))\n  {\n" \
131                 --vhead "    static const G@Type@Value _@enum_name@_values[] = {" \
132                 --vprod "      { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
133                 --vtail "      { 0, NULL, NULL }\n    };\n\n" \
134                 --vtail "    type = g_@type@_register_static (\"@EnumName@\", _@enum_name@_values);\n  }\n\n" \
135                 --vtail "  return type;\n}\n\n" \
136                 $(libmmanager_la_headers) > xgen-$(@F) \
137         && ( cmp -s xgen-$(@F) $(@F:stamp-%=%) || cp xgen-$(@F) $(@F:stamp-%=%) ) \
138         && rm -f xgen-$(@F) \
139         && echo timestamp > $(@F)
141 mm-type-builtins.h: stamp-mm-type-builtins.h Makefile
142         @true
143 stamp-mm-type-builtins.h: Makefile $(libmmanager_la_headers)
144         $(GLIB_MKENUMS) \
145                 --fhead "#ifndef __MM_TYPE_BUILTINS_H__\n" \
146                 --fhead "#define __MM_TYPE_BUILTINS_H__\n\n" \
147                 --fhead "#include <glib-object.h>\n\n" \
148                 --fhead "G_BEGIN_DECLS\n\n" \
149                 --ftail "G_END_DECLS\n\n" \
150                 --ftail "#endif /* __MM_TYPE_BUILTINS_H__ */\n" \
151                 --fprod "\n/* --- @filename@ --- */" \
152                 --eprod "#define MM_TYPE_@ENUMSHORT@ @enum_name@_get_type()\n" \
153                 --eprod "GType @enum_name@_get_type (void);\n" \
154                 $(libmmanager_la_headers) > xgen-$(@F) \
155         && ( cmp -s xgen-$(@F) $(@F:stamp-%=%) || cp xgen-$(@F) $(@F:stamp-%=%) ) \
156         && rm -f xgen-$(@F) \
157         && echo timestamp > $(@F)
158         
159 mm-dbus-manager-type-builtins.c: stamp-mm-dbus-manager-type-builtins.c Makefile
160         @true
161 stamp-mm-dbus-manager-type-builtins.c: Makefile $(mm_dbus_manager_headers)
162         $(GLIB_MKENUMS) \
163                 --fhead "#include <config.h>\n\n" \
164                 --fhead "#include \"mm-type-builtins.h\"\n\n" \
165                 --fprod "\n/* enumerations from \"@filename@\" */" \
166                 --fprod "\n#include \"@filename@\"" \
167                 --vhead "GType\n@enum_name@_get_type (void)\n{\n" \
168                 --vhead "  static GType type = 0;\n\n" \
169                 --vhead "  if (G_UNLIKELY (type == 0))\n  {\n" \
170                 --vhead "    static const G@Type@Value _@enum_name@_values[] = {" \
171                 --vprod "      { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
172                 --vtail "      { 0, NULL, NULL }\n    };\n\n" \
173                 --vtail "    type = g_@type@_register_static (\"@EnumName@\", _@enum_name@_values);\n  }\n\n" \
174                 --vtail "  return type;\n}\n\n" \
175                 $(mm_dbus_manager_headers) > xgen-$(@F) \
176         && ( cmp -s xgen-$(@F) $(@F:stamp-%=%) || cp xgen-$(@F) $(@F:stamp-%=%) ) \
177         && rm -f xgen-$(@F) \
178         && echo timestamp > $(@F)
180 mm-dbus-manager-type-builtins.h: stamp-mm-dbus-manager-type-builtins.h Makefile
181         @true
182 stamp-mm-dbus-manager-type-builtins.h: Makefile $(mm_dbus_manager_headers)
183         $(GLIB_MKENUMS) \
184                 --fhead "#ifndef __MM_TYPE_BUILTINS_H__\n" \
185                 --fhead "#define __MM_TYPE_BUILTINS_H__\n\n" \
186                 --fhead "#include <glib-object.h>\n\n" \
187                 --fhead "G_BEGIN_DECLS\n\n" \
188                 --ftail "G_END_DECLS\n\n" \
189                 --ftail "#endif /* __MM_TYPE_BUILTINS_H__ */\n" \
190                 --fprod "\n/* --- @filename@ --- */" \
191                 --eprod "#define MM_TYPE_@ENUMSHORT@ @enum_name@_get_type()\n" \
192                 --eprod "GType @enum_name@_get_type (void);\n" \
193                 $(mm_dbus_manager_headers) > xgen-$(@F) \
194         && ( cmp -s xgen-$(@F) $(@F:stamp-%=%) || cp xgen-$(@F) $(@F:stamp-%=%) ) \
195         && rm -f xgen-$(@F) \
196         && echo timestamp > $(@F)
198 mm-dbus-manager-server-bindings.h: stamp-mm-dbus-manager-server-bindings.h
199         @true
200 stamp-mm-dbus-manager-server-bindings.h: mm-dbus-manager-info.xml Makefile
201         $(DBUS_BINDING_TOOL) --prefix=mm_dbus_manager --mode=glib-server $< > xgen-$(@F) \
202         && ( cmp -s xgen-$(@F) $(@F:stamp-%=%) || cp xgen-$(@F) $(@F:stamp-%=%) ) \
203         && rm -f xgen-$(@F) \
204         && echo timestamp > $(@F)
206 mm-dbus-manager-client-bindings.h: stamp-mm-dbus-manager-client-bindings.h
207         @true
208 stamp-mm-dbus-manager-client-bindings.h: mm-dbus-manager-info.xml Makefile
209         $(DBUS_BINDING_TOOL) --prefix=mm_dbus_manager --mode=glib-client $< > xgen-$(@F) \
210         && ( cmp -s xgen-$(@F) $(@F:stamp-%=%) || cp xgen-$(@F) $(@F:stamp-%=%) ) \
211         && rm -f xgen-$(@F) \
212         && echo timestamp > $(@F)
214 mm-dbus-module-server-bindings.h: stamp-mm-dbus-module-server-bindings.h
215         @true
216 stamp-mm-dbus-module-server-bindings.h: mm-dbus-module-info.xml Makefile
217         $(DBUS_BINDING_TOOL) --prefix=mm_dbus_module --mode=glib-server $< > xget-$(@F) \
218         && ( cmp -s xgen-$(@F) $(@F:stamp-%=%) || cp xgen-$(@F) $(@F:stamp-%=%) ) \
219         && rm -f xgen-$(@F) \
220         && echo timestamp > $(@F)
222 mm-dbus-module-client-bindings.h: stamp-mm-dbus-module-client-bindings.h
223         @true
224 stamp-mm-dbus-module-client-bindings.h: mm-dbus-module-info.xml Makefile
225         $(DBUS_BINDING_TOOL) --prefix=mm_dbus_module --mode=glib-client $< > xgen-$(@F) \
226         && ( cmp -s xgen-$(@F) $(@F:stamp-%=%) || cp xgen-$(@F) $(@F:stamp-%=%) ) \
227         && rm -f xgen-$(@F) \
228         && echo timestamp > $(@F)
230 CLEANFILES = $(stamp_files) $(BUILT_SOURCES)
231 DISTCLEANFILES = $(stamp_files) $(BUILT_SOURCES)
232 MAINTAINERCLEANFILES = $(stamp_files) $(BUILT_SOURCES)
234 pkgconfigdir=$(libdir)/pkgconfig
235 pkgconfig_DATA=libmmanager.pc
237 EXTRA_DIST =                            \
238         libmmanager.pc.in               \
239         mm-dbus-manager-info.xml        \
240         mm-dbus-module-info.xml