gst/: Convert asm source into inline assembly.
[platform/upstream/gstreamer.git] / gst / Makefile.am
1 lib_LTLIBRARIES = libgstreamer-@GST_MAJORMINOR@.la
2 AS_LIBTOOL_LIB = libgstreamer-@GST_MAJORMINOR@
3 if GST_DISABLE_OMEGA_COTHREADS
4 noinst_LTLIBRARIES =
5 else
6 noinst_LTLIBRARIES = libcothreads.la
7 endif
8
9 #GST_INSTRUMENT_FLAGS = -finstrument-functions -DGST_ENABLE_FUNC_INSTRUMENTATION
10
11 if GST_DISABLE_LOADSAVE
12 GST_LOADSAVE_SRC = 
13 else
14 GST_LOADSAVE_SRC = gstxml.c
15 endif
16
17 if GST_DISABLE_PARSE
18 GST_PARSE_SRC = 
19 GST_PARSE_DIRS = 
20 GST_PARSE_LIBADD = 
21 else
22 GST_PARSE_SRC = gstparse.c
23 GST_PARSE_DIRS = parse
24 GST_PARSE_LIBADD = parse/libgstparse.la 
25 endif
26
27 if GST_DISABLE_TRACE
28 GST_TRACE_SRC = 
29 else
30 GST_TRACE_SRC = gsttrace.c
31 endif
32
33 if GST_DISABLE_REGISTRY
34 GST_REGISTRY_SRC = 
35 GST_REGISTRY_DIRS =
36 GST_REGISTRY_LIBADD = 
37 else
38 GST_REGISTRY_SRC = gstregistry.c
39 GST_REGISTRY_DIRS = registries
40 GST_REGISTRY_LIBADD = registries/libgstxmlregistry.la
41 endif
42
43 if GST_DISABLE_ENUMTYPES
44 GST_ENUMTYPES_SRC = 
45 else
46 GST_ENUMTYPES_SRC = gstenumtypes.c
47 endif
48
49 if GST_DISABLE_INDEX
50 GST_INDEX_SRC = 
51 GST_INDEX_DIRS =
52 else
53 GST_INDEX_SRC = gstindex.c
54 GST_INDEX_DIRS = indexers
55 endif
56
57 if GST_DISABLE_PLUGIN
58 GST_PLUGIN_SRC = 
59 else
60 GST_PLUGIN_SRC = gstplugin.c
61 endif
62
63 if GST_DISABLE_URI
64 GST_URI_SRC = 
65 else
66 GST_URI_SRC = gsturi.c
67 endif
68
69 SUBDIRS = $(GST_PARSE_DIRS) $(GST_REGISTRY_DIRS) . autoplug elements schedulers $(GST_INDEX_DIRS) 
70 DIST_SUBDIRS = autoplug elements parse registries schedulers indexers
71
72 # make variables for all generated source and header files to make the
73 # distinction clear
74                                                                                 
75 built_header_configure = gstconfig.h gstversion.h
76 built_header_make = gstenumtypes.h gstmarshal.h
77 built_source_make = $(GST_ENUMTYPES_SRC) gstmarshal.c
78
79 EXTRA_libgstreamer_@GST_MAJORMINOR@_la_SOURCES = \
80         gstmarshal.list gstxml.c gstparse.c gsttrace.c
81
82 libgstreamer_@GST_MAJORMINOR@_la_SOURCES = \
83         gst.c                   \
84         gstobject.c             \
85         gstatomic.c             \
86         gstbin.c                \
87         gstbuffer.c             \
88         gstcaps.c               \
89         gstclock.c              \
90         gstcpu.c                \
91         gstdata.c               \
92         gstelement.c            \
93         gstelementfactory.c     \
94         gsterror.c              \
95         gstevent.c              \
96         gstfilter.c             \
97         gstformat.c             \
98         $(GST_INDEX_SRC)        \
99         gstinfo.c               \
100         gstinterface.c          \
101         gstmemchunk.c           \
102         gstpad.c                \
103         gstpipeline.c           \
104         gstplugin.c             \
105         gstpluginfeature.c      \
106         gstprobe.c              \
107         gstqueue.c              \
108         gstquery.c              \
109         gstscheduler.c          \
110         gststructure.c          \
111         gstsystemclock.c        \
112         gsttag.c                \
113         gsttaginterface.c       \
114         gstthread.c             \
115         $(GST_TRACE_SRC)        \
116         gsttrashstack.c         \
117         gsttypefind.c           \
118         $(GST_URI_SRC)          \
119         gsturitype.c            \
120         gstutils.c              \
121         gstvalue.c              \
122         $(GST_REGISTRY_SRC)     \
123         gstregistrypool.c       \
124         $(GST_PARSE_SRC)        \
125         $(GSTARCH_SRCS)         \
126         $(GST_LOADSAVE_SRC)
127
128 # do not put files in the distribution that are generated
129 nodist_libgstreamer_@GST_MAJORMINOR@_la_SOURCES = $(built_source_make)
130
131 # BUILT_SOURCES are built on make all/check/install before all other targets
132 BUILT_SOURCES = \
133         $(built_header_configure)       \
134         $(built_header_make)            \
135         $(built_source_make)
136 # CLEANFILES is for files generated by make
137 CLEANFILES = $(built_header_make) $(built_source_make) $(as_dll_cleanfiles)
138 # DISTCLEANFILES is for files generated by configure
139 DISTCLEANFILES = $(built_header_configure)
140                                                                                 
141 libgstreamer_@GST_MAJORMINOR@_la_CFLAGS = \
142         -D_GNU_SOURCE                           \
143         $(GST_CFLAGS)                           \
144         $(VALGRIND_CFLAGS)                      \
145         -DG_LOG_DOMAIN=g_log_domain_gstreamer   \
146         -DGST_MAJORMINOR=\""$(GST_MAJORMINOR)"\" 
147 libgstreamer_@GST_MAJORMINOR@_la_LIBADD = \
148         $(LIBGST_LIBS) $(GST_PARSE_LIBADD) $(GST_REGISTRY_LIBADD) $(VALGRIND_LIBS)
149 libgstreamer_@GST_MAJORMINOR@_la_LDFLAGS = \
150         @GST_LT_LDFLAGS@ -version-info @GST_LIBVERSION@ \
151         -export-symbols-regex [_]*\(gst_\|Gst\|GST_\).* \
152         $(as_libtool_LDFLAGS)
153
154 libgstreamer_@GST_MAJORMINOR@includedir = $(includedir)/gstreamer-@GST_MAJORMINOR@/gst
155
156 gst_headers =                   \
157         gst.h                   \
158         gstatomic.h             \
159         gstobject.h             \
160         gstbin.h                \
161         gstbuffer.h             \
162         gstcaps.h               \
163         gstclock.h              \
164         gstcompat.h             \
165         gstcpu.h                \
166         gstdata.h               \
167         gstelement.h            \
168         gsterror.h              \
169         gstevent.h              \
170         gstfilter.h             \
171         gstformat.h             \
172         gstindex.h              \
173         gstinfo.h               \
174         gstinterface.h          \
175         gstlog.h                \
176         gstmacros.h             \
177         gstmemchunk.h           \
178         gstpad.h                \
179         gstpipeline.h           \
180         gstplugin.h             \
181         gstpluginfeature.h      \
182         gstprobe.h              \
183         gstqueue.h              \
184         gstquery.h              \
185         gstscheduler.h          \
186         gststructure.h          \
187         gstsystemclock.h        \
188         gsttag.h                \
189         gsttaginterface.h       \
190         gstthread.h             \
191         gsttrace.h              \
192         gsttrashstack.h         \
193         gsttypefind.h           \
194         gsttypes.h              \
195         gsturi.h                \
196         gsturitype.h            \
197         gstutils.h              \
198         gstvalue.h              \
199         gstregistry.h           \
200         gstregistrypool.h       \
201         gstparse.h              \
202         gstxml.h
203
204 libgstreamer_@GST_MAJORMINOR@include_HEADERS = $(gst_headers)
205 nodist_libgstreamer_@GST_MAJORMINOR@include_HEADERS = \
206         $(built_header_configure) $(built_header_make)
207
208 noinst_HEADERS =                \
209         gettext.h               \
210         gst-i18n-lib.h          \
211         gst-i18n-app.h          \
212         gst_private.h           \
213         gstatomic_impl.h        \
214         gstdata_private.h       \
215         gstarch.h               \
216         cothreads.h             
217
218 if GST_DISABLE_OMEGA_COTHREADS
219 #libcothreads_la_SOURCES =
220 #libcothreads_la_CFLAGS =
221 else
222 libcothreads_la_SOURCES = cothreads.c
223 libcothreads_la_CFLAGS = $(libgstreamer_@GST_MAJORMINOR@_la_CFLAGS) 
224 endif
225
226
227 gstmarshal.h: gstmarshal.list
228         glib-genmarshal --header --prefix=gst_marshal $^ > gstmarshal.h.tmp
229         mv gstmarshal.h.tmp gstmarshal.h
230
231 gstmarshal.c: gstmarshal.list
232         echo "#include \"glib-object.h\"" >gstmarshal.c.tmp
233         echo "#include \"gstlog.h\"" >> gstmarshal.c.tmp
234         echo "#include \"gstmarshal.h\"" >> gstmarshal.c.tmp
235         glib-genmarshal --body --prefix=gst_marshal $^ >> gstmarshal.c.tmp
236         mv gstmarshal.c.tmp gstmarshal.c
237
238 gstenumtypes.h: $(gst_headers)
239         glib-mkenums \
240         --fhead "#ifndef __GST_ENUM_TYPES_H__\n#define __GST_ENUM_TYPES_H__\n\n#include <glib-object.h>\n\nG_BEGIN_DECLS\n" \
241         --fprod "/* enumerations from \"@filename@\" */\n" \
242         --vhead "GType @enum_name@_get_type (void);\n#define GST_TYPE_@ENUMSHORT@ (@enum_name@_get_type())\n"         \
243         --ftail "G_END_DECLS\n\n#endif /* __GST_ENUM_TYPES_H__ */" \
244         $^ > gstenumtypes.h
245
246 gstenumtypes.c: $(gst_headers)
247         glib-mkenums \
248         --fhead "#include <gst/gst.h>" \
249         --fprod "\n/* enumerations from \"@filename@\" */" \
250         --vhead "GType\n@enum_name@_get_type (void)\n{\n  static GType etype = 0;\n  if (etype == 0) {\n    static const G@Type@Value values[] = {"     \
251         --vprod "      { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
252         --vtail "      { 0, NULL, NULL }\n    };\n    etype = g_@type@_register_static (\"@EnumName@\", values);\n  }\n  return etype;\n}\n" \
253         $^ > gstenumtypes.c
254
255 noinst_DATA = $(as_libtool_noinst_DATA_files)
256
257 EXTRA_DIST = ROADMAP $(as_libtool_EXTRA_DIST)
258
259 install-data-local: as-libtool-install-data-local
260
261 uninstall-local: as-libtool-uninstall-local
262
263 include $(top_srcdir)/common/as-libtool.mak
264