configure
changeset 12088 399cc39583cc
parent 12081 277e57c09ff4
child 12130 24142c5073a4
equal deleted inserted replaced
12087:cb546477e34f 12088:399cc39583cc
   866 enable_pthreads
   866 enable_pthreads
   867 enable_pthread_sem
   867 enable_pthread_sem
   868 enable_directx
   868 enable_directx
   869 enable_wasapi
   869 enable_wasapi
   870 enable_sdl_dlopen
   870 enable_sdl_dlopen
       
   871 enable_hidapi
   871 enable_clock_gettime
   872 enable_clock_gettime
   872 enable_rpath
   873 enable_rpath
   873 enable_render_d3d
   874 enable_render_d3d
   874 '
   875 '
   875       ac_precious_vars='build_alias
   876       ac_precious_vars='build_alias
  1621                           [[default=yes]]
  1622                           [[default=yes]]
  1622   --enable-pthread-sem    use pthread semaphores [[default=yes]]
  1623   --enable-pthread-sem    use pthread semaphores [[default=yes]]
  1623   --enable-directx        use DirectX for Windows audio/video [[default=yes]]
  1624   --enable-directx        use DirectX for Windows audio/video [[default=yes]]
  1624   --enable-wasapi         use the Windows WASAPI audio driver [[default=yes]]
  1625   --enable-wasapi         use the Windows WASAPI audio driver [[default=yes]]
  1625   --enable-sdl-dlopen     use dlopen for shared object loading [[default=yes]]
  1626   --enable-sdl-dlopen     use dlopen for shared object loading [[default=yes]]
       
  1627   --enable-hidapi         use HIDAPI for low level joystick drivers
       
  1628                           [[default=no]]
  1626   --enable-clock_gettime  use clock_gettime() instead of gettimeofday() on
  1629   --enable-clock_gettime  use clock_gettime() instead of gettimeofday() on
  1627                           UNIX [[default=yes]]
  1630                           UNIX [[default=yes]]
  1628   --enable-rpath          use an rpath when linking SDL [[default=yes]]
  1631   --enable-rpath          use an rpath when linking SDL [[default=yes]]
  1629   --enable-render-d3d     enable the Direct3D render driver [[default=yes]]
  1632   --enable-render-d3d     enable the Direct3D render driver [[default=yes]]
  1630 
  1633 
 16771 $as_echo "#define HAVE_SA_SIGACTION 1" >>confdefs.h
 16774 $as_echo "#define HAVE_SA_SIGACTION 1" >>confdefs.h
 16772 
 16775 
 16773 fi
 16776 fi
 16774 
 16777 
 16775 
 16778 
 16776 	    for ac_header in libunwind.h
 16779         for ac_header in libunwind.h
 16777 do :
 16780 do :
 16778   ac_fn_c_check_header_mongrel "$LINENO" "libunwind.h" "ac_cv_header_libunwind_h" "$ac_includes_default"
 16781   ac_fn_c_check_header_mongrel "$LINENO" "libunwind.h" "ac_cv_header_libunwind_h" "$ac_includes_default"
 16779 if test "x$ac_cv_header_libunwind_h" = xyes; then :
 16782 if test "x$ac_cv_header_libunwind_h" = xyes; then :
 16780   cat >>confdefs.h <<_ACEOF
 16783   cat >>confdefs.h <<_ACEOF
 16781 #define HAVE_LIBUNWIND_H 1
 16784 #define HAVE_LIBUNWIND_H 1
 18375 
 18378 
 18376 
 18379 
 18377         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PulseAudio $PULSEAUDIO_REQUIRED_VERSION support" >&5
 18380         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PulseAudio $PULSEAUDIO_REQUIRED_VERSION support" >&5
 18378 $as_echo_n "checking for PulseAudio $PULSEAUDIO_REQUIRED_VERSION support... " >&6; }
 18381 $as_echo_n "checking for PulseAudio $PULSEAUDIO_REQUIRED_VERSION support... " >&6; }
 18379         if test x$PKG_CONFIG != xno; then
 18382         if test x$PKG_CONFIG != xno; then
 18380         if $PKG_CONFIG --atleast-pkgconfig-version 0.7 && $PKG_CONFIG --atleast-version $PULSEAUDIO_REQUIRED_VERSION libpulse-simple; then
 18383             if $PKG_CONFIG --atleast-pkgconfig-version 0.7 && $PKG_CONFIG --atleast-version $PULSEAUDIO_REQUIRED_VERSION libpulse-simple; then
 18381                 PULSEAUDIO_CFLAGS=`$PKG_CONFIG --cflags libpulse-simple`
 18384                 PULSEAUDIO_CFLAGS=`$PKG_CONFIG --cflags libpulse-simple`
 18382                 PULSEAUDIO_LIBS=`$PKG_CONFIG --libs libpulse-simple`
 18385                 PULSEAUDIO_LIBS=`$PKG_CONFIG --libs libpulse-simple`
 18383                 audio_pulseaudio=yes
 18386                 audio_pulseaudio=yes
 18384             fi
 18387             fi
 18385         fi
 18388         fi
 20461 $as_echo_n "checking for XGenericEvent... " >&6; }
 20464 $as_echo_n "checking for XGenericEvent... " >&6; }
 20462             have_XGenericEvent=no
 20465             have_XGenericEvent=no
 20463             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 20466             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 20464 /* end confdefs.h.  */
 20467 /* end confdefs.h.  */
 20465 
 20468 
 20466               	#include <X11/Xlib.h>
 20469                 #include <X11/Xlib.h>
 20467 
 20470 
 20468 int
 20471 int
 20469 main ()
 20472 main ()
 20470 {
 20473 {
 20471 
 20474 
 20805 
 20808 
 20806 $as_echo "#define SDL_VIDEO_DRIVER_X11_XINPUT2 1" >>confdefs.h
 20809 $as_echo "#define SDL_VIDEO_DRIVER_X11_XINPUT2 1" >>confdefs.h
 20807 
 20810 
 20808                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xinput2 multitouch" >&5
 20811                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xinput2 multitouch" >&5
 20809 $as_echo_n "checking for xinput2 multitouch... " >&6; }
 20812 $as_echo_n "checking for xinput2 multitouch... " >&6; }
 20810             	have_xinput2_multitouch=no
 20813                 have_xinput2_multitouch=no
 20811             	cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 20814                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 20812 /* end confdefs.h.  */
 20815 /* end confdefs.h.  */
 20813 
 20816 
 20814               		#include <X11/Xlib.h>
 20817                     #include <X11/Xlib.h>
 20815              		#include <X11/Xproto.h>
 20818                     #include <X11/Xproto.h>
 20816 			#include <X11/extensions/XInput2.h>
 20819                     #include <X11/extensions/XInput2.h>
 20817 
 20820 
 20818 int
 20821 int
 20819 main ()
 20822 main ()
 20820 {
 20823 {
 20821 
 20824 
 20826   return 0;
 20829   return 0;
 20827 }
 20830 }
 20828 _ACEOF
 20831 _ACEOF
 20829 if ac_fn_c_try_compile "$LINENO"; then :
 20832 if ac_fn_c_try_compile "$LINENO"; then :
 20830 
 20833 
 20831             	have_xinput2_multitouch=yes
 20834                     have_xinput2_multitouch=yes
 20832             	$as_echo "#define SDL_VIDEO_DRIVER_X11_XINPUT2_SUPPORTS_MULTITOUCH 1" >>confdefs.h
 20835                     $as_echo "#define SDL_VIDEO_DRIVER_X11_XINPUT2_SUPPORTS_MULTITOUCH 1" >>confdefs.h
 20833 
 20836 
 20834                 SUMMARY_video_x11="${SUMMARY_video_x11} xinput2_multitouch"
 20837                     SUMMARY_video_x11="${SUMMARY_video_x11} xinput2_multitouch"
 20835 
 20838 
 20836 fi
 20839 fi
 20837 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 20840 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
 20838             	{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_xinput2_multitouch" >&5
 20841                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_xinput2_multitouch" >&5
 20839 $as_echo "$have_xinput2_multitouch" >&6; }
 20842 $as_echo "$have_xinput2_multitouch" >&6; }
 20840             fi
 20843             fi
 20841             # Check whether --enable-video-x11-xrandr was given.
 20844             # Check whether --enable-video-x11-xrandr was given.
 20842 if test "${enable_video_x11_xrandr+set}" = set; then :
 20845 if test "${enable_video_x11_xrandr+set}" = set; then :
 20843   enableval=$enable_video_x11_xrandr;
 20846   enableval=$enable_video_x11_xrandr;
 23726             fi
 23729             fi
 23727         ;;
 23730         ;;
 23728     esac
 23731     esac
 23729 }
 23732 }
 23730 
 23733 
       
 23734 CheckHIDAPI()
       
 23735 {
       
 23736     # The hidraw support doesn't catch Xbox, PS4 and Nintendo controllers,
       
 23737     # so we'll just use libusb when it's available.
       
 23738     #
       
 23739     # Except that libusb requires root permissions to open devices, so that's not generally useful, and we'll disable this by default.
       
 23740     # Check whether --enable-hidapi was given.
       
 23741 if test "${enable_hidapi+set}" = set; then :
       
 23742   enableval=$enable_hidapi;
       
 23743 else
       
 23744   enable_hidapi=no
       
 23745 fi
       
 23746 
       
 23747     if test x$enable_joystick = xyes -a x$enable_hidapi = xyes; then
       
 23748         hidapi_support=no
       
 23749         # Extract the first word of "pkg-config", so it can be a program name with args.
       
 23750 set dummy pkg-config; ac_word=$2
       
 23751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
       
 23752 $as_echo_n "checking for $ac_word... " >&6; }
       
 23753 if ${ac_cv_path_PKG_CONFIG+:} false; then :
       
 23754   $as_echo_n "(cached) " >&6
       
 23755 else
       
 23756   case $PKG_CONFIG in
       
 23757   [\\/]* | ?:[\\/]*)
       
 23758   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
       
 23759   ;;
       
 23760   *)
       
 23761   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
       
 23762 for as_dir in $PATH
       
 23763 do
       
 23764   IFS=$as_save_IFS
       
 23765   test -z "$as_dir" && as_dir=.
       
 23766     for ac_exec_ext in '' $ac_executable_extensions; do
       
 23767   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
       
 23768     ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
       
 23769     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
       
 23770     break 2
       
 23771   fi
       
 23772 done
       
 23773   done
       
 23774 IFS=$as_save_IFS
       
 23775 
       
 23776   test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
       
 23777   ;;
       
 23778 esac
       
 23779 fi
       
 23780 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
       
 23781 if test -n "$PKG_CONFIG"; then
       
 23782   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
       
 23783 $as_echo "$PKG_CONFIG" >&6; }
       
 23784 else
       
 23785   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
       
 23786 $as_echo "no" >&6; }
       
 23787 fi
       
 23788 
       
 23789 
       
 23790         if test x$PKG_CONFIG != xno; then
       
 23791             LIBUSB_CFLAGS=`$PKG_CONFIG --cflags libusb-1.0`
       
 23792             LIBUSB_LDFLAGS=`$PKG_CONFIG --libs libusb-1.0`
       
 23793             save_CFLAGS="$CFLAGS"
       
 23794             CFLAGS="$save_CFLAGS $LIBUSB_CFLAGS"
       
 23795             ac_fn_c_check_header_mongrel "$LINENO" "libusb.h" "ac_cv_header_libusb_h" "$ac_includes_default"
       
 23796 if test "x$ac_cv_header_libusb_h" = xyes; then :
       
 23797   have_libusb_h=yes
       
 23798 fi
       
 23799 
       
 23800 
       
 23801             CFLAGS="$save_CFLAGS"
       
 23802         fi
       
 23803         if test x$have_libusb_h = xyes; then
       
 23804             hidapi_support=yes
       
 23805 
       
 23806 $as_echo "#define SDL_JOYSTICK_HIDAPI 1" >>confdefs.h
       
 23807 
       
 23808             EXTRA_CFLAGS="$EXTRA_CFLAGS -I$srcdir/src/hidapi/hidapi"
       
 23809             SOURCES="$SOURCES $srcdir/src/joystick/hidapi/*.c"
       
 23810             SOURCES="$SOURCES $srcdir/src/hidapi/libusb/hid.c"
       
 23811             EXTRA_CFLAGS="$EXTRA_CFLAGS $LIBUSB_CFLAGS"
       
 23812             EXTRA_LDFLAGS="$EXTRA_LDFLAGS $LIBUSB_LDFLAGS"
       
 23813         fi
       
 23814         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hidapi support" >&5
       
 23815 $as_echo_n "checking for hidapi support... " >&6; }
       
 23816         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hidapi_support" >&5
       
 23817 $as_echo "$hidapi_support" >&6; }
       
 23818     fi
       
 23819 }
       
 23820 
 23731 CheckClockGettime()
 23821 CheckClockGettime()
 23732 {
 23822 {
 23733     # Check whether --enable-clock_gettime was given.
 23823     # Check whether --enable-clock_gettime was given.
 23734 if test "${enable_clock_gettime+set}" = set; then :
 23824 if test "${enable_clock_gettime+set}" = set; then :
 23735   enableval=$enable_clock_gettime;
 23825   enableval=$enable_clock_gettime;
 23937               CheckInputKD
 24027               CheckInputKD
 23938           ;;
 24028           ;;
 23939         esac
 24029         esac
 23940         CheckTslib
 24030         CheckTslib
 23941         CheckUSBHID
 24031         CheckUSBHID
       
 24032         CheckHIDAPI
 23942         CheckPTHREAD
 24033         CheckPTHREAD
 23943         CheckClockGettime
 24034         CheckClockGettime
 23944         CheckLinuxVersion
 24035         CheckLinuxVersion
 23945         CheckRPATH
 24036         CheckRPATH
 23946         CheckVivanteVideo
 24037         CheckVivanteVideo
 24512         # Set up files for the joystick library
 24603         # Set up files for the joystick library
 24513         if test x$enable_joystick = xyes; then
 24604         if test x$enable_joystick = xyes; then
 24514 
 24605 
 24515 $as_echo "#define SDL_JOYSTICK_IOKIT 1" >>confdefs.h
 24606 $as_echo "#define SDL_JOYSTICK_IOKIT 1" >>confdefs.h
 24516 
 24607 
       
 24608 
       
 24609 $as_echo "#define SDL_JOYSTICK_HIDAPI 1" >>confdefs.h
       
 24610 
 24517             SOURCES="$SOURCES $srcdir/src/joystick/darwin/*.c"
 24611             SOURCES="$SOURCES $srcdir/src/joystick/darwin/*.c"
       
 24612             SOURCES="$SOURCES $srcdir/src/joystick/hidapi/*.c"
       
 24613             SOURCES="$SOURCES $srcdir/src/hidapi/mac/hid.c"
       
 24614             EXTRA_CFLAGS="$EXTRA_CFLAGS -I$srcdir/src/hidapi/hidapi"
 24518             have_joystick=yes
 24615             have_joystick=yes
 24519         fi
 24616         fi
 24520         # Set up files for the haptic library
 24617         # Set up files for the haptic library
 24521         if test x$enable_haptic = xyes; then
 24618         if test x$enable_haptic = xyes; then
 24522 
 24619