summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/libva/aclocal.m490
-rw-r--r--lib/libva/configure88
2 files changed, 123 insertions, 55 deletions
diff --git a/lib/libva/aclocal.m4 b/lib/libva/aclocal.m4
index c24510d1e..c0d703866 100644
--- a/lib/libva/aclocal.m4
+++ b/lib/libva/aclocal.m4
@@ -19,7 +19,7 @@ You have another version of autoconf. It may work, but is not guaranteed to.
If you have problems, you may need to regenerate the build system entirely.
To do so, use the procedure documented by the package, typically 'autoreconf'.])])
-# pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*-
+# pkg.m4 - Macros to locate and use pkg-config. -*- Autoconf -*-
# serial 12 (pkg-config-0.29.2)
dnl Copyright © 2004 Scott James Remnant <scott@netsplit.com>.
@@ -107,7 +107,7 @@ dnl Check to see whether a particular set of modules exists. Similar to
dnl PKG_CHECK_MODULES(), but does not set variables or print errors.
dnl
dnl Please remember that m4 expands AC_REQUIRE([PKG_PROG_PKG_CONFIG])
-dnl only at the first occurence in configure.ac, so if the first place
+dnl only at the first occurrence in configure.ac, so if the first place
dnl it's called might be skipped (such as if it is within an "if", you
dnl have to call PKG_CHECK_EXISTS manually
AC_DEFUN([PKG_CHECK_EXISTS],
@@ -176,14 +176,14 @@ if test $pkg_failed = yes; then
AC_MSG_RESULT([no])
_PKG_SHORT_ERRORS_SUPPORTED
if test $_pkg_short_errors_supported = yes; then
- $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
+ $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "$2" 2>&1`
else
- $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
+ $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "$2" 2>&1`
fi
- # Put the nasty error message in config.log where it belongs
- echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
+ # Put the nasty error message in config.log where it belongs
+ echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD
- m4_default([$4], [AC_MSG_ERROR(
+ m4_default([$4], [AC_MSG_ERROR(
[Package requirements ($2) were not met:
$$1_PKG_ERRORS
@@ -195,7 +195,7 @@ _PKG_TEXT])[]dnl
])
elif test $pkg_failed = untried; then
AC_MSG_RESULT([no])
- m4_default([$4], [AC_MSG_FAILURE(
+ m4_default([$4], [AC_MSG_FAILURE(
[The pkg-config script could not be found or is too old. Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
path to pkg-config.
@@ -205,10 +205,10 @@ _PKG_TEXT
To get pkg-config, see <http://pkg-config.freedesktop.org/>.])[]dnl
])
else
- $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
- $1[]_LIBS=$pkg_cv_[]$1[]_LIBS
+ $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS
+ $1[]_LIBS=$pkg_cv_[]$1[]_LIBS
AC_MSG_RESULT([yes])
- $3
+ $3
fi[]dnl
])dnl PKG_CHECK_MODULES
@@ -295,6 +295,74 @@ AS_VAR_COPY([$1], [pkg_cv_][$1])
AS_VAR_IF([$1], [""], [$5], [$4])dnl
])dnl PKG_CHECK_VAR
+dnl PKG_WITH_MODULES(VARIABLE-PREFIX, MODULES,
+dnl [ACTION-IF-FOUND],[ACTION-IF-NOT-FOUND],
+dnl [DESCRIPTION], [DEFAULT])
+dnl ------------------------------------------
+dnl
+dnl Prepare a "--with-" configure option using the lowercase
+dnl [VARIABLE-PREFIX] name, merging the behaviour of AC_ARG_WITH and
+dnl PKG_CHECK_MODULES in a single macro.
+AC_DEFUN([PKG_WITH_MODULES],
+[
+m4_pushdef([with_arg], m4_tolower([$1]))
+
+m4_pushdef([description],
+ [m4_default([$5], [build with ]with_arg[ support])])
+
+m4_pushdef([def_arg], [m4_default([$6], [auto])])
+m4_pushdef([def_action_if_found], [AS_TR_SH([with_]with_arg)=yes])
+m4_pushdef([def_action_if_not_found], [AS_TR_SH([with_]with_arg)=no])
+
+m4_case(def_arg,
+ [yes],[m4_pushdef([with_without], [--without-]with_arg)],
+ [m4_pushdef([with_without],[--with-]with_arg)])
+
+AC_ARG_WITH(with_arg,
+ AS_HELP_STRING(with_without, description[ @<:@default=]def_arg[@:>@]),,
+ [AS_TR_SH([with_]with_arg)=def_arg])
+
+AS_CASE([$AS_TR_SH([with_]with_arg)],
+ [yes],[PKG_CHECK_MODULES([$1],[$2],$3,$4)],
+ [auto],[PKG_CHECK_MODULES([$1],[$2],
+ [m4_n([def_action_if_found]) $3],
+ [m4_n([def_action_if_not_found]) $4])])
+
+m4_popdef([with_arg])
+m4_popdef([description])
+m4_popdef([def_arg])
+
+])dnl PKG_WITH_MODULES
+
+dnl PKG_HAVE_WITH_MODULES(VARIABLE-PREFIX, MODULES,
+dnl [DESCRIPTION], [DEFAULT])
+dnl -----------------------------------------------
+dnl
+dnl Convenience macro to trigger AM_CONDITIONAL after PKG_WITH_MODULES
+dnl check._[VARIABLE-PREFIX] is exported as make variable.
+AC_DEFUN([PKG_HAVE_WITH_MODULES],
+[
+PKG_WITH_MODULES([$1],[$2],,,[$3],[$4])
+
+AM_CONDITIONAL([HAVE_][$1],
+ [test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"])
+])dnl PKG_HAVE_WITH_MODULES
+
+dnl PKG_HAVE_DEFINE_WITH_MODULES(VARIABLE-PREFIX, MODULES,
+dnl [DESCRIPTION], [DEFAULT])
+dnl ------------------------------------------------------
+dnl
+dnl Convenience macro to run AM_CONDITIONAL and AC_DEFINE after
+dnl PKG_WITH_MODULES check. HAVE_[VARIABLE-PREFIX] is exported as make
+dnl and preprocessor variable.
+AC_DEFUN([PKG_HAVE_DEFINE_WITH_MODULES],
+[
+PKG_HAVE_WITH_MODULES([$1],[$2],[$3],[$4])
+
+AS_IF([test "$AS_TR_SH([with_]m4_tolower([$1]))" = "yes"],
+ [AC_DEFINE([HAVE_][$1], 1, [Enable ]m4_tolower([$1])[ support])])
+])dnl PKG_HAVE_DEFINE_WITH_MODULES
+
# Copyright (C) 2002-2012 Free Software Foundation, Inc.
#
# This file is free software; the Free Software Foundation
diff --git a/lib/libva/configure b/lib/libva/configure
index eb2f49bff..e8bc6ab2c 100644
--- a/lib/libva/configure
+++ b/lib/libva/configure
@@ -17865,14 +17865,14 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- DRM_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libdrm >= $LIBDRM_VERSION" 2>&1`
+ DRM_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libdrm >= $LIBDRM_VERSION" 2>&1`
else
- DRM_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libdrm >= $LIBDRM_VERSION" 2>&1`
+ DRM_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libdrm >= $LIBDRM_VERSION" 2>&1`
fi
- # Put the nasty error message in config.log where it belongs
- echo "$DRM_PKG_ERRORS" >&5
+ # Put the nasty error message in config.log where it belongs
+ echo "$DRM_PKG_ERRORS" >&5
- as_fn_error $? "Package requirements (libdrm >= $LIBDRM_VERSION) were not met:
+ as_fn_error $? "Package requirements (libdrm >= $LIBDRM_VERSION) were not met:
$DRM_PKG_ERRORS
@@ -17885,7 +17885,7 @@ See the pkg-config man page for more details." "$LINENO" 5
elif test $pkg_failed = untried; then
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
- { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+ { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;}
as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it
is in your PATH or set the PKG_CONFIG environment variable to the full
@@ -17898,8 +17898,8 @@ See the pkg-config man page for more details.
To get pkg-config, see <http://pkg-config.freedesktop.org/>.
See \`config.log' for more details" "$LINENO" 5; }
else
- DRM_CFLAGS=$pkg_cv_DRM_CFLAGS
- DRM_LIBS=$pkg_cv_DRM_LIBS
+ DRM_CFLAGS=$pkg_cv_DRM_CFLAGS
+ DRM_LIBS=$pkg_cv_DRM_LIBS
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
@@ -17977,24 +17977,24 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- X11_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "x11 xext xfixes x11-xcb xcb xcb-dri3" 2>&1`
+ X11_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "x11 xext xfixes x11-xcb xcb xcb-dri3" 2>&1`
else
- X11_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "x11 xext xfixes x11-xcb xcb xcb-dri3" 2>&1`
+ X11_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "x11 xext xfixes x11-xcb xcb xcb-dri3" 2>&1`
fi
- # Put the nasty error message in config.log where it belongs
- echo "$X11_PKG_ERRORS" >&5
+ # Put the nasty error message in config.log where it belongs
+ echo "$X11_PKG_ERRORS" >&5
- :
+ :
elif test $pkg_failed = untried; then
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
- :
+ :
else
- X11_CFLAGS=$pkg_cv_X11_CFLAGS
- X11_LIBS=$pkg_cv_X11_LIBS
+ X11_CFLAGS=$pkg_cv_X11_CFLAGS
+ X11_LIBS=$pkg_cv_X11_LIBS
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
- USE_X11="yes"
+ USE_X11="yes"
fi
if test "x$USE_X11" = "xno" -a "x$enable_x11" = "xyes"; then
@@ -18076,24 +18076,24 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- GLX_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gl x11" 2>&1`
+ GLX_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gl x11" 2>&1`
else
- GLX_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gl x11" 2>&1`
+ GLX_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gl x11" 2>&1`
fi
- # Put the nasty error message in config.log where it belongs
- echo "$GLX_PKG_ERRORS" >&5
+ # Put the nasty error message in config.log where it belongs
+ echo "$GLX_PKG_ERRORS" >&5
- :
+ :
elif test $pkg_failed = untried; then
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
- :
+ :
else
- GLX_CFLAGS=$pkg_cv_GLX_CFLAGS
- GLX_LIBS=$pkg_cv_GLX_LIBS
+ GLX_CFLAGS=$pkg_cv_GLX_CFLAGS
+ GLX_LIBS=$pkg_cv_GLX_LIBS
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
- USE_GLX="yes"
+ USE_GLX="yes"
fi
saved_CPPFLAGS="$CPPFLAGS"
saved_LIBS="$LIBS"
@@ -18234,24 +18234,24 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- WAYLAND_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "wayland-client >= 1.11.0" 2>&1`
+ WAYLAND_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "wayland-client >= 1.11.0" 2>&1`
else
- WAYLAND_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "wayland-client >= 1.11.0" 2>&1`
+ WAYLAND_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "wayland-client >= 1.11.0" 2>&1`
fi
- # Put the nasty error message in config.log where it belongs
- echo "$WAYLAND_PKG_ERRORS" >&5
+ # Put the nasty error message in config.log where it belongs
+ echo "$WAYLAND_PKG_ERRORS" >&5
- :
+ :
elif test $pkg_failed = untried; then
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
- :
+ :
else
- WAYLAND_CFLAGS=$pkg_cv_WAYLAND_CFLAGS
- WAYLAND_LIBS=$pkg_cv_WAYLAND_LIBS
+ WAYLAND_CFLAGS=$pkg_cv_WAYLAND_CFLAGS
+ WAYLAND_LIBS=$pkg_cv_WAYLAND_LIBS
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
- USE_WAYLAND="yes"
+ USE_WAYLAND="yes"
fi
if test "x$USE_WAYLAND" = "xno" -a "x$enable_wayland" = "xyes"; then
@@ -18358,24 +18358,24 @@ else
_pkg_short_errors_supported=no
fi
if test $_pkg_short_errors_supported = yes; then
- WL_SCANNER_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "wayland-scanner >= 1.15" 2>&1`
+ WL_SCANNER_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "wayland-scanner >= 1.15" 2>&1`
else
- WL_SCANNER_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "wayland-scanner >= 1.15" 2>&1`
+ WL_SCANNER_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "wayland-scanner >= 1.15" 2>&1`
fi
- # Put the nasty error message in config.log where it belongs
- echo "$WL_SCANNER_PKG_ERRORS" >&5
+ # Put the nasty error message in config.log where it belongs
+ echo "$WL_SCANNER_PKG_ERRORS" >&5
- :
+ :
elif test $pkg_failed = untried; then
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
printf "%s\n" "no" >&6; }
- :
+ :
else
- WL_SCANNER_CFLAGS=$pkg_cv_WL_SCANNER_CFLAGS
- WL_SCANNER_LIBS=$pkg_cv_WL_SCANNER_LIBS
+ WL_SCANNER_CFLAGS=$pkg_cv_WL_SCANNER_CFLAGS
+ WL_SCANNER_LIBS=$pkg_cv_WL_SCANNER_LIBS
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
printf "%s\n" "yes" >&6; }
- USE_WAYLAND="yes"
+ USE_WAYLAND="yes"
fi
if test "x$USE_WAYLAND" = "xno" -a "x$enable_wayland" = "xyes"; then