mkv: abort if read fails during seek
[vlc.git] / modules / video_output / Makefile.am
1 voutdir = $(pluginsdir)/video_output
2 vout_LTLIBRARIES =
3
4 EXTRA_DIST += video_output/README
5
6 if HAVE_DECKLINK
7 libdecklinkoutput_plugin_la_SOURCES = video_output/decklink.cpp
8 libdecklinkoutput_plugin_la_CXXFLAGS = $(AM_CXXFLAGS) $(CPPFLAGS_decklinkoutput)
9 libdecklinkoutput_plugin_la_LIBADD = $(LIBS_decklink) $(LIBDL) -lpthread
10 vout_LTLIBRARIES += libdecklinkoutput_plugin.la
11 endif
12
13 if HAVE_OSX
14 libvout_macosx_plugin_la_SOURCES = video_output/macosx.m video_output/opengl.c video_output/opengl.h
15 libvout_macosx_plugin_la_CFLAGS = $(AM_CFLAGS)
16 libvout_macosx_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)' -Wl,-framework,OpenGL,-framework,Cocoa
17
18 libcaopengllayer_plugin_la_SOURCES = video_output/caopengllayer.m video_output/opengl.c video_output/opengl.h
19 libcaopengllayer_plugin_la_CFLAGS = $(AM_CFLAGS)
20 libcaopengllayer_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)' -Wl,-framework,OpenGL,-framework,Cocoa,-framework,QuartzCore
21 vout_LTLIBRARIES += libvout_macosx_plugin.la libcaopengllayer_plugin.la
22 endif
23
24 libvout_ios2_plugin_la_SOURCES = video_output/ios2.m video_output/opengl.h video_output/opengl.c
25 libvout_ios2_plugin_la_CFLAGS = $(AM_CFLAGS)
26 libvout_ios2_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)' -Wl,-framework,OpenGLES,-framework,QuartzCore,-framework,UIKit
27 if HAVE_IOS
28 vout_LTLIBRARIES += libvout_ios2_plugin.la
29 endif
30 if HAVE_TVOS
31 vout_LTLIBRARIES += libvout_ios2_plugin.la
32 endif
33
34 ### OpenGL ###
35 # TODO: merge all three source files (?)
36 libgles2_plugin_la_SOURCES = video_output/opengl.c video_output/opengl.h \
37         video_output/gl.c
38 libgles2_plugin_la_CFLAGS = $(AM_CFLAGS) $(GLES2_CFLAGS) -DUSE_OPENGL_ES=2
39 libgles2_plugin_la_LIBADD = $(GLES2_LIBS)
40 libgles2_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
41
42 libgles1_plugin_la_SOURCES = video_output/opengl.c video_output/opengl.h \
43         video_output/gl.c
44 libgles1_plugin_la_CFLAGS = $(AM_CFLAGS) $(GLES1_CFLAGS) -DUSE_OPENGL_ES=1
45 libgles1_plugin_la_LIBADD = $(GLES1_LIBS)
46 libgles1_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
47
48 EXTRA_LTLIBRARIES += libgles2_plugin.la libgles1_plugin.la
49 vout_LTLIBRARIES += $(LTLIBgles2) $(LTLIBgles1)
50
51 libgl_plugin_la_SOURCES = video_output/opengl.c video_output/opengl.h \
52         video_output/gl.c
53 libgl_plugin_la_CFLAGS = $(AM_CFLAGS) $(GL_CFLAGS)
54 libgl_plugin_la_LIBADD = $(GL_LIBS)
55 if HAVE_GL
56 vout_LTLIBRARIES += libgl_plugin.la
57 endif
58
59
60 ### XCB ###
61 libvlc_xcb_events_la_SOURCES = \
62         video_output/xcb/events.c video_output/xcb/events.h
63 libvlc_xcb_events_la_CPPFLAGS = -DMODULE_STRING=\"xcb\"
64 libvlc_xcb_events_la_CFLAGS = $(AM_CFLAGS) $(XCB_CFLAGS)
65 libvlc_xcb_events_la_LDFLAGS = -static
66 libvlc_xcb_events_la_LIBADD = $(XCB_LIBS)
67
68 libxcb_x11_plugin_la_SOURCES = \
69         video_output/xcb/pictures.c video_output/xcb/pictures.h \
70         video_output/xcb/x11.c
71 libxcb_x11_plugin_la_CFLAGS = $(AM_CFLAGS) \
72         $(XCB_CFLAGS) $(XCB_SHM_CFLAGS)
73 libxcb_x11_plugin_la_LIBADD = libvlc_xcb_events.la \
74         $(XCB_LIBS) $(XCB_SHM_LIBS)
75
76 libxcb_xv_plugin_la_SOURCES = \
77         video_output/xcb/pictures.c video_output/xcb/pictures.h \
78         video_output/xcb/xvideo.c
79 libxcb_xv_plugin_la_CFLAGS = $(AM_CFLAGS) \
80         $(XCB_CFLAGS) $(XCB_SHM_CFLAGS) $(XCB_XV_CFLAGS)
81 libxcb_xv_plugin_la_LIBADD = libvlc_xcb_events.la \
82         $(XCB_LIBS) $(XCB_SHM_LIBS) $(XCB_XV_LIBS)
83
84 libxcb_glx_plugin_la_SOURCES = \
85         video_output/opengl.c video_output/opengl.h \
86         video_output/xcb/glx.c
87 libxcb_glx_plugin_la_CFLAGS = $(AM_CFLAGS) \
88         $(XCB_CFLAGS) $(GL_CFLAGS)
89 libxcb_glx_plugin_la_LIBADD = libvlc_xcb_events.la \
90         $(XCB_LIBS) $(GL_LIBS)
91
92 libxcb_window_plugin_la_SOURCES =  \
93         video_output/xcb/keys.c \
94         video_output/xcb/keysym.h video_output/xcb/xcb_keysym.h \
95         video_output/xcb/window.c
96 libxcb_window_plugin_la_CFLAGS = $(AM_CFLAGS) \
97         $(CFLAGS_xcb_window) \
98         $(XPROTO_CFLAGS) $(XCB_CFLAGS) $(XCB_KEYSYMS_CFLAGS)
99 libxcb_window_plugin_la_LIBADD = $(XPROTO_LIBS) $(XCB_LIBS) $(XCB_KEYSYMS_LIBS)
100
101 libegl_x11_plugin_la_SOURCES = video_output/egl.c
102 libegl_x11_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) -DUSE_PLATFORM_X11=1
103 libegl_x11_plugin_la_CFLAGS = $(AM_CFLAGS) $(EGL_CFLAGS)
104 libegl_x11_plugin_la_LIBADD = $(EGL_LIBS) $(X_LIBS) $(X_PRE_LIBS) -lX11
105
106 libglx_plugin_la_SOURCES = video_output/glx.c
107 libglx_plugin_la_CFLAGS = $(AM_CFLAGS) $(GL_CFLAGS)
108 libglx_plugin_la_LIBADD = $(GL_LIBS) $(X_LIBS) $(X_PRE_LIBS) -lX11
109
110 if HAVE_XCB
111 noinst_LTLIBRARIES += libvlc_xcb_events.la
112 vout_LTLIBRARIES += libxcb_x11_plugin.la libxcb_window_plugin.la
113 if HAVE_XCB_KEYSYMS
114 libxcb_window_plugin_la_CFLAGS += -DHAVE_XCB_KEYSYMS
115 endif
116 if HAVE_XCB_XVIDEO
117 vout_LTLIBRARIES += libxcb_xv_plugin.la
118 endif
119 if HAVE_EGL
120 vout_LTLIBRARIES += libegl_x11_plugin.la
121 endif
122 if HAVE_GL
123 vout_LTLIBRARIES += libxcb_glx_plugin.la libglx_plugin.la
124 endif
125 endif
126
127
128 ### Wayland ###
129 libwl_shm_plugin_la_SOURCES = video_output/wayland/shm.c
130 nodist_libwl_shm_plugin_la_SOURCES = video_output/wayland/scaler-protocol.c
131 libwl_shm_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
132         -I$(builddir)/video_output/wayland
133 libwl_shm_plugin_la_CFLAGS = $(WAYLAND_CLIENT_CFLAGS)
134 libwl_shm_plugin_la_LIBADD = $(WAYLAND_CLIENT_LIBS)
135 EXTRA_DIST += video_output/wayland/scaler.xml
136 CLEANFILES += $(nodist_libwl_shm_plugin_la_SOURCES)
137
138 libwl_shell_surface_plugin_la_SOURCES = video_output/wayland/shell_surface.c
139 libwl_shell_surface_plugin_la_CFLAGS = $(WAYLAND_CLIENT_CFLAGS)
140 libwl_shell_surface_plugin_la_LIBADD = $(WAYLAND_CLIENT_LIBS) $(LIBPTHREAD)
141
142 libegl_wl_plugin_la_SOURCES = video_output/egl.c
143 libegl_wl_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) -DUSE_PLATFORM_WAYLAND=1
144 libegl_wl_plugin_la_CFLAGS = $(AM_CFLAGS) $(EGL_CFLAGS) $(WAYLAND_EGL_CFLAGS)
145 libegl_wl_plugin_la_LIBADD = $(EGL_LIBS) $(WAYLAND_EGL_LIBS)
146
147 if HAVE_WAYLAND
148 BUILT_SOURCES += video_output/wayland/scaler-client-protocol.h
149 vout_LTLIBRARIES += libwl_shm_plugin.la
150 vout_LTLIBRARIES += libwl_shell_surface_plugin.la
151 if HAVE_WAYLAND_EGL
152 if HAVE_EGL
153 vout_LTLIBRARIES += libegl_wl_plugin.la
154 endif
155 endif
156 endif
157
158
159 ### Win32 ###
160 libdirect2d_plugin_la_SOURCES = video_output/win32/direct2d.c \
161         video_output/win32/common.c video_output/win32/common.h \
162         video_output/win32/events.c video_output/win32/events.h \
163         video_output/win32/win32touch.c video_output/win32/win32touch.h
164 libdirect2d_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
165         -DMODULE_NAME_IS_direct2d
166 libdirect2d_plugin_la_LIBADD = -lgdi32 -lole32 -luuid
167 libdirect2d_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
168 if HAVE_WIN32_DESKTOP
169 vout_LTLIBRARIES += $(LTLIBdirect2d)
170 EXTRA_LTLIBRARIES += libdirect2d_plugin.la
171 endif
172
173 libdirect3d9_plugin_la_SOURCES = video_output/win32/direct3d9.c \
174         video_output/win32/common.c video_output/win32/common.h \
175         video_output/win32/events.c video_output/win32/events.h \
176         video_output/win32/builtin_shaders.h \
177         video_output/win32/win32touch.c video_output/win32/win32touch.h
178 libdirect3d9_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
179         -DMODULE_NAME_IS_direct3d9
180 libdirect3d9_plugin_la_LIBADD = -lgdi32 -lole32 -luuid
181 libdirect3d9_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
182 if HAVE_WIN32_DESKTOP
183 vout_LTLIBRARIES += $(LTLIBdirect3d9)
184 EXTRA_LTLIBRARIES += libdirect3d9_plugin.la
185 endif
186
187 libdirect3d11_plugin_la_SOURCES = video_output/win32/direct3d11.c \
188  video_chroma/dxgi_fmt.c video_chroma/dxgi_fmt.h \
189  video_output/win32/common.c video_output/win32/common.h
190 libdirect3d11_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
191  -DMODULE_NAME_IS_direct3d11
192 if !HAVE_WINSTORE
193 libdirect3d11_plugin_la_SOURCES += video_output/win32/events.c \
194  video_output/win32/events.h \
195  video_output/win32/win32touch.c video_output/win32/win32touch.h
196 libdirect3d11_plugin_la_LIBADD = -lgdi32 -lole32 -luuid
197 else
198 libdirect3d11_plugin_la_LIBADD = -ld3dcompiler_47 -lole32 -luuid
199 endif
200 libdirect3d11_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
201 vout_LTLIBRARIES += $(LTLIBdirect3d11)
202 EXTRA_LTLIBRARIES += libdirect3d11_plugin.la
203
204 libdirectdraw_plugin_la_SOURCES = video_output/win32/directdraw.c \
205         video_output/win32/common.c video_output/win32/common.h \
206         video_output/win32/events.c video_output/win32/events.h \
207         video_output/win32/win32touch.c video_output/win32/win32touch.h
208 libdirectdraw_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
209         -DMODULE_NAME_IS_directdraw
210 libdirectdraw_plugin_la_LIBADD = -luser32 -lgdi32 -lole32 -luuid
211 libdirectdraw_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
212 if HAVE_WIN32_DESKTOP
213 vout_LTLIBRARIES += $(LTLIBdirectdraw)
214 EXTRA_LTLIBRARIES += libdirectdraw_plugin.la
215 endif
216
217 libglwin32_plugin_la_SOURCES = video_output/win32/glwin32.c \
218         video_output/opengl.c video_output/opengl.h \
219         video_output/win32/common.c video_output/win32/common.h \
220         video_output/win32/events.c video_output/win32/events.h \
221         video_output/win32/win32touch.c video_output/win32/win32touch.h
222 libwgl_plugin_la_SOURCES = video_output/win32/wgl.c \
223         video_output/opengl.c video_output/opengl.h
224
225 libglwin32_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
226         -DMODULE_NAME_IS_glwin32
227 libwgl_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
228         -DMODULE_NAME_IS_wgl
229
230 libglwin32_plugin_la_LIBADD = -lopengl32 -lgdi32 -lole32 -luuid
231 libwgl_plugin_la_LIBADD = -lopengl32 -lgdi32
232
233 libglwin32_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
234 libwgl_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
235
236 if HAVE_WIN32_DESKTOP
237 vout_LTLIBRARIES += $(LTLIBglwin32) $(LTLIBwgl)
238 EXTRA_LTLIBRARIES += libglwin32_plugin.la libwgl_plugin.la
239 endif
240
241 libwingdi_plugin_la_SOURCES = video_output/win32/wingdi.c \
242         video_output/win32/common.c video_output/win32/common.h \
243         video_output/win32/events.c video_output/win32/events.h \
244         video_output/win32/win32touch.c video_output/win32/win32touch.h
245 libwingdi_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) \
246         -DMODULE_NAME_IS_wingdi
247 libwingdi_plugin_la_LIBADD = -lgdi32 -lole32 -luuid
248 if HAVE_WIN32_DESKTOP
249 vout_LTLIBRARIES += libwingdi_plugin.la
250 endif
251
252 libegl_win32_plugin_la_SOURCES = video_output/egl.c
253 libegl_win32_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) -DUSE_PLATFORM_WIN32=1
254 libegl_win32_plugin_la_CFLAGS = $(AM_CFLAGS) $(EGL_CFLAGS)
255 libegl_win32_plugin_la_LIBADD = $(EGL_LIBS)
256 if HAVE_WIN32
257 if HAVE_EGL
258 vout_LTLIBRARIES += libegl_win32_plugin.la
259 endif
260 endif
261
262 libdrawable_plugin_la_SOURCES = video_output/drawable.c
263 if HAVE_WIN32
264 vout_LTLIBRARIES += libdrawable_plugin.la
265 endif
266
267 ### OS/2 ###
268 if HAVE_OS2
269 vout_LTLIBRARIES += libdrawable_plugin.la
270 endif
271
272 libkva_plugin_la_SOURCES = video_output/kva.c
273 libkva_plugin_la_LIBADD = $(KVA_LIBS)
274 if HAVE_KVA
275 vout_LTLIBRARIES += libkva_plugin.la
276 endif
277
278
279 ### Android ###
280
281 libegl_android_plugin_la_SOURCES = video_output/egl.c
282 libegl_android_plugin_la_CFLAGS = $(AM_CFLAGS) $(EGL_CFLAGS) -DUSE_PLATFORM_ANDROID=1
283 libegl_android_plugin_la_LIBADD = $(EGL_LIBS)
284
285 libandroid_native_window_plugin_la_SOURCES = video_output/android/nativewindow.c \
286         video_output/android/utils.c video_output/android/utils.h
287 libandroid_native_window_plugin_la_CFLAGS = $(AM_CFLAGS)
288 libandroid_native_window_plugin_la_LIBADD = $(LIBDL)
289
290 libandroid_window_plugin_la_SOURCES = video_output/android/android_window.c video_output/android/android_window.h video_output/android/utils.c video_output/android/utils.h
291 libandroid_window_plugin_la_CFLAGS = $(AM_CFLAGS)
292 libandroid_window_plugin_la_LIBADD = $(LIBDL)
293 libandroid_window_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
294
295 if HAVE_ANDROID
296 vout_LTLIBRARIES += libandroid_native_window_plugin.la libandroid_window_plugin.la
297 vout_LTLIBRARIES += $(LTLIBandroid_window)
298 if HAVE_EGL
299 vout_LTLIBRARIES += libegl_android_plugin.la
300 endif
301 endif
302
303
304 ### FrameBuffer ###
305
306 libdirectfb_plugin_la_SOURCES = video_output/directfb.c
307 libdirectfb_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) $(CPPFLAGS_directfb)
308 libdirectfb_plugin_la_LIBADD = $(LIBS_directfb)
309 libdirectfb_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
310 EXTRA_LTLIBRARIES += libdirectfb_plugin.la
311 vout_LTLIBRARIES += $(LTLIBdirectfb)
312
313 libfb_plugin_la_SOURCES = video_output/fb.c
314 libfb_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
315 EXTRA_LTLIBRARIES += libfb_plugin.la
316 vout_LTLIBRARIES += $(LTLIBfb)
317
318
319 ### Simple DirectMedia Layer ###
320 libvout_sdl_plugin_la_SOURCES = video_output/sdl.c
321 libvout_sdl_plugin_la_CFLAGS = $(AM_CFLAGS) $(SDL_CFLAGS)
322 libvout_sdl_plugin_la_LIBADD = $(SDL_LIBS)
323 if !HAVE_WIN32
324 if !HAVE_OS2
325 libvout_sdl_plugin_la_LIBADD += $(X_LIBS) $(X_PRE_LIBS) -lX11
326 endif
327 endif
328 libvout_sdl_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
329 EXTRA_LTLIBRARIES += libvout_sdl_plugin.la
330 vout_LTLIBRARIES += $(LTLIBvout_sdl)
331
332
333
334 ### ASCII Art ###
335 libaa_plugin_la_SOURCES = video_output/aa.c
336 libaa_plugin_la_LIBADD = -laa
337 if !HAVE_WIN32
338 libaa_plugin_la_LIBADD += $(X_LIBS) $(X_PRE_LIBS) -lX11
339 endif
340 libaa_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
341 EXTRA_LTLIBRARIES += libaa_plugin.la
342 vout_LTLIBRARIES += $(LTLIBaa)
343
344
345 ### Coloured ASCII art ###
346 libcaca_plugin_la_SOURCES = video_output/caca.c
347 libcaca_plugin_la_CFLAGS = $(AM_CFLAGS) $(CACA_CFLAGS)
348 libcaca_plugin_la_LIBADD = $(CACA_LIBS)
349 if !HAVE_WIN32
350 if !HAVE_DARWIN
351 libcaca_plugin_la_LIBADD += $(X_LIBS) $(X_PRE_LIBS) -lX11
352 endif
353 endif
354 libcaca_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
355 EXTRA_LTLIBRARIES += libcaca_plugin.la
356 vout_LTLIBRARIES += $(LTLIBcaca)
357
358
359 ### EFL Evas video output ###
360 libevas_plugin_la_SOURCES = video_output/evas.c
361 libevas_plugin_la_CFLAGS = $(AM_CFLAGS) $(EVAS_CFLAGS)
362 libevas_plugin_la_LIBADD = $(EVAS_LIBS)
363 libevas_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(voutdir)'
364 if HAVE_EVAS
365 vout_LTLIBRARIES += libevas_plugin.la
366 endif
367
368
369 ### Common ###
370 libvdummy_plugin_la_SOURCES = video_output/vdummy.c
371 libvmem_plugin_la_SOURCES = video_output/vmem.c
372 libyuv_plugin_la_SOURCES = video_output/yuv.c
373
374 vout_LTLIBRARIES += \
375         libvdummy_plugin.la \
376         libvmem_plugin.la \
377         libyuv_plugin.la