1 # gstreamer-vaapi package version number
2 m4_define([gst_vaapi_major_version], [1])
3 m4_define([gst_vaapi_minor_version], [17])
4 m4_define([gst_vaapi_micro_version], [0])
5 m4_define([gst_vaapi_nano_version], [1])
6 m4_define([gst_vaapi_version],
7 [gst_vaapi_major_version.gst_vaapi_minor_version.gst_vaapi_micro_version])
8 m4_if(gst_vaapi_nano_version, [0], [],
9 [m4_append([gst_vaapi_version], gst_vaapi_nano_version, [.])])
12 m4_define([default_glapi], [any])
14 dnl - library source changed -> increment REVISION
15 dnl - interfaces added/removed/changed -> increment CURRENT, REVISION = 0
16 dnl - interfaces added -> increment AGE
17 dnl - interfaces removed -> AGE = 0
18 # gstreamer-vaapi library (libtool) version number
19 m4_define([gst_vaapi_lt_current], [1700])
20 m4_define([gst_vaapi_lt_revision], [0])
21 m4_define([gst_vaapi_lt_age], [1700])
24 m4_define([glib_version], [2.40])
26 # gstreamer version number
27 m4_define([gst_version], [1.17.0.1])
28 m4_define([gst_plugins_base_version], [1.17.0.1])
29 m4_define([gst_plugins_bad_version], [1.17.0.1])
31 # Wayland minimum version number
32 m4_define([wayland_api_version], [1.11.0])
34 # VA-API minimum version number
35 m4_define([va_api_version], [0.39.0])
37 # gtk-doc version number
38 # XXX: introspection annotations require gtk-doc >= 1.12
39 m4_define([gtkdoc_version], [1.12])
42 AC_INIT([GStreamer VA-API Plug-ins], [gst_vaapi_version],
43 [http://bugzilla.gnome.org/enter_bug.cgi?product=GStreamer],
46 dnl define the output header for config
47 AC_CONFIG_HEADERS([config.h])
48 AC_CONFIG_SRCDIR([Makefile.am])
49 AC_CONFIG_MACRO_DIR([m4])
50 AC_CONFIG_AUX_DIR([build-aux])
54 dnl initialize automake
55 AM_INIT_AUTOMAKE([-Wno-portability 1.14 no-dist-gzip dist-xz tar-ustar subdir-objects])
57 dnl define PACKAGE_VERSION_* variables
60 dnl check if this is a release version
61 AS_NANO(GST_GIT="no", GST_GIT="yes")
63 dnl AM_MAINTAINER_MODE only provides the option to configure to enable it
64 AM_MAINTAINER_MODE([enable])
66 dnl use pretty build output by default
67 AM_SILENT_RULES([yes])
69 dnl our libraries and install dirs use GST_API_VERSION in the filename
70 dnl to allow side-by-side installation of different API versions
72 AC_SUBST([GST_API_VERSION])
73 AC_DEFINE_UNQUOTED([GST_API_VERSION], ["$GST_API_VERSION"],
74 [GStreamer API Version])
76 AG_GST_LIBTOOL_PREPARE
78 dnl CURRENT, REVISION, AGE
79 dnl sets GST_LT_LDFLAGS
80 AS_LIBTOOL(GST, gst_vaapi_lt_current, gst_vaapi_lt_revision, gst_vaapi_lt_age)
82 dnl *** required versions of GStreamer stuff ***
85 GST_PBREQ=gst_plugins_base_version
86 GST_PBADREQ=gst_plugins_bad_version
87 WAYLAND_REQ=wayland_api_version
88 GTKDOC_REQ=gtkdoc_version
90 dnl *** required versions of VA-API stuff ***
91 VAAPI_REQ=va_api_version
93 dnl *** autotools stuff ****
95 dnl allow for different autotools
96 AS_AUTOTOOLS_ALTERNATE
98 dnl Add parameters for aclocal
99 AC_SUBST([ACLOCAL_AMFLAGS], ["-I m4 -I common/m4"])
101 dnl *** check for arguments to configure ***
103 AG_GST_ARG_DISABLE_FATAL_WARNINGS
104 AG_GST_ARG_ENABLE_EXTRA_CHECKS
109 AG_GST_ARG_WITH_PKG_CONFIG_PATH
111 AG_GST_SET_PACKAGE_RELEASE_DATETIME_WITH_NANO([$PACKAGE_VERSION_NANO],
112 ["${srcdir}/gstreamer-vaapi.doap"],
113 [$PACKAGE_VERSION_MAJOR.$PACKAGE_VERSION_MINOR.$PACKAGE_VERSION_MICRO])
115 AC_ARG_ENABLE([encoders],
116 AS_HELP_STRING([--enable-encoders],
117 [enable video encoders @<:@default=yes@:>@]),
118 [], [enable_encoders="yes"])
121 AS_HELP_STRING([--enable-drm],
122 [enable DRM backend @<:@default=yes@:>@]),
123 [], [enable_drm="yes"])
126 AS_HELP_STRING([--enable-x11],
127 [enable X11 output @<:@default=yes@:>@]),
128 [], [enable_x11="yes"])
131 AS_HELP_STRING([--enable-glx],
132 [enable OpenGL/X11 output @<:@default=yes@:>@]),
133 [], [enable_glx="yes"])
135 AC_ARG_ENABLE([wayland],
136 AC_HELP_STRING([--enable-wayland],
137 [enable Wayland output @<:@default=yes@:>@]),
138 [], [enable_wayland="yes"])
141 AS_HELP_STRING([--enable-egl],
142 [enable EGL output @<:@default=yes@:>@]),
143 [], [enable_egl="yes"])
146 AS_HELP_STRING([--with-glapi=APIs],
147 [build with the specified OpenGL APIs @<:@default=default_glapi@:>@]),
148 [GLAPI="$with_glapi"], [GLAPI=default_glapi])
151 [AS_HELP_STRING([--with-gtk],
152 [compile GTK3 based test apps @<:@default=check@:>@])],
153 [], [with_gtk="check"])
155 dnl *** checks for platform ***
157 dnl * hardware/architecture *
162 dnl *** checks for programs ***
168 dnl check if the compiler supports '-c' and '-o' options
171 dnl check for documentation tools
172 GTK_DOC_CHECK([$GTKDOC_REQ])
173 AG_GST_PLUGIN_DOCS([$GTKDOC_REQ])
175 dnl *** checks for libraries ***
176 dnl check for libm, for sin() etc.
177 AC_CHECK_LIB([m], [tan])
179 dnl Check to see if dlopen/dlsym is in default libraries (like
180 dnl Solaris, which has it in libc), or if libdl is needed to get it.
181 AC_CHECK_FUNC([dlopen], [], [
182 AC_CHECK_LIB([dl], [dlopen], [DLOPEN_LIBS="-ldl"])])
183 AC_SUBST([DLOPEN_LIBS])
185 dnl define LIBDIR so we can inform people where we live
186 AS_AC_EXPAND([LIBDIR], [$libdir])
187 AC_DEFINE_UNQUOTED([LIBDIR], ["$LIBDIR"], [library dir])
189 dnl set location of plugin directory
192 dnl *** checks for header files ***
194 dnl *** checks for types/defines ***
196 dnl *** checks for structures ***
198 dnl *** checks for compiler characteristics ***
200 dnl *** checks for library functions ***
202 dnl *** checks for headers ***
204 dnl *** checks for dependency libraries ***
206 dnl ---------------------------------------------------------------------------
208 dnl ---------------------------------------------------------------------------
210 AG_GST_GLIB_CHECK([$GLIB_REQ])
212 dnl checks for gstreamer
213 dnl uninstalled is selected preferentially -- see pkg-config(1)
214 AG_GST_CHECK_GST([$GST_API_VERSION], [$GST_REQ], [yes])
216 dnl back compatibility
217 AC_MSG_CHECKING([for GStreamer API version])
218 gst_api_version=`$PKG_CONFIG --modversion "gstreamer-$GST_API_VERSION"`
219 gst_major_version=`echo "$gst_api_version" | cut -d'.' -f1`
220 gst_minor_version=`echo "$gst_api_version" | cut -d'.' -f2`
221 GST_VERSION="${gst_major_version}.${gst_minor_version}"
222 AC_MSG_RESULT([$GST_VERSION])
223 AC_DEFINE_UNQUOTED([GST_API_VERSION_S], ["$GST_VERSION"],
224 [Defined to the string representation of GStreamer version])
226 AG_GST_CHECK_GST_BASE([$GST_API_VERSION], [$GST_REQ], [yes])
227 AG_GST_CHECK_GST_PLUGINS_BASE([$GST_API_VERSION], [$GST_PBREQ], [yes])
229 dnl gst_dmabuf_memory_get_fd (gstreamer-allocators)
230 AG_GST_CHECK_MODULES([GST_ALLOCATORS],
231 [gstreamer-allocators-$GST_API_VERSION], [$GST_PBREQ], [yes])
233 dnl GstVideoOverlayComposition (gstreamer-video)
234 AG_GST_CHECK_MODULES([GST_VIDEO],
235 [gstreamer-video-$GST_API_VERSION], [$GST_PBREQ], [yes])
237 dnl ... GStreamer base utils (gstreamer-pbutils)
238 AG_GST_CHECK_MODULES([GST_PBUTILS],
239 [gstreamer-pbutils-$GST_API_VERSION], [$GST_PBREQ], [yes])
241 dnl bitstream parsers (gstreamer-codecparsers)
242 AG_GST_CHECK_MODULES([GST_CODEC_PARSERS],
243 [gstreamer-codecparsers-$GST_API_VERSION], [$GST_PBADREQ], [yes])
245 AS_IF([test "x$enable_glx" = "xyes" -o "x$enable_egl" = "xyes"],
246 [enable_opengl="yes"], [enable_opengl="no"])
248 dnl ... opengl helper libraries
250 if test "x$enable_opengl" = "xyes"; then
251 PKG_CHECK_MODULES([GST_GL],
252 [gstreamer-gl-$GST_API_VERSION >= $GST_PBADREQ],
255 AC_CACHE_CHECK([for GStreamer OpenGL helper libraries],
256 [ac_cv_have_gst_gl_helpers],
258 saved_CPPFLAGS="$CPPFLAGS"
259 CPPFLAGS="$CPPFLAGS $GST_GL_CFLAGS $GST_VIDEO_CFLAGS"
262 AC_CHECK_HEADERS([gst/gl/gl.h], [], [HAVE_GSTGL=0])
267 #include <gst/gl/gl.h>
270 GstGLContext gl_context;
273 [ac_cv_have_gst_gl_helpers="yes"],
274 [ac_cv_have_gst_gl_helpers="no"])
275 CPPFLAGS="$saved_CPPFLAGS"
280 AS_IF([test "x$ac_cv_have_gst_gl_helpers" = "xno"], [HAVE_GSTGL=0])
281 AM_CONDITIONAL([USE_GST_GL_HELPERS], [test $HAVE_GSTGL -eq 1])
282 AC_DEFINE_UNQUOTED([USE_GST_GL_HELPERS], [$HAVE_GSTGL],
283 [Defined to 1 if GStreamer OpenGL helper libraries are available])
285 if test "x$enable_egl" = "xyes" -a $HAVE_GSTGL -ne 1; then
286 AC_MSG_WARN([GStreamer/GL helper libraries not found, disabling EGL support])
290 dnl ---------------------------------------------------------------------------
292 dnl ---------------------------------------------------------------------------
294 dnl Check for DRM/libudev
296 if test "x$enable_drm" = "xyes"; then
297 PKG_CHECK_MODULES([DRM], [libdrm libudev],
300 saved_CPPFLAGS="$CPPFLAGS"
301 CPPFLAGS="$CPPFLAGS $DRM_CFLAGS"
302 AC_CHECK_HEADERS([drm_fourcc.h], [], [USE_DRM=0])
303 CPPFLAGS="$saved_CPPFLAGS"
309 if test "x$enable_x11" = "xyes"; then
310 PKG_CHECK_MODULES([X11], [x11],
313 saved_CPPFLAGS="$CPPFLAGS"
314 CPPFLAGS="$CPPFLAGS $X11_CFLAGS"
315 AC_CHECK_HEADERS([X11/Xlib.h X11/Xutil.h X11/Xatom.h], [], [USE_X11=0])
316 CPPFLAGS="$saved_CPPFLAGS"
323 if test $USE_X11 -eq 1; then
324 dnl Check for XKB library
326 saved_CPPFLAGS="$CPPFLAGS"
327 CPPFLAGS="$CPPFLAGS $X11_CFLAGS"
328 AC_CHECK_HEADERS([X11/XKBlib.h], [], [HAVE_XKBLIB=0])
329 CPPFLAGS="$saved_CPPFLAGS"
332 PKG_CHECK_MODULES([XRANDR], [xrandr],
335 saved_CPPFLAGS="$CPPFLAGS"
336 CPPFLAGS="$CPPFLAGS $XRANDR_CFLAGS"
337 AC_CHECK_HEADERS([X11/extensions/Xrandr.h], [], [HAVE_XRANDR=0])
338 CPPFLAGS="$saved_CPPFLAGS"
341 dnl Check for XRender
342 PKG_CHECK_MODULES([XRENDER], [xrender],
345 saved_CPPFLAGS="$CPPFLAGS"
346 CPPFLAGS="$CPPFLAGS $XRENDER_CFLAGS"
347 AC_CHECK_HEADERS([X11/extensions/Xrender.h], [], [HAVE_XRENDER=0])
348 CPPFLAGS="$saved_CPPFLAGS"
352 AC_DEFINE_UNQUOTED([HAVE_XKBLIB], [$HAVE_XKBLIB],
353 [Defined to 1 if the XKB extension exists.])
354 AC_DEFINE_UNQUOTED([HAVE_XRANDR], [$HAVE_XRANDR],
355 [Defined to 1 if the XRandR extension exists.])
356 AC_DEFINE_UNQUOTED([HAVE_XRENDER], [$HAVE_XRENDER],
357 [Defined to 1 if the XRender extension exists.])
365 if test "x$enable_opengl" = "xyes"; then
370 PKG_CHECK_MODULES([GL], [gl],
372 saved_CPPFLAGS="$CPPFLAGS"
373 CPPFLAGS="$CPPFLAGS $GL_CFLAGS"
374 AC_CHECK_HEADERS([GL/gl.h GL/glext.h], [], [HAVE_GL=0],
380 CPPFLAGS="$saved_CPPFLAGS"
382 GLES_VERSION_MASK=`expr $GLES_VERSION_MASK "+" $HAVE_GL "*" 1`
390 PKG_CHECK_MODULES([GLES2], [glesv2],
392 saved_CPPFLAGS="$CPPFLAGS"
393 CPPFLAGS="$CPPFLAGS $GLES2_CFLAGS"
394 AC_CHECK_HEADERS([GLES2/gl2.h GLES2/gl2ext.h], [], [HAVE_GLESv2=0],
396 #ifdef HAVE_GLES2_GL2_H
397 # include <GLES2/gl2.h>
400 CPPFLAGS="$saved_CPPFLAGS"
402 GLES_VERSION_MASK=`expr $GLES_VERSION_MASK "+" $HAVE_GLESv2 "*" 4`
410 PKG_CHECK_MODULES([GLES3], [glesv2],
412 saved_CPPFLAGS="$CPPFLAGS"
413 CPPFLAGS="$CPPFLAGS $GLES3_CFLAGS"
414 AC_CHECK_HEADERS([GLES3/gl3.h GLES3/gl3ext.h GLES2/gl2ext.h], [],
417 #ifdef HAVE_GLES3_GL3_H
418 # include <GLES3/gl3.h>
421 CPPFLAGS="$saved_CPPFLAGS"
423 GLES_VERSION_MASK=`expr $GLES_VERSION_MASK "+" $HAVE_GLESv3 "*" 8`
430 if test "x$enable_glx" = "xyes" -a $HAVE_GL -eq 1 -a $USE_X11 -eq 1; then
433 saved_CPPFLAGS="$CPPFLAGS"
435 CPPFLAGS="$CPPFLAGS $GL_CFLAGS"
436 LIBS="$LIBS $GL_LIBS"
437 AC_CHECK_HEADERS([GL/glx.h], [], [USE_GLX=0],
443 AC_CHECK_LIB([GL], [glXCreateContext], [], [USE_GLX=0])
444 CPPFLAGS="$saved_CPPFLAGS"
450 if test "x$enable_egl" = "xyes" -a $GLES_VERSION_MASK -ne 0; then
451 PKG_CHECK_MODULES([EGL], [egl],
455 saved_CPPFLAGS="$CPPFLAGS"
457 CPPFLAGS="$CPPFLAGS $EGL_CFLAGS"
458 LIBS="$LIBS $EGL_LIBS"
459 AC_CHECK_HEADERS([EGL/egl.h], [], [USE_EGL=0])
460 AC_CHECK_LIB([EGL], [eglGetDisplay], [], [USE_EGL=0])
461 CPPFLAGS="$saved_CPPFLAGS"
466 dnl Check for Wayland
468 if test "x$enable_wayland" = "xyes"; then
469 PKG_CHECK_MODULES([WAYLAND], [wayland-client >= $WAYLAND_REQ, wayland-protocols >= 1.15],
472 saved_CPPFLAGS="$CPPFLAGS"
473 CPPFLAGS="$CPPFLAGS $WAYLAND_CFLAGS"
474 AC_CHECK_HEADERS([wayland-client.h], [], [USE_WAYLAND=0])
475 CPPFLAGS="$saved_CPPFLAGS"
477 AC_CHECK_PROGS(WAYLAND_SCANNER, wayland-scanner, [USE_WAYLAND=0])
479 WAYLAND_PROTOCOLS_DATADIR="`$PKG_CONFIG --variable=pkgdatadir wayland-protocols`"
480 AC_SUBST(WAYLAND_PROTOCOLS_DATADIR, $WAYLAND_PROTOCOLS_DATADIR)
484 dnl Check for GTK for tests
486 AS_IF([test "x$BUILD_EXAMPLES" = "xyes" -a $USE_X11 -eq 1],
487 [AS_CASE([$with_gtk],
488 [yes], [PKG_CHECK_MODULES([GTK3], [gtk+-3.0], [USE_GTK=1])],
490 [PKG_CHECK_MODULES([GTK3], [gtk+-3.0], [USE_GTK=1], [USE_GTK=0])])])
491 AS_IF([test $USE_GTK -eq 1],
493 saved_CPPFLAGS="$CPPFLAGS"
494 CPPFLAGS="$CPPFLAGS $GTK3_CFLAGS"
495 AC_CHECK_HEADERS([gtk/gtk.h], [], [USE_GTK=0])
496 CPPFLAGS="$saved_CPPFLAGS"
498 dnl USE_GTK conditional is delayed after being sure to handle X11
500 dnl ---------------------------------------------------------------------------
502 dnl ---------------------------------------------------------------------------
505 PKG_CHECK_MODULES([LIBVA], [libva >= $VAAPI_REQ libva != 0.99.0])
506 VA_VERSION_STR=`$PKG_CONFIG --modversion libva`
507 VA_DRIVERS_PATH=`$PKG_CONFIG --variable=driverdir libva`
508 AC_DEFINE_UNQUOTED([VA_DRIVERS_PATH], ["$VA_DRIVERS_PATH"],
512 if test $USE_DRM -eq 1; then
513 PKG_CHECK_MODULES([LIBVA_DRM], [libva-drm >= $VAAPI_REQ],
515 saved_CPPFLAGS="$CPPFLAGS"
516 CPPFLAGS="$CPPFLAGS $LIBVA_DRM_CFLAGS"
517 AC_CHECK_HEADERS([va/va_drm.h], [], [USE_DRM=0])
518 CPPFLAGS="$saved_CPPFLAGS"
523 if test $USE_X11 -eq 1; then
524 PKG_CHECK_MODULES(LIBVA_X11, [libva-x11 >= $VAAPI_REQ],
531 dnl export USE_GTK after being sure to handle X11
532 AM_CONDITIONAL([USE_GTK], [test $USE_X11 -eq 1 -a $USE_GTK -eq 1])
534 dnl Check for encoding support
536 if test "x$enable_encoders" = "xyes"; then
541 USE_H264_FEI_ENCODER=0
543 if test $USE_ENCODERS -eq 1; then
544 saved_CPPFLAGS="$CPPFLAGS"
545 CPPFLAGS="$CPPFLAGS $LIBVA_CFLAGS"
547 dnl Check for VP9 Encoding API (0.39.1+)
548 AC_CHECK_HEADERS([va/va_enc_vp9.h], [], [],
552 AC_CACHE_CHECK([for VP9 encoding API],
553 [ac_cv_have_vp9_encoding_api],
556 LIBS="$LIBS $LIBVA_LIBS"
562 #ifdef HAVE_VA_VA_ENC_VP9_H
563 # include <va/va_enc_vp9.h>
567 VAEncSequenceParameterBufferVP9 seq_param;
568 VAEncPictureParameterBufferVP9 pic_param;
569 VAEncSegParamVP9 seg_param;
570 VAEncMiscParameterTypeVP9PerSegmantParam misc_param;
573 [ac_cv_have_vp9_encoding_api="yes"],
574 [ac_cv_have_vp9_encoding_api="no"])
577 AS_IF([test "x$ac_cv_have_vp9_encoding_api" = "xyes"], [USE_VP9_ENCODER=1])
579 dnl Check for H264 FEI Encoding API
580 AC_CHECK_HEADERS([va/va_fei_h264.h], [], [],
584 AC_CACHE_CHECK([for H264_FEI encoding API],
585 [ac_cv_have_h264_fei_encoding_api],
587 saved_CPPFLAGS="$CPPFLAGS"
588 CPPFLAGS="$CPPFLAGS $LIBVA_CFLAGS"
590 LIBS="$LIBS $LIBVA_LIBS"
596 #ifdef HAVE_VA_VA_FEI_H264_H
597 # include <va/va_fei_h264.h>
601 VAEncMiscParameterFEIFrameControlH264 framectl;
602 VAEncFEIMBControlH264 mbcntrl;
603 VAEncFEIMVPredictorH264 mvpred;
604 VAEncFEIMBCodeH264 mbcode;
605 VAEncFEIDistortionH264 dist;
608 [ac_cv_have_h264_fei_encoding_api="yes"],
609 [ac_cv_have_h264_fei_encoding_api="no"])
610 CPPFLAGS="$saved_CPPFLAGS"
613 AS_IF([test "x$ac_cv_have_h264_fei_encoding_api" = "xyes"], [USE_H264_FEI_ENCODER=1])
614 CPPFLAGS="$saved_CPPFLAGS"
618 if test $USE_WAYLAND -eq 1; then
619 PKG_CHECK_MODULES([LIBVA_WAYLAND], [libva-wayland >= $VAAPI_REQ],
623 dnl *** finalize CFLAGS, LDFLAGS, LIBS
625 # set by AG_GST_PARSE_SUBSYSTEM_DISABLES above
626 dnl make sure it doesn't complain about unused variables if debugging is disabled
627 AG_GST_CHECK_GST_DEBUG_DISABLED([NO_WARNINGS="-Wno-unused"], [NO_WARNINGS=""])
629 dnl define an ERROR_CFLAGS Makefile variable
630 dnl FIXME Add -Wredundant-decls again if considered useful and warnings are fixed
631 AG_GST_SET_ERROR_CFLAGS([$FATAL_WARNINGS], [-Wmissing-declarations -Wmissing-prototypes -Wwrite-strings -Wformat-security -Wold-style-definition -Winit-self -Wmissing-include-dirs -Waddress -Wno-multichar -Wnested-externs $NO_WARNINGS])
633 dnl define correct level for debugging messages
634 AG_GST_SET_LEVEL_DEFAULT([$GST_GIT])
637 dnl GST_OPTION_CFLAGS: common flags for profiling, debugging, errors, ...
638 dnl GST_*: flags shared by built objects to link against GStreamer
639 dnl GST_ALL_LDFLAGS: linker flags shared by all
640 dnl GST_LIB_LDFLAGS: additional linker flags for all libaries
641 dnl GST_LT_LDFLAGS: library versioning of our libraries
642 dnl GST_PLUGIN_LDFLAGS: flags to be used for all plugins
644 dnl GST_OPTION_CFLAGS
645 if test "x$USE_DEBUG" = xyes; then
648 AC_SUBST([PROFILE_CFLAGS])
650 if test "x$GST_GIT" = "xyes"; then
651 DEPRECATED_CFLAGS="-DGST_DISABLE_DEPRECATED"
655 AC_SUBST([DEPRECATED_CFLAGS])
657 dnl disable strict aliasing
658 AS_COMPILER_FLAG([-fno-strict-aliasing], [EXTRA_CFLAGS="-fno-strict-aliasing"])
659 AC_SUBST(EXTRA_CFLAGS)
661 dnl every flag in GST_OPTION_CFLAGS and GST_OPTION_CXXFLAGS can be overridden
662 dnl at make time with e.g. make ERROR_CFLAGS=""
663 GST_OPTION_CFLAGS="\$(WARNING_CFLAGS) \$(ERROR_CFLAGS) \$(DEBUG_CFLAGS) \$(PROFILE_CFLAGS) \$(DEPRECATED_CFLAGS)"
664 AC_SUBST([GST_OPTION_CFLAGS])
666 dnl FIXME: do we want to rename to GST_ALL_* ?
667 dnl prefer internal headers to already installed ones
668 dnl also add builddir include for enumtypes and marshal
669 dnl add GST_OPTION_CFLAGS, but overridable
670 GST_CFLAGS="$GST_CFLAGS -DGST_USE_UNSTABLE_API"
671 GST_CFLAGS="$GST_CFLAGS $EXTRA_CFLAGS $GLIB_EXTRA_CFLAGS \$(GST_OPTION_CFLAGS)"
672 AC_SUBST([GST_CFLAGS])
674 dnl LDFLAGS really should only contain flags, not libs - they get added before
675 dnl whatevertarget_LIBS and -L flags here affect the rest of the linking
676 GST_ALL_LDFLAGS="-no-undefined"
677 if test "x${enable_Bsymbolic}" = "xyes"; then
678 GST_ALL_LDFLAGS="$GST_ALL_LDFLAGS -Wl,-Bsymbolic-functions"
680 AC_SUBST([GST_ALL_LDFLAGS])
683 dnl linker flags shared by all libraries
684 dnl LDFLAGS modifier defining exported symbols from built libraries
685 dnl (export _gst_foo but not __gst_foo)
686 GST_LIB_LDFLAGS="-export-symbols-regex ^_?\(gst_\|Gst\|GST_\).*"
687 AC_SUBST([GST_LIB_LDFLAGS])
689 dnl this really should only contain flags, not libs - they get added before
690 dnl whatevertarget_LIBS and -L flags here affect the rest of the linking
691 GST_PLUGIN_LDFLAGS="-module -avoid-version -export-symbols-regex '^[_]*gst_plugin_.*' $GST_ALL_LDFLAGS"
692 AC_SUBST([GST_PLUGIN_LDFLAGS])
694 dnl ---------------------------------------------------------------------------
695 dnl -- Generate files and summary --
696 dnl ---------------------------------------------------------------------------
698 case ":$USE_X11:$USE_GLX:$USE_EGL:$USE_WAYLAND:$USE_DRM:" in
700 *) AC_MSG_ERROR([No renderer is enabled]) ;;
703 AC_DEFINE_UNQUOTED([USE_ENCODERS], [$USE_ENCODERS],
704 [Defined to 1 if video encoders are used])
705 AM_CONDITIONAL([USE_ENCODERS], [test $USE_ENCODERS -eq 1])
707 AC_DEFINE_UNQUOTED([USE_VP9_ENCODER], [$USE_VP9_ENCODER],
708 [Defined to 1 if VP9 encoder is used])
709 AM_CONDITIONAL([USE_VP9_ENCODER], [test $USE_VP9_ENCODER -eq 1])
711 AC_DEFINE_UNQUOTED([USE_H264_FEI_ENCODER], [$USE_H264_FEI_ENCODER],
712 [Defined to 1 if H264_FEI encoder is used])
713 AM_CONDITIONAL([USE_H264_FEI_ENCODER], [test $USE_H264_FEI_ENCODER -eq 1])
715 AC_DEFINE_UNQUOTED([USE_DRM], [$USE_DRM],
716 [Defined to 1 if DRM is enabled])
717 AM_CONDITIONAL([USE_DRM], [test $USE_DRM -eq 1])
719 AC_DEFINE_UNQUOTED([USE_X11], [$USE_X11],
720 [Defined to 1 if X11 is enabled])
721 AM_CONDITIONAL([USE_X11], [test $USE_X11 -eq 1])
723 AC_DEFINE_UNQUOTED([USE_GLX], [$USE_GLX],
724 [Defined to 1 if GLX is enabled])
725 AM_CONDITIONAL([USE_GLX], [test $USE_GLX -eq 1])
727 AC_DEFINE_UNQUOTED([USE_EGL], [$USE_EGL],
728 [Defined to 1 if EGL is enabled])
729 AM_CONDITIONAL([USE_EGL], [test $USE_EGL -eq 1])
731 AC_DEFINE_UNQUOTED([USE_GLES_VERSION_MASK], [$GLES_VERSION_MASK],
732 [Defined to the set of enabled OpenGL ES APIs])
734 AC_DEFINE_UNQUOTED([USE_WAYLAND], [$USE_WAYLAND],
735 [Defined to 1 if WAYLAND is enabled])
736 AM_CONDITIONAL([USE_WAYLAND], [test $USE_WAYLAND -eq 1])
738 dnl @TODO hack for egl's dynamic module loading. remove it!
739 AC_DEFINE_UNQUOTED([GST_VAAPI_MAJOR_VERSION_S], ["0"],
740 [Defined to the string representation of gstreamer-vaapi major version])
748 docs/version.entities
749 docs/plugins/Makefile
750 docs/plugins/gstreamer-vaapi-plugins-docs.xml
752 gst-libs/gst/Makefile
753 gst-libs/gst/vaapi/Makefile
757 tests/elements/Makefile
763 test $1 -eq 1 && echo yes || echo no
767 AS_IF([test $USE_DRM -eq 1], [VIDEO_OUTPUTS="$VIDEO_OUTPUTS drm"])
768 AS_IF([test $USE_X11 -eq 1], [VIDEO_OUTPUTS="$VIDEO_OUTPUTS x11"])
769 AS_IF([test $USE_GLX -eq 1], [VIDEO_OUTPUTS="$VIDEO_OUTPUTS glx"])
770 AS_IF([test $USE_EGL -eq 1], [VIDEO_OUTPUTS="$VIDEO_OUTPUTS egl"])
771 AS_IF([test $USE_WAYLAND -eq 1], [VIDEO_OUTPUTS="$VIDEO_OUTPUTS wayland"])
774 echo $PACKAGE configuration summary:
776 echo Installation Prefix .............. : ${prefix}
777 echo GStreamer API version ............ : $GST_VERSION
778 echo VA-API version ................... : $VA_VERSION_STR
779 echo Video encoding ................... : $(yesno $USE_ENCODERS)
780 echo Video outputs .................... : $VIDEO_OUTPUTS