libs: drop GstVaapiImageFormat helpers.
[platform/upstream/gstreamer-vaapi.git] / gst-libs / gst / vaapi / Makefile.am
1 lib_LTLIBRARIES = libgstvaapi-@GST_API_VERSION@.la
2
3 if USE_DRM
4 lib_LTLIBRARIES += libgstvaapi-drm-@GST_API_VERSION@.la
5 endif
6
7 if USE_X11
8 lib_LTLIBRARIES += libgstvaapi-x11-@GST_API_VERSION@.la
9 endif
10
11 if USE_GLX
12 lib_LTLIBRARIES += libgstvaapi-glx-@GST_API_VERSION@.la
13 endif
14
15 if USE_WAYLAND
16 lib_LTLIBRARIES += libgstvaapi-wayland-@GST_API_VERSION@.la
17 endif
18
19 libgstvaapi_includedir = \
20         $(includedir)/gstreamer-$(GST_API_VERSION)/gst/vaapi
21
22 libgstvaapi_cflags =                            \
23         -DGST_VAAPI_CORE                        \
24         -DGST_USE_UNSTABLE_API                  \
25         -I$(top_srcdir)/gst-libs                \
26         -I$(top_builddir)/gst-libs              \
27         $(GST_BASE_CFLAGS)                      \
28         $(GST_BASEVIDEO_CFLAGS)                 \
29         $(GST_VIDEO_CFLAGS)                     \
30         $(GST_CFLAGS)                           \
31         $(GST_CODEC_PARSERS_CFLAGS)             \
32         $(LIBVA_CFLAGS)                         \
33         $(NULL)
34
35 libgstvaapi_libs =                              \
36         $(GST_BASE_LIBS)                        \
37         $(GST_BASEVIDEO_LIBS)                   \
38         $(GST_LIBS)                             \
39         $(GST_VIDEO_LIBS)                       \
40         $(GST_CODEC_PARSERS_LIBS)               \
41         $(LIBVA_LIBS)                           \
42         $(top_builddir)/gst-libs/gst/video/libgstvaapi-videoutils.la \
43         $(top_builddir)/gst-libs/gst/codecparsers/libgstvaapi-codecparsers.la
44
45 libgstvaapi_source_c =                          \
46         gstvaapicodec_objects.c                 \
47         gstvaapicontext.c                       \
48         gstvaapidecoder.c                       \
49         gstvaapidecoder_dpb.c                   \
50         gstvaapidecoder_h264.c                  \
51         gstvaapidecoder_mpeg2.c                 \
52         gstvaapidecoder_mpeg4.c                 \
53         gstvaapidecoder_objects.c               \
54         gstvaapidecoder_unit.c                  \
55         gstvaapidecoder_vc1.c                   \
56         gstvaapidisplay.c                       \
57         gstvaapidisplaycache.c                  \
58         gstvaapiimage.c                         \
59         gstvaapiimagepool.c                     \
60         gstvaapiminiobject.c                    \
61         gstvaapiobject.c                        \
62         gstvaapiparser_frame.c                  \
63         gstvaapiprofile.c                       \
64         gstvaapisubpicture.c                    \
65         gstvaapisurface.c                       \
66         gstvaapisurfacepool.c                   \
67         gstvaapisurfaceproxy.c                  \
68         gstvaapiutils.c                         \
69         gstvaapivalue.c                         \
70         gstvaapivideopool.c                     \
71         gstvaapiwindow.c                        \
72         video-format.c                          \
73         $(NULL)
74
75 libgstvaapi_source_h =                          \
76         gstvaapicontext.h                       \
77         gstvaapidecoder.h                       \
78         gstvaapidecoder_h264.h                  \
79         gstvaapidecoder_mpeg2.h                 \
80         gstvaapidecoder_mpeg4.h                 \
81         gstvaapidecoder_vc1.h                   \
82         gstvaapidisplay.h                       \
83         gstvaapidisplaycache.h                  \
84         gstvaapiimage.h                         \
85         gstvaapiimagepool.h                     \
86         gstvaapiobject.h                        \
87         gstvaapiprofile.h                       \
88         gstvaapisubpicture.h                    \
89         gstvaapisurface.h                       \
90         gstvaapisurfacepool.h                   \
91         gstvaapisurfaceproxy.h                  \
92         gstvaapitypes.h                         \
93         gstvaapivalue.h                         \
94         gstvaapivideopool.h                     \
95         gstvaapiwindow.h                        \
96         video-format.h                          \
97         $(NULL)
98
99 libgstvaapi_source_priv_h =                     \
100         glibcompat.h                            \
101         gstcompat.h                             \
102         gstvaapicodec_objects.h                 \
103         gstvaapicompat.h                        \
104         gstvaapidebug.h                         \
105         gstvaapidecoder_dpb.h                   \
106         gstvaapidecoder_objects.h               \
107         gstvaapidecoder_priv.h                  \
108         gstvaapidecoder_unit.h                  \
109         gstvaapidisplay_priv.h                  \
110         gstvaapiminiobject.h                    \
111         gstvaapiobject_priv.h                   \
112         gstvaapiparser_frame.h                  \
113         gstvaapisurface_priv.h                  \
114         gstvaapisurfaceproxy_priv.h             \
115         gstvaapiutils.h                         \
116         gstvaapiversion.h                       \
117         gstvaapivideopool_priv.h                \
118         gstvaapiwindow_priv.h                   \
119         gstvaapiworkarounds.h                   \
120         sysdeps.h                               \
121         $(NULL)
122
123 libgstvaapi_jpegdec_source_c = gstvaapidecoder_jpeg.c
124 libgstvaapi_jpegdec_source_h = gstvaapidecoder_jpeg.h
125 if USE_JPEG_DECODER
126 libgstvaapi_source_c += $(libgstvaapi_jpegdec_source_c)
127 libgstvaapi_source_h += $(libgstvaapi_jpegdec_source_h)
128 endif
129
130 libgstvaapi_drm_source_c =                      \
131         gstvaapidisplay_drm.c                   \
132         gstvaapiwindow_drm.c                    \
133         gstvaapiutils.c                         \
134         $(NULL)
135
136 libgstvaapi_drm_source_h =                      \
137         gstvaapidisplay_drm.h                   \
138         gstvaapiwindow_drm.h                    \
139         $(NULL)
140
141 libgstvaapi_drm_source_priv_h =                 \
142         gstvaapicompat.h                        \
143         gstvaapidisplay_drm_priv.h              \
144         gstvaapiutils.h                         \
145         $(NULL)
146
147 libgstvaapi_x11_source_c =                      \
148         gstvaapidisplay_x11.c                   \
149         gstvaapiutils.c                         \
150         gstvaapiutils_x11.c                     \
151         gstvaapiwindow_x11.c                    \
152         $(NULL)
153
154 libgstvaapi_x11_source_h =                      \
155         gstvaapidisplay_x11.h                   \
156         gstvaapiwindow_x11.h                    \
157         $(NULL)
158
159 libgstvaapi_x11_source_priv_h =                 \
160         gstvaapicompat.h                        \
161         gstvaapidisplay_x11_priv.h              \
162         gstvaapiutils.h                         \
163         gstvaapiutils_x11.h                     \
164         gstvaapiwindow_x11_priv.h               \
165         $(NULL)
166
167 libgstvaapi_glx_source_c =                      \
168         gstvaapidisplay_glx.c                   \
169         gstvaapitexture.c                       \
170         gstvaapiutils.c                         \
171         gstvaapiutils_glx.c                     \
172         gstvaapiutils_x11.c                     \
173         gstvaapiwindow_glx.c                    \
174         $(NULL)
175
176 libgstvaapi_glx_source_h =                      \
177         gstvaapidisplay_glx.h                   \
178         gstvaapitexture.h                       \
179         gstvaapiwindow_glx.h                    \
180         $(NULL)
181
182 libgstvaapi_glx_source_priv_h =                 \
183         gstvaapicompat.h                        \
184         gstvaapidisplay_glx_priv.h              \
185         gstvaapiutils.h                         \
186         gstvaapiutils_glx.h                     \
187         gstvaapiutils_x11.h                     \
188         $(NULL)
189
190 libgstvaapi_wayland_source_c =                  \
191         gstvaapidisplay_wayland.c               \
192         gstvaapiutils.c                         \
193         gstvaapiwindow_wayland.c                \
194         $(NULL)
195
196 libgstvaapi_wayland_source_h =                  \
197         gstvaapidisplay_wayland.h               \
198         gstvaapiwindow_wayland.h                \
199         $(NULL)
200
201 libgstvaapi_wayland_source_priv_h =             \
202         gstvaapicompat.h                        \
203         gstvaapidisplay_wayland_priv.h          \
204         gstvaapiutils.h                         \
205         $(NULL)
206
207 libgstvaapi_@GST_API_VERSION@_la_SOURCES =      \
208         $(libgstvaapi_source_c)                 \
209         $(libgstvaapi_source_priv_h)            \
210         $(NULL)
211
212 libgstvaapi_@GST_API_VERSION@include_HEADERS =  \
213         $(libgstvaapi_source_h)                 \
214         $(NULL)
215
216 libgstvaapi_@GST_API_VERSION@includedir =       \
217         $(libgstvaapi_includedir)
218
219 libgstvaapi_@GST_API_VERSION@_la_CFLAGS =       \
220         $(libgstvaapi_cflags)                   \
221         $(NULL)
222
223 libgstvaapi_@GST_API_VERSION@_la_LIBADD =       \
224         $(libgstvaapi_libs)                     \
225         $(NULL)
226
227 libgstvaapi_@GST_API_VERSION@_la_LDFLAGS =      \
228         $(GST_ALL_LDFLAGS)                      \
229         $(GST_VAAPI_LT_LDFLAGS)                 \
230         -export-symbols-regex "^gst_(.*vaapi|video_format).*" \
231         $(NULL)
232
233 libgstvaapi_drm_@GST_API_VERSION@_la_SOURCES =  \
234         $(libgstvaapi_drm_source_c)             \
235         $(libgstvaapi_drm_source_priv_h)        \
236         $(NULL)
237
238 libgstvaapi_drm_@GST_API_VERSION@include_HEADERS = \
239         $(libgstvaapi_drm_source_h)             \
240         $(NULL)
241
242 libgstvaapi_drm_@GST_API_VERSION@includedir =   \
243         $(libgstvaapi_includedir)
244
245 libgstvaapi_drm_@GST_API_VERSION@_la_CFLAGS =   \
246         -DGST_USE_UNSTABLE_API                  \
247         -I$(top_srcdir)/gst-libs                \
248         $(GLIB_CFLAGS)                          \
249         $(GST_BASE_CFLAGS)                      \
250         $(UDEV_CFLAGS)                          \
251         $(DRM_CFLAGS)                           \
252         $(LIBVA_DRM_CFLAGS)                     \
253         $(NULL)
254
255 libgstvaapi_drm_@GST_API_VERSION@_la_LIBADD =   \
256         $(GLIB_LIBS)                            \
257         $(UDEV_LIBS)                            \
258         $(DRM_LIBS)                             \
259         $(LIBVA_DRM_LIBS)                       \
260         libgstvaapi-$(GST_API_VERSION).la       \
261         $(NULL)
262
263 libgstvaapi_drm_@GST_API_VERSION@_la_LDFLAGS =  \
264         $(GST_ALL_LDFLAGS)                      \
265         $(GST_VAAPI_LT_LDFLAGS)                 \
266         $(NULL)
267
268 libgstvaapi_x11_@GST_API_VERSION@_la_SOURCES =  \
269         $(libgstvaapi_x11_source_c)             \
270         $(libgstvaapi_x11_source_priv_h)        \
271         $(NULL)
272
273 libgstvaapi_x11_@GST_API_VERSION@include_HEADERS = \
274         $(libgstvaapi_x11_source_h)             \
275         $(NULL)
276
277 libgstvaapi_x11_@GST_API_VERSION@includedir =   \
278         $(libgstvaapi_includedir)
279
280 libgstvaapi_x11_@GST_API_VERSION@_la_CFLAGS =   \
281         -DGST_USE_UNSTABLE_API                  \
282         -I$(top_srcdir)/gst-libs                \
283         $(GLIB_CFLAGS)                          \
284         $(GST_BASE_CFLAGS)                      \
285         $(X11_CFLAGS)                           \
286         $(XRANDR_CFLAGS)                        \
287         $(LIBVA_X11_CFLAGS)                     \
288         $(NULL)
289
290 libgstvaapi_x11_@GST_API_VERSION@_la_LIBADD =   \
291         $(GLIB_LIBS)                            \
292         $(X11_LIBS)                             \
293         $(XRANDR_LIBS)                          \
294         $(LIBVA_X11_LIBS)                       \
295         libgstvaapi-$(GST_API_VERSION).la       \
296         $(NULL)
297
298 libgstvaapi_x11_@GST_API_VERSION@_la_LDFLAGS =  \
299         $(GST_ALL_LDFLAGS)                      \
300         $(GST_VAAPI_LT_LDFLAGS)                 \
301         $(NULL)
302
303 libgstvaapi_glx_@GST_API_VERSION@_la_SOURCES =  \
304         $(libgstvaapi_glx_source_c)             \
305         $(libgstvaapi_glx_source_priv_h)        \
306         $(NULL)
307
308 libgstvaapi_glx_@GST_API_VERSION@include_HEADERS = \
309         $(libgstvaapi_glx_source_h)             \
310         $(NULL)
311
312 libgstvaapi_glx_@GST_API_VERSION@includedir =   \
313         $(libgstvaapi_includedir)
314
315 libgstvaapi_glx_@GST_API_VERSION@_la_CFLAGS =   \
316         -DGST_USE_UNSTABLE_API                  \
317         -I$(top_srcdir)/gst-libs                \
318         $(GLIB_CFLAGS)                          \
319         $(GST_BASE_CFLAGS)                      \
320         $(GST_VIDEO_CFLAGS)                     \
321         $(GL_CFLAGS)                            \
322         $(LIBVA_GLX_CFLAGS)                     \
323         $(NULL)
324
325 libgstvaapi_glx_@GST_API_VERSION@_la_LIBADD =   \
326         $(GLIB_LIBS)                            \
327         $(GST_BASE_LIBS)                        \
328         $(GST_VIDEO_LIBS)                       \
329         $(GL_LIBS)                              \
330         $(LIBVA_GLX_LIBS)                       \
331         libgstvaapi-x11-$(GST_API_VERSION).la   \
332         $(DLOPEN_LIBS)                          \
333         $(NULL)
334
335 libgstvaapi_glx_@GST_API_VERSION@_la_LDFLAGS =  \
336         $(GST_ALL_LDFLAGS)                      \
337         $(GST_VAAPI_LT_LDFLAGS)                 \
338         $(NULL)
339
340 libgstvaapi_wayland_@GST_API_VERSION@_la_SOURCES = \
341         $(libgstvaapi_wayland_source_c)         \
342         $(libgstvaapi_wayland_source_priv_h)    \
343         $(NULL)
344
345 libgstvaapi_wayland_@GST_API_VERSION@include_HEADERS = \
346         $(libgstvaapi_wayland_source_h)         \
347         $(NULL)
348
349 libgstvaapi_wayland_@GST_API_VERSION@includedir = \
350         $(libgstvaapi_includedir)
351
352 libgstvaapi_wayland_@GST_API_VERSION@_la_CFLAGS = \
353         -DGST_USE_UNSTABLE_API                  \
354         -I$(top_srcdir)/gst-libs                \
355         $(GLIB_CFLAGS)                          \
356         $(GST_BASE_CFLAGS)                      \
357         $(WAYLAND_CFLAGS)                       \
358         $(LIBVA_WAYLAND_CFLAGS)                 \
359         $(NULL)
360
361 libgstvaapi_wayland_@GST_API_VERSION@_la_LIBADD = \
362         $(GLIB_LIBS)                            \
363         $(WAYLAND_LIBS)                         \
364         $(LIBVA_WAYLAND_LIBS)                   \
365         libgstvaapi-$(GST_API_VERSION).la       \
366         $(NULL)
367
368 libgstvaapi_wayland_@GST_API_VERSION@_la_LDFLAGS = \
369         $(GST_ALL_LDFLAGS)                      \
370         $(GST_VAAPI_LT_LDFLAGS)                 \
371         $(NULL)
372
373 VERSION_FILE            = .VERSION
374 OLD_VERSION_FILE        = $(VERSION_FILE).old
375 NEW_VERSION_FILE        = $(VERSION_FILE).new
376 PKG_VERSION_FILE        = $(VERSION_FILE).pkg
377
378 gstvaapiversion.h: gen-version
379         $(AM_V_GEN)                                                         \
380         OV=`[ -f $(OLD_VERSION_FILE) ] && cat $(OLD_VERSION_FILE) || :`;    \
381         NV=`cat $(NEW_VERSION_FILE)`;                                       \
382         if [ "$$OV" != "$$NV" -o ! -f gstvaapiversion.h ]; then             \
383                 cp -f $(NEW_VERSION_FILE) $(OLD_VERSION_FILE);              \
384                 $(SED) -e "s|\@GST_VAAPI_VERSION_ID\@|$${NV}|"              \
385                         $(srcdir)/gstvaapiversion.h.in > gstvaapiversion.h; \
386         fi
387
388 gen-version:
389         @echo $(VERSION) > $(NEW_VERSION_FILE)
390 if HAVE_GIT
391         @[ -d $(top_srcdir)/.git ] && \
392         (cd $(top_srcdir) && $(GIT) describe --tags) > $(NEW_VERSION_FILE) || :
393 endif
394         @[ -f $(srcdir)/$(PKG_VERSION_FILE) ] && \
395         cp -f $(srcdir)/$(PKG_VERSION_FILE) $(NEW_VERSION_FILE) || :
396
397 $(PKG_VERSION_FILE): $(NEW_VERSION_FILE)
398         @cp -f $< $@
399
400 BUILT_SOURCES   = gstvaapiversion.h
401 EXTRA_DIST      = gstvaapiversion.h.in $(PKG_VERSION_FILE)
402
403 EXTRA_DIST += \
404         $(libgstvaapi_jpegdec_source_c) \
405         $(libgstvaapi_jpegdec_source_h) \
406         $(NULL)
407
408 CLEANFILES = \
409         $(OLD_VERSION_FILE)     \
410         $(NEW_VERSION_FILE)     \
411         $(PKG_VERSION_FILE)     \
412         $(NULL)
413
414 # Extra clean files so that maintainer-clean removes *everything*
415 MAINTAINERCLEANFILES = Makefile.in