configure: Make the libssl soname check depend on the header check.
[wine] / configure
index a68d2d1..97208d2 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
 #! /bin/sh
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.61 for Wine 0.9.28.
+# Generated by GNU Autoconf 2.61 for Wine 0.9.40.
 #
 # Report bugs to <wine-devel@winehq.org>.
 #
@@ -574,8 +574,8 @@ SHELL=${CONFIG_SHELL-/bin/sh}
 # Identity of this package.
 PACKAGE_NAME='Wine'
 PACKAGE_TARNAME='wine'
-PACKAGE_VERSION='0.9.28'
-PACKAGE_STRING='Wine 0.9.28'
+PACKAGE_VERSION='0.9.40'
+PACKAGE_STRING='Wine 0.9.40'
 PACKAGE_BUGREPORT='wine-devel@winehq.org'
 
 ac_unique_file="server/atom.c"
@@ -681,10 +681,7 @@ X_CFLAGS
 X_PRE_LIBS
 X_LIBS
 X_EXTRA_LIBS
-LEX
-LEX_OUTPUT_ROOT
-LEXLIB
-XLEX
+FLEX
 BISON
 AS
 ac_ct_AS
@@ -713,6 +710,27 @@ OPENGLFILES
 GLU32FILES
 OPENGL_LIBS
 QUARTZFILES
+DLLEXT
+DLLFLAGS
+LDSHARED
+LDDLLFLAGS
+LIBEXT
+IMPLIBEXT
+LDRPATH_INSTALL
+LDRPATH_LOCAL
+LDD
+DLLTOOL
+DLLWRAP
+MINGWAR
+COREFOUNDATIONLIB
+IOKITLIB
+LDEXECFLAGS
+DISKARBITRATIONLIB
+COREAUDIO
+CARBONLIB
+CROSSTEST
+CROSSCC
+CROSSWINDRES
 NASLIBS
 XML2LIBS
 XML2INCL
@@ -720,7 +738,6 @@ XSLTLIBS
 XSLTINCL
 HALINCL
 sane_devel
-SANELIBS
 SANEINCL
 gphoto2_devel
 gphoto2port_devel
@@ -735,9 +752,6 @@ FREETYPEINCL
 ft_devel
 ft_devel2
 FONTSSUBDIRS
-ARTSCCONFIG
-ARTSLIBS
-ARTSINCL
 ESDCONFIG
 ESDLIBS
 ESDINCL
@@ -745,30 +759,11 @@ ALSALIBS
 AUDIOIOLIBS
 EXTRACFLAGS
 BUILTINFLAG
-DLLEXT
-DLLFLAGS
-LDSHARED
-LDDLLFLAGS
-LIBEXT
-IMPLIBEXT
-LIBWINE_LDFLAGS
-DLLTOOL
-DLLWRAP
-COREFOUNDATIONLIB
-IOKITLIB
-LDEXECFLAGS
-DISKARBITRATIONLIB
-COREAUDIO
-CARBONLIB
-CROSSTEST
-CROSSCC
-CROSSWINDRES
 LDPATH
 CRTLIBS
 SOCKETLIBS
 MAIN_BINARY
 EXTRA_BINARIES
-LDD
 LIBDL
 LIBPOLL
 DEPENDENCIES
@@ -1294,7 +1289,7 @@ if test "$ac_init_help" = "long"; then
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures Wine 0.9.28 to adapt to many kinds of systems.
+\`configure' configures Wine 0.9.40 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1363,7 +1358,7 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of Wine 0.9.28:";;
+     short | recursive ) echo "Configuration of Wine 0.9.40:";;
    esac
   cat <<\_ACEOF
 
@@ -1458,7 +1453,7 @@ fi
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-Wine configure 0.9.28
+Wine configure 0.9.40
 generated by GNU Autoconf 2.61
 
 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
@@ -1472,7 +1467,7 @@ cat >config.log <<_ACEOF
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by Wine $as_me 0.9.28, which was
+It was created by Wine $as_me 0.9.40, which was
 generated by GNU Autoconf 2.61.  Invocation command line was
 
   $ $0 $@
 
 fi
 
-for ac_prog in flex lex
-do
-  # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_LEX+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$LEX"; then
-  ac_cv_prog_LEX="$LEX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_LEX="$ac_prog"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-LEX=$ac_cv_prog_LEX
-if test -n "$LEX"; then
-  { echo "$as_me:$LINENO: result: $LEX" >&5
-echo "${ECHO_T}$LEX" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-  test -n "$LEX" && break
-done
-test -n "$LEX" || LEX=":"
-
-if test "x$LEX" != "x:"; then
-  cat >conftest.l <<_ACEOF
-%%
-a { ECHO; }
-b { REJECT; }
-c { yymore (); }
-d { yyless (1); }
-e { yyless (input () != 0); }
-f { unput (yytext[0]); }
-. { BEGIN INITIAL; }
-%%
-#ifdef YYTEXT_POINTER
-extern char *yytext;
-#endif
-int
-main (void)
-{
-  return ! yylex () + ! yywrap ();
-}
-_ACEOF
-{ (ac_try="$LEX conftest.l"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$LEX conftest.l") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }
-{ echo "$as_me:$LINENO: checking lex output file root" >&5
-echo $ECHO_N "checking lex output file root... $ECHO_C" >&6; }
-if test "${ac_cv_prog_lex_root+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-if test -f lex.yy.c; then
-  ac_cv_prog_lex_root=lex.yy
-elif test -f lexyy.c; then
-  ac_cv_prog_lex_root=lexyy
-else
-  { { echo "$as_me:$LINENO: error: cannot find output from $LEX; giving up" >&5
-echo "$as_me: error: cannot find output from $LEX; giving up" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_prog_lex_root" >&5
-echo "${ECHO_T}$ac_cv_prog_lex_root" >&6; }
-LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
-
-if test -z "${LEXLIB+set}"; then
-  { echo "$as_me:$LINENO: checking lex library" >&5
-echo $ECHO_N "checking lex library... $ECHO_C" >&6; }
-if test "${ac_cv_lib_lex+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-
-    ac_save_LIBS=$LIBS
-    ac_cv_lib_lex='none needed'
-    for ac_lib in '' -lfl -ll; do
-      LIBS="$ac_lib $ac_save_LIBS"
-      cat >conftest.$ac_ext <<_ACEOF
-`cat $LEX_OUTPUT_ROOT.c`
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_lex=$ac_lib
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-      test "$ac_cv_lib_lex" != 'none needed' && break
-    done
-    LIBS=$ac_save_LIBS
-
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_lex" >&5
-echo "${ECHO_T}$ac_cv_lib_lex" >&6; }
-  test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex
-fi
-
-
-{ echo "$as_me:$LINENO: checking whether yytext is a pointer" >&5
-echo $ECHO_N "checking whether yytext is a pointer... $ECHO_C" >&6; }
-if test "${ac_cv_prog_lex_yytext_pointer+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  # POSIX says lex can declare yytext either as a pointer or an array; the
-# default is implementation-dependent.  Figure out which it is, since
-# not all implementations provide the %pointer and %array declarations.
-ac_cv_prog_lex_yytext_pointer=no
-ac_save_LIBS=$LIBS
-LIBS="$LEXLIB $ac_save_LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-#define YYTEXT_POINTER 1
-`cat $LEX_OUTPUT_ROOT.c`
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_prog_lex_yytext_pointer=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_save_LIBS
-
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_prog_lex_yytext_pointer" >&5
-echo "${ECHO_T}$ac_cv_prog_lex_yytext_pointer" >&6; }
-if test $ac_cv_prog_lex_yytext_pointer = yes; then
-
-cat >>confdefs.h <<\_ACEOF
-#define YYTEXT_POINTER 1
-_ACEOF
-
-fi
-rm -f conftest.l $LEX_OUTPUT_ROOT.c
 
-fi
-
-for ac_prog in $LEX flex lex
+for ac_prog in flex
 do
   # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 { echo "$as_me:$LINENO: checking for $ac_word" >&5
 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_XLEX+set}" = set; then
+if test "${ac_cv_prog_FLEX+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  if test -n "$XLEX"; then
-  ac_cv_prog_XLEX="$XLEX" # Let the user override the test.
+  if test -n "$FLEX"; then
+  ac_cv_prog_FLEX="$FLEX" # Let the user override the test.
 else
 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 for as_dir in $PATH
@@ -5220,7 +5011,7 @@ do
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_XLEX="$ac_prog"
+    ac_cv_prog_FLEX="$ac_prog"
     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
     break 2
   fi
@@ -5230,24 +5021,24 @@ IFS=$as_save_IFS
 
 fi
 fi
-XLEX=$ac_cv_prog_XLEX
-if test -n "$XLEX"; then
-  { echo "$as_me:$LINENO: result: $XLEX" >&5
-echo "${ECHO_T}$XLEX" >&6; }
+FLEX=$ac_cv_prog_FLEX
+if test -n "$FLEX"; then
+  { echo "$as_me:$LINENO: result: $FLEX" >&5
+echo "${ECHO_T}$FLEX" >&6; }
 else
   { echo "$as_me:$LINENO: result: no" >&5
 echo "${ECHO_T}no" >&6; }
 fi
 
 
-  test -n "$XLEX" && break
+  test -n "$FLEX" && break
 done
-test -n "$XLEX" || XLEX="none"
+test -n "$FLEX" || FLEX="none"
 
-if test "$XLEX" = "none"
+if test "$FLEX" = "none"
 then
-  { { echo "$as_me:$LINENO: error: no suitable lex found. Please install the 'flex' package." >&5
-echo "$as_me: error: no suitable lex found. Please install the 'flex' package." >&2;}
+  { { echo "$as_me:$LINENO: error: no suitable flex found. Please install the 'flex' package." >&5
+echo "$as_me: error: no suitable flex found. Please install the 'flex' package." >&2;}
    { (exit 1); exit 1; }; }
 fi
 
@@ -7863,270 +7654,412 @@ done
 
 
 
-if test "$have_x" = "yes"
-then
-    XLIB="-lXext -lX11"
-    ac_save_CPPFLAGS="$CPPFLAGS"
-    CPPFLAGS="$CPPFLAGS $X_CFLAGS"
+DLLEXT=""
 
+DLLFLAGS="-D_REENTRANT"
+
+LDSHARED=""
 
+LDDLLFLAGS=""
 
+LIBEXT="so"
 
+IMPLIBEXT="def"
 
+LDRPATH_INSTALL=""
 
+LDRPATH_LOCAL=""
 
+# Extract the first word of "ldd", so it can be a program name with args.
+set dummy ldd; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_path_LDD+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  case $LDD in
+  [\\/]* | ?:[\\/]*)
+  ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
+  ;;
+  *)
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+as_dummy="/sbin:/usr/sbin:$PATH"
+for as_dir in $as_dummy
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
+  test -z "$ac_cv_path_LDD" && ac_cv_path_LDD="true"
+  ;;
+esac
+fi
+LDD=$ac_cv_path_LDD
+if test -n "$LDD"; then
+  { echo "$as_me:$LINENO: result: $LDD" >&5
+echo "${ECHO_T}$LDD" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
 
 
 
-for ac_header in X11/Xlib.h \
-                      X11/XKBlib.h \
-                      X11/Xutil.h \
-                      X11/extensions/shape.h \
-                      X11/extensions/XInput.h \
-                      X11/extensions/XShm.h \
-                      X11/extensions/Xinerama.h \
-                      X11/extensions/Xrandr.h \
-                      X11/extensions/Xrender.h \
-                      X11/extensions/xf86vmode.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+case $host_os in
+  cygwin*|mingw32*)
+    if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
+set dummy ${ac_tool_prefix}dlltool; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_DLLTOOL+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#ifdef HAVE_X11_XLIB_H
-# include <X11/Xlib.h>
-#endif
-#ifdef HAVE_X11_XUTIL_H
-# include <X11/Xutil.h>
-#endif
-
-#include <$ac_header>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  eval "$as_ac_Header=yes"
+  if test -n "$DLLTOOL"; then
+  ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
 else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
-       eval "$as_ac_Header=no"
 fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
+DLLTOOL=$ac_cv_prog_DLLTOOL
+if test -n "$DLLTOOL"; then
+  { echo "$as_me:$LINENO: result: $DLLTOOL" >&5
+echo "${ECHO_T}$DLLTOOL" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
-done
-
 
-                if test "$ac_cv_header_X11_XKBlib_h" = "yes"
-        then
-              { echo "$as_me:$LINENO: checking for XkbQueryExtension in -lX11" >&5
-echo $ECHO_N "checking for XkbQueryExtension in -lX11... $ECHO_C" >&6; }
-if test "${ac_cv_lib_X11_XkbQueryExtension+set}" = set; then
+fi
+if test -z "$ac_cv_prog_DLLTOOL"; then
+  ac_ct_DLLTOOL=$DLLTOOL
+  # Extract the first word of "dlltool", so it can be a program name with args.
+set dummy dlltool; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lX11 $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* 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 XkbQueryExtension ();
-int
-main ()
-{
-return XkbQueryExtension ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_X11_XkbQueryExtension=yes
+  if test -n "$ac_ct_DLLTOOL"; then
+  ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
 else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
-       ac_cv_lib_X11_XkbQueryExtension=no
 fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_X11_XkbQueryExtension" >&5
-echo "${ECHO_T}$ac_cv_lib_X11_XkbQueryExtension" >&6; }
-if test $ac_cv_lib_X11_XkbQueryExtension = yes; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_XKB 1
-_ACEOF
-
+ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
+if test -n "$ac_ct_DLLTOOL"; then
+  { echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
+echo "${ECHO_T}$ac_ct_DLLTOOL" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
-        fi
+  if test "x$ac_ct_DLLTOOL" = x; then
+    DLLTOOL="false"
+  else
+    case $cross_compiling:$ac_tool_warned in
+yes:)
+{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet.  If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&5
+echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet.  If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+ac_tool_warned=yes ;;
+esac
+    DLLTOOL=$ac_ct_DLLTOOL
+  fi
+else
+  DLLTOOL="$ac_cv_prog_DLLTOOL"
+fi
 
-                if test "$ac_cv_header_X11_extensions_XShm_h" = "yes"
-        then
-              { echo "$as_me:$LINENO: checking for XShmQueryExtension in -lXext" >&5
-echo $ECHO_N "checking for XShmQueryExtension in -lXext... $ECHO_C" >&6; }
-if test "${ac_cv_lib_Xext_XShmQueryExtension+set}" = set; then
+    if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
+set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_DLLWRAP+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lXext $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* 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 XShmQueryExtension ();
-int
-main ()
-{
-return XShmQueryExtension ();
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_Xext_XShmQueryExtension=yes
+  if test -n "$DLLWRAP"; then
+  ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
 else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
-       ac_cv_lib_Xext_XShmQueryExtension=no
 fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShmQueryExtension" >&5
-echo "${ECHO_T}$ac_cv_lib_Xext_XShmQueryExtension" >&6; }
-if test $ac_cv_lib_Xext_XShmQueryExtension = yes; then
+DLLWRAP=$ac_cv_prog_DLLWRAP
+if test -n "$DLLWRAP"; then
+  { echo "$as_me:$LINENO: result: $DLLWRAP" >&5
+echo "${ECHO_T}$DLLWRAP" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
 
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBXXSHM 1
-_ACEOF
 
 fi
+if test -z "$ac_cv_prog_DLLWRAP"; then
+  ac_ct_DLLWRAP=$DLLWRAP
+  # Extract the first word of "dllwrap", so it can be a program name with args.
+set dummy dllwrap; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_ac_ct_DLLWRAP+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test -n "$ac_ct_DLLWRAP"; then
+  ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
-        fi
+fi
+fi
+ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
+if test -n "$ac_ct_DLLWRAP"; then
+  { echo "$as_me:$LINENO: result: $ac_ct_DLLWRAP" >&5
+echo "${ECHO_T}$ac_ct_DLLWRAP" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
 
-                if test "$ac_cv_header_X11_extensions_shape_h" = "yes"
-        then
-              { echo "$as_me:$LINENO: checking for XShapeQueryExtension in -lXext" >&5
-echo $ECHO_N "checking for XShapeQueryExtension in -lXext... $ECHO_C" >&6; }
-if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then
+  if test "x$ac_ct_DLLWRAP" = x; then
+    DLLWRAP="false"
+  else
+    case $cross_compiling:$ac_tool_warned in
+yes:)
+{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet.  If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&5
+echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet.  If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+ac_tool_warned=yes ;;
+esac
+    DLLWRAP=$ac_ct_DLLWRAP
+  fi
+else
+  DLLWRAP="$ac_cv_prog_DLLWRAP"
+fi
+
+    if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
+set dummy ${ac_tool_prefix}ar; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_MINGWAR+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lXext $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
+  if test -n "$MINGWAR"; then
+  ac_cv_prog_MINGWAR="$MINGWAR" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_MINGWAR="${ac_tool_prefix}ar"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
-/* 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 XShapeQueryExtension ();
-int
-main ()
-{
-return XShapeQueryExtension ();
-  ;
-  return 0;
-}
+fi
+fi
+MINGWAR=$ac_cv_prog_MINGWAR
+if test -n "$MINGWAR"; then
+  { echo "$as_me:$LINENO: result: $MINGWAR" >&5
+echo "${ECHO_T}$MINGWAR" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+
+
+fi
+if test -z "$ac_cv_prog_MINGWAR"; then
+  ac_ct_MINGWAR=$MINGWAR
+  # Extract the first word of "ar", so it can be a program name with args.
+set dummy ar; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_ac_ct_MINGWAR+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test -n "$ac_ct_MINGWAR"; then
+  ac_cv_prog_ac_ct_MINGWAR="$ac_ct_MINGWAR" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_ac_ct_MINGWAR="ar"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
+
+fi
+fi
+ac_ct_MINGWAR=$ac_cv_prog_ac_ct_MINGWAR
+if test -n "$ac_ct_MINGWAR"; then
+  { echo "$as_me:$LINENO: result: $ac_ct_MINGWAR" >&5
+echo "${ECHO_T}$ac_ct_MINGWAR" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+
+  if test "x$ac_ct_MINGWAR" = x; then
+    MINGWAR="false"
+  else
+    case $cross_compiling:$ac_tool_warned in
+yes:)
+{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet.  If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&5
+echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
+whose name does not start with the host triplet.  If you think this
+configuration is useful to you, please write to autoconf@gnu.org." >&2;}
+ac_tool_warned=yes ;;
+esac
+    MINGWAR=$ac_ct_MINGWAR
+  fi
+else
+  MINGWAR="$ac_cv_prog_MINGWAR"
+fi
+
+    if test "$DLLWRAP" = "false"; then
+      LIBEXT="a"
+    else
+            LIBEXT="dll"
+    fi
+    IMPLIBEXT="a"
+        WIN16_FILES=""
+    WIN16_INSTALL=""
+    ;;
+  darwin*|macosx*)
+    DLLEXT=".so"
+    LIBEXT="dylib"
+    DLLFLAGS="$DLLFLAGS -fPIC"
+    LDDLLFLAGS="-bundle -multiply_defined suppress"
+    LIBWINE_LDFLAGS="-multiply_defined suppress"
+    LDSHARED="\$(CC) -dynamiclib"
+    STRIP="$STRIP -x"
+    LDRPATH_LOCAL="&& install_name_tool -change @executable_path/\`\$(RELPATH) \$(bindir) \$(libdir)\`/libwine.1.dylib @executable_path/\$(TOPOBJDIR)/libs/wine/libwine.1.dylib \$@ || \$(RM) \$@"
+        COREFOUNDATIONLIB="-framework CoreFoundation"
+
+    IOKITLIB="-framework IOKit -framework CoreFoundation"
+
+    LDEXECFLAGS="-image_base 0x7bf00000 -Wl,-segaddr,WINE_DOS,0x00000000,-segaddr,WINE_SHARED_HEAP,0x7f000000"
+
+    if test "$ac_cv_header_DiskArbitration_DiskArbitration_h" = "yes"
+    then
+                DISKARBITRATIONLIB="-framework DiskArbitration -framework CoreFoundation"
+
+    fi
+    if test "$ac_cv_header_CoreAudio_CoreAudio_h" = "yes" -a "$ac_cv_header_AudioUnit_AudioUnit_h" = "yes"
+    then
+                COREAUDIO="-framework CoreAudio -framework AudioUnit -framework CoreServices -framework AudioToolbox -framework CoreMIDI"
+
+    fi
+    case $host_cpu in
+      *powerpc*)
+        LDDLLFLAGS="$LDDLLFLAGS -read_only_relocs warning"          ;;
+    esac
+        if test "$ac_cv_header_Carbon_Carbon_h" = "yes"
+    then
+        CARBONLIB="-framework Carbon"
+
+        QUARTZFILES='$(QUARTZFILES)'
+    fi
+    ;;
+  *)
+    DLLFLAGS="$DLLFLAGS -fPIC"
+    DLLEXT=".so"
+    { echo "$as_me:$LINENO: checking whether we can build a GNU style ELF dll" >&5
+echo $ECHO_N "checking whether we can build a GNU style ELF dll... $ECHO_C" >&6; }
+if test "${ac_cv_c_dll_gnuelf+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -fPIC -shared -Wl,-Bsymbolic"
+cat >conftest.$ac_ext <<_ACEOF
+void myfunc() {}
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
 if { (ac_try="$ac_link"
@@ -8146,39 +8079,31 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_Xext_XShapeQueryExtension=yes
+  ac_cv_c_dll_gnuelf="yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_Xext_XShapeQueryExtension=no
+       ac_cv_c_dll_gnuelf="no"
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
-echo "${ECHO_T}$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
-if test $ac_cv_lib_Xext_XShapeQueryExtension = yes; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBXSHAPE 1
-_ACEOF
-
+CFLAGS=$ac_wine_try_cflags_saved
 fi
-
-        fi
-
-                if test "$ac_cv_header_X11_extensions_xf86vmode_h" = "yes"
-        then
-                { echo "$as_me:$LINENO: checking for XF86VidModeQueryExtension in -lXxf86vm" >&5
-echo $ECHO_N "checking for XF86VidModeQueryExtension in -lXxf86vm... $ECHO_C" >&6; }
-if test "${ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension+set}" = set; then
+{ echo "$as_me:$LINENO: result: $ac_cv_c_dll_gnuelf" >&5
+echo "${ECHO_T}$ac_cv_c_dll_gnuelf" >&6; }
+    if test "$ac_cv_c_dll_gnuelf" = "yes"
+    then
+      LDSHARED="\$(CC) -shared"
+      LDDLLFLAGS="-shared -Wl,-Bsymbolic"
+      { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -shared -Wl,-soname,confest.so.1" >&5
+echo $ECHO_N "checking whether the compiler supports -fPIC -shared -Wl,-soname,confest.so.1... $ECHO_C" >&6; }
+if test "${ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lXxf86vm $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -fPIC -shared -Wl,-soname,confest.so.1"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -8186,17 +8111,10 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 XF86VidModeQueryExtension ();
 int
 main ()
 {
-return XF86VidModeQueryExtension ();
+
   ;
   return 0;
 }
@@ -8219,58 +8137,53 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension=yes
+  ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension=no
+       ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension" >&5
-echo "${ECHO_T}$ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension" >&6; }
-if test $ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension = yes; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBXXF86VM 1
-_ACEOF
-
-                     X_PRE_LIBS="$X_PRE_LIBS -lXxf86vm"
-
+CFLAGS=$ac_wine_try_cflags_saved
 fi
-
-        fi
-
-                if test "$ac_cv_header_X11_extensions_Xrandr_h" = "yes"
-        then
-                cat >conftest.$ac_ext <<_ACEOF
+{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1" >&5
+echo "${ECHO_T}$ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1" >&6; }
+if test $ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1 = yes; then
+  LDSHARED="\$(CC) -shared \$(SONAME:%=-Wl,-soname,%)"
+else
+  { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -shared -Wl,-h,confest.so.1" >&5
+echo $ECHO_N "checking whether the compiler supports -fPIC -shared -Wl,-h,confest.so.1... $ECHO_C" >&6; }
+if test "${ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -fPIC -shared -Wl,-h,confest.so.1"
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <X11/Xlib.h>
-#include <X11/extensions/Xrandr.h>
+
 int
 main ()
 {
-static typeof(XRRSetScreenConfigAndRate) * func;
+
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -8279,31 +8192,36 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBXRANDR 1
-_ACEOF
-
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+       ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1=no
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+CFLAGS=$ac_wine_try_cflags_saved
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1" >&5
+echo "${ECHO_T}$ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1" >&6; }
+if test $ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1 = yes; then
+  LDSHARED="\$(CC) -shared \$(SONAME:%=-Wl,-h,%)"
+fi
 
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-        fi
 
-                if test "$ac_cv_header_X11_extensions_Xrender_h" = "yes"
-        then
-              { echo "$as_me:$LINENO: checking for XRenderSetPictureTransform in -lXrender" >&5
-echo $ECHO_N "checking for XRenderSetPictureTransform in -lXrender... $ECHO_C" >&6; }
-if test "${ac_cv_lib_Xrender_XRenderSetPictureTransform+set}" = set; then
+      { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -shared -Wl,-Bsymbolic,-z,defs" >&5
+echo $ECHO_N "checking whether the compiler supports -fPIC -shared -Wl,-Bsymbolic,-z,defs... $ECHO_C" >&6; }
+if test "${ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lXrender $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -fPIC -shared -Wl,-Bsymbolic,-z,defs"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -8311,17 +8229,10 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 XRenderSetPictureTransform ();
 int
 main ()
 {
-return XRenderSetPictureTransform ();
+
   ;
   return 0;
 }
@@ -8344,56 +8255,55 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_Xrender_XRenderSetPictureTransform=yes
+  ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_Xrender_XRenderSetPictureTransform=no
+       ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+CFLAGS=$ac_wine_try_cflags_saved
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xrender_XRenderSetPictureTransform" >&5
-echo "${ECHO_T}$ac_cv_lib_Xrender_XRenderSetPictureTransform" >&6; }
-if test $ac_cv_lib_Xrender_XRenderSetPictureTransform = yes; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_XRENDERSETPICTURETRANSFORM 1
-_ACEOF
-
+{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs" >&5
+echo "${ECHO_T}$ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs" >&6; }
+if test $ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs = yes; then
+  LDDLLFLAGS="$LDDLLFLAGS,-z,defs"
 fi
 
-        fi
 
-                if test "$ac_cv_header_X11_extensions_Xinerama_h" = "yes"
-        then
-                cat >conftest.$ac_ext <<_ACEOF
+      { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -shared -Wl,-Bsymbolic,-init,__wine_spec_init,-fini,__wine_spec_fini" >&5
+echo $ECHO_N "checking whether the compiler supports -fPIC -shared -Wl,-Bsymbolic,-init,__wine_spec_init,-fini,__wine_spec_fini... $ECHO_C" >&6; }
+if test "${ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -fPIC -shared -Wl,-Bsymbolic,-init,__wine_spec_init,-fini,__wine_spec_fini"
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <X11/Xlib.h>
-#include <X11/extensions/Xinerama.h>
+
 int
 main ()
 {
-static typeof(XineramaQueryScreens) * func;
+
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -8402,57 +8312,58 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBXINERAMA 1
-_ACEOF
-
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-
+       ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini=no
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-        fi
-
-
-        if test "x$with_opengl" != "xno"
-    then
-
-
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+CFLAGS=$ac_wine_try_cflags_saved
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini" >&5
+echo "${ECHO_T}$ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini" >&6; }
+if test $ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini = yes; then
+  LDDLLFLAGS="$LDDLLFLAGS,-init,__wine_spec_init,-fini,__wine_spec_fini"
+fi
 
 
-for ac_header in GL/gl.h GL/glx.h GL/glext.h GL/glu.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+      echo '{ global: *; };' >conftest.map
+      { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -shared -Wl,--version-script=conftest.map" >&5
+echo $ECHO_N "checking whether the compiler supports -fPIC -shared -Wl,--version-script=conftest.map... $ECHO_C" >&6; }
+if test "${ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  cat >conftest.$ac_ext <<_ACEOF
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -fPIC -shared -Wl,--version-script=conftest.map"
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#ifdef HAVE_GL_GLX_H
-# include <GL/glx.h>
-#endif
 
-#include <$ac_header>
+int
+main ()
+{
+
+  ;
+  return 0;
+}
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -8461,59 +8372,58 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  eval "$as_ac_Header=yes"
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       eval "$as_ac_Header=no"
+       ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map=no
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+CFLAGS=$ac_wine_try_cflags_saved
 fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
+{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map" >&5
+echo "${ECHO_T}$ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map" >&6; }
+if test $ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map = yes; then
+  LDSHARED="$LDSHARED \$(VERSCRIPT:%=-Wl,--version-script=%)"
 fi
 
-done
+      rm -f conftest.map
 
-       if test "$ac_cv_header_GL_gl_h" = "yes" -a "$ac_cv_header_GL_glx_h" = "yes"
-       then
-                   { echo "$as_me:$LINENO: checking for up-to-date OpenGL version" >&5
-echo $ECHO_N "checking for up-to-date OpenGL version... $ECHO_C" >&6; }
-if test "${wine_cv_opengl_header_version_OK+set}" = set; then
+      { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -Wl,--export-dynamic" >&5
+echo $ECHO_N "checking whether the compiler supports -fPIC -Wl,--export-dynamic... $ECHO_C" >&6; }
+if test "${ac_cv_cflags__fPIC__Wl___export_dynamic+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  cat >conftest.$ac_ext <<_ACEOF
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -fPIC -Wl,--export-dynamic"
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <GL/gl.h>
+
 int
 main ()
 {
-GLenum test = GL_UNSIGNED_SHORT_5_6_5;
+
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -8522,31 +8432,36 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  wine_cv_opengl_header_version_OK="yes"
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_cflags__fPIC__Wl___export_dynamic=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       wine_cv_opengl_header_version_OK="no"
-
+       ac_cv_cflags__fPIC__Wl___export_dynamic=no
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+CFLAGS=$ac_wine_try_cflags_saved
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__Wl___export_dynamic" >&5
+echo "${ECHO_T}$ac_cv_cflags__fPIC__Wl___export_dynamic" >&6; }
+if test $ac_cv_cflags__fPIC__Wl___export_dynamic = yes; then
+  LDEXECFLAGS="-Wl,--export-dynamic"
 
 fi
-{ echo "$as_me:$LINENO: result: $wine_cv_opengl_header_version_OK" >&5
-echo "${ECHO_T}$wine_cv_opengl_header_version_OK" >&6; }
 
-           if test "$wine_cv_opengl_header_version_OK" = "yes"
-            then
-                               { echo "$as_me:$LINENO: checking for glXCreateContext in -lGL" >&5
-echo $ECHO_N "checking for glXCreateContext in -lGL... $ECHO_C" >&6; }
-if test "${ac_cv_lib_GL_glXCreateContext+set}" = set; then
+
+      as_ac_var=`echo "ac_cv_cflags_-fPIC -Wl,--rpath,\$ORIGIN/../lib" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -Wl,--rpath,\$ORIGIN/../lib" >&5
+echo $ECHO_N "checking whether the compiler supports -fPIC -Wl,--rpath,\$ORIGIN/../lib... $ECHO_C" >&6; }
+if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lGL $X_LIBS -lXext -lX11 -lm $X_EXTRA_LIBS $LIBS"
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -fPIC -Wl,--rpath,\$ORIGIN/../lib"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -8554,17 +8469,10 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 glXCreateContext ();
 int
 main ()
 {
-return glXCreateContext ();
+
   ;
   return 0;
 }
@@ -8587,40 +8495,33 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_GL_glXCreateContext=yes
+  eval "$as_ac_var=yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_GL_glXCreateContext=no
+       eval "$as_ac_var=no"
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_GL_glXCreateContext" >&5
-echo "${ECHO_T}$ac_cv_lib_GL_glXCreateContext" >&6; }
-if test $ac_cv_lib_GL_glXCreateContext = yes; then
-  OPENGL_LIBS="-lGL"
-                             OPENGLFILES='$(OPENGLFILES)'
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_OPENGL 1
-_ACEOF
-
-
+CFLAGS=$ac_wine_try_cflags_saved
 fi
-
-
-                               { echo "$as_me:$LINENO: checking for gluLookAt in -lGLU" >&5
-echo $ECHO_N "checking for gluLookAt in -lGLU... $ECHO_C" >&6; }
-if test "${ac_cv_lib_GLU_gluLookAt+set}" = set; then
+ac_res=`eval echo '${'$as_ac_var'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+  LDRPATH_INSTALL="-Wl,--rpath,\\\$\$ORIGIN/\`\$(RELPATH) \$(bindir) \$(libdir)\`"
+                       LDRPATH_LOCAL="-Wl,--rpath,\\\$\$ORIGIN/\$(TOPOBJDIR)/libs/wine"
+else
+  as_ac_var=`echo "ac_cv_cflags_-fPIC -Wl,-R,\$ORIGIN/../lib" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -Wl,-R,\$ORIGIN/../lib" >&5
+echo $ECHO_N "checking whether the compiler supports -fPIC -Wl,-R,\$ORIGIN/../lib... $ECHO_C" >&6; }
+if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lGLU $OPENGL_LIBS $X_LIBS $X_PRE_LIBS -lXext -lX11 -lm $X_EXTRA_LIBS
-                $LIBS"
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -fPIC -Wl,-R,\$ORIGIN/../lib"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -8628,17 +8529,10 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 gluLookAt ();
 int
 main ()
 {
-return gluLookAt ();
+
   ;
   return 0;
 }
@@ -8661,67 +8555,61 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_GLU_gluLookAt=yes
+  eval "$as_ac_var=yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_GLU_gluLookAt=no
+       eval "$as_ac_var=no"
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+CFLAGS=$ac_wine_try_cflags_saved
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_GLU_gluLookAt" >&5
-echo "${ECHO_T}$ac_cv_lib_GLU_gluLookAt" >&6; }
-if test $ac_cv_lib_GLU_gluLookAt = yes; then
-  OPENGL_LIBS="$OPENGL_LIBS -lGLU"
-                            GLU32FILES='$(GLU32FILES)'
-
+ac_res=`eval echo '${'$as_ac_var'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+  LDRPATH_INSTALL="-Wl,-R,\\\$\$ORIGIN/\`\$(RELPATH) \$(bindir) \$(libdir)\`"
+                            LDRPATH_LOCAL="-Wl,-R,\\\$\$ORIGIN/\$(TOPOBJDIR)/libs/wine"
 fi
 
-            fi
-         else
-             wine_cv_opengl_headers_found="no"
-        fi
-    fi
-        NASLIBS=""
+fi
 
 
-for ac_header in audio/audiolib.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  { echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+      case $host_cpu in
+        *i[3456789]86* | x86_64)
+          { echo "$as_me:$LINENO: checking whether the compiler supports -Wl,--section-start,.interp=0x7bf00400" >&5
+echo $ECHO_N "checking whether the compiler supports -Wl,--section-start,.interp=0x7bf00400... $ECHO_C" >&6; }
+if test "${ac_cv_cflags__Wl___section_start__interp_0x7bf00400+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
 else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -Wl,--section-start,.interp=0x7bf00400"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-$ac_includes_default
-#include <$ac_header>
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -8730,190 +8618,87 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_cflags__Wl___section_start__interp_0x7bf00400=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_header_compiler=no
+       ac_cv_cflags__Wl___section_start__interp_0x7bf00400=no
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+CFLAGS=$ac_wine_try_cflags_saved
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_cflags__Wl___section_start__interp_0x7bf00400" >&5
+echo "${ECHO_T}$ac_cv_cflags__Wl___section_start__interp_0x7bf00400" >&6; }
+if test $ac_cv_cflags__Wl___section_start__interp_0x7bf00400 = yes; then
+  LDEXECFLAGS="$LDEXECFLAGS -Wl,--section-start,.interp=0x7bf00400"
+fi
 
-# Is the header present?
-{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
+          ;;
+      esac
+
+    else
+      { echo "$as_me:$LINENO: checking whether we can build a UnixWare (Solaris) dll" >&5
+echo $ECHO_N "checking whether we can build a UnixWare (Solaris) dll... $ECHO_C" >&6; }
+if test "${ac_cv_c_dll_unixware+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -fPIC -Wl,-G,-h,conftest.so.1.0,-B,symbolic"
 cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <$ac_header>
+void myfunc() {}
 _ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
   cat conftest.err >&5
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-        test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_c_dll_unixware="yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-  ac_header_preproc=no
-fi
-
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
-    ( cat <<\_ASBOX
-## ------------------------------------ ##
-## Report this to wine-devel@winehq.org ##
-## ------------------------------------ ##
-_ASBOX
-     ) | sed "s/^/$as_me: WARNING:     /" >&2
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  eval "$as_ac_Header=\$ac_header_preproc"
+       ac_cv_c_dll_unixware="no"
 fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
 
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+CFLAGS=$ac_wine_try_cflags_saved
 fi
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
+{ echo "$as_me:$LINENO: result: $ac_cv_c_dll_unixware" >&5
+echo "${ECHO_T}$ac_cv_c_dll_unixware" >&6; }
+      if test "$ac_cv_c_dll_unixware" = "yes"
+      then
+        LDSHARED="\$(CC) -Wl,-G \$(SONAME:%=-Wl,-h,%)"
+        LDDLLFLAGS="-Wl,-G,-B,symbolic"
 
-for ac_header in audio/soundlib.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+      else
+        { echo "$as_me:$LINENO: checking whether we can build an HP-UX dll" >&5
+echo $ECHO_N "checking whether we can build an HP-UX dll... $ECHO_C" >&6; }
+if test "${ac_cv_c_dll_hpux+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <audio/audiolib.h>
-
-#include <$ac_header>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  eval "$as_ac_Header=yes"
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-       eval "$as_ac_Header=no"
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-          { echo "$as_me:$LINENO: checking for AuCreateFlow in -laudio" >&5
-echo $ECHO_N "checking for AuCreateFlow in -laudio... $ECHO_C" >&6; }
-if test "${ac_cv_lib_audio_AuCreateFlow+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-laudio -lXt $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* 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 AuCreateFlow ();
-int
-main ()
-{
-return AuCreateFlow ();
-  ;
-  return 0;
-}
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -shared"
+cat >conftest.$ac_ext <<_ACEOF
+void myfunc() {}
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
 if { (ac_try="$ac_link"
@@ -8933,204 +8718,325 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_audio_AuCreateFlow=yes
+  ac_cv_c_dll_hpux="yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_audio_AuCreateFlow=no
+       ac_cv_c_dll_hpux="no"
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+CFLAGS=$ac_wine_try_cflags_saved
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_audio_AuCreateFlow" >&5
-echo "${ECHO_T}$ac_cv_lib_audio_AuCreateFlow" >&6; }
-if test $ac_cv_lib_audio_AuCreateFlow = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_c_dll_hpux" >&5
+echo "${ECHO_T}$ac_cv_c_dll_hpux" >&6; }
+        if test "$ac_cv_c_dll_hpux" = "yes"
+        then
+          LIBEXT="sl"
+          DLLEXT=".sl"
+          LDDLLFLAGS="-shared -fPIC"
+          LDSHARED="\$(CC) -shared"
+        fi
+      fi
+    fi
 
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_NAS 1
-_ACEOF
+        CROSSTEST=""
 
-                        NASLIBS="-laudio -lXt $X_LIBS -lXext -lX11 $X_EXTRA_LIBS"
-fi
+    if test "$cross_compiling" = "no"
+    then
+      for ac_prog in i586-mingw32msvc-gcc i386-mingw32msvc-gcc i386-mingw32-gcc mingw32-gcc mingw-gcc
+do
+  # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_CROSSCC+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test -n "$CROSSCC"; then
+  ac_cv_prog_CROSSCC="$CROSSCC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_CROSSCC="$ac_prog"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
 fi
+fi
+CROSSCC=$ac_cv_prog_CROSSCC
+if test -n "$CROSSCC"; then
+  { echo "$as_me:$LINENO: result: $CROSSCC" >&5
+echo "${ECHO_T}$CROSSCC" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+
 
+  test -n "$CROSSCC" && break
 done
+test -n "$CROSSCC" || CROSSCC="false"
 
+      for ac_prog in i586-mingw32msvc-dlltool i386-mingw32msvc-dlltool i386-mingw32-dlltool mingw32-dlltool mingw-dlltool
+do
+  # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_DLLTOOL+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test -n "$DLLTOOL"; then
+  ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_DLLTOOL="$ac_prog"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
-    CPPFLAGS="$ac_save_CPPFLAGS"
-    XFILES='$(XFILES)'
+fi
+fi
+DLLTOOL=$ac_cv_prog_DLLTOOL
+if test -n "$DLLTOOL"; then
+  { echo "$as_me:$LINENO: result: $DLLTOOL" >&5
+echo "${ECHO_T}$DLLTOOL" >&6; }
 else
-    XLIB=""
-    X_CFLAGS=""
-    X_LIBS=""
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
 
-XML2LIBS=""
+  test -n "$DLLTOOL" && break
+done
+test -n "$DLLTOOL" || DLLTOOL="false"
 
-XML2INCL=""
+      for ac_prog in i586-mingw32msvc-windres i386-mingw32msvc-windres i386-mingw32-windres mingw32-windres mingw-windres
+do
+  # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_CROSSWINDRES+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test -n "$CROSSWINDRES"; then
+  ac_cv_prog_CROSSWINDRES="$CROSSWINDRES" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_CROSSWINDRES="$ac_prog"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
-XSLTLIBS=""
+fi
+fi
+CROSSWINDRES=$ac_cv_prog_CROSSWINDRES
+if test -n "$CROSSWINDRES"; then
+  { echo "$as_me:$LINENO: result: $CROSSWINDRES" >&5
+echo "${ECHO_T}$CROSSWINDRES" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
 
-XSLTINCL=""
 
-if test "$PKG_CONFIG" != "false"
-then
-    ac_save_CPPFLAGS="$CPPFLAGS"
-    ac_xml_libs="`$PKG_CONFIG --libs libxml-2.0 2>/dev/null`"
-    ac_xml_cflags="`$PKG_CONFIG --cflags libxml-2.0 2>/dev/null`"
-    CPPFLAGS="$CPPFLAGS $ac_xml_cflags"
+  test -n "$CROSSWINDRES" && break
+done
+test -n "$CROSSWINDRES" || CROSSWINDRES="false"
 
-for ac_header in libxml/parser.h
+      for ac_prog in i586-mingw32msvc-ar i386-mingw32msvc-ar i386-mingw32-ar mingw32-ar mingw-ar
 do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  { echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+  # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_MINGWAR+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
 else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-$ac_includes_default
-#include <$ac_header>
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
+  if test -n "$MINGWAR"; then
+  ac_cv_prog_MINGWAR="$MINGWAR" # Let the user override the test.
 else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_MINGWAR="$ac_prog"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
-       ac_header_compiler=no
+fi
+fi
+MINGWAR=$ac_cv_prog_MINGWAR
+if test -n "$MINGWAR"; then
+  { echo "$as_me:$LINENO: result: $MINGWAR" >&5
+echo "${ECHO_T}$MINGWAR" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
 
-# Is the header present?
-{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
+  test -n "$MINGWAR" && break
+done
+test -n "$MINGWAR" || MINGWAR="false"
+
+      if test "$CROSSCC" != "false"; then CROSSTEST="\$(CROSSTEST)"; fi
+    fi
+    ;;
+esac
+
+if test "$LIBEXT" = "a"; then
+  { { echo "$as_me:$LINENO: error: could not find a way to build shared libraries.
+It is currently not possible to build Wine without shared library
+(.so) support to allow transparent switch between .so and .dll files.
+If you are using Linux, you will need a newer binutils.
+" >&5
+echo "$as_me: error: could not find a way to build shared libraries.
+It is currently not possible to build Wine without shared library
+(.so) support to allow transparent switch between .so and .dll files.
+If you are using Linux, you will need a newer binutils.
+" >&2;}
+   { (exit 1); exit 1; }; }
+fi
+
+
+if test "$have_x" = "yes"
+then
+    XLIB="-lXext -lX11"
+    ac_save_CPPFLAGS="$CPPFLAGS"
+    CPPFLAGS="$CPPFLAGS $X_CFLAGS"
+
+
+
+
+
+
+
+
+
+
+
+
+for ac_header in X11/Xlib.h \
+                      X11/XKBlib.h \
+                      X11/Xutil.h \
+                      X11/Xcursor/Xcursor.h \
+                      X11/extensions/shape.h \
+                      X11/extensions/XInput.h \
+                      X11/extensions/XShm.h \
+                      X11/extensions/Xinerama.h \
+                      X11/extensions/Xrandr.h \
+                      X11/extensions/Xrender.h \
+                      X11/extensions/xf86vmode.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
+#ifdef HAVE_X11_XLIB_H
+# include <X11/Xlib.h>
+#endif
+#ifdef HAVE_X11_XUTIL_H
+# include <X11/Xutil.h>
+#endif
+
 #include <$ac_header>
 _ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
   cat conftest.err >&5
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-        test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
+       } && test -s conftest.$ac_objext; then
+  eval "$as_ac_Header=yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-  ac_header_preproc=no
+       eval "$as_ac_Header=no"
 fi
 
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
-    ( cat <<\_ASBOX
-## ------------------------------------ ##
-## Report this to wine-devel@winehq.org ##
-## ------------------------------------ ##
-_ASBOX
-     ) | sed "s/^/$as_me: WARNING:     /" >&2
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  eval "$as_ac_Header=\$ac_header_preproc"
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
 ac_res=`eval echo '${'$as_ac_Header'}'`
               { echo "$as_me:$LINENO: result: $ac_res" >&5
 echo "${ECHO_T}$ac_res" >&6; }
-
-fi
 if test `eval echo '${'$as_ac_Header'}'` = yes; then
   cat >>confdefs.h <<_ACEOF
 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
 _ACEOF
- { echo "$as_me:$LINENO: checking for xmlParseMemory in -lxml2" >&5
-echo $ECHO_N "checking for xmlParseMemory in -lxml2... $ECHO_C" >&6; }
-if test "${ac_cv_lib_xml2_xmlParseMemory+set}" = set; then
+
+fi
+
+done
+
+
+                if test "$ac_cv_header_X11_XKBlib_h" = "yes"
+        then
+              { echo "$as_me:$LINENO: checking for XkbQueryExtension in -lX11" >&5
+echo $ECHO_N "checking for XkbQueryExtension in -lX11... $ECHO_C" >&6; }
+if test "${ac_cv_lib_X11_XkbQueryExtension+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lxml2 $ac_xml_libs $LIBS"
+LIBS="-lX11 $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -9144,11 +9050,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char xmlParseMemory ();
+char XkbQueryExtension ();
 int
 main ()
 {
-return xmlParseMemory ();
+return XkbQueryExtension ();
   ;
   return 0;
 }
@@ -9171,37 +9077,39 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_xml2_xmlParseMemory=yes
+  ac_cv_lib_X11_XkbQueryExtension=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_xml2_xmlParseMemory=no
+       ac_cv_lib_X11_XkbQueryExtension=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlParseMemory" >&5
-echo "${ECHO_T}$ac_cv_lib_xml2_xmlParseMemory" >&6; }
-if test $ac_cv_lib_xml2_xmlParseMemory = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_X11_XkbQueryExtension" >&5
+echo "${ECHO_T}$ac_cv_lib_X11_XkbQueryExtension" >&6; }
+if test $ac_cv_lib_X11_XkbQueryExtension = yes; then
 
 cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBXML2 1
+#define HAVE_XKB 1
 _ACEOF
 
-             XML2LIBS="$ac_xml_libs"
-             XML2INCL="$ac_xml_cflags"
 fi
 
-         { echo "$as_me:$LINENO: checking for xmlReadMemory in -lxml2" >&5
-echo $ECHO_N "checking for xmlReadMemory in -lxml2... $ECHO_C" >&6; }
-if test "${ac_cv_lib_xml2_xmlReadMemory+set}" = set; then
+        fi
+
+                if test "$ac_cv_header_X11_extensions_XShm_h" = "yes"
+        then
+              { echo "$as_me:$LINENO: checking for XShmQueryExtension in -lXext" >&5
+echo $ECHO_N "checking for XShmQueryExtension in -lXext... $ECHO_C" >&6; }
+if test "${ac_cv_lib_Xext_XShmQueryExtension+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lxml2 $ac_xml_libs $LIBS"
+LIBS="-lXext $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -9215,11 +9123,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char xmlReadMemory ();
+char XShmQueryExtension ();
 int
 main ()
 {
-return xmlReadMemory ();
+return XShmQueryExtension ();
   ;
   return 0;
 }
@@ -9242,35 +9150,39 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_xml2_xmlReadMemory=yes
+  ac_cv_lib_Xext_XShmQueryExtension=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_xml2_xmlReadMemory=no
+       ac_cv_lib_Xext_XShmQueryExtension=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlReadMemory" >&5
-echo "${ECHO_T}$ac_cv_lib_xml2_xmlReadMemory" >&6; }
-if test $ac_cv_lib_xml2_xmlReadMemory = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShmQueryExtension" >&5
+echo "${ECHO_T}$ac_cv_lib_Xext_XShmQueryExtension" >&6; }
+if test $ac_cv_lib_Xext_XShmQueryExtension = yes; then
 
 cat >>confdefs.h <<\_ACEOF
-#define HAVE_XMLREADMEMORY 1
+#define HAVE_LIBXXSHM 1
 _ACEOF
 
 fi
 
-         { echo "$as_me:$LINENO: checking for xmlNewDocPI in -lxml2" >&5
-echo $ECHO_N "checking for xmlNewDocPI in -lxml2... $ECHO_C" >&6; }
-if test "${ac_cv_lib_xml2_xmlNewDocPI+set}" = set; then
+        fi
+
+                if test "$ac_cv_header_X11_extensions_shape_h" = "yes"
+        then
+              { echo "$as_me:$LINENO: checking for XShapeQueryExtension in -lXext" >&5
+echo $ECHO_N "checking for XShapeQueryExtension in -lXext... $ECHO_C" >&6; }
+if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lxml2 $ac_xml_libs $LIBS"
+LIBS="-lXext $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -9284,11 +9196,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char xmlNewDocPI ();
+char XShapeQueryExtension ();
 int
 main ()
 {
-return xmlNewDocPI ();
+return XShapeQueryExtension ();
   ;
   return 0;
 }
@@ -9311,58 +9223,122 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_xml2_xmlNewDocPI=yes
+  ac_cv_lib_Xext_XShapeQueryExtension=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_xml2_xmlNewDocPI=no
+       ac_cv_lib_Xext_XShapeQueryExtension=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlNewDocPI" >&5
-echo "${ECHO_T}$ac_cv_lib_xml2_xmlNewDocPI" >&6; }
-if test $ac_cv_lib_xml2_xmlNewDocPI = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
+echo "${ECHO_T}$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
+if test $ac_cv_lib_Xext_XShapeQueryExtension = yes; then
 
 cat >>confdefs.h <<\_ACEOF
-#define HAVE_XMLNEWDOCPI 1
+#define HAVE_LIBXSHAPE 1
 _ACEOF
 
 fi
 
+        fi
+
+                if test "$ac_cv_header_X11_extensions_xf86vmode_h" = "yes"
+        then
+                { echo "$as_me:$LINENO: checking for XF86VidModeQueryExtension in -lXxf86vm" >&5
+echo $ECHO_N "checking for XF86VidModeQueryExtension in -lXxf86vm... $ECHO_C" >&6; }
+if test "${ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lXxf86vm $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* 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 XF86VidModeQueryExtension ();
+int
+main ()
+{
+return XF86VidModeQueryExtension ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
 
+       ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension=no
 fi
 
-done
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension" >&5
+echo "${ECHO_T}$ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension" >&6; }
+if test $ac_cv_lib_Xxf86vm_XF86VidModeQueryExtension = yes; then
 
-    CPPFLAGS="$ac_save_CPPFLAGS"
-    ac_xslt_libs="`$PKG_CONFIG --libs libxslt 2>/dev/null`"
-    ac_xslt_cflags="`$PKG_CONFIG --cflags libxslt 2>/dev/null`"
-    CPPFLAGS="$CPPFLAGS $ac_xslt_cflags"
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_LIBXXF86VM 1
+_ACEOF
 
+                     X_PRE_LIBS="$X_PRE_LIBS -lXxf86vm"
 
-for ac_header in libxslt/pattern.h libxslt/transform.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
+fi
+
+        fi
+
+                if test "$ac_cv_header_X11_extensions_Xrandr_h" = "yes"
+        then
+                cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#ifdef HAVE_LIBXSLT_PATTERN_H
-# include <libxslt/pattern.h>
-#endif
-
-#include <$ac_header>
+#include <X11/Xlib.h>
+#include <X11/extensions/Xrandr.h>
+int
+main ()
+{
+static typeof(XRRSetScreenConfigAndRate) * func;
+  ;
+  return 0;
+}
 _ACEOF
 rm -f conftest.$ac_objext
 if { (ac_try="$ac_compile"
@@ -9381,30 +9357,30 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
        } && test -s conftest.$ac_objext; then
-  eval "$as_ac_Header=yes"
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_LIBXRANDR 1
+_ACEOF
+
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       eval "$as_ac_Header=no"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
- { echo "$as_me:$LINENO: checking for xsltCompilePattern in -lxslt" >&5
-echo $ECHO_N "checking for xsltCompilePattern in -lxslt... $ECHO_C" >&6; }
-if test "${ac_cv_lib_xslt_xsltCompilePattern+set}" = set; then
+        fi
+
+                if test "$ac_cv_header_X11_extensions_Xrender_h" = "yes"
+        then
+              { echo "$as_me:$LINENO: checking for XRenderSetPictureTransform in -lXrender" >&5
+echo $ECHO_N "checking for XRenderSetPictureTransform in -lXrender... $ECHO_C" >&6; }
+if test "${ac_cv_lib_Xrender_XRenderSetPictureTransform+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lxslt $ac_xslt_libs $LIBS"
+LIBS="-lXrender $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -9418,11 +9394,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char xsltCompilePattern ();
+char XRenderSetPictureTransform ();
 int
 main ()
 {
-return xsltCompilePattern ();
+return XRenderSetPictureTransform ();
   ;
   return 0;
 }
@@ -9445,72 +9421,47 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_xslt_xsltCompilePattern=yes
+  ac_cv_lib_Xrender_XRenderSetPictureTransform=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_xslt_xsltCompilePattern=no
+       ac_cv_lib_Xrender_XRenderSetPictureTransform=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltCompilePattern" >&5
-echo "${ECHO_T}$ac_cv_lib_xslt_xsltCompilePattern" >&6; }
-if test $ac_cv_lib_xslt_xsltCompilePattern = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xrender_XRenderSetPictureTransform" >&5
+echo "${ECHO_T}$ac_cv_lib_Xrender_XRenderSetPictureTransform" >&6; }
+if test $ac_cv_lib_Xrender_XRenderSetPictureTransform = yes; then
 
 cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBXSLT 1
+#define HAVE_XRENDERSETPICTURETRANSFORM 1
 _ACEOF
 
-             XSLTLIBS="$ac_xslt_libs"
-             XSLTINCL="$ac_xslt_cflags"
-fi
-
-
-fi
-
-done
-
-    CPPFLAGS="$ac_save_CPPFLAGS"
 fi
 
-HALINCL=""
-
-if test "$PKG_CONFIG" != "false"
-then
-    ac_save_CPPFLAGS="$CPPFLAGS"
-    ac_hal_libs="`$PKG_CONFIG --libs hal 2>/dev/null`"
-    ac_hal_cflags="`$PKG_CONFIG --cflags hal 2>/dev/null`"
-    CPPFLAGS="$CPPFLAGS $ac_hal_cflags"
-
+        fi
 
-for ac_header in dbus/dbus.h hal/libhal.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  { echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
-echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
+                if test "$ac_cv_header_X11_extensions_Xinerama_h" = "yes"
+        then
+                cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-$ac_includes_default
-#include <$ac_header>
+#include <X11/Xlib.h>
+#include <X11/extensions/Xinerama.h>
+int
+main ()
+{
+static typeof(XineramaQueryScreens) * func;
+  ;
+  return 0;
+}
 _ACEOF
 rm -f conftest.$ac_objext
 if { (ac_try="$ac_compile"
@@ -9529,99 +9480,78 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
        } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_LIBXINERAMA 1
+_ACEOF
+
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_header_compiler=no
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
+        fi
 
-# Is the header present?
-{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
-echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
+
+        if test "x$with_opengl" != "xno"
+    then
+
+
+
+
+for ac_header in GL/gl.h GL/glx.h GL/glext.h GL/glu.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
+#ifdef HAVE_GL_GLX_H
+# include <GL/glx.h>
+#endif
+
 #include <$ac_header>
 _ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
   cat conftest.err >&5
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-        test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
+       } && test -s conftest.$ac_objext; then
+  eval "$as_ac_Header=yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-  ac_header_preproc=no
+       eval "$as_ac_Header=no"
 fi
 
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
-echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
-    ( cat <<\_ASBOX
-## ------------------------------------ ##
-## Report this to wine-devel@winehq.org ##
-## ------------------------------------ ##
-_ASBOX
-     ) | sed "s/^/$as_me: WARNING:     /" >&2
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  eval "$as_ac_Header=\$ac_header_preproc"
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
 ac_res=`eval echo '${'$as_ac_Header'}'`
               { echo "$as_me:$LINENO: result: $ac_res" >&5
 echo "${ECHO_T}$ac_res" >&6; }
-
-fi
 if test `eval echo '${'$as_ac_Header'}'` = yes; then
   cat >>confdefs.h <<_ACEOF
 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
@@ -9631,45 +9561,36 @@ fi
 
 done
 
-    if test "$ac_cv_header_dbus_dbus_h" = "yes" -a "$ac_cv_header_hal_libhal_h" = "yes"
-    then
-        { echo "$as_me:$LINENO: checking for libhal_ctx_new in -lhal" >&5
-echo $ECHO_N "checking for libhal_ctx_new in -lhal... $ECHO_C" >&6; }
-if test "${ac_cv_lib_hal_libhal_ctx_new+set}" = set; then
+       if test "$ac_cv_header_GL_gl_h" = "yes" -a "$ac_cv_header_GL_glx_h" = "yes"
+       then
+                   { echo "$as_me:$LINENO: checking for up-to-date OpenGL version" >&5
+echo $ECHO_N "checking for up-to-date OpenGL version... $ECHO_C" >&6; }
+if test "${wine_cv_opengl_header_version_OK+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lhal  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 libhal_ctx_new ();
+#include <GL/gl.h>
 int
 main ()
 {
-return libhal_ctx_new ();
+GLenum test = GL_UNSIGNED_SHORT_5_6_5;
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -9678,30 +9599,29 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_hal_libhal_ctx_new=yes
+       } && test -s conftest.$ac_objext; then
+  wine_cv_opengl_header_version_OK="yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_hal_libhal_ctx_new=no
+       wine_cv_opengl_header_version_OK="no"
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_hal_libhal_ctx_new" >&5
-echo "${ECHO_T}$ac_cv_lib_hal_libhal_ctx_new" >&6; }
-if test $ac_cv_lib_hal_libhal_ctx_new = yes; then
-  { echo "$as_me:$LINENO: checking for dbus_connection_close in -ldbus-1" >&5
-echo $ECHO_N "checking for dbus_connection_close in -ldbus-1... $ECHO_C" >&6; }
-if test "${ac_cv_lib_dbus_1_dbus_connection_close+set}" = set; then
+{ echo "$as_me:$LINENO: result: $wine_cv_opengl_header_version_OK" >&5
+echo "${ECHO_T}$wine_cv_opengl_header_version_OK" >&6; }
+
+           if test "$wine_cv_opengl_header_version_OK" = "yes"
+            then
+                               { echo "$as_me:$LINENO: checking for glXCreateContext in -lGL" >&5
+echo $ECHO_N "checking for glXCreateContext in -lGL... $ECHO_C" >&6; }
+if test "${ac_cv_lib_GL_glXCreateContext+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldbus-1 $ac_hal_libs $LIBS"
+LIBS="-lGL $X_LIBS -lXext -lX11 -lm $X_EXTRA_LIBS $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -9715,11 +9635,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char dbus_connection_close ();
+char glXCreateContext ();
 int
 main ()
 {
-return dbus_connection_close ();
+return glXCreateContext ();
   ;
   return 0;
 }
@@ -9742,45 +9662,40 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_dbus_1_dbus_connection_close=yes
+  ac_cv_lib_GL_glXCreateContext=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_dbus_1_dbus_connection_close=no
+       ac_cv_lib_GL_glXCreateContext=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_dbus_1_dbus_connection_close" >&5
-echo "${ECHO_T}$ac_cv_lib_dbus_1_dbus_connection_close" >&6; }
-if test $ac_cv_lib_dbus_1_dbus_connection_close = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_GL_glXCreateContext" >&5
+echo "${ECHO_T}$ac_cv_lib_GL_glXCreateContext" >&6; }
+if test $ac_cv_lib_GL_glXCreateContext = yes; then
+  OPENGL_LIBS="-lGL"
+                             OPENGLFILES='$(OPENGLFILES)'
 
 cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBHAL 1
+#define HAVE_OPENGL 1
 _ACEOF
 
-             HALINCL="$ac_hal_cflags"
-fi
 
 fi
 
-    fi
-    CPPFLAGS="$ac_save_CPPFLAGS"
-fi
 
-CURSESLIBS=""
-if test "$ac_cv_header_ncurses_h" = "yes"
-then
-    { echo "$as_me:$LINENO: checking for waddch in -lncurses" >&5
-echo $ECHO_N "checking for waddch in -lncurses... $ECHO_C" >&6; }
-if test "${ac_cv_lib_ncurses_waddch+set}" = set; then
+                               { echo "$as_me:$LINENO: checking for gluLookAt in -lGLU" >&5
+echo $ECHO_N "checking for gluLookAt in -lGLU... $ECHO_C" >&6; }
+if test "${ac_cv_lib_GLU_gluLookAt+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lncurses  $LIBS"
+LIBS="-lGLU $OPENGL_LIBS $X_LIBS $X_PRE_LIBS -lXext -lX11 -lm $X_EXTRA_LIBS
+                $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -9794,11 +9709,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char waddch ();
+char gluLookAt ();
 int
 main ()
 {
-return waddch ();
+return gluLookAt ();
   ;
   return 0;
 }
@@ -9821,63 +9736,67 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_ncurses_waddch=yes
+  ac_cv_lib_GLU_gluLookAt=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_ncurses_waddch=no
+       ac_cv_lib_GLU_gluLookAt=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_waddch" >&5
-echo "${ECHO_T}$ac_cv_lib_ncurses_waddch" >&6; }
-if test $ac_cv_lib_ncurses_waddch = yes; then
-  CURSESLIBS="-lncurses"
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_GLU_gluLookAt" >&5
+echo "${ECHO_T}$ac_cv_lib_GLU_gluLookAt" >&6; }
+if test $ac_cv_lib_GLU_gluLookAt = yes; then
+  OPENGL_LIBS="$OPENGL_LIBS -lGLU"
+                            GLU32FILES='$(GLU32FILES)'
+
 fi
 
-elif test "$ac_cv_header_curses_h" = "yes"
-then
-    { echo "$as_me:$LINENO: checking for waddch in -lcurses" >&5
-echo $ECHO_N "checking for waddch in -lcurses... $ECHO_C" >&6; }
-if test "${ac_cv_lib_curses_waddch+set}" = set; then
+            fi
+         else
+             wine_cv_opengl_headers_found="no"
+        fi
+    fi
+        NASLIBS=""
+
+
+for ac_header in audio/audiolib.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+  { echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+ac_res=`eval echo '${'$as_ac_Header'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lcurses  $LIBS"
+  # Is the header compilable?
+{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
+echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 waddch ();
-int
-main ()
-{
-return waddch ();
-  ;
-  return 0;
-}
+$ac_includes_default
+#include <$ac_header>
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -9886,195 +9805,122 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_curses_waddch=yes
+       } && test -s conftest.$ac_objext; then
+  ac_header_compiler=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_curses_waddch=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_curses_waddch" >&5
-echo "${ECHO_T}$ac_cv_lib_curses_waddch" >&6; }
-if test $ac_cv_lib_curses_waddch = yes; then
-  CURSESLIBS="-lcurses"
+       ac_header_compiler=no
 fi
 
-fi
-ac_save_LIBS="$LIBS"
-LIBS="$LIBS $CURSESLIBS"
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6; }
 
-for ac_func in mousemask
-do
-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_func" >&5
-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
-if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
+# Is the header present?
+{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
+echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define $ac_func innocuous_$ac_func
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $ac_func
-
-/* 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 $ac_func ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_$ac_func || defined __stub___$ac_func
-choke me
-#endif
-
-int
-main ()
-{
-return $ac_func ();
-  ;
-  return 0;
-}
+#include <$ac_header>
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+if { (ac_try="$ac_cpp conftest.$ac_ext"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
   cat conftest.err >&5
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
+  (exit $ac_status); } >/dev/null && {
+        test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  eval "$as_ac_var=yes"
+       }; then
+  ac_header_preproc=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       eval "$as_ac_var=no"
+  ac_header_preproc=no
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
+rm -f conftest.err conftest.$ac_ext
+{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6; }
+
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+  yes:no: )
+    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
+    ac_header_preproc=yes
+    ;;
+  no:yes:* )
+    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
+    ( cat <<\_ASBOX
+## ------------------------------------ ##
+## Report this to wine-devel@winehq.org ##
+## ------------------------------------ ##
+_ASBOX
+     ) | sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+{ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  eval "$as_ac_Header=\$ac_header_preproc"
 fi
-ac_res=`eval echo '${'$as_ac_var'}'`
+ac_res=`eval echo '${'$as_ac_Header'}'`
               { echo "$as_me:$LINENO: result: $ac_res" >&5
 echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_var'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
 
 fi
-done
-
-LIBS="$ac_save_LIBS"
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
 
-# Extract the first word of "sane-config", so it can be a program name with args.
-set dummy sane-config; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_sane_devel+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$sane_devel"; then
-  ac_cv_prog_sane_devel="$sane_devel" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
+for ac_header in audio/soundlib.h
 do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_sane_devel="sane-config"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-  test -z "$ac_cv_prog_sane_devel" && ac_cv_prog_sane_devel="no"
-fi
-fi
-sane_devel=$ac_cv_prog_sane_devel
-if test -n "$sane_devel"; then
-  { echo "$as_me:$LINENO: result: $sane_devel" >&5
-echo "${ECHO_T}$sane_devel" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-SANELIBS=""
-
-SANEINCL=""
-
-if test "$sane_devel" != "no"
-then
-    SANELIBS="`$sane_devel --libs`"
-    SANEINCL="`$sane_devel --cflags`"
-    ac_save_CPPFLAGS="$CPPFLAGS"
-    ac_save_LIBS="$LIBS"
-    CPPFLAGS="$CPPFLAGS $SANEINCL"
-    LIBS="$LIBS $SANELIBS"
-    if test "${ac_cv_header_sane_sane_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for sane/sane.h" >&5
-echo $ECHO_N "checking for sane/sane.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_sane_sane_h+set}" = set; then
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_sane_sane_h" >&5
-echo "${ECHO_T}$ac_cv_header_sane_sane_h" >&6; }
 else
-  # Is the header compilable?
-{ echo "$as_me:$LINENO: checking sane/sane.h usability" >&5
-echo $ECHO_N "checking sane/sane.h usability... $ECHO_C" >&6; }
-cat >conftest.$ac_ext <<_ACEOF
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-$ac_includes_default
-#include <sane/sane.h>
+#include <audio/audiolib.h>
+
+#include <$ac_header>
 _ACEOF
 rm -f conftest.$ac_objext
 if { (ac_try="$ac_compile"
@@ -10093,106 +9939,102 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
        } && test -s conftest.$ac_objext; then
-  ac_header_compiler=yes
+  eval "$as_ac_Header=yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_header_compiler=no
+       eval "$as_ac_Header=no"
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
-echo "${ECHO_T}$ac_header_compiler" >&6; }
+fi
+ac_res=`eval echo '${'$as_ac_Header'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
 
-# Is the header present?
-{ echo "$as_me:$LINENO: checking sane/sane.h presence" >&5
-echo $ECHO_N "checking sane/sane.h presence... $ECHO_C" >&6; }
+fi
+
+done
+
+          { echo "$as_me:$LINENO: checking for AuCreateFlow in -laudio" >&5
+echo $ECHO_N "checking for AuCreateFlow in -laudio... $ECHO_C" >&6; }
+if test "${ac_cv_lib_audio_AuCreateFlow+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-laudio -lXt $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <sane/sane.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 AuCreateFlow ();
+int
+main ()
+{
+return AuCreateFlow ();
+  ;
+  return 0;
+}
 _ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
   cat conftest.err >&5
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-        test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       }; then
-  ac_header_preproc=yes
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_lib_audio_AuCreateFlow=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-  ac_header_preproc=no
+       ac_cv_lib_audio_AuCreateFlow=no
 fi
 
-rm -f conftest.err conftest.$ac_ext
-{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
-echo "${ECHO_T}$ac_header_preproc" >&6; }
-
-# So?  What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
-  yes:no: )
-    { echo "$as_me:$LINENO: WARNING: sane/sane.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: sane/sane.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sane/sane.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: sane/sane.h: proceeding with the compiler's result" >&2;}
-    ac_header_preproc=yes
-    ;;
-  no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: sane/sane.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: sane/sane.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sane/sane.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: sane/sane.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sane/sane.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: sane/sane.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sane/sane.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: sane/sane.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sane/sane.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: sane/sane.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: sane/sane.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: sane/sane.h: in the future, the compiler will take precedence" >&2;}
-    ( cat <<\_ASBOX
-## ------------------------------------ ##
-## Report this to wine-devel@winehq.org ##
-## ------------------------------------ ##
-_ASBOX
-     ) | sed "s/^/$as_me: WARNING:     /" >&2
-    ;;
-esac
-{ echo "$as_me:$LINENO: checking for sane/sane.h" >&5
-echo $ECHO_N "checking for sane/sane.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_sane_sane_h+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_cv_header_sane_sane_h=$ac_header_preproc
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_sane_sane_h" >&5
-echo "${ECHO_T}$ac_cv_header_sane_sane_h" >&6; }
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_audio_AuCreateFlow" >&5
+echo "${ECHO_T}$ac_cv_lib_audio_AuCreateFlow" >&6; }
+if test $ac_cv_lib_audio_AuCreateFlow = yes; then
 
-fi
-if test $ac_cv_header_sane_sane_h = yes; then
-  { echo "$as_me:$LINENO: checking for sane_open in -lsane" >&5
-echo $ECHO_N "checking for sane_open in -lsane... $ECHO_C" >&6; }
-if test "${ac_cv_lib_sane_sane_open+set}" = set; then
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_NAS 1
+_ACEOF
+
+                        { echo "$as_me:$LINENO: checking for XauGetBestAuthByAddr in -lXau" >&5
+echo $ECHO_N "checking for XauGetBestAuthByAddr in -lXau... $ECHO_C" >&6; }
+if test "${ac_cv_lib_Xau_XauGetBestAuthByAddr+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsane  $LIBS"
+LIBS="-lXau $X_LIBS $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -10206,11 +10048,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char sane_open ();
+char XauGetBestAuthByAddr ();
 int
 main ()
 {
-return sane_open ();
+return XauGetBestAuthByAddr ();
   ;
   return 0;
 }
@@ -10233,148 +10075,78 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_sane_sane_open=yes
+  ac_cv_lib_Xau_XauGetBestAuthByAddr=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_sane_sane_open=no
+       ac_cv_lib_Xau_XauGetBestAuthByAddr=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_sane_sane_open" >&5
-echo "${ECHO_T}$ac_cv_lib_sane_sane_open" >&6; }
-if test $ac_cv_lib_sane_sane_open = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_Xau_XauGetBestAuthByAddr" >&5
+echo "${ECHO_T}$ac_cv_lib_Xau_XauGetBestAuthByAddr" >&6; }
+if test $ac_cv_lib_Xau_XauGetBestAuthByAddr = yes; then
+  NASLIBS="-lXau -laudio -lXt $X_LIBS -lXext -lX11 $X_EXTRA_LIBS"
+else
+  NASLIBS="-laudio -lXt $X_LIBS -lXext -lX11 $X_EXTRA_LIBS"
+fi
 
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_SANE 1
-_ACEOF
 
-else
-  SANELIBS=""
-                                  SANEINCL=""
 fi
 
-else
-  SANELIBS=""
-                    SANEINCL=""
 fi
 
+done
+
 
-    LIBS="$ac_save_LIBS"
     CPPFLAGS="$ac_save_CPPFLAGS"
+    XFILES='$(XFILES)'
+else
+    XLIB=""
+    X_CFLAGS=""
+    X_LIBS=""
 fi
 
-# Extract the first word of "gphoto2-config", so it can be a program name with args.
-set dummy gphoto2-config; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_gphoto2_devel+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$gphoto2_devel"; then
-  ac_cv_prog_gphoto2_devel="$gphoto2_devel" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_gphoto2_devel="gphoto2-config"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
 
-  test -z "$ac_cv_prog_gphoto2_devel" && ac_cv_prog_gphoto2_devel="no"
-fi
-fi
-gphoto2_devel=$ac_cv_prog_gphoto2_devel
-if test -n "$gphoto2_devel"; then
-  { echo "$as_me:$LINENO: result: $gphoto2_devel" >&5
-echo "${ECHO_T}$gphoto2_devel" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
+XML2LIBS=""
 
+XML2INCL=""
 
-# Extract the first word of "gphoto2-port-config", so it can be a program name with args.
-set dummy gphoto2-port-config; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_gphoto2port_devel+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$gphoto2port_devel"; then
-  ac_cv_prog_gphoto2port_devel="$gphoto2port_devel" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_gphoto2port_devel="gphoto2-port-config"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
+XSLTLIBS=""
 
-  test -z "$ac_cv_prog_gphoto2port_devel" && ac_cv_prog_gphoto2port_devel="no"
-fi
-fi
-gphoto2port_devel=$ac_cv_prog_gphoto2port_devel
-if test -n "$gphoto2port_devel"; then
-  { echo "$as_me:$LINENO: result: $gphoto2port_devel" >&5
-echo "${ECHO_T}$gphoto2port_devel" >&6; }
+XSLTINCL=""
+
+ac_save_CPPFLAGS="$CPPFLAGS"
+if test "$PKG_CONFIG" != "false"
+then
+    ac_xml_libs="`$PKG_CONFIG --libs libxml-2.0 2>/dev/null`"
+    ac_xml_cflags="`$PKG_CONFIG --cflags libxml-2.0 2>/dev/null`"
 else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+    ac_xml_libs="`xml2-config --libs 2>/dev/null`"
+    ac_xml_cflags="`xml2-config --cflags  2>/dev/null`"
 fi
+CPPFLAGS="$CPPFLAGS $ac_xml_cflags"
 
-
-GPHOTO2LIBS=""
-
-GPHOTO2INCL=""
-
-if test "$gphoto2_devel" != "no" -a "$gphoto2port_devel" != "no"
-then
-    GPHOTO2INCL="`$gphoto2_devel --cflags` `$gphoto2port_devel --cflags`"
-    GPHOTO2LIBS=""
-    for i in `$gphoto2_devel --libs` `$gphoto2port_devel --libs`
-    do
-      case "$i" in
-        -L/usr/lib|-L/usr/lib64) ;;
-        -L*|-l*) GPHOTO2LIBS="$GPHOTO2LIBS $i";;
-      esac
-    done
-    ac_save_CPPFLAGS="$CPPFLAGS"
-    ac_save_LIBS="$LIBS"
-    CPPFLAGS="$CPPFLAGS $GPHOTO2INCL"
-    LIBS="$LIBS $GPHOTO2LIBS"
-    if test "${ac_cv_header_gphoto2_camera_h+set}" = set; then
-  { echo "$as_me:$LINENO: checking for gphoto2-camera.h" >&5
-echo $ECHO_N "checking for gphoto2-camera.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_gphoto2_camera_h+set}" = set; then
+for ac_header in libxml/parser.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+  { echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_gphoto2_camera_h" >&5
-echo "${ECHO_T}$ac_cv_header_gphoto2_camera_h" >&6; }
+ac_res=`eval echo '${'$as_ac_Header'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
 else
   # Is the header compilable?
-{ echo "$as_me:$LINENO: checking gphoto2-camera.h usability" >&5
-echo $ECHO_N "checking gphoto2-camera.h usability... $ECHO_C" >&6; }
+{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
+echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -10382,7 +10154,7 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 $ac_includes_default
-#include <gphoto2-camera.h>
+#include <$ac_header>
 _ACEOF
 rm -f conftest.$ac_objext
 if { (ac_try="$ac_compile"
@@ -10414,15 +10186,15 @@ rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 echo "${ECHO_T}$ac_header_compiler" >&6; }
 
 # Is the header present?
-{ echo "$as_me:$LINENO: checking gphoto2-camera.h presence" >&5
-echo $ECHO_N "checking gphoto2-camera.h presence... $ECHO_C" >&6; }
+{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
+echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <gphoto2-camera.h>
+#include <$ac_header>
 _ACEOF
 if { (ac_try="$ac_cpp conftest.$ac_ext"
 case "(($ac_try" in
@@ -10455,25 +10227,25 @@ echo "${ECHO_T}$ac_header_preproc" >&6; }
 # So?  What about this header?
 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
   yes:no: )
-    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: accepted by the compiler, rejected by the preprocessor!" >&5
-echo "$as_me: WARNING: gphoto2-camera.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
-    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: proceeding with the compiler's result" >&5
-echo "$as_me: WARNING: gphoto2-camera.h: proceeding with the compiler's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
     ac_header_preproc=yes
     ;;
   no:yes:* )
-    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: present but cannot be compiled" >&5
-echo "$as_me: WARNING: gphoto2-camera.h: present but cannot be compiled" >&2;}
-    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h:     check for missing prerequisite headers?" >&5
-echo "$as_me: WARNING: gphoto2-camera.h:     check for missing prerequisite headers?" >&2;}
-    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: see the Autoconf documentation" >&5
-echo "$as_me: WARNING: gphoto2-camera.h: see the Autoconf documentation" >&2;}
-    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h:     section \"Present But Cannot Be Compiled\"" >&5
-echo "$as_me: WARNING: gphoto2-camera.h:     section \"Present But Cannot Be Compiled\"" >&2;}
-    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: proceeding with the preprocessor's result" >&5
-echo "$as_me: WARNING: gphoto2-camera.h: proceeding with the preprocessor's result" >&2;}
-    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: in the future, the compiler will take precedence" >&5
-echo "$as_me: WARNING: gphoto2-camera.h: in the future, the compiler will take precedence" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
     ( cat <<\_ASBOX
 ## ------------------------------------ ##
 ## Report this to wine-devel@winehq.org ##
@@ -10482,25 +10254,29 @@ _ASBOX
      ) | sed "s/^/$as_me: WARNING:     /" >&2
     ;;
 esac
-{ echo "$as_me:$LINENO: checking for gphoto2-camera.h" >&5
-echo $ECHO_N "checking for gphoto2-camera.h... $ECHO_C" >&6; }
-if test "${ac_cv_header_gphoto2_camera_h+set}" = set; then
+{ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_cv_header_gphoto2_camera_h=$ac_header_preproc
+  eval "$as_ac_Header=\$ac_header_preproc"
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_header_gphoto2_camera_h" >&5
-echo "${ECHO_T}$ac_cv_header_gphoto2_camera_h" >&6; }
+ac_res=`eval echo '${'$as_ac_Header'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
 
 fi
-if test $ac_cv_header_gphoto2_camera_h = yes; then
-  { echo "$as_me:$LINENO: checking for gp_camera_new in -lgphoto2" >&5
-echo $ECHO_N "checking for gp_camera_new in -lgphoto2... $ECHO_C" >&6; }
-if test "${ac_cv_lib_gphoto2_gp_camera_new+set}" = set; then
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+ { echo "$as_me:$LINENO: checking for xmlParseMemory in -lxml2" >&5
+echo $ECHO_N "checking for xmlParseMemory in -lxml2... $ECHO_C" >&6; }
+if test "${ac_cv_lib_xml2_xmlParseMemory+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lgphoto2  $LIBS"
+LIBS="-lxml2 $ac_xml_libs $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -10514,11 +10290,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char gp_camera_new ();
+char xmlParseMemory ();
 int
 main ()
 {
-return gp_camera_new ();
+return xmlParseMemory ();
   ;
   return 0;
 }
@@ -10541,62 +10317,55 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_gphoto2_gp_camera_new=yes
+  ac_cv_lib_xml2_xmlParseMemory=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_gphoto2_gp_camera_new=no
+       ac_cv_lib_xml2_xmlParseMemory=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_gphoto2_gp_camera_new" >&5
-echo "${ECHO_T}$ac_cv_lib_gphoto2_gp_camera_new" >&6; }
-if test $ac_cv_lib_gphoto2_gp_camera_new = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlParseMemory" >&5
+echo "${ECHO_T}$ac_cv_lib_xml2_xmlParseMemory" >&6; }
+if test $ac_cv_lib_xml2_xmlParseMemory = yes; then
 
 cat >>confdefs.h <<\_ACEOF
-#define HAVE_GPHOTO2 1
+#define HAVE_LIBXML2 1
 _ACEOF
 
-else
-  GPHOTO2LIBS=""
-                                  GPHOTO2INCL=""
+             XML2LIBS="$ac_xml_libs"
+             XML2INCL="$ac_xml_cflags"
 fi
 
+         { echo "$as_me:$LINENO: checking for xmlReadMemory in -lxml2" >&5
+echo $ECHO_N "checking for xmlReadMemory in -lxml2... $ECHO_C" >&6; }
+if test "${ac_cv_lib_xml2_xmlReadMemory+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  GPHOTO2LIBS=""
-                    GPHOTO2INCL=""
-fi
-
-
-    LIBS="$ac_save_LIBS"
-    CPPFLAGS="$ac_save_CPPFLAGS"
-fi
-
-if test "$ac_cv_header_unicode_ubidi_h" = "yes"
-then
-    saved_libs="$LIBS"
-    for i in ${ICU_LIB_DIR-/usr/lib}/libsicu ${ICU_LIB_DIR-/usr/lib}/libicu
-    do
-        TEST_ICUUC_LIB="${ICUUC_LIB-${i}uc.a}"
-        TEST_ICUDATA_LIB="${ICUDATA_LIB-${i}data.a}"
-        { echo "$as_me:$LINENO: checking whether can link with ICU libraries $TEST_ICUUC_LIB and $TEST_ICUDATA_LIB" >&5
-echo $ECHO_N "checking whether can link with ICU libraries $TEST_ICUUC_LIB and $TEST_ICUDATA_LIB... $ECHO_C" >&6; }
-        LIBS="$saved_libs $TEST_ICUUC_LIB $TEST_ICUDATA_LIB -lstdc++ -lgcc_s"
-       cat >conftest.$ac_ext <<_ACEOF
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lxml2 $ac_xml_libs $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <unicode/ubidi.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 xmlReadMemory ();
 int
 main ()
 {
-ubidi_open()
+return xmlReadMemory ();
   ;
   return 0;
 }
@@ -10619,40 +10388,35 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_ICU 1
-_ACEOF
-
-                    ICULIBS="$TEST_ICUUC_LIB $TEST_ICUDATA_LIB -lstdc++ -lgcc_s"
-
-                     { echo "$as_me:$LINENO: result: yes" >&5
-echo "${ECHO_T}yes" >&6; }
+  ac_cv_lib_xml2_xmlReadMemory=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+       ac_cv_lib_xml2_xmlReadMemory=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-    done
-    LIBS="$saved_libs"
+LIBS=$ac_check_lib_save_LIBS
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlReadMemory" >&5
+echo "${ECHO_T}$ac_cv_lib_xml2_xmlReadMemory" >&6; }
+if test $ac_cv_lib_xml2_xmlReadMemory = yes; then
 
-RESOLVLIBS=""
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_XMLREADMEMORY 1
+_ACEOF
 
-if test "$ac_cv_header_resolv_h" = "yes"
-then
-    { echo "$as_me:$LINENO: checking for res_query in -lresolv" >&5
-echo $ECHO_N "checking for res_query in -lresolv... $ECHO_C" >&6; }
-if test "${ac_cv_lib_resolv_res_query+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
+fi
+
+         { echo "$as_me:$LINENO: checking for xmlNewDocPI in -lxml2" >&5
+echo $ECHO_N "checking for xmlNewDocPI in -lxml2... $ECHO_C" >&6; }
+if test "${ac_cv_lib_xml2_xmlNewDocPI+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lresolv  $LIBS"
+LIBS="-lxml2 $ac_xml_libs $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -10666,11 +10430,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char res_query ();
+char xmlNewDocPI ();
 int
 main ()
 {
-return res_query ();
+return xmlNewDocPI ();
   ;
   return 0;
 }
@@ -10693,72 +10457,73 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_resolv_res_query=yes
+  ac_cv_lib_xml2_xmlNewDocPI=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_resolv_res_query=no
+       ac_cv_lib_xml2_xmlNewDocPI=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_query" >&5
-echo "${ECHO_T}$ac_cv_lib_resolv_res_query" >&6; }
-if test $ac_cv_lib_resolv_res_query = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlNewDocPI" >&5
+echo "${ECHO_T}$ac_cv_lib_xml2_xmlNewDocPI" >&6; }
+if test $ac_cv_lib_xml2_xmlNewDocPI = yes; then
 
 cat >>confdefs.h <<\_ACEOF
-#define HAVE_RESOLV 1
+#define HAVE_XMLNEWDOCPI 1
 _ACEOF
 
-         RESOLVLIBS="-lresolv"
 fi
 
+
 fi
 
-LCMSLIBS=""
+done
 
-if test "$ac_cv_header_lcms_h" = "yes" -o "$ac_cv_header_lcms_lcms_h" = "yes"
+CPPFLAGS="$ac_save_CPPFLAGS"
+if test "$PKG_CONFIG" != "false"
 then
-    { echo "$as_me:$LINENO: checking for cmsOpenProfileFromFile in -llcms" >&5
-echo $ECHO_N "checking for cmsOpenProfileFromFile in -llcms... $ECHO_C" >&6; }
-if test "${ac_cv_lib_lcms_cmsOpenProfileFromFile+set}" = set; then
+    ac_xslt_libs="`$PKG_CONFIG --libs libxslt 2>/dev/null`"
+    ac_xslt_cflags="`$PKG_CONFIG --cflags libxslt 2>/dev/null`"
+else
+    ac_xslt_libs="`xslt-config --libs 2>/dev/null`"
+    ac_xslt_cflags="`xslt-config --cflags 2>/dev/null`"
+fi
+CPPFLAGS="$CPPFLAGS $ac_xslt_cflags"
+
+
+for ac_header in libxslt/pattern.h libxslt/transform.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-llcms  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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"
+#ifdef HAVE_LIBXSLT_PATTERN_H
+# include <libxslt/pattern.h>
 #endif
-char cmsOpenProfileFromFile ();
-int
-main ()
-{
-return cmsOpenProfileFromFile ();
-  ;
-  return 0;
-}
+
+#include <$ac_header>
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -10767,44 +10532,31 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_lcms_cmsOpenProfileFromFile=yes
+       } && test -s conftest.$ac_objext; then
+  eval "$as_ac_Header=yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_lcms_cmsOpenProfileFromFile=no
+       eval "$as_ac_Header=no"
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_lcms_cmsOpenProfileFromFile" >&5
-echo "${ECHO_T}$ac_cv_lib_lcms_cmsOpenProfileFromFile" >&6; }
-if test $ac_cv_lib_lcms_cmsOpenProfileFromFile = yes; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LCMS 1
+ac_res=`eval echo '${'$as_ac_Header'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
 _ACEOF
-
-         LCMSLIBS="-llcms"
-fi
-
-fi
-
-LDAPLIBS=""
-
-if test "$ac_cv_header_ldap_h" = "yes" -a "$ac_cv_header_lber_h" = "yes"
-then
-    { echo "$as_me:$LINENO: checking for ldap_initialize in -lldap_r" >&5
-echo $ECHO_N "checking for ldap_initialize in -lldap_r... $ECHO_C" >&6; }
-if test "${ac_cv_lib_ldap_r_ldap_initialize+set}" = set; then
+ { echo "$as_me:$LINENO: checking for xsltCompilePattern in -lxslt" >&5
+echo $ECHO_N "checking for xsltCompilePattern in -lxslt... $ECHO_C" >&6; }
+if test "${ac_cv_lib_xslt_xsltCompilePattern+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lldap_r $LIBPTHREAD $LIBS"
+LIBS="-lxslt $ac_xslt_libs $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -10818,11 +10570,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char ldap_initialize ();
+char xsltCompilePattern ();
 int
 main ()
 {
-return ldap_initialize ();
+return xsltCompilePattern ();
   ;
   return 0;
 }
@@ -10845,58 +10597,80 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_ldap_r_ldap_initialize=yes
+  ac_cv_lib_xslt_xsltCompilePattern=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_ldap_r_ldap_initialize=no
+       ac_cv_lib_xslt_xsltCompilePattern=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_initialize" >&5
-echo "${ECHO_T}$ac_cv_lib_ldap_r_ldap_initialize" >&6; }
-if test $ac_cv_lib_ldap_r_ldap_initialize = yes; then
-  { echo "$as_me:$LINENO: checking for ber_init in -llber" >&5
-echo $ECHO_N "checking for ber_init in -llber... $ECHO_C" >&6; }
-if test "${ac_cv_lib_lber_ber_init+set}" = set; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltCompilePattern" >&5
+echo "${ECHO_T}$ac_cv_lib_xslt_xsltCompilePattern" >&6; }
+if test $ac_cv_lib_xslt_xsltCompilePattern = yes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_LIBXSLT 1
+_ACEOF
+
+             XSLTLIBS="$ac_xslt_libs"
+             XSLTINCL="$ac_xslt_cflags"
+fi
+
+
+fi
+
+done
+
+CPPFLAGS="$ac_save_CPPFLAGS"
+
+HALINCL=""
+
+if test "$PKG_CONFIG" != "false"
+then
+    ac_save_CPPFLAGS="$CPPFLAGS"
+    ac_hal_libs="`$PKG_CONFIG --libs hal 2>/dev/null`"
+    ac_hal_cflags="`$PKG_CONFIG --cflags hal 2>/dev/null`"
+    CPPFLAGS="$CPPFLAGS $ac_hal_cflags"
+
+
+for ac_header in dbus/dbus.h hal/libhal.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+  { echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+ac_res=`eval echo '${'$as_ac_Header'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-llber $LIBPTHREAD $LIBS"
+  # Is the header compilable?
+{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
+echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 ber_init ();
-int
-main ()
-{
-return ber_init ();
-  ;
-  return 0;
-}
+$ac_includes_default
+#include <$ac_header>
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -10905,73 +10679,124 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_lber_ber_init=yes
+       } && test -s conftest.$ac_objext; then
+  ac_header_compiler=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_lber_ber_init=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_lber_ber_init" >&5
-echo "${ECHO_T}$ac_cv_lib_lber_ber_init" >&6; }
-if test $ac_cv_lib_lber_ber_init = yes; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LDAP 1
-_ACEOF
-
-             LDAPLIBS="-lldap_r -llber"
-fi
-
+       ac_header_compiler=no
 fi
 
-    ac_wine_check_funcs_save_LIBS="$LIBS"
-LIBS="$LIBS $LDAPLIBS $LIBPTHREAD"
-
-
-
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6; }
 
-for ac_func in \
-       ldap_count_references \
-       ldap_first_reference \
-       ldap_next_reference \
-       ldap_parse_reference
-do
-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_func" >&5
-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
-if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
+# Is the header present?
+{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
+echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define $ac_func innocuous_$ac_func
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
+#include <$ac_header>
+_ACEOF
+if { (ac_try="$ac_cpp conftest.$ac_ext"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } >/dev/null && {
+        test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       }; then
+  ac_header_preproc=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
 
-#undef $ac_func
+  ac_header_preproc=no
+fi
+
+rm -f conftest.err conftest.$ac_ext
+{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6; }
+
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+  yes:no: )
+    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
+    ac_header_preproc=yes
+    ;;
+  no:yes:* )
+    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
+echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
+    ( cat <<\_ASBOX
+## ------------------------------------ ##
+## Report this to wine-devel@winehq.org ##
+## ------------------------------------ ##
+_ASBOX
+     ) | sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+{ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  eval "$as_ac_Header=\$ac_header_preproc"
+fi
+ac_res=`eval echo '${'$as_ac_Header'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
+
+fi
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+
+fi
+
+done
+
+    if test "$ac_cv_header_dbus_dbus_h" = "yes" -a "$ac_cv_header_hal_libhal_h" = "yes"
+    then
+        { echo "$as_me:$LINENO: checking for dbus_connection_close in -ldbus-1" >&5
+echo $ECHO_N "checking for dbus_connection_close in -ldbus-1... $ECHO_C" >&6; }
+if test "${ac_cv_lib_dbus_1_dbus_connection_close+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-ldbus-1 $ac_hal_libs $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
 
 /* Override any GCC internal prototype to avoid an error.
    Use char because int might match the return type of a GCC
@@ -10979,18 +10804,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char $ac_func ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_$ac_func || defined __stub___$ac_func
-choke me
-#endif
-
+char dbus_connection_close ();
 int
 main ()
 {
-return $ac_func ();
+return dbus_connection_close ();
   ;
   return 0;
 }
@@ -11013,133 +10831,29 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  eval "$as_ac_var=yes"
+  ac_cv_lib_dbus_1_dbus_connection_close=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       eval "$as_ac_var=no"
+       ac_cv_lib_dbus_1_dbus_connection_close=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
 fi
-ac_res=`eval echo '${'$as_ac_var'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_var'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-LIBS="$ac_wine_check_funcs_save_LIBS"
-fi
-
-FREETYPELIBS=""
-
-FREETYPEINCL=""
-
-# Extract the first word of "freetype-config", so it can be a program name with args.
-set dummy freetype-config; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_ft_devel+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ft_devel"; then
-  ac_cv_prog_ft_devel="$ft_devel" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ft_devel="freetype-config"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-  test -z "$ac_cv_prog_ft_devel" && ac_cv_prog_ft_devel="no"
-fi
-fi
-ft_devel=$ac_cv_prog_ft_devel
-if test -n "$ft_devel"; then
-  { echo "$as_me:$LINENO: result: $ft_devel" >&5
-echo "${ECHO_T}$ft_devel" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-if test "$ft_devel" = "no"
-then
-    # Extract the first word of "freetype2-config", so it can be a program name with args.
-set dummy freetype2-config; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_ft_devel2+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ft_devel2"; then
-  ac_cv_prog_ft_devel2="$ft_devel2" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ft_devel2="freetype2-config"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-  test -z "$ac_cv_prog_ft_devel2" && ac_cv_prog_ft_devel2="no"
-fi
-fi
-ft_devel2=$ac_cv_prog_ft_devel2
-if test -n "$ft_devel2"; then
-  { echo "$as_me:$LINENO: result: $ft_devel2" >&5
-echo "${ECHO_T}$ft_devel2" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-    if test "$ft_devel2" = "freetype2-config"
-    then
-       ft_devel=$ft_devel2
-    fi
-fi
-
-if test "$ft_devel" = "no"
-then
-    wine_cv_msg_freetype=yes
-else
-    FREETYPELIBS=`$ft_devel --libs`
-    FREETYPEINCL=`$ft_devel --cflags`
-    { echo "$as_me:$LINENO: checking for FT_Init_FreeType in -lfreetype" >&5
-echo $ECHO_N "checking for FT_Init_FreeType in -lfreetype... $ECHO_C" >&6; }
-if test "${ac_cv_lib_freetype_FT_Init_FreeType+set}" = set; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_dbus_1_dbus_connection_close" >&5
+echo "${ECHO_T}$ac_cv_lib_dbus_1_dbus_connection_close" >&6; }
+if test $ac_cv_lib_dbus_1_dbus_connection_close = yes; then
+  { echo "$as_me:$LINENO: checking for -lhal" >&5
+echo $ECHO_N "checking for -lhal... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_hal+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lfreetype $FREETYPELIBS $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lhal $ac_hal_libs $LIBS"
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
@@ -11152,11 +10866,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char FT_Init_FreeType ();
+char libhal_ctx_new ();
 int
 main ()
 {
-return FT_Init_FreeType ();
+return libhal_ctx_new ();
   ;
   return 0;
 }
@@ -11179,83 +10893,83 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_freetype_FT_Init_FreeType=yes
+  case "$LIBEXT" in
+    dll) ;;
+    dylib) ac_cv_lib_soname_hal=`otool -L conftest$ac_exeext | grep "libhal\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libhal\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_hal=`$ac_cv_path_LDD conftest$ac_exeext | grep "libhal\\.$LIBEXT" | sed -e "s/^.*\(libhal\.$LIBEXT[^    ]*\).*$/\1/"';2,$d'` ;;
+  esac
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_freetype_FT_Init_FreeType=no
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_freetype_FT_Init_FreeType" >&5
-echo "${ECHO_T}$ac_cv_lib_freetype_FT_Init_FreeType" >&6; }
-if test $ac_cv_lib_freetype_FT_Init_FreeType = yes; then
-  ft_lib=yes
+if test "x$ac_cv_lib_soname_hal" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
 else
-  ft_lib=no
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_hal" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_hal" >&6; }
+
+cat >>confdefs.h <<_ACEOF
+#define SONAME_LIBHAL "$ac_cv_lib_soname_hal"
+_ACEOF
+
+       HALINCL="$ac_hal_cflags"
 fi
 
-    if test "$ft_lib" = "no"
-    then
-       wine_cv_msg_freetype=yes
-       FREETYPELIBS=""
-       FREETYPEINCL=""
-    else
-       ac_save_CPPFLAGS="$CPPFLAGS"
-       CPPFLAGS="$FREETYPEINCL $CPPFLAGS"
-
-
-
-
-
-
-
-
-
+fi
 
+    fi
+    CPPFLAGS="$ac_save_CPPFLAGS"
+fi
 
-for ac_header in ft2build.h \
-                         freetype/freetype.h \
-                         freetype/ftglyph.h \
-                         freetype/tttables.h \
-                         freetype/ftnames.h \
-                         freetype/ftsnames.h \
-                         freetype/ttnameid.h \
-                         freetype/ftoutln.h \
-                         freetype/ftwinfnt.h \
-                         freetype/ftmodapi.h \
-                         freetype/internal/sfnt.h
-do
-as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_header" >&5
-echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
-if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
+CURSESLIBS=""
+if test "$ac_cv_header_ncurses_h" = "yes"
+then
+    { echo "$as_me:$LINENO: checking for -lncurses" >&5
+echo $ECHO_N "checking for -lncurses... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_ncurses+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lncurses  $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#if HAVE_FT2BUILD_H
-                          #include <ft2build.h>
-                          #endif
 
-#include <$ac_header>
+/* 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 waddch ();
+int
+main ()
+{
+return waddch ();
+  ;
+  return 0;
+}
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -11264,101 +10978,78 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  eval "$as_ac_Header=yes"
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  case "$LIBEXT" in
+    dll) ;;
+    dylib) ac_cv_lib_soname_ncurses=`otool -L conftest$ac_exeext | grep "libncurses\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libncurses\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_ncurses=`$ac_cv_path_LDD conftest$ac_exeext | grep "libncurses\\.$LIBEXT" | sed -e "s/^.*\(libncurses\.$LIBEXT[^        ]*\).*$/\1/"';2,$d'` ;;
+  esac
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       eval "$as_ac_Header=no"
-fi
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-ac_res=`eval echo '${'$as_ac_Header'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_Header'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
 
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+  LIBS=$ac_check_soname_save_LIBS
 fi
+if test "x$ac_cv_lib_soname_ncurses" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
 
-done
-
-       cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <ft2build.h>
-                    #include <freetype/fttrigon.h>
-_ACEOF
-if { (ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } >/dev/null && {
-        test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       }; then
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_ncurses" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_ncurses" >&6; }
 
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_FREETYPE_FTTRIGON_H 1
+cat >>confdefs.h <<_ACEOF
+#define SONAME_LIBNCURSES "$ac_cv_lib_soname_ncurses"
 _ACEOF
 
-                    wine_cv_fttrigon=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-  wine_cv_fttrigon=no
+       CURSESLIBS="-lncurses"
 fi
 
-rm -f conftest.err conftest.$ac_ext
-        { echo "$as_me:$LINENO: checking for FT_TrueTypeEngineType" >&5
-echo $ECHO_N "checking for FT_TrueTypeEngineType... $ECHO_C" >&6; }
-if test "${ac_cv_type_FT_TrueTypeEngineType+set}" = set; then
+elif test "$ac_cv_header_curses_h" = "yes"
+then
+    { echo "$as_me:$LINENO: checking for -lcurses" >&5
+echo $ECHO_N "checking for -lcurses... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_curses+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lcurses  $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <freetype/ftmodapi.h>
 
-typedef FT_TrueTypeEngineType ac__type_new_;
+/* 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 waddch ();
 int
 main ()
 {
-if ((ac__type_new_ *) 0)
-  return 0;
-if (sizeof (ac__type_new_))
-  return 0;
+return waddch ();
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -11367,32 +11058,44 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_type_FT_TrueTypeEngineType=yes
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  case "$LIBEXT" in
+    dll) ;;
+    dylib) ac_cv_lib_soname_curses=`otool -L conftest$ac_exeext | grep "libcurses\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libcurses\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_curses=`$ac_cv_path_LDD conftest$ac_exeext | grep "libcurses\\.$LIBEXT" | sed -e "s/^.*\(libcurses\.$LIBEXT[^   ]*\).*$/\1/"';2,$d'` ;;
+  esac
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_type_FT_TrueTypeEngineType=no
+
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_type_FT_TrueTypeEngineType" >&5
-echo "${ECHO_T}$ac_cv_type_FT_TrueTypeEngineType" >&6; }
-if test $ac_cv_type_FT_TrueTypeEngineType = yes; then
+if test "x$ac_cv_lib_soname_curses" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_curses" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_curses" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define HAVE_FT_TRUETYPEENGINETYPE 1
+#define SONAME_LIBCURSES "$ac_cv_lib_soname_curses"
 _ACEOF
 
-
+       CURSESLIBS="-lcurses"
 fi
 
-        ac_save_CFLAGS="$CFLAGS"
-        CFLAGS="$CFLAGS $FREETYPELIBS"
+fi
+ac_save_LIBS="$LIBS"
+LIBS="$LIBS $CURSESLIBS"
 
-for ac_func in FT_Load_Sfnt_Table
+for ac_func in mousemask
 do
 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
 { echo "$as_me:$LINENO: checking for $ac_func" >&5
@@ -11485,49 +11188,71 @@ _ACEOF
 fi
 done
 
-        CFLAGS="$ac_save_CFLAGS"
-       CPPFLAGS="$ac_save_CPPFLAGS"
-               if test "$ac_cv_header_freetype_freetype_h" = "yes" -a "$wine_cv_fttrigon" = "yes"
-       then
+LIBS="$ac_save_LIBS"
 
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_FREETYPE 1
-_ACEOF
+# Extract the first word of "sane-config", so it can be a program name with args.
+set dummy sane-config; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_sane_devel+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test -n "$sane_devel"; then
+  ac_cv_prog_sane_devel="$sane_devel" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_sane_devel="sane-config"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
-           wine_cv_msg_freetype=no
-       else
-           FREETYPELIBS=""
-           FREETYPEINCL=""
-           wine_cv_msg_freetype=yes
-       fi
-    fi
+  test -z "$ac_cv_prog_sane_devel" && ac_cv_prog_sane_devel="no"
 fi
-
-if test "$FONTFORGE" != "false" -a -n "$FREETYPELIBS"
-then
-  FONTSSUBDIRS="fonts"
-
+fi
+sane_devel=$ac_cv_prog_sane_devel
+if test -n "$sane_devel"; then
+  { echo "$as_me:$LINENO: result: $sane_devel" >&5
+echo "${ECHO_T}$sane_devel" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
-{ echo "$as_me:$LINENO: checking for parport header/ppdev.h" >&5
-echo $ECHO_N "checking for parport header/ppdev.h... $ECHO_C" >&6; }
-if test "${ac_cv_c_ppdev+set}" = set; then
+
+if test "$sane_devel" != "no"
+then
+    ac_sane_incl="`$sane_devel --cflags`"
+    ac_save_CPPFLAGS="$CPPFLAGS"
+    CPPFLAGS="$CPPFLAGS $ac_sane_incl"
+    if test "${ac_cv_header_sane_sane_h+set}" = set; then
+  { echo "$as_me:$LINENO: checking for sane/sane.h" >&5
+echo $ECHO_N "checking for sane/sane.h... $ECHO_C" >&6; }
+if test "${ac_cv_header_sane_sane_h+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_header_sane_sane_h" >&5
+echo "${ECHO_T}$ac_cv_header_sane_sane_h" >&6; }
 else
-  cat >conftest.$ac_ext <<_ACEOF
+  # Is the header compilable?
+{ echo "$as_me:$LINENO: checking sane/sane.h usability" >&5
+echo $ECHO_N "checking sane/sane.h usability... $ECHO_C" >&6; }
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <linux/ppdev.h>
-int
-main ()
-{
-ioctl (1,PPCLAIM,0)
-  ;
-  return 0;
-}
+$ac_includes_default
+#include <sane/sane.h>
 _ACEOF
 rm -f conftest.$ac_objext
 if { (ac_try="$ac_compile"
@@ -11546,108 +11271,124 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
        } && test -s conftest.$ac_objext; then
-  ac_cv_c_ppdev="yes"
+  ac_header_compiler=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_c_ppdev="no"
+       ac_header_compiler=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6; }
 
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_ppdev" >&5
-echo "${ECHO_T}$ac_cv_c_ppdev" >&6; }
-if test "$ac_cv_c_ppdev" = "yes"
-then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_PPDEV 1
-_ACEOF
-
-fi
-
-{ echo "$as_me:$LINENO: checking for va_copy" >&5
-echo $ECHO_N "checking for va_copy... $ECHO_C" >&6; }
-if test "${ac_cv_c_va_copy+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
+# Is the header present?
+{ echo "$as_me:$LINENO: checking sane/sane.h presence" >&5
+echo $ECHO_N "checking sane/sane.h presence... $ECHO_C" >&6; }
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <stdarg.h>
-int
-main ()
-{
-va_list ap1, ap2;
-    va_copy(ap1,ap2);
-
-  ;
-  return 0;
-}
+#include <sane/sane.h>
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+if { (ac_try="$ac_cpp conftest.$ac_ext"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
   cat conftest.err >&5
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
+  (exit $ac_status); } >/dev/null && {
+        test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_c_va_copy="yes"
+       }; then
+  ac_header_preproc=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_c_va_copy="no"
+  ac_header_preproc=no
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
+rm -f conftest.err conftest.$ac_ext
+{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6; }
 
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+  yes:no: )
+    { echo "$as_me:$LINENO: WARNING: sane/sane.h: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: sane/sane.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: sane/sane.h: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: sane/sane.h: proceeding with the compiler's result" >&2;}
+    ac_header_preproc=yes
+    ;;
+  no:yes:* )
+    { echo "$as_me:$LINENO: WARNING: sane/sane.h: present but cannot be compiled" >&5
+echo "$as_me: WARNING: sane/sane.h: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: sane/sane.h:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: sane/sane.h:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: sane/sane.h: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: sane/sane.h: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: sane/sane.h:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: sane/sane.h:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: sane/sane.h: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: sane/sane.h: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: sane/sane.h: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: sane/sane.h: in the future, the compiler will take precedence" >&2;}
+    ( cat <<\_ASBOX
+## ------------------------------------ ##
+## Report this to wine-devel@winehq.org ##
+## ------------------------------------ ##
+_ASBOX
+     ) | sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+{ echo "$as_me:$LINENO: checking for sane/sane.h" >&5
+echo $ECHO_N "checking for sane/sane.h... $ECHO_C" >&6; }
+if test "${ac_cv_header_sane_sane_h+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_cv_header_sane_sane_h=$ac_header_preproc
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_va_copy" >&5
-echo "${ECHO_T}$ac_cv_c_va_copy" >&6; }
-if test "$ac_cv_c_va_copy" = "yes"
-then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_VA_COPY 1
-_ACEOF
+{ echo "$as_me:$LINENO: result: $ac_cv_header_sane_sane_h" >&5
+echo "${ECHO_T}$ac_cv_header_sane_sane_h" >&6; }
 
 fi
-{ echo "$as_me:$LINENO: checking for __va_copy" >&5
-echo $ECHO_N "checking for __va_copy... $ECHO_C" >&6; }
-if test "${ac_cv_c___va_copy+set}" = set; then
+if test $ac_cv_header_sane_sane_h = yes; then
+  { echo "$as_me:$LINENO: checking for -lsane" >&5
+echo $ECHO_N "checking for -lsane... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_sane+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lsane  $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <stdarg.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 sane_init ();
 int
 main ()
 {
-va_list ap1, ap2;
-    __va_copy(ap1,ap2);
-
+return sane_init ();
   ;
   return 0;
 }
@@ -11670,117 +11411,159 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_c___va_copy="yes"
+  case "$LIBEXT" in
+    dll) ;;
+    dylib) ac_cv_lib_soname_sane=`otool -L conftest$ac_exeext | grep "libsane\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libsane\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_sane=`$ac_cv_path_LDD conftest$ac_exeext | grep "libsane\\.$LIBEXT" | sed -e "s/^.*\(libsane\.$LIBEXT[^         ]*\).*$/\1/"';2,$d'` ;;
+  esac
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_c___va_copy="no"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c___va_copy" >&5
-echo "${ECHO_T}$ac_cv_c___va_copy" >&6; }
-if test "$ac_cv_c___va_copy" = "yes"
-then
+if test "x$ac_cv_lib_soname_sane" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
 
-cat >>confdefs.h <<\_ACEOF
-#define HAVE___VA_COPY 1
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_sane" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_sane" >&6; }
+
+cat >>confdefs.h <<_ACEOF
+#define SONAME_LIBSANE "$ac_cv_lib_soname_sane"
 _ACEOF
 
-fi
+       SANEINCL="$ac_sane_incl"
 
-{ echo "$as_me:$LINENO: checking for sigsetjmp" >&5
-echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6; }
-if test "${ac_cv_c_sigsetjmp+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <setjmp.h>
-int
-main ()
-{
-sigjmp_buf buf;
-    sigsetjmp( buf, 1 );
-    siglongjmp( buf, 1 );
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_c_sigsetjmp="yes"
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+fi
 
-       ac_cv_c_sigsetjmp="no"
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
 
+    CPPFLAGS="$ac_save_CPPFLAGS"
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_sigsetjmp" >&5
-echo "${ECHO_T}$ac_cv_c_sigsetjmp" >&6; }
-if test "$ac_cv_c_sigsetjmp" = "yes"
-then
 
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_SIGSETJMP 1
-_ACEOF
+# Extract the first word of "gphoto2-config", so it can be a program name with args.
+set dummy gphoto2-config; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_gphoto2_devel+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test -n "$gphoto2_devel"; then
+  ac_cv_prog_gphoto2_devel="$gphoto2_devel" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_gphoto2_devel="gphoto2-config"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
 
+  test -z "$ac_cv_prog_gphoto2_devel" && ac_cv_prog_gphoto2_devel="no"
+fi
+fi
+gphoto2_devel=$ac_cv_prog_gphoto2_devel
+if test -n "$gphoto2_devel"; then
+  { echo "$as_me:$LINENO: result: $gphoto2_devel" >&5
+echo "${ECHO_T}$gphoto2_devel" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 fi
 
-{ echo "$as_me:$LINENO: checking for pthread_rwlock_t" >&5
-echo $ECHO_N "checking for pthread_rwlock_t... $ECHO_C" >&6; }
-if test "${ac_cv_type_pthread_rwlock_t+set}" = set; then
+
+# Extract the first word of "gphoto2-port-config", so it can be a program name with args.
+set dummy gphoto2-port-config; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_gphoto2port_devel+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#define _GNU_SOURCE
-#include <pthread.h>
-
-typedef pthread_rwlock_t ac__type_new_;
-int
-main ()
-{
-if ((ac__type_new_ *) 0)
-  return 0;
-if (sizeof (ac__type_new_))
-  return 0;
-  ;
-  return 0;
-}
+  if test -n "$gphoto2port_devel"; then
+  ac_cv_prog_gphoto2port_devel="$gphoto2port_devel" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_gphoto2port_devel="gphoto2-port-config"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
+
+  test -z "$ac_cv_prog_gphoto2port_devel" && ac_cv_prog_gphoto2port_devel="no"
+fi
+fi
+gphoto2port_devel=$ac_cv_prog_gphoto2port_devel
+if test -n "$gphoto2port_devel"; then
+  { echo "$as_me:$LINENO: result: $gphoto2port_devel" >&5
+echo "${ECHO_T}$gphoto2port_devel" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+
+
+GPHOTO2LIBS=""
+
+GPHOTO2INCL=""
+
+if test "$gphoto2_devel" != "no" -a "$gphoto2port_devel" != "no"
+then
+    GPHOTO2INCL="`$gphoto2_devel --cflags` `$gphoto2port_devel --cflags`"
+    GPHOTO2LIBS=""
+    for i in `$gphoto2_devel --libs` `$gphoto2port_devel --libs`
+    do
+      case "$i" in
+        -L/usr/lib|-L/usr/lib64) ;;
+        -L*|-l*) GPHOTO2LIBS="$GPHOTO2LIBS $i";;
+      esac
+    done
+    ac_save_CPPFLAGS="$CPPFLAGS"
+    ac_save_LIBS="$LIBS"
+    CPPFLAGS="$CPPFLAGS $GPHOTO2INCL"
+    LIBS="$LIBS $GPHOTO2LIBS"
+    if test "${ac_cv_header_gphoto2_camera_h+set}" = set; then
+  { echo "$as_me:$LINENO: checking for gphoto2-camera.h" >&5
+echo $ECHO_N "checking for gphoto2-camera.h... $ECHO_C" >&6; }
+if test "${ac_cv_header_gphoto2_camera_h+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_header_gphoto2_camera_h" >&5
+echo "${ECHO_T}$ac_cv_header_gphoto2_camera_h" >&6; }
+else
+  # Is the header compilable?
+{ echo "$as_me:$LINENO: checking gphoto2-camera.h usability" >&5
+echo $ECHO_N "checking gphoto2-camera.h usability... $ECHO_C" >&6; }
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+$ac_includes_default
+#include <gphoto2-camera.h>
 _ACEOF
 rm -f conftest.$ac_objext
 if { (ac_try="$ac_compile"
@@ -11799,131 +11582,112 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
        } && test -s conftest.$ac_objext; then
-  ac_cv_type_pthread_rwlock_t=yes
+  ac_header_compiler=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_type_pthread_rwlock_t=no
+       ac_header_compiler=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_type_pthread_rwlock_t" >&5
-echo "${ECHO_T}$ac_cv_type_pthread_rwlock_t" >&6; }
-if test $ac_cv_type_pthread_rwlock_t = yes; then
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_PTHREAD_RWLOCK_T 1
-_ACEOF
-
+{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
+echo "${ECHO_T}$ac_header_compiler" >&6; }
 
-fi
-{ echo "$as_me:$LINENO: checking for pthread_rwlockattr_t" >&5
-echo $ECHO_N "checking for pthread_rwlockattr_t... $ECHO_C" >&6; }
-if test "${ac_cv_type_pthread_rwlockattr_t+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
+# Is the header present?
+{ echo "$as_me:$LINENO: checking gphoto2-camera.h presence" >&5
+echo $ECHO_N "checking gphoto2-camera.h presence... $ECHO_C" >&6; }
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#define _GNU_SOURCE
-#include <pthread.h>
-
-typedef pthread_rwlockattr_t ac__type_new_;
-int
-main ()
-{
-if ((ac__type_new_ *) 0)
-  return 0;
-if (sizeof (ac__type_new_))
-  return 0;
-  ;
-  return 0;
-}
+#include <gphoto2-camera.h>
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+if { (ac_try="$ac_cpp conftest.$ac_ext"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
   cat conftest.err >&5
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
+  (exit $ac_status); } >/dev/null && {
+        test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_type_pthread_rwlockattr_t=yes
+       }; then
+  ac_header_preproc=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_type_pthread_rwlockattr_t=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+  ac_header_preproc=no
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_type_pthread_rwlockattr_t" >&5
-echo "${ECHO_T}$ac_cv_type_pthread_rwlockattr_t" >&6; }
-if test $ac_cv_type_pthread_rwlockattr_t = yes; then
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_PTHREAD_RWLOCKATTR_T 1
-_ACEOF
 
+rm -f conftest.err conftest.$ac_ext
+{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
+echo "${ECHO_T}$ac_header_preproc" >&6; }
 
+# So?  What about this header?
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
+  yes:no: )
+    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: accepted by the compiler, rejected by the preprocessor!" >&5
+echo "$as_me: WARNING: gphoto2-camera.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
+    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: proceeding with the compiler's result" >&5
+echo "$as_me: WARNING: gphoto2-camera.h: proceeding with the compiler's result" >&2;}
+    ac_header_preproc=yes
+    ;;
+  no:yes:* )
+    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: present but cannot be compiled" >&5
+echo "$as_me: WARNING: gphoto2-camera.h: present but cannot be compiled" >&2;}
+    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h:     check for missing prerequisite headers?" >&5
+echo "$as_me: WARNING: gphoto2-camera.h:     check for missing prerequisite headers?" >&2;}
+    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: see the Autoconf documentation" >&5
+echo "$as_me: WARNING: gphoto2-camera.h: see the Autoconf documentation" >&2;}
+    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h:     section \"Present But Cannot Be Compiled\"" >&5
+echo "$as_me: WARNING: gphoto2-camera.h:     section \"Present But Cannot Be Compiled\"" >&2;}
+    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: proceeding with the preprocessor's result" >&5
+echo "$as_me: WARNING: gphoto2-camera.h: proceeding with the preprocessor's result" >&2;}
+    { echo "$as_me:$LINENO: WARNING: gphoto2-camera.h: in the future, the compiler will take precedence" >&5
+echo "$as_me: WARNING: gphoto2-camera.h: in the future, the compiler will take precedence" >&2;}
+    ( cat <<\_ASBOX
+## ------------------------------------ ##
+## Report this to wine-devel@winehq.org ##
+## ------------------------------------ ##
+_ASBOX
+     ) | sed "s/^/$as_me: WARNING:     /" >&2
+    ;;
+esac
+{ echo "$as_me:$LINENO: checking for gphoto2-camera.h" >&5
+echo $ECHO_N "checking for gphoto2-camera.h... $ECHO_C" >&6; }
+if test "${ac_cv_header_gphoto2_camera_h+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_cv_header_gphoto2_camera_h=$ac_header_preproc
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_header_gphoto2_camera_h" >&5
+echo "${ECHO_T}$ac_cv_header_gphoto2_camera_h" >&6; }
 
-
-ac_wine_check_funcs_save_LIBS="$LIBS"
-LIBS="$LIBS $LIBPTHREAD"
-
-
-
-
-for ac_func in \
-        pthread_attr_get_np \
-        pthread_getattr_np \
-        pthread_get_stackaddr_np \
-        pthread_get_stacksize_np
-do
-as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking for $ac_func" >&5
-echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
-if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
+fi
+if test $ac_cv_header_gphoto2_camera_h = yes; then
+  { echo "$as_me:$LINENO: checking for gp_camera_new in -lgphoto2" >&5
+echo $ECHO_N "checking for gp_camera_new in -lgphoto2... $ECHO_C" >&6; }
+if test "${ac_cv_lib_gphoto2_gp_camera_new+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  cat >conftest.$ac_ext <<_ACEOF
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lgphoto2  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
-   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
-#define $ac_func innocuous_$ac_func
-
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char $ac_func (); below.
-    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
-    <limits.h> exists even on freestanding compilers.  */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $ac_func
 
 /* Override any GCC internal prototype to avoid an error.
    Use char because int might match the return type of a GCC
@@ -11931,18 +11695,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char $ac_func ();
-/* The GNU C library defines this for functions which it implements
-    to always fail with ENOSYS.  Some functions are actually named
-    something starting with __ and the normal name is an alias.  */
-#if defined __stub_$ac_func || defined __stub___$ac_func
-choke me
-#endif
-
+char gp_camera_new ();
 int
 main ()
 {
-return $ac_func ();
+return gp_camera_new ();
   ;
   return 0;
 }
@@ -11965,174 +11722,157 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  eval "$as_ac_var=yes"
+  ac_cv_lib_gphoto2_gp_camera_new=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       eval "$as_ac_var=no"
+       ac_cv_lib_gphoto2_gp_camera_new=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
 fi
-ac_res=`eval echo '${'$as_ac_var'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_var'}'` = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_gphoto2_gp_camera_new" >&5
+echo "${ECHO_T}$ac_cv_lib_gphoto2_gp_camera_new" >&6; }
+if test $ac_cv_lib_gphoto2_gp_camera_new = yes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_GPHOTO2 1
 _ACEOF
 
+else
+  GPHOTO2LIBS=""
+                                  GPHOTO2INCL=""
 fi
-done
-
-LIBS="$ac_wine_check_funcs_save_LIBS"
 
-# Extract the first word of "artsc-config", so it can be a program name with args.
-set dummy artsc-config; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_path_ARTSCCONFIG+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  case $ARTSCCONFIG in
-  [\\/]* | ?:[\\/]*)
-  ac_cv_path_ARTSCCONFIG="$ARTSCCONFIG" # Let the user override the test with a path.
-  ;;
-  *)
-  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_path_ARTSCCONFIG="$as_dir/$ac_word$ac_exec_ext"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-  ;;
-esac
-fi
-ARTSCCONFIG=$ac_cv_path_ARTSCCONFIG
-if test -n "$ARTSCCONFIG"; then
-  { echo "$as_me:$LINENO: result: $ARTSCCONFIG" >&5
-echo "${ECHO_T}$ARTSCCONFIG" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+  GPHOTO2LIBS=""
+                    GPHOTO2INCL=""
 fi
 
 
-if test x$ARTSCCONFIG != x -a x$ARTSCCONFIG != x'"$ARTSCCONFIG"';
+    LIBS="$ac_save_LIBS"
+    CPPFLAGS="$ac_save_CPPFLAGS"
+fi
+
+if test "$ac_cv_header_unicode_ubidi_h" = "yes"
 then
-    ARTSC_CFLAGS=""
-    for i in `$ARTSCCONFIG --cflags`
-    do
-      case "$i" in
-        -I*) ARTSC_CFLAGS="$ARTSC_CFLAGS $i";;
-      esac
-    done
-    ARTSC_LIBS=""
-    for i in `$ARTSCCONFIG --libs`
-    do
-      case "$i" in
-        -L/usr/lib|-L/usr/lib64) ;;
-        -L*|-l*) ARTSC_LIBS="$ARTSC_LIBS $i";;
-      esac
-    done
-    save_CFLAGS="$CFLAGS"
-    CFLAGS="$CFLAGS $ARTSC_CFLAGS"
-    { echo "$as_me:$LINENO: checking for arts_init in -lartsc" >&5
-echo $ECHO_N "checking for arts_init in -lartsc... $ECHO_C" >&6; }
-if test "${ac_cv_lib_artsc_arts_init+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
+    saved_libs="$LIBS"
+    icu_libs="-lsicuuc -lsicudata -lstdc++ -lgcc_s"
+    if test -n "$ICU_LIB_DIR"
+    then
+        icu_libs="-L$ICU_LIB_DIR $icu_libs"
+    fi
+    { echo "$as_me:$LINENO: checking whether can link with ICU libraries" >&5
+echo $ECHO_N "checking whether can link with ICU libraries... $ECHO_C" >&6; }
+    LIBS="$saved_libs $icu_libs"
+    if test "$cross_compiling" = yes; then
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lartsc $ARTSC_LIBS $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 arts_init ();
+#include <unicode/ubidi.h>
 int
 main ()
 {
-return arts_init ();
+ubidi_open()
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
+rm -f conftest$ac_exeext
 if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_link") 2>&5
   ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_artsc_arts_init=yes
+  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+  { (case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_try") 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_ICU 1
+_ACEOF
+
+                 ICULIBS="$icu_libs"
+
+                 { echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6; }
 else
-  echo "$as_me: failed program was:" >&5
+  echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_artsc_arts_init=no
+( exit $ac_status )
+{ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+
+    LIBS="$saved_libs"
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_artsc_arts_init" >&5
-echo "${ECHO_T}$ac_cv_lib_artsc_arts_init" >&6; }
-if test $ac_cv_lib_artsc_arts_init = yes; then
-  cat >conftest.$ac_ext <<_ACEOF
+
+RESOLVLIBS=""
+
+if test "$ac_cv_header_resolv_h" = "yes"
+then
+    { echo "$as_me:$LINENO: checking for res_query in -lresolv" >&5
+echo $ECHO_N "checking for res_query in -lresolv... $ECHO_C" >&6; }
+if test "${ac_cv_lib_resolv_res_query+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lresolv  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <artsc.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 res_query ();
 int
 main ()
 {
-arts_stream_t stream;
+return res_query ();
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -12141,88 +11881,44 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ARTSLIBS=$ARTSC_LIBS
-
-            ARTSINCL=$ARTSC_CFLAGS
-
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_ARTS 1
-_ACEOF
-
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_lib_resolv_res_query=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+       ac_cv_lib_resolv_res_query=no
 fi
 
-    CFLAGS="$save_CFLAGS"
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_query" >&5
+echo "${ECHO_T}$ac_cv_lib_resolv_res_query" >&6; }
+if test $ac_cv_lib_resolv_res_query = yes; then
 
-# Extract the first word of "esd-config", so it can be a program name with args.
-set dummy esd-config; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_path_ESDCONFIG+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  case $ESDCONFIG in
-  [\\/]* | ?:[\\/]*)
-  ac_cv_path_ESDCONFIG="$ESDCONFIG" # Let the user override the test with a path.
-  ;;
-  *)
-  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_path_ESDCONFIG="$as_dir/$ac_word$ac_exec_ext"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_RESOLV 1
+_ACEOF
 
-  ;;
-esac
+         RESOLVLIBS="-lresolv"
 fi
-ESDCONFIG=$ac_cv_path_ESDCONFIG
-if test -n "$ESDCONFIG"; then
-  { echo "$as_me:$LINENO: result: $ESDCONFIG" >&5
-echo "${ECHO_T}$ESDCONFIG" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+
 fi
 
+LCMSLIBS=""
 
-if test x$ESDCONFIG != x -a x$ESDCONFIG != x'"$ESDCONFIG"';
+if test "$ac_cv_header_lcms_h" = "yes" -o "$ac_cv_header_lcms_lcms_h" = "yes"
 then
-    ESD_CFLAGS=""
-    for i in `$ESDCONFIG --cflags`
-    do
-      case "$i" in
-        -I*) ESD_CFLAGS="$ESD_CFLAGS $i";;
-      esac
-    done
-    ESD_LIBS=`$ESDCONFIG --libs`
-    save_CFLAGS="$CFLAGS"
-    CFLAGS="$CFLAGS $ESD_CFLAGS"
-    { echo "$as_me:$LINENO: checking for esd_open_sound in -lesd" >&5
-echo $ECHO_N "checking for esd_open_sound in -lesd... $ECHO_C" >&6; }
-if test "${ac_cv_lib_esd_esd_open_sound+set}" = set; then
+    { echo "$as_me:$LINENO: checking for cmsOpenProfileFromFile in -llcms" >&5
+echo $ECHO_N "checking for cmsOpenProfileFromFile in -llcms... $ECHO_C" >&6; }
+if test "${ac_cv_lib_lcms_cmsOpenProfileFromFile+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lesd  $LIBS"
+LIBS="-llcms  $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -12236,11 +11932,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char esd_open_sound ();
+char cmsOpenProfileFromFile ();
 int
 main ()
 {
-return esd_open_sound ();
+return cmsOpenProfileFromFile ();
   ;
   return 0;
 }
@@ -12263,46 +11959,42 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_esd_esd_open_sound=yes
+  ac_cv_lib_lcms_cmsOpenProfileFromFile=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_esd_esd_open_sound=no
+       ac_cv_lib_lcms_cmsOpenProfileFromFile=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_esd_esd_open_sound" >&5
-echo "${ECHO_T}$ac_cv_lib_esd_esd_open_sound" >&6; }
-if test $ac_cv_lib_esd_esd_open_sound = yes; then
-  ESDLIBS=$ESD_LIBS
-
-         ESDINCL=$ESD_CFLAGS
-
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_lcms_cmsOpenProfileFromFile" >&5
+echo "${ECHO_T}$ac_cv_lib_lcms_cmsOpenProfileFromFile" >&6; }
+if test $ac_cv_lib_lcms_cmsOpenProfileFromFile = yes; then
 
 cat >>confdefs.h <<\_ACEOF
-#define HAVE_ESD 1
+#define HAVE_LCMS 1
 _ACEOF
 
+         LCMSLIBS="-llcms"
 fi
 
-    CFLAGS="$save_CFLAGS"
 fi
 
-ALSALIBS=""
+LDAPLIBS=""
 
-if test "$ac_cv_header_sys_asoundlib_h" = "yes" -o "$ac_cv_header_alsa_asoundlib_h" = "yes"
+if test "$ac_cv_header_ldap_h" = "yes" -a "$ac_cv_header_lber_h" = "yes"
 then
-    { echo "$as_me:$LINENO: checking for snd_pcm_hw_params_get_access in -lasound" >&5
-echo $ECHO_N "checking for snd_pcm_hw_params_get_access in -lasound... $ECHO_C" >&6; }
-if test "${ac_cv_lib_asound_snd_pcm_hw_params_get_access+set}" = set; then
+    { echo "$as_me:$LINENO: checking for ldap_initialize in -lldap_r" >&5
+echo $ECHO_N "checking for ldap_initialize in -lldap_r... $ECHO_C" >&6; }
+if test "${ac_cv_lib_ldap_r_ldap_initialize+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lasound  $LIBS"
+LIBS="-lldap_r $LIBPTHREAD $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -12316,11 +12008,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char snd_pcm_hw_params_get_access ();
+char ldap_initialize ();
 int
 main ()
 {
-return snd_pcm_hw_params_get_access ();
+return ldap_initialize ();
   ;
   return 0;
 }
@@ -12343,48 +12035,58 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_asound_snd_pcm_hw_params_get_access=yes
+  ac_cv_lib_ldap_r_ldap_initialize=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_asound_snd_pcm_hw_params_get_access=no
+       ac_cv_lib_ldap_r_ldap_initialize=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_asound_snd_pcm_hw_params_get_access" >&5
-echo "${ECHO_T}$ac_cv_lib_asound_snd_pcm_hw_params_get_access" >&6; }
-if test $ac_cv_lib_asound_snd_pcm_hw_params_get_access = yes; then
-  cat >conftest.$ac_ext <<_ACEOF
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_initialize" >&5
+echo "${ECHO_T}$ac_cv_lib_ldap_r_ldap_initialize" >&6; }
+if test $ac_cv_lib_ldap_r_ldap_initialize = yes; then
+  { echo "$as_me:$LINENO: checking for ber_init in -llber" >&5
+echo $ECHO_N "checking for ber_init in -llber... $ECHO_C" >&6; }
+if test "${ac_cv_lib_lber_ber_init+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-llber $LIBPTHREAD $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#ifdef HAVE_ALSA_ASOUNDLIB_H
-#include <alsa/asoundlib.h>
-#elif defined(HAVE_SYS_ASOUNDLIB_H)
-#include <sys/asoundlib.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 ber_init ();
 int
 main ()
 {
-int ret = snd_pcm_hw_params_get_access(NULL, NULL)
+return ber_init ();
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -12393,43 +12095,73 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_ALSA 1
-_ACEOF
-
-                         ALSALIBS="-lasound"
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_lib_lber_ber_init=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
+       ac_cv_lib_lber_ber_init=no
+fi
 
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_lber_ber_init" >&5
+echo "${ECHO_T}$ac_cv_lib_lber_ber_init" >&6; }
+if test $ac_cv_lib_lber_ber_init = yes; then
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_LDAP 1
+_ACEOF
+
+             LDAPLIBS="-lldap_r -llber"
 fi
 
 fi
 
+    ac_wine_check_funcs_save_LIBS="$LIBS"
+LIBS="$LIBS $LDAPLIBS $LIBPTHREAD"
+
 
-AUDIOIOLIBS=""
 
-if test "$ac_cv_header_libaudioio_h" = "yes"
-then
-    { echo "$as_me:$LINENO: checking for AudioIOGetVersion in -laudioio" >&5
-echo $ECHO_N "checking for AudioIOGetVersion in -laudioio... $ECHO_C" >&6; }
-if test "${ac_cv_lib_audioio_AudioIOGetVersion+set}" = set; then
+
+for ac_func in \
+       ldap_count_references \
+       ldap_first_reference \
+       ldap_next_reference \
+       ldap_parse_reference
+do
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
+if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-laudioio  $LIBS"
-cat >conftest.$ac_ext <<_ACEOF
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
+/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
+   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
+#define $ac_func innocuous_$ac_func
+
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char $ac_func (); below.
+    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+    <limits.h> exists even on freestanding compilers.  */
+
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+
+#undef $ac_func
 
 /* Override any GCC internal prototype to avoid an error.
    Use char because int might match the return type of a GCC
@@ -12437,11 +12169,18 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char AudioIOGetVersion ();
+char $ac_func ();
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined __stub_$ac_func || defined __stub___$ac_func
+choke me
+#endif
+
 int
 main ()
 {
-return AudioIOGetVersion ();
+return $ac_func ();
   ;
   return 0;
 }
@@ -12464,41 +12203,132 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_audioio_AudioIOGetVersion=yes
+  eval "$as_ac_var=yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_audioio_AudioIOGetVersion=no
+       eval "$as_ac_var=no"
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_audioio_AudioIOGetVersion" >&5
-echo "${ECHO_T}$ac_cv_lib_audioio_AudioIOGetVersion" >&6; }
-if test $ac_cv_lib_audioio_AudioIOGetVersion = yes; then
-  AUDIOIOLIBS="-laudioio"
-
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_LIBAUDIOIO 1
+ac_res=`eval echo '${'$as_ac_var'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
 _ACEOF
 
 fi
+done
 
+LIBS="$ac_wine_check_funcs_save_LIBS"
 fi
 
+FREETYPELIBS=""
 
-if test "$ac_cv_header_capi20_h" = "yes" -a "$ac_cv_header_linux_capi_h" = "yes"
+FREETYPEINCL=""
+
+# Extract the first word of "freetype-config", so it can be a program name with args.
+set dummy freetype-config; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_ft_devel+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test -n "$ft_devel"; then
+  ac_cv_prog_ft_devel="$ft_devel" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_ft_devel="freetype-config"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
+
+  test -z "$ac_cv_prog_ft_devel" && ac_cv_prog_ft_devel="no"
+fi
+fi
+ft_devel=$ac_cv_prog_ft_devel
+if test -n "$ft_devel"; then
+  { echo "$as_me:$LINENO: result: $ft_devel" >&5
+echo "${ECHO_T}$ft_devel" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+
+
+if test "$ft_devel" = "no"
+then
+    # Extract the first word of "freetype2-config", so it can be a program name with args.
+set dummy freetype2-config; ac_word=$2
+{ echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
+if test "${ac_cv_prog_ft_devel2+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test -n "$ft_devel2"; then
+  ac_cv_prog_ft_devel2="$ft_devel2" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+  IFS=$as_save_IFS
+  test -z "$as_dir" && as_dir=.
+  for ac_exec_ext in '' $ac_executable_extensions; do
+  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
+    ac_cv_prog_ft_devel2="freetype2-config"
+    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+    break 2
+  fi
+done
+done
+IFS=$as_save_IFS
+
+  test -z "$ac_cv_prog_ft_devel2" && ac_cv_prog_ft_devel2="no"
+fi
+fi
+ft_devel2=$ac_cv_prog_ft_devel2
+if test -n "$ft_devel2"; then
+  { echo "$as_me:$LINENO: result: $ft_devel2" >&5
+echo "${ECHO_T}$ft_devel2" >&6; }
+else
+  { echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6; }
+fi
+
+
+    if test "$ft_devel2" = "freetype2-config"
+    then
+       ft_devel=$ft_devel2
+    fi
+fi
+
+if test "$ft_devel" = "no"
 then
-    { echo "$as_me:$LINENO: checking for capi20_register in -lcapi20" >&5
-echo $ECHO_N "checking for capi20_register in -lcapi20... $ECHO_C" >&6; }
-if test "${ac_cv_lib_capi20_capi20_register+set}" = set; then
+    wine_cv_msg_freetype=yes
+else
+    FREETYPELIBS=`$ft_devel --libs`
+    FREETYPEINCL=`$ft_devel --cflags`
+    { echo "$as_me:$LINENO: checking for FT_Init_FreeType in -lfreetype" >&5
+echo $ECHO_N "checking for FT_Init_FreeType in -lfreetype... $ECHO_C" >&6; }
+if test "${ac_cv_lib_freetype_FT_Init_FreeType+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_check_lib_save_LIBS=$LIBS
-LIBS="-lcapi20  $LIBS"
+LIBS="-lfreetype $FREETYPELIBS $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -12512,11 +12342,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char capi20_register ();
+char FT_Init_FreeType ();
 int
 main ()
 {
-return capi20_register ();
+return FT_Init_FreeType ();
   ;
   return 0;
 }
@@ -12539,44 +12369,62 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_capi20_capi20_register=yes
+  ac_cv_lib_freetype_FT_Init_FreeType=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_capi20_capi20_register=no
+       ac_cv_lib_freetype_FT_Init_FreeType=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_capi20_capi20_register" >&5
-echo "${ECHO_T}$ac_cv_lib_capi20_capi20_register" >&6; }
-if test $ac_cv_lib_capi20_capi20_register = yes; then
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_freetype_FT_Init_FreeType" >&5
+echo "${ECHO_T}$ac_cv_lib_freetype_FT_Init_FreeType" >&6; }
+if test $ac_cv_lib_freetype_FT_Init_FreeType = yes; then
+  ft_lib=yes
+else
+  ft_lib=no
+fi
 
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_CAPI4LINUX 1
-_ACEOF
+    if test "$ft_lib" = "no"
+    then
+       wine_cv_msg_freetype=yes
+       FREETYPELIBS=""
+       FREETYPEINCL=""
+    else
+       ac_save_CPPFLAGS="$CPPFLAGS"
+       CPPFLAGS="$FREETYPEINCL $CPPFLAGS"
 
-fi
 
-fi
 
 
-EXTRACFLAGS=""
 
-if test "x${GCC}" = "xyes"
-then
-  EXTRACFLAGS="-Wall -pipe"
 
-    { echo "$as_me:$LINENO: checking for gcc strength-reduce bug" >&5
-echo $ECHO_N "checking for gcc strength-reduce bug... $ECHO_C" >&6; }
-if test "${ac_cv_c_gcc_strength_bug+set}" = set; then
+
+
+
+
+
+for ac_header in ft2build.h \
+                         freetype/freetype.h \
+                         freetype/ftglyph.h \
+                         freetype/tttables.h \
+                         freetype/ftnames.h \
+                         freetype/ftsnames.h \
+                         freetype/ttnameid.h \
+                         freetype/ftoutln.h \
+                         freetype/ftwinfnt.h \
+                         freetype/ftmodapi.h \
+                         freetype/internal/sfnt.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
+if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test "$cross_compiling" = yes; then
-  ac_cv_c_gcc_strength_bug="yes"
 else
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
@@ -12584,153 +12432,123 @@ _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
+#if HAVE_FT2BUILD_H
+                          #include <ft2build.h>
+                          #endif
 
-int    L[4] = {0,1,2,3};
-int main(void) {
-  static int Array[3];
-  unsigned int B = 3;
-  int i;
-  for(i=0; i<B; i++) Array[i] = i - 3;
-  for(i=0; i<4 - 1; i++) L[i] = L[i + 1];
-  L[i] = 4;
-
-  exit( Array[1] != -2 || L[2] != 3);
-}
+#include <$ac_header>
 _ACEOF
-rm -f conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>&5
-  ac_status=$?
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
-  { (case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_try") 2>&5
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); }; }; then
-  ac_cv_c_gcc_strength_bug="no"
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       } && test -s conftest.$ac_objext; then
+  eval "$as_ac_Header=yes"
 else
-  echo "$as_me: program exited with status $ac_status" >&5
-echo "$as_me: failed program was:" >&5
+  echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-( exit $ac_status )
-ac_cv_c_gcc_strength_bug="yes"
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+       eval "$as_ac_Header=no"
 fi
 
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+ac_res=`eval echo '${'$as_ac_Header'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
 
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_gcc_strength_bug" >&5
-echo "${ECHO_T}$ac_cv_c_gcc_strength_bug" >&6; }
-  if test "$ac_cv_c_gcc_strength_bug" = "yes"
-  then
-    EXTRACFLAGS="$EXTRACFLAGS -fno-strength-reduce"
-  fi
 
+done
 
-  { echo "$as_me:$LINENO: checking whether the compiler supports -fshort-wchar" >&5
-echo $ECHO_N "checking whether the compiler supports -fshort-wchar... $ECHO_C" >&6; }
-if test "${ac_cv_cflags__fshort_wchar+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -fshort-wchar"
-cat >conftest.$ac_ext <<_ACEOF
+       cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-
-int
-main ()
-{
-
-  ;
-  return 0;
-}
+#include <ft2build.h>
+                    #include <freetype/fttrigon.h>
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+if { (ac_try="$ac_cpp conftest.$ac_ext"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
   cat conftest.err >&5
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
+  (exit $ac_status); } >/dev/null && {
+        test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_cflags__fshort_wchar=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-       ac_cv_cflags__fshort_wchar=no
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fshort_wchar" >&5
-echo "${ECHO_T}$ac_cv_cflags__fshort_wchar" >&6; }
-if test $ac_cv_cflags__fshort_wchar = yes; then
+       }; then
 
 cat >>confdefs.h <<\_ACEOF
-#define CC_FLAG_SHORT_WCHAR "-fshort-wchar"
+#define HAVE_FREETYPE_FTTRIGON_H 1
 _ACEOF
 
+                    wine_cv_fttrigon=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+  wine_cv_fttrigon=no
 fi
 
-  { echo "$as_me:$LINENO: checking whether the compiler supports -fno-strict-aliasing" >&5
-echo $ECHO_N "checking whether the compiler supports -fno-strict-aliasing... $ECHO_C" >&6; }
-if test "${ac_cv_cflags__fno_strict_aliasing+set}" = set; then
+rm -f conftest.err conftest.$ac_ext
+        { echo "$as_me:$LINENO: checking for FT_TrueTypeEngineType" >&5
+echo $ECHO_N "checking for FT_TrueTypeEngineType... $ECHO_C" >&6; }
+if test "${ac_cv_type_FT_TrueTypeEngineType+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -fno-strict-aliasing"
-cat >conftest.$ac_ext <<_ACEOF
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
+#include <freetype/ftmodapi.h>
 
+typedef FT_TrueTypeEngineType ac__type_new_;
 int
 main ()
 {
-
+if ((ac__type_new_ *) 0)
+  return 0;
+if (sizeof (ac__type_new_))
+  return 0;
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -12739,44 +12557,80 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_cflags__fno_strict_aliasing=yes
+       } && test -s conftest.$ac_objext; then
+  ac_cv_type_FT_TrueTypeEngineType=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_cflags__fno_strict_aliasing=no
+       ac_cv_type_FT_TrueTypeEngineType=no
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fno_strict_aliasing" >&5
-echo "${ECHO_T}$ac_cv_cflags__fno_strict_aliasing" >&6; }
-if test $ac_cv_cflags__fno_strict_aliasing = yes; then
-  EXTRACFLAGS="$EXTRACFLAGS -fno-strict-aliasing"
+{ echo "$as_me:$LINENO: result: $ac_cv_type_FT_TrueTypeEngineType" >&5
+echo "${ECHO_T}$ac_cv_type_FT_TrueTypeEngineType" >&6; }
+if test $ac_cv_type_FT_TrueTypeEngineType = yes; then
+
+cat >>confdefs.h <<_ACEOF
+#define HAVE_FT_TRUETYPEENGINETYPE 1
+_ACEOF
+
+
 fi
 
-  { echo "$as_me:$LINENO: checking whether the compiler supports -Wdeclaration-after-statement" >&5
-echo $ECHO_N "checking whether the compiler supports -Wdeclaration-after-statement... $ECHO_C" >&6; }
-if test "${ac_cv_cflags__Wdeclaration_after_statement+set}" = set; then
+        ac_save_CFLAGS="$CFLAGS"
+        CFLAGS="$CFLAGS $FREETYPELIBS"
+
+for ac_func in FT_Load_Sfnt_Table
+do
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
+if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -Wdeclaration-after-statement"
-cat >conftest.$ac_ext <<_ACEOF
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
+/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
+   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
+#define $ac_func innocuous_$ac_func
+
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char $ac_func (); below.
+    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+    <limits.h> exists even on freestanding compilers.  */
+
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+
+#undef $ac_func
+
+/* 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 $ac_func ();
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined __stub_$ac_func || defined __stub___$ac_func
+choke me
+#endif
 
 int
 main ()
 {
-
+return $ac_func ();
   ;
   return 0;
 }
@@ -12799,54 +12653,80 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_cflags__Wdeclaration_after_statement=yes
+  eval "$as_ac_var=yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_cflags__Wdeclaration_after_statement=no
+       eval "$as_ac_var=no"
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cflags__Wdeclaration_after_statement" >&5
-echo "${ECHO_T}$ac_cv_cflags__Wdeclaration_after_statement" >&6; }
-if test $ac_cv_cflags__Wdeclaration_after_statement = yes; then
-  EXTRACFLAGS="$EXTRACFLAGS -Wdeclaration-after-statement"
+ac_res=`eval echo '${'$as_ac_var'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
+
 fi
+done
 
-  { echo "$as_me:$LINENO: checking whether the compiler supports -Wwrite-strings" >&5
-echo $ECHO_N "checking whether the compiler supports -Wwrite-strings... $ECHO_C" >&6; }
-if test "${ac_cv_cflags__Wwrite_strings+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
+        CFLAGS="$ac_save_CFLAGS"
+       CPPFLAGS="$ac_save_CPPFLAGS"
+               if test "$ac_cv_header_freetype_freetype_h" = "yes" -a "$wine_cv_fttrigon" = "yes"
+       then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_FREETYPE 1
+_ACEOF
+
+           wine_cv_msg_freetype=no
+       else
+           FREETYPELIBS=""
+           FREETYPEINCL=""
+           wine_cv_msg_freetype=yes
+       fi
+    fi
+fi
+
+if test "$FONTFORGE" != "false" -a -n "$FREETYPELIBS"
+then
+  FONTSSUBDIRS="fonts"
+
+fi
+
+{ echo "$as_me:$LINENO: checking for parport header/ppdev.h" >&5
+echo $ECHO_N "checking for parport header/ppdev.h... $ECHO_C" >&6; }
+if test "${ac_cv_c_ppdev+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -Wwrite-strings"
-cat >conftest.$ac_ext <<_ACEOF
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-
+#include <linux/ppdev.h>
 int
 main ()
 {
-
+ioctl (1,PPCLAIM,0)
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -12855,32 +12735,31 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_cflags__Wwrite_strings=yes
+       } && test -s conftest.$ac_objext; then
+  ac_cv_c_ppdev="yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_cflags__Wwrite_strings=no
+       ac_cv_c_ppdev="no"
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cflags__Wwrite_strings" >&5
-echo "${ECHO_T}$ac_cv_cflags__Wwrite_strings" >&6; }
-if test $ac_cv_cflags__Wwrite_strings = yes; then
-  EXTRACFLAGS="$EXTRACFLAGS -Wwrite-strings"
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_c_ppdev" >&5
+echo "${ECHO_T}$ac_cv_c_ppdev" >&6; }
+if test "$ac_cv_c_ppdev" = "yes"
+then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_PPDEV 1
+_ACEOF
 
+fi
 
-    saved_CFLAGS="$CFLAGS"
-  CFLAGS="$CFLAGS -Wpointer-arith -Werror"
-  { echo "$as_me:$LINENO: checking for broken string.h that generates warnings" >&5
-echo $ECHO_N "checking for broken string.h that generates warnings... $ECHO_C" >&6; }
-if test "${ac_cv_c_string_h_warnings+set}" = set; then
+{ echo "$as_me:$LINENO: checking for va_copy" >&5
+echo $ECHO_N "checking for va_copy... $ECHO_C" >&6; }
+if test "${ac_cv_c_va_copy+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -12889,23 +12768,23 @@ _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-#include <string.h>
+#include <stdarg.h>
 int
 main ()
 {
-
+va_list ap1, ap2; va_copy(ap1,ap2);
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -12914,32 +12793,33 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_c_string_h_warnings=no
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_c_va_copy="yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_c_string_h_warnings=yes
+       ac_cv_c_va_copy="no"
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_string_h_warnings" >&5
-echo "${ECHO_T}$ac_cv_c_string_h_warnings" >&6; }
-  CFLAGS="$saved_CFLAGS"
-  if test "$ac_cv_c_string_h_warnings" = "no"
-  then
-    EXTRACFLAGS="$EXTRACFLAGS -Wpointer-arith"
-  fi
+{ echo "$as_me:$LINENO: result: $ac_cv_c_va_copy" >&5
+echo "${ECHO_T}$ac_cv_c_va_copy" >&6; }
+if test "$ac_cv_c_va_copy" = "yes"
+then
 
-  BUILTINFLAG=""
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_VA_COPY 1
+_ACEOF
 
-  saved_CFLAGS="$CFLAGS"
-  CFLAGS="$CFLAGS -Werror"
-  { echo "$as_me:$LINENO: checking for builtin wchar inlines" >&5
-echo $ECHO_N "checking for builtin wchar inlines... $ECHO_C" >&6; }
-if test "${ac_cv_c_builtin_wchar_ctype+set}" = set; then
+fi
+{ echo "$as_me:$LINENO: checking for __va_copy" >&5
+echo $ECHO_N "checking for __va_copy... $ECHO_C" >&6; }
+if test "${ac_cv_c___va_copy+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -12948,23 +12828,23 @@ _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-
+#include <stdarg.h>
 int
 main ()
 {
-int iswlower(unsigned short);
+va_list ap1, ap2; __va_copy(ap1,ap2);
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
+  (eval "$ac_link") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -12973,30 +12853,34 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_c_builtin_wchar_ctype=no
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_c___va_copy="yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_c_builtin_wchar_ctype=yes
+       ac_cv_c___va_copy="no"
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_builtin_wchar_ctype" >&5
-echo "${ECHO_T}$ac_cv_c_builtin_wchar_ctype" >&6; }
-  CFLAGS="$saved_CFLAGS"
-  if test "$ac_cv_c_builtin_wchar_ctype" = "yes"
-  then
-    BUILTINFLAG="-fno-builtin"
-  fi
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_c___va_copy" >&5
+echo "${ECHO_T}$ac_cv_c___va_copy" >&6; }
+if test "$ac_cv_c___va_copy" = "yes"
+then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE___VA_COPY 1
+_ACEOF
 
+fi
 
-{ echo "$as_me:$LINENO: checking how to define a function in assembly code" >&5
-echo $ECHO_N "checking how to define a function in assembly code... $ECHO_C" >&6; }
-if test "${ac_cv_asm_func_def+set}" = set; then
+{ echo "$as_me:$LINENO: checking for sigsetjmp" >&5
+echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6; }
+if test "${ac_cv_c_sigsetjmp+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -13005,12 +12889,13 @@ _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-void ac_asm(void) { asm("\t.globl _ac_test\n\t.def _ac_test; .scl 2; .type 32; .endef\n_ac_test:\t.long 0"); }
-
+#include <setjmp.h>
 int
 main ()
 {
-
+sigjmp_buf buf;
+    sigsetjmp( buf, 1 );
+    siglongjmp( buf, 1 );
   ;
   return 0;
 }
@@ -13033,35 +12918,63 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_asm_func_def=".def"
+  ac_cv_c_sigsetjmp="yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       cat >conftest.$ac_ext <<_ACEOF
+       ac_cv_c_sigsetjmp="no"
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_c_sigsetjmp" >&5
+echo "${ECHO_T}$ac_cv_c_sigsetjmp" >&6; }
+if test "$ac_cv_c_sigsetjmp" = "yes"
+then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_SIGSETJMP 1
+_ACEOF
+
+fi
+
+{ echo "$as_me:$LINENO: checking for pthread_rwlock_t" >&5
+echo $ECHO_N "checking for pthread_rwlock_t... $ECHO_C" >&6; }
+if test "${ac_cv_type_pthread_rwlock_t+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-void ac_asm(void) { asm("\t.globl _ac_test\n\t.type _ac_test,@function\n_ac_test:\t.long 0"); }
+#define _GNU_SOURCE
+#include <pthread.h>
 
+typedef pthread_rwlock_t ac__type_new_;
 int
 main ()
 {
-
+if ((ac__type_new_ *) 0)
+  return 0;
+if (sizeof (ac__type_new_))
+  return 0;
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -13070,37 +12983,61 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_asm_func_def=".type @function"
+       } && test -s conftest.$ac_objext; then
+  ac_cv_type_pthread_rwlock_t=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       cat >conftest.$ac_ext <<_ACEOF
+       ac_cv_type_pthread_rwlock_t=no
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_type_pthread_rwlock_t" >&5
+echo "${ECHO_T}$ac_cv_type_pthread_rwlock_t" >&6; }
+if test $ac_cv_type_pthread_rwlock_t = yes; then
+
+cat >>confdefs.h <<_ACEOF
+#define HAVE_PTHREAD_RWLOCK_T 1
+_ACEOF
+
+
+fi
+{ echo "$as_me:$LINENO: checking for pthread_rwlockattr_t" >&5
+echo $ECHO_N "checking for pthread_rwlockattr_t... $ECHO_C" >&6; }
+if test "${ac_cv_type_pthread_rwlockattr_t+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-void ac_asm(void) { asm("\t.globl _ac_test\n\t.type _ac_test,2\n_ac_test:\t.long 0"); }
+#define _GNU_SOURCE
+#include <pthread.h>
 
+typedef pthread_rwlockattr_t ac__type_new_;
 int
 main ()
 {
-
+if ((ac__type_new_ *) 0)
+  return 0;
+if (sizeof (ac__type_new_))
+  return 0;
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -13109,59 +13046,45 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_asm_func_def=".type 2"
+       } && test -s conftest.$ac_objext; then
+  ac_cv_type_pthread_rwlockattr_t=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_asm_func_def="unknown"
+       ac_cv_type_pthread_rwlockattr_t=no
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_type_pthread_rwlockattr_t" >&5
+echo "${ECHO_T}$ac_cv_type_pthread_rwlockattr_t" >&6; }
+if test $ac_cv_type_pthread_rwlockattr_t = yes; then
+
+cat >>confdefs.h <<_ACEOF
+#define HAVE_PTHREAD_RWLOCKATTR_T 1
+_ACEOF
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_asm_func_def" >&5
-echo "${ECHO_T}$ac_cv_asm_func_def" >&6; }
 
 
+ac_wine_check_funcs_save_LIBS="$LIBS"
+LIBS="$LIBS $LIBPTHREAD"
 
-case "$ac_cv_asm_func_def" in
-  ".def")
-     cat >>confdefs.h <<\_ACEOF
-#define __ASM_FUNC(name) ".def " __ASM_NAME(name) "; .scl 2; .type 32; .endef"
-_ACEOF
- ;;
-  ".type @function")
-     cat >>confdefs.h <<\_ACEOF
-#define __ASM_FUNC(name) ".type " __ASM_NAME(name) ",@function"
-_ACEOF
- ;;
-  ".type 2")
-     cat >>confdefs.h <<\_ACEOF
-#define __ASM_FUNC(name) ".type " __ASM_NAME(name) ",2"
-_ACEOF
- ;;
-  *)
-     cat >>confdefs.h <<\_ACEOF
-#define __ASM_FUNC(name) ""
-_ACEOF
- ;;
-esac
 
 
-{ echo "$as_me:$LINENO: checking whether external symbols need an underscore prefix" >&5
-echo $ECHO_N "checking whether external symbols need an underscore prefix... $ECHO_C" >&6; }
-if test "${ac_cv_c_extern_prefix+set}" = set; then
+
+for ac_func in \
+        pthread_attr_get_np \
+        pthread_getattr_np \
+        pthread_get_stackaddr_np \
+        pthread_get_stacksize_np
+do
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
+if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   cat >conftest.$ac_ext <<_ACEOF
@@ -13170,12 +13093,41 @@ _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-void ac_asm(void) { asm(".globl _ac_test\n_ac_test:\t.long 0"); }
-extern int ac_test;
+/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
+   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
+#define $ac_func innocuous_$ac_func
+
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char $ac_func (); below.
+    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+    <limits.h> exists even on freestanding compilers.  */
+
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+
+#undef $ac_func
+
+/* 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 $ac_func ();
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined __stub_$ac_func || defined __stub___$ac_func
+choke me
+#endif
+
 int
 main ()
 {
-if (ac_test) return 1
+return $ac_func ();
   ;
   return 0;
 }
@@ -13198,72 +13150,50 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_c_extern_prefix="yes"
+  eval "$as_ac_var=yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_c_extern_prefix="no"
+       eval "$as_ac_var=no"
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_extern_prefix" >&5
-echo "${ECHO_T}$ac_cv_c_extern_prefix" >&6; }
-
-
-
-if test "$ac_cv_c_extern_prefix" = "yes"
-then
-  cat >>confdefs.h <<\_ACEOF
-#define __ASM_NAME(name) "_" name
-_ACEOF
-
-else
-  cat >>confdefs.h <<\_ACEOF
-#define __ASM_NAME(name) name
+ac_res=`eval echo '${'$as_ac_var'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+  cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
 _ACEOF
 
 fi
+done
 
+LIBS="$ac_wine_check_funcs_save_LIBS"
 
-DLLEXT=""
-
-DLLFLAGS="-D_REENTRANT"
-
-LDSHARED=""
-
-LDDLLFLAGS=""
-
-LIBEXT="so"
-
-IMPLIBEXT="def"
-
-LIBWINE_LDFLAGS=""
-
-
-case $host_os in
-  cygwin*|mingw32*)
-    if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
-set dummy ${ac_tool_prefix}dlltool; ac_word=$2
+# Extract the first word of "esd-config", so it can be a program name with args.
+set dummy esd-config; ac_word=$2
 { echo "$as_me:$LINENO: checking for $ac_word" >&5
 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_DLLTOOL+set}" = set; then
+if test "${ac_cv_path_ESDCONFIG+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  if test -n "$DLLTOOL"; then
-  ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+  case $ESDCONFIG in
+  [\\/]* | ?:[\\/]*)
+  ac_cv_path_ESDCONFIG="$ESDCONFIG" # Let the user override the test with a path.
+  ;;
+  *)
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
 for as_dir in $PATH
 do
   IFS=$as_save_IFS
   test -z "$as_dir" && as_dir=.
   for ac_exec_ext in '' $ac_executable_extensions; do
   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
+    ac_cv_path_ESDCONFIG="$as_dir/$ac_word$ac_exec_ext"
     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
     break 2
   fi
 done
 IFS=$as_save_IFS
 
+  ;;
+esac
 fi
-fi
-DLLTOOL=$ac_cv_prog_DLLTOOL
-if test -n "$DLLTOOL"; then
-  { echo "$as_me:$LINENO: result: $DLLTOOL" >&5
-echo "${ECHO_T}$DLLTOOL" >&6; }
+ESDCONFIG=$ac_cv_path_ESDCONFIG
+if test -n "$ESDCONFIG"; then
+  { echo "$as_me:$LINENO: result: $ESDCONFIG" >&5
+echo "${ECHO_T}$ESDCONFIG" >&6; }
 else
   { echo "$as_me:$LINENO: result: no" >&5
 echo "${ECHO_T}no" >&6; }
 fi
 
 
-fi
-if test -z "$ac_cv_prog_DLLTOOL"; then
-  ac_ct_DLLTOOL=$DLLTOOL
-  # Extract the first word of "dlltool", so it can be a program name with args.
-set dummy dlltool; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
+if test x$ESDCONFIG != x -a x$ESDCONFIG != x'"$ESDCONFIG"';
+then
+    ESD_CFLAGS=""
+    for i in `$ESDCONFIG --cflags`
+    do
+      case "$i" in
+        -I*) ESD_CFLAGS="$ESD_CFLAGS $i";;
+      esac
+    done
+    ESD_LIBS=`$ESDCONFIG --libs`
+    save_CFLAGS="$CFLAGS"
+    CFLAGS="$CFLAGS $ESD_CFLAGS"
+    { echo "$as_me:$LINENO: checking for esd_open_sound in -lesd" >&5
+echo $ECHO_N "checking for esd_open_sound in -lesd... $ECHO_C" >&6; }
+if test "${ac_cv_lib_esd_esd_open_sound+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  if test -n "$ac_ct_DLLTOOL"; then
-  ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_DLLTOOL="dlltool"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lesd  $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
 
-fi
-fi
-ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
-if test -n "$ac_ct_DLLTOOL"; then
-  { echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
-echo "${ECHO_T}$ac_ct_DLLTOOL" >&6; }
+/* 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 esd_open_sound ();
+int
+main ()
+{
+return esd_open_sound ();
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_lib_esd_esd_open_sound=yes
 else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       ac_cv_lib_esd_esd_open_sound=no
 fi
 
-  if test "x$ac_ct_DLLTOOL" = x; then
-    DLLTOOL="false"
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&2;}
-ac_tool_warned=yes ;;
-esac
-    DLLTOOL=$ac_ct_DLLTOOL
-  fi
-else
-  DLLTOOL="$ac_cv_prog_DLLTOOL"
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_esd_esd_open_sound" >&5
+echo "${ECHO_T}$ac_cv_lib_esd_esd_open_sound" >&6; }
+if test $ac_cv_lib_esd_esd_open_sound = yes; then
+  ESDLIBS=$ESD_LIBS
 
-    if test -n "$ac_tool_prefix"; then
-  # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
-set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_DLLWRAP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$DLLWRAP"; then
-  ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-DLLWRAP=$ac_cv_prog_DLLWRAP
-if test -n "$DLLWRAP"; then
-  { echo "$as_me:$LINENO: result: $DLLWRAP" >&5
-echo "${ECHO_T}$DLLWRAP" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
+         ESDINCL=$ESD_CFLAGS
 
 
-fi
-if test -z "$ac_cv_prog_DLLWRAP"; then
-  ac_ct_DLLWRAP=$DLLWRAP
-  # Extract the first word of "dllwrap", so it can be a program name with args.
-set dummy dllwrap; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_ac_ct_DLLWRAP+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$ac_ct_DLLWRAP"; then
-  ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_ESD 1
+_ACEOF
 
-fi
-fi
-ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
-if test -n "$ac_ct_DLLWRAP"; then
-  { echo "$as_me:$LINENO: result: $ac_ct_DLLWRAP" >&5
-echo "${ECHO_T}$ac_ct_DLLWRAP" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
 fi
 
-  if test "x$ac_ct_DLLWRAP" = x; then
-    DLLWRAP="false"
-  else
-    case $cross_compiling:$ac_tool_warned in
-yes:)
-{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&5
-echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
-whose name does not start with the host triplet.  If you think this
-configuration is useful to you, please write to autoconf@gnu.org." >&2;}
-ac_tool_warned=yes ;;
-esac
-    DLLWRAP=$ac_ct_DLLWRAP
-  fi
-else
-  DLLWRAP="$ac_cv_prog_DLLWRAP"
+    CFLAGS="$save_CFLAGS"
 fi
 
-    if test "$DLLWRAP" = "false"; then
-      LIBEXT="a"
-    else
-            LIBEXT="dll"
-    fi
-    IMPLIBEXT="a"
-        WIN16_FILES=""
-    WIN16_INSTALL=""
-    ;;
-  darwin*|macosx*)
-    DLLEXT=".so"
-    LIBEXT="dylib"
-    DLLFLAGS="$DLLFLAGS -fPIC"
-    LDDLLFLAGS="-bundle -multiply_defined suppress"
-    LIBWINE_LDFLAGS="-multiply_defined suppress"
-    LDSHARED="\$(CC) -dynamiclib -install_name @executable_path/\`\$(RELPATH) \$(bindir) \$(libdir)\`/\$(DYNAME)"
-    STRIP="$STRIP -u -r"
-        COREFOUNDATIONLIB="-framework CoreFoundation"
-
-    IOKITLIB="-framework IOKit -framework CoreFoundation"
-
-    LDEXECFLAGS="-image_base 0x7bf00000 -Wl,-segaddr,WINE_DOS,0x00000000,-segaddr,WINE_SHARED_HEAP,0x7f000000"
-
-    if test "$ac_cv_header_DiskArbitration_DiskArbitration_h" = "yes"
-    then
-                DISKARBITRATIONLIB="-framework DiskArbitration -framework CoreFoundation"
-
-    fi
-    if test "$ac_cv_header_CoreAudio_CoreAudio_h" = "yes" -a "$ac_cv_header_AudioUnit_AudioUnit_h" = "yes"
-    then
-                COREAUDIO="-framework CoreAudio -framework AudioUnit -framework CoreServices"
-
-    fi
-    case $host_cpu in
-      *powerpc*)
-        LDDLLFLAGS="$LDDLLFLAGS -read_only_relocs warning"          ;;
-    esac
-        if test "$ac_cv_header_Carbon_Carbon_h" = "yes"
-    then
-        CARBONLIB="-framework Carbon"
+ALSALIBS=""
 
-        QUARTZFILES='$(QUARTZFILES)'
-    fi
-    ;;
-  *)
-    DLLFLAGS="$DLLFLAGS -fPIC"
-    DLLEXT=".so"
-    { echo "$as_me:$LINENO: checking whether we can build a GNU style ELF dll" >&5
-echo $ECHO_N "checking whether we can build a GNU style ELF dll... $ECHO_C" >&6; }
-if test "${ac_cv_c_dll_gnuelf+set}" = set; then
+if test "$ac_cv_header_sys_asoundlib_h" = "yes" -o "$ac_cv_header_alsa_asoundlib_h" = "yes"
+then
+    { echo "$as_me:$LINENO: checking for snd_pcm_hw_params_get_access in -lasound" >&5
+echo $ECHO_N "checking for snd_pcm_hw_params_get_access in -lasound... $ECHO_C" >&6; }
+if test "${ac_cv_lib_asound_snd_pcm_hw_params_get_access+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -fPIC -shared -Wl,-Bsymbolic"
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-lasound  $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
-void myfunc() {}
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* 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 snd_pcm_hw_params_get_access ();
+int
+main ()
+{
+return snd_pcm_hw_params_get_access ();
+  ;
+  return 0;
+}
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
 if { (ac_try="$ac_link"
@@ -13512,54 +13353,48 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_c_dll_gnuelf="yes"
+  ac_cv_lib_asound_snd_pcm_hw_params_get_access=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_c_dll_gnuelf="no"
+       ac_cv_lib_asound_snd_pcm_hw_params_get_access=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
+LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_dll_gnuelf" >&5
-echo "${ECHO_T}$ac_cv_c_dll_gnuelf" >&6; }
-    if test "$ac_cv_c_dll_gnuelf" = "yes"
-    then
-      LDSHARED="\$(CC) -shared"
-      LDDLLFLAGS="-shared -Wl,-Bsymbolic"
-      { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -shared -Wl,-soname,confest.so.1" >&5
-echo $ECHO_N "checking whether the compiler supports -fPIC -shared -Wl,-soname,confest.so.1... $ECHO_C" >&6; }
-if test "${ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -fPIC -shared -Wl,-soname,confest.so.1"
-cat >conftest.$ac_ext <<_ACEOF
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_asound_snd_pcm_hw_params_get_access" >&5
+echo "${ECHO_T}$ac_cv_lib_asound_snd_pcm_hw_params_get_access" >&6; }
+if test $ac_cv_lib_asound_snd_pcm_hw_params_get_access = yes; then
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-
+#ifdef HAVE_ALSA_ASOUNDLIB_H
+#include <alsa/asoundlib.h>
+#elif defined(HAVE_SYS_ASOUNDLIB_H)
+#include <sys/asoundlib.h>
+#endif
 int
 main ()
 {
-
+int ret = snd_pcm_hw_params_get_access(NULL, NULL)
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -13568,32 +13403,37 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1=yes
+       } && test -s conftest.$ac_objext; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_ALSA 1
+_ACEOF
+
+                         ALSALIBS="-lasound"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1=no
+
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1" >&5
-echo "${ECHO_T}$ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1" >&6; }
-if test $ac_cv_cflags__fPIC__shared__Wl__soname_confest_so_1 = yes; then
-  LDSHARED="\$(CC) -shared \$(SONAME:%=-Wl,-soname,%)"
-else
-  { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -shared -Wl,-h,confest.so.1" >&5
-echo $ECHO_N "checking whether the compiler supports -fPIC -shared -Wl,-h,confest.so.1... $ECHO_C" >&6; }
-if test "${ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1+set}" = set; then
+
+fi
+
+
+AUDIOIOLIBS=""
+
+if test "$ac_cv_header_libaudioio_h" = "yes"
+then
+    { echo "$as_me:$LINENO: checking for AudioIOGetVersion in -laudioio" >&5
+echo $ECHO_N "checking for AudioIOGetVersion in -laudioio... $ECHO_C" >&6; }
+if test "${ac_cv_lib_audioio_AudioIOGetVersion+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -fPIC -shared -Wl,-h,confest.so.1"
+  ac_check_lib_save_LIBS=$LIBS
+LIBS="-laudioio  $LIBS"
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -13601,10 +13441,17 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 AudioIOGetVersion ();
 int
 main ()
 {
-
+return AudioIOGetVersion ();
   ;
   return 0;
 }
@@ -13627,45 +13474,59 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1=yes
+  ac_cv_lib_audioio_AudioIOGetVersion=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1=no
+       ac_cv_lib_audioio_AudioIOGetVersion=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
+LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1" >&5
-echo "${ECHO_T}$ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1" >&6; }
-if test $ac_cv_cflags__fPIC__shared__Wl__h_confest_so_1 = yes; then
-  LDSHARED="\$(CC) -shared \$(SONAME:%=-Wl,-h,%)"
+{ echo "$as_me:$LINENO: result: $ac_cv_lib_audioio_AudioIOGetVersion" >&5
+echo "${ECHO_T}$ac_cv_lib_audioio_AudioIOGetVersion" >&6; }
+if test $ac_cv_lib_audioio_AudioIOGetVersion = yes; then
+  AUDIOIOLIBS="-laudioio"
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_LIBAUDIOIO 1
+_ACEOF
+
 fi
 
 fi
 
 
-      { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -shared -Wl,-Bsymbolic,-z,defs" >&5
-echo $ECHO_N "checking whether the compiler supports -fPIC -shared -Wl,-Bsymbolic,-z,defs... $ECHO_C" >&6; }
-if test "${ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs+set}" = set; then
+if test "$ac_cv_header_capi20_h" = "yes" -a "$ac_cv_header_linux_capi_h" = "yes"
+then
+    { echo "$as_me:$LINENO: checking for -lcapi20" >&5
+echo $ECHO_N "checking for -lcapi20... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_capi20+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -fPIC -shared -Wl,-Bsymbolic,-z,defs"
-cat >conftest.$ac_ext <<_ACEOF
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lcapi20  $LIBS"
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 capi20_register ();
 int
 main ()
 {
-
+return capi20_register ();
   ;
   return 0;
 }
@@ -13688,43 +13549,66 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs=yes
+  case "$LIBEXT" in
+    dll) ;;
+    dylib) ac_cv_lib_soname_capi20=`otool -L conftest$ac_exeext | grep "libcapi20\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libcapi20\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_capi20=`$ac_cv_path_LDD conftest$ac_exeext | grep "libcapi20\\.$LIBEXT" | sed -e "s/^.*\(libcapi20\.$LIBEXT[^   ]*\).*$/\1/"';2,$d'` ;;
+  esac
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs=no
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs" >&5
-echo "${ECHO_T}$ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs" >&6; }
-if test $ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__z_defs = yes; then
-  LDDLLFLAGS="$LDDLLFLAGS,-z,defs"
+if test "x$ac_cv_lib_soname_capi20" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_capi20" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_capi20" >&6; }
+
+cat >>confdefs.h <<_ACEOF
+#define SONAME_LIBCAPI20 "$ac_cv_lib_soname_capi20"
+_ACEOF
+
+
 fi
 
+fi
 
-      { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -shared -Wl,-Bsymbolic,-init,__wine_spec_init,-fini,__wine_spec_fini" >&5
-echo $ECHO_N "checking whether the compiler supports -fPIC -shared -Wl,-Bsymbolic,-init,__wine_spec_init,-fini,__wine_spec_fini... $ECHO_C" >&6; }
-if test "${ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini+set}" = set; then
+if test "$ac_cv_header_cups_cups_h" = "yes"
+then
+    { echo "$as_me:$LINENO: checking for -lcups" >&5
+echo $ECHO_N "checking for -lcups... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_cups+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -fPIC -shared -Wl,-Bsymbolic,-init,__wine_spec_init,-fini,__wine_spec_fini"
-cat >conftest.$ac_ext <<_ACEOF
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lcups  $LIBS"
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 cupsGetDefault ();
 int
 main ()
 {
-
+return cupsGetDefault ();
   ;
   return 0;
 }
@@ -13747,44 +13631,66 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini=yes
+  case "$LIBEXT" in
+    dll) ;;
+    dylib) ac_cv_lib_soname_cups=`otool -L conftest$ac_exeext | grep "libcups\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libcups\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_cups=`$ac_cv_path_LDD conftest$ac_exeext | grep "libcups\\.$LIBEXT" | sed -e "s/^.*\(libcups\.$LIBEXT[^         ]*\).*$/\1/"';2,$d'` ;;
+  esac
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini=no
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini" >&5
-echo "${ECHO_T}$ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini" >&6; }
-if test $ac_cv_cflags__fPIC__shared__Wl__Bsymbolic__init___wine_spec_init__fini___wine_spec_fini = yes; then
-  LDDLLFLAGS="$LDDLLFLAGS,-init,__wine_spec_init,-fini,__wine_spec_fini"
+if test "x$ac_cv_lib_soname_cups" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_cups" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_cups" >&6; }
+
+cat >>confdefs.h <<_ACEOF
+#define SONAME_LIBCUPS "$ac_cv_lib_soname_cups"
+_ACEOF
+
+
 fi
 
+fi
 
-      echo '{ global: *; };' >conftest.map
-      { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -shared -Wl,--version-script=conftest.map" >&5
-echo $ECHO_N "checking whether the compiler supports -fPIC -shared -Wl,--version-script=conftest.map... $ECHO_C" >&6; }
-if test "${ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map+set}" = set; then
+if test "$ac_cv_header_jack_jack_h" = "yes"
+then
+    { echo "$as_me:$LINENO: checking for -ljack" >&5
+echo $ECHO_N "checking for -ljack... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_jack+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -fPIC -shared -Wl,--version-script=conftest.map"
-cat >conftest.$ac_ext <<_ACEOF
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-ljack  $LIBS"
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 jack_client_new ();
 int
 main ()
 {
-
+return jack_client_new ();
   ;
   return 0;
 }
@@ -13807,44 +13713,66 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map=yes
+  case "$LIBEXT" in
+    dll) ;;
+    dylib) ac_cv_lib_soname_jack=`otool -L conftest$ac_exeext | grep "libjack\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libjack\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_jack=`$ac_cv_path_LDD conftest$ac_exeext | grep "libjack\\.$LIBEXT" | sed -e "s/^.*\(libjack\.$LIBEXT[^         ]*\).*$/\1/"';2,$d'` ;;
+  esac
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map=no
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map" >&5
-echo "${ECHO_T}$ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map" >&6; }
-if test $ac_cv_cflags__fPIC__shared__Wl___version_script_conftest_map = yes; then
-  LDSHARED="$LDSHARED \$(VERSCRIPT:%=-Wl,--version-script=%)"
+if test "x$ac_cv_lib_soname_jack" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_jack" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_jack" >&6; }
+
+cat >>confdefs.h <<_ACEOF
+#define SONAME_LIBJACK "$ac_cv_lib_soname_jack"
+_ACEOF
+
+
 fi
 
-      rm -f conftest.map
+fi
 
-      { echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -Wl,--export-dynamic" >&5
-echo $ECHO_N "checking whether the compiler supports -fPIC -Wl,--export-dynamic... $ECHO_C" >&6; }
-if test "${ac_cv_cflags__fPIC__Wl___export_dynamic+set}" = set; then
+if test "$ac_cv_header_fontconfig_fontconfig_h" = "yes"
+then
+    { echo "$as_me:$LINENO: checking for -lfontconfig" >&5
+echo $ECHO_N "checking for -lfontconfig... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_fontconfig+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -fPIC -Wl,--export-dynamic"
-cat >conftest.$ac_ext <<_ACEOF
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lfontconfig  $LIBS"
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 FcInit ();
 int
 main ()
 {
-
+return FcInit ();
   ;
   return 0;
 }
@@ -13867,45 +13795,66 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_cflags__fPIC__Wl___export_dynamic=yes
+  case "$LIBEXT" in
+    dll) ;;
+    dylib) ac_cv_lib_soname_fontconfig=`otool -L conftest$ac_exeext | grep "libfontconfig\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libfontconfig\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_fontconfig=`$ac_cv_path_LDD conftest$ac_exeext | grep "libfontconfig\\.$LIBEXT" | sed -e "s/^.*\(libfontconfig\.$LIBEXT[^       ]*\).*$/\1/"';2,$d'` ;;
+  esac
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_cflags__fPIC__Wl___export_dynamic=no
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fPIC__Wl___export_dynamic" >&5
-echo "${ECHO_T}$ac_cv_cflags__fPIC__Wl___export_dynamic" >&6; }
-if test $ac_cv_cflags__fPIC__Wl___export_dynamic = yes; then
-  LDEXECFLAGS="-Wl,--export-dynamic"
+if test "x$ac_cv_lib_soname_fontconfig" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_fontconfig" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_fontconfig" >&6; }
+
+cat >>confdefs.h <<_ACEOF
+#define SONAME_LIBFONTCONFIG "$ac_cv_lib_soname_fontconfig"
+_ACEOF
+
 
 fi
 
+fi
 
-      as_ac_var=`echo "ac_cv_cflags_-fPIC -Wl,--rpath,\$ORIGIN/../lib" | $as_tr_sh`
-{ echo "$as_me:$LINENO: checking whether the compiler supports -fPIC -Wl,--rpath,\$ORIGIN/../lib" >&5
-echo $ECHO_N "checking whether the compiler supports -fPIC -Wl,--rpath,\$ORIGIN/../lib... $ECHO_C" >&6; }
-if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
+if test "$ac_cv_header_openssl_err_h" = "yes" -a "$ac_cv_header_openssl_ssl_h" = "yes"
+then
+    { echo "$as_me:$LINENO: checking for -lssl" >&5
+echo $ECHO_N "checking for -lssl... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_ssl+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -fPIC -Wl,--rpath,\$ORIGIN/../lib"
-cat >conftest.$ac_ext <<_ACEOF
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lssl  $LIBS"
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 SSL_library_init ();
 int
 main ()
 {
-
+return SSL_library_init ();
   ;
   return 0;
 }
@@ -13928,46 +13877,62 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  eval "$as_ac_var=yes"
+  case "$LIBEXT" in
+    dll) ;;
+    dylib) ac_cv_lib_soname_ssl=`otool -L conftest$ac_exeext | grep "libssl\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libssl\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_ssl=`$ac_cv_path_LDD conftest$ac_exeext | grep "libssl\\.$LIBEXT" | sed -e "s/^.*\(libssl\.$LIBEXT[^    ]*\).*$/\1/"';2,$d'` ;;
+  esac
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       eval "$as_ac_var=no"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
-fi
-ac_res=`eval echo '${'$as_ac_var'}'`
-              { echo "$as_me:$LINENO: result: $ac_res" >&5
-echo "${ECHO_T}$ac_res" >&6; }
-if test `eval echo '${'$as_ac_var'}'` = yes; then
-  LIBWINE_LDFLAGS="-Wl,--rpath,\\\$\$ORIGIN/\`\$(RELPATH) \$(bindir) \$(libdir)\`"
+  LIBS=$ac_check_soname_save_LIBS
 fi
+if test "x$ac_cv_lib_soname_ssl" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
 
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_ssl" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_ssl" >&6; }
 
-      case $host_cpu in
-        *i[3456789]86* | x86_64)
-          { echo "$as_me:$LINENO: checking whether the compiler supports -Wl,--section-start,.interp=0x7bf00400" >&5
-echo $ECHO_N "checking whether the compiler supports -Wl,--section-start,.interp=0x7bf00400... $ECHO_C" >&6; }
-if test "${ac_cv_cflags__Wl___section_start__interp_0x7bf00400+set}" = set; then
+cat >>confdefs.h <<_ACEOF
+#define SONAME_LIBSSL "$ac_cv_lib_soname_ssl"
+_ACEOF
+
+
+fi
+
+    { echo "$as_me:$LINENO: checking for -lcrypto" >&5
+echo $ECHO_N "checking for -lcrypto... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_crypto+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -Wl,--section-start,.interp=0x7bf00400"
-cat >conftest.$ac_ext <<_ACEOF
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lcrypto  $LIBS"
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
-int
-main ()
-{
-
+/* 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 BIO_new_socket ();
+int
+main ()
+{
+return BIO_new_socket ();
   ;
   return 0;
 }
@@ -13990,37 +13955,138 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_cflags__Wl___section_start__interp_0x7bf00400=yes
+  case "$LIBEXT" in
+    dll) ;;
+    dylib) ac_cv_lib_soname_crypto=`otool -L conftest$ac_exeext | grep "libcrypto\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libcrypto\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_crypto=`$ac_cv_path_LDD conftest$ac_exeext | grep "libcrypto\\.$LIBEXT" | sed -e "s/^.*\(libcrypto\.$LIBEXT[^   ]*\).*$/\1/"';2,$d'` ;;
+  esac
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_cflags__Wl___section_start__interp_0x7bf00400=no
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-CFLAGS=$ac_wine_try_cflags_saved
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cflags__Wl___section_start__interp_0x7bf00400" >&5
-echo "${ECHO_T}$ac_cv_cflags__Wl___section_start__interp_0x7bf00400" >&6; }
-if test $ac_cv_cflags__Wl___section_start__interp_0x7bf00400 = yes; then
-  LDEXECFLAGS="$LDEXECFLAGS -Wl,--section-start,.interp=0x7bf00400"
+if test "x$ac_cv_lib_soname_crypto" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_crypto" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_crypto" >&6; }
+
+cat >>confdefs.h <<_ACEOF
+#define SONAME_LIBCRYPTO "$ac_cv_lib_soname_crypto"
+_ACEOF
+
+
 fi
 
-          ;;
-      esac
+fi
 
-    else
-      { echo "$as_me:$LINENO: checking whether we can build a UnixWare (Solaris) dll" >&5
-echo $ECHO_N "checking whether we can build a UnixWare (Solaris) dll... $ECHO_C" >&6; }
-if test "${ac_cv_c_dll_unixware+set}" = set; then
+
+EXTRACFLAGS=""
+
+if test "x${GCC}" = "xyes"
+then
+  EXTRACFLAGS="-Wall -pipe"
+
+    { echo "$as_me:$LINENO: checking for gcc strength-reduce bug" >&5
+echo $ECHO_N "checking for gcc strength-reduce bug... $ECHO_C" >&6; }
+if test "${ac_cv_c_gcc_strength_bug+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  if test "$cross_compiling" = yes; then
+  ac_cv_c_gcc_strength_bug="yes"
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+int L[4] = {0,1,2,3};
+int
+main ()
+{
+static int Array[3];
+  unsigned int B = 3;
+  int i;
+  for(i=0; i<B; i++) Array[i] = i - 3;
+  for(i=0; i<4 - 1; i++) L[i] = L[i + 1];
+  L[i] = 4;
+  exit( Array[1] != -2 || L[2] != 3)
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+  { (case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_try") 2>&5
+  ac_status=$?
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); }; }; then
+  ac_cv_c_gcc_strength_bug="no"
+else
+  echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+ac_cv_c_gcc_strength_bug="yes"
+fi
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
+
+
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_c_gcc_strength_bug" >&5
+echo "${ECHO_T}$ac_cv_c_gcc_strength_bug" >&6; }
+  if test "$ac_cv_c_gcc_strength_bug" = "yes"
+  then
+    EXTRACFLAGS="$EXTRACFLAGS -fno-strength-reduce"
+  fi
+
+
+  { echo "$as_me:$LINENO: checking whether the compiler supports -fshort-wchar" >&5
+echo $ECHO_N "checking whether the compiler supports -fshort-wchar... $ECHO_C" >&6; }
+if test "${ac_cv_cflags__fshort_wchar+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -fPIC -Wl,-G,-h,conftest.so.1.0,-B,symbolic"
+CFLAGS="$CFLAGS -fshort-wchar"
 cat >conftest.$ac_ext <<_ACEOF
-void myfunc() {}
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
 if { (ac_try="$ac_link"
@@ -14040,35 +14106,49 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_c_dll_unixware="yes"
+  ac_cv_cflags__fshort_wchar=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_c_dll_unixware="no"
+       ac_cv_cflags__fshort_wchar=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 CFLAGS=$ac_wine_try_cflags_saved
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_dll_unixware" >&5
-echo "${ECHO_T}$ac_cv_c_dll_unixware" >&6; }
-      if test "$ac_cv_c_dll_unixware" = "yes"
-      then
-        LDSHARED="\$(CC) -Wl,-G \$(SONAME:%=-Wl,-h,%)"
-        LDDLLFLAGS="-Wl,-G,-B,symbolic"
+{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fshort_wchar" >&5
+echo "${ECHO_T}$ac_cv_cflags__fshort_wchar" >&6; }
+if test $ac_cv_cflags__fshort_wchar = yes; then
 
-      else
-        { echo "$as_me:$LINENO: checking whether we can build an HP-UX dll" >&5
-echo $ECHO_N "checking whether we can build an HP-UX dll... $ECHO_C" >&6; }
-if test "${ac_cv_c_dll_hpux+set}" = set; then
+cat >>confdefs.h <<\_ACEOF
+#define CC_FLAG_SHORT_WCHAR "-fshort-wchar"
+_ACEOF
+
+fi
+
+  { echo "$as_me:$LINENO: checking whether the compiler supports -fno-strict-aliasing" >&5
+echo $ECHO_N "checking whether the compiler supports -fno-strict-aliasing... $ECHO_C" >&6; }
+if test "${ac_cv_cflags__fno_strict_aliasing+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
   ac_wine_try_cflags_saved=$CFLAGS
-CFLAGS="$CFLAGS -shared"
+CFLAGS="$CFLAGS -fno-strict-aliasing"
 cat >conftest.$ac_ext <<_ACEOF
-void myfunc() {}
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
 if { (ac_try="$ac_link"
@@ -14088,286 +14168,42 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_c_dll_hpux="yes"
+  ac_cv_cflags__fno_strict_aliasing=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_c_dll_hpux="no"
+       ac_cv_cflags__fno_strict_aliasing=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
 CFLAGS=$ac_wine_try_cflags_saved
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_c_dll_hpux" >&5
-echo "${ECHO_T}$ac_cv_c_dll_hpux" >&6; }
-        if test "$ac_cv_c_dll_hpux" = "yes"
-        then
-          LIBEXT="sl"
-          DLLEXT=".sl"
-          LDDLLFLAGS="-shared -fPIC"
-          LDSHARED="\$(CC) -shared"
-        fi
-      fi
-    fi
-
-        CROSSTEST=""
+{ echo "$as_me:$LINENO: result: $ac_cv_cflags__fno_strict_aliasing" >&5
+echo "${ECHO_T}$ac_cv_cflags__fno_strict_aliasing" >&6; }
+if test $ac_cv_cflags__fno_strict_aliasing = yes; then
+  EXTRACFLAGS="$EXTRACFLAGS -fno-strict-aliasing"
+fi
 
-    if test "$cross_compiling" = "no"
-    then
-      for ac_prog in i586-mingw32msvc-gcc i386-mingw32msvc-gcc i386-mingw32-gcc mingw32-gcc mingw-gcc
-do
-  # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CROSSCC+set}" = set; then
+  { echo "$as_me:$LINENO: checking whether the compiler supports -Wdeclaration-after-statement" >&5
+echo $ECHO_N "checking whether the compiler supports -Wdeclaration-after-statement... $ECHO_C" >&6; }
+if test "${ac_cv_cflags__Wdeclaration_after_statement+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  if test -n "$CROSSCC"; then
-  ac_cv_prog_CROSSCC="$CROSSCC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_CROSSCC="$ac_prog"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-CROSSCC=$ac_cv_prog_CROSSCC
-if test -n "$CROSSCC"; then
-  { echo "$as_me:$LINENO: result: $CROSSCC" >&5
-echo "${ECHO_T}$CROSSCC" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -Wdeclaration-after-statement"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
 
-  test -n "$CROSSCC" && break
-done
-test -n "$CROSSCC" || CROSSCC="false"
+int
+main ()
+{
 
-      for ac_prog in i586-mingw32msvc-dlltool i386-mingw32msvc-dlltool i386-mingw32-dlltool mingw32-dlltool mingw-dlltool
-do
-  # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_DLLTOOL+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$DLLTOOL"; then
-  ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_DLLTOOL="$ac_prog"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-DLLTOOL=$ac_cv_prog_DLLTOOL
-if test -n "$DLLTOOL"; then
-  { echo "$as_me:$LINENO: result: $DLLTOOL" >&5
-echo "${ECHO_T}$DLLTOOL" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-  test -n "$DLLTOOL" && break
-done
-test -n "$DLLTOOL" || DLLTOOL="false"
-
-      for ac_prog in i586-mingw32msvc-windres i386-mingw32msvc-windres i386-mingw32-windres mingw32-windres mingw-windres
-do
-  # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_prog_CROSSWINDRES+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  if test -n "$CROSSWINDRES"; then
-  ac_cv_prog_CROSSWINDRES="$CROSSWINDRES" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_prog_CROSSWINDRES="$ac_prog"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-fi
-fi
-CROSSWINDRES=$ac_cv_prog_CROSSWINDRES
-if test -n "$CROSSWINDRES"; then
-  { echo "$as_me:$LINENO: result: $CROSSWINDRES" >&5
-echo "${ECHO_T}$CROSSWINDRES" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-  test -n "$CROSSWINDRES" && break
-done
-test -n "$CROSSWINDRES" || CROSSWINDRES="false"
-
-      if test "$CROSSCC" != "false"; then CROSSTEST="\$(CROSSTEST)"; fi
-    fi
-    ;;
-esac
-
-if test "$LIBEXT" = "a"; then
-  { { echo "$as_me:$LINENO: error: could not find a way to build shared libraries.
-It is currently not possible to build Wine without shared library
-(.so) support to allow transparent switch between .so and .dll files.
-If you are using Linux, you will need a newer binutils.
-" >&5
-echo "$as_me: error: could not find a way to build shared libraries.
-It is currently not possible to build Wine without shared library
-(.so) support to allow transparent switch between .so and .dll files.
-If you are using Linux, you will need a newer binutils.
-" >&2;}
-   { (exit 1); exit 1; }; }
-fi
-
-case $build_os in
-  cygwin*|mingw32*)
-    LDPATH="PATH=\"\$(TOOLSDIR)/libs/wine:\$\$PATH\""
- ;;
-  darwin*|macosx*)
-    LDPATH="DYLD_LIBRARY_PATH=\"\$(TOOLSDIR)/libs/wine:\$\$DYLD_LIBRARY_PATH\""
- ;;
-  *)
-    LDPATH="LD_LIBRARY_PATH=\"\$(TOOLSDIR)/libs/wine:\$\$LD_LIBRARY_PATH\""
- ;;
-esac
-
-case $host_os in
-  mingw32*)
-    CRTLIBS="-lmsvcrt"
-
-    SOCKETLIBS="-lws2_32"
-
-    ;;
-esac
-
-MAIN_BINARY="wine-pthread"
-  case $host_cpu in
-  *i[3456789]86*)
-    case $host_os in
-      linux* | k*bsd*-gnu)
-        MAIN_BINARY="wine-glibc"
-
-        EXTRA_BINARIES="wine-kthread wine-pthread wine-preloader"
- ;;
-    esac
-    ;;
-esac
-
-
-if test "$LIBEXT" = "so" -o "$LIBEXT" = "dylib"
-then
-  # Extract the first word of "ldd", so it can be a program name with args.
-set dummy ldd; ac_word=$2
-{ echo "$as_me:$LINENO: checking for $ac_word" >&5
-echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
-if test "${ac_cv_path_LDD+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  case $LDD in
-  [\\/]* | ?:[\\/]*)
-  ac_cv_path_LDD="$LDD" # Let the user override the test with a path.
-  ;;
-  *)
-  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_dummy="/sbin:/usr/sbin:$PATH"
-for as_dir in $as_dummy
-do
-  IFS=$as_save_IFS
-  test -z "$as_dir" && as_dir=.
-  for ac_exec_ext in '' $ac_executable_extensions; do
-  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
-    ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext"
-    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
-    break 2
-  fi
-done
-done
-IFS=$as_save_IFS
-
-  test -z "$ac_cv_path_LDD" && ac_cv_path_LDD="true"
-  ;;
-esac
-fi
-LDD=$ac_cv_path_LDD
-if test -n "$LDD"; then
-  { echo "$as_me:$LINENO: result: $LDD" >&5
-echo "${ECHO_T}$LDD" >&6; }
-else
-  { echo "$as_me:$LINENO: result: no" >&5
-echo "${ECHO_T}no" >&6; }
-fi
-
-
-{ echo "$as_me:$LINENO: checking for -lX11 soname" >&5
-echo $ECHO_N "checking for -lX11 soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_X11+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lX11 $X_LIBS $X_EXTRA_LIBS $LIBS"
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* 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 XCreateWindow ();
-int
-main ()
-{
-return XCreateWindow ();
   ;
   return 0;
 }
@@ -14390,60 +14226,42 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_X11=`otool -L conftest$ac_exeext | grep libX11\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libX11\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_X11=`$ac_cv_path_LDD conftest$ac_exeext | grep libX11\\.so | sed -e "s/^.*\(libX11\.so[^       ]*\).*$/\1/"';2,$d'` ;;
-  esac
-  if test "x$ac_cv_lib_soname_X11" = "x"
-  then
-     ac_cv_lib_soname_X11="libX11.$LIBEXT"
-  fi
+  ac_cv_cflags__Wdeclaration_after_statement=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_X11="libX11.$LIBEXT"
+       ac_cv_cflags__Wdeclaration_after_statement=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+CFLAGS=$ac_wine_try_cflags_saved
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_X11" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_X11" >&6; }
-if test "${ac_cv_lib_soname_X11+set}" = set; then
-
-cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBX11 "$ac_cv_lib_soname_X11"
-_ACEOF
-
+{ echo "$as_me:$LINENO: result: $ac_cv_cflags__Wdeclaration_after_statement" >&5
+echo "${ECHO_T}$ac_cv_cflags__Wdeclaration_after_statement" >&6; }
+if test $ac_cv_cflags__Wdeclaration_after_statement = yes; then
+  EXTRACFLAGS="$EXTRACFLAGS -Wdeclaration-after-statement"
 fi
 
-  { echo "$as_me:$LINENO: checking for -lXext soname" >&5
-echo $ECHO_N "checking for -lXext soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_Xext+set}" = set; then
+  { echo "$as_me:$LINENO: checking whether the compiler supports -Wwrite-strings" >&5
+echo $ECHO_N "checking whether the compiler supports -Wwrite-strings... $ECHO_C" >&6; }
+if test "${ac_cv_cflags__Wwrite_strings+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lXext $X_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
-  cat >conftest.$ac_ext <<_ACEOF
+  ac_wine_try_cflags_saved=$CFLAGS
+CFLAGS="$CFLAGS -Wwrite-strings"
+cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 XextCreateExtension ();
 int
 main ()
 {
-return XextCreateExtension ();
+
   ;
   return 0;
 }
@@ -14466,72 +14284,55 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_Xext=`otool -L conftest$ac_exeext | grep libXext\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libXext\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_Xext=`$ac_cv_path_LDD conftest$ac_exeext | grep libXext\\.so | sed -e "s/^.*\(libXext\.so[^    ]*\).*$/\1/"';2,$d'` ;;
-  esac
-  if test "x$ac_cv_lib_soname_Xext" = "x"
-  then
-     ac_cv_lib_soname_Xext="libXext.$LIBEXT"
-  fi
+  ac_cv_cflags__Wwrite_strings=yes
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_Xext="libXext.$LIBEXT"
+       ac_cv_cflags__Wwrite_strings=no
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+CFLAGS=$ac_wine_try_cflags_saved
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_Xext" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_Xext" >&6; }
-if test "${ac_cv_lib_soname_Xext+set}" = set; then
-
-cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBXEXT "$ac_cv_lib_soname_Xext"
-_ACEOF
-
+{ echo "$as_me:$LINENO: result: $ac_cv_cflags__Wwrite_strings" >&5
+echo "${ECHO_T}$ac_cv_cflags__Wwrite_strings" >&6; }
+if test $ac_cv_cflags__Wwrite_strings = yes; then
+  EXTRACFLAGS="$EXTRACFLAGS -Wwrite-strings"
 fi
 
-  { echo "$as_me:$LINENO: checking for -lXi soname" >&5
-echo $ECHO_N "checking for -lXi soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_Xi+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lXi $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
-  cat >conftest.$ac_ext <<_ACEOF
+
+    saved_CFLAGS="$CFLAGS"
+  CFLAGS="$CFLAGS -Wpointer-arith -Werror"
+  { echo "$as_me:$LINENO: checking for broken string.h that generates warnings" >&5
+echo $ECHO_N "checking for broken string.h that generates warnings... $ECHO_C" >&6; }
+if test "${ac_cv_c_string_h_warnings+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 XOpenDevice ();
+#include <string.h>
 int
 main ()
 {
-return XOpenDevice ();
+
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -14540,44 +14341,34 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_Xi=`otool -L conftest$ac_exeext | grep libXi\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libXi\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_Xi=`$ac_cv_path_LDD conftest$ac_exeext | grep libXi\\.so | sed -e "s/^.*\(libXi\.so[^  ]*\).*$/\1/"';2,$d'` ;;
-  esac
-  if test "x$ac_cv_lib_soname_Xi" = "x"
-  then
-     ac_cv_lib_soname_Xi="libXi.$LIBEXT"
-  fi
+       } && test -s conftest.$ac_objext; then
+  ac_cv_c_string_h_warnings=no
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_Xi="libXi.$LIBEXT"
+       ac_cv_c_string_h_warnings=yes
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_Xi" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_Xi" >&6; }
-if test "${ac_cv_lib_soname_Xi+set}" = set; then
-
-cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBXI "$ac_cv_lib_soname_Xi"
-_ACEOF
+{ echo "$as_me:$LINENO: result: $ac_cv_c_string_h_warnings" >&5
+echo "${ECHO_T}$ac_cv_c_string_h_warnings" >&6; }
+  CFLAGS="$saved_CFLAGS"
+  if test "$ac_cv_c_string_h_warnings" = "no"
+  then
+    EXTRACFLAGS="$EXTRACFLAGS -Wpointer-arith"
+  fi
 
-fi
+  BUILTINFLAG=""
 
-  { echo "$as_me:$LINENO: checking for -lXinerama soname" >&5
-echo $ECHO_N "checking for -lXinerama soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_Xinerama+set}" = set; then
+  saved_CFLAGS="$CFLAGS"
+  CFLAGS="$CFLAGS -Werror"
+  { echo "$as_me:$LINENO: checking for builtin wchar inlines" >&5
+echo $ECHO_N "checking for builtin wchar inlines... $ECHO_C" >&6; }
+if test "${ac_cv_c_builtin_wchar_ctype+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lXinerama $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -14585,29 +14376,22 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 XineramaQueryScreens ();
 int
 main ()
 {
-return XineramaQueryScreens ();
+int iswlower(unsigned short);
   ;
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
   *) ac_try_echo=$ac_try;;
 esac
 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
+  (eval "$ac_compile") 2>conftest.er1
   ac_status=$?
   grep -v '^ *+' conftest.er1 >conftest.err
   rm -f conftest.er1
@@ -14616,44 +14400,32 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
   (exit $ac_status); } && {
         test -z "$ac_c_werror_flag" ||
         test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_Xinerama=`otool -L conftest$ac_exeext | grep libXinerama\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libXinerama\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_Xinerama=`$ac_cv_path_LDD conftest$ac_exeext | grep libXinerama\\.so | sed -e "s/^.*\(libXinerama\.so[^        ]*\).*$/\1/"';2,$d'` ;;
-  esac
-  if test "x$ac_cv_lib_soname_Xinerama" = "x"
-  then
-     ac_cv_lib_soname_Xinerama="libXinerama.$LIBEXT"
-  fi
+       } && test -s conftest.$ac_objext; then
+  ac_cv_c_builtin_wchar_ctype=no
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_Xinerama="libXinerama.$LIBEXT"
+       ac_cv_c_builtin_wchar_ctype=yes
 fi
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_Xinerama" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_Xinerama" >&6; }
-if test "${ac_cv_lib_soname_Xinerama+set}" = set; then
-
-cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBXINERAMA "$ac_cv_lib_soname_Xinerama"
-_ACEOF
-
+{ echo "$as_me:$LINENO: result: $ac_cv_c_builtin_wchar_ctype" >&5
+echo "${ECHO_T}$ac_cv_c_builtin_wchar_ctype" >&6; }
+  CFLAGS="$saved_CFLAGS"
+  if test "$ac_cv_c_builtin_wchar_ctype" = "yes"
+  then
+    BUILTINFLAG="-fno-builtin"
+  fi
 fi
 
-  { echo "$as_me:$LINENO: checking for -lXrender soname" >&5
-echo $ECHO_N "checking for -lXrender soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_Xrender+set}" = set; then
+
+{ echo "$as_me:$LINENO: checking how to define a function in assembly code" >&5
+echo $ECHO_N "checking how to define a function in assembly code... $ECHO_C" >&6; }
+if test "${ac_cv_asm_func_def+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lXrender $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -14661,17 +14433,10 @@ cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 XRenderQueryExtension ();
 int
 main ()
 {
-return XRenderQueryExtension ();
+asm("\t.globl _ac_test\n\t.def _ac_test; .scl 2; .type 32; .endef\n_ac_test:\t.long 0");
   ;
   return 0;
 }
@@ -14694,60 +14459,22 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_Xrender=`otool -L conftest$ac_exeext | grep libXrender\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libXrender\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_Xrender=`$ac_cv_path_LDD conftest$ac_exeext | grep libXrender\\.so | sed -e "s/^.*\(libXrender\.so[^   ]*\).*$/\1/"';2,$d'` ;;
-  esac
-  if test "x$ac_cv_lib_soname_Xrender" = "x"
-  then
-     ac_cv_lib_soname_Xrender="libXrender.$LIBEXT"
-  fi
+  ac_cv_asm_func_def=".def"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_Xrender="libXrender.$LIBEXT"
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_Xrender" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_Xrender" >&6; }
-if test "${ac_cv_lib_soname_Xrender+set}" = set; then
-
-cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBXRENDER "$ac_cv_lib_soname_Xrender"
-_ACEOF
-
-fi
-
-  { echo "$as_me:$LINENO: checking for -lXrandr soname" >&5
-echo $ECHO_N "checking for -lXrandr soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_Xrandr+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lXrandr $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
-  cat >conftest.$ac_ext <<_ACEOF
+       cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 XRRQueryExtension ();
 int
 main ()
 {
-return XRRQueryExtension ();
+asm("\t.globl _ac_test\n\t.type _ac_test,@function\n_ac_test:\t.long 0");
   ;
   return 0;
 }
@@ -14770,60 +14497,22 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_Xrandr=`otool -L conftest$ac_exeext | grep libXrandr\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libXrandr\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_Xrandr=`$ac_cv_path_LDD conftest$ac_exeext | grep libXrandr\\.so | sed -e "s/^.*\(libXrandr\.so[^      ]*\).*$/\1/"';2,$d'` ;;
-  esac
-  if test "x$ac_cv_lib_soname_Xrandr" = "x"
-  then
-     ac_cv_lib_soname_Xrandr="libXrandr.$LIBEXT"
-  fi
+  ac_cv_asm_func_def=".type @function"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_Xrandr="libXrandr.$LIBEXT"
-fi
-
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_Xrandr" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_Xrandr" >&6; }
-if test "${ac_cv_lib_soname_Xrandr+set}" = set; then
-
-cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBXRANDR "$ac_cv_lib_soname_Xrandr"
-_ACEOF
-
-fi
-
-  { echo "$as_me:$LINENO: checking for -lfreetype soname" >&5
-echo $ECHO_N "checking for -lfreetype soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_freetype+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lfreetype $X_LIBS $LIBS"
-  cat >conftest.$ac_ext <<_ACEOF
+       cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 FT_Init_FreeType ();
 int
 main ()
 {
-return FT_Init_FreeType ();
+asm("\t.globl _ac_test\n\t.type _ac_test,2\n_ac_test:\t.long 0");
   ;
   return 0;
 }
@@ -14846,60 +14535,70 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_freetype=`otool -L conftest$ac_exeext | grep libfreetype\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libfreetype\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_freetype=`$ac_cv_path_LDD conftest$ac_exeext | grep libfreetype\\.so | sed -e "s/^.*\(libfreetype\.so[^        ]*\).*$/\1/"';2,$d'` ;;
-  esac
-  if test "x$ac_cv_lib_soname_freetype" = "x"
-  then
-     ac_cv_lib_soname_freetype="libfreetype.$LIBEXT"
-  fi
+  ac_cv_asm_func_def=".type 2"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_freetype="libfreetype.$LIBEXT"
+       ac_cv_asm_func_def="unknown"
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_freetype" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_freetype" >&6; }
-if test "${ac_cv_lib_soname_freetype+set}" = set; then
 
-cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBFREETYPE "$ac_cv_lib_soname_freetype"
-_ACEOF
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+fi
 
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_asm_func_def" >&5
+echo "${ECHO_T}$ac_cv_asm_func_def" >&6; }
 
-  { echo "$as_me:$LINENO: checking for -lGL soname" >&5
-echo $ECHO_N "checking for -lGL soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_GL+set}" = set; then
+
+
+case "$ac_cv_asm_func_def" in
+  ".def")
+     cat >>confdefs.h <<\_ACEOF
+#define __ASM_FUNC(name) ".def " __ASM_NAME(name) "; .scl 2; .type 32; .endef"
+_ACEOF
+ ;;
+  ".type @function")
+     cat >>confdefs.h <<\_ACEOF
+#define __ASM_FUNC(name) ".type " __ASM_NAME(name) ",@function"
+_ACEOF
+ ;;
+  ".type 2")
+     cat >>confdefs.h <<\_ACEOF
+#define __ASM_FUNC(name) ".type " __ASM_NAME(name) ",2"
+_ACEOF
+ ;;
+  *)
+     cat >>confdefs.h <<\_ACEOF
+#define __ASM_FUNC(name) ""
+_ACEOF
+ ;;
+esac
+
+
+{ echo "$as_me:$LINENO: checking whether external symbols need an underscore prefix" >&5
+echo $ECHO_N "checking whether external symbols need an underscore prefix... $ECHO_C" >&6; }
+if test "${ac_cv_c_extern_prefix+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lGL $X_LIBS $X_EXTRA_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* 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 glXQueryExtension ();
+extern int ac_test;
 int
 main ()
 {
-return glXQueryExtension ();
+asm(".globl _ac_test\n_ac_test:\t.long 0"); if (ac_test) return 1
   ;
   return 0;
 }
@@ -14922,42 +14621,90 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_GL=`otool -L conftest$ac_exeext | grep libGL\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libGL\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_GL=`$ac_cv_path_LDD conftest$ac_exeext | grep libGL\\.so | sed -e "s/^.*\(libGL\.so[^  ]*\).*$/\1/"';2,$d'` ;;
-  esac
-  if test "x$ac_cv_lib_soname_GL" = "x"
-  then
-     ac_cv_lib_soname_GL="libGL.$LIBEXT"
-  fi
+  ac_cv_c_extern_prefix="yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_GL="libGL.$LIBEXT"
+       ac_cv_c_extern_prefix="no"
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_GL" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_GL" >&6; }
-if test "${ac_cv_lib_soname_GL+set}" = set; then
+{ echo "$as_me:$LINENO: result: $ac_cv_c_extern_prefix" >&5
+echo "${ECHO_T}$ac_cv_c_extern_prefix" >&6; }
 
-cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBGL "$ac_cv_lib_soname_GL"
-_ACEOF
 
-fi
 
-  { echo "$as_me:$LINENO: checking for -lhal soname" >&5
-echo $ECHO_N "checking for -lhal soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_hal+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
+if test "$ac_cv_c_extern_prefix" = "yes"
+then
+  cat >>confdefs.h <<\_ACEOF
+#define __ASM_NAME(name) "_" name
+_ACEOF
+
+else
+  cat >>confdefs.h <<\_ACEOF
+#define __ASM_NAME(name) name
+_ACEOF
+
+fi
+
+
+LDPATH=""
+
+case $build_os in
+  cygwin*|mingw32*)
+    LDPATH="PATH=\"\$(TOOLSDIR)/libs/wine:\$\$PATH\""
+    ;;
+  darwin*|macosx*)
+    ;;
+  linux*|solaris*)      if test -z "$LDRPATH_LOCAL"
+    then
+      LDPATH="LD_LIBRARY_PATH=\"\$(TOOLSDIR)/libs/wine:\$\$LD_LIBRARY_PATH\""
+    fi
+    ;;
+  *)
+    LDPATH="LD_LIBRARY_PATH=\"\$(TOOLSDIR)/libs/wine:\$\$LD_LIBRARY_PATH\""
+    ;;
+esac
+
+case $host_os in
+  mingw32*)
+    CRTLIBS="-lmsvcrt"
+
+    SOCKETLIBS="-lws2_32"
+
+    ;;
+esac
+
+MAIN_BINARY="wine-pthread"
+  case $host_cpu in
+  *i[3456789]86*)
+    case $host_os in
+      linux* | k*bsd*-gnu)
+        MAIN_BINARY="wine-glibc"
+
+        EXTRA_BINARIES="wine-kthread wine-pthread wine-preloader"
+ ;;
+    esac
+    ;;
+esac
+
+
+
+cat >>confdefs.h <<_ACEOF
+#define SONAME_EXT ".$LIBEXT"
+_ACEOF
+
+
+{ echo "$as_me:$LINENO: checking for -lX11" >&5
+echo $ECHO_N "checking for -lX11... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_X11+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lhal  $LIBS"
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lX11 $X_LIBS $X_EXTRA_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -14971,11 +14718,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char libhal_ctx_new ();
+char XCreateWindow ();
 int
 main ()
 {
-return libhal_ctx_new ();
+return XCreateWindow ();
   ;
   return 0;
 }
@@ -14999,41 +14746,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
   case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_hal=`otool -L conftest$ac_exeext | grep libhal\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libhal\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_hal=`$ac_cv_path_LDD conftest$ac_exeext | grep libhal\\.so | sed -e "s/^.*\(libhal\.so[^       ]*\).*$/\1/"';2,$d'` ;;
+    dll) ;;
+    dylib) ac_cv_lib_soname_X11=`otool -L conftest$ac_exeext | grep "libX11\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libX11\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_X11=`$ac_cv_path_LDD conftest$ac_exeext | grep "libX11\\.$LIBEXT" | sed -e "s/^.*\(libX11\.$LIBEXT[^    ]*\).*$/\1/"';2,$d'` ;;
   esac
-  if test "x$ac_cv_lib_soname_hal" = "x"
-  then
-     ac_cv_lib_soname_hal="libhal.$LIBEXT"
-  fi
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_hal="libhal.$LIBEXT"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_hal" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_hal" >&6; }
-if test "${ac_cv_lib_soname_hal+set}" = set; then
+if test "x$ac_cv_lib_soname_X11" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_X11" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_X11" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBHAL "$ac_cv_lib_soname_hal"
+#define SONAME_LIBX11 "$ac_cv_lib_soname_X11"
 _ACEOF
 
+
 fi
 
-  { echo "$as_me:$LINENO: checking for -ltxc_dxtn soname" >&5
-echo $ECHO_N "checking for -ltxc_dxtn soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_txc_dxtn+set}" = set; then
+{ echo "$as_me:$LINENO: checking for -lXext" >&5
+echo $ECHO_N "checking for -lXext... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_Xext+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-ltxc_dxtn  $LIBS"
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lXext $X_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -15047,11 +14796,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char fetch_2d_texel_rgba_dxt1 ();
+char XextCreateExtension ();
 int
 main ()
 {
-return fetch_2d_texel_rgba_dxt1 ();
+return XextCreateExtension ();
   ;
   return 0;
 }
@@ -15075,41 +14824,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
   case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_txc_dxtn=`otool -L conftest$ac_exeext | grep libtxc_dxtn\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libtxc_dxtn\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_txc_dxtn=`$ac_cv_path_LDD conftest$ac_exeext | grep libtxc_dxtn\\.so | sed -e "s/^.*\(libtxc_dxtn\.so[^        ]*\).*$/\1/"';2,$d'` ;;
+    dll) ;;
+    dylib) ac_cv_lib_soname_Xext=`otool -L conftest$ac_exeext | grep "libXext\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libXext\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_Xext=`$ac_cv_path_LDD conftest$ac_exeext | grep "libXext\\.$LIBEXT" | sed -e "s/^.*\(libXext\.$LIBEXT[^         ]*\).*$/\1/"';2,$d'` ;;
   esac
-  if test "x$ac_cv_lib_soname_txc_dxtn" = "x"
-  then
-     ac_cv_lib_soname_txc_dxtn="libtxc_dxtn.$LIBEXT"
-  fi
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_txc_dxtn="libtxc_dxtn.$LIBEXT"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_txc_dxtn" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_txc_dxtn" >&6; }
-if test "${ac_cv_lib_soname_txc_dxtn+set}" = set; then
+if test "x$ac_cv_lib_soname_Xext" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_Xext" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_Xext" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBTXC_DXTN "$ac_cv_lib_soname_txc_dxtn"
+#define SONAME_LIBXEXT "$ac_cv_lib_soname_Xext"
 _ACEOF
 
+
 fi
 
-  { echo "$as_me:$LINENO: checking for -lcups soname" >&5
-echo $ECHO_N "checking for -lcups soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_cups+set}" = set; then
+{ echo "$as_me:$LINENO: checking for -lXi" >&5
+echo $ECHO_N "checking for -lXi... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_Xi+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lcups  $LIBS"
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lXi $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -15123,11 +14874,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char cupsGetDefault ();
+char XOpenDevice ();
 int
 main ()
 {
-return cupsGetDefault ();
+return XOpenDevice ();
   ;
   return 0;
 }
@@ -15151,41 +14902,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
   case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_cups=`otool -L conftest$ac_exeext | grep libcups\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libcups\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_cups=`$ac_cv_path_LDD conftest$ac_exeext | grep libcups\\.so | sed -e "s/^.*\(libcups\.so[^    ]*\).*$/\1/"';2,$d'` ;;
+    dll) ;;
+    dylib) ac_cv_lib_soname_Xi=`otool -L conftest$ac_exeext | grep "libXi\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libXi\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_Xi=`$ac_cv_path_LDD conftest$ac_exeext | grep "libXi\\.$LIBEXT" | sed -e "s/^.*\(libXi\.$LIBEXT[^       ]*\).*$/\1/"';2,$d'` ;;
   esac
-  if test "x$ac_cv_lib_soname_cups" = "x"
-  then
-     ac_cv_lib_soname_cups="libcups.$LIBEXT"
-  fi
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_cups="libcups.$LIBEXT"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_cups" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_cups" >&6; }
-if test "${ac_cv_lib_soname_cups+set}" = set; then
+if test "x$ac_cv_lib_soname_Xi" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_Xi" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_Xi" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBCUPS "$ac_cv_lib_soname_cups"
+#define SONAME_LIBXI "$ac_cv_lib_soname_Xi"
 _ACEOF
 
+
 fi
 
-  { echo "$as_me:$LINENO: checking for -ljack soname" >&5
-echo $ECHO_N "checking for -ljack soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_jack+set}" = set; then
+{ echo "$as_me:$LINENO: checking for -lXinerama" >&5
+echo $ECHO_N "checking for -lXinerama... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_Xinerama+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-ljack  $LIBS"
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lXinerama $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -15199,11 +14952,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char jack_client_new ();
+char XineramaQueryScreens ();
 int
 main ()
 {
-return jack_client_new ();
+return XineramaQueryScreens ();
   ;
   return 0;
 }
@@ -15227,41 +14980,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
   case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_jack=`otool -L conftest$ac_exeext | grep libjack\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libjack\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_jack=`$ac_cv_path_LDD conftest$ac_exeext | grep libjack\\.so | sed -e "s/^.*\(libjack\.so[^    ]*\).*$/\1/"';2,$d'` ;;
+    dll) ;;
+    dylib) ac_cv_lib_soname_Xinerama=`otool -L conftest$ac_exeext | grep "libXinerama\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libXinerama\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_Xinerama=`$ac_cv_path_LDD conftest$ac_exeext | grep "libXinerama\\.$LIBEXT" | sed -e "s/^.*\(libXinerama\.$LIBEXT[^     ]*\).*$/\1/"';2,$d'` ;;
   esac
-  if test "x$ac_cv_lib_soname_jack" = "x"
-  then
-     ac_cv_lib_soname_jack="libjack.$LIBEXT"
-  fi
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_jack="libjack.$LIBEXT"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_jack" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_jack" >&6; }
-if test "${ac_cv_lib_soname_jack+set}" = set; then
+if test "x$ac_cv_lib_soname_Xinerama" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_Xinerama" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_Xinerama" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBJACK "$ac_cv_lib_soname_jack"
+#define SONAME_LIBXINERAMA "$ac_cv_lib_soname_Xinerama"
 _ACEOF
 
+
 fi
 
-  { echo "$as_me:$LINENO: checking for -lfontconfig soname" >&5
-echo $ECHO_N "checking for -lfontconfig soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_fontconfig+set}" = set; then
+{ echo "$as_me:$LINENO: checking for -lXrender" >&5
+echo $ECHO_N "checking for -lXrender... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_Xrender+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lfontconfig  $LIBS"
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lXrender $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -15275,11 +15030,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char FcInit ();
+char XRenderQueryExtension ();
 int
 main ()
 {
-return FcInit ();
+return XRenderQueryExtension ();
   ;
   return 0;
 }
@@ -15303,41 +15058,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
   case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_fontconfig=`otool -L conftest$ac_exeext | grep libfontconfig\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libfontconfig\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_fontconfig=`$ac_cv_path_LDD conftest$ac_exeext | grep libfontconfig\\.so | sed -e "s/^.*\(libfontconfig\.so[^  ]*\).*$/\1/"';2,$d'` ;;
+    dll) ;;
+    dylib) ac_cv_lib_soname_Xrender=`otool -L conftest$ac_exeext | grep "libXrender\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libXrender\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_Xrender=`$ac_cv_path_LDD conftest$ac_exeext | grep "libXrender\\.$LIBEXT" | sed -e "s/^.*\(libXrender\.$LIBEXT[^        ]*\).*$/\1/"';2,$d'` ;;
   esac
-  if test "x$ac_cv_lib_soname_fontconfig" = "x"
-  then
-     ac_cv_lib_soname_fontconfig="libfontconfig.$LIBEXT"
-  fi
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_fontconfig="libfontconfig.$LIBEXT"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_fontconfig" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_fontconfig" >&6; }
-if test "${ac_cv_lib_soname_fontconfig+set}" = set; then
+if test "x$ac_cv_lib_soname_Xrender" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_Xrender" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_Xrender" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBFONTCONFIG "$ac_cv_lib_soname_fontconfig"
+#define SONAME_LIBXRENDER "$ac_cv_lib_soname_Xrender"
 _ACEOF
 
+
 fi
 
-  { echo "$as_me:$LINENO: checking for -lssl soname" >&5
-echo $ECHO_N "checking for -lssl soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_ssl+set}" = set; then
+{ echo "$as_me:$LINENO: checking for -lXrandr" >&5
+echo $ECHO_N "checking for -lXrandr... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_Xrandr+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lssl  $LIBS"
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lXrandr $X_LIBS -lXext -lX11 $X_EXTRA_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -15351,11 +15108,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char SSL_library_init ();
+char XRRQueryExtension ();
 int
 main ()
 {
-return SSL_library_init ();
+return XRRQueryExtension ();
   ;
   return 0;
 }
@@ -15379,41 +15136,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
   case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_ssl=`otool -L conftest$ac_exeext | grep libssl\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libssl\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_ssl=`$ac_cv_path_LDD conftest$ac_exeext | grep libssl\\.so | sed -e "s/^.*\(libssl\.so[^       ]*\).*$/\1/"';2,$d'` ;;
+    dll) ;;
+    dylib) ac_cv_lib_soname_Xrandr=`otool -L conftest$ac_exeext | grep "libXrandr\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libXrandr\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_Xrandr=`$ac_cv_path_LDD conftest$ac_exeext | grep "libXrandr\\.$LIBEXT" | sed -e "s/^.*\(libXrandr\.$LIBEXT[^   ]*\).*$/\1/"';2,$d'` ;;
   esac
-  if test "x$ac_cv_lib_soname_ssl" = "x"
-  then
-     ac_cv_lib_soname_ssl="libssl.$LIBEXT"
-  fi
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_ssl="libssl.$LIBEXT"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_ssl" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_ssl" >&6; }
-if test "${ac_cv_lib_soname_ssl+set}" = set; then
+if test "x$ac_cv_lib_soname_Xrandr" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_Xrandr" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_Xrandr" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBSSL "$ac_cv_lib_soname_ssl"
+#define SONAME_LIBXRANDR "$ac_cv_lib_soname_Xrandr"
 _ACEOF
 
+
 fi
 
-  { echo "$as_me:$LINENO: checking for -lcrypto soname" >&5
-echo $ECHO_N "checking for -lcrypto soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_crypto+set}" = set; then
+{ echo "$as_me:$LINENO: checking for -lXcursor" >&5
+echo $ECHO_N "checking for -lXcursor... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_Xcursor+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lcrypto  $LIBS"
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lXcursor $X_LIBS -lX11 $X_EXTRA_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -15427,11 +15186,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char BIO_new_socket ();
+char XcursorImageLoadCursor ();
 int
 main ()
 {
-return BIO_new_socket ();
+return XcursorImageLoadCursor ();
   ;
   return 0;
 }
@@ -15455,41 +15214,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
   case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_crypto=`otool -L conftest$ac_exeext | grep libcrypto\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libcrypto\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_crypto=`$ac_cv_path_LDD conftest$ac_exeext | grep libcrypto\\.so | sed -e "s/^.*\(libcrypto\.so[^      ]*\).*$/\1/"';2,$d'` ;;
+    dll) ;;
+    dylib) ac_cv_lib_soname_Xcursor=`otool -L conftest$ac_exeext | grep "libXcursor\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libXcursor\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_Xcursor=`$ac_cv_path_LDD conftest$ac_exeext | grep "libXcursor\\.$LIBEXT" | sed -e "s/^.*\(libXcursor\.$LIBEXT[^        ]*\).*$/\1/"';2,$d'` ;;
   esac
-  if test "x$ac_cv_lib_soname_crypto" = "x"
-  then
-     ac_cv_lib_soname_crypto="libcrypto.$LIBEXT"
-  fi
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_crypto="libcrypto.$LIBEXT"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_crypto" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_crypto" >&6; }
-if test "${ac_cv_lib_soname_crypto+set}" = set; then
+if test "x$ac_cv_lib_soname_Xcursor" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_Xcursor" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_Xcursor" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBCRYPTO "$ac_cv_lib_soname_crypto"
+#define SONAME_LIBXCURSOR "$ac_cv_lib_soname_Xcursor"
 _ACEOF
 
+
 fi
 
-  { echo "$as_me:$LINENO: checking for -lncurses soname" >&5
-echo $ECHO_N "checking for -lncurses soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_ncurses+set}" = set; then
+{ echo "$as_me:$LINENO: checking for -lfreetype" >&5
+echo $ECHO_N "checking for -lfreetype... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_freetype+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lncurses  $LIBS"
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lfreetype $X_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -15503,11 +15264,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char waddch ();
+char FT_Init_FreeType ();
 int
 main ()
 {
-return waddch ();
+return FT_Init_FreeType ();
   ;
   return 0;
 }
@@ -15531,41 +15292,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
   case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_ncurses=`otool -L conftest$ac_exeext | grep libncurses\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libncurses\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_ncurses=`$ac_cv_path_LDD conftest$ac_exeext | grep libncurses\\.so | sed -e "s/^.*\(libncurses\.so[^   ]*\).*$/\1/"';2,$d'` ;;
+    dll) ;;
+    dylib) ac_cv_lib_soname_freetype=`otool -L conftest$ac_exeext | grep "libfreetype\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libfreetype\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_freetype=`$ac_cv_path_LDD conftest$ac_exeext | grep "libfreetype\\.$LIBEXT" | sed -e "s/^.*\(libfreetype\.$LIBEXT[^     ]*\).*$/\1/"';2,$d'` ;;
   esac
-  if test "x$ac_cv_lib_soname_ncurses" = "x"
-  then
-     ac_cv_lib_soname_ncurses="libncurses.$LIBEXT"
-  fi
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_ncurses="libncurses.$LIBEXT"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_ncurses" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_ncurses" >&6; }
-if test "${ac_cv_lib_soname_ncurses+set}" = set; then
+if test "x$ac_cv_lib_soname_freetype" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_freetype" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_freetype" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBNCURSES "$ac_cv_lib_soname_ncurses"
+#define SONAME_LIBFREETYPE "$ac_cv_lib_soname_freetype"
 _ACEOF
 
+
 fi
 
-  { echo "$as_me:$LINENO: checking for -lcurses soname" >&5
-echo $ECHO_N "checking for -lcurses soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_curses+set}" = set; then
+{ echo "$as_me:$LINENO: checking for -lGL" >&5
+echo $ECHO_N "checking for -lGL... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_GL+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lcurses  $LIBS"
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-lGL $X_LIBS $X_EXTRA_LIBS $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -15579,11 +15342,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char waddch ();
+char glXQueryExtension ();
 int
 main ()
 {
-return waddch ();
+return glXQueryExtension ();
   ;
   return 0;
 }
@@ -15607,41 +15370,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
   case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_curses=`otool -L conftest$ac_exeext | grep libcurses\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libcurses\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_curses=`$ac_cv_path_LDD conftest$ac_exeext | grep libcurses\\.so | sed -e "s/^.*\(libcurses\.so[^      ]*\).*$/\1/"';2,$d'` ;;
+    dll) ;;
+    dylib) ac_cv_lib_soname_GL=`otool -L conftest$ac_exeext | grep "libGL\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libGL\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_GL=`$ac_cv_path_LDD conftest$ac_exeext | grep "libGL\\.$LIBEXT" | sed -e "s/^.*\(libGL\.$LIBEXT[^       ]*\).*$/\1/"';2,$d'` ;;
   esac
-  if test "x$ac_cv_lib_soname_curses" = "x"
-  then
-     ac_cv_lib_soname_curses="libcurses.$LIBEXT"
-  fi
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_curses="libcurses.$LIBEXT"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_curses" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_curses" >&6; }
-if test "${ac_cv_lib_soname_curses+set}" = set; then
+if test "x$ac_cv_lib_soname_GL" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_GL" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_GL" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBCURSES "$ac_cv_lib_soname_curses"
+#define SONAME_LIBGL "$ac_cv_lib_soname_GL"
 _ACEOF
 
+
 fi
 
-  { echo "$as_me:$LINENO: checking for -ljpeg soname" >&5
-echo $ECHO_N "checking for -ljpeg soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_jpeg+set}" = set; then
+{ echo "$as_me:$LINENO: checking for -ltxc_dxtn" >&5
+echo $ECHO_N "checking for -ltxc_dxtn... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_txc_dxtn+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-ljpeg  $LIBS"
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-ltxc_dxtn  $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -15655,11 +15420,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char jpeg_start_decompress ();
+char fetch_2d_texel_rgba_dxt1 ();
 int
 main ()
 {
-return jpeg_start_decompress ();
+return fetch_2d_texel_rgba_dxt1 ();
   ;
   return 0;
 }
@@ -15683,41 +15448,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
   case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_jpeg=`otool -L conftest$ac_exeext | grep libjpeg\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libjpeg\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_jpeg=`$ac_cv_path_LDD conftest$ac_exeext | grep libjpeg\\.so | sed -e "s/^.*\(libjpeg\.so[^    ]*\).*$/\1/"';2,$d'` ;;
+    dll) ;;
+    dylib) ac_cv_lib_soname_txc_dxtn=`otool -L conftest$ac_exeext | grep "libtxc_dxtn\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libtxc_dxtn\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_txc_dxtn=`$ac_cv_path_LDD conftest$ac_exeext | grep "libtxc_dxtn\\.$LIBEXT" | sed -e "s/^.*\(libtxc_dxtn\.$LIBEXT[^     ]*\).*$/\1/"';2,$d'` ;;
   esac
-  if test "x$ac_cv_lib_soname_jpeg" = "x"
-  then
-     ac_cv_lib_soname_jpeg="libjpeg.$LIBEXT"
-  fi
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_jpeg="libjpeg.$LIBEXT"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_jpeg" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_jpeg" >&6; }
-if test "${ac_cv_lib_soname_jpeg+set}" = set; then
+if test "x$ac_cv_lib_soname_txc_dxtn" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_txc_dxtn" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_txc_dxtn" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBJPEG "$ac_cv_lib_soname_jpeg"
+#define SONAME_LIBTXC_DXTN "$ac_cv_lib_soname_txc_dxtn"
 _ACEOF
 
+
 fi
 
-  { echo "$as_me:$LINENO: checking for -lcapi20 soname" >&5
-echo $ECHO_N "checking for -lcapi20 soname... $ECHO_C" >&6; }
-if test "${ac_cv_lib_soname_capi20+set}" = set; then
+{ echo "$as_me:$LINENO: checking for -ljpeg" >&5
+echo $ECHO_N "checking for -ljpeg... $ECHO_C" >&6; }
+if test "${ac_cv_lib_soname_jpeg+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_get_soname_save_LIBS=$LIBS
-LIBS="-lcapi20  $LIBS"
+  ac_check_soname_save_LIBS=$LIBS
+LIBS="-ljpeg  $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -15731,11 +15498,11 @@ cat >>conftest.$ac_ext <<_ACEOF
 #ifdef __cplusplus
 extern "C"
 #endif
-char capi20_isinstalled ();
+char jpeg_start_decompress ();
 int
 main ()
 {
-return capi20_isinstalled ();
+return jpeg_start_decompress ();
   ;
   return 0;
 }
@@ -15759,33 +15526,33 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
   case "$LIBEXT" in
-    dylib) ac_cv_lib_soname_capi20=`otool -L conftest$ac_exeext | grep libcapi20\\.[0-9A-Za-z.]*dylib | sed -e "s/^.*\/\(libcapi20\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
-    so) ac_cv_lib_soname_capi20=`$ac_cv_path_LDD conftest$ac_exeext | grep libcapi20\\.so | sed -e "s/^.*\(libcapi20\.so[^      ]*\).*$/\1/"';2,$d'` ;;
+    dll) ;;
+    dylib) ac_cv_lib_soname_jpeg=`otool -L conftest$ac_exeext | grep "libjpeg\\.[0-9A-Za-z.]*dylib" | sed -e "s/^.*\/\(libjpeg\.[0-9A-Za-z.]*dylib\).*$/\1/"';2,$d'` ;;
+    *) ac_cv_lib_soname_jpeg=`$ac_cv_path_LDD conftest$ac_exeext | grep "libjpeg\\.$LIBEXT" | sed -e "s/^.*\(libjpeg\.$LIBEXT[^         ]*\).*$/\1/"';2,$d'` ;;
   esac
-  if test "x$ac_cv_lib_soname_capi20" = "x"
-  then
-     ac_cv_lib_soname_capi20="libcapi20.$LIBEXT"
-  fi
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_soname_capi20="libcapi20.$LIBEXT"
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-  LIBS=$ac_get_soname_save_LIBS
+  LIBS=$ac_check_soname_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_soname_capi20" >&5
-echo "${ECHO_T}$ac_cv_lib_soname_capi20" >&6; }
-if test "${ac_cv_lib_soname_capi20+set}" = set; then
+if test "x$ac_cv_lib_soname_jpeg" = "x"; then
+  { echo "$as_me:$LINENO: result: not found" >&5
+echo "${ECHO_T}not found" >&6; }
+
+else
+  { echo "$as_me:$LINENO: result: $ac_cv_lib_soname_jpeg" >&5
+echo "${ECHO_T}$ac_cv_lib_soname_jpeg" >&6; }
 
 cat >>confdefs.h <<_ACEOF
-#define SONAME_LIBCAPI20 "$ac_cv_lib_soname_capi20"
+#define SONAME_LIBJPEG "$ac_cv_lib_soname_jpeg"
 _ACEOF
 
-fi
 
 fi
 
 
 
 
-
-
-
-
-
-
-
-
-
 
 
 
@@ -15873,7 +15631,6 @@ for ac_func in \
        asctime_r \
        chsize \
        clone \
-       connect \
        dlopen \
        epoll_create \
        ffs \
@@ -15885,22 +15642,14 @@ for ac_func in \
        ftruncate \
        futimes \
        futimesat \
-       getaddrinfo \
        getdirentries \
-       gethostbyname \
-       getnameinfo \
-       getnetbyname \
        getopt_long \
        getpagesize \
-       getprotobyname \
-       getprotobynumber \
        getpwuid \
-       getservbyport \
        gettid \
        gettimeofday \
        getuid \
-       inet_aton \
-       inet_network \
+       inet_pton \
        kqueue \
        lstat \
        memmove \
@@ -15915,7 +15664,6 @@ for ac_func in \
        rfork \
        sched_yield \
        select \
-       sendmsg \
        setrlimit \
        settimeofday \
        sigaltstack \
 
 fi
 
-if test "$ac_cv_func_gethostbyname" = no
-then
-
-{ echo "$as_me:$LINENO: checking for gethostbyname in -lnsl" >&5
-echo $ECHO_N "checking for gethostbyname in -lnsl... $ECHO_C" >&6; }
-if test "${ac_cv_lib_nsl_gethostbyname+set}" = set; then
+{ echo "$as_me:$LINENO: checking for library containing gethostbyname" >&5
+echo $ECHO_N "checking for library containing gethostbyname... $ECHO_C" >&6; }
+if test "${ac_cv_search_gethostbyname+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lnsl  $LIBS"
+  ac_func_search_save_LIBS=$LIBS
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -16303,7 +16047,14 @@ return gethostbyname ();
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
+for ac_lib in '' nsl; do
+  if test -z "$ac_lib"; then
+    ac_res="none required"
+  else
+    ac_res=-l$ac_lib
+    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
+  fi
+  rm -f conftest.$ac_objext conftest$ac_exeext
 if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
@@ -16321,41 +16072,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_nsl_gethostbyname=yes
+  ac_cv_search_gethostbyname=$ac_res
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_nsl_gethostbyname=no
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+      conftest$ac_exeext
+  if test "${ac_cv_search_gethostbyname+set}" = set; then
+  break
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_gethostbyname" >&5
-echo "${ECHO_T}$ac_cv_lib_nsl_gethostbyname" >&6; }
-if test $ac_cv_lib_nsl_gethostbyname = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define HAVE_LIBNSL 1
-_ACEOF
-
-  LIBS="-lnsl $LIBS"
-
+done
+if test "${ac_cv_search_gethostbyname+set}" = set; then
+  :
+else
+  ac_cv_search_gethostbyname=no
+fi
+rm conftest.$ac_ext
+LIBS=$ac_func_search_save_LIBS
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname" >&5
+echo "${ECHO_T}$ac_cv_search_gethostbyname" >&6; }
+ac_res=$ac_cv_search_gethostbyname
+if test "$ac_res" != no; then
+  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
 
 fi
 
-if test "$ac_cv_func_connect" = no
-then
 
-{ echo "$as_me:$LINENO: checking for connect in -lsocket" >&5
-echo $ECHO_N "checking for connect in -lsocket... $ECHO_C" >&6; }
-if test "${ac_cv_lib_socket_connect+set}" = set; then
+{ echo "$as_me:$LINENO: checking for library containing connect" >&5
+echo $ECHO_N "checking for library containing connect... $ECHO_C" >&6; }
+if test "${ac_cv_search_connect+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsocket  $LIBS"
+  ac_func_search_save_LIBS=$LIBS
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -16378,7 +16131,14 @@ return connect ();
   return 0;
 }
 _ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
+for ac_lib in '' socket; do
+  if test -z "$ac_lib"; then
+    ac_res="none required"
+  else
+    ac_res=-l$ac_lib
+    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
+  fi
+  rm -f conftest.$ac_objext conftest$ac_exeext
 if { (ac_try="$ac_link"
 case "(($ac_try" in
   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
@@ -16396,41 +16156,43 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_socket_connect=yes
+  ac_cv_search_connect=$ac_res
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_socket_connect=no
+
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
+      conftest$ac_exeext
+  if test "${ac_cv_search_connect+set}" = set; then
+  break
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_socket_connect" >&5
-echo "${ECHO_T}$ac_cv_lib_socket_connect" >&6; }
-if test $ac_cv_lib_socket_connect = yes; then
-  cat >>confdefs.h <<_ACEOF
-#define HAVE_LIBSOCKET 1
-_ACEOF
-
-  LIBS="-lsocket $LIBS"
-
+done
+if test "${ac_cv_search_connect+set}" = set; then
+  :
+else
+  ac_cv_search_connect=no
+fi
+rm conftest.$ac_ext
+LIBS=$ac_func_search_save_LIBS
 fi
+{ echo "$as_me:$LINENO: result: $ac_cv_search_connect" >&5
+echo "${ECHO_T}$ac_cv_search_connect" >&6; }
+ac_res=$ac_cv_search_connect
+if test "$ac_res" != no; then
+  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
 
 fi
 
-if test "$ac_cv_func_inet_aton" = no
-then
 
-{ echo "$as_me:$LINENO: checking for inet_aton in -lresolv" >&5
-echo $ECHO_N "checking for inet_aton in -lresolv... $ECHO_C" >&6; }
-if test "${ac_cv_lib_resolv_inet_aton+set}" = set; then
+{ echo "$as_me:$LINENO: checking for library containing inet_aton" >&5
+echo $ECHO_N "checking for library containing inet_aton... $ECHO_C" >&6; }
+if test "${ac_cv_search_inet_aton+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
 else
-  ac_check_lib_save_LIBS=$LIBS
-LIBS="-lresolv  $LIBS"
+  ac_func_search_save_LIBS=$LIBS
 cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -16453,6 +16215,132 @@ return inet_aton ();
   return 0;
 }
 _ACEOF
+for ac_lib in '' resolv; do
+  if test -z "$ac_lib"; then
+    ac_res="none required"
+  else
+    ac_res=-l$ac_lib
+    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
+  fi
+  rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_search_inet_aton=$ac_res
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext
+  if test "${ac_cv_search_inet_aton+set}" = set; then
+  break
+fi
+done
+if test "${ac_cv_search_inet_aton+set}" = set; then
+  :
+else
+  ac_cv_search_inet_aton=no
+fi
+rm conftest.$ac_ext
+LIBS=$ac_func_search_save_LIBS
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_search_inet_aton" >&5
+echo "${ECHO_T}$ac_cv_search_inet_aton" >&6; }
+ac_res=$ac_cv_search_inet_aton
+if test "$ac_res" != no; then
+  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
+
+fi
+
+
+
+
+
+
+
+
+
+
+for ac_func in \
+       getaddrinfo \
+       getnameinfo \
+       getnetbyname \
+       getprotobyname \
+       getprotobynumber \
+       getservbyport \
+       inet_network \
+       sendmsg \
+
+do
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+{ echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
+if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
+   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
+#define $ac_func innocuous_$ac_func
+
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char $ac_func (); below.
+    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+    <limits.h> exists even on freestanding compilers.  */
+
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+
+#undef $ac_func
+
+/* 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 $ac_func ();
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined __stub_$ac_func || defined __stub___$ac_func
+choke me
+#endif
+
+int
+main ()
+{
+return $ac_func ();
+  ;
+  return 0;
+}
+_ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
 if { (ac_try="$ac_link"
 case "(($ac_try" in
@@ -16471,30 +16359,28 @@ eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
         test ! -s conftest.err
        } && test -s conftest$ac_exeext &&
        $as_test_x conftest$ac_exeext; then
-  ac_cv_lib_resolv_inet_aton=yes
+  eval "$as_ac_var=yes"
 else
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_lib_resolv_inet_aton=no
+       eval "$as_ac_var=no"
 fi
 
 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
       conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
 fi
-{ echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_inet_aton" >&5
-echo "${ECHO_T}$ac_cv_lib_resolv_inet_aton" >&6; }
-if test $ac_cv_lib_resolv_inet_aton = yes; then
+ac_res=`eval echo '${'$as_ac_var'}'`
+              { echo "$as_me:$LINENO: result: $ac_res" >&5
+echo "${ECHO_T}$ac_res" >&6; }
+if test `eval echo '${'$as_ac_var'}'` = yes; then
   cat >>confdefs.h <<_ACEOF
-#define HAVE_LIBRESOLV 1
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
 _ACEOF
 
-  LIBS="-lresolv $LIBS"
-
 fi
+done
 
-fi
 
 
 { echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
@@ -17469,9 +17355,7 @@ _ACEOF
 cat confdefs.h >>conftest.$ac_ext
 cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
-
 #include <netdb.h>
-
 int
 main ()
 {
@@ -17549,6 +17433,7 @@ cat >>conftest.$ac_ext <<_ACEOF
 /* end confdefs.h.  */
 
        #include <sys/ioctl.h>
+       #include <sys/types.h>
        #include <linux/joystick.h>
 
        struct js_event blub;
   echo "$as_me: failed program was:" >&5
 sed 's/^/| /' conftest.$ac_ext >&5
 
-       ac_cv_member_struct_sockaddr_in6_sin6_scope_id=no
-fi
+       ac_cv_member_struct_sockaddr_in6_sin6_scope_id=no
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_in6_sin6_scope_id" >&5
+echo "${ECHO_T}$ac_cv_member_struct_sockaddr_in6_sin6_scope_id" >&6; }
+if test $ac_cv_member_struct_sockaddr_in6_sin6_scope_id = yes; then
+
+cat >>confdefs.h <<_ACEOF
+#define HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID 1
+_ACEOF
+
+
+fi
+
+
+{ echo "$as_me:$LINENO: checking for ns_msg._msg_ptr" >&5
+echo $ECHO_N "checking for ns_msg._msg_ptr... $ECHO_C" >&6; }
+if test "${ac_cv_member_ns_msg__msg_ptr+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#ifdef HAVE_SYS_TYPES_H
+#include <sys/types.h>
+#endif
+#ifdef HAVE_NETINET_IN_H
+# include <netinet/in.h>
+#endif
+#ifdef HAVE_ARPA_NAMESER_H
+# include <arpa/nameser.h>
+#endif
+
+int
+main ()
+{
+static ns_msg ac_aggr;
+if (ac_aggr._msg_ptr)
+return 0;
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_compile") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       } && test -s conftest.$ac_objext; then
+  ac_cv_member_ns_msg__msg_ptr=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#ifdef HAVE_SYS_TYPES_H
+#include <sys/types.h>
+#endif
+#ifdef HAVE_NETINET_IN_H
+# include <netinet/in.h>
+#endif
+#ifdef HAVE_ARPA_NAMESER_H
+# include <arpa/nameser.h>
+#endif
+
+int
+main ()
+{
+static ns_msg ac_aggr;
+if (sizeof ac_aggr._msg_ptr)
+return 0;
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (ac_try="$ac_compile"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_compile") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       } && test -s conftest.$ac_objext; then
+  ac_cv_member_ns_msg__msg_ptr=yes
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       ac_cv_member_ns_msg__msg_ptr=no
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_member_ns_msg__msg_ptr" >&5
+echo "${ECHO_T}$ac_cv_member_ns_msg__msg_ptr" >&6; }
+if test $ac_cv_member_ns_msg__msg_ptr = yes; then
+
+cat >>confdefs.h <<_ACEOF
+#define HAVE_NS_MSG__MSG_PTR 1
+_ACEOF
+
+
+fi
+
+
+{ echo "$as_me:$LINENO: checking for timezone variable" >&5
+echo $ECHO_N "checking for timezone variable... $ECHO_C" >&6; }
+if test "${ac_cv_have_timezone+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#include <time.h>
+int
+main ()
+{
+timezone = 1
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_have_timezone="yes"
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       ac_cv_have_timezone="no"
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_have_timezone" >&5
+echo "${ECHO_T}$ac_cv_have_timezone" >&6; }
+if test "$ac_cv_have_timezone" = "yes"
+then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_TIMEZONE 1
+_ACEOF
+
+fi
+{ echo "$as_me:$LINENO: checking for daylight variable" >&5
+echo $ECHO_N "checking for daylight variable... $ECHO_C" >&6; }
+if test "${ac_cv_have_daylight+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#include <time.h>
+int
+main ()
+{
+daylight = 1
+  ;
+  return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (ac_try="$ac_link"
+case "(($ac_try" in
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
+  *) ac_try_echo=$ac_try;;
+esac
+eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
+  (eval "$ac_link") 2>conftest.er1
+  ac_status=$?
+  grep -v '^ *+' conftest.er1 >conftest.err
+  rm -f conftest.er1
+  cat conftest.err >&5
+  echo "$as_me:$LINENO: \$? = $ac_status" >&5
+  (exit $ac_status); } && {
+        test -z "$ac_c_werror_flag" ||
+        test ! -s conftest.err
+       } && test -s conftest$ac_exeext &&
+       $as_test_x conftest$ac_exeext; then
+  ac_cv_have_daylight="yes"
+else
+  echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+       ac_cv_have_daylight="no"
+fi
+
+rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
+      conftest$ac_exeext conftest.$ac_ext
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_have_daylight" >&5
+echo "${ECHO_T}$ac_cv_have_daylight" >&6; }
+if test "$ac_cv_have_daylight" = "yes"
+then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_DAYLIGHT 1
+_ACEOF
+
+fi
+
+
+case $host_cpu in
+  *i[3456789]86*) { echo "$as_me:$LINENO: checking whether we need to define __i386__" >&5
+echo $ECHO_N "checking whether we need to define __i386__... $ECHO_C" >&6; }
+if test "${ac_cv_cpp_def___i386__+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#ifndef __i386__
+yes
+#endif
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  $EGREP "yes" >/dev/null 2>&1; then
+  ac_cv_cpp_def___i386__=yes
+else
+  ac_cv_cpp_def___i386__=no
+fi
+rm -f conftest*
+
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___i386__" >&5
+echo "${ECHO_T}$ac_cv_cpp_def___i386__" >&6; }
+if test $ac_cv_cpp_def___i386__ = yes; then
+  CFLAGS="$CFLAGS -D__i386__"
+  LINTFLAGS="$LINTFLAGS -D__i386__"
+fi
+ ;;
+  *x86_64*)         { echo "$as_me:$LINENO: checking whether we need to define __x86_64__" >&5
+echo $ECHO_N "checking whether we need to define __x86_64__... $ECHO_C" >&6; }
+if test "${ac_cv_cpp_def___x86_64__+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#ifndef __x86_64__
+yes
+#endif
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  $EGREP "yes" >/dev/null 2>&1; then
+  ac_cv_cpp_def___x86_64__=yes
+else
+  ac_cv_cpp_def___x86_64__=no
+fi
+rm -f conftest*
+
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___x86_64__" >&5
+echo "${ECHO_T}$ac_cv_cpp_def___x86_64__" >&6; }
+if test $ac_cv_cpp_def___x86_64__ = yes; then
+  CFLAGS="$CFLAGS -D__x86_64__"
+  LINTFLAGS="$LINTFLAGS -D__x86_64__"
+fi
+ ;;
+  *alpha*)          { echo "$as_me:$LINENO: checking whether we need to define __ALPHA__" >&5
+echo $ECHO_N "checking whether we need to define __ALPHA__... $ECHO_C" >&6; }
+if test "${ac_cv_cpp_def___ALPHA__+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#ifndef __ALPHA__
+yes
+#endif
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  $EGREP "yes" >/dev/null 2>&1; then
+  ac_cv_cpp_def___ALPHA__=yes
+else
+  ac_cv_cpp_def___ALPHA__=no
+fi
+rm -f conftest*
+
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___ALPHA__" >&5
+echo "${ECHO_T}$ac_cv_cpp_def___ALPHA__" >&6; }
+if test $ac_cv_cpp_def___ALPHA__ = yes; then
+  CFLAGS="$CFLAGS -D__ALPHA__"
+  LINTFLAGS="$LINTFLAGS -D__ALPHA__"
+fi
+ ;;
+  *sparc*)          { echo "$as_me:$LINENO: checking whether we need to define __sparc__" >&5
+echo $ECHO_N "checking whether we need to define __sparc__... $ECHO_C" >&6; }
+if test "${ac_cv_cpp_def___sparc__+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#ifndef __sparc__
+yes
+#endif
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  $EGREP "yes" >/dev/null 2>&1; then
+  ac_cv_cpp_def___sparc__=yes
+else
+  ac_cv_cpp_def___sparc__=no
+fi
+rm -f conftest*
+
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___sparc__" >&5
+echo "${ECHO_T}$ac_cv_cpp_def___sparc__" >&6; }
+if test $ac_cv_cpp_def___sparc__ = yes; then
+  CFLAGS="$CFLAGS -D__sparc__"
+  LINTFLAGS="$LINTFLAGS -D__sparc__"
+fi
+ ;;
+  *powerpc*)        { echo "$as_me:$LINENO: checking whether we need to define __powerpc__" >&5
+echo $ECHO_N "checking whether we need to define __powerpc__... $ECHO_C" >&6; }
+if test "${ac_cv_cpp_def___powerpc__+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#ifndef __powerpc__
+yes
+#endif
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  $EGREP "yes" >/dev/null 2>&1; then
+  ac_cv_cpp_def___powerpc__=yes
+else
+  ac_cv_cpp_def___powerpc__=no
+fi
+rm -f conftest*
+
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___powerpc__" >&5
+echo "${ECHO_T}$ac_cv_cpp_def___powerpc__" >&6; }
+if test $ac_cv_cpp_def___powerpc__ = yes; then
+  CFLAGS="$CFLAGS -D__powerpc__"
+  LINTFLAGS="$LINTFLAGS -D__powerpc__"
+fi
+ ;;
+esac
+
+case $host_vendor in
+  *sun*) { echo "$as_me:$LINENO: checking whether we need to define __sun__" >&5
+echo $ECHO_N "checking whether we need to define __sun__... $ECHO_C" >&6; }
+if test "${ac_cv_cpp_def___sun__+set}" = set; then
+  echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+  cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h.  */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h.  */
+#ifndef __sun__
+yes
+#endif
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  $EGREP "yes" >/dev/null 2>&1; then
+  ac_cv_cpp_def___sun__=yes
+else
+  ac_cv_cpp_def___sun__=no
+fi
+rm -f conftest*
+
+fi
+{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___sun__" >&5
+echo "${ECHO_T}$ac_cv_cpp_def___sun__" >&6; }
+if test $ac_cv_cpp_def___sun__ = yes; then
+  CFLAGS="$CFLAGS -D__sun__"
+  LINTFLAGS="$LINTFLAGS -D__sun__"
+fi
+ ;;
+esac
+
+
+DEPENDENCIES="### Dependencies:
+
+.INIT: Makefile
+.BEGIN: Makefile
+Makefile: dummy
+       -\$(MAKEDEP) -C\$(SRCDIR) -S\$(TOPSRCDIR) -T\$(TOPOBJDIR) \$(EXTRAINCL) \$(DEPEND_SRCS)
+
+\$(OBJS): \$(IDL_GEN_HEADERS)
+\$(IDL_GEN_C_SRCS:.c=.o): \$(IDL_GEN_C_SRCS)
+\$(LEX_SRCS:.l=.yy.o): \$(LEX_SRCS:.l=.yy.c)
+\$(BISON_SRCS:.y=.tab.o): \$(BISON_SRCS:.y=.tab.c)"
+
+
+
+
+
+ac_config_commands="$ac_config_commands include/stamp-h"
+
+
+ac_config_commands="$ac_config_commands dlls/gdi32/enhmfdrv"
+
+ac_config_commands="$ac_config_commands dlls/gdi32/mfdrv"
+
+ac_config_commands="$ac_config_commands dlls/kernel32/nls"
+
+ac_config_commands="$ac_config_commands dlls/user32/resources"
+
+ac_config_commands="$ac_config_commands dlls/wineps.drv/data"
+
+ac_config_commands="$ac_config_commands include/wine"
+
+
+MAKE_RULES=Make.rules
+
+
+MAKE_DLL_RULES=dlls/Makedll.rules
+
+
+MAKE_IMPLIB_RULES=dlls/Makeimplib.rules
+
+
+MAKE_TEST_RULES=dlls/Maketest.rules
+
+
+MAKE_PROG_RULES=programs/Makeprog.rules
+
+
+ac_config_files="$ac_config_files Make.rules"
+
+ac_config_files="$ac_config_files dlls/Makedll.rules"
+
+ac_config_files="$ac_config_files dlls/Makeimplib.rules"
+
+ac_config_files="$ac_config_files dlls/Maketest.rules"
+
+ac_config_files="$ac_config_files programs/Makeprog.rules"
+
+ac_config_files="$ac_config_files Makefile"
+
+ac_config_files="$ac_config_files dlls/Makefile"
+
+ac_config_files="$ac_config_files dlls/acledit/Makefile"
+
+ac_config_files="$ac_config_files dlls/activeds/Makefile"
+
+ac_config_files="$ac_config_files dlls/advapi32/Makefile"
+
+ac_config_files="$ac_config_files dlls/advapi32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/advpack/Makefile"
+
+ac_config_files="$ac_config_files dlls/advpack/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/amstream/Makefile"
+
+ac_config_files="$ac_config_files dlls/atl/Makefile"
+
+ac_config_files="$ac_config_files dlls/avicap32/Makefile"
+
+ac_config_files="$ac_config_files dlls/avifil32/Makefile"
+
+ac_config_files="$ac_config_files dlls/browseui/Makefile"
+
+ac_config_files="$ac_config_files dlls/browseui/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/cabinet/Makefile"
+
+ac_config_files="$ac_config_files dlls/cabinet/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/capi2032/Makefile"
+
+ac_config_files="$ac_config_files dlls/cards/Makefile"
+
+ac_config_files="$ac_config_files dlls/cfgmgr32/Makefile"
+
+ac_config_files="$ac_config_files dlls/clusapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/comcat/Makefile"
+
+ac_config_files="$ac_config_files dlls/comcat/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/comctl32/Makefile"
+
+ac_config_files="$ac_config_files dlls/comctl32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/comdlg32/Makefile"
+
+ac_config_files="$ac_config_files dlls/comdlg32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/compstui/Makefile"
+
+ac_config_files="$ac_config_files dlls/credui/Makefile"
+
+ac_config_files="$ac_config_files dlls/crtdll/Makefile"
+
+ac_config_files="$ac_config_files dlls/crypt32/Makefile"
+
+ac_config_files="$ac_config_files dlls/crypt32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/cryptdll/Makefile"
+
+ac_config_files="$ac_config_files dlls/cryptnet/Makefile"
+
+ac_config_files="$ac_config_files dlls/ctl3d32/Makefile"
+
+ac_config_files="$ac_config_files dlls/d3d8/Makefile"
+
+ac_config_files="$ac_config_files dlls/d3d8/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/d3d9/Makefile"
+
+ac_config_files="$ac_config_files dlls/d3d9/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/d3dim/Makefile"
+
+ac_config_files="$ac_config_files dlls/d3drm/Makefile"
+
+ac_config_files="$ac_config_files dlls/d3drm/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/d3dx8/Makefile"
+
+ac_config_files="$ac_config_files dlls/d3dxof/Makefile"
+
+ac_config_files="$ac_config_files dlls/dbghelp/Makefile"
+
+ac_config_files="$ac_config_files dlls/dciman32/Makefile"
+
+ac_config_files="$ac_config_files dlls/ddraw/Makefile"
+
+ac_config_files="$ac_config_files dlls/ddraw/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/ddrawex/Makefile"
+
+ac_config_files="$ac_config_files dlls/devenum/Makefile"
+
+ac_config_files="$ac_config_files dlls/dinput/Makefile"
+
+ac_config_files="$ac_config_files dlls/dinput/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/dinput8/Makefile"
+
+ac_config_files="$ac_config_files dlls/dmband/Makefile"
+
+ac_config_files="$ac_config_files dlls/dmcompos/Makefile"
+
+ac_config_files="$ac_config_files dlls/dmime/Makefile"
+
+ac_config_files="$ac_config_files dlls/dmloader/Makefile"
+
+ac_config_files="$ac_config_files dlls/dmscript/Makefile"
+
+ac_config_files="$ac_config_files dlls/dmstyle/Makefile"
+
+ac_config_files="$ac_config_files dlls/dmsynth/Makefile"
+
+ac_config_files="$ac_config_files dlls/dmusic/Makefile"
+
+ac_config_files="$ac_config_files dlls/dmusic32/Makefile"
+
+ac_config_files="$ac_config_files dlls/dnsapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/dnsapi/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/dplay/Makefile"
+
+ac_config_files="$ac_config_files dlls/dplayx/Makefile"
+
+ac_config_files="$ac_config_files dlls/dplayx/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/dpnaddr/Makefile"
+
+ac_config_files="$ac_config_files dlls/dpnet/Makefile"
+
+ac_config_files="$ac_config_files dlls/dpnhpast/Makefile"
+
+ac_config_files="$ac_config_files dlls/dsound/Makefile"
+
+ac_config_files="$ac_config_files dlls/dsound/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/dswave/Makefile"
+
+ac_config_files="$ac_config_files dlls/dwmapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/dxdiagn/Makefile"
+
+ac_config_files="$ac_config_files dlls/dxerr8/Makefile"
+
+ac_config_files="$ac_config_files dlls/dxerr9/Makefile"
+
+ac_config_files="$ac_config_files dlls/dxguid/Makefile"
+
+ac_config_files="$ac_config_files dlls/gdi32/Makefile"
+
+ac_config_files="$ac_config_files dlls/gdi32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/gdiplus/Makefile"
+
+ac_config_files="$ac_config_files dlls/gdiplus/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/glu32/Makefile"
+
+ac_config_files="$ac_config_files dlls/gphoto2.ds/Makefile"
+
+ac_config_files="$ac_config_files dlls/hal/Makefile"
+
+ac_config_files="$ac_config_files dlls/hhctrl.ocx/Makefile"
+
+ac_config_files="$ac_config_files dlls/hid/Makefile"
+
+ac_config_files="$ac_config_files dlls/hlink/Makefile"
+
+ac_config_files="$ac_config_files dlls/hlink/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/hnetcfg/Makefile"
+
+ac_config_files="$ac_config_files dlls/iccvid/Makefile"
+
+ac_config_files="$ac_config_files dlls/icmp/Makefile"
+
+ac_config_files="$ac_config_files dlls/ifsmgr.vxd/Makefile"
+
+ac_config_files="$ac_config_files dlls/imaadp32.acm/Makefile"
+
+ac_config_files="$ac_config_files dlls/imagehlp/Makefile"
+
+ac_config_files="$ac_config_files dlls/imm32/Makefile"
+
+ac_config_files="$ac_config_files dlls/infosoft/Makefile"
+
+ac_config_files="$ac_config_files dlls/infosoft/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/inseng/Makefile"
+
+ac_config_files="$ac_config_files dlls/iphlpapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/iphlpapi/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/itss/Makefile"
+
+ac_config_files="$ac_config_files dlls/itss/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/kernel32/Makefile"
+
+ac_config_files="$ac_config_files dlls/kernel32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/localspl/Makefile"
+
+ac_config_files="$ac_config_files dlls/localspl/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/localui/Makefile"
+
+ac_config_files="$ac_config_files dlls/localui/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/lz32/Makefile"
+
+ac_config_files="$ac_config_files dlls/lz32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/mapi32/Makefile"
+
+ac_config_files="$ac_config_files dlls/mapi32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/mciavi32/Makefile"
+
+ac_config_files="$ac_config_files dlls/mcicda/Makefile"
+
+ac_config_files="$ac_config_files dlls/mciseq/Makefile"
+
+ac_config_files="$ac_config_files dlls/mciwave/Makefile"
+
+ac_config_files="$ac_config_files dlls/midimap/Makefile"
+
+ac_config_files="$ac_config_files dlls/mlang/Makefile"
+
+ac_config_files="$ac_config_files dlls/mlang/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/mmdevldr.vxd/Makefile"
+
+ac_config_files="$ac_config_files dlls/monodebg.vxd/Makefile"
+
+ac_config_files="$ac_config_files dlls/mpr/Makefile"
+
+ac_config_files="$ac_config_files dlls/mprapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/msacm32.drv/Makefile"
+
+ac_config_files="$ac_config_files dlls/msacm32/Makefile"
+
+ac_config_files="$ac_config_files dlls/msacm32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/msadp32.acm/Makefile"
+
+ac_config_files="$ac_config_files dlls/mscms/Makefile"
+
+ac_config_files="$ac_config_files dlls/mscms/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/mscoree/Makefile"
+
+ac_config_files="$ac_config_files dlls/msdmo/Makefile"
+
+ac_config_files="$ac_config_files dlls/msftedit/Makefile"
+
+ac_config_files="$ac_config_files dlls/msg711.acm/Makefile"
+
+ac_config_files="$ac_config_files dlls/mshtml/Makefile"
+
+ac_config_files="$ac_config_files dlls/mshtml/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/msi/Makefile"
+
+ac_config_files="$ac_config_files dlls/msi/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/msimg32/Makefile"
+
+ac_config_files="$ac_config_files dlls/msisys.ocx/Makefile"
+
+ac_config_files="$ac_config_files dlls/msnet32/Makefile"
+
+ac_config_files="$ac_config_files dlls/msrle32/Makefile"
+
+ac_config_files="$ac_config_files dlls/msvcrt/Makefile"
+
+ac_config_files="$ac_config_files dlls/msvcrt/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/msvcrt20/Makefile"
+
+ac_config_files="$ac_config_files dlls/msvcrt40/Makefile"
+
+ac_config_files="$ac_config_files dlls/msvcrtd/Makefile"
+
+ac_config_files="$ac_config_files dlls/msvcrtd/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/msvfw32/Makefile"
+
+ac_config_files="$ac_config_files dlls/msvidc32/Makefile"
+
+ac_config_files="$ac_config_files dlls/mswsock/Makefile"
+
+ac_config_files="$ac_config_files dlls/msxml3/Makefile"
+
+ac_config_files="$ac_config_files dlls/msxml3/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/nddeapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/netapi32/Makefile"
+
+ac_config_files="$ac_config_files dlls/netapi32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/newdev/Makefile"
+
+ac_config_files="$ac_config_files dlls/ntdll/Makefile"
+
+ac_config_files="$ac_config_files dlls/ntdll/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/ntdsapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/ntoskrnl.exe/Makefile"
+
+ac_config_files="$ac_config_files dlls/ntprint/Makefile"
+
+ac_config_files="$ac_config_files dlls/ntprint/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/objsel/Makefile"
+
+ac_config_files="$ac_config_files dlls/odbc32/Makefile"
+
+ac_config_files="$ac_config_files dlls/odbccp32/Makefile"
+
+ac_config_files="$ac_config_files dlls/odbccp32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/ole32/Makefile"
+
+ac_config_files="$ac_config_files dlls/ole32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/oleacc/Makefile"
+
+ac_config_files="$ac_config_files dlls/oleaut32/Makefile"
+
+ac_config_files="$ac_config_files dlls/oleaut32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/olecli32/Makefile"
+
+ac_config_files="$ac_config_files dlls/oledlg/Makefile"
+
+ac_config_files="$ac_config_files dlls/olepro32/Makefile"
+
+ac_config_files="$ac_config_files dlls/olesvr32/Makefile"
+
+ac_config_files="$ac_config_files dlls/opengl32/Makefile"
+
+ac_config_files="$ac_config_files dlls/pdh/Makefile"
+
+ac_config_files="$ac_config_files dlls/powrprof/Makefile"
+
+ac_config_files="$ac_config_files dlls/printui/Makefile"
+
+ac_config_files="$ac_config_files dlls/psapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/psapi/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/pstorec/Makefile"
+
+ac_config_files="$ac_config_files dlls/qcap/Makefile"
+
+ac_config_files="$ac_config_files dlls/quartz/Makefile"
+
+ac_config_files="$ac_config_files dlls/quartz/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/query/Makefile"
+
+ac_config_files="$ac_config_files dlls/rasapi32/Makefile"
+
+ac_config_files="$ac_config_files dlls/resutils/Makefile"
+
+ac_config_files="$ac_config_files dlls/riched20/Makefile"
+
+ac_config_files="$ac_config_files dlls/riched20/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/riched32/Makefile"
+
+ac_config_files="$ac_config_files dlls/rpcrt4/Makefile"
+
+ac_config_files="$ac_config_files dlls/rpcrt4/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/rsabase/Makefile"
+
+ac_config_files="$ac_config_files dlls/rsabase/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/rsaenh/Makefile"
+
+ac_config_files="$ac_config_files dlls/rsaenh/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/sane.ds/Makefile"
+
+ac_config_files="$ac_config_files dlls/schannel/Makefile"
+
+ac_config_files="$ac_config_files dlls/schannel/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/secur32/Makefile"
+
+ac_config_files="$ac_config_files dlls/secur32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/security/Makefile"
+
+ac_config_files="$ac_config_files dlls/sensapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/serialui/Makefile"
+
+ac_config_files="$ac_config_files dlls/serialui/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/setupapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/setupapi/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/sfc/Makefile"
+
+ac_config_files="$ac_config_files dlls/sfc_os/Makefile"
+
+ac_config_files="$ac_config_files dlls/shdoclc/Makefile"
+
+ac_config_files="$ac_config_files dlls/shdocvw/Makefile"
+
+ac_config_files="$ac_config_files dlls/shdocvw/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/shell32/Makefile"
+
+ac_config_files="$ac_config_files dlls/shell32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/shfolder/Makefile"
+
+ac_config_files="$ac_config_files dlls/shlwapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/shlwapi/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/snmpapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/snmpapi/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/spoolss/Makefile"
+
+ac_config_files="$ac_config_files dlls/stdole2.tlb/Makefile"
+
+ac_config_files="$ac_config_files dlls/stdole32.tlb/Makefile"
+
+ac_config_files="$ac_config_files dlls/sti/Makefile"
+
+ac_config_files="$ac_config_files dlls/strmiids/Makefile"
+
+ac_config_files="$ac_config_files dlls/svrapi/Makefile"
+
+ac_config_files="$ac_config_files dlls/sxs/Makefile"
+
+ac_config_files="$ac_config_files dlls/tapi32/Makefile"
+
+ac_config_files="$ac_config_files dlls/twain_32/Makefile"
+
+ac_config_files="$ac_config_files dlls/unicows/Makefile"
+
+ac_config_files="$ac_config_files dlls/url/Makefile"
+
+ac_config_files="$ac_config_files dlls/urlmon/Makefile"
+
+ac_config_files="$ac_config_files dlls/urlmon/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/user32/Makefile"
+
+ac_config_files="$ac_config_files dlls/user32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/userenv/Makefile"
+
+ac_config_files="$ac_config_files dlls/usp10/Makefile"
+
+ac_config_files="$ac_config_files dlls/usp10/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/uuid/Makefile"
+
+ac_config_files="$ac_config_files dlls/uxtheme/Makefile"
+
+ac_config_files="$ac_config_files dlls/uxtheme/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/vdhcp.vxd/Makefile"
+
+ac_config_files="$ac_config_files dlls/vdmdbg/Makefile"
+
+ac_config_files="$ac_config_files dlls/version/Makefile"
+
+ac_config_files="$ac_config_files dlls/version/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/vmm.vxd/Makefile"
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
+ac_config_files="$ac_config_files dlls/vnbt.vxd/Makefile"
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_in6_sin6_scope_id" >&5
-echo "${ECHO_T}$ac_cv_member_struct_sockaddr_in6_sin6_scope_id" >&6; }
-if test $ac_cv_member_struct_sockaddr_in6_sin6_scope_id = yes; then
+ac_config_files="$ac_config_files dlls/vnetbios.vxd/Makefile"
 
-cat >>confdefs.h <<_ACEOF
-#define HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID 1
-_ACEOF
+ac_config_files="$ac_config_files dlls/vtdapi.vxd/Makefile"
 
+ac_config_files="$ac_config_files dlls/vwin32.vxd/Makefile"
 
-fi
+ac_config_files="$ac_config_files dlls/w32skrnl/Makefile"
 
+ac_config_files="$ac_config_files dlls/winealsa.drv/Makefile"
 
-{ echo "$as_me:$LINENO: checking for ns_msg._msg_ptr" >&5
-echo $ECHO_N "checking for ns_msg._msg_ptr... $ECHO_C" >&6; }
-if test "${ac_cv_member_ns_msg__msg_ptr+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#ifdef HAVE_SYS_TYPES_H
-#include <sys/types.h>
-#endif
-#ifdef HAVE_NETINET_IN_H
-# include <netinet/in.h>
-#endif
-#ifdef HAVE_ARPA_NAMESER_H
-# include <arpa/nameser.h>
-#endif
+ac_config_files="$ac_config_files dlls/wineaudioio.drv/Makefile"
 
-int
-main ()
-{
-static ns_msg ac_aggr;
-if (ac_aggr._msg_ptr)
-return 0;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_member_ns_msg__msg_ptr=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+ac_config_files="$ac_config_files dlls/winecoreaudio.drv/Makefile"
 
-       cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#ifdef HAVE_SYS_TYPES_H
-#include <sys/types.h>
-#endif
-#ifdef HAVE_NETINET_IN_H
-# include <netinet/in.h>
-#endif
-#ifdef HAVE_ARPA_NAMESER_H
-# include <arpa/nameser.h>
-#endif
+ac_config_files="$ac_config_files dlls/winecrt0/Makefile"
 
-int
-main ()
-{
-static ns_msg ac_aggr;
-if (sizeof ac_aggr._msg_ptr)
-return 0;
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext
-if { (ac_try="$ac_compile"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_compile") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest.$ac_objext; then
-  ac_cv_member_ns_msg__msg_ptr=yes
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+ac_config_files="$ac_config_files dlls/wined3d/Makefile"
 
-       ac_cv_member_ns_msg__msg_ptr=no
-fi
+ac_config_files="$ac_config_files dlls/winedos/Makefile"
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
+ac_config_files="$ac_config_files dlls/wineesd.drv/Makefile"
 
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_member_ns_msg__msg_ptr" >&5
-echo "${ECHO_T}$ac_cv_member_ns_msg__msg_ptr" >&6; }
-if test $ac_cv_member_ns_msg__msg_ptr = yes; then
+ac_config_files="$ac_config_files dlls/winejack.drv/Makefile"
 
-cat >>confdefs.h <<_ACEOF
-#define HAVE_NS_MSG__MSG_PTR 1
-_ACEOF
+ac_config_files="$ac_config_files dlls/winejoystick.drv/Makefile"
 
+ac_config_files="$ac_config_files dlls/winemp3.acm/Makefile"
 
-fi
+ac_config_files="$ac_config_files dlls/winenas.drv/Makefile"
 
+ac_config_files="$ac_config_files dlls/wineoss.drv/Makefile"
 
-{ echo "$as_me:$LINENO: checking for timezone variable" >&5
-echo $ECHO_N "checking for timezone variable... $ECHO_C" >&6; }
-if test "${ac_cv_have_timezone+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <time.h>
-int
-main ()
-{
-timezone = 1
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_have_timezone="yes"
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+ac_config_files="$ac_config_files dlls/wineps.drv/Makefile"
 
-       ac_cv_have_timezone="no"
-fi
+ac_config_files="$ac_config_files dlls/winequartz.drv/Makefile"
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_have_timezone" >&5
-echo "${ECHO_T}$ac_cv_have_timezone" >&6; }
-if test "$ac_cv_have_timezone" = "yes"
-then
+ac_config_files="$ac_config_files dlls/winex11.drv/Makefile"
 
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_TIMEZONE 1
-_ACEOF
+ac_config_files="$ac_config_files dlls/wing32/Makefile"
 
-fi
-{ echo "$as_me:$LINENO: checking for daylight variable" >&5
-echo $ECHO_N "checking for daylight variable... $ECHO_C" >&6; }
-if test "${ac_cv_have_daylight+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#include <time.h>
-int
-main ()
-{
-daylight = 1
-  ;
-  return 0;
-}
-_ACEOF
-rm -f conftest.$ac_objext conftest$ac_exeext
-if { (ac_try="$ac_link"
-case "(($ac_try" in
-  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
-  *) ac_try_echo=$ac_try;;
-esac
-eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
-  (eval "$ac_link") 2>conftest.er1
-  ac_status=$?
-  grep -v '^ *+' conftest.er1 >conftest.err
-  rm -f conftest.er1
-  cat conftest.err >&5
-  echo "$as_me:$LINENO: \$? = $ac_status" >&5
-  (exit $ac_status); } && {
-        test -z "$ac_c_werror_flag" ||
-        test ! -s conftest.err
-       } && test -s conftest$ac_exeext &&
-       $as_test_x conftest$ac_exeext; then
-  ac_cv_have_daylight="yes"
-else
-  echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
+ac_config_files="$ac_config_files dlls/wininet/Makefile"
 
-       ac_cv_have_daylight="no"
-fi
+ac_config_files="$ac_config_files dlls/wininet/tests/Makefile"
 
-rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
-      conftest$ac_exeext conftest.$ac_ext
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_have_daylight" >&5
-echo "${ECHO_T}$ac_cv_have_daylight" >&6; }
-if test "$ac_cv_have_daylight" = "yes"
-then
+ac_config_files="$ac_config_files dlls/winmm/Makefile"
+
+ac_config_files="$ac_config_files dlls/winmm/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/winnls32/Makefile"
+
+ac_config_files="$ac_config_files dlls/winscard/Makefile"
+
+ac_config_files="$ac_config_files dlls/winspool.drv/Makefile"
+
+ac_config_files="$ac_config_files dlls/winspool.drv/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/wintab32/Makefile"
+
+ac_config_files="$ac_config_files dlls/wintrust/Makefile"
+
+ac_config_files="$ac_config_files dlls/wintrust/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/wldap32/Makefile"
+
+ac_config_files="$ac_config_files dlls/wnaspi32/Makefile"
+
+ac_config_files="$ac_config_files dlls/wow32/Makefile"
+
+ac_config_files="$ac_config_files dlls/ws2_32/Makefile"
+
+ac_config_files="$ac_config_files dlls/ws2_32/tests/Makefile"
+
+ac_config_files="$ac_config_files dlls/wsock32/Makefile"
+
+ac_config_files="$ac_config_files dlls/wtsapi32/Makefile"
+
+ac_config_files="$ac_config_files documentation/Makefile"
+
+ac_config_files="$ac_config_files fonts/Makefile"
+
+ac_config_files="$ac_config_files include/Makefile"
+
+ac_config_files="$ac_config_files libs/Makefile"
+
+ac_config_files="$ac_config_files libs/port/Makefile"
+
+ac_config_files="$ac_config_files libs/wine/Makefile"
+
+ac_config_files="$ac_config_files libs/wpp/Makefile"
+
+ac_config_files="$ac_config_files loader/Makefile"
+
+ac_config_files="$ac_config_files programs/Makefile"
+
+ac_config_files="$ac_config_files programs/clock/Makefile"
+
+ac_config_files="$ac_config_files programs/cmd/Makefile"
+
+ac_config_files="$ac_config_files programs/cmdlgtst/Makefile"
 
-cat >>confdefs.h <<\_ACEOF
-#define HAVE_DAYLIGHT 1
-_ACEOF
+ac_config_files="$ac_config_files programs/control/Makefile"
 
-fi
+ac_config_files="$ac_config_files programs/eject/Makefile"
 
+ac_config_files="$ac_config_files programs/expand/Makefile"
 
-case $host_cpu in
-  *i[3456789]86*) { echo "$as_me:$LINENO: checking whether we need to define __i386__" >&5
-echo $ECHO_N "checking whether we need to define __i386__... $ECHO_C" >&6; }
-if test "${ac_cv_cpp_def___i386__+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#ifndef __i386__
-yes
-#endif
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "yes" >/dev/null 2>&1; then
-  ac_cv_cpp_def___i386__=yes
-else
-  ac_cv_cpp_def___i386__=no
-fi
-rm -f conftest*
+ac_config_files="$ac_config_files programs/explorer/Makefile"
 
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___i386__" >&5
-echo "${ECHO_T}$ac_cv_cpp_def___i386__" >&6; }
-if test $ac_cv_cpp_def___i386__ = yes; then
-  CFLAGS="$CFLAGS -D__i386__"
-  LINTFLAGS="$LINTFLAGS -D__i386__"
-fi
- ;;
-  *x86_64*)         { echo "$as_me:$LINENO: checking whether we need to define __x86_64__" >&5
-echo $ECHO_N "checking whether we need to define __x86_64__... $ECHO_C" >&6; }
-if test "${ac_cv_cpp_def___x86_64__+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#ifndef __x86_64__
-yes
-#endif
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "yes" >/dev/null 2>&1; then
-  ac_cv_cpp_def___x86_64__=yes
-else
-  ac_cv_cpp_def___x86_64__=no
-fi
-rm -f conftest*
+ac_config_files="$ac_config_files programs/hh/Makefile"
 
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___x86_64__" >&5
-echo "${ECHO_T}$ac_cv_cpp_def___x86_64__" >&6; }
-if test $ac_cv_cpp_def___x86_64__ = yes; then
-  CFLAGS="$CFLAGS -D__x86_64__"
-  LINTFLAGS="$LINTFLAGS -D__x86_64__"
-fi
- ;;
-  *alpha*)          { echo "$as_me:$LINENO: checking whether we need to define __ALPHA__" >&5
-echo $ECHO_N "checking whether we need to define __ALPHA__... $ECHO_C" >&6; }
-if test "${ac_cv_cpp_def___ALPHA__+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#ifndef __ALPHA__
-yes
-#endif
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "yes" >/dev/null 2>&1; then
-  ac_cv_cpp_def___ALPHA__=yes
-else
-  ac_cv_cpp_def___ALPHA__=no
-fi
-rm -f conftest*
+ac_config_files="$ac_config_files programs/icinfo/Makefile"
 
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___ALPHA__" >&5
-echo "${ECHO_T}$ac_cv_cpp_def___ALPHA__" >&6; }
-if test $ac_cv_cpp_def___ALPHA__ = yes; then
-  CFLAGS="$CFLAGS -D__ALPHA__"
-  LINTFLAGS="$LINTFLAGS -D__ALPHA__"
-fi
- ;;
-  *sparc*)          { echo "$as_me:$LINENO: checking whether we need to define __sparc__" >&5
-echo $ECHO_N "checking whether we need to define __sparc__... $ECHO_C" >&6; }
-if test "${ac_cv_cpp_def___sparc__+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#ifndef __sparc__
-yes
-#endif
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "yes" >/dev/null 2>&1; then
-  ac_cv_cpp_def___sparc__=yes
-else
-  ac_cv_cpp_def___sparc__=no
-fi
-rm -f conftest*
+ac_config_files="$ac_config_files programs/iexplore/Makefile"
 
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___sparc__" >&5
-echo "${ECHO_T}$ac_cv_cpp_def___sparc__" >&6; }
-if test $ac_cv_cpp_def___sparc__ = yes; then
-  CFLAGS="$CFLAGS -D__sparc__"
-  LINTFLAGS="$LINTFLAGS -D__sparc__"
-fi
- ;;
-  *powerpc*)        { echo "$as_me:$LINENO: checking whether we need to define __powerpc__" >&5
-echo $ECHO_N "checking whether we need to define __powerpc__... $ECHO_C" >&6; }
-if test "${ac_cv_cpp_def___powerpc__+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#ifndef __powerpc__
-yes
-#endif
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "yes" >/dev/null 2>&1; then
-  ac_cv_cpp_def___powerpc__=yes
-else
-  ac_cv_cpp_def___powerpc__=no
-fi
-rm -f conftest*
+ac_config_files="$ac_config_files programs/msiexec/Makefile"
 
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___powerpc__" >&5
-echo "${ECHO_T}$ac_cv_cpp_def___powerpc__" >&6; }
-if test $ac_cv_cpp_def___powerpc__ = yes; then
-  CFLAGS="$CFLAGS -D__powerpc__"
-  LINTFLAGS="$LINTFLAGS -D__powerpc__"
-fi
- ;;
-esac
+ac_config_files="$ac_config_files programs/net/Makefile"
 
-case $host_vendor in
-  *sun*) { echo "$as_me:$LINENO: checking whether we need to define __sun__" >&5
-echo $ECHO_N "checking whether we need to define __sun__... $ECHO_C" >&6; }
-if test "${ac_cv_cpp_def___sun__+set}" = set; then
-  echo $ECHO_N "(cached) $ECHO_C" >&6
-else
-  cat >conftest.$ac_ext <<_ACEOF
-/* confdefs.h.  */
-_ACEOF
-cat confdefs.h >>conftest.$ac_ext
-cat >>conftest.$ac_ext <<_ACEOF
-/* end confdefs.h.  */
-#ifndef __sun__
-yes
-#endif
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  $EGREP "yes" >/dev/null 2>&1; then
-  ac_cv_cpp_def___sun__=yes
-else
-  ac_cv_cpp_def___sun__=no
-fi
-rm -f conftest*
+ac_config_files="$ac_config_files programs/notepad/Makefile"
 
-fi
-{ echo "$as_me:$LINENO: result: $ac_cv_cpp_def___sun__" >&5
-echo "${ECHO_T}$ac_cv_cpp_def___sun__" >&6; }
-if test $ac_cv_cpp_def___sun__ = yes; then
-  CFLAGS="$CFLAGS -D__sun__"
-  LINTFLAGS="$LINTFLAGS -D__sun__"
-fi
- ;;
-esac
+ac_config_files="$ac_config_files programs/oleview/Makefile"
 
+ac_config_files="$ac_config_files programs/progman/Makefile"
 
-DEPENDENCIES="### Dependencies:
+ac_config_files="$ac_config_files programs/regedit/Makefile"
 
-.INIT: Makefile
-.BEGIN: Makefile
-Makefile: dummy
-       -\$(MAKEDEP) -C\$(SRCDIR) -S\$(TOPSRCDIR) -T\$(TOPOBJDIR) \$(EXTRAINCL) \$(DEPEND_SRCS)
+ac_config_files="$ac_config_files programs/regsvr32/Makefile"
 
-\$(ALL_OBJS): \$(IDL_H_SRCS:.idl=.h)
-\$(IDL_GEN_C_SRCS:.c=.o): \$(IDL_GEN_C_SRCS)
-\$(LEX_SRCS:.l=.yy.o): \$(LEX_SRCS:.l=.yy.c)
-\$(BISON_SRCS:.y=.tab.o): \$(BISON_SRCS:.y=.tab.c)"
+ac_config_files="$ac_config_files programs/rpcss/Makefile"
 
+ac_config_files="$ac_config_files programs/rundll32/Makefile"
 
+ac_config_files="$ac_config_files programs/spoolsv/Makefile"
 
+ac_config_files="$ac_config_files programs/start/Makefile"
 
+ac_config_files="$ac_config_files programs/taskmgr/Makefile"
 
-ac_config_commands="$ac_config_commands include/stamp-h"
+ac_config_files="$ac_config_files programs/uninstaller/Makefile"
 
+ac_config_files="$ac_config_files programs/view/Makefile"
 
-ac_config_commands="$ac_config_commands dlls/gdi32/enhmfdrv"
+ac_config_files="$ac_config_files programs/wineboot/Makefile"
 
-ac_config_commands="$ac_config_commands dlls/gdi32/mfdrv"
+ac_config_files="$ac_config_files programs/winebrowser/Makefile"
 
-ac_config_commands="$ac_config_commands dlls/kernel32/nls"
+ac_config_files="$ac_config_files programs/winecfg/Makefile"
 
-ac_config_commands="$ac_config_commands dlls/user32/resources"
+ac_config_files="$ac_config_files programs/wineconsole/Makefile"
 
-ac_config_commands="$ac_config_commands dlls/wineps.drv/data"
+ac_config_files="$ac_config_files programs/winedbg/Makefile"
 
-ac_config_commands="$ac_config_commands include/wine"
+ac_config_files="$ac_config_files programs/winedevice/Makefile"
 
+ac_config_files="$ac_config_files programs/winefile/Makefile"
 
-MAKE_RULES=Make.rules
+ac_config_files="$ac_config_files programs/winemenubuilder/Makefile"
 
+ac_config_files="$ac_config_files programs/winemine/Makefile"
 
-MAKE_DLL_RULES=dlls/Makedll.rules
+ac_config_files="$ac_config_files programs/winepath/Makefile"
 
+ac_config_files="$ac_config_files programs/winetest/Makefile"
 
-MAKE_IMPLIB_RULES=dlls/Makeimplib.rules
+ac_config_files="$ac_config_files programs/winevdm/Makefile"
 
+ac_config_files="$ac_config_files programs/winhelp/Makefile"
 
-MAKE_TEST_RULES=dlls/Maketest.rules
+ac_config_files="$ac_config_files programs/winver/Makefile"
 
+ac_config_files="$ac_config_files programs/wordpad/Makefile"
 
-MAKE_PROG_RULES=programs/Makeprog.rules
+ac_config_files="$ac_config_files programs/xcopy/Makefile"
 
+ac_config_files="$ac_config_files server/Makefile"
 
-ac_config_files="$ac_config_files Make.rules dlls/Makedll.rules dlls/Makeimplib.rules dlls/Maketest.rules programs/Makeprog.rules Makefile dlls/Makefile dlls/activeds/Makefile dlls/advapi32/Makefile dlls/advapi32/tests/Makefile dlls/advpack/Makefile dlls/advpack/tests/Makefile dlls/amstream/Makefile dlls/atl/Makefile dlls/avicap32/Makefile dlls/avifil32/Makefile dlls/cabinet/Makefile dlls/cabinet/tests/Makefile dlls/capi2032/Makefile dlls/cards/Makefile dlls/cfgmgr32/Makefile dlls/clusapi/Makefile dlls/comcat/Makefile dlls/comcat/tests/Makefile dlls/comctl32/Makefile dlls/comctl32/tests/Makefile dlls/comdlg32/Makefile dlls/comdlg32/tests/Makefile dlls/compstui/Makefile dlls/crtdll/Makefile dlls/crypt32/Makefile dlls/crypt32/tests/Makefile dlls/cryptdll/Makefile dlls/cryptnet/Makefile dlls/ctl3d32/Makefile dlls/d3d8/Makefile dlls/d3d8/tests/Makefile dlls/d3d9/Makefile dlls/d3d9/tests/Makefile dlls/d3dim/Makefile dlls/d3drm/Makefile dlls/d3dx8/Makefile dlls/d3dxof/Makefile dlls/dbghelp/Makefile dlls/dciman32/Makefile dlls/ddraw/Makefile dlls/ddraw/tests/Makefile dlls/ddrawex/Makefile dlls/devenum/Makefile dlls/dinput/Makefile dlls/dinput/tests/Makefile dlls/dinput8/Makefile dlls/dmband/Makefile dlls/dmcompos/Makefile dlls/dmime/Makefile dlls/dmloader/Makefile dlls/dmscript/Makefile dlls/dmstyle/Makefile dlls/dmsynth/Makefile dlls/dmusic/Makefile dlls/dmusic32/Makefile dlls/dnsapi/Makefile dlls/dnsapi/tests/Makefile dlls/dplay/Makefile dlls/dplayx/Makefile dlls/dpnet/Makefile dlls/dpnhpast/Makefile dlls/dsound/Makefile dlls/dsound/tests/Makefile dlls/dswave/Makefile dlls/dxdiagn/Makefile dlls/dxerr8/Makefile dlls/dxerr9/Makefile dlls/dxguid/Makefile dlls/gdi32/Makefile dlls/gdi32/tests/Makefile dlls/glu32/Makefile dlls/gphoto2.ds/Makefile dlls/hhctrl.ocx/Makefile dlls/hid/Makefile dlls/hlink/Makefile dlls/hlink/tests/Makefile dlls/iccvid/Makefile dlls/icmp/Makefile dlls/ifsmgr.vxd/Makefile dlls/imaadp32.acm/Makefile dlls/imagehlp/Makefile dlls/imm32/Makefile dlls/infosoft/Makefile dlls/infosoft/tests/Makefile dlls/inseng/Makefile dlls/iphlpapi/Makefile dlls/iphlpapi/tests/Makefile dlls/itss/Makefile dlls/itss/tests/Makefile dlls/kernel32/Makefile dlls/kernel32/tests/Makefile dlls/localspl/Makefile dlls/localspl/tests/Makefile dlls/lz32/Makefile dlls/lz32/tests/Makefile dlls/mapi32/Makefile dlls/mapi32/tests/Makefile dlls/mciavi32/Makefile dlls/mcicda/Makefile dlls/mciseq/Makefile dlls/mciwave/Makefile dlls/midimap/Makefile dlls/mlang/Makefile dlls/mlang/tests/Makefile dlls/mmdevldr.vxd/Makefile dlls/monodebg.vxd/Makefile dlls/mpr/Makefile dlls/mprapi/Makefile dlls/msacm32.drv/Makefile dlls/msacm32/Makefile dlls/msacm32/tests/Makefile dlls/msadp32.acm/Makefile dlls/mscms/Makefile dlls/mscms/tests/Makefile dlls/mscoree/Makefile dlls/msdmo/Makefile dlls/msftedit/Makefile dlls/msg711.acm/Makefile dlls/mshtml/Makefile dlls/mshtml/tests/Makefile dlls/msi/Makefile dlls/msi/tests/Makefile dlls/msimg32/Makefile dlls/msisys.ocx/Makefile dlls/msnet32/Makefile dlls/msrle32/Makefile dlls/msvcrt/Makefile dlls/msvcrt/tests/Makefile dlls/msvcrt20/Makefile dlls/msvcrt40/Makefile dlls/msvcrtd/Makefile dlls/msvcrtd/tests/Makefile dlls/msvfw32/Makefile dlls/msvidc32/Makefile dlls/mswsock/Makefile dlls/msxml3/Makefile dlls/msxml3/tests/Makefile dlls/nddeapi/Makefile dlls/netapi32/Makefile dlls/netapi32/tests/Makefile dlls/newdev/Makefile dlls/ntdll/Makefile dlls/ntdll/tests/Makefile dlls/ntdsapi/Makefile dlls/objsel/Makefile dlls/odbc32/Makefile dlls/odbccp32/Makefile dlls/ole32/Makefile dlls/ole32/tests/Makefile dlls/oleacc/Makefile dlls/oleaut32/Makefile dlls/oleaut32/tests/Makefile dlls/olecli32/Makefile dlls/oledlg/Makefile dlls/olepro32/Makefile dlls/olesvr32/Makefile dlls/opengl32/Makefile dlls/powrprof/Makefile dlls/psapi/Makefile dlls/psapi/tests/Makefile dlls/pstorec/Makefile dlls/qcap/Makefile dlls/quartz/Makefile dlls/quartz/tests/Makefile dlls/query/Makefile dlls/rasapi32/Makefile dlls/resutils/Makefile dlls/riched20/Makefile dlls/riched20/tests/Makefile dlls/riched32/Makefile dlls/rpcrt4/Makefile dlls/rpcrt4/tests/Makefile dlls/rsabase/Makefile dlls/rsabase/tests/Makefile dlls/rsaenh/Makefile dlls/rsaenh/tests/Makefile dlls/sane.ds/Makefile dlls/secur32/Makefile dlls/secur32/tests/Makefile dlls/security/Makefile dlls/sensapi/Makefile dlls/serialui/Makefile dlls/setupapi/Makefile dlls/setupapi/tests/Makefile dlls/sfc/Makefile dlls/shdoclc/Makefile dlls/shdocvw/Makefile dlls/shdocvw/tests/Makefile dlls/shell32/Makefile dlls/shell32/tests/Makefile dlls/shfolder/Makefile dlls/shlwapi/Makefile dlls/shlwapi/tests/Makefile dlls/snmpapi/Makefile dlls/spoolss/Makefile dlls/stdole2.tlb/Makefile dlls/stdole32.tlb/Makefile dlls/sti/Makefile dlls/strmiids/Makefile dlls/svrapi/Makefile dlls/tapi32/Makefile dlls/twain_32/Makefile dlls/unicows/Makefile dlls/url/Makefile dlls/urlmon/Makefile dlls/urlmon/tests/Makefile dlls/user32/Makefile dlls/user32/tests/Makefile dlls/userenv/Makefile dlls/usp10/Makefile dlls/usp10/tests/Makefile dlls/uuid/Makefile dlls/uxtheme/Makefile dlls/uxtheme/tests/Makefile dlls/vdhcp.vxd/Makefile dlls/vdmdbg/Makefile dlls/version/Makefile dlls/version/tests/Makefile dlls/vmm.vxd/Makefile dlls/vnbt.vxd/Makefile dlls/vnetbios.vxd/Makefile dlls/vtdapi.vxd/Makefile dlls/vwin32.vxd/Makefile dlls/w32skrnl/Makefile dlls/winecrt0/Makefile dlls/wined3d/Makefile dlls/winedos/Makefile dlls/winejoystick.drv/Makefile dlls/winemp3.acm/Makefile dlls/wineps.drv/Makefile dlls/winequartz.drv/Makefile dlls/winex11.drv/Makefile dlls/wininet/Makefile dlls/wininet/tests/Makefile dlls/winmm/Makefile dlls/winmm/tests/Makefile dlls/winmm/winealsa/Makefile dlls/winmm/winearts/Makefile dlls/winmm/wineaudioio/Makefile dlls/winmm/winecoreaudio/Makefile dlls/winmm/wineesd/Makefile dlls/winmm/winejack/Makefile dlls/winmm/winenas/Makefile dlls/winmm/wineoss/Makefile dlls/winnls32/Makefile dlls/winspool.drv/Makefile dlls/winspool.drv/tests/Makefile dlls/wintab32/Makefile dlls/wintrust/Makefile dlls/wintrust/tests/Makefile dlls/wldap32/Makefile dlls/wnaspi32/Makefile dlls/wow32/Makefile dlls/ws2_32/Makefile dlls/ws2_32/tests/Makefile dlls/wsock32/Makefile dlls/wtsapi32/Makefile documentation/Makefile fonts/Makefile include/Makefile libs/Makefile libs/port/Makefile libs/wine/Makefile libs/wpp/Makefile loader/Makefile programs/Makefile programs/clock/Makefile programs/cmd/Makefile programs/cmdlgtst/Makefile programs/control/Makefile programs/eject/Makefile programs/expand/Makefile programs/explorer/Makefile programs/hh/Makefile programs/icinfo/Makefile programs/iexplore/Makefile programs/msiexec/Makefile programs/notepad/Makefile programs/oleview/Makefile programs/progman/Makefile programs/regedit/Makefile programs/regsvr32/Makefile programs/rpcss/Makefile programs/rundll32/Makefile programs/start/Makefile programs/taskmgr/Makefile programs/uninstaller/Makefile programs/view/Makefile programs/wineboot/Makefile programs/winebrowser/Makefile programs/winecfg/Makefile programs/wineconsole/Makefile programs/winedbg/Makefile programs/winefile/Makefile programs/winemenubuilder/Makefile programs/winemine/Makefile programs/winepath/Makefile programs/winetest/Makefile programs/winevdm/Makefile programs/winhelp/Makefile programs/winver/Makefile programs/wordpad/Makefile server/Makefile tools/Makefile tools/widl/Makefile tools/winebuild/Makefile tools/winedump/Makefile tools/winegcc/Makefile tools/wmc/Makefile tools/wrc/Makefile"
+ac_config_files="$ac_config_files tools/Makefile"
+
+ac_config_files="$ac_config_files tools/widl/Makefile"
+
+ac_config_files="$ac_config_files tools/winebuild/Makefile"
+
+ac_config_files="$ac_config_files tools/winedump/Makefile"
+
+ac_config_files="$ac_config_files tools/winegcc/Makefile"
+
+ac_config_files="$ac_config_files tools/wmc/Makefile"
+
+ac_config_files="$ac_config_files tools/wrc/Makefile"
 
 
 cat >confcache <<\_ACEOF
@@ -20686,7 +21263,7 @@ exec 6>&1
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by Wine $as_me 0.9.28, which was
+This file was extended by Wine $as_me 0.9.40, which was
 generated by GNU Autoconf 2.61.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -20739,7 +21316,7 @@ Report bugs to <bug-autoconf@gnu.org>."
 _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF
 ac_cs_version="\\
-Wine config.status 0.9.28
+Wine config.status 0.9.40
 configured by $0, generated by GNU Autoconf 2.61,
   with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
 
@@ -20862,6 +21439,7 @@ do
     "programs/Makeprog.rules") CONFIG_FILES="$CONFIG_FILES programs/Makeprog.rules" ;;
     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
     "dlls/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/Makefile" ;;
+    "dlls/acledit/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/acledit/Makefile" ;;
     "dlls/activeds/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/activeds/Makefile" ;;
     "dlls/advapi32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/advapi32/Makefile" ;;
     "dlls/advapi32/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/advapi32/tests/Makefile" ;;
@@ -20871,6 +21449,8 @@ do
     "dlls/atl/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/atl/Makefile" ;;
     "dlls/avicap32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/avicap32/Makefile" ;;
     "dlls/avifil32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/avifil32/Makefile" ;;
+    "dlls/browseui/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/browseui/Makefile" ;;
+    "dlls/browseui/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/browseui/tests/Makefile" ;;
     "dlls/cabinet/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/cabinet/Makefile" ;;
     "dlls/cabinet/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/cabinet/tests/Makefile" ;;
     "dlls/capi2032/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/capi2032/Makefile" ;;
@@ -20884,6 +21464,7 @@ do
     "dlls/comdlg32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/comdlg32/Makefile" ;;
     "dlls/comdlg32/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/comdlg32/tests/Makefile" ;;
     "dlls/compstui/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/compstui/Makefile" ;;
+    "dlls/credui/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/credui/Makefile" ;;
     "dlls/crtdll/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/crtdll/Makefile" ;;
     "dlls/crypt32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/crypt32/Makefile" ;;
     "dlls/crypt32/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/crypt32/tests/Makefile" ;;
@@ -20896,6 +21477,7 @@ do
     "dlls/d3d9/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3d9/tests/Makefile" ;;
     "dlls/d3dim/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3dim/Makefile" ;;
     "dlls/d3drm/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3drm/Makefile" ;;
+    "dlls/d3drm/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3drm/tests/Makefile" ;;
     "dlls/d3dx8/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3dx8/Makefile" ;;
     "dlls/d3dxof/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/d3dxof/Makefile" ;;
     "dlls/dbghelp/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dbghelp/Makefile" ;;
     "dlls/dnsapi/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dnsapi/tests/Makefile" ;;
     "dlls/dplay/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dplay/Makefile" ;;
     "dlls/dplayx/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dplayx/Makefile" ;;
+    "dlls/dplayx/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dplayx/tests/Makefile" ;;
+    "dlls/dpnaddr/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dpnaddr/Makefile" ;;
     "dlls/dpnet/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dpnet/Makefile" ;;
     "dlls/dpnhpast/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dpnhpast/Makefile" ;;
     "dlls/dsound/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dsound/Makefile" ;;
     "dlls/dsound/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dsound/tests/Makefile" ;;
     "dlls/dswave/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dswave/Makefile" ;;
+    "dlls/dwmapi/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dwmapi/Makefile" ;;
     "dlls/dxdiagn/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dxdiagn/Makefile" ;;
     "dlls/dxerr8/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dxerr8/Makefile" ;;
     "dlls/dxerr9/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dxerr9/Makefile" ;;
     "dlls/dxguid/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/dxguid/Makefile" ;;
     "dlls/gdi32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/gdi32/Makefile" ;;
     "dlls/gdi32/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/gdi32/tests/Makefile" ;;
+    "dlls/gdiplus/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/gdiplus/Makefile" ;;
+    "dlls/gdiplus/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/gdiplus/tests/Makefile" ;;
     "dlls/glu32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/glu32/Makefile" ;;
     "dlls/gphoto2.ds/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/gphoto2.ds/Makefile" ;;
+    "dlls/hal/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/hal/Makefile" ;;
     "dlls/hhctrl.ocx/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/hhctrl.ocx/Makefile" ;;
     "dlls/hid/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/hid/Makefile" ;;
     "dlls/hlink/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/hlink/Makefile" ;;
     "dlls/hlink/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/hlink/tests/Makefile" ;;
+    "dlls/hnetcfg/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/hnetcfg/Makefile" ;;
     "dlls/iccvid/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/iccvid/Makefile" ;;
     "dlls/icmp/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/icmp/Makefile" ;;
     "dlls/ifsmgr.vxd/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/ifsmgr.vxd/Makefile" ;;
@@ -20954,6 +21543,8 @@ do
     "dlls/kernel32/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/kernel32/tests/Makefile" ;;
     "dlls/localspl/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/localspl/Makefile" ;;
     "dlls/localspl/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/localspl/tests/Makefile" ;;
+    "dlls/localui/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/localui/Makefile" ;;
+    "dlls/localui/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/localui/tests/Makefile" ;;
     "dlls/lz32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/lz32/Makefile" ;;
     "dlls/lz32/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/lz32/tests/Makefile" ;;
     "dlls/mapi32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/mapi32/Makefile" ;;
     "dlls/ntdll/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/ntdll/Makefile" ;;
     "dlls/ntdll/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/ntdll/tests/Makefile" ;;
     "dlls/ntdsapi/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/ntdsapi/Makefile" ;;
+    "dlls/ntoskrnl.exe/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/ntoskrnl.exe/Makefile" ;;
+    "dlls/ntprint/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/ntprint/Makefile" ;;
+    "dlls/ntprint/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/ntprint/tests/Makefile" ;;
     "dlls/objsel/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/objsel/Makefile" ;;
     "dlls/odbc32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/odbc32/Makefile" ;;
     "dlls/odbccp32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/odbccp32/Makefile" ;;
+    "dlls/odbccp32/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/odbccp32/tests/Makefile" ;;
     "dlls/ole32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/ole32/Makefile" ;;
     "dlls/ole32/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/ole32/tests/Makefile" ;;
     "dlls/oleacc/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/oleacc/Makefile" ;;
@@ -21018,7 +21613,9 @@ do
     "dlls/olepro32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/olepro32/Makefile" ;;
     "dlls/olesvr32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/olesvr32/Makefile" ;;
     "dlls/opengl32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/opengl32/Makefile" ;;
+    "dlls/pdh/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/pdh/Makefile" ;;
     "dlls/powrprof/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/powrprof/Makefile" ;;
+    "dlls/printui/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/printui/Makefile" ;;
     "dlls/psapi/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/psapi/Makefile" ;;
     "dlls/psapi/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/psapi/tests/Makefile" ;;
     "dlls/pstorec/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/pstorec/Makefile" ;;
     "dlls/rsaenh/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/rsaenh/Makefile" ;;
     "dlls/rsaenh/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/rsaenh/tests/Makefile" ;;
     "dlls/sane.ds/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/sane.ds/Makefile" ;;
+    "dlls/schannel/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/schannel/Makefile" ;;
+    "dlls/schannel/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/schannel/tests/Makefile" ;;
     "dlls/secur32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/secur32/Makefile" ;;
     "dlls/secur32/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/secur32/tests/Makefile" ;;
     "dlls/security/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/security/Makefile" ;;
     "dlls/sensapi/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/sensapi/Makefile" ;;
     "dlls/serialui/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/serialui/Makefile" ;;
+    "dlls/serialui/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/serialui/tests/Makefile" ;;
     "dlls/setupapi/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/setupapi/Makefile" ;;
     "dlls/setupapi/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/setupapi/tests/Makefile" ;;
     "dlls/sfc/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/sfc/Makefile" ;;
+    "dlls/sfc_os/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/sfc_os/Makefile" ;;
     "dlls/shdoclc/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/shdoclc/Makefile" ;;
     "dlls/shdocvw/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/shdocvw/Makefile" ;;
     "dlls/shdocvw/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/shdocvw/tests/Makefile" ;;
     "dlls/shlwapi/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/shlwapi/Makefile" ;;
     "dlls/shlwapi/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/shlwapi/tests/Makefile" ;;
     "dlls/snmpapi/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/snmpapi/Makefile" ;;
+    "dlls/snmpapi/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/snmpapi/tests/Makefile" ;;
     "dlls/spoolss/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/spoolss/Makefile" ;;
     "dlls/stdole2.tlb/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/stdole2.tlb/Makefile" ;;
     "dlls/stdole32.tlb/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/stdole32.tlb/Makefile" ;;
     "dlls/sti/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/sti/Makefile" ;;
     "dlls/strmiids/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/strmiids/Makefile" ;;
     "dlls/svrapi/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/svrapi/Makefile" ;;
+    "dlls/sxs/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/sxs/Makefile" ;;
     "dlls/tapi32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/tapi32/Makefile" ;;
     "dlls/twain_32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/twain_32/Makefile" ;;
     "dlls/unicows/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/unicows/Makefile" ;;
     "dlls/vtdapi.vxd/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/vtdapi.vxd/Makefile" ;;
     "dlls/vwin32.vxd/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/vwin32.vxd/Makefile" ;;
     "dlls/w32skrnl/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/w32skrnl/Makefile" ;;
+    "dlls/winealsa.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winealsa.drv/Makefile" ;;
+    "dlls/wineaudioio.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wineaudioio.drv/Makefile" ;;
+    "dlls/winecoreaudio.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winecoreaudio.drv/Makefile" ;;
     "dlls/winecrt0/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winecrt0/Makefile" ;;
     "dlls/wined3d/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wined3d/Makefile" ;;
     "dlls/winedos/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winedos/Makefile" ;;
+    "dlls/wineesd.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wineesd.drv/Makefile" ;;
+    "dlls/winejack.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winejack.drv/Makefile" ;;
     "dlls/winejoystick.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winejoystick.drv/Makefile" ;;
     "dlls/winemp3.acm/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winemp3.acm/Makefile" ;;
+    "dlls/winenas.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winenas.drv/Makefile" ;;
+    "dlls/wineoss.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wineoss.drv/Makefile" ;;
     "dlls/wineps.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wineps.drv/Makefile" ;;
     "dlls/winequartz.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winequartz.drv/Makefile" ;;
     "dlls/winex11.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winex11.drv/Makefile" ;;
+    "dlls/wing32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wing32/Makefile" ;;
     "dlls/wininet/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wininet/Makefile" ;;
     "dlls/wininet/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wininet/tests/Makefile" ;;
     "dlls/winmm/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/Makefile" ;;
     "dlls/winmm/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/tests/Makefile" ;;
-    "dlls/winmm/winealsa/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/winealsa/Makefile" ;;
-    "dlls/winmm/winearts/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/winearts/Makefile" ;;
-    "dlls/winmm/wineaudioio/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/wineaudioio/Makefile" ;;
-    "dlls/winmm/winecoreaudio/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/winecoreaudio/Makefile" ;;
-    "dlls/winmm/wineesd/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/wineesd/Makefile" ;;
-    "dlls/winmm/winejack/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/winejack/Makefile" ;;
-    "dlls/winmm/winenas/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/winenas/Makefile" ;;
-    "dlls/winmm/wineoss/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winmm/wineoss/Makefile" ;;
     "dlls/winnls32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winnls32/Makefile" ;;
+    "dlls/winscard/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winscard/Makefile" ;;
     "dlls/winspool.drv/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winspool.drv/Makefile" ;;
     "dlls/winspool.drv/tests/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/winspool.drv/tests/Makefile" ;;
     "dlls/wintab32/Makefile") CONFIG_FILES="$CONFIG_FILES dlls/wintab32/Makefile" ;;
@@ -21138,6 +21742,7 @@ do
     "programs/icinfo/Makefile") CONFIG_FILES="$CONFIG_FILES programs/icinfo/Makefile" ;;
     "programs/iexplore/Makefile") CONFIG_FILES="$CONFIG_FILES programs/iexplore/Makefile" ;;
     "programs/msiexec/Makefile") CONFIG_FILES="$CONFIG_FILES programs/msiexec/Makefile" ;;
+    "programs/net/Makefile") CONFIG_FILES="$CONFIG_FILES programs/net/Makefile" ;;
     "programs/notepad/Makefile") CONFIG_FILES="$CONFIG_FILES programs/notepad/Makefile" ;;
     "programs/oleview/Makefile") CONFIG_FILES="$CONFIG_FILES programs/oleview/Makefile" ;;
     "programs/progman/Makefile") CONFIG_FILES="$CONFIG_FILES programs/progman/Makefile" ;;
@@ -21145,6 +21750,7 @@ do
     "programs/regsvr32/Makefile") CONFIG_FILES="$CONFIG_FILES programs/regsvr32/Makefile" ;;
     "programs/rpcss/Makefile") CONFIG_FILES="$CONFIG_FILES programs/rpcss/Makefile" ;;
     "programs/rundll32/Makefile") CONFIG_FILES="$CONFIG_FILES programs/rundll32/Makefile" ;;
+    "programs/spoolsv/Makefile") CONFIG_FILES="$CONFIG_FILES programs/spoolsv/Makefile" ;;
     "programs/start/Makefile") CONFIG_FILES="$CONFIG_FILES programs/start/Makefile" ;;
     "programs/taskmgr/Makefile") CONFIG_FILES="$CONFIG_FILES programs/taskmgr/Makefile" ;;
     "programs/uninstaller/Makefile") CONFIG_FILES="$CONFIG_FILES programs/uninstaller/Makefile" ;;
@@ -21154,6 +21760,7 @@ do
     "programs/winecfg/Makefile") CONFIG_FILES="$CONFIG_FILES programs/winecfg/Makefile" ;;
     "programs/wineconsole/Makefile") CONFIG_FILES="$CONFIG_FILES programs/wineconsole/Makefile" ;;
     "programs/winedbg/Makefile") CONFIG_FILES="$CONFIG_FILES programs/winedbg/Makefile" ;;
+    "programs/winedevice/Makefile") CONFIG_FILES="$CONFIG_FILES programs/winedevice/Makefile" ;;
     "programs/winefile/Makefile") CONFIG_FILES="$CONFIG_FILES programs/winefile/Makefile" ;;
     "programs/winemenubuilder/Makefile") CONFIG_FILES="$CONFIG_FILES programs/winemenubuilder/Makefile" ;;
     "programs/winemine/Makefile") CONFIG_FILES="$CONFIG_FILES programs/winemine/Makefile" ;;
@@ -21163,6 +21770,7 @@ do
     "programs/winhelp/Makefile") CONFIG_FILES="$CONFIG_FILES programs/winhelp/Makefile" ;;
     "programs/winver/Makefile") CONFIG_FILES="$CONFIG_FILES programs/winver/Makefile" ;;
     "programs/wordpad/Makefile") CONFIG_FILES="$CONFIG_FILES programs/wordpad/Makefile" ;;
+    "programs/xcopy/Makefile") CONFIG_FILES="$CONFIG_FILES programs/xcopy/Makefile" ;;
     "server/Makefile") CONFIG_FILES="$CONFIG_FILES server/Makefile" ;;
     "tools/Makefile") CONFIG_FILES="$CONFIG_FILES tools/Makefile" ;;
     "tools/widl/Makefile") CONFIG_FILES="$CONFIG_FILES tools/widl/Makefile" ;;
@@ -21304,10 +21912,7 @@ X_CFLAGS!$X_CFLAGS$ac_delim
 X_PRE_LIBS!$X_PRE_LIBS$ac_delim
 X_LIBS!$X_LIBS$ac_delim
 X_EXTRA_LIBS!$X_EXTRA_LIBS$ac_delim
-LEX!$LEX$ac_delim
-LEX_OUTPUT_ROOT!$LEX_OUTPUT_ROOT$ac_delim
-LEXLIB!$LEXLIB$ac_delim
-XLEX!$XLEX$ac_delim
+FLEX!$FLEX$ac_delim
 BISON!$BISON$ac_delim
 AS!$AS$ac_delim
 ac_ct_AS!$ac_ct_AS$ac_delim
@@ -21320,6 +21925,9 @@ LN_S!$LN_S$ac_delim
 LN!$LN$ac_delim
 GREP!$GREP$ac_delim
 EGREP!$EGREP$ac_delim
+LDCONFIG!$LDCONFIG$ac_delim
+INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim
+INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim
 _ACEOF
 
   if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 82; then
@@ -21381,9 +21989,6 @@ _ACEOF
 ac_delim='%!_!# '
 for ac_last_try in false false false false false :; do
   cat >conf$$subs.sed <<_ACEOF
-LDCONFIG!$LDCONFIG$ac_delim
-INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim
-INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim
 INSTALL_DATA!$INSTALL_DATA$ac_delim
 LINT!$LINT$ac_delim
 LINTFLAGS!$LINTFLAGS$ac_delim
@@ -21397,6 +22002,27 @@ OPENGLFILES!$OPENGLFILES$ac_delim
 GLU32FILES!$GLU32FILES$ac_delim
 OPENGL_LIBS!$OPENGL_LIBS$ac_delim
 QUARTZFILES!$QUARTZFILES$ac_delim
+DLLEXT!$DLLEXT$ac_delim
+DLLFLAGS!$DLLFLAGS$ac_delim
+LDSHARED!$LDSHARED$ac_delim
+LDDLLFLAGS!$LDDLLFLAGS$ac_delim
+LIBEXT!$LIBEXT$ac_delim
+IMPLIBEXT!$IMPLIBEXT$ac_delim
+LDRPATH_INSTALL!$LDRPATH_INSTALL$ac_delim
+LDRPATH_LOCAL!$LDRPATH_LOCAL$ac_delim
+LDD!$LDD$ac_delim
+DLLTOOL!$DLLTOOL$ac_delim
+DLLWRAP!$DLLWRAP$ac_delim
+MINGWAR!$MINGWAR$ac_delim
+COREFOUNDATIONLIB!$COREFOUNDATIONLIB$ac_delim
+IOKITLIB!$IOKITLIB$ac_delim
+LDEXECFLAGS!$LDEXECFLAGS$ac_delim
+DISKARBITRATIONLIB!$DISKARBITRATIONLIB$ac_delim
+COREAUDIO!$COREAUDIO$ac_delim
+CARBONLIB!$CARBONLIB$ac_delim
+CROSSTEST!$CROSSTEST$ac_delim
+CROSSCC!$CROSSCC$ac_delim
+CROSSWINDRES!$CROSSWINDRES$ac_delim
 NASLIBS!$NASLIBS$ac_delim
 XML2LIBS!$XML2LIBS$ac_delim
 XML2INCL!$XML2INCL$ac_delim
@@ -21404,7 +22030,6 @@ XSLTLIBS!$XSLTLIBS$ac_delim
 XSLTINCL!$XSLTINCL$ac_delim
 HALINCL!$HALINCL$ac_delim
 sane_devel!$sane_devel$ac_delim
-SANELIBS!$SANELIBS$ac_delim
 SANEINCL!$SANEINCL$ac_delim
 gphoto2_devel!$gphoto2_devel$ac_delim
 gphoto2port_devel!$gphoto2port_devel$ac_delim
@@ -21419,9 +22044,6 @@ FREETYPEINCL!$FREETYPEINCL$ac_delim
 ft_devel!$ft_devel$ac_delim
 ft_devel2!$ft_devel2$ac_delim
 FONTSSUBDIRS!$FONTSSUBDIRS$ac_delim
-ARTSCCONFIG!$ARTSCCONFIG$ac_delim
-ARTSLIBS!$ARTSLIBS$ac_delim
-ARTSINCL!$ARTSINCL$ac_delim
 ESDCONFIG!$ESDCONFIG$ac_delim
 ESDLIBS!$ESDLIBS$ac_delim
 ESDINCL!$ESDINCL$ac_delim
@@ -21429,30 +22051,11 @@ ALSALIBS!$ALSALIBS$ac_delim
 AUDIOIOLIBS!$AUDIOIOLIBS$ac_delim
 EXTRACFLAGS!$EXTRACFLAGS$ac_delim
 BUILTINFLAG!$BUILTINFLAG$ac_delim
-DLLEXT!$DLLEXT$ac_delim
-DLLFLAGS!$DLLFLAGS$ac_delim
-LDSHARED!$LDSHARED$ac_delim
-LDDLLFLAGS!$LDDLLFLAGS$ac_delim
-LIBEXT!$LIBEXT$ac_delim
-IMPLIBEXT!$IMPLIBEXT$ac_delim
-LIBWINE_LDFLAGS!$LIBWINE_LDFLAGS$ac_delim
-DLLTOOL!$DLLTOOL$ac_delim
-DLLWRAP!$DLLWRAP$ac_delim
-COREFOUNDATIONLIB!$COREFOUNDATIONLIB$ac_delim
-IOKITLIB!$IOKITLIB$ac_delim
-LDEXECFLAGS!$LDEXECFLAGS$ac_delim
-DISKARBITRATIONLIB!$DISKARBITRATIONLIB$ac_delim
-COREAUDIO!$COREAUDIO$ac_delim
-CARBONLIB!$CARBONLIB$ac_delim
-CROSSTEST!$CROSSTEST$ac_delim
-CROSSCC!$CROSSCC$ac_delim
-CROSSWINDRES!$CROSSWINDRES$ac_delim
 LDPATH!$LDPATH$ac_delim
 CRTLIBS!$CRTLIBS$ac_delim
 SOCKETLIBS!$SOCKETLIBS$ac_delim
 MAIN_BINARY!$MAIN_BINARY$ac_delim
 EXTRA_BINARIES!$EXTRA_BINARIES$ac_delim
-LDD!$LDD$ac_delim
 LIBDL!$LIBDL$ac_delim
 LIBPOLL!$LIBPOLL$ac_delim
 DEPENDENCIES!$DEPENDENCIES$ac_delim
@@ -21460,7 +22063,7 @@ LIBOBJS!$LIBOBJS$ac_delim
 LTLIBOBJS!$LTLIBOBJS$ac_delim
 _ACEOF
 
-  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 77; then
+  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 72; then
     break
   elif $ac_last_try; then
     { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
@@ -22137,7 +22740,6 @@ echo "$as_me: WARNING: Fonts will not be built. Dialog text may be invisible or
 fi
 
 if test -z "$ALSALIBS" -a \
-        -z "$ARTSC_LIBS" -a \
         -z "$AUDIOIOLIBS" -a \
         -z "$NASLIBS" -a \
         -z "$ESD_LIBS" -a \
@@ -22151,8 +22753,8 @@ then
 echo "$as_me: WARNING: No sound system was found. Windows applications will be silent." >&2;}
   { echo "$as_me:$LINENO: WARNING: The currently supported sound systems are:" >&5
 echo "$as_me: WARNING: The currently supported sound systems are:" >&2;}
-  { echo "$as_me:$LINENO: WARNING: ALSA, ARTS, EsounD, AudioIO, Jack, NAS and OSS" >&5
-echo "$as_me: WARNING: ALSA, ARTS, EsounD, AudioIO, Jack, NAS and OSS" >&2;}
+  { echo "$as_me:$LINENO: WARNING: ALSA, EsounD, AudioIO, Jack, NAS and OSS" >&5
+echo "$as_me: WARNING: ALSA, EsounD, AudioIO, Jack, NAS and OSS" >&2;}
 fi
 
 echo