configure
changeset 6870 31dee5110b4d
parent 6849 b9dcf6242476
child 6960 e4e9fbf6f333
     1.1 --- a/configure	Tue Feb 12 14:53:47 2013 -0800
     1.2 +++ b/configure	Tue Feb 12 16:17:24 2013 -0800
     1.3 @@ -813,6 +813,7 @@
     1.4  enable_video_opengl
     1.5  enable_video_opengles
     1.6  enable_libudev
     1.7 +enable_dbus
     1.8  enable_input_tslib
     1.9  enable_pthreads
    1.10  enable_pthread_sem
    1.11 @@ -1536,6 +1537,7 @@
    1.12    --enable-video-opengl   include OpenGL support [[default=yes]]
    1.13    --enable-video-opengles include OpenGL ES support [[default=yes]]
    1.14    --enable-libudev        enable libudev support [[default=yes]]
    1.15 +  --enable-dbus           enable D-Bus support [[default=yes]]
    1.16    --enable-input-tslib    use the Touchscreen library for input
    1.17                            [[default=yes]]
    1.18    --enable-pthreads       use POSIX threads for multi-threading
    1.19 @@ -20740,6 +20742,80 @@
    1.20      fi
    1.21  }
    1.22  
    1.23 +CheckDBus()
    1.24 +{
    1.25 +    # Check whether --enable-dbus was given.
    1.26 +if test "${enable_dbus+set}" = set; then :
    1.27 +  enableval=$enable_dbus;
    1.28 +else
    1.29 +  enable_dbus=yes
    1.30 +fi
    1.31 +
    1.32 +    if test x$enable_dbus = xyes; then
    1.33 +        # Extract the first word of "pkg-config", so it can be a program name with args.
    1.34 +set dummy pkg-config; ac_word=$2
    1.35 +{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
    1.36 +$as_echo_n "checking for $ac_word... " >&6; }
    1.37 +if ${ac_cv_path_PKG_CONFIG+:} false; then :
    1.38 +  $as_echo_n "(cached) " >&6
    1.39 +else
    1.40 +  case $PKG_CONFIG in
    1.41 +  [\\/]* | ?:[\\/]*)
    1.42 +  ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
    1.43 +  ;;
    1.44 +  *)
    1.45 +  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
    1.46 +for as_dir in $PATH
    1.47 +do
    1.48 +  IFS=$as_save_IFS
    1.49 +  test -z "$as_dir" && as_dir=.
    1.50 +    for ac_exec_ext in '' $ac_executable_extensions; do
    1.51 +  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    1.52 +    ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
    1.53 +    $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
    1.54 +    break 2
    1.55 +  fi
    1.56 +done
    1.57 +  done
    1.58 +IFS=$as_save_IFS
    1.59 +
    1.60 +  test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
    1.61 +  ;;
    1.62 +esac
    1.63 +fi
    1.64 +PKG_CONFIG=$ac_cv_path_PKG_CONFIG
    1.65 +if test -n "$PKG_CONFIG"; then
    1.66 +  { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
    1.67 +$as_echo "$PKG_CONFIG" >&6; }
    1.68 +else
    1.69 +  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
    1.70 +$as_echo "no" >&6; }
    1.71 +fi
    1.72 +
    1.73 +
    1.74 +        if test x$PKG_CONFIG != xno; then
    1.75 +            DBUS_CFLAGS=`$PKG_CONFIG --cflags dbus-1`
    1.76 +            save_CFLAGS="$CFLAGS"
    1.77 +            CFLAGS="$save_CFLAGS $DBUS_CFLAGS"
    1.78 +            ac_fn_c_check_header_mongrel "$LINENO" "dbus/dbus.h" "ac_cv_header_dbus_dbus_h" "$ac_includes_default"
    1.79 +if test "x$ac_cv_header_dbus_dbus_h" = xyes; then :
    1.80 +  have_dbus_dbus_h_hdr=yes
    1.81 +else
    1.82 +  have_dbus_dbus_h_hdr=no
    1.83 +fi
    1.84 +
    1.85 +
    1.86 +            CFLAGS="$save_CFLAGS"
    1.87 +            if test x$have_dbus_dbus_h_hdr = xyes; then
    1.88 +
    1.89 +$as_echo "#define HAVE_DBUS_DBUS_H 1" >>confdefs.h
    1.90 +
    1.91 +                EXTRA_CFLAGS="$EXTRA_CFLAGS $DBUS_CFLAGS"
    1.92 +            fi
    1.93 +        fi
    1.94 +    fi
    1.95 +}
    1.96 +
    1.97  CheckTslib()
    1.98  {
    1.99      # Check whether --enable-input-tslib was given.
   1.100 @@ -21927,6 +22003,7 @@
   1.101          CheckOpenGLX11
   1.102          CheckOpenGLESX11
   1.103          CheckLibUDev
   1.104 +        CheckDBus
   1.105          CheckInputEvents
   1.106          CheckTslib
   1.107          CheckUSBHID