1 lib_LTLIBRARIES = libgstreamer-@GST_MAJORMINOR@.la
3 if GST_DISABLE_LOADSAVE
4 GST_LOADSAVE_SRC =
5 else
6 GST_LOADSAVE_SRC = gstxml.c
7 endif
9 if GST_DISABLE_REGISTRY
10 GST_REGISTRY_SRC =
11 else
12 GST_REGISTRY_SRC = gstregistrybinary.c
13 endif
15 if GST_DISABLE_PARSE
16 SUBDIRS_PARSE =
17 GST_PARSE_LA =
18 else
19 SUBDIRS_PARSE = parse
20 GST_PARSE_LA = parse/libgstparse.la
21 endif
23 if GST_DISABLE_TRACE
24 GST_TRACE_SRC =
25 else
26 GST_TRACE_SRC = gsttrace.c
27 endif
29 if GST_DISABLE_PLUGIN
30 GST_PLUGIN_SRC =
31 else
32 GST_PLUGIN_SRC = gstplugin.c
33 endif
35 SUBDIRS = $(SUBDIRS_PARSE)
37 DIST_SUBDIRS = parse
39 # make variables for all generated source and header files to make the
40 # distinction clear
42 built_header_configure = gstconfig.h gstversion.h
43 built_header_make = gstenumtypes.h gstmarshal.h
44 built_source_make = gstenumtypes.c gstmarshal.c
46 EXTRA_libgstreamer_@GST_MAJORMINOR@_la_SOURCES = \
47 gstmarshal.list gsttrace.c gstxml.c \
48 gstregistrybinary.c
51 # temporarily not used
52 # glib-compat.c
54 libgstreamer_@GST_MAJORMINOR@_la_SOURCES = \
55 gst.c \
56 gstobject.c \
57 gstbin.c \
58 gstbuffer.c \
59 gstbufferlist.c \
60 gstbus.c \
61 gstcaps.c \
62 gstchildproxy.c \
63 gstclock.c \
64 gstdatetime.c \
65 gstdebugutils.c \
66 gstelement.c \
67 gstelementfactory.c \
68 gsterror.c \
69 gstevent.c \
70 gstfilter.c \
71 gstformat.c \
72 gstghostpad.c \
73 gstindex.c \
74 gstindexfactory.c \
75 gstinfo.c \
76 gstinterface.c \
77 gstiterator.c \
78 gstatomicqueue.c \
79 gstmessage.c \
80 gstminiobject.c \
81 gstpad.c \
82 gstpadtemplate.c \
83 gstparamspecs.c \
84 gstpipeline.c \
85 gstplugin.c \
86 gstpluginfeature.c \
87 gstpluginloader.c \
88 gstpoll.c \
89 gstpreset.c \
90 gstquark.c \
91 gstquery.c \
92 gstregistry.c \
93 gstregistrychunks.c \
94 gstsegment.c \
95 gststructure.c \
96 gstsystemclock.c \
97 gsttaglist.c \
98 gsttagsetter.c \
99 gsttask.c \
100 gsttaskpool.c \
101 $(GST_TRACE_SRC) \
102 gsttypefind.c \
103 gsttypefindfactory.c \
104 gsturi.c \
105 gstutils.c \
106 gstvalue.c \
107 gstparse.c \
108 $(GST_REGISTRY_SRC) \
109 $(GST_LOADSAVE_SRC)
111 # do not put files in the distribution that are generated
112 nodist_libgstreamer_@GST_MAJORMINOR@_la_SOURCES = $(built_source_make)
114 # BUILT_SOURCES are built on make all/check/install before all other targets
115 BUILT_SOURCES = \
116 $(built_header_configure) \
117 $(built_header_make) \
118 $(built_source_make)
119 # CLEANFILES is for files generated by make
120 CLEANFILES = $(built_header_make) $(built_source_make) $(as_dll_cleanfiles) *.gcno *.gcda *.gcov *.gcov.out
121 # DISTCLEANFILES is for files generated by configure
122 DISTCLEANFILES = $(built_header_configure)
124 libgstreamer_@GST_MAJORMINOR@_la_CFLAGS = \
125 -D_GNU_SOURCE \
126 -DGST_EXPORTS \
127 -DG_LOG_DOMAIN=g_log_domain_gstreamer \
128 -DGST_MAJORMINOR=\""$(GST_MAJORMINOR)"\" \
129 -DGST_DISABLE_DEPRECATED \
130 $(VALGRIND_CFLAGS) \
131 $(GST_ALL_CFLAGS)
133 libgstreamer_@GST_MAJORMINOR@_la_LIBADD = \
134 $(GST_PARSE_LA) \
135 $(GST_ALL_LIBS) \
136 $(WIN32_LIBS) \
137 $(XML_LIBS) \
138 $(LIBM)
140 libgstreamer_@GST_MAJORMINOR@_la_LDFLAGS = \
141 $(GST_LIB_LDFLAGS) $(GST_ALL_LDFLAGS) $(GST_LT_LDFLAGS)
143 libgstreamer_@GST_MAJORMINOR@includedir = $(includedir)/gstreamer-@GST_MAJORMINOR@/gst
145 gst_headers = \
146 gst.h \
147 glib-compat.h \
148 gstobject.h \
149 gstbin.h \
150 gstbuffer.h \
151 gstbufferlist.h \
152 gstbus.h \
153 gstcaps.h \
154 gstchildproxy.h \
155 gstclock.h \
156 gstcompat.h \
157 gstdatetime.h \
158 gstdebugutils.h \
159 gstelement.h \
160 gstelementfactory.h \
161 gsterror.h \
162 gstevent.h \
163 gstfilter.h \
164 gstformat.h \
165 gstghostpad.h \
166 gstindex.h \
167 gstindexfactory.h \
168 gstinfo.h \
169 gstinterface.h \
170 gstiterator.h \
171 gstatomicqueue.h \
172 gstmacros.h \
173 gstmessage.h \
174 gstminiobject.h \
175 gstpad.h \
176 gstpadtemplate.h \
177 gstparamspecs.h \
178 gstpipeline.h \
179 gstplugin.h \
180 gstpluginfeature.h \
181 gstpoll.h \
182 gstpreset.h \
183 gstquery.h \
184 gstsegment.h \
185 gststructure.h \
186 gstsystemclock.h \
187 gsttaglist.h \
188 gsttagsetter.h \
189 gsttask.h \
190 gsttaskpool.h \
191 gsttrace.h \
192 gsttypefind.h \
193 gsttypefindfactory.h \
194 gsturi.h \
195 gstutils.h \
196 gstvalue.h \
197 gstregistry.h \
198 gstparse.h \
199 gstxml.h
201 libgstreamer_@GST_MAJORMINOR@include_HEADERS = $(gst_headers) math-compat.h
203 nodist_libgstreamer_@GST_MAJORMINOR@include_HEADERS = \
204 $(built_header_configure) $(built_header_make)
206 noinst_HEADERS = \
207 gettext.h \
208 glib-compat-private.h \
209 gst-i18n-lib.h \
210 gst-i18n-app.h \
211 gstelementdetails.h \
212 gstpluginloader.h \
213 gstquark.h \
214 gstregistrybinary.h \
215 gstregistrychunks.h \
216 gst_private.h
218 gstmarshal.h: gstmarshal.list
219 $(AM_V_GEN)glib-genmarshal --header --prefix=gst_marshal $(srcdir)/gstmarshal.list > gstmarshal.h.tmp && \
220 mv gstmarshal.h.tmp gstmarshal.h
222 gstmarshal.c: gstmarshal.list gst_private.h
223 $(AM_V_GEN)echo "#include \"gst_private.h\"" > gstmarshal.c.tmp && \
224 echo "#include \"glib-object.h\"" >> gstmarshal.c.tmp && \
225 echo "#include \"gstmarshal.h\"" >> gstmarshal.c.tmp && \
226 glib-genmarshal --body --prefix=gst_marshal $(srcdir)/gstmarshal.list >> gstmarshal.c.tmp && \
227 mv gstmarshal.c.tmp gstmarshal.c
229 gstenumtypes.h: $(gst_headers)
230 $(AM_V_GEN)glib-mkenums \
231 --fhead "#ifndef __GST_ENUM_TYPES_H__\n#define __GST_ENUM_TYPES_H__\n\n#include <glib-object.h>\n\nG_BEGIN_DECLS\n" \
232 --fprod "\n/* enumerations from \"@filename@\" */\n" \
233 --vhead "GType @enum_name@_get_type (void);\n#define GST_TYPE_@ENUMSHORT@ (@enum_name@_get_type())\n" \
234 --ftail "G_END_DECLS\n\n#endif /* __GST_ENUM_TYPES_H__ */" \
235 $^ > gstenumtypes.h
237 gstenumtypes.c: $(gst_headers)
238 $(AM_V_GEN)glib-mkenums \
239 --fhead "#include \"gst_private.h\"\n#include <gst/gst.h>\n#define C_ENUM(v) ((gint) v)\n#define C_FLAGS(v) ((guint) v)\n " \
240 --fprod "\n/* enumerations from \"@filename@\" */" \
241 --vhead "GType\n@enum_name@_get_type (void)\n{\n static gsize id = 0;\n static const G@Type@Value values[] = {" \
242 --vprod " { C_@TYPE@(@VALUENAME@), \"@VALUENAME@\", \"@valuenick@\" }," \
243 --vtail " { 0, NULL, NULL }\n };\n\n if (g_once_init_enter (&id)) {\n GType tmp = g_@type@_register_static (\"@EnumName@\", values);\n g_once_init_leave (&id, tmp);\n }\n\n return (GType) id;\n}" \
244 $^ > gstenumtypes.c
246 %.c.gcov: .libs/libgstreamer_@GST_MAJORMINOR@_la-%.gcda %.c
247 $(GCOV) -b -f -o $^ > $@.out
249 gcov: $(libgstreamer_@GST_MAJORMINOR@_la_SOURCES:=.gcov)
251 Android.mk: Makefile.am
252 androgenizer -:PROJECT gstreamer -:SHARED libgstreamer-@GST_MAJORMINOR@ \
253 -:TAGS eng debug \
254 -:REL_TOP $(top_srcdir) -:ABS_TOP $(abs_top_srcdir) \
255 -:SOURCES $(libgstreamer_@GST_MAJORMINOR@_la_SOURCES) \
256 $(nodist_libgstreamer_@GST_MAJORMINOR@_la_SOURCES) \
257 -:CFLAGS $(DEFS) $(libgstreamer_@GST_MAJORMINOR@_la_CFLAGS) \
258 -:LDFLAGS $(libgstreamer_@GST_MAJORMINOR@_la_LDFLAGS) \
259 $(libgstreamer_@GST_MAJORMINOR@_la_LIBADD) \
260 -ldl \
261 -:SUBDIR gst/parse \
262 -:HEADER_TARGET gstreamer-@GST_MAJORMINOR@/gst \
263 -:HEADERS $(libgstreamer_@GST_MAJORMINOR@include_HEADERS) \
264 -:LIBFILTER_STATIC gstparse \
265 -:PASSTHROUGH LOCAL_ARM_MODE:=arm \
266 > $@
268 if HAVE_INTROSPECTION
269 BUILT_GIRSOURCES = Gst-@GST_MAJORMINOR@.gir
271 gir_headers=$(patsubst %,$(srcdir)/%, $(libgstreamer_@GST_MAJORMINOR@include_HEADERS))
272 gir_sources=$(patsubst %,$(srcdir)/%, $(libgstreamer_@GST_MAJORMINOR@_la_SOURCES))
274 Gst-@GST_MAJORMINOR@.gir: $(INTROSPECTION_SCANNER) libgstreamer-@GST_MAJORMINOR@.la
275 $(AM_V_GEN)GST_PLUGIN_SYSTEM_PATH="" GST_PLUGIN_PATH="" GST_REGISTRY_UPDATE=no \
276 $(INTROSPECTION_SCANNER) -v --namespace Gst \
277 --nsversion=@GST_MAJORMINOR@ \
278 -I$(top_srcdir) \
279 -I$(top_builddir) \
280 -DIN_GOBJECT_INTROSPECTION=1 \
281 --c-include='gst/gst.h' \
282 --library=libgstreamer-0.10.la \
283 --include=GLib-2.0 \
284 --include=GObject-2.0 \
285 --include=GModule-2.0 \
286 --include=libxml2-2.0 \
287 --libtool="$(top_builddir)/libtool" \
288 --pkg glib-2.0 \
289 --pkg gobject-2.0 \
290 --pkg gmodule-no-export-2.0 \
291 --pkg gthread-2.0 \
292 --pkg libxml-2.0 \
293 --pkg-export gstreamer-0.10 \
294 --add-init-section="gst_init(NULL, NULL);" \
295 --output $@ \
296 $(gir_headers) \
297 $(gir_sources)
299 # INTROSPECTION_GIRDIR/INTROSPECTION_TYPELIBDIR aren't the right place to
300 # install anything - we need to install inside our prefix.
301 girdir = $(datadir)/gir-1.0
302 gir_DATA = $(BUILT_GIRSOURCES)
304 typelibsdir = $(libdir)/girepository-1.0/
306 typelibs_DATA = $(BUILT_GIRSOURCES:.gir=.typelib)
308 %.typelib: %.gir $(INTROSPECTION_COMPILER)
309 $(AM_V_GEN)$(INTROSPECTION_COMPILER) --includedir=$(srcdir) --includedir=$(builddir) $(INTROSPECTION_COMPILER_OPTS) $< -o $(@F)
311 CLEANFILES += $(BUILT_GIRSOURCES) $(typelibs_DATA)
312 endif
314 # try to prevent packaging errors
315 check-libexecdir-consistency:
316 @if test "${GST_PLUGIN_SCANNER_INSTALLED}" != "${libexecdir}/gstreamer-$(GST_MAJORMINOR)/gst-plugin-scanner"; then \
317 echo "*** Inconsistent libexecdir! Please use ./configure --libexecdir=/foo/bar"; \
318 echo "*** to set the libexecdir and not make libexecdir=/foo/bar or the like."; \
319 echo "*** The same goes for prefix, libdir etc."; \
320 echo "*** ${GST_PLUGIN_SCANNER_INSTALLED} != ${libexecdir}/gstreamer-$(GST_MAJORMINOR)/gst-plugin-scanner"; \
321 exit 1; \
322 fi
324 all-local: check-libexecdir-consistency