configure: Add configure checks for Xfixes library.
Signed-off-by: Piotr Caban <piotr@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
4270c08cd7
commit
4208bc8cdd
90
configure
vendored
90
configure
vendored
@ -853,6 +853,7 @@ with_udev
|
||||
with_v4l
|
||||
with_xcomposite
|
||||
with_xcursor
|
||||
with_xfixes
|
||||
with_xinerama
|
||||
with_xinput
|
||||
with_xinput2
|
||||
@ -2363,6 +2364,7 @@ Optional Packages:
|
||||
--without-v4l do not use v4l1 (v4l support)
|
||||
--without-xcomposite do not use the Xcomposite extension
|
||||
--without-xcursor do not use the Xcursor extension
|
||||
--without-xfixes do not use Xfixes for clipboard change notifications
|
||||
--without-xinerama do not use Xinerama (multi-monitor support)
|
||||
--without-xinput do not use the Xinput extension
|
||||
--without-xinput2 do not use the Xinput 2 extension
|
||||
@ -3657,6 +3659,12 @@ if test "${with_xcursor+set}" = set; then :
|
||||
fi
|
||||
|
||||
|
||||
# Check whether --with-xfixes was given.
|
||||
if test "${with_xfixes+set}" = set; then :
|
||||
withval=$with_xfixes; if test "x$withval" = "xno"; then ac_cv_header_X11_extensions_Xfixes_h=no; fi
|
||||
fi
|
||||
|
||||
|
||||
# Check whether --with-xinerama was given.
|
||||
if test "${with_xinerama+set}" = set; then :
|
||||
withval=$with_xinerama; if test "x$withval" = "xno"; then ac_cv_header_X11_extensions_Xinerama_h=no; fi
|
||||
@ -9834,6 +9842,7 @@ fi
|
||||
X11/extensions/XInput2.h \
|
||||
X11/extensions/XShm.h \
|
||||
X11/extensions/Xcomposite.h \
|
||||
X11/extensions/Xfixes.h \
|
||||
X11/extensions/Xinerama.h \
|
||||
X11/extensions/Xrandr.h \
|
||||
X11/extensions/Xrender.h \
|
||||
@ -10471,6 +10480,87 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
This is an error since --with-xrandr was requested." "$LINENO" 5 ;;
|
||||
esac
|
||||
|
||||
fi
|
||||
|
||||
if test "$ac_cv_header_X11_extensions_Xfixes_h" = "yes"
|
||||
then
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/extensions/Xfixes.h>
|
||||
int
|
||||
main ()
|
||||
{
|
||||
static typeof(XFixesQueryVersion) * func; if (func) return 0;
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_compile "$LINENO"; then :
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -lXfixes" >&5
|
||||
$as_echo_n "checking for -lXfixes... " >&6; }
|
||||
if ${ac_cv_lib_soname_Xfixes+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
ac_check_soname_save_LIBS=$LIBS
|
||||
LIBS="-lXfixes $X_LIBS $X_EXTRA_LIBS $LIBS"
|
||||
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
|
||||
/* end confdefs.h. */
|
||||
|
||||
/* Override any GCC internal prototype to avoid an error.
|
||||
Use char because int might match the return type of a GCC
|
||||
builtin and then its argument prototype would still apply. */
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
#endif
|
||||
char XFixesQueryVersion ();
|
||||
int
|
||||
main ()
|
||||
{
|
||||
return XFixesQueryVersion ();
|
||||
;
|
||||
return 0;
|
||||
}
|
||||
_ACEOF
|
||||
if ac_fn_c_try_link "$LINENO"; then :
|
||||
case "$LIBEXT" in
|
||||
dll) ac_cv_lib_soname_Xfixes=`$ac_cv_path_LDD conftest.exe | grep "Xfixes" | sed -e "s/dll.*/dll/"';2,$d'` ;;
|
||||
dylib) ac_cv_lib_soname_Xfixes=`$OTOOL -L conftest$ac_exeext | grep "libXfixes\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libXfixes\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
|
||||
*) ac_cv_lib_soname_Xfixes=`$READELF -d conftest$ac_exeext | grep "NEEDED.*libXfixes\\.$LIBEXT" | sed -e "s/^.*\\[\\(libXfixes\\.$LIBEXT[^ ]*\\)\\].*$/\1/"';2,$d'`
|
||||
if ${ac_cv_lib_soname_Xfixes:+false} :; then :
|
||||
ac_cv_lib_soname_Xfixes=`$LDD conftest$ac_exeext | grep "libXfixes\\.$LIBEXT" | sed -e "s/^.*\(libXfixes\.$LIBEXT[^ ]*\).*$/\1/"';2,$d'`
|
||||
fi ;;
|
||||
esac
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext \
|
||||
conftest$ac_exeext conftest.$ac_ext
|
||||
LIBS=$ac_check_soname_save_LIBS
|
||||
fi
|
||||
if ${ac_cv_lib_soname_Xfixes:+false} :; then :
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
|
||||
$as_echo "not found" >&6; }
|
||||
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_soname_Xfixes" >&5
|
||||
$as_echo "$ac_cv_lib_soname_Xfixes" >&6; }
|
||||
|
||||
cat >>confdefs.h <<_ACEOF
|
||||
#define SONAME_LIBXFIXES "$ac_cv_lib_soname_Xfixes"
|
||||
_ACEOF
|
||||
|
||||
|
||||
fi
|
||||
fi
|
||||
rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
|
||||
fi
|
||||
if test "x$ac_cv_lib_soname_Xfixes" = "x"; then :
|
||||
case "x$with_xfixes" in
|
||||
x) as_fn_append wine_notices "|libxfixes ${notice_platform}development files not found, Xfixes won't be supported." ;;
|
||||
xno) ;;
|
||||
*) as_fn_error $? "libxfixes ${notice_platform}development files not found, Xfixes won't be supported.
|
||||
This is an error since --with-xfixes was requested." "$LINENO" 5 ;;
|
||||
esac
|
||||
|
||||
fi
|
||||
|
||||
if test "$ac_cv_header_X11_extensions_Xinerama_h" = "yes"
|
||||
|
13
configure.ac
13
configure.ac
@ -81,6 +81,8 @@ AC_ARG_WITH(xcomposite,AS_HELP_STRING([--without-xcomposite],[do not use the Xco
|
||||
[if test "x$withval" = "xno"; then ac_cv_header_X11_extensions_Xcomposite_h=no; fi])
|
||||
AC_ARG_WITH(xcursor, AS_HELP_STRING([--without-xcursor],[do not use the Xcursor extension]),
|
||||
[if test "x$withval" = "xno"; then ac_cv_header_X11_Xcursor_Xcursor_h=no; fi])
|
||||
AC_ARG_WITH(xfixes, AS_HELP_STRING([--without-xfixes],[do not use Xfixes for clipboard change notifications]),
|
||||
[if test "x$withval" = "xno"; then ac_cv_header_X11_extensions_Xfixes_h=no; fi])
|
||||
AC_ARG_WITH(xinerama, AS_HELP_STRING([--without-xinerama],[do not use Xinerama (multi-monitor support)]),
|
||||
[if test "x$withval" = "xno"; then ac_cv_header_X11_extensions_Xinerama_h=no; fi])
|
||||
AC_ARG_WITH(xinput, AS_HELP_STRING([--without-xinput],[do not use the Xinput extension]),
|
||||
@ -999,6 +1001,7 @@ then
|
||||
X11/extensions/XInput2.h \
|
||||
X11/extensions/XShm.h \
|
||||
X11/extensions/Xcomposite.h \
|
||||
X11/extensions/Xfixes.h \
|
||||
X11/extensions/Xinerama.h \
|
||||
X11/extensions/Xrandr.h \
|
||||
X11/extensions/Xrender.h \
|
||||
@ -1096,6 +1099,16 @@ then
|
||||
WINE_NOTICE_WITH(xrandr,[test "x$ac_cv_lib_soname_Xrandr" = "x"],
|
||||
[libxrandr ${notice_platform}development files not found, XRandr won't be supported.])
|
||||
|
||||
dnl *** Check for Xfixes extension
|
||||
if test "$ac_cv_header_X11_extensions_Xfixes_h" = "yes"
|
||||
then
|
||||
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <X11/Xlib.h>
|
||||
#include <X11/extensions/Xfixes.h>]], [[static typeof(XFixesQueryVersion) * func; if (func) return 0;]])],
|
||||
[WINE_CHECK_SONAME(Xfixes,XFixesQueryVersion,,,[$X_LIBS $X_EXTRA_LIBS])])
|
||||
fi
|
||||
WINE_NOTICE_WITH(xfixes,[test "x$ac_cv_lib_soname_Xfixes" = "x"],
|
||||
[libxfixes ${notice_platform}development files not found, Xfixes won't be supported.])
|
||||
|
||||
dnl *** Check for Xinerama extension
|
||||
if test "$ac_cv_header_X11_extensions_Xinerama_h" = "yes"
|
||||
then
|
||||
|
@ -1251,6 +1251,9 @@
|
||||
/* Define to 1 if you have the <X11/extensions/xf86vmproto.h> header file. */
|
||||
#undef HAVE_X11_EXTENSIONS_XF86VMPROTO_H
|
||||
|
||||
/* Define to 1 if you have the <X11/extensions/Xfixes.h> header file. */
|
||||
#undef HAVE_X11_EXTENSIONS_XFIXES_H
|
||||
|
||||
/* Define to 1 if you have the <X11/extensions/Xinerama.h> header file. */
|
||||
#undef HAVE_X11_EXTENSIONS_XINERAMA_H
|
||||
|
||||
@ -1472,6 +1475,9 @@
|
||||
/* Define to the soname of the libXext library. */
|
||||
#undef SONAME_LIBXEXT
|
||||
|
||||
/* Define to the soname of the libXfixes library. */
|
||||
#undef SONAME_LIBXFIXES
|
||||
|
||||
/* Define to the soname of the libXi library. */
|
||||
#undef SONAME_LIBXI
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user