~ubuntu-branches/ubuntu/natty/gtkboard/natty

« back to all changes in this revision

Viewing changes to configure

  • Committer: Bazaar Package Importer
  • Author(s): Barak A. Pearlmutter
  • Date: 2011-02-24 16:32:36 UTC
  • mto: (3.1.7 sid)
  • mto: This revision was merged to the branch mainline in revision 10.
  • Revision ID: james.westby@ubuntu.com-20110224163236-trlakq1yjp0d749a
Tags: upstream-0.11pre0+cvs.2003.11.02
ImportĀ upstreamĀ versionĀ 0.11pre0+cvs.2003.11.02

Show diffs side-by-side

added added

removed removed

Lines of Context:
308
308
# include <unistd.h>
309
309
#endif"
310
310
 
311
 
ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO AMTAR install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM AWK SET_MAKE CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE PKG_CONFIG GTK_CFLAGS GTK_LIBS GTK_CONFIG SDL_CONFIG SDL_CFLAGS SDL_LIBS GNOME_CFLAGS GNOME_LIBS WITH_GNOME_TRUE WITH_GNOME_FALSE CPP EGREP LIBOBJS LTLIBOBJS'
 
311
ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO AMTAR install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM AWK SET_MAKE CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE PKG_CONFIG GTK_CFLAGS GTK_LIBS GTK_CONFIG GNOME_CFLAGS GNOME_LIBS WITH_GNOME_TRUE WITH_GNOME_FALSE CPP EGREP LIBOBJS LTLIBOBJS'
312
312
ac_subst_files=''
313
313
 
314
314
# Initialize some variables set by options.
854
854
  --disable-gtk2      Don't look for GTK2 libraries
855
855
  --disable-gtktest       Do not try to compile and run a test GTK program
856
856
  --disable-sdl      Don't look for the SDL library
857
 
  --disable-sdltest       Do not try to compile and run a test SDL program
858
857
  --enable-gnome    Turn on gnome
859
858
 
860
859
Optional Packages:
862
861
  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
863
862
  --with-gtk-prefix=PFX   Prefix where GTK is installed (optional)
864
863
  --with-gtk-exec-prefix=PFX Exec prefix where GTK is installed (optional)
865
 
  --with-sdl-prefix=PFX   Prefix where SDL is installed (optional)
866
 
  --with-sdl-exec-prefix=PFX Exec prefix where SDL is installed (optional)
867
864
 
868
865
Some influential environment variables:
869
866
  CC          C compiler command
3191
3188
fi;
3192
3189
 
3193
3190
if test "$enable_sdl" = "yes" ; then
3194
 
                SDL_VERSION=1.2.0
3195
 
 
3196
 
# Check whether --with-sdl-prefix or --without-sdl-prefix was given.
3197
 
if test "${with_sdl_prefix+set}" = set; then
3198
 
  withval="$with_sdl_prefix"
3199
 
  sdl_prefix="$withval"
3200
 
else
3201
 
  sdl_prefix=""
3202
 
fi;
3203
 
 
3204
 
# Check whether --with-sdl-exec-prefix or --without-sdl-exec-prefix was given.
3205
 
if test "${with_sdl_exec_prefix+set}" = set; then
3206
 
  withval="$with_sdl_exec_prefix"
3207
 
  sdl_exec_prefix="$withval"
3208
 
else
3209
 
  sdl_exec_prefix=""
3210
 
fi;
3211
 
# Check whether --enable-sdltest or --disable-sdltest was given.
3212
 
if test "${enable_sdltest+set}" = set; then
3213
 
  enableval="$enable_sdltest"
3214
 
 
3215
 
else
3216
 
  enable_sdltest=yes
3217
 
fi;
3218
 
 
3219
 
  if test x$sdl_exec_prefix != x ; then
3220
 
     sdl_args="$sdl_args --exec-prefix=$sdl_exec_prefix"
3221
 
     if test x${SDL_CONFIG+set} != xset ; then
3222
 
        SDL_CONFIG=$sdl_exec_prefix/bin/sdl-config
3223
 
     fi
3224
 
  fi
3225
 
  if test x$sdl_prefix != x ; then
3226
 
     sdl_args="$sdl_args --prefix=$sdl_prefix"
3227
 
     if test x${SDL_CONFIG+set} != xset ; then
3228
 
        SDL_CONFIG=$sdl_prefix/bin/sdl-config
3229
 
     fi
3230
 
  fi
3231
 
 
3232
 
 
3233
 
  PATH="$prefix/bin:$prefix/usr/bin:$PATH"
3234
 
  # Extract the first word of "sdl-config", so it can be a program name with args.
3235
 
set dummy sdl-config; ac_word=$2
3236
 
echo "$as_me:$LINENO: checking for $ac_word" >&5
3237
 
echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3238
 
if test "${ac_cv_path_SDL_CONFIG+set}" = set; then
 
3191
        #       SDL_VERSION=1.2.0
 
3192
#       AM_PATH_SDL($SDL_VERSION,
 
3193
#                       AC_DEFINE([HAVE_SDL], [], [Do we have the SDL library]),
 
3194
#                       AC_MSG_WARN([*** SDL version $SDL_VERSION not found. Sound will be disabled])
 
3195
#       )
 
3196
        echo "$as_me:$LINENO: checking for Mix_OpenAudio in -lSDL_mixer" >&5
 
3197
echo $ECHO_N "checking for Mix_OpenAudio in -lSDL_mixer... $ECHO_C" >&6
 
3198
if test "${ac_cv_lib_SDL_mixer_Mix_OpenAudio+set}" = set; then
3239
3199
  echo $ECHO_N "(cached) $ECHO_C" >&6
3240
3200
else
3241
 
  case $SDL_CONFIG in
3242
 
  [\\/]* | ?:[\\/]*)
3243
 
  ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a path.
3244
 
  ;;
3245
 
  *)
3246
 
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3247
 
for as_dir in $PATH
3248
 
do
3249
 
  IFS=$as_save_IFS
3250
 
  test -z "$as_dir" && as_dir=.
3251
 
  for ac_exec_ext in '' $ac_executable_extensions; do
3252
 
  if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3253
 
    ac_cv_path_SDL_CONFIG="$as_dir/$ac_word$ac_exec_ext"
3254
 
    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3255
 
    break 2
3256
 
  fi
3257
 
done
3258
 
done
3259
 
 
3260
 
  test -z "$ac_cv_path_SDL_CONFIG" && ac_cv_path_SDL_CONFIG="no"
3261
 
  ;;
3262
 
esac
3263
 
fi
3264
 
SDL_CONFIG=$ac_cv_path_SDL_CONFIG
3265
 
 
3266
 
if test -n "$SDL_CONFIG"; then
3267
 
  echo "$as_me:$LINENO: result: $SDL_CONFIG" >&5
3268
 
echo "${ECHO_T}$SDL_CONFIG" >&6
3269
 
else
3270
 
  echo "$as_me:$LINENO: result: no" >&5
3271
 
echo "${ECHO_T}no" >&6
3272
 
fi
3273
 
 
3274
 
  min_sdl_version=$SDL_VERSION
3275
 
  echo "$as_me:$LINENO: checking for SDL - version >= $min_sdl_version" >&5
3276
 
echo $ECHO_N "checking for SDL - version >= $min_sdl_version... $ECHO_C" >&6
3277
 
  no_sdl=""
3278
 
  if test "$SDL_CONFIG" = "no" ; then
3279
 
    no_sdl=yes
3280
 
  else
3281
 
    SDL_CFLAGS=`$SDL_CONFIG $sdlconf_args --cflags`
3282
 
    SDL_LIBS=`$SDL_CONFIG $sdlconf_args --libs`
3283
 
 
3284
 
    sdl_major_version=`$SDL_CONFIG $sdl_args --version | \
3285
 
           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'`
3286
 
    sdl_minor_version=`$SDL_CONFIG $sdl_args --version | \
3287
 
           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'`
3288
 
    sdl_micro_version=`$SDL_CONFIG $sdl_config_args --version | \
3289
 
           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'`
3290
 
    if test "x$enable_sdltest" = "xyes" ; then
3291
 
      ac_save_CFLAGS="$CFLAGS"
3292
 
      ac_save_CXXFLAGS="$CXXFLAGS"
3293
 
      ac_save_LIBS="$LIBS"
3294
 
      CFLAGS="$CFLAGS $SDL_CFLAGS"
3295
 
      CXXFLAGS="$CXXFLAGS $SDL_CFLAGS"
3296
 
      LIBS="$LIBS $SDL_LIBS"
3297
 
      rm -f conf.sdltest
3298
 
      if test "$cross_compiling" = yes; then
3299
 
  echo $ac_n "cross compiling; assumed OK... $ac_c"
3300
 
else
3301
 
  cat >conftest.$ac_ext <<_ACEOF
 
3201
  ac_check_lib_save_LIBS=$LIBS
 
3202
LIBS="-lSDL_mixer  $LIBS"
 
3203
cat >conftest.$ac_ext <<_ACEOF
3302
3204
#line $LINENO "configure"
3303
3205
/* confdefs.h.  */
3304
3206
_ACEOF
3306
3208
cat >>conftest.$ac_ext <<_ACEOF
3307
3209
/* end confdefs.h.  */
3308
3210
 
3309
 
#include <stdio.h>
3310
 
#include <stdlib.h>
3311
 
#include <string.h>
3312
 
#include "SDL.h"
3313
 
 
3314
 
char*
3315
 
my_strdup (char *str)
3316
 
{
3317
 
  char *new_str;
3318
 
 
3319
 
  if (str)
3320
 
    {
3321
 
      new_str = (char *)malloc ((strlen (str) + 1) * sizeof(char));
3322
 
      strcpy (new_str, str);
3323
 
    }
3324
 
  else
3325
 
    new_str = NULL;
3326
 
 
3327
 
  return new_str;
3328
 
}
3329
 
 
3330
 
int main (int argc, char *argv[])
3331
 
{
3332
 
  int major, minor, micro;
3333
 
  char *tmp_version;
3334
 
 
3335
 
  /* This hangs on some systems (?)
3336
 
  system ("touch conf.sdltest");
3337
 
  */
3338
 
  { FILE *fp = fopen("conf.sdltest", "a"); if ( fp ) fclose(fp); }
3339
 
 
3340
 
  /* HP/UX 9 (%@#!) writes to sscanf strings */
3341
 
  tmp_version = my_strdup("$min_sdl_version");
3342
 
  if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
3343
 
     printf("%s, bad version string\n", "$min_sdl_version");
3344
 
     exit(1);
3345
 
   }
3346
 
 
3347
 
   if (($sdl_major_version > major) ||
3348
 
      (($sdl_major_version == major) && ($sdl_minor_version > minor)) ||
3349
 
      (($sdl_major_version == major) && ($sdl_minor_version == minor) && ($sdl_micro_version >= micro)))
3350
 
    {
3351
 
      return 0;
3352
 
    }
3353
 
  else
3354
 
    {
3355
 
      printf("\n*** 'sdl-config --version' returned %d.%d.%d, but the minimum version\n", $sdl_major_version, $sdl_minor_version, $sdl_micro_version);
3356
 
      printf("*** of SDL required is %d.%d.%d. If sdl-config is correct, then it is\n", major, minor, micro);
3357
 
      printf("*** best to upgrade to the required version.\n");
3358
 
      printf("*** If sdl-config was wrong, set the environment variable SDL_CONFIG\n");
3359
 
      printf("*** to point to the correct copy of sdl-config, and remove the file\n");
3360
 
      printf("*** config.cache before re-running configure\n");
3361
 
      return 1;
3362
 
    }
3363
 
}
3364
 
 
3365
 
 
 
3211
/* Override any gcc2 internal prototype to avoid an error.  */
 
3212
#ifdef __cplusplus
 
3213
extern "C"
 
3214
#endif
 
3215
/* We use char because int might match the return type of a gcc2
 
3216
   builtin and then its argument prototype would still apply.  */
 
3217
char Mix_OpenAudio ();
 
3218
int
 
3219
main ()
 
3220
{
 
3221
Mix_OpenAudio ();
 
3222
  ;
 
3223
  return 0;
 
3224
}
3366
3225
_ACEOF
3367
 
rm -f conftest$ac_exeext
 
3226
rm -f conftest.$ac_objext conftest$ac_exeext
3368
3227
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3369
3228
  (eval $ac_link) 2>&5
3370
3229
  ac_status=$?
3371
3230
  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3372
 
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
 
3231
  (exit $ac_status); } &&
 
3232
         { ac_try='test -s conftest$ac_exeext'
3373
3233
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3374
3234
  (eval $ac_try) 2>&5
3375
3235
  ac_status=$?
3376
3236
  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3377
3237
  (exit $ac_status); }; }; then
3378
 
  :
 
3238
  ac_cv_lib_SDL_mixer_Mix_OpenAudio=yes
3379
3239
else
3380
 
  echo "$as_me: program exited with status $ac_status" >&5
3381
 
echo "$as_me: failed program was:" >&5
 
3240
  echo "$as_me: failed program was:" >&5
3382
3241
sed 's/^/| /' conftest.$ac_ext >&5
3383
3242
 
3384
 
( exit $ac_status )
3385
 
no_sdl=yes
3386
 
fi
3387
 
rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3388
 
fi
3389
 
       CFLAGS="$ac_save_CFLAGS"
3390
 
       CXXFLAGS="$ac_save_CXXFLAGS"
3391
 
       LIBS="$ac_save_LIBS"
3392
 
     fi
3393
 
  fi
3394
 
  if test "x$no_sdl" = x ; then
3395
 
     echo "$as_me:$LINENO: result: yes" >&5
3396
 
echo "${ECHO_T}yes" >&6
 
3243
ac_cv_lib_SDL_mixer_Mix_OpenAudio=no
 
3244
fi
 
3245
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
 
3246
LIBS=$ac_check_lib_save_LIBS
 
3247
fi
 
3248
echo "$as_me:$LINENO: result: $ac_cv_lib_SDL_mixer_Mix_OpenAudio" >&5
 
3249
echo "${ECHO_T}$ac_cv_lib_SDL_mixer_Mix_OpenAudio" >&6
 
3250
if test $ac_cv_lib_SDL_mixer_Mix_OpenAudio = yes; then
 
3251
  have_SDL_mixer=yes
 
3252
else
 
3253
  have_SDL_mixer=no
 
3254
fi
 
3255
 
 
3256
 
 
3257
        if test "$have_SDL_mixer" = "yes" ; then
 
3258
#               CFLAGS="$CFLAGS -DHAVE_SDL"
3397
3259
 
3398
3260
cat >>confdefs.h <<\_ACEOF
3399
3261
#define HAVE_SDL
3400
3262
_ACEOF
3401
3263
 
3402
 
  else
3403
 
     echo "$as_me:$LINENO: result: no" >&5
3404
 
echo "${ECHO_T}no" >&6
3405
 
     if test "$SDL_CONFIG" = "no" ; then
3406
 
       echo "*** The sdl-config script installed by SDL could not be found"
3407
 
       echo "*** If SDL was installed in PREFIX, make sure PREFIX/bin is in"
3408
 
       echo "*** your path, or set the SDL_CONFIG environment variable to the"
3409
 
       echo "*** full path to sdl-config."
3410
 
     else
3411
 
       if test -f conf.sdltest ; then
3412
 
        :
3413
 
       else
3414
 
          echo "*** Could not run SDL test program, checking why..."
3415
 
          CFLAGS="$CFLAGS $SDL_CFLAGS"
3416
 
          CXXFLAGS="$CXXFLAGS $SDL_CFLAGS"
3417
 
          LIBS="$LIBS $SDL_LIBS"
3418
 
          cat >conftest.$ac_ext <<_ACEOF
3419
 
#line $LINENO "configure"
3420
 
/* confdefs.h.  */
3421
 
_ACEOF
3422
 
cat confdefs.h >>conftest.$ac_ext
3423
 
cat >>conftest.$ac_ext <<_ACEOF
3424
 
/* end confdefs.h.  */
3425
 
 
3426
 
#include <stdio.h>
3427
 
#include "SDL.h"
3428
 
 
3429
 
int main(int argc, char *argv[])
3430
 
{ return 0; }
3431
 
#undef  main
3432
 
#define main K_and_R_C_main
3433
 
 
3434
 
int
3435
 
main ()
3436
 
{
3437
 
 return 0;
3438
 
  ;
3439
 
  return 0;
3440
 
}
3441
 
_ACEOF
3442
 
rm -f conftest.$ac_objext conftest$ac_exeext
3443
 
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3444
 
  (eval $ac_link) 2>&5
3445
 
  ac_status=$?
3446
 
  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3447
 
  (exit $ac_status); } &&
3448
 
         { ac_try='test -s conftest$ac_exeext'
3449
 
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3450
 
  (eval $ac_try) 2>&5
3451
 
  ac_status=$?
3452
 
  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3453
 
  (exit $ac_status); }; }; then
3454
 
   echo "*** The test program compiled, but did not run. This usually means"
3455
 
          echo "*** that the run-time linker is not finding SDL or finding the wrong"
3456
 
          echo "*** version of SDL. If it is not finding SDL, you'll need to set your"
3457
 
          echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
3458
 
          echo "*** to the installed location  Also, make sure you have run ldconfig if that"
3459
 
          echo "*** is required on your system"
3460
 
          echo "***"
3461
 
          echo "*** If you have an old version installed, it is best to remove it, although"
3462
 
          echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
3463
 
else
3464
 
  echo "$as_me: failed program was:" >&5
3465
 
sed 's/^/| /' conftest.$ac_ext >&5
3466
 
 
3467
 
 echo "*** The test program failed to compile or link. See the file config.log for the"
3468
 
          echo "*** exact error that occured. This usually means SDL was incorrectly installed"
3469
 
          echo "*** or that you have moved SDL since it was installed. In the latter case, you"
3470
 
          echo "*** may want to edit the sdl-config script: $SDL_CONFIG"
3471
 
fi
3472
 
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3473
 
          CFLAGS="$ac_save_CFLAGS"
3474
 
          CXXFLAGS="$ac_save_CXXFLAGS"
3475
 
          LIBS="$ac_save_LIBS"
3476
 
       fi
3477
 
     fi
3478
 
     SDL_CFLAGS=""
3479
 
     SDL_LIBS=""
3480
 
     { echo "$as_me:$LINENO: WARNING: *** SDL version $SDL_VERSION not found. Sound will be disabled" >&5
3481
 
echo "$as_me: WARNING: *** SDL version $SDL_VERSION not found. Sound will be disabled" >&2;}
3482
 
 
3483
 
  fi
3484
 
 
3485
 
 
3486
 
  rm -f conf.sdltest
3487
 
 
3488
 
        CFLAGS="$CFLAGS $SDL_CFLAGS"
3489
 
        LIBS="$LIBS $SDL_LIBS -lSDL_mixer"
 
3264
            LIBS="$LIBS -lSDL_mixer"
 
3265
        else
 
3266
            echo "*** SDL_mixer not found.  Configuring without audio support."
 
3267
        fi
 
3268
 
 
3269
 
 
3270
#       CFLAGS="$CFLAGS $SDL_CFLAGS"
 
3271
#       LIBS="$LIBS $SDL_LIBS -lSDL_mixer"
3490
3272
fi
3491
3273
 
3492
3274
gnome=false
5193
4975
s,@GTK_CFLAGS@,$GTK_CFLAGS,;t t
5194
4976
s,@GTK_LIBS@,$GTK_LIBS,;t t
5195
4977
s,@GTK_CONFIG@,$GTK_CONFIG,;t t
5196
 
s,@SDL_CONFIG@,$SDL_CONFIG,;t t
5197
 
s,@SDL_CFLAGS@,$SDL_CFLAGS,;t t
5198
 
s,@SDL_LIBS@,$SDL_LIBS,;t t
5199
4978
s,@GNOME_CFLAGS@,$GNOME_CFLAGS,;t t
5200
4979
s,@GNOME_LIBS@,$GNOME_LIBS,;t t
5201
4980
s,@WITH_GNOME_TRUE@,$WITH_GNOME_TRUE,;t t