configure 271 KB
Newer Older
1
#! /bin/sh
2

3
# Guess values for system-dependent variables and create Makefiles.
4 5
# Generated automatically using autoconf version 2.13 
# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6 7 8 9
#
# This configure script is free software; the Free Software Foundation
# gives unlimited permission to copy, distribute and modify it.

10 11
# Defaults:
ac_help=
12
ac_default_prefix=/usr/local
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
# Any additions from configure.in:
ac_help="$ac_help
  --with-libiconv-prefix=DIR  search for libiconv in DIR/include and DIR/lib"
ac_help="$ac_help
  --disable-nls           do not use Native Language Support"
ac_help="$ac_help
  --with-included-gettext use the GNU gettext library included here"
ac_help="$ac_help
"
ac_help="$ac_help
Optimization options:"
ac_help="$ac_help
  --with-tuning=ARCH      enable special tuning for an architecture
                          (default i686 on IA-32 and 750 on PPC)"
ac_help="$ac_help
  --disable-optimizations disable compiler optimizations (default enabled)"
ac_help="$ac_help
Sam Hocevar's avatar
Sam Hocevar committed
30
  --disable-altivec       disable AltiVec optimizations (default enabled on PPC)"
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50
ac_help="$ac_help
  --enable-debug          debug mode (default disabled)"
ac_help="$ac_help
  --enable-release        activate extra optimizations (default disabled)"
ac_help="$ac_help
Input plugins:"
ac_help="$ac_help
  --enable-dvd            DVD input module (default enabled)"
ac_help="$ac_help
    --with-dvdcss=PATH    libdvdcss headers and libraries"
ac_help="$ac_help
    --with-dvdcss-tree=PATH libdvdcss tree for static linking"
ac_help="$ac_help
  --enable-dvdread        dvdread input module (default disabled)"
ac_help="$ac_help
    --with-dvdread=PATH   libdvdread headers and libraries"
ac_help="$ac_help
  --enable-dvbpsi        dvbpsi ts demux module (default disabled)"
ac_help="$ac_help
    --with-dvbpsi=PATH    libdvbpsi headers and libraries"
51 52
ac_help="$ac_help
    --with-dvbpsi-tree=PATH libdvbpsi tree for static linking"
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68
ac_help="$ac_help
  --enable-vcd            VCD support for Linux, FreeBSD and MacOS X (default enabled)"
ac_help="$ac_help
  --enable-satellite      satellite card support (default disabled)"
ac_help="$ac_help
  --enable-avi            AVI demux module (default enabled)"
ac_help="$ac_help
Codec plugins:"
ac_help="$ac_help
  --enable-mad            libmad module (default disabled)"
ac_help="$ac_help
    --with-mad=PATH       path to libmad"
ac_help="$ac_help
    --with-mad-tree=PATH  mad tree for static linking"
ac_help="$ac_help
  --enable-ffmpeg         ffmpeg codec (default disabled)"
69 70
ac_help="$ac_help
    --with-ffmpeg=PATH    path to ffmpeg installation"
71 72
ac_help="$ac_help
    --with-ffmpeg-tree=PATH ffmpeg tree for static linking"
73
ac_help="$ac_help
74
  --enable-mp4            MP4 demux module (default disabled)"
75 76 77 78
ac_help="$ac_help
  --enable-a52            AC3 support with liba52 (default enabled)"
ac_help="$ac_help
    --with-a52-tree=PATH  a52dec tree for static linking "
79 80
ac_help="$ac_help
  --enable-cinepak        Cinepak decoder (default enabled)"
81 82 83 84 85 86 87 88 89 90 91 92 93 94 95
ac_help="$ac_help
  --enable-vorbis         Ogg/Vorbis decoder support (default enabled)"
ac_help="$ac_help
Video plugins:"
ac_help="$ac_help
  --enable-x11            X11 support (default enabled)"
ac_help="$ac_help
  --enable-xvideo         XVideo support (default enabled)"
ac_help="$ac_help
  --enable-sdl            SDL support (default enabled)"
ac_help="$ac_help
    --with-sdl-config-path=PATH sdl-config path (default search in \$PATH)"
ac_help="$ac_help
  --enable-directx        Win32 DirectX support (default enabled on Win32)"
ac_help="$ac_help
Gildas Bazin's avatar
 
Gildas Bazin committed
96
    --with-directx=PATH   Win32 DirectX headers"
97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128
ac_help="$ac_help
  --enable-fb             Linux framebuffer support (default enabled on Linux)"
ac_help="$ac_help
  --enable-mga            Linux kernel Matrox support (default disabled)"
ac_help="$ac_help
  --enable-ggi            GGI support (default disabled)"
ac_help="$ac_help
    --with-ggi=PATH       path to libggi"
ac_help="$ac_help
  --enable-glide          Glide (3dfx) support (default disabled)"
ac_help="$ac_help
    --with-glide=PATH     path to libglide"
ac_help="$ac_help
  --enable-aa             aalib output (default disabled)"
ac_help="$ac_help
Audio plugins:"
ac_help="$ac_help
  --enable-dsp            Linux /dev/dsp support (enabled on Linux)"
ac_help="$ac_help
  --enable-esd            Esound library support (default disabled)"
ac_help="$ac_help
  --enable-arts           aRts sound server (default disabled)"
ac_help="$ac_help
  --enable-alsa           ALSA sound support for Linux (default disabled)"
ac_help="$ac_help
  --enable-waveout        Win32 waveOut module (default enabled on Win32)"
ac_help="$ac_help
Interface plugins:"
ac_help="$ac_help
  --enable-gtk            Gtk+ support (default enabled)"
ac_help="$ac_help
    --with-gtk-config-path=PATH gtk-config path (default search in \$PATH)"
129 130 131 132
ac_help="$ac_help
  --enable-familiar       Familiar Gtk+ support (default disabled)"
ac_help="$ac_help
    --with-gtk-config-path=PATH gtk-config path (default search in \$PATH)"
133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149
ac_help="$ac_help
  --enable-gnome          Gnome interface support (default disabled)"
ac_help="$ac_help
  --enable-qt             Qt interface support (default disabled)"
ac_help="$ac_help
  --enable-kde            KDE interface support (default disabled)"
ac_help="$ac_help
  --enable-macosx         MacOS X support (default enabled on MacOS X)"
ac_help="$ac_help
  --enable-qnx            QNX RTOS support (default enabled on QNX RTOS)"
ac_help="$ac_help
  --enable-intfwin        Win32 interface support (default disabled)"
ac_help="$ac_help
    --with-bcbuilder=PATH Borland C++ Builder installation path"
ac_help="$ac_help
  --enable-ncurses        ncurses interface support (default disabled)"
ac_help="$ac_help
150 151 152 153 154 155 156
  --enable-xosd           xosd interface support (default disabled)"
ac_help="$ac_help
  --enable-lirc           lirc support (default disabled)"
ac_help="$ac_help
Misc options:"
ac_help="$ac_help
  --with-words=endianness set endianness (big or little)"
157 158 159 160 161 162 163 164
ac_help="$ac_help
  --enable-gprof          gprof profiling (default disabled)"
ac_help="$ac_help
  --enable-cprof          cprof profiling (default disabled)"
ac_help="$ac_help
  --enable-pth            GNU Pth support (default disabled)"
ac_help="$ac_help
  --enable-st             State Threads (default disabled)"
165 166
ac_help="$ac_help
  --enable-mozilla        build a vlc-based Mozilla plugin (default disabled)"
167 168
ac_help="$ac_help
  --disable-plugins       make all plug-ins built-in (default plug-ins enabled)"
169 170 171 172

# Initialize some variables set by options.
# The variables have the same names as the options, with
# dashes changed to underlines.
173 174
build=NONE
cache_file=./config.cache
175
exec_prefix=NONE
176
host=NONE
177
no_create=
178
nonopt=NONE
179 180 181 182 183 184 185 186
no_recursion=
prefix=NONE
program_prefix=NONE
program_suffix=NONE
program_transform_name=s,x,x,
silent=
site=
srcdir=
187
target=NONE
188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203
verbose=
x_includes=NONE
x_libraries=NONE
bindir='${exec_prefix}/bin'
sbindir='${exec_prefix}/sbin'
libexecdir='${exec_prefix}/libexec'
datadir='${prefix}/share'
sysconfdir='${prefix}/etc'
sharedstatedir='${prefix}/com'
localstatedir='${prefix}/var'
libdir='${exec_prefix}/lib'
includedir='${prefix}/include'
oldincludedir='/usr/include'
infodir='${prefix}/info'
mandir='${prefix}/man'

204 205 206 207 208 209 210
# Initialize some other variables.
subdirs=
MFLAGS= MAKEFLAGS=
SHELL=${CONFIG_SHELL-/bin/sh}
# Maximum number of lines to put in a shell here document.
ac_max_here_lines=12

211 212 213
ac_prev=
for ac_option
do
214

215 216 217 218 219 220 221
  # If the previous option needs an argument, assign it.
  if test -n "$ac_prev"; then
    eval "$ac_prev=\$ac_option"
    ac_prev=
    continue
  fi

222 223 224 225
  case "$ac_option" in
  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
  *) ac_optarg= ;;
  esac
226 227 228

  # Accept the important Cygnus configure options, so we can diagnose typos.

229
  case "$ac_option" in
230 231 232 233

  -bindir | --bindir | --bindi | --bind | --bin | --bi)
    ac_prev=bindir ;;
  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
234
    bindir="$ac_optarg" ;;
235 236

  -build | --build | --buil | --bui | --bu)
237
    ac_prev=build ;;
238
  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
239
    build="$ac_optarg" ;;
240 241 242 243 244 245

  -cache-file | --cache-file | --cache-fil | --cache-fi \
  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
    ac_prev=cache_file ;;
  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
246
    cache_file="$ac_optarg" ;;
247 248 249 250 251

  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
    ac_prev=datadir ;;
  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
  | --da=*)
252
    datadir="$ac_optarg" ;;
253 254

  -disable-* | --disable-*)
255
    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
256
    # Reject names that are not valid shell variable names.
257 258 259 260 261
    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
    fi
    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
    eval "enable_${ac_feature}=no" ;;
262 263

  -enable-* | --enable-*)
264
    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
265
    # Reject names that are not valid shell variable names.
266 267 268 269 270 271
    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
    fi
    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
    case "$ac_option" in
      *=*) ;;
272 273
      *) ac_optarg=yes ;;
    esac
274
    eval "enable_${ac_feature}='$ac_optarg'" ;;
275 276 277 278 279 280 281 282

  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  | --exec | --exe | --ex)
    ac_prev=exec_prefix ;;
  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  | --exec=* | --exe=* | --ex=*)
283
    exec_prefix="$ac_optarg" ;;
284 285 286 287 288

  -gas | --gas | --ga | --g)
    # Obsolete; use --with-gas.
    with_gas=yes ;;

289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342
  -help | --help | --hel | --he)
    # 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 << EOF
Usage: configure [options] [host]
Options: [defaults in brackets after descriptions]
Configuration:
  --cache-file=FILE       cache test results in FILE
  --help                  print this message
  --no-create             do not create output files
  --quiet, --silent       do not print \`checking...' messages
  --version               print the version of autoconf that created configure
Directory and file names:
  --prefix=PREFIX         install architecture-independent files in PREFIX
                          [$ac_default_prefix]
  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
                          [same as prefix]
  --bindir=DIR            user executables in DIR [EPREFIX/bin]
  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
  --datadir=DIR           read-only architecture-independent data in DIR
                          [PREFIX/share]
  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
                          [PREFIX/com]
  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
  --includedir=DIR        C header files in DIR [PREFIX/include]
  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
  --infodir=DIR           info documentation in DIR [PREFIX/info]
  --mandir=DIR            man documentation in DIR [PREFIX/man]
  --srcdir=DIR            find the sources in DIR [configure dir or ..]
  --program-prefix=PREFIX prepend PREFIX to installed program names
  --program-suffix=SUFFIX append SUFFIX to installed program names
  --program-transform-name=PROGRAM
                          run sed PROGRAM on installed program names
EOF
    cat << EOF
Host type:
  --build=BUILD           configure for building on BUILD [BUILD=HOST]
  --host=HOST             configure for HOST [guessed]
  --target=TARGET         configure for TARGET [TARGET=HOST]
Features and packages:
  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  --x-includes=DIR        X include files are in DIR
  --x-libraries=DIR       X library files are in DIR
EOF
    if test -n "$ac_help"; then
      echo "--enable and --with options recognized:$ac_help"
    fi
    exit 0 ;;
343 344

  -host | --host | --hos | --ho)
345
    ac_prev=host ;;
346
  -host=* | --host=* | --hos=* | --ho=*)
347
    host="$ac_optarg" ;;
348 349 350 351 352 353

  -includedir | --includedir | --includedi | --included | --include \
  | --includ | --inclu | --incl | --inc)
    ac_prev=includedir ;;
  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
  | --includ=* | --inclu=* | --incl=* | --inc=*)
354
    includedir="$ac_optarg" ;;
355 356 357 358

  -infodir | --infodir | --infodi | --infod | --info | --inf)
    ac_prev=infodir ;;
  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
359
    infodir="$ac_optarg" ;;
360 361 362 363

  -libdir | --libdir | --libdi | --libd)
    ac_prev=libdir ;;
  -libdir=* | --libdir=* | --libdi=* | --libd=*)
364
    libdir="$ac_optarg" ;;
365 366 367 368 369 370

  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
  | --libexe | --libex | --libe)
    ac_prev=libexecdir ;;
  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
  | --libexe=* | --libex=* | --libe=*)
371
    libexecdir="$ac_optarg" ;;
372 373 374 375 376 377 378 379

  -localstatedir | --localstatedir | --localstatedi | --localstated \
  | --localstate | --localstat | --localsta | --localst \
  | --locals | --local | --loca | --loc | --lo)
    ac_prev=localstatedir ;;
  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
380
    localstatedir="$ac_optarg" ;;
381 382 383 384

  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
    ac_prev=mandir ;;
  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
385
    mandir="$ac_optarg" ;;
386 387 388 389 390 391

  -nfp | --nfp | --nf)
    # Obsolete; use --without-fp.
    with_fp=no ;;

  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
392
  | --no-cr | --no-c)
393 394 395 396 397 398 399 400 401 402 403 404 405
    no_create=yes ;;

  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
    no_recursion=yes ;;

  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
  | --oldin | --oldi | --old | --ol | --o)
    ac_prev=oldincludedir ;;
  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
406
    oldincludedir="$ac_optarg" ;;
407 408 409 410

  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
    ac_prev=prefix ;;
  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
411
    prefix="$ac_optarg" ;;
412 413 414 415 416 417

  -program-prefix | --program-prefix | --program-prefi | --program-pref \
  | --program-pre | --program-pr | --program-p)
    ac_prev=program_prefix ;;
  -program-prefix=* | --program-prefix=* | --program-prefi=* \
  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
418
    program_prefix="$ac_optarg" ;;
419 420 421 422 423 424

  -program-suffix | --program-suffix | --program-suffi | --program-suff \
  | --program-suf | --program-su | --program-s)
    ac_prev=program_suffix ;;
  -program-suffix=* | --program-suffix=* | --program-suffi=* \
  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
425
    program_suffix="$ac_optarg" ;;
426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441

  -program-transform-name | --program-transform-name \
  | --program-transform-nam | --program-transform-na \
  | --program-transform-n | --program-transform- \
  | --program-transform | --program-transfor \
  | --program-transfo | --program-transf \
  | --program-trans | --program-tran \
  | --progr-tra | --program-tr | --program-t)
    ac_prev=program_transform_name ;;
  -program-transform-name=* | --program-transform-name=* \
  | --program-transform-nam=* | --program-transform-na=* \
  | --program-transform-n=* | --program-transform-=* \
  | --program-transform=* | --program-transfor=* \
  | --program-transfo=* | --program-transf=* \
  | --program-trans=* | --program-tran=* \
  | --progr-tra=* | --program-tr=* | --program-t=*)
442
    program_transform_name="$ac_optarg" ;;
443 444 445 446 447 448 449 450 451

  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  | -silent | --silent | --silen | --sile | --sil)
    silent=yes ;;

  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
    ac_prev=sbindir ;;
  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
  | --sbi=* | --sb=*)
452
    sbindir="$ac_optarg" ;;
453 454 455 456 457 458 459 460 461 462

  -sharedstatedir | --sharedstatedir | --sharedstatedi \
  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
  | --sharedst | --shareds | --shared | --share | --shar \
  | --sha | --sh)
    ac_prev=sharedstatedir ;;
  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
  | --sha=* | --sh=*)
463
    sharedstatedir="$ac_optarg" ;;
464 465 466 467

  -site | --site | --sit)
    ac_prev=site ;;
  -site=* | --site=* | --sit=*)
468
    site="$ac_optarg" ;;
469 470 471 472

  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
    ac_prev=srcdir ;;
  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
473
    srcdir="$ac_optarg" ;;
474 475 476 477 478 479

  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
  | --syscon | --sysco | --sysc | --sys | --sy)
    ac_prev=sysconfdir ;;
  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
480
    sysconfdir="$ac_optarg" ;;
481 482

  -target | --target | --targe | --targ | --tar | --ta | --t)
483
    ac_prev=target ;;
484
  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
485
    target="$ac_optarg" ;;
486 487 488 489

  -v | -verbose | --verbose | --verbos | --verbo | --verb)
    verbose=yes ;;

490 491 492
  -version | --version | --versio | --versi | --vers)
    echo "configure generated by autoconf version 2.13"
    exit 0 ;;
493 494

  -with-* | --with-*)
495
    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
496
    # Reject names that are not valid shell variable names.
497 498 499
    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
    fi
500
    ac_package=`echo $ac_package| sed 's/-/_/g'`
501 502
    case "$ac_option" in
      *=*) ;;
503 504
      *) ac_optarg=yes ;;
    esac
505
    eval "with_${ac_package}='$ac_optarg'" ;;
506 507

  -without-* | --without-*)
508
    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
509
    # Reject names that are not valid shell variable names.
510 511 512 513 514
    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
    fi
    ac_package=`echo $ac_package| sed 's/-/_/g'`
    eval "with_${ac_package}=no" ;;
515 516 517 518 519 520 521 522 523 524

  --x)
    # Obsolete; use --with-x.
    with_x=yes ;;

  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  | --x-incl | --x-inc | --x-in | --x-i)
    ac_prev=x_includes ;;
  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
525
    x_includes="$ac_optarg" ;;
526 527 528 529 530 531

  -x-libraries | --x-libraries | --x-librarie | --x-librari \
  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
    ac_prev=x_libraries ;;
  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
532
    x_libraries="$ac_optarg" ;;
533

534
  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
535 536 537
    ;;

  *)
538 539 540 541 542 543 544
    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
      echo "configure: warning: $ac_option: invalid host type" 1>&2
    fi
    if test "x$nonopt" != xNONE; then
      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
    fi
    nonopt="$ac_option"
545 546 547 548 549 550
    ;;

  esac
done

if test -n "$ac_prev"; then
551
  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
552
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
553

554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15

# File descriptor usage:
# 0 standard input
# 1 file creation
# 2 errors and warnings
# 3 some systems may open it to /dev/tty
# 4 used on the Kubota Titan
# 6 checking for... messages and results
# 5 compiler messages saved in config.log
if test "$silent" = yes; then
  exec 6>/dev/null
else
  exec 6>&1
fi
exec 5>./config.log

echo "\
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
" 1>&5
575

576 577 578 579
# Strip out --no-create and --no-recursion so they do not pile up.
# Also quote any args containing shell metacharacters.
ac_configure_args=
for ac_arg
580
do
581 582 583 584 585 586 587 588
  case "$ac_arg" in
  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  | --no-cr | --no-c) ;;
  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
  *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
589 590 591
  esac
done

592 593 594 595 596 597 598 599 600
# NLS nuisances.
# Only set these to C if already set.  These must not be set unconditionally
# because not all systems understand e.g. LANG=C (notably SCO).
# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
# Non-C LC_CTYPE values break the ctype check.
if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
601

602 603 604 605
# confdefs.h avoids OS command line length limits that DEFS can exceed.
rm -rf conftest* confdefs.h
# AIX cpp loses on an empty file, so make sure it contains at least a newline.
echo > confdefs.h
606

607 608 609
# A filename unique to this package, relative to the directory that
# configure is in, which we can look for to find out if srcdir is correct.
ac_unique_file=include/main.h
610 611 612 613 614

# Find the source files, if location was not specified.
if test -z "$srcdir"; then
  ac_srcdir_defaulted=yes
  # Try the directory containing this script, then its parent.
615 616 617
  ac_prog=$0
  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
618 619 620 621 622 623 624 625 626
  srcdir=$ac_confdir
  if test ! -r $srcdir/$ac_unique_file; then
    srcdir=..
  fi
else
  ac_srcdir_defaulted=no
fi
if test ! -r $srcdir/$ac_unique_file; then
  if test "$ac_srcdir_defaulted" = yes; then
627
    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
628
  else
629
    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
630 631
  fi
fi
632
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
633 634 635 636 637 638 639 640 641 642 643

# Prefer explicitly selected file to automatically selected ones.
if test -z "$CONFIG_SITE"; then
  if test "x$prefix" != xNONE; then
    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
  else
    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
  fi
fi
for ac_site_file in $CONFIG_SITE; do
  if test -r "$ac_site_file"; then
644
    echo "loading site script $ac_site_file"
645 646 647 648 649
    . "$ac_site_file"
  fi
done

if test -r "$cache_file"; then
650 651
  echo "loading cache $cache_file"
  . $cache_file
652
else
653 654
  echo "creating cache $cache_file"
  > $cache_file
655 656 657
fi

ac_ext=c
658
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
659
ac_cpp='$CPP $CPPFLAGS'
660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
cross_compiling=$ac_cv_prog_cc_cross

ac_exeext=
ac_objext=o
if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
    ac_n= ac_c='
' ac_t='	'
  else
    ac_n=-n ac_c= ac_t=
  fi
else
  ac_n= ac_c='\c' ac_t=
fi
677 678 679



680 681 682 683 684 685 686 687 688 689 690 691 692
ac_aux_dir=
for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
  if test -f $ac_dir/install-sh; then
    ac_aux_dir=$ac_dir
    ac_install_sh="$ac_aux_dir/install-sh -c"
    break
  elif test -f $ac_dir/install.sh; then
    ac_aux_dir=$ac_dir
    ac_install_sh="$ac_aux_dir/install.sh -c"
    break
  fi
done
if test -z "$ac_aux_dir"; then
693
  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
694
fi
695 696 697
ac_config_guess=$ac_aux_dir/config.guess
ac_config_sub=$ac_aux_dir/config.sub
ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
Sam Hocevar's avatar
 
Sam Hocevar committed
698

699

700 701 702 703 704 705 706 707 708 709 710 711
# Do some error checking and defaulting for the host and target type.
# The inputs are:
#    configure --host=HOST --target=TARGET --build=BUILD NONOPT
#
# The rules are:
# 1. You are not allowed to specify --host, --target, and nonopt at the
#    same time.
# 2. Host defaults to nonopt.
# 3. If nonopt is not specified, then host defaults to the current host,
#    as determined by config.guess.
# 4. Target and build default to nonopt.
# 5. If nonopt is not specified, then target and build default to host.
712 713 714

# The aliases save the names the user supplied, while $host etc.
# will get canonicalized.
715 716 717 718 719 720 721 722 723 724 725 726
case $host---$target---$nonopt in
NONE---*---* | *---NONE---* | *---*---NONE) ;;
*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
esac


# Make sure we can run config.sub.
if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi

echo $ac_n "checking host system type""... $ac_c" 1>&6
727
echo "configure:728: checking host system type" >&5
728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747

host_alias=$host
case "$host_alias" in
NONE)
  case $nonopt in
  NONE)
    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
    fi ;;
  *) host_alias=$nonopt ;;
  esac ;;
esac

host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6

echo $ac_n "checking target system type""... $ac_c" 1>&6
748
echo "configure:749: checking target system type" >&5
749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765

target_alias=$target
case "$target_alias" in
NONE)
  case $nonopt in
  NONE) target_alias=$host_alias ;;
  *) target_alias=$nonopt ;;
  esac ;;
esac

target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6

echo $ac_n "checking build system type""... $ac_c" 1>&6
766
echo "configure:767: checking build system type" >&5
767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783

build_alias=$build
case "$build_alias" in
NONE)
  case $nonopt in
  NONE) build_alias=$host_alias ;;
  *) build_alias=$nonopt ;;
  esac ;;
esac

build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$build" 1>&6

test "$host_alias" != "$target_alias" &&
784 785 786 787
  test "$program_prefix$program_suffix$program_transform_name" = \
    NONENONEs,x,x, &&
  program_prefix=${target_alias}-

788

Sam Hocevar's avatar
Sam Hocevar committed
789 790
CONFIGURE_LINE="$0 $*"

Sam Hocevar's avatar
 
Sam Hocevar committed
791
PACKAGE="vlc"
Sam Hocevar's avatar
Sam Hocevar committed
792 793
VERSION="0.5.0-cvs"
CODENAME="Natalya"
Sam Hocevar's avatar
 
Sam Hocevar committed
794

795
save_CPPFLAGS="${CPPFLAGS}"
Sam Hocevar's avatar
Sam Hocevar committed
796
save_CFLAGS="${CFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
797
save_LDFLAGS="${LDFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
798

799
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
800
echo "configure:801: checking whether ${MAKE-make} sets \${MAKE}" >&5
801 802 803
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
804
else
805
  cat > conftestmake <<\EOF
806 807
all:
	@echo 'ac_maketemp="${MAKE}"'
808
EOF
809
# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
810
eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
811 812 813 814 815
if test -n "$ac_maketemp"; then
  eval ac_cv_prog_make_${ac_make}_set=yes
else
  eval ac_cv_prog_make_${ac_make}_set=no
fi
816
rm -f conftestmake
817 818
fi
if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
819
  echo "$ac_t""yes" 1>&6
820 821
  SET_MAKE=
else
822
  echo "$ac_t""no" 1>&6
823 824 825
  SET_MAKE="MAKE=${MAKE-make}"
fi

826 827 828
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
829
echo "configure:830: checking for $ac_word" >&5
830 831
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
832 833 834 835
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
836 837 838 839 840 841 842 843 844 845
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_CC="gcc"
      break
    fi
  done
  IFS="$ac_save_ifs"
846 847
fi
fi
848
CC="$ac_cv_prog_CC"
849
if test -n "$CC"; then
850
  echo "$ac_t""$CC" 1>&6
851
else
852
  echo "$ac_t""no" 1>&6
853 854 855 856 857
fi

if test -z "$CC"; then
  # Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
858
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
859
echo "configure:860: checking for $ac_word" >&5
860 861
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
862 863 864 865
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
866
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
867
  ac_prog_rejected=no
868 869 870 871 872 873 874 875 876 877 878 879 880
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
        ac_prog_rejected=yes
	continue
      fi
      ac_cv_prog_CC="cc"
      break
    fi
  done
  IFS="$ac_save_ifs"
881 882 883 884
if test $ac_prog_rejected = yes; then
  # We found a bogon in the path, so make sure we never use it.
  set dummy $ac_cv_prog_CC
  shift
885
  if test $# -gt 0; then
886 887 888 889
    # We chose a different compiler from the bogus one.
    # However, it has the same basename, so the bogon will be chosen
    # first if we set CC to just the basename; use the full file name.
    shift
890
    set dummy "$ac_dir/$ac_word" "$@"
891 892 893 894 895 896
    shift
    ac_cv_prog_CC="$@"
  fi
fi
fi
fi
897
CC="$ac_cv_prog_CC"
898
if test -n "$CC"; then
899
  echo "$ac_t""$CC" 1>&6
900
else
901
  echo "$ac_t""no" 1>&6
902 903
fi

904 905 906 907 908 909
  if test -z "$CC"; then
    case "`uname -s`" in
    *win32* | *WIN32*)
      # Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
910
echo "configure:911: checking for $ac_word" >&5
911 912
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
913 914 915 916
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
917 918 919 920 921 922 923 924 925 926
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_CC="cl"
      break
    fi
  done
  IFS="$ac_save_ifs"
927 928
fi
fi
929
CC="$ac_cv_prog_CC"
930
if test -n "$CC"; then
931
  echo "$ac_t""$CC" 1>&6
932
else
933
  echo "$ac_t""no" 1>&6
934
fi
935 936
 ;;
    esac
Sam Hocevar's avatar
 
Sam Hocevar committed
937
  fi
938
  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
939
fi
940

941
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
942
echo "configure:943: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
943

944 945 946 947 948 949
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
ac_cpp='$CPP $CPPFLAGS'
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
cross_compiling=$ac_cv_prog_cc_cross
950

951
cat > conftest.$ac_ext << EOF
952

953
#line 954 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
954 955
#include "confdefs.h"

956 957
main(){return(0);}
EOF
958
if { (eval echo configure:959: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
959 960 961 962
  ac_cv_prog_cc_works=yes
  # If we can't run a trivial program, we are probably using a cross compiler.
  if (./conftest; exit) 2>/dev/null; then
    ac_cv_prog_cc_cross=no
Sam Hocevar's avatar
 
Sam Hocevar committed
963
  else
964
    ac_cv_prog_cc_cross=yes
Sam Hocevar's avatar
 
Sam Hocevar committed
965
  fi
Sam Hocevar's avatar
 
Sam Hocevar committed
966
else
967 968 969
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  ac_cv_prog_cc_works=no
970
fi
971 972 973 974 975 976 977
rm -fr conftest*
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
ac_cpp='$CPP $CPPFLAGS'
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
cross_compiling=$ac_cv_prog_cc_cross
Sam Hocevar's avatar
 
Sam Hocevar committed
978

979 980 981 982 983
echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
if test $ac_cv_prog_cc_works = no; then
  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
984
echo "configure:985: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
985 986
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
Sam Hocevar's avatar
 
Sam Hocevar committed
987

988
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
989
echo "configure:990: checking whether we are using GNU C" >&5
990 991
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
992
else
993 994 995
  cat > conftest.c <<EOF
#ifdef __GNUC__
  yes;
Sam Hocevar's avatar
 
Sam Hocevar committed
996
#endif
997
EOF
998
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:999: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
999
  ac_cv_prog_gcc=yes
Sam Hocevar's avatar
 
Sam Hocevar committed
1000
else
1001
  ac_cv_prog_gcc=no
Sam Hocevar's avatar
 
Sam Hocevar committed
1002
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
1003 1004
fi

1005
echo "$ac_t""$ac_cv_prog_gcc" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1006

1007 1008 1009 1010 1011
if test $ac_cv_prog_gcc = yes; then
  GCC=yes
else
  GCC=
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
1012

1013 1014 1015 1016
ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1017
echo "configure:1018: checking whether ${CC-cc} accepts -g" >&5
1018 1019 1020 1021 1022
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  echo 'void f(){}' > conftest.c
if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
1023 1024
  ac_cv_prog_cc_g=yes
else
1025
  ac_cv_prog_cc_g=no
Sam Hocevar's avatar
 
Sam Hocevar committed
1026
fi
1027 1028
rm -f conftest*

Sam Hocevar's avatar
 
Sam Hocevar committed
1029
fi
1030 1031

echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1032
if test "$ac_test_CFLAGS" = set; then
1033
  CFLAGS="$ac_save_CFLAGS"
1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046
elif test $ac_cv_prog_cc_g = yes; then
  if test "$GCC" = yes; then
    CFLAGS="-g -O2"
  else
    CFLAGS="-g"
  fi
else
  if test "$GCC" = yes; then
    CFLAGS="-O2"
  else
    CFLAGS=
  fi
fi
1047

1048
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1049
echo "configure:1050: checking how to run the C preprocessor" >&5
1050 1051 1052 1053 1054
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
  CPP=
fi
if test -z "$CPP"; then
1055 1056 1057 1058 1059 1060
if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
    # This must be in double quotes, not single quotes, because CPP may get
  # substituted into the Makefile and "${CC-cc}" will confuse make.
  CPP="${CC-cc} -E"
1061
  # On the NeXT, cc -E runs the code through the compiler's parser,
1062 1063
  # not just through cpp.
  cat > conftest.$ac_ext <<EOF
1064
#line 1065 "configure"
1065 1066
#include "confdefs.h"
#include <assert.h>
1067 1068 1069
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1070
{ (eval echo configure:1071: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1071 1072
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
1073 1074
  :
else
1075 1076
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
1077
  cat conftest.$ac_ext >&5
1078 1079 1080
  rm -rf conftest*
  CPP="${CC-cc} -E -traditional-cpp"
  cat > conftest.$ac_ext <<EOF
1081
#line 1082 "configure"
1082 1083 1084 1085 1086
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1087
{ (eval echo configure:1088: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1088 1089 1090
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  :
1091
else
1092 1093
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
1094
  cat conftest.$ac_ext >&5
1095 1096 1097
  rm -rf conftest*
  CPP="${CC-cc} -nologo -E"
  cat > conftest.$ac_ext <<EOF
1098
#line 1099 "configure"
1099 1100
#include "confdefs.h"
#include <assert.h>
1101 1102 1103
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1104
{ (eval echo configure:1105: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1105 1106
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
1107 1108
  :
else
1109 1110
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
1111
  cat conftest.$ac_ext >&5
1112 1113
  rm -rf conftest*
  CPP=/lib/cpp
Sam Hocevar's avatar
 
Sam Hocevar committed
1114
fi
1115
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1116
fi
1117 1118 1119 1120 1121 1122
rm -f conftest*
fi
rm -f conftest*
  ac_cv_prog_CPP="$CPP"
fi
  CPP="$ac_cv_prog_CPP"
Gildas Bazin's avatar
 
Gildas Bazin committed
1123
else
1124
  ac_cv_prog_CPP="$CPP"
Gildas Bazin's avatar
 
Gildas Bazin committed
1125
fi
1126
echo "$ac_t""$CPP" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
1127

1128

1129 1130 1131 1132 1133
if test $host != $build; then
  ac_tool_prefix=${host_alias}-
else
  ac_tool_prefix=
fi
1134

1135
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
Gildas Bazin's avatar
 
Gildas Bazin committed
1136
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
1137
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1138
echo "configure:1139: checking for $ac_word" >&5
1139 1140
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
1141 1142 1143 1144
else
  if test -n "$RANLIB"; then
  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
else
1145 1146 1147 1148 1149 1150 1151 1152 1153 1154
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
      break
    fi
  done
  IFS="$ac_save_ifs"
Gildas Bazin's avatar
 
Gildas Bazin committed
1155 1156
fi
fi
1157
RANLIB="$ac_cv_prog_RANLIB"
Gildas Bazin's avatar
 
Gildas Bazin committed
1158
if test -n "$RANLIB"; then
1159
  echo "$ac_t""$RANLIB" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
1160
else
1161
  echo "$ac_t""no" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
1162 1163
fi

1164

Gildas Bazin's avatar
 
Gildas Bazin committed
1165
if test -z "$ac_cv_prog_RANLIB"; then
1166
if test -n "$ac_tool_prefix"; then
Gildas Bazin's avatar
 
Gildas Bazin committed
1167 1168
  # Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
1169
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1170
echo "configure:1171: checking for $ac_word" >&5
1171 1172
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
1173
else
1174 1175
  if test -n "$RANLIB"; then
  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
Gildas Bazin's avatar
 
Gildas Bazin committed
1176
else
1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_RANLIB="ranlib"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
Gildas Bazin's avatar
 
Gildas Bazin committed
1188 1189
fi
fi
1190 1191 1192
RANLIB="$ac_cv_prog_RANLIB"
if test -n "$RANLIB"; then
  echo "$ac_t""$RANLIB" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
1193
else
1194
  echo "$ac_t""no" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
1195 1196 1197
fi

else
1198 1199
  RANLIB=":"
fi
Gildas Bazin's avatar
 
Gildas Bazin committed
1200 1201
fi

1202
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
Sam Hocevar's avatar
 
Sam Hocevar committed
1203
set dummy ${ac_tool_prefix}strip; ac_word=$2
1204
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1205
echo "configure:1206: checking for $ac_word" >&5
1206 1207
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1208 1209 1210 1211
else
  if test -n "$STRIP"; then
  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
else
1212 1213 1214 1215 1216 1217 1218 1219 1220 1221
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_STRIP="${ac_tool_prefix}strip"
      break
    fi
  done
  IFS="$ac_save_ifs"
Sam Hocevar's avatar
 
Sam Hocevar committed
1222 1223
fi
fi
1224
STRIP="$ac_cv_prog_STRIP"
Sam Hocevar's avatar
 
Sam Hocevar committed
1225
if test -n "$STRIP"; then
1226
  echo "$ac_t""$STRIP" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1227
else
1228
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1229 1230
fi

1231

Sam Hocevar's avatar
 
Sam Hocevar committed
1232
if test -z "$ac_cv_prog_STRIP"; then
1233
if test -n "$ac_tool_prefix"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
1234 1235
  # Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
1236
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1237
echo "configure:1238: checking for $ac_word" >&5
1238 1239
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1240
else
1241 1242
  if test -n "$STRIP"; then
  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
Sam Hocevar's avatar
 
Sam Hocevar committed
1243
else
1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_STRIP="strip"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_prog_STRIP" && ac_cv_prog_STRIP=":"
Sam Hocevar's avatar
 
Sam Hocevar committed
1255 1256
fi
fi
1257 1258 1259
STRIP="$ac_cv_prog_STRIP"
if test -n "$STRIP"; then
  echo "$ac_t""$STRIP" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1260
else
1261
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1262 1263 1264
fi

else
1265 1266
  STRIP=":"
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
1267 1268
fi

Gildas Bazin's avatar
 
Gildas Bazin committed
1269

Christophe Massiot's avatar
Christophe Massiot committed
1270 1271
# Extract the first word of "gmake", so it can be a program name with args.
set dummy gmake; ac_word=$2
1272
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1273
echo "configure:1274: checking for $ac_word" >&5
1274 1275
if eval "test \"`echo '$''{'ac_cv_path_GMAKE'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
1276
else
1277 1278
  case "$GMAKE" in
  /*)
1279 1280
  ac_cv_path_GMAKE="$GMAKE" # Let the user override the test with a path.
  ;;
1281 1282 1283
  ?:/*)			 
  ac_cv_path_GMAKE="$GMAKE" # Let the user override the test with a dos path.
  ;;
1284
  *)
1285 1286 1287 1288 1289 1290 1291 1292 1293 1294
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_GMAKE="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
Christophe Massiot's avatar
Christophe Massiot committed
1295 1296 1297 1298
  test -z "$ac_cv_path_GMAKE" && ac_cv_path_GMAKE="no"
  ;;
esac
fi
1299
GMAKE="$ac_cv_path_GMAKE"
Christophe Massiot's avatar
Christophe Massiot committed
1300
if test -n "$GMAKE"; then
1301
  echo "$ac_t""$GMAKE" 1>&6
Christophe Massiot's avatar
Christophe Massiot committed
1302
else
1303
  echo "$ac_t""no" 1>&6
Christophe Massiot's avatar
Christophe Massiot committed
1304 1305
fi

1306
if test "x${GMAKE}" = "xno"; then
1307
  echo $ac_n "checking whether GNU make is installed""... $ac_c" 1>&6
1308
echo "configure:1309: checking whether GNU make is installed" >&5
1309 1310
if eval "test \"`echo '$''{'ac_cv_gmake'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Christophe Massiot's avatar
Christophe Massiot committed
1311 1312 1313 1314 1315 1316 1317 1318 1319
else
  if make --version | grep -q -i gnu; then
         ac_cv_gmake="yes"
       else
         echo "This software needs you to install GNU make to compile properly."
         echo "You can get it from http://www.gnu.org/."
         exit
       fi
fi
1320 1321

echo "$ac_t""$ac_cv_gmake" 1>&6
Christophe Massiot's avatar
Christophe Massiot committed
1322 1323 1324 1325 1326
  VLC_MAKE="make"
else
  VLC_MAKE="gmake"
fi

1327
ALL_LINGUAS="de en_GB fr ja no ru nl pl"
Sam Hocevar's avatar
Sam Hocevar committed
1328

1329
cat >> confdefs.h <<EOF
1330
#define VLC_PACKAGE "${PACKAGE}"
1331
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1332

1333
cat >> confdefs.h <<EOF
1334
#define VLC_VERSION "${VERSION}"
1335
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1336

1337 1338 1339
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1340
echo "configure:1341: checking for $ac_word" >&5
1341 1342
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1343 1344 1345 1346
else
  if test -n "$RANLIB"; then
  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
else
1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_RANLIB="ranlib"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
Sam Hocevar's avatar
 
Sam Hocevar committed
1358 1359
fi
fi
1360
RANLIB="$ac_cv_prog_RANLIB"
Sam Hocevar's avatar
 
Sam Hocevar committed
1361
if test -n "$RANLIB"; then
1362
  echo "$ac_t""$RANLIB" 1>&6
1363
else
1364
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1365
fi
1366 1367


1368
        echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6
1369
echo "configure:1370: checking for strerror in -lcposix" >&5
1370 1371 1372
ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1373
else
1374
  ac_save_LIBS="$LIBS"
1375
LIBS="-lcposix  $LIBS"
1376
cat > conftest.$ac_ext <<EOF
1377
#line 1378 "configure"
1378 1379 1380
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
1381 1382
    builtin and then its argument prototype would still apply.  */
char strerror();
Sam Hocevar's avatar
 
Sam Hocevar committed
1383

1384 1385 1386 1387
int main() {
strerror()
; return 0; }
EOF
1388
if { (eval echo configure:1389: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1389 1390 1391 1392 1393 1394 1395 1396 1397 1398
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
1399

1400 1401 1402 1403 1404 1405 1406
fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  LIBS="$LIBS -lcposix"
else
  echo "$ac_t""no" 1>&6
fi
1407

1408
  
1409

1410
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1411
echo "configure:1412: checking for ANSI C header files" >&5
1412 1413
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1414
else
1415
  cat > conftest.$ac_ext <<EOF
1416
#line 1417 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1417 1418 1419 1420 1421
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
#include <string.h>
#include <float.h>
1422 1423
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1424
{ (eval echo configure:1425: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1425 1426 1427
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1428 1429
  ac_cv_header_stdc=yes
else
1430 1431
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
1432
  cat conftest.$ac_ext >&5
1433
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1434 1435
  ac_cv_header_stdc=no
fi
1436
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1437 1438 1439

if test $ac_cv_header_stdc = yes; then
  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1440
cat > conftest.$ac_ext <<EOF
1441
#line 1442 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1442 1443
#include "confdefs.h"
#include <string.h>
1444
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1445 1446 1447 1448
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "memchr" >/dev/null 2>&1; then
  :
else
1449
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1450 1451 1452 1453 1454 1455 1456 1457
  ac_cv_header_stdc=no
fi
rm -f conftest*

fi

if test $ac_cv_header_stdc = yes; then
  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1458
cat > conftest.$ac_ext <<EOF
1459
#line 1460 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1460 1461
#include "confdefs.h"
#include <stdlib.h>
1462
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1463 1464 1465 1466
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "free" >/dev/null 2>&1; then
  :
else
1467
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1468 1469 1470 1471 1472 1473 1474 1475
  ac_cv_header_stdc=no
fi
rm -f conftest*

fi

if test $ac_cv_header_stdc = yes; then
  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1476
if test "$cross_compiling" = yes; then
Sam Hocevar's avatar
 
Sam Hocevar committed
1477 1478
  :
else
1479
  cat > conftest.$ac_ext <<EOF
1480
#line 1481 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1481 1482
#include "confdefs.h"
#include <ctype.h>
1483 1484
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1485
#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1486 1487 1488 1489 1490
int main () { int i; for (i = 0; i < 256; i++)
if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }

EOF
1491
if { (eval echo configure:1492: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1492
then
Sam Hocevar's avatar
 
Sam Hocevar committed
1493 1494
  :
else
1495 1496 1497 1498
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -fr conftest*
  ac_cv_header_stdc=no
Sam Hocevar's avatar
 
Sam Hocevar committed
1499
fi
1500
rm -fr conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1501
fi
1502

Sam Hocevar's avatar
 
Sam Hocevar committed
1503 1504
fi
fi
1505

1506 1507 1508
echo "$ac_t""$ac_cv_header_stdc" 1>&6
if test $ac_cv_header_stdc = yes; then
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1509
#define STDC_HEADERS 1
1510
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1511 1512 1513

fi

1514
echo $ac_n "checking for working const""... $ac_c" 1>&6
1515
echo "configure:1516: checking for working const" >&5
1516 1517 1518 1519
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  cat > conftest.$ac_ext <<EOF
1520
#line 1521 "configure"
1521 1522 1523 1524 1525
#include "confdefs.h"

int main() {

/* Ultrix mips cc rejects this.  */
1526
typedef int charset[2]; const charset x;
1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546
/* SunOS 4.1.1 cc rejects this.  */
char const *const *ccp;
char **p;
/* NEC SVR4.0.2 mips cc rejects this.  */
struct point {int x, y;};
static struct point const zero = {0,0};
/* AIX XL C 1.02.0.0 rejects this.
   It does not let you subtract one const X* pointer from another in an arm
   of an if-expression whose if-part is not a constant expression */
const char *g = "string";
ccp = &g + (g ? g-g : 0);
/* HPUX 7.0 cc rejects these. */
++ccp;
p = (char**) ccp;
ccp = (char const *const *) p;
{ /* SCO 3.2v4 cc rejects this.  */
  char *t;
  char const *s = 0 ? (char *) 0 : (char const *) 0;

  *t++ = 0;
Sam Hocevar's avatar
 
Sam Hocevar committed
1547
}
1548 1549 1550 1551
{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
  int x[] = {25, 17};
  const int *foo = &x[0];
  ++foo;
Sam Hocevar's avatar
 
Sam Hocevar committed
1552
}
1553 1554 1555 1556
{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
  typedef const int *iptr;
  iptr p = 0;
  ++p;
Sam Hocevar's avatar
 
Sam Hocevar committed
1557
}
1558 1559 1560 1561 1562 1563 1564
{ /* AIX XL C 1.02.0.0 rejects this saying
     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
  struct s { int j; const int *ap[3]; };
  struct s *b; b->j = 5;
}
{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
  const int foo = 10;
1565
}
1566 1567 1568

; return 0; }
EOF
1569
if { (eval echo configure:1570: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1570
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1571 1572
  ac_cv_c_const=yes
else
1573 1574 1575 1576
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_const=no
Sam Hocevar's avatar
 
Sam Hocevar committed
1577
fi
1578
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1579
fi
1580

1581 1582 1583 1584 1585
echo "$ac_t""$ac_cv_c_const" 1>&6
if test $ac_cv_c_const = no; then
  cat >> confdefs.h <<\EOF
#define const 
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1586 1587 1588

fi

1589
echo $ac_n "checking for inline""... $ac_c" 1>&6
1590
echo "configure:1591: checking for inline" >&5
1591 1592
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1593 1594 1595
else
  ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
1596
  cat > conftest.$ac_ext <<EOF
1597
#line 1598 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1598 1599
#include "confdefs.h"

1600
int main() {
1601
} $ac_kw foo() {
1602 1603
; return 0; }
EOF
1604
if { (eval echo configure:1605: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1605
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1606 1607
  ac_cv_c_inline=$ac_kw; break
else
1608 1609
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
1610
fi
1611
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1612 1613 1614
done

fi
1615 1616 1617

echo "$ac_t""$ac_cv_c_inline" 1>&6
case "$ac_cv_c_inline" in
Sam Hocevar's avatar
 
Sam Hocevar committed
1618
  inline | yes) ;;
1619 1620 1621
  no) cat >> confdefs.h <<\EOF
#define inline 
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1622
 ;;
1623
  *)  cat >> confdefs.h <<EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1624
#define inline $ac_cv_c_inline
1625
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1626 1627 1628
 ;;
esac

1629
echo $ac_n "checking for off_t""... $ac_c" 1>&6
1630
echo "configure:1631: checking for off_t" >&5
1631 1632
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1633
else
1634
  cat > conftest.$ac_ext <<EOF
1635
#line 1636 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1636
#include "confdefs.h"
1637 1638 1639 1640
#include <sys/types.h>
#if STDC_HEADERS
#include <stdlib.h>
#include <stddef.h>
Sam Hocevar's avatar
 
Sam Hocevar committed
1641
#endif
1642 1643 1644 1645
EOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1646 1647
  ac_cv_type_off_t=yes
else
1648 1649
  rm -rf conftest*
  ac_cv_type_off_t=no
Sam Hocevar's avatar
 
Sam Hocevar committed
1650
fi
1651
rm -f conftest*
1652

1653 1654 1655 1656
fi
echo "$ac_t""$ac_cv_type_off_t" 1>&6
if test $ac_cv_type_off_t = no; then
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1657
#define off_t long
1658
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1659 1660 1661

fi

1662
echo $ac_n "checking for size_t""... $ac_c" 1>&6
1663
echo "configure:1664: checking for size_t" >&5
1664 1665
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1666
else
1667
  cat > conftest.$ac_ext <<EOF
1668
#line 1669 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1669
#include "confdefs.h"
1670 1671 1672 1673
#include <sys/types.h>
#if STDC_HEADERS
#include <stdlib.h>
#include <stddef.h>
Sam Hocevar's avatar
 
Sam Hocevar committed
1674
#endif
1675 1676 1677 1678
EOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1679 1680
  ac_cv_type_size_t=yes
else
1681 1682
  rm -rf conftest*
  ac_cv_type_size_t=no
Sam Hocevar's avatar
 
Sam Hocevar committed
1683
fi
1684
rm -f conftest*
1685

1686 1687 1688 1689
fi
echo "$ac_t""$ac_cv_type_size_t" 1>&6
if test $ac_cv_type_size_t = no; then
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1690
#define size_t unsigned
1691
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1692 1693 1694 1695 1696

fi

# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments.  Useless!
1697
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
1698
echo "configure:1699: checking for working alloca.h" >&5
1699 1700
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1701
else
1702
  cat > conftest.$ac_ext <<EOF
1703
#line 1704 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1704 1705
#include "confdefs.h"
#include <alloca.h>
1706
int main() {
1707
char *p = alloca(2 * sizeof(int));
1708 1709
; return 0; }
EOF
1710
if { (eval echo configure:1711: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724
  rm -rf conftest*
  ac_cv_header_alloca_h=yes
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_header_alloca_h=no
fi
rm -f conftest*
fi

echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
if test $ac_cv_header_alloca_h = yes; then
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1725
#define HAVE_ALLOCA_H 1
1726
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1727 1728 1729

fi

1730
echo $ac_n "checking for alloca""... $ac_c" 1>&6
1731
echo "configure:1732: checking for alloca" >&5
1732 1733
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1734
else
1735
  cat > conftest.$ac_ext <<EOF
1736
#line 1737 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1737
#include "confdefs.h"
1738

Sam Hocevar's avatar
 
Sam Hocevar committed
1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759
#ifdef __GNUC__
# define alloca __builtin_alloca
#else
# ifdef _MSC_VER
#  include <malloc.h>
#  define alloca _alloca
# else
#  if HAVE_ALLOCA_H
#   include <alloca.h>
#  else
#   ifdef _AIX
 #pragma alloca
#   else
#    ifndef alloca /* predefined by HP cc +Olibcalls */
char *alloca ();
#    endif
#   endif
#  endif
# endif
#endif

1760 1761 1762 1763
int main() {
char *p = (char *) alloca(1);
; return 0; }
EOF
1764
if { (eval echo configure:1765: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1765
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1766 1767
  ac_cv_func_alloca_works=yes
else
1768 1769 1770 1771
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_func_alloca_works=no
Sam Hocevar's avatar
 
Sam Hocevar committed
1772
fi
1773
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1774 1775
fi

1776
echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1777
if test $ac_cv_func_alloca_works = yes; then
1778
  cat >> confdefs.h <<\EOF
1779
#define HAVE_ALLOCA 1
1780
EOF
1781

1782
fi
1783

1784 1785 1786 1787 1788 1789 1790
if test $ac_cv_func_alloca_works = no; then
  # The SVR3 libPW and SVR4 libucb both contain incompatible functions
  # that cause trouble.  Some versions do not even contain alloca or
  # contain a buggy version.  If you still want to use their alloca,
  # use ar to extract alloca.o from them instead of compiling alloca.c.
  ALLOCA=alloca.${ac_objext}
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1791
#define C_ALLOCA 1
1792
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1793 1794


1795
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
1796
echo "configure:1797: checking whether alloca needs Cray hooks" >&5
1797 1798
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1799
else
1800
  cat > conftest.$ac_ext <<EOF
1801
#line 1802 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1802 1803 1804 1805 1806 1807 1808
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
#else
wenotbecray
#endif

1809
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1810 1811
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "webecray" >/dev/null 2>&1; then
1812
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1813 1814
  ac_cv_os_cray=yes
else
1815
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1816 1817 1818 1819 1820
  ac_cv_os_cray=no
fi
rm -f conftest*

fi
1821 1822

echo "$ac_t""$ac_cv_os_cray" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1823
if test $ac_cv_os_cray = yes; then
1824 1825
for ac_func in _getb67 GETB67 getb67; do
  echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1826
echo "configure:1827: checking for $ac_func" >&5
1827 1828
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1829
else
1830
  cat > conftest.$ac_ext <<EOF
1831
#line 1832 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1832 1833
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
1834
    which can conflict with char $ac_func(); below.  */
Sam Hocevar's avatar
 
Sam Hocevar committed
1835 1836 1837
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
1838 1839 1840 1841
    builtin and then its argument prototype would still apply.  */
char $ac_func();

int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
1842 1843 1844 1845 1846 1847 1848

/* 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
#else
1849
$ac_func();
Sam Hocevar's avatar
 
Sam Hocevar committed
1850 1851
#endif

1852 1853
; return 0; }
EOF
1854
if { (eval echo configure:1855: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=no"
fi
rm -f conftest*
fi

if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  cat >> confdefs.h <<EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1869
#define CRAY_STACKSEG_END $ac_func
1870
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1871

1872 1873 1874
  break
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1875 1876
fi

1877
done
Sam Hocevar's avatar
 
Sam Hocevar committed
1878 1879
fi

1880
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
1881
echo "configure:1882: checking stack direction for C alloca" >&5
1882 1883
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1884 1885 1886 1887
else
  if test "$cross_compiling" = yes; then
  ac_cv_c_stack_direction=0
else
1888
  cat > conftest.$ac_ext <<EOF
1889
#line 1890 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904
#include "confdefs.h"
find_stack_direction ()
{
  static char *addr = 0;
  auto char dummy;
  if (addr == 0)
    {
      addr = &dummy;
      return find_stack_direction ();
    }
  else
    return (&dummy > addr) ? 1 : -1;
}
main ()
{
1905
  exit (find_stack_direction() < 0);
Sam Hocevar's avatar
 
Sam Hocevar committed
1906
}
1907
EOF
1908
if { (eval echo configure:1909: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1909
then
Sam Hocevar's avatar
 
Sam Hocevar committed
1910 1911
  ac_cv_c_stack_direction=1
else
1912 1913 1914 1915
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -fr conftest*
  ac_cv_c_stack_direction=-1
Sam Hocevar's avatar
 
Sam Hocevar committed
1916
fi
1917
rm -fr conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1918
fi
1919

Sam Hocevar's avatar
 
Sam Hocevar committed
1920 1921
fi

1922 1923
echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
cat >> confdefs.h <<EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1924
#define STACK_DIRECTION $ac_cv_c_stack_direction
1925
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
1926 1927 1928

fi

1929
for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
Sam Hocevar's avatar
 
Sam Hocevar committed
1930
do
1931 1932
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1933
echo "configure:1934: checking for $ac_hdr" >&5
1934 1935
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
1936
else
1937
  cat > conftest.$ac_ext <<EOF
1938
#line 1939 "configure"
1939 1940 1941 1942
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1943
{ (eval echo configure:1944: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1944 1945 1946 1947 1948 1949 1950
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
1951
  cat conftest.$ac_ext >&5
1952 1953
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
1954
fi
1955
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
1956
fi
1957 1958 1959 1960 1961 1962 1963 1964 1965
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1966 1967 1968 1969 1970
fi
done

for ac_func in getpagesize
do
1971
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1972
echo "configure:1973: checking for $ac_func" >&5
1973 1974
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
1975
else
1976
  cat > conftest.$ac_ext <<EOF
1977
#line 1978 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
1978 1979
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
1980
    which can conflict with char $ac_func(); below.  */
Sam Hocevar's avatar
 
Sam Hocevar committed
1981 1982 1983
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
1984 1985 1986 1987
    builtin and then its argument prototype would still apply.  */
char $ac_func();

int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
1988 1989 1990 1991 1992 1993 1994

/* 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
#else
1995
$ac_func();
Sam Hocevar's avatar
 
Sam Hocevar committed
1996 1997
#endif

1998 1999
; return 0; }
EOF
2000
if { (eval echo configure:2001: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2001 2002 2003 2004 2005 2006 2007 2008 2009 2010
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=no"
fi
rm -f conftest*
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
2011

2012 2013 2014 2015 2016 2017 2018 2019 2020
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
  cat >> confdefs.h <<EOF
#define $ac_tr_func 1
EOF
 
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2021 2022 2023
fi
done

2024
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
2025
echo "configure:2026: checking for working mmap" >&5
2026 2027
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2028 2029 2030 2031
else
  if test "$cross_compiling" = yes; then
  ac_cv_func_mmap_fixed_mapped=no
else
2032
  cat > conftest.$ac_ext <<EOF
2033
#line 2034 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047
#include "confdefs.h"

/* Thanks to Mike Haertel and Jim Avera for this test.
   Here is a matrix of mmap possibilities:
	mmap private not fixed
	mmap private fixed at somewhere currently unmapped
	mmap private fixed at somewhere already mapped
	mmap shared not fixed
	mmap shared fixed at somewhere currently unmapped
	mmap shared fixed at somewhere already mapped
   For private mappings, we should verify that changes cannot be read()
   back from the file, nor mmap's back from the file at a different
   address.  (There have been systems where private was not correctly
   implemented like the infamous i386 svr4.0, and systems where the
2048
   VM page cache was not coherent with the filesystem buffer cache
Sam Hocevar's avatar
 
Sam Hocevar committed
2049 2050
   like early versions of FreeBSD and possibly contemporary NetBSD.)
   For shared mappings, we should conversely verify that changes get
2051
   propogated back to all the places they're supposed to be.
Sam Hocevar's avatar
 
Sam Hocevar committed
2052 2053 2054 2055 2056

   Grep wants private fixed already mapped.
   The main things grep needs to know about mmap are:
   * does it exist and is it safe to write into the mmap'd area
   * how to use it (BSD variants)  */
2057
#include <sys/types.h>
Sam Hocevar's avatar
 
Sam Hocevar committed
2058 2059 2060
#include <fcntl.h>
#include <sys/mman.h>

2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076
#if HAVE_SYS_TYPES_H
# include <sys/types.h>
#endif

#if HAVE_STDLIB_H
# include <stdlib.h>
#endif

#if HAVE_SYS_STAT_H
# include <sys/stat.h>
#endif

#if HAVE_UNISTD_H
# include <unistd.h>
#endif

2077
/* This mess was copied from the GNU getpagesize.h.  */
2078 2079
#ifndef HAVE_GETPAGESIZE

Sam Hocevar's avatar
 
Sam Hocevar committed
2080
/* Assume that all systems that can run configure have sys/param.h.  */
2081
# ifndef HAVE_SYS_PARAM_H
Sam Hocevar's avatar
 
Sam Hocevar committed
2082 2083 2084 2085 2086 2087
#  define HAVE_SYS_PARAM_H 1
# endif

# ifdef _SC_PAGESIZE
#  define getpagesize() sysconf(_SC_PAGESIZE)
# else /* no _SC_PAGESIZE */
2088
#  ifdef HAVE_SYS_PARAM_H
Sam Hocevar's avatar
 
Sam Hocevar committed
2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114
#   include <sys/param.h>
#   ifdef EXEC_PAGESIZE
#    define getpagesize() EXEC_PAGESIZE
#   else /* no EXEC_PAGESIZE */
#    ifdef NBPG
#     define getpagesize() NBPG * CLSIZE
#     ifndef CLSIZE
#      define CLSIZE 1
#     endif /* no CLSIZE */
#    else /* no NBPG */
#     ifdef NBPC
#      define getpagesize() NBPC
#     else /* no NBPC */
#      ifdef PAGESIZE
#       define getpagesize() PAGESIZE
#      endif /* PAGESIZE */
#     endif /* no NBPC */
#    endif /* no NBPG */
#   endif /* no EXEC_PAGESIZE */
#  else /* no HAVE_SYS_PARAM_H */
#   define getpagesize() 8192	/* punt totally */
#  endif /* no HAVE_SYS_PARAM_H */
# endif /* no _SC_PAGESIZE */

#endif /* no HAVE_GETPAGESIZE */

2115 2116 2117 2118 2119 2120
#ifdef __cplusplus
extern "C" { void *malloc(unsigned); }
#else
char *malloc();
#endif

Sam Hocevar's avatar
 
Sam Hocevar committed
2121
int
2122
main()
Sam Hocevar's avatar
 
Sam Hocevar committed
2123
{
2124 2125 2126 2127 2128 2129 2130 2131 2132
	char *data, *data2, *data3;
	int i, pagesize;
	int fd;

	pagesize = getpagesize();

	/*
	 * First, make a file with some known garbage in it.
	 */
2133
	data = malloc(pagesize);
2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153
	if (!data)
		exit(1);
	for (i = 0; i < pagesize; ++i)
		*(data + i) = rand();
	umask(0);
	fd = creat("conftestmmap", 0600);
	if (fd < 0)
		exit(1);
	if (write(fd, data, pagesize) != pagesize)
		exit(1);
	close(fd);

	/*
	 * Next, try to mmap the file at a fixed address which
	 * already has something else allocated at it.  If we can,
	 * also make sure that we see the same garbage.
	 */
	fd = open("conftestmmap", O_RDWR);
	if (fd < 0)
		exit(1);
2154
	data2 = malloc(2 * pagesize);
2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171
	if (!data2)
		exit(1);
	data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
	if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
	    MAP_PRIVATE | MAP_FIXED, fd, 0L))
		exit(1);
	for (i = 0; i < pagesize; ++i)
		if (*(data + i) != *(data2 + i))
			exit(1);

	/*
	 * Finally, make sure that changes to the mapped area
	 * do not percolate back to the file as seen by read().
	 * (This is a bug on some variants of i386 svr4.0.)
	 */
	for (i = 0; i < pagesize; ++i)
		*(data2 + i) = *(data2 + i) + 1;
2172
	data3 = malloc(pagesize);
2173 2174 2175 2176 2177 2178 2179 2180 2181 2182
	if (!data3)
		exit(1);
	if (read(fd, data3, pagesize) != pagesize)
		exit(1);
	for (i = 0; i < pagesize; ++i)
		if (*(data + i) != *(data3 + i))
			exit(1);
	close(fd);
	unlink("conftestmmap");
	exit(0);
Sam Hocevar's avatar
 
Sam Hocevar committed
2183
}
2184 2185

EOF
2186
if { (eval echo configure:2187: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2187
then
Sam Hocevar's avatar
 
Sam Hocevar committed
2188 2189
  ac_cv_func_mmap_fixed_mapped=yes
else
2190 2191 2192 2193
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -fr conftest*
  ac_cv_func_mmap_fixed_mapped=no
Sam Hocevar's avatar
 
Sam Hocevar committed
2194
fi
2195
rm -fr conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2196
fi
2197

Sam Hocevar's avatar
 
Sam Hocevar committed
2198
fi
2199

2200 2201 2202
echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
if test $ac_cv_func_mmap_fixed_mapped = yes; then
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2203
#define HAVE_MMAP 1
2204
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2205 2206 2207 2208

fi


2209
    echo $ac_n "checking whether we are using the GNU C Library 2.1 or newer""... $ac_c" 1>&6
2210
echo "configure:2211: checking whether we are using the GNU C Library 2.1 or newer" >&5
2211 2212
if eval "test \"`echo '$''{'ac_cv_gnu_library_2_1'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2213
else
2214
  cat > conftest.$ac_ext <<EOF
2215
#line 2216 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
2216 2217 2218 2219 2220 2221 2222 2223
#include "confdefs.h"

#include <features.h>
#ifdef __GNU_LIBRARY__
 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
  Lucky GNU user
 #endif
#endif
2224 2225
	
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2226 2227
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "Lucky GNU user" >/dev/null 2>&1; then
2228
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2229 2230
  ac_cv_gnu_library_2_1=yes
else
2231
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2232 2233 2234 2235
  ac_cv_gnu_library_2_1=no
fi
rm -f conftest*

2236 2237
      
    
Sam Hocevar's avatar
 
Sam Hocevar committed
2238 2239
fi

2240 2241
echo "$ac_t""$ac_cv_gnu_library_2_1" 1>&6
    
Sam Hocevar's avatar
 
Sam Hocevar committed
2242
    GLIBC21="$ac_cv_gnu_library_2_1"
2243
  
Sam Hocevar's avatar
 
Sam Hocevar committed
2244

2245 2246
                                    
   for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h stddef.h \
Sam Hocevar's avatar
 
Sam Hocevar committed
2247 2248
stdlib.h string.h unistd.h sys/param.h
do
2249 2250
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2251
echo "configure:2252: checking for $ac_hdr" >&5
2252 2253
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
2254
else
2255
  cat > conftest.$ac_ext <<EOF
2256
#line 2257 "configure"
2257 2258 2259 2260
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2261
{ (eval echo configure:2262: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2262 2263 2264 2265 2266 2267 2268
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
2269
  cat conftest.$ac_ext >&5
2270 2271
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
2272
fi
2273
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2274
fi
2275 2276 2277 2278 2279 2280 2281 2282 2283
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2284 2285 2286
fi
done

2287
   for ac_func in feof_unlocked fgets_unlocked getcwd getegid geteuid \
Sam Hocevar's avatar
 
Sam Hocevar committed
2288 2289 2290
getgid getuid mempcpy munmap putenv setenv setlocale stpcpy strchr strcasecmp \
strdup strtoul tsearch __argz_count __argz_stringify __argz_next
do
2291
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2292
echo "configure:2293: checking for $ac_func" >&5
2293 2294
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2295
else
2296
  cat > conftest.$ac_ext <<EOF
2297
#line 2298 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
2298 2299
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
2300
    which can conflict with char $ac_func(); below.  */
Sam Hocevar's avatar
 
Sam Hocevar committed
2301 2302 2303
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
2304 2305 2306 2307
    builtin and then its argument prototype would still apply.  */
char $ac_func();

int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
2308 2309 2310 2311 2312 2313 2314

/* 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
#else
2315
$ac_func();
Sam Hocevar's avatar
 
Sam Hocevar committed
2316 2317
#endif

2318 2319
; return 0; }
EOF
2320
if { (eval echo configure:2321: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2321 2322 2323 2324 2325 2326 2327 2328 2329 2330
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=no"
fi
rm -f conftest*
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
2331

2332 2333 2334 2335 2336 2337 2338 2339 2340
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
  cat >> confdefs.h <<EOF
#define $ac_tr_func 1
EOF
 
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2341 2342 2343 2344
fi
done


2345 2346 2347
   
    
  # Check whether --with-libiconv-prefix or --without-libiconv-prefix was given.
Sam Hocevar's avatar
 
Sam Hocevar committed
2348 2349
if test "${with_libiconv_prefix+set}" = set; then
  withval="$with_libiconv_prefix"
2350
  
Sam Hocevar's avatar
 
Sam Hocevar committed
2351 2352 2353 2354
    for dir in `echo "$withval" | tr : ' '`; do
      if test -d $dir/include; then CPPFLAGS="$CPPFLAGS -I$dir/include"; fi
      if test -d $dir/lib; then LDFLAGS="$LDFLAGS -L$dir/lib"; fi
    done
2355 2356
   
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
2357 2358


2359
  echo $ac_n "checking for iconv""... $ac_c" 1>&6
2360
echo "configure:2361: checking for iconv" >&5
2361 2362
if eval "test \"`echo '$''{'am_cv_func_iconv'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2363
else
2364
  
Sam Hocevar's avatar
 
Sam Hocevar committed
2365 2366
    am_cv_func_iconv="no, consider installing GNU libiconv"
    am_cv_lib_iconv=no
2367
    cat > conftest.$ac_ext <<EOF
2368
#line 2369 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
2369 2370 2371
#include "confdefs.h"
#include <stdlib.h>
#include <iconv.h>
2372
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
2373 2374 2375
iconv_t cd = iconv_open("","");
       iconv(cd,NULL,NULL,NULL,NULL);
       iconv_close(cd);
2376 2377
; return 0; }
EOF
2378
if { (eval echo configure:2379: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2379
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2380 2381
  am_cv_func_iconv=yes
else
2382 2383
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
2384
fi
2385
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2386 2387 2388
    if test "$am_cv_func_iconv" != yes; then
      am_save_LIBS="$LIBS"
      LIBS="$LIBS -liconv"
2389
      cat > conftest.$ac_ext <<EOF
2390
#line 2391 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
2391 2392 2393
#include "confdefs.h"
#include <stdlib.h>
#include <iconv.h>
2394
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
2395 2396 2397
iconv_t cd = iconv_open("","");
         iconv(cd,NULL,NULL,NULL,NULL);
         iconv_close(cd);
2398 2399
; return 0; }
EOF
2400
if { (eval echo configure:2401: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2401
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2402 2403 2404
  am_cv_lib_iconv=yes
        am_cv_func_iconv=yes
else
2405 2406
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
2407
fi
2408
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2409 2410
      LIBS="$am_save_LIBS"
    fi
2411
  
2412 2413
fi

2414 2415 2416
echo "$ac_t""$am_cv_func_iconv" 1>&6
  if test "$am_cv_func_iconv" = yes; then
    cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2417
#define HAVE_ICONV 1
2418
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2419

2420
    echo $ac_n "checking for iconv declaration""... $ac_c" 1>&6
2421
echo "configure:2422: checking for iconv declaration" >&5
2422 2423
    if eval "test \"`echo '$''{'am_cv_proto_iconv'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2424
else
2425 2426
  
      cat > conftest.$ac_ext <<EOF
2427
#line 2428 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441
#include "confdefs.h"

#include <stdlib.h>
#include <iconv.h>
extern
#ifdef __cplusplus
"C"
#endif
#if defined(__STDC__) || defined(__cplusplus)
size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
#else
size_t iconv();
#endif

2442
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
2443

2444 2445
; return 0; }
EOF
2446
if { (eval echo configure:2447: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
2447
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2448 2449
  am_cv_proto_iconv_arg1=""
else
2450 2451 2452 2453
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  am_cv_proto_iconv_arg1="const"
Sam Hocevar's avatar
 
Sam Hocevar committed
2454
fi
2455
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2456 2457 2458 2459
      am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);"
fi

    am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'`
2460 2461 2462
    echo "$ac_t""${ac_t:-
         }$am_cv_proto_iconv" 1>&6
    cat >> confdefs.h <<EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2463
#define ICONV_CONST $am_cv_proto_iconv_arg1
2464
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2465 2466 2467 2468 2469 2470

  fi
  LIBICONV=
  if test "$am_cv_lib_iconv" = yes; then
    LIBICONV="-liconv"
  fi
2471
  
Sam Hocevar's avatar
 
Sam Hocevar committed
2472

2473 2474
   
  echo $ac_n "checking for nl_langinfo and CODESET""... $ac_c" 1>&6
2475
echo "configure:2476: checking for nl_langinfo and CODESET" >&5
2476 2477
if eval "test \"`echo '$''{'am_cv_langinfo_codeset'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2478
else
2479
  cat > conftest.$ac_ext <<EOF
2480
#line 2481 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
2481 2482
#include "confdefs.h"
#include <langinfo.h>
2483
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
2484
char* cs = nl_langinfo(CODESET);
2485 2486
; return 0; }
EOF
2487
if { (eval echo configure:2488: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2488
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2489 2490
  am_cv_langinfo_codeset=yes
else
2491 2492 2493 2494
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  am_cv_langinfo_codeset=no
Sam Hocevar's avatar
 
Sam Hocevar committed
2495
fi
2496 2497
rm -f conftest*
    
2498 2499
fi

2500 2501 2502
echo "$ac_t""$am_cv_langinfo_codeset" 1>&6
  if test $am_cv_langinfo_codeset = yes; then
    cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2503
#define HAVE_LANGINFO_CODESET 1
2504
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2505 2506 2507 2508

  fi

   if test $ac_cv_header_locale_h = yes; then
2509
    echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
2510
echo "configure:2511: checking for LC_MESSAGES" >&5
2511 2512
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2513
else
2514
  cat > conftest.$ac_ext <<EOF
2515
#line 2516 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
2516 2517
#include "confdefs.h"
#include <locale.h>
2518
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
2519
return LC_MESSAGES
2520 2521
; return 0; }
EOF
2522
if { (eval echo configure:2523: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2523
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2524 2525
  am_cv_val_LC_MESSAGES=yes
else
2526 2527 2528 2529
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  am_cv_val_LC_MESSAGES=no
Sam Hocevar's avatar
 
Sam Hocevar committed
2530
fi
2531
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2532
fi
2533

2534 2535 2536
echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
    if test $am_cv_val_LC_MESSAGES = yes; then
      cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2537
#define HAVE_LC_MESSAGES 1
2538
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2539 2540 2541

    fi
  fi
2542
   echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
2543
echo "configure:2544: checking whether NLS is requested" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
2544 2545 2546 2547 2548 2549
        # Check whether --enable-nls or --disable-nls was given.
if test "${enable_nls+set}" = set; then
  enableval="$enable_nls"
  USE_NLS=$enableval
else
  USE_NLS=yes
2550
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
2551

2552 2553
    echo "$ac_t""$USE_NLS" 1>&6
    
Sam Hocevar's avatar
 
Sam Hocevar committed
2554 2555 2556 2557 2558 2559

    BUILD_INCLUDED_LIBINTL=no
    USE_INCLUDED_LIBINTL=no
    INTLLIBS=

        if test "$USE_NLS" = "yes"; then
2560
      cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2561
#define ENABLE_NLS 1
2562
EOF
2563

2564
      echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
2565
echo "configure:2566: checking whether included gettext is requested" >&5
2566
      # Check whether --with-included-gettext or --without-included-gettext was given.
Sam Hocevar's avatar
 
Sam Hocevar committed
2567 2568 2569 2570 2571
if test "${with_included_gettext+set}" = set; then
  withval="$with_included_gettext"
  nls_cv_force_use_gnu_gettext=$withval
else
  nls_cv_force_use_gnu_gettext=no
2572 2573 2574
fi

      echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2575 2576 2577 2578 2579

      nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
      if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
                        	CATOBJEXT=NONE

2580 2581
                
        
Sam Hocevar's avatar
 
Sam Hocevar committed
2582

2583 2584
	ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
2585
echo "configure:2586: checking for libintl.h" >&5
2586 2587
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2588
else
2589
  cat > conftest.$ac_ext <<EOF
2590
#line 2591 "configure"
2591 2592
#include "confdefs.h"
#include <libintl.h>
2593 2594
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2595
{ (eval echo configure:2596: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2596 2597 2598 2599 2600 2601 2602
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
2603
  cat conftest.$ac_ext >&5
2604 2605
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
2606
fi
2607
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2608
fi
2609 2610 2611
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  echo $ac_n "checking for GNU gettext in libc""... $ac_c" 1>&6
2612
echo "configure:2613: checking for GNU gettext in libc" >&5
2613 2614
if eval "test \"`echo '$''{'gt_cv_func_gnugettext1_libc'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2615
else
2616
  cat > conftest.$ac_ext <<EOF
2617
#line 2618 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
2618 2619 2620
#include "confdefs.h"
#include <libintl.h>
extern int _nl_msg_cat_cntr;
2621
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
2622 2623
bindtextdomain ("", "");
return (int) gettext ("") + _nl_msg_cat_cntr
2624 2625
; return 0; }
EOF
2626
if { (eval echo configure:2627: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2627
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2628 2629
  gt_cv_func_gnugettext1_libc=yes
else
2630 2631 2632 2633
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  gt_cv_func_gnugettext1_libc=no
Sam Hocevar's avatar
 
Sam Hocevar committed
2634
fi
2635
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2636
fi
2637 2638

echo "$ac_t""$gt_cv_func_gnugettext1_libc" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2639 2640

	   if test "$gt_cv_func_gnugettext1_libc" != "yes"; then
2641
	     echo $ac_n "checking for GNU gettext in libintl""... $ac_c" 1>&6
2642
echo "configure:2643: checking for GNU gettext in libintl" >&5
2643 2644
if eval "test \"`echo '$''{'gt_cv_func_gnugettext1_libintl'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2645 2646 2647
else
  gt_save_LIBS="$LIBS"
		LIBS="$LIBS -lintl $LIBICONV"
2648
		cat > conftest.$ac_ext <<EOF
2649
#line 2650 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
2650 2651 2652
#include "confdefs.h"
#include <libintl.h>
extern int _nl_msg_cat_cntr;
2653
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
2654 2655
bindtextdomain ("", "");
return (int) gettext ("") + _nl_msg_cat_cntr
2656 2657
; return 0; }
EOF
2658
if { (eval echo configure:2659: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2659
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2660 2661
  gt_cv_func_gnugettext1_libintl=yes
else
2662 2663 2664 2665
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  gt_cv_func_gnugettext1_libintl=no
Sam Hocevar's avatar
 
Sam Hocevar committed
2666
fi
2667
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
2668 2669
		LIBS="$gt_save_LIBS"
fi
2670 2671

echo "$ac_t""$gt_cv_func_gnugettext1_libintl" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2672 2673 2674 2675 2676
	   fi

	   	   	   	   	   if test "$gt_cv_func_gnugettext1_libc" = "yes" \
	      || { test "$gt_cv_func_gnugettext1_libintl" = "yes" \
		   && test "$PACKAGE" != gettext; }; then
2677
	     cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2678
#define HAVE_GETTEXT 1
2679
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
2680 2681 2682 2683 2684 2685 2686 2687


	     if test "$gt_cv_func_gnugettext1_libintl" = "yes"; then
	       	       	       	       INTLLIBS="-lintl $LIBICONV"
	     fi

	     gt_save_LIBS="$LIBS"
	     LIBS="$LIBS $INTLLIBS"
2688
	     for ac_func in dcgettext
Sam Hocevar's avatar
 
Sam Hocevar committed
2689
do
2690
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2691
echo "configure:2692: checking for $ac_func" >&5
2692 2693
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2694
else
2695
  cat > conftest.$ac_ext <<EOF
2696
#line 2697 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
2697 2698
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
2699
    which can conflict with char $ac_func(); below.  */
Sam Hocevar's avatar
 
Sam Hocevar committed
2700 2701 2702
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
2703 2704 2705 2706 2707
    builtin and then its argument prototype would still apply.  */
char $ac_func();

int main() {

Sam Hocevar's avatar
 
Sam Hocevar committed
2708 2709 2710 2711 2712 2713
/* 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
#else
2714
$ac_func();
Sam Hocevar's avatar
 
Sam Hocevar committed
2715 2716
#endif

2717 2718
; return 0; }
EOF
2719
if { (eval echo configure:2720: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2720 2721 2722 2723 2724 2725 2726 2727 2728 2729
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=no"
fi
rm -f conftest*
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
2730

2731 2732 2733 2734 2735 2736 2737 2738 2739
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
  cat >> confdefs.h <<EOF
#define $ac_tr_func 1
EOF
 
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2740 2741 2742 2743 2744 2745 2746
fi
done

	     LIBS="$gt_save_LIBS"

	     	     # Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
2747
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2748
echo "configure:2749: checking for $ac_word" >&5
2749 2750
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773
else
  case "$MSGFMT" in
  /*)
  ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
  ;;
  *)
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  for ac_dir in $PATH; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1; then
	ac_cv_path_MSGFMT="$ac_dir/$ac_word"
	break
      fi
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
  ;;
esac
fi
MSGFMT="$ac_cv_path_MSGFMT"
if test "$MSGFMT" != ":"; then
2774
  echo "$ac_t""$MSGFMT" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2775
else
2776
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2777 2778 2779 2780
fi

	     # Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
2781
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2782
echo "configure:2783: checking for $ac_word" >&5
2783 2784
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2785
else
2786 2787
  case "$GMSGFMT" in
  /*)
Sam Hocevar's avatar
 
Sam Hocevar committed
2788 2789
  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
  ;;
2790 2791 2792
  ?:/*)			 
  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
  ;;
2793
  *)
2794 2795 2796 2797 2798 2799 2800 2801 2802 2803
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
Sam Hocevar's avatar
 
Sam Hocevar committed
2804 2805 2806 2807
  test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
  ;;
esac
fi
2808
GMSGFMT="$ac_cv_path_GMSGFMT"
Sam Hocevar's avatar
 
Sam Hocevar committed
2809
if test -n "$GMSGFMT"; then
2810
  echo "$ac_t""$GMSGFMT" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2811
else
2812
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2813 2814 2815 2816 2817
fi


	     	     # Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
2818
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2819
echo "configure:2820: checking for $ac_word" >&5
2820 2821
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844
else
  case "$XGETTEXT" in
  /*)
  ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
  ;;
  *)
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  for ac_dir in $PATH; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      if $ac_dir/$ac_word --omit-header /dev/null >/dev/null 2>&1; then
	ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
	break
      fi
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
  ;;
esac
fi
XGETTEXT="$ac_cv_path_XGETTEXT"
if test "$XGETTEXT" != ":"; then
2845
  echo "$ac_t""$XGETTEXT" 1>&6
2846
else
2847
  echo "$ac_t""no" 1>&6
2848 2849
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
2850 2851 2852

	     CATOBJEXT=.gmo
	   fi
2853 2854 2855
	
else
  echo "$ac_t""no" 1>&6
2856 2857
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
2858 2859 2860 2861 2862 2863 2864 2865 2866 2867

        if test "$CATOBJEXT" = "NONE"; then
	  	  	  nls_cv_use_gnu_gettext=yes
        fi
      fi

      if test "$nls_cv_use_gnu_gettext" = "yes"; then
                INTLOBJS="\$(GETTOBJS)"
        # Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
2868
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2869
echo "configure:2870: checking for $ac_word" >&5
2870 2871
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
2872
else
Sam Hocevar's avatar
 
Sam Hocevar committed
2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894
  case "$MSGFMT" in
  /*)
  ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
  ;;
  *)
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  for ac_dir in $PATH; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1; then
	ac_cv_path_MSGFMT="$ac_dir/$ac_word"
	break
      fi
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
  ;;
esac
fi
MSGFMT="$ac_cv_path_MSGFMT"
if test "$MSGFMT" != ":"; then
2895
  echo "$ac_t""$MSGFMT" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2896
else
2897
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2898 2899 2900 2901
fi

        # Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
2902
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2903
echo "configure:2904: checking for $ac_word" >&5
2904 2905
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
2906
else
2907 2908
  case "$GMSGFMT" in
  /*)
Sam Hocevar's avatar
 
Sam Hocevar committed
2909 2910
  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
  ;;
2911 2912 2913
  ?:/*)			 
  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
  ;;
Sam Hocevar's avatar
 
Sam Hocevar committed
2914
  *)
2915 2916 2917 2918 2919 2920 2921 2922 2923 2924
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
Sam Hocevar's avatar
 
Sam Hocevar committed
2925 2926 2927
  test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
  ;;
esac
2928
fi
2929
GMSGFMT="$ac_cv_path_GMSGFMT"
Sam Hocevar's avatar
 
Sam Hocevar committed
2930
if test -n "$GMSGFMT"; then
2931
  echo "$ac_t""$GMSGFMT" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2932
else
2933
  echo "$ac_t""no" 1>&6
2934
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
2935 2936 2937

        # Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
2938
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2939
echo "configure:2940: checking for $ac_word" >&5
2940 2941
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964
else
  case "$XGETTEXT" in
  /*)
  ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
  ;;
  *)
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
  for ac_dir in $PATH; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      if $ac_dir/$ac_word --omit-header /dev/null >/dev/null 2>&1; then
	ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
	break
      fi
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
  ;;
esac
fi
XGETTEXT="$ac_cv_path_XGETTEXT"
if test "$XGETTEXT" != ":"; then
2965
  echo "$ac_t""$XGETTEXT" 1>&6
2966
else
2967
  echo "$ac_t""no" 1>&6
2968 2969
fi

2970
        
Sam Hocevar's avatar
 
Sam Hocevar committed
2971 2972 2973 2974 2975 2976
	BUILD_INCLUDED_LIBINTL=yes
	USE_INCLUDED_LIBINTL=yes
        CATOBJEXT=.gmo
	INTLLIBS="\$(top_builddir)/intl/libintl.a $LIBICONV"
	LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'`
      fi
2977

Sam Hocevar's avatar
 
Sam Hocevar committed
2978 2979 2980 2981
                  if test "$GMSGFMT" != ":"; then
			if $GMSGFMT --statistics /dev/null >/dev/null 2>&1; then
	  : ;
	else
2982
	  echo "$ac_t""found msgfmt program is not GNU msgfmt; ignore it" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2983 2984 2985 2986 2987 2988 2989 2990
	  GMSGFMT=":"
	fi
      fi

                  if test "$XGETTEXT" != ":"; then
			if $XGETTEXT --omit-header /dev/null >/dev/null 2>&1; then
	  : ;
	else
2991
	  echo "$ac_t""found xgettext program is not GNU xgettext; ignore it" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
2992 2993 2994 2995 2996 2997
	  XGETTEXT=":"
	fi
      fi

            POSUB=po
    fi
2998
    
Sam Hocevar's avatar
 
Sam Hocevar committed
2999 3000 3001 3002 3003 3004 3005 3006


            if test "$PACKAGE" = gettext; then
      BUILD_INCLUDED_LIBINTL=yes
    fi

                                            for ac_prog in bison
do
3007
# Extract the first word of "$ac_prog", so it can be a program name with args.
Sam Hocevar's avatar
 
Sam Hocevar committed
3008
set dummy $ac_prog; ac_word=$2
3009
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3010
echo "configure:3011: checking for $ac_word" >&5
3011 3012
if eval "test \"`echo '$''{'ac_cv_prog_INTLBISON'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3013
else
Sam Hocevar's avatar
 
Sam Hocevar committed
3014 3015
  if test -n "$INTLBISON"; then
  ac_cv_prog_INTLBISON="$INTLBISON" # Let the user override the test.
Sam Hocevar's avatar
 
Sam Hocevar committed
3016
else
3017 3018 3019 3020 3021 3022 3023 3024 3025 3026
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_INTLBISON="$ac_prog"
      break
    fi
  done
  IFS="$ac_save_ifs"
Sam Hocevar's avatar
 
Sam Hocevar committed
3027 3028
fi
fi
3029
INTLBISON="$ac_cv_prog_INTLBISON"
Sam Hocevar's avatar
 
Sam Hocevar committed
3030
if test -n "$INTLBISON"; then
3031
  echo "$ac_t""$INTLBISON" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3032
else
3033
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3034 3035
fi

3036
test -n "$INTLBISON" && break
Sam Hocevar's avatar
 
Sam Hocevar committed
3037 3038 3039 3040 3041
done

    if test -z "$INTLBISON"; then
      ac_verc_fail=yes
    else
3042
            echo $ac_n "checking version of bison""... $ac_c" 1>&6
3043
echo "configure:3044: checking version of bison" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
3044 3045 3046 3047 3048 3049 3050
      ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
      case $ac_prog_version in
        '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;;
        1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*)
           ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;;
        *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;;
      esac
3051
      echo "$ac_t""$ac_prog_version" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3052 3053 3054 3055 3056 3057 3058 3059 3060 3061
    fi
    if test $ac_verc_fail = yes; then
      INTLBISON=:
    fi

                for lang in $ALL_LINGUAS; do
      GMOFILES="$GMOFILES $lang.gmo"
      POFILES="$POFILES $lang.po"
    done

3062 3063 3064 3065 3066 3067 3068 3069 3070
        
    
    
    
    
    
    
    
    
Sam Hocevar's avatar
 
Sam Hocevar committed
3071 3072 3073 3074 3075

        nls_cv_header_intl=
    nls_cv_header_libgt=

        DATADIRNAME=share
3076
    
Sam Hocevar's avatar
 
Sam Hocevar committed
3077 3078

        INSTOBJEXT=.mo
3079
    
Sam Hocevar's avatar
 
Sam Hocevar committed
3080 3081

        GENCAT=gencat
3082 3083
    
  
Sam Hocevar's avatar
 
Sam Hocevar committed
3084 3085 3086 3087 3088

   if test "x$CATOBJEXT" != "x"; then
     if test "x$ALL_LINGUAS" = "x"; then
       LINGUAS=
     else
3089
       echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
3090
echo "configure:3091: checking for catalogs to be installed" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108
       NEW_LINGUAS=
       for presentlang in $ALL_LINGUAS; do
         useit=no
         for desiredlang in ${LINGUAS-$ALL_LINGUAS}; do
           # Use the presentlang catalog if desiredlang is
           #   a. equal to presentlang, or
           #   b. a variant of presentlang (because in this case,
           #      presentlang can be used as a fallback for messages
           #      which are not translated in the desiredlang catalog).
           case "$desiredlang" in
             "$presentlang"*) useit=yes;;
           esac
         done
         if test $useit = yes; then
           NEW_LINGUAS="$NEW_LINGUAS $presentlang"
         fi
       done
       LINGUAS=$NEW_LINGUAS
3109
       echo "$ac_t""$LINGUAS" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123
     fi

          if test -n "$LINGUAS"; then
       for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
     fi
   fi

            MKINSTALLDIRS=
   if test -n "$ac_aux_dir"; then
     MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs"
   fi
   if test -z "$MKINSTALLDIRS"; then
     MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
   fi
3124
   
3125

Sam Hocevar's avatar
 
Sam Hocevar committed
3126
      INTL_LIBTOOL_SUFFIX_PREFIX=
3127 3128
   
  
3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140

# Find a good install program.  We prefer a C program (faster),
# so one script is as good as another.  But avoid the broken or
# incompatible versions:
# SysV /etc/install, /usr/sbin/install
# SunOS /usr/etc/install
# IRIX /sbin/install
# AIX /bin/install
# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
# AFS /usr/afsws/bin/install, which mishandles nonexistent args
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
3141
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
3142
echo "configure:3143: checking for a BSD compatible install" >&5
3143
if test -z "$INSTALL"; then
3144 3145
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
3146
else
3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166
    IFS="${IFS= 	}"; ac_save_IFS="$IFS"; IFS=":"
  for ac_dir in $PATH; do
    # Account for people who put trailing slashes in PATH elements.
    case "$ac_dir/" in
    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
    *)
      # OSF1 and SCO ODT 3.0 have their own names for install.
      # Don't use installbsd from OSF since it installs stuff as root
      # by default.
      for ac_prog in ginstall scoinst install; do
        if test -f $ac_dir/$ac_prog; then
	  if test $ac_prog = install &&
            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
	    # AIX install.  It has an incompatible calling convention.
	    :
	  else
	    ac_cv_path_install="$ac_dir/$ac_prog -c"
	    break 2
	  fi
	fi
3167
      done
3168 3169 3170 3171
      ;;
    esac
  done
  IFS="$ac_save_IFS"
3172 3173 3174

fi
  if test "${ac_cv_path_install+set}" = set; then
3175
    INSTALL="$ac_cv_path_install"
3176 3177 3178 3179 3180
  else
    # As a last resort, use the slow shell script.  We don't cache a
    # path for INSTALL within a source directory, because that will
    # break other packages using the cache if that directory is
    # removed, or if the path is relative.
3181
    INSTALL="$ac_install_sh"
3182 3183
  fi
fi
3184
echo "$ac_t""$INSTALL" 1>&6
3185 3186 3187 3188 3189

# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
# It thinks the first close brace ends the variable substitution.
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'

3190
test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
3191 3192 3193

test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'

Sam Hocevar's avatar
 
Sam Hocevar committed
3194

Sam Hocevar's avatar
Sam Hocevar committed
3195 3196
vlc_LDFLAGS="${LDFLAGS}"

3197
case "x${target_os}" in
Gildas Bazin's avatar
 
Gildas Bazin committed
3198 3199 3200 3201 3202 3203 3204 3205
  x)
    SYS=unknown
    ;;
  xlinux*)
    SYS=linux
    ;;
  xbsdi*)
    SYS=bsdi
3206
    save_CFLAGS="${save_CFLAGS} -pthread"; CFLAGS="${save_CFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
3207 3208 3209 3210 3211
    dvd_LDFLAGS="${dvd_LDFLAGS} -ldvd"
    vcd_LDFLAGS="${vcd_LDFLAGS} -ldvd"
    ;;
  x*bsd*)
    SYS="${target_os}"
3212
    save_CFLAGS="${save_CFLAGS} -pthread"; CFLAGS="${save_CFLAGS}"
Gildas Bazin's avatar
 
Gildas Bazin committed
3213 3214 3215
    ;;
  xdarwin*)
    SYS=darwin
3216
    save_CFLAGS="${save_CFLAGS} -no-cpp-precomp"; CFLAGS="${save_CFLAGS}"
3217
    vlc_LDFLAGS="${vlc_LDFLAGS} -all_load"
Gildas Bazin's avatar
 
Gildas Bazin committed
3218 3219 3220
    ;;
  x*mingw32*)
    SYS=mingw32
3221
    # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
Gildas Bazin's avatar
 
Gildas Bazin committed
3222
set dummy ${ac_tool_prefix}windres; ac_word=$2
3223
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3224
echo "configure:3225: checking for $ac_word" >&5
3225 3226
if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
3227 3228 3229 3230
else
  if test -n "$WINDRES"; then
  ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
else
3231 3232 3233 3234 3235 3236 3237 3238 3239 3240
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
      break
    fi
  done
  IFS="$ac_save_ifs"
Gildas Bazin's avatar
 
Gildas Bazin committed
3241 3242
fi
fi
3243
WINDRES="$ac_cv_prog_WINDRES"
Gildas Bazin's avatar
 
Gildas Bazin committed
3244
if test -n "$WINDRES"; then
3245
  echo "$ac_t""$WINDRES" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
3246
else
3247
  echo "$ac_t""no" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
3248 3249
fi

3250

Gildas Bazin's avatar
 
Gildas Bazin committed
3251
if test -z "$ac_cv_prog_WINDRES"; then
3252
if test -n "$ac_tool_prefix"; then
Gildas Bazin's avatar
 
Gildas Bazin committed
3253 3254
  # Extract the first word of "windres", so it can be a program name with args.
set dummy windres; ac_word=$2
3255
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3256
echo "configure:3257: checking for $ac_word" >&5
3257 3258
if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
3259
else
3260 3261
  if test -n "$WINDRES"; then
  ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
Gildas Bazin's avatar
 
Gildas Bazin committed
3262
else
3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_prog_WINDRES="windres"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_prog_WINDRES" && ac_cv_prog_WINDRES=":"
Gildas Bazin's avatar
 
Gildas Bazin committed
3274 3275
fi
fi
3276 3277 3278
WINDRES="$ac_cv_prog_WINDRES"
if test -n "$WINDRES"; then
  echo "$ac_t""$WINDRES" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
3279
else
3280
  echo "$ac_t""no" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
3281 3282 3283
fi

else
3284 3285
  WINDRES=":"
fi
Gildas Bazin's avatar
 
Gildas Bazin committed
3286 3287
fi

3288
    save_CFLAGS="${save_CFLAGS} -fnative-struct -D_OFF_T_ -D_off_t=long"; CFLAGS="${save_CFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
3289
    vlc_LDFLAGS="${vlc_LDFLAGS} -mwindows -Xlinker --force-exe-suffix"
Sam Hocevar's avatar
 
Sam Hocevar committed
3290 3291
    vlc_LDFLAGS="${vlc_LDFLAGS} -lws2_32 -lnetapi32"
    ipv4_LDFLAGS="${ipv4_LDFLAGS} -lws2_32"
Gildas Bazin's avatar
 
Gildas Bazin committed
3292
    ipv6_LDFLAGS="${ipv6_LDFLAGS} -lws2_32"
3293
    http_LDFLAGS="${http_LDFLAGS} -lws2_32"
Sam Hocevar's avatar
 
Sam Hocevar committed
3294
    rc_LDFLAGS="${rc_LDFLAGS} -lws2_32"
Gildas Bazin's avatar
 
Gildas Bazin committed
3295 3296 3297
    ;;
  x*nto*)
    SYS=nto
Sam Hocevar's avatar
 
Sam Hocevar committed
3298 3299
    x11_LDFLAGS="${x11_LDFLAGS} -lsocket"
    xvideo_LDFLAGS="${xvideo_LDFLAGS} -lsocket"
Gildas Bazin's avatar
 
Gildas Bazin committed
3300 3301 3302
    ;;
  xbeos)
    SYS=beos
3303
    save_CFLAGS="${save_CFLAGS} -Wno-multichar -Wno-ctor-dtor-privacy -Woverloaded-virtual"; CFLAGS="${save_CFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
3304 3305 3306 3307
    vlc_LDFLAGS="${vlc_LDFLAGS} -lbe"
    plugins_LDFLAGS="${plugins_LDFLAGS} -nostart"
    beos_LDFLAGS="${beos_LDFLAGS} -lbe -lgame -lroot -ltracker"
    ipv4_LDFLAGS="${ipv4_LDFLAGS} -lbind"
Gildas Bazin's avatar
 
Gildas Bazin committed
3308 3309
    ;;
  x*)
Sam Hocevar's avatar
 
Sam Hocevar committed
3310
    SYS="${target_os}"
Gildas Bazin's avatar
 
Gildas Bazin committed
3311 3312 3313
    ;;
esac

3314
if test "x${SYS}" = "xmingw32"
Sam Hocevar's avatar
 
Sam Hocevar committed
3315 3316 3317 3318
then
  plugins_CFLAGS="${plugins_CFLAGS} -fnative-struct"
else
  plugins_CFLAGS="${plugins_CFLAGS} -fPIC"
3319
  plugins_LDFLAGS="${plugins_LDFLAGS} -fPIC"
Sam Hocevar's avatar
 
Sam Hocevar committed
3320 3321
fi

3322
save_CFLAGS="${save_CFLAGS} -DSYS_`echo ${SYS} | sed -e 's/-.*//' | tr 'abcdefghijklmnopqrstuvwxyz.' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`"; CFLAGS="${save_CFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
3323

3324
for ac_func in gettimeofday select strerror strtod strtol isatty vasprintf swab sigrelse getpwuid memalign posix_memalign gethostbyname2 atoll strndup
3325
do
3326
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
3327
echo "configure:3328: checking for $ac_func" >&5
3328 3329
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
3330
else
3331
  cat > conftest.$ac_ext <<EOF
3332
#line 3333 "configure"
3333 3334
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
3335
    which can conflict with char $ac_func(); below.  */
3336 3337 3338
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3339 3340 3341 3342
    builtin and then its argument prototype would still apply.  */
char $ac_func();

int main() {
3343 3344 3345 3346 3347 3348 3349

/* 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
#else
3350
$ac_func();
3351 3352
#endif

3353 3354
; return 0; }
EOF
3355
if { (eval echo configure:3356: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3356 3357 3358 3359 3360 3361 3362 3363 3364 3365
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_$ac_func=no"
fi
rm -f conftest*
fi
3366

3367 3368 3369 3370 3371 3372 3373 3374 3375
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
  cat >> confdefs.h <<EOF
#define $ac_tr_func 1
EOF
 
else
  echo "$ac_t""no" 1>&6
3376 3377 3378
fi
done

Sam Hocevar's avatar
 
Sam Hocevar committed
3379

3380
echo $ac_n "checking for connect""... $ac_c" 1>&6
3381
echo "configure:3382: checking for connect" >&5
3382 3383
if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
3384
else
3385
  cat > conftest.$ac_ext <<EOF
3386
#line 3387 "configure"
3387 3388
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
3389
    which can conflict with char connect(); below.  */
3390 3391 3392
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3393 3394 3395 3396
    builtin and then its argument prototype would still apply.  */
char connect();

int main() {
3397 3398 3399 3400 3401 3402 3403

/* 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_connect) || defined (__stub___connect)
choke me
#else
3404
connect();
3405 3406
#endif

3407 3408
; return 0; }
EOF
3409
if { (eval echo configure:3410: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422
  rm -rf conftest*
  eval "ac_cv_func_connect=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_connect=no"
fi
rm -f conftest*
fi

if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
  echo "$ac_t""yes" 1>&6
3423 3424
  :
else
3425
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3426

3427
  echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
3428
echo "configure:3429: checking for connect in -lsocket" >&5
3429 3430 3431
ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
3432
else
3433
  ac_save_LIBS="$LIBS"
3434
LIBS="-lsocket  $LIBS"
3435
cat > conftest.$ac_ext <<EOF
3436
#line 3437 "configure"
3437 3438 3439
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3440 3441 3442 3443 3444 3445 3446
    builtin and then its argument prototype would still apply.  */
char connect();

int main() {
connect()
; return 0; }
EOF
3447
if { (eval echo configure:3448: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3462 3463
  ipv4_LDFLAGS="${ipv4_LDFLAGS} -lsocket"
    vlc_LDFLAGS="${vlc_LDFLAGS} -lsocket"
Sam Hocevar's avatar
 
Sam Hocevar committed
3464

3465 3466
else
  echo "$ac_t""no" 1>&6
3467 3468 3469 3470
fi

fi

Sam Hocevar's avatar
Sam Hocevar committed
3471
echo $ac_n "checking for send""... $ac_c" 1>&6
3472
echo "configure:3473: checking for send" >&5
Sam Hocevar's avatar
Sam Hocevar committed
3473 3474 3475 3476
if eval "test \"`echo '$''{'ac_cv_func_send'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  cat > conftest.$ac_ext <<EOF
3477
#line 3478 "configure"
Sam Hocevar's avatar
Sam Hocevar committed
3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char send(); below.  */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char send();

int main() {

/* 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_send) || defined (__stub___send)
choke me
#else
send();
#endif

; return 0; }
EOF
3500
if { (eval echo configure:3501: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
Sam Hocevar's avatar
Sam Hocevar committed
3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518
  rm -rf conftest*
  eval "ac_cv_func_send=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_send=no"
fi
rm -f conftest*
fi

if eval "test \"`echo '$ac_cv_func_'send`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  :
else
  echo "$ac_t""no" 1>&6

  echo $ac_n "checking for send in -lsocket""... $ac_c" 1>&6
3519
echo "configure:3520: checking for send in -lsocket" >&5
Sam Hocevar's avatar
Sam Hocevar committed
3520 3521 3522 3523 3524 3525 3526
ac_lib_var=`echo socket'_'send | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  ac_save_LIBS="$LIBS"
LIBS="-lsocket  $LIBS"
cat > conftest.$ac_ext <<EOF
3527
#line 3528 "configure"
Sam Hocevar's avatar
Sam Hocevar committed
3528 3529 3530 3531 3532 3533 3534 3535 3536 3537
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char send();

int main() {
send()
; return 0; }
EOF
3538
if { (eval echo configure:3539: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
Sam Hocevar's avatar
Sam Hocevar committed
3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  http_LDFLAGS="${http_LDFLAGS} -lsocket"

else
  echo "$ac_t""no" 1>&6
fi

fi

3561
echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
3562
echo "configure:3563: checking for gethostbyname" >&5
3563 3564
if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
3565
else
3566
  cat > conftest.$ac_ext <<EOF
3567
#line 3568 "configure"
3568 3569
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
3570
    which can conflict with char gethostbyname(); below.  */
3571 3572 3573
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3574 3575 3576 3577
    builtin and then its argument prototype would still apply.  */
char gethostbyname();

int main() {
3578 3579 3580 3581 3582 3583 3584

/* 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_gethostbyname) || defined (__stub___gethostbyname)
choke me
#else
3585
gethostbyname();
3586 3587
#endif

3588 3589
; return 0; }
EOF
3590
if { (eval echo configure:3591: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603
  rm -rf conftest*
  eval "ac_cv_func_gethostbyname=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_gethostbyname=no"
fi
rm -f conftest*
fi

if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
  echo "$ac_t""yes" 1>&6
3604 3605
  :
else
3606
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3607

3608
  echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
3609
echo "configure:3610: checking for gethostbyname in -lnsl" >&5
3610 3611 3612
ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
3613
else
3614
  ac_save_LIBS="$LIBS"
3615
LIBS="-lnsl  $LIBS"
3616
cat > conftest.$ac_ext <<EOF
3617
#line 3618 "configure"
3618 3619 3620
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3621 3622 3623 3624 3625 3626 3627
    builtin and then its argument prototype would still apply.  */
char gethostbyname();

int main() {
gethostbyname()
; return 0; }
EOF
3628
if { (eval echo configure:3629: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3643
  ipv4_LDFLAGS="${ipv4_LDFLAGS} -lnsl"
3644 3645
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3646 3647 3648 3649 3650
fi


fi

3651
echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
3652
echo "configure:3653: checking for gethostbyname" >&5
3653 3654
if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3655
else
3656
  cat > conftest.$ac_ext <<EOF
3657
#line 3658 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
3658 3659
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
3660
    which can conflict with char gethostbyname(); below.  */
Sam Hocevar's avatar
 
Sam Hocevar committed
3661 3662 3663
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3664 3665 3666 3667
    builtin and then its argument prototype would still apply.  */
char gethostbyname();

int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
3668 3669 3670 3671 3672 3673 3674

/* 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_gethostbyname) || defined (__stub___gethostbyname)
choke me
#else
3675
gethostbyname();
Sam Hocevar's avatar
 
Sam Hocevar committed
3676 3677
#endif

3678 3679
; return 0; }
EOF
3680
if { (eval echo configure:3681: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693
  rm -rf conftest*
  eval "ac_cv_func_gethostbyname=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_gethostbyname=no"
fi
rm -f conftest*
fi

if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3694 3695
  :
else
3696
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3697

3698
  echo $ac_n "checking for gethostbyname in -lbind""... $ac_c" 1>&6
3699
echo "configure:3700: checking for gethostbyname in -lbind" >&5
3700 3701 3702
ac_lib_var=`echo bind'_'gethostbyname | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3703
else
3704
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
3705
LIBS="-lbind  $LIBS"
3706
cat > conftest.$ac_ext <<EOF
3707
#line 3708 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
3708 3709 3710
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3711 3712 3713 3714 3715 3716 3717
    builtin and then its argument prototype would still apply.  */
char gethostbyname();

int main() {
gethostbyname()
; return 0; }
EOF
3718
if { (eval echo configure:3719: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3733
  ipv4_LDFLAGS="${ipv4_LDFLAGS} -lbind"
3734 3735
else
  echo "$ac_t""no" 1>&6
3736 3737
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
3738

3739 3740
fi

3741 3742
have_nanosleep=0
echo $ac_n "checking for nanosleep""... $ac_c" 1>&6
3743
echo "configure:3744: checking for nanosleep" >&5
3744
if eval "test \"`echo '$''{'ac_cv_func_nanosleep'+set}'`\" = set"; then
3745
  echo $ac_n "(cached) $ac_c" 1>&6
3746
else
3747
  cat > conftest.$ac_ext <<EOF
3748
#line 3749 "configure"
3749 3750
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
3751
    which can conflict with char nanosleep(); below.  */
3752 3753 3754
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3755
    builtin and then its argument prototype would still apply.  */
3756
char nanosleep();
3757 3758

int main() {
3759 3760 3761 3762

/* 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.  */
3763
#if defined (__stub_nanosleep) || defined (__stub___nanosleep)
3764 3765
choke me
#else
3766
nanosleep();
3767 3768
#endif

3769 3770
; return 0; }
EOF
3771
if { (eval echo configure:3772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3772
  rm -rf conftest*
3773
  eval "ac_cv_func_nanosleep=yes"
3774 3775 3776 3777
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
3778
  eval "ac_cv_func_nanosleep=no"
3779 3780 3781 3782
fi
rm -f conftest*
fi

3783
if eval "test \"`echo '$ac_cv_func_'nanosleep`\" = yes"; then
3784
  echo "$ac_t""yes" 1>&6
3785
  have_nanosleep=1
3786 3787
else
  echo "$ac_t""no" 1>&6
3788 3789

  echo $ac_n "checking for nanosleep in -lrt""... $ac_c" 1>&6
3790
echo "configure:3791: checking for nanosleep in -lrt" >&5
3791 3792 3793 3794 3795
ac_lib_var=`echo rt'_'nanosleep | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  ac_save_LIBS="$LIBS"
3796
LIBS="-lrt  $LIBS"
3797
cat > conftest.$ac_ext <<EOF
3798
#line 3799 "configure"
3799
#include "confdefs.h"
3800 3801
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3802 3803 3804 3805 3806 3807 3808
    builtin and then its argument prototype would still apply.  */
char nanosleep();

int main() {
nanosleep()
; return 0; }
EOF
3809
if { (eval echo configure:3810: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
3824
  vlc_LDFLAGS="${vlc_LDFLAGS} -lrt"; have_nanosleep=1
3825
else
3826 3827
  echo "$ac_t""no" 1>&6
echo $ac_n "checking for nanosleep in -lposix4""... $ac_c" 1>&6
3828
echo "configure:3829: checking for nanosleep in -lposix4" >&5
3829 3830 3831
ac_lib_var=`echo posix4'_'nanosleep | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
3832
else
3833
  ac_save_LIBS="$LIBS"
3834
LIBS="-lposix4  $LIBS"
3835
cat > conftest.$ac_ext <<EOF
3836
#line 3837 "configure"
3837 3838 3839
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3840 3841 3842 3843 3844 3845 3846
    builtin and then its argument prototype would still apply.  */
char nanosleep();

int main() {
nanosleep()
; return 0; }
EOF
3847
if { (eval echo configure:3848: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3848 3849 3850 3851 3852 3853 3854
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
3855
fi
3856 3857
rm -f conftest*
LIBS="$ac_save_LIBS"
3858

3859 3860 3861
fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
3862
  vlc_LDFLAGS="${vlc_LDFLAGS} -lposix4"; have_nanosleep=1
3863 3864 3865
else
  echo "$ac_t""no" 1>&6
fi
3866

3867
  
3868 3869
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
3870

3871 3872
fi

3873 3874 3875 3876 3877 3878
if test x$have_nanosleep = x1; then
  cat >> confdefs.h <<\EOF
#define HAVE_NANOSLEEP 1
EOF

fi
3879 3880
# HP/UX port
echo $ac_n "checking for sem_init in -lrt""... $ac_c" 1>&6
3881
echo "configure:3882: checking for sem_init in -lrt" >&5
3882 3883 3884 3885 3886 3887 3888
ac_lib_var=`echo rt'_'sem_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  ac_save_LIBS="$LIBS"
LIBS="-lrt  $LIBS"
cat > conftest.$ac_ext <<EOF
3889
#line 3890 "configure"
3890 3891 3892 3893 3894 3895 3896 3897 3898 3899
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char sem_init();

int main() {
sem_init()
; return 0; }
EOF
3900
if { (eval echo configure:3901: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  vlc_LDFLAGS="${vlc_LDFLAGS} -lrt"
else
  echo "$ac_t""no" 1>&6
fi


3921
echo $ac_n "checking for inet_aton""... $ac_c" 1>&6
3922
echo "configure:3923: checking for inet_aton" >&5
3923 3924
if eval "test \"`echo '$''{'ac_cv_func_inet_aton'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
3925
else
3926
  cat > conftest.$ac_ext <<EOF
3927
#line 3928 "configure"
3928 3929
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
3930
    which can conflict with char inet_aton(); below.  */
3931 3932 3933
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3934 3935 3936 3937
    builtin and then its argument prototype would still apply.  */
char inet_aton();

int main() {
3938 3939 3940 3941 3942 3943 3944

/* 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_inet_aton) || defined (__stub___inet_aton)
choke me
#else
3945
inet_aton();
3946 3947
#endif

3948 3949
; return 0; }
EOF
3950
if { (eval echo configure:3951: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963
  rm -rf conftest*
  eval "ac_cv_func_inet_aton=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_inet_aton=no"
fi
rm -f conftest*
fi

if eval "test \"`echo '$ac_cv_func_'inet_aton`\" = yes"; then
  echo "$ac_t""yes" 1>&6
3964 3965
  :
else
3966
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
3967

3968
  echo $ac_n "checking for inet_aton in -lresolv""... $ac_c" 1>&6
3969
echo "configure:3970: checking for inet_aton in -lresolv" >&5
3970 3971 3972
ac_lib_var=`echo resolv'_'inet_aton | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
3973
else
3974
  ac_save_LIBS="$LIBS"
3975
LIBS="-lresolv  $LIBS"
3976
cat > conftest.$ac_ext <<EOF
3977
#line 3978 "configure"
3978 3979 3980
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
3981 3982 3983 3984 3985 3986 3987
    builtin and then its argument prototype would still apply.  */
char inet_aton();

int main() {
inet_aton()
; return 0; }
EOF
3988
if { (eval echo configure:3989: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4003
  ipv4_LDFLAGS="${ipv4_LDFLAGS} -lresolv"
4004 4005
else
  echo "$ac_t""no" 1>&6
4006 4007 4008 4009 4010
fi


fi

4011
echo $ac_n "checking for textdomain""... $ac_c" 1>&6
4012
echo "configure:4013: checking for textdomain" >&5
4013 4014
if eval "test \"`echo '$''{'ac_cv_func_textdomain'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4015
else
4016
  cat > conftest.$ac_ext <<EOF
4017
#line 4018 "configure"
4018 4019
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
4020
    which can conflict with char textdomain(); below.  */
4021 4022 4023
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
4024 4025 4026 4027
    builtin and then its argument prototype would still apply.  */
char textdomain();

int main() {
4028 4029 4030 4031 4032 4033 4034

/* 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_textdomain) || defined (__stub___textdomain)
choke me
#else
4035
textdomain();
4036 4037
#endif

4038 4039
; return 0; }
EOF
4040
if { (eval echo configure:4041: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053
  rm -rf conftest*
  eval "ac_cv_func_textdomain=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_textdomain=no"
fi
rm -f conftest*
fi

if eval "test \"`echo '$ac_cv_func_'textdomain`\" = yes"; then
  echo "$ac_t""yes" 1>&6
4054 4055
  :
else
4056
  echo "$ac_t""no" 1>&6
4057

4058
  echo $ac_n "checking for textdomain in -lintl""... $ac_c" 1>&6
4059
echo "configure:4060: checking for textdomain in -lintl" >&5
4060 4061 4062
ac_lib_var=`echo intl'_'textdomain | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4063
else
4064
  ac_save_LIBS="$LIBS"
4065
LIBS="-lintl  $LIBS"
4066
cat > conftest.$ac_ext <<EOF
4067
#line 4068 "configure"
4068 4069 4070
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
4071 4072 4073 4074 4075 4076 4077
    builtin and then its argument prototype would still apply.  */
char textdomain();

int main() {
textdomain()
; return 0; }
EOF
4078
if { (eval echo configure:4079: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
Sam Hocevar committed
4093
  vlc_LDFLAGS="${vlc_LDFLAGS} -lintl"
4094 4095
    plugins_LDFLAGS="${plugins_LDFLAGS} -lintl"
  
4096 4097
else
  echo "$ac_t""no" 1>&6
4098 4099
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
4100

4101 4102
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
4103

Sam Hocevar's avatar
 
Sam Hocevar committed
4104
NEED_GETOPT=0
4105
echo $ac_n "checking for getopt_long""... $ac_c" 1>&6
4106
echo "configure:4107: checking for getopt_long" >&5
4107 4108
if eval "test \"`echo '$''{'ac_cv_func_getopt_long'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4109
else
4110
  cat > conftest.$ac_ext <<EOF
4111
#line 4112 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
4112 4113
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
4114
    which can conflict with char getopt_long(); below.  */
Sam Hocevar's avatar
 
Sam Hocevar committed
4115 4116 4117
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
4118 4119 4120 4121
    builtin and then its argument prototype would still apply.  */
char getopt_long();

int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
4122 4123 4124 4125 4126 4127 4128

/* 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_getopt_long) || defined (__stub___getopt_long)
choke me
#else
4129
getopt_long();
Sam Hocevar's avatar
 
Sam Hocevar committed
4130 4131
#endif

4132 4133
; return 0; }
EOF
4134
if { (eval echo configure:4135: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148
  rm -rf conftest*
  eval "ac_cv_func_getopt_long=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_getopt_long=no"
fi
rm -f conftest*
fi

if eval "test \"`echo '$ac_cv_func_'getopt_long`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4149
#define HAVE_GETOPT_LONG 1
4150
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4151 4152

else
4153 4154 4155
  echo "$ac_t""no" 1>&6
 # FreeBSD has a gnugetopt library for this:
  echo $ac_n "checking for getopt_long in -lgnugetopt""... $ac_c" 1>&6
4156
echo "configure:4157: checking for getopt_long in -lgnugetopt" >&5
4157 4158 4159
ac_lib_var=`echo gnugetopt'_'getopt_long | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4160
else
4161
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
4162
LIBS="-lgnugetopt  $LIBS"
4163
cat > conftest.$ac_ext <<EOF
4164
#line 4165 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
4165 4166 4167
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
4168 4169 4170 4171 4172 4173 4174
    builtin and then its argument prototype would still apply.  */
char getopt_long();

int main() {
getopt_long()
; return 0; }
EOF
4175
if { (eval echo configure:4176: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4191
#define HAVE_GETOPT_LONG 1
4192
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4193
 vlc_LDFLAGS="${vlc_LDFLAGS} -lgnugetopt"
Sam Hocevar's avatar
 
Sam Hocevar committed
4194
else
4195 4196
  echo "$ac_t""no" 1>&6
NEED_GETOPT=1
Sam Hocevar's avatar
 
Sam Hocevar committed
4197
fi
4198 4199 4200

fi

Sam Hocevar's avatar
 
Sam Hocevar committed
4201

4202
echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
4203
echo "configure:4204: checking return type of signal handlers" >&5
4204 4205
if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4206
else
4207
  cat > conftest.$ac_ext <<EOF
4208
#line 4209 "configure"
4209 4210 4211 4212
#include "confdefs.h"
#include <sys/types.h>
#include <signal.h>
#ifdef signal
4213
#undef signal
4214 4215 4216 4217 4218 4219 4220
#endif
#ifdef __cplusplus
extern "C" void (*signal (int, void (*)(int)))(int);
#else
void (*signal ()) ();
#endif

4221
int main() {
4222
int i;
4223 4224
; return 0; }
EOF
4225
if { (eval echo configure:4226: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4226
  rm -rf conftest*
4227 4228
  ac_cv_type_signal=void
else
4229 4230 4231 4232
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_type_signal=int
4233
fi
4234
rm -f conftest*
4235 4236
fi

4237 4238
echo "$ac_t""$ac_cv_type_signal" 1>&6
cat >> confdefs.h <<EOF
4239
#define RETSIGTYPE $ac_cv_type_signal
4240
EOF
4241

Sam Hocevar's avatar
 
Sam Hocevar committed
4242

4243
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
4244
echo "configure:4245: checking for dlopen in -ldl" >&5
4245 4246 4247
ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4248
else
4249
  ac_save_LIBS="$LIBS"
4250
LIBS="-ldl  $LIBS"
4251
cat > conftest.$ac_ext <<EOF
4252
#line 4253 "configure"
4253 4254 4255
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
4256 4257 4258 4259 4260 4261 4262
    builtin and then its argument prototype would still apply.  */
char dlopen();

int main() {
dlopen()
; return 0; }
EOF
4263
if { (eval echo configure:4264: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4278
  vlc_LDFLAGS="${vlc_LDFLAGS} -ldl"
4279 4280
else
  echo "$ac_t""no" 1>&6
4281 4282
fi

4283
echo $ac_n "checking for cos in -lm""... $ac_c" 1>&6
4284
echo "configure:4285: checking for cos in -lm" >&5
4285 4286 4287
ac_lib_var=`echo m'_'cos | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4288
else
4289
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
4290
LIBS="-lm  $LIBS"
4291
cat > conftest.$ac_ext <<EOF
4292
#line 4293 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
4293 4294 4295
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
4296 4297 4298 4299 4300 4301 4302
    builtin and then its argument prototype would still apply.  */
char cos();

int main() {
cos()
; return 0; }
EOF
4303
if { (eval echo configure:4304: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4318 4319
  imdct_LDFLAGS="${imdct_LDFLAGS} -lm"
  filter_distort_LDFLAGS="${filter_distort_LDFLAGS} -lm"
4320 4321
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4322 4323
fi

4324
echo $ac_n "checking for pow in -lm""... $ac_c" 1>&6
4325
echo "configure:4326: checking for pow in -lm" >&5
4326 4327 4328
ac_lib_var=`echo m'_'pow | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4329
else
4330
  ac_save_LIBS="$LIBS"
4331
LIBS="-lm  $LIBS"
4332
cat > conftest.$ac_ext <<EOF
4333
#line 4334 "configure"
4334 4335 4336
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
4337 4338 4339 4340 4341 4342 4343
    builtin and then its argument prototype would still apply.  */
char pow();

int main() {
pow()
; return 0; }
EOF
4344
if { (eval echo configure:4345: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
Sam Hocevar committed
4359
  ffmpeg_LDFLAGS="${ffmpeg_LDFLAGS} -lm"
Sam Hocevar's avatar
 
Sam Hocevar committed
4360 4361 4362 4363
  imdct_LDFLAGS="${imdct_LDFLAGS} -lm"
  imdct3dn_LDFLAGS="${imdct3dn_LDFLAGS} -lm"
  imdctsse_LDFLAGS="${imdctsse_LDFLAGS} -lm"
  chroma_i420_rgb_LDFLAGS="${chroma_i420_rgb_LDFLAGS} -lm"
Sam Hocevar's avatar
 
Sam Hocevar committed
4364

4365 4366
else
  echo "$ac_t""no" 1>&6
4367 4368
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
4369

Sam Hocevar's avatar
 
Sam Hocevar committed
4370
THREAD_LIB=error
4371
if test "x${THREAD_LIB}" = "xerror"; then
4372
  echo $ac_n "checking for main in -lpthread""... $ac_c" 1>&6
4373
echo "configure:4374: checking for main in -lpthread" >&5
4374
ac_lib_var=`echo pthread'_'main | sed 'y%./+-%__p_%'`
4375 4376
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4377
else
4378
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
4379
LIBS="-lpthread  $LIBS"
4380
cat > conftest.$ac_ext <<EOF
4381
#line 4382 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
4382
#include "confdefs.h"
4383 4384

int main() {
4385
main()
4386 4387
; return 0; }
EOF
4388
if { (eval echo configure:4389: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4403
  THREAD_LIB="-lpthread"
4404 4405
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4406
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
4407

Sam Hocevar's avatar
 
Sam Hocevar committed
4408
fi
4409
if test "x${THREAD_LIB}" = "xerror"; then
4410
  echo $ac_n "checking for main in -lpthreads""... $ac_c" 1>&6
4411
echo "configure:4412: checking for main in -lpthreads" >&5
4412
ac_lib_var=`echo pthreads'_'main | sed 'y%./+-%__p_%'`
4413 4414
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4415
else
4416
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
4417
LIBS="-lpthreads  $LIBS"
4418
cat > conftest.$ac_ext <<EOF
4419
#line 4420 "configure"
4420
#include "confdefs.h"
4421 4422

int main() {
4423
main()
4424 4425
; return 0; }
EOF
4426
if { (eval echo configure:4427: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4441
  THREAD_LIB="-lpthreads"
4442 4443
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4444 4445
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
4446
fi
4447
if test "x${THREAD_LIB}" = "xerror"; then
4448
  echo $ac_n "checking for main in -lc_r""... $ac_c" 1>&6
4449
echo "configure:4450: checking for main in -lc_r" >&5
4450
ac_lib_var=`echo c_r'_'main | sed 'y%./+-%__p_%'`
4451 4452
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4453
else
4454
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
4455
LIBS="-lc_r  $LIBS"
4456
cat > conftest.$ac_ext <<EOF
4457
#line 4458 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
4458
#include "confdefs.h"
4459 4460

int main() {
4461
main()
4462 4463
; return 0; }
EOF
4464
if { (eval echo configure:4465: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4479
  THREAD_LIB="-lc_r"
4480 4481
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4482
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
4483

Sam Hocevar's avatar
 
Sam Hocevar committed
4484
fi
4485
if test "x${THREAD_LIB}" = "xerror"; then
4486
  echo $ac_n "checking for pthread_mutex_lock""... $ac_c" 1>&6
4487
echo "configure:4488: checking for pthread_mutex_lock" >&5
4488
if eval "test \"`echo '$''{'ac_cv_func_pthread_mutex_lock'+set}'`\" = set"; then
4489
  echo $ac_n "(cached) $ac_c" 1>&6
4490
else
4491
  cat > conftest.$ac_ext <<EOF
4492
#line 4493 "configure"
4493
#include "confdefs.h"
Sam Hocevar's avatar
 
Sam Hocevar committed
4494
/* System header to define __stub macros and hopefully few prototypes,
4495
    which can conflict with char pthread_mutex_lock(); below.  */
Sam Hocevar's avatar
 
Sam Hocevar committed
4496
#include <assert.h>
4497 4498
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
4499
    builtin and then its argument prototype would still apply.  */
4500
char pthread_mutex_lock();
4501 4502

int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
4503 4504 4505 4506

/* 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.  */
4507
#if defined (__stub_pthread_mutex_lock) || defined (__stub___pthread_mutex_lock)
Sam Hocevar's avatar
 
Sam Hocevar committed
4508 4509
choke me
#else
4510
pthread_mutex_lock();
Sam Hocevar's avatar
 
Sam Hocevar committed
4511 4512
#endif

4513 4514
; return 0; }
EOF
4515
if { (eval echo configure:4516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4516
  rm -rf conftest*
4517
  eval "ac_cv_func_pthread_mutex_lock=yes"
4518 4519 4520 4521
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
4522
  eval "ac_cv_func_pthread_mutex_lock=no"
4523 4524 4525 4526
fi
rm -f conftest*
fi

4527
if eval "test \"`echo '$ac_cv_func_'pthread_mutex_lock`\" = yes"; then
4528 4529 4530 4531 4532
  echo "$ac_t""yes" 1>&6
  :
else
  echo "$ac_t""no" 1>&6
fi
4533

Sam Hocevar's avatar
 
Sam Hocevar committed
4534
  THREAD_LIB=""
Sam Hocevar's avatar
 
Sam Hocevar committed
4535
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
4536

4537
echo $ac_n "checking for cthread_fork in -lthreads""... $ac_c" 1>&6
4538
echo "configure:4539: checking for cthread_fork in -lthreads" >&5
4539 4540 4541
ac_lib_var=`echo threads'_'cthread_fork | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4542
else
4543
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
4544
LIBS="-lthreads  $LIBS"
4545
cat > conftest.$ac_ext <<EOF
4546
#line 4547 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
4547 4548 4549
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
4550 4551 4552 4553 4554 4555 4556
    builtin and then its argument prototype would still apply.  */
char cthread_fork();

int main() {
cthread_fork()
; return 0; }
EOF
4557
if { (eval echo configure:4558: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4572
  THREAD_LIB="-lthreads"
4573 4574
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4575
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
4576 4577


4578
cat > conftest.$ac_ext <<EOF
4579
#line 4580 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
4580 4581
#include "confdefs.h"
#include <pthread.h>
4582
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4583 4584
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "pthread_cond_t" >/dev/null 2>&1; then
4585 4586 4587
  rm -rf conftest*
  
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4588
#define PTHREAD_COND_T_IN_PTHREAD_H 1
4589
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4590 4591 4592 4593

fi
rm -f conftest*

4594
cat > conftest.$ac_ext <<EOF
4595
#line 4596 "configure"
Sam Hocevar's avatar
Sam Hocevar committed
4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610
#include "confdefs.h"
#include <pthread.h>
EOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "pthread_once" >/dev/null 2>&1; then
  rm -rf conftest*
  
  cat >> confdefs.h <<\EOF
#define PTHREAD_ONCE_IN_PTHREAD_H 1
EOF

fi
rm -f conftest*

cat > conftest.$ac_ext <<EOF
4611
#line 4612 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
4612 4613
#include "confdefs.h"
#include <strings.h>
4614
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4615 4616
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "strncasecmp" >/dev/null 2>&1; then
4617 4618 4619
  rm -rf conftest*
  
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4620
#define STRNCASECMP_IN_STRINGS_H 1
4621
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4622 4623 4624

fi
rm -f conftest*
4625

Sam Hocevar's avatar
 
Sam Hocevar committed
4626

Sam Hocevar's avatar
Sam Hocevar committed
4627
for ac_hdr in stdint.h getopt.h strings.h inttypes.h sys/int_types.h
Christophe Massiot's avatar
Christophe Massiot committed
4628
do
4629 4630
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4631
echo "configure:4632: checking for $ac_hdr" >&5
4632 4633
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4634
else
4635
  cat > conftest.$ac_ext <<EOF
4636
#line 4637 "configure"
4637 4638 4639 4640
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4641
{ (eval echo configure:4642: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4642 4643 4644 4645 4646 4647 4648
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Christophe Massiot's avatar
Christophe Massiot committed
4649
  cat conftest.$ac_ext >&5
4650 4651
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Christophe Massiot's avatar
Christophe Massiot committed
4652
fi
4653
rm -f conftest*
Christophe Massiot's avatar
Christophe Massiot committed
4654
fi
4655 4656 4657 4658 4659 4660 4661 4662 4663
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&6
Christophe Massiot's avatar
Christophe Massiot committed
4664 4665 4666
fi
done

4667
for ac_hdr in sys/sockio.h fcntl.h sys/types.h sys/time.h sys/times.h
4668
do
4669 4670
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4671
echo "configure:4672: checking for $ac_hdr" >&5
4672 4673
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4674
else
4675
  cat > conftest.$ac_ext <<EOF
4676
#line 4677 "configure"
4677 4678 4679 4680
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4681
{ (eval echo configure:4682: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4682 4683 4684 4685 4686 4687 4688
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
4689
  cat conftest.$ac_ext >&5
4690 4691
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
4692
fi
4693
rm -f conftest*
4694
fi
4695 4696 4697 4698 4699 4700 4701 4702 4703
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&6
4704 4705 4706
fi
done

4707
for ac_hdr in dlfcn.h image.h
4708
do
4709 4710
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4711
echo "configure:4712: checking for $ac_hdr" >&5
4712 4713
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4714
else
4715
  cat > conftest.$ac_ext <<EOF
4716
#line 4717 "configure"
4717 4718 4719 4720
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4721
{ (eval echo configure:4722: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4722 4723 4724 4725 4726 4727 4728
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
4729
  cat conftest.$ac_ext >&5
4730 4731
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
4732
fi
4733
rm -f conftest*
4734
fi
4735 4736 4737 4738 4739 4740 4741 4742 4743
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&6
4744 4745 4746
fi
done

4747
for ac_hdr in arpa/inet.h net/if.h netinet/in.h sys/socket.h
4748
do
4749 4750
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4751
echo "configure:4752: checking for $ac_hdr" >&5
4752 4753
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4754
else
4755
  cat > conftest.$ac_ext <<EOF
4756
#line 4757 "configure"
4757 4758 4759 4760
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4761
{ (eval echo configure:4762: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4762 4763 4764 4765 4766 4767 4768
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
4769
  cat conftest.$ac_ext >&5
4770 4771
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
4772
fi
4773
rm -f conftest*
4774
fi
4775 4776 4777 4778 4779 4780 4781 4782 4783
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&6
4784 4785 4786
fi
done

4787
for ac_hdr in machine/param.h sys/shm.h
4788
do
4789 4790
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4791
echo "configure:4792: checking for $ac_hdr" >&5
4792 4793
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4794
else
4795
  cat > conftest.$ac_ext <<EOF
4796
#line 4797 "configure"
4797 4798 4799 4800
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4801
{ (eval echo configure:4802: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4802 4803 4804 4805 4806 4807 4808
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
4809
  cat conftest.$ac_ext >&5
4810 4811
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
4812
fi
4813
rm -f conftest*
4814
fi
4815 4816 4817 4818 4819 4820 4821 4822 4823
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&6
4824 4825 4826
fi
done

4827
for ac_hdr in linux/version.h
4828
do
4829 4830
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4831
echo "configure:4832: checking for $ac_hdr" >&5
4832 4833
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4834
else
4835
  cat > conftest.$ac_ext <<EOF
4836
#line 4837 "configure"
4837 4838 4839 4840
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4841
{ (eval echo configure:4842: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4842 4843 4844 4845 4846 4847 4848
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
4849
  cat conftest.$ac_ext >&5
4850 4851
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
4852
fi
4853
rm -f conftest*
4854
fi
4855 4856 4857 4858 4859 4860 4861 4862 4863
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&6
4864 4865 4866
fi
done

Sam Hocevar's avatar
 
Sam Hocevar committed
4867

4868
echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
4869
echo "configure:4870: checking whether time.h and sys/time.h may both be included" >&5
4870 4871
if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
4872
else
4873
  cat > conftest.$ac_ext <<EOF
4874
#line 4875 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
4875 4876 4877 4878
#include "confdefs.h"
#include <sys/types.h>
#include <sys/time.h>
#include <time.h>
4879 4880 4881 4882
int main() {
struct tm *tp;
; return 0; }
EOF
4883
if { (eval echo configure:4884: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4884
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
4885 4886
  ac_cv_header_time=yes
else
4887 4888 4889 4890
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_header_time=no
Sam Hocevar's avatar
 
Sam Hocevar committed
4891
fi
4892
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
4893
fi
4894

4895 4896 4897
echo "$ac_t""$ac_cv_header_time" 1>&6
if test $ac_cv_header_time = yes; then
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4898
#define TIME_WITH_SYS_TIME 1
4899
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
4900 4901 4902 4903

fi


4904
cat > conftest.$ac_ext <<EOF
4905
#line 4906 "configure"
Christophe Massiot's avatar
Christophe Massiot committed
4906
#include "confdefs.h"
4907 4908 4909 4910 4911 4912 4913
#include <time.h>
EOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "nanosleep" >/dev/null 2>&1; then
  rm -rf conftest*
  
  cat >> confdefs.h <<\EOF
4914
#define HAVE_DECL_NANOSLEEP 1
4915
EOF
4916 4917 4918


fi
4919
rm -f conftest*
4920 4921


4922
cat > conftest.$ac_ext <<EOF
4923
#line 4924 "configure"
4924
#include "confdefs.h"
4925 4926 4927 4928 4929 4930 4931
#include <sys/time.h>
EOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "timespec" >/dev/null 2>&1; then
  rm -rf conftest*
  
  cat >> confdefs.h <<\EOF
4932
#define HAVE_STRUCT_TIMESPEC 1
4933
EOF
4934 4935 4936


fi
4937
rm -f conftest*
4938 4939


4940
for ac_hdr in cthreads.h pthread.h kernel/scheduler.h kernel/OS.h
4941
do
4942 4943
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4944
echo "configure:4945: checking for $ac_hdr" >&5
4945 4946
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4947
else
4948
  cat > conftest.$ac_ext <<EOF
4949
#line 4950 "configure"
4950 4951 4952 4953
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4954
{ (eval echo configure:4955: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4955 4956 4957 4958 4959 4960 4961
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
4962
  cat conftest.$ac_ext >&5
4963 4964
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
4965
fi
4966
rm -f conftest*
Christophe Massiot's avatar
Christophe Massiot committed
4967
fi
4968 4969 4970 4971 4972 4973 4974 4975 4976
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&6
4977
fi
Christophe Massiot's avatar
Christophe Massiot committed
4978 4979
done

Sam Hocevar's avatar
 
Sam Hocevar committed
4980

4981 4982 4983 4984 4985 4986 4987 4988
if test "x${x_includes}" = "xNONE"; then
  x_includes="/usr/X11R6/include"
fi
if test "x${x_libraries}" = "xNONE"; then
  x_libraries="/usr/X11R6/lib"
fi

if test "x${SYS}" != "xmingw32"
Sam Hocevar's avatar
 
Sam Hocevar committed
4989
then
4990
  CPPFLAGS="${save_CPPFLAGS} -I${x_includes}"
4991
  for ac_hdr in X11/extensions/dpms.h
Sam Hocevar's avatar
 
Sam Hocevar committed
4992
do
4993 4994
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4995
echo "configure:4996: checking for $ac_hdr" >&5
4996 4997
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
4998
else
4999
  cat > conftest.$ac_ext <<EOF
5000
#line 5001 "configure"
5001 5002 5003 5004
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5005
{ (eval echo configure:5006: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5006 5007 5008 5009 5010 5011 5012
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
5013
  cat conftest.$ac_ext >&5
5014 5015
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
5016
fi
5017
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5018
fi
5019 5020 5021 5022 5023 5024 5025 5026
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
    cat > conftest.$ac_ext <<EOF
5027
#line 5028 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5028 5029
#include "confdefs.h"
#include <X11/extensions/dpms.h>
5030
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
5031 5032
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "DPMSInfo" >/dev/null 2>&1; then
5033 5034 5035
  rm -rf conftest*
  
      cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
5036
#define DPMSINFO_IN_DPMS_H 1
5037
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
5038

5039
    
Sam Hocevar's avatar
 
Sam Hocevar committed
5040 5041 5042
fi
rm -f conftest*

5043 5044 5045
  
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
5046 5047 5048
fi
done

5049
  CPPFLAGS="${save_CPPFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
5050 5051
fi

5052
echo $ac_n "checking for ntohl in sys/param.h""... $ac_c" 1>&6
5053
echo "configure:5054: checking for ntohl in sys/param.h" >&5
5054 5055
if eval "test \"`echo '$''{'ac_cv_c_ntohl_sys_param_h'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5056 5057
else
  CFLAGS="${save_CFLAGS} -Wall -Werror"
5058
     cat > conftest.$ac_ext <<EOF
5059
#line 5060 "configure"
Christophe Massiot's avatar
Christophe Massiot committed
5060 5061
#include "confdefs.h"
#include <sys/param.h>
5062
int main() {
5063
void foo() { int meuh; ntohl(meuh); }
5064 5065
; return 0; }
EOF
5066
if { (eval echo configure:5067: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5067
  rm -rf conftest*
5068
  ac_cv_c_ntohl_sys_param_h=yes
Christophe Massiot's avatar
Christophe Massiot committed
5069
else
5070 5071 5072 5073
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_ntohl_sys_param_h=no
Christophe Massiot's avatar
Christophe Massiot committed
5074
fi
5075
rm -f conftest*
5076
fi
5077

5078
echo "$ac_t""$ac_cv_c_ntohl_sys_param_h" 1>&6
5079
if test "x${ac_cv_c_ntohl_sys_param_h}" != "xno"; then
5080
    cat >> confdefs.h <<\EOF
5081
#define NTOHL_IN_SYS_PARAM_H 1
5082
EOF
5083 5084

fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5085

5086
echo $ac_n "checking if \$CC accepts -finline-limit""... $ac_c" 1>&6
5087
echo "configure:5088: checking if \$CC accepts -finline-limit" >&5
5088 5089
if eval "test \"`echo '$''{'ac_cv_c_inline_limit'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5090 5091
else
  CFLAGS="${save_CFLAGS} -finline-limit-30000"
5092
     cat > conftest.$ac_ext <<EOF
5093
#line 5094 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5094 5095
#include "confdefs.h"

5096
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5097

5098 5099
; return 0; }
EOF
5100
if { (eval echo configure:5101: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5101
  rm -rf conftest*
5102
  ac_cv_c_inline_limit=yes
Sam Hocevar's avatar
 
Sam Hocevar committed
5103
else
5104 5105 5106 5107
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_inline_limit=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5108
fi
5109
rm -f conftest*
5110
fi
5111 5112

echo "$ac_t""$ac_cv_c_inline_limit" 1>&6
5113 5114
if test "x${ac_cv_c_inline_limit}" != "xno"; then
    save_CFLAGS="${save_CFLAGS} -finline-limit-30000"; CFLAGS="${save_CFLAGS}"
5115 5116
fi

5117
echo $ac_n "checking if \$CC accepts -Wall -Winline""... $ac_c" 1>&6
5118
echo "configure:5119: checking if \$CC accepts -Wall -Winline" >&5
5119 5120
if eval "test \"`echo '$''{'ac_cv_c_Wall_Winline'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
5121
else
Sam Hocevar's avatar
Sam Hocevar committed
5122
  CFLAGS="-Wall -Winline ${save_CFLAGS}"
5123
     cat > conftest.$ac_ext <<EOF
5124
#line 5125 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5125 5126
#include "confdefs.h"

5127
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5128

5129 5130
; return 0; }
EOF
5131
if { (eval echo configure:5132: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5132
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5133 5134
  ac_cv_c_Wall_Winline=yes
else
5135 5136 5137 5138
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_Wall_Winline=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5139
fi
5140
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5141
fi
5142 5143

echo "$ac_t""$ac_cv_c_Wall_Winline" 1>&6
5144 5145
if test "x${ac_cv_c_Wall_Winline}" != "xno"; then
    save_CFLAGS="-Wall -Winline ${save_CFLAGS}"; CFLAGS="${save_CFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
5146
else
5147
    echo $ac_n "checking if \$CC accepts -wall -winline""... $ac_c" 1>&6
5148
echo "configure:5149: checking if \$CC accepts -wall -winline" >&5
5149 5150
if eval "test \"`echo '$''{'ac_cv_c_wall_winline'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
5151
else
Sam Hocevar's avatar
Sam Hocevar committed
5152
  CFLAGS="-wall -winline ${save_CFLAGS}"
5153
         cat > conftest.$ac_ext <<EOF
5154
#line 5155 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5155 5156
#include "confdefs.h"

5157
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5158

5159 5160
; return 0; }
EOF
5161
if { (eval echo configure:5162: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5162
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5163 5164
  ac_cv_c_wall_winline=yes
else
5165 5166 5167 5168
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_wall_winline=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5169
fi
5170
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5171
fi
5172 5173

echo "$ac_t""$ac_cv_c_wall_winline" 1>&6
5174 5175
    if test "x${ac_cv_c_wall_winline}" != "xno"; then
        save_CFLAGS="-wall -winline ${save_CFLAGS}"; CFLAGS="${save_CFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
5176 5177 5178
    fi
fi

5179
echo $ac_n "checking if \$CC accepts -pipe""... $ac_c" 1>&6
5180
echo "configure:5181: checking if \$CC accepts -pipe" >&5
5181 5182
if eval "test \"`echo '$''{'ac_cv_c_pipe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
5183 5184
else
  CFLAGS="${save_CFLAGS} -pipe"
5185
     cat > conftest.$ac_ext <<EOF
5186
#line 5187 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5187 5188
#include "confdefs.h"

5189
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5190

5191 5192
; return 0; }
EOF
5193
if { (eval echo configure:5194: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5194
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5195 5196
  ac_cv_c_pipe=yes
else
5197 5198 5199 5200
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_pipe=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5201
fi
5202
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5203
fi
5204 5205

echo "$ac_t""$ac_cv_c_pipe" 1>&6
5206 5207
if test "x${ac_cv_c_pipe}" != "xno"; then
    save_CFLAGS="${save_CFLAGS} -pipe"; CFLAGS="${save_CFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
5208 5209
fi

5210
echo $ac_n "checking if \$CC accepts -O3""... $ac_c" 1>&6
5211
echo "configure:5212: checking if \$CC accepts -O3" >&5
5212 5213
if eval "test \"`echo '$''{'ac_cv_c_o3'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
5214 5215
else
  CFLAGS="${save_CFLAGS} -O3"
5216
     cat > conftest.$ac_ext <<EOF
5217
#line 5218 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5218 5219
#include "confdefs.h"

5220
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5221

5222 5223
; return 0; }
EOF
5224
if { (eval echo configure:5225: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5225
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5226 5227
  ac_cv_c_o3=yes
else
5228 5229 5230 5231
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_o3=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5232
fi
5233
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5234
fi
5235 5236

echo "$ac_t""$ac_cv_c_o3" 1>&6
5237
if test "x${ac_cv_c_o3}" != "xno"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
5238 5239
    CFLAGS_OPTIM="${CFLAGS_OPTIM} -O3"
else
5240
    echo $ac_n "checking if \$CC accepts -O2""... $ac_c" 1>&6
5241
echo "configure:5242: checking if \$CC accepts -O2" >&5
5242 5243
if eval "test \"`echo '$''{'ac_cv_c_o2'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
5244 5245
else
  CFLAGS="${save_CFLAGS} -O2"
5246
         cat > conftest.$ac_ext <<EOF
5247
#line 5248 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5248 5249
#include "confdefs.h"

5250
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5251

5252 5253
; return 0; }
EOF
5254
if { (eval echo configure:5255: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5255
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5256 5257
  ac_cv_c_o2=yes
else
5258 5259 5260 5261
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_o2=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5262
fi
5263
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5264
fi
5265 5266

echo "$ac_t""$ac_cv_c_o2" 1>&6
5267
    if test "x${ac_cv_c_o2}" != "xno"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
5268 5269
        CFLAGS_OPTIM="${CFLAGS_OPTIM} -O2"
    else
5270
        echo $ac_n "checking if \$CC accepts -O""... $ac_c" 1>&6
5271
echo "configure:5272: checking if \$CC accepts -O" >&5
5272 5273
if eval "test \"`echo '$''{'ac_cv_c_o'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
5274 5275
else
  CFLAGS="${save_CFLAGS} -O"
5276
             cat > conftest.$ac_ext <<EOF
5277
#line 5278 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5278 5279
#include "confdefs.h"

5280
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5281

5282 5283
; return 0; }
EOF
5284
if { (eval echo configure:5285: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5285
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5286 5287
  ac_cv_c_o=yes
else
5288 5289 5290 5291
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_o=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5292
fi
5293
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5294
fi
5295 5296

echo "$ac_t""$ac_cv_c_o" 1>&6
5297
        if test "x${ac_cv_c_o}" != "xno"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
5298 5299 5300 5301 5302
            CFLAGS_OPTIM="${CFLAGS_OPTIM} -O"
        fi
    fi
fi

5303
echo $ac_n "checking if \$CC accepts -ffast-math""... $ac_c" 1>&6
5304
echo "configure:5305: checking if \$CC accepts -ffast-math" >&5
5305 5306
if eval "test \"`echo '$''{'ac_cv_c_fast_math'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
5307 5308
else
  CFLAGS="${save_CFLAGS} -ffast-math"
5309
     cat > conftest.$ac_ext <<EOF
5310
#line 5311 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5311 5312
#include "confdefs.h"

5313
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5314

5315 5316
; return 0; }
EOF
5317
if { (eval echo configure:5318: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5318
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5319 5320
  ac_cv_c_fast_math=yes
else
5321 5322 5323 5324
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_fast_math=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5325
fi
5326
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5327
fi
5328 5329

echo "$ac_t""$ac_cv_c_fast_math" 1>&6
5330
if test "x${ac_cv_c_fast_math}" != "xno"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
5331 5332 5333
    CFLAGS_OPTIM="${CFLAGS_OPTIM} -ffast-math"
fi

5334
echo $ac_n "checking if \$CC accepts -funroll-loops""... $ac_c" 1>&6
5335
echo "configure:5336: checking if \$CC accepts -funroll-loops" >&5
5336 5337
if eval "test \"`echo '$''{'ac_cv_c_unroll_loops'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
5338 5339
else
  CFLAGS="${save_CFLAGS} -funroll-loops"
5340
     cat > conftest.$ac_ext <<EOF
5341
#line 5342 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5342 5343
#include "confdefs.h"

5344
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5345

5346 5347
; return 0; }
EOF
5348
if { (eval echo configure:5349: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5349
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5350 5351
  ac_cv_c_unroll_loops=yes
else
5352 5353 5354 5355
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_unroll_loops=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5356
fi
5357
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5358
fi
5359 5360

echo "$ac_t""$ac_cv_c_unroll_loops" 1>&6
5361
if test "x${ac_cv_c_unroll_loops}" != "xno"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
5362 5363 5364
    CFLAGS_OPTIM="${CFLAGS_OPTIM} -funroll-loops"
fi

5365
echo $ac_n "checking if \$CC accepts -fomit-frame-pointer""... $ac_c" 1>&6
5366
echo "configure:5367: checking if \$CC accepts -fomit-frame-pointer" >&5
5367 5368
if eval "test \"`echo '$''{'ac_cv_c_omit_frame_pointer'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
5369 5370
else
  CFLAGS="${save_CFLAGS} -fomit-frame-pointer"
5371
     cat > conftest.$ac_ext <<EOF
5372
#line 5373 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5373 5374
#include "confdefs.h"

5375
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5376

5377 5378
; return 0; }
EOF
5379
if { (eval echo configure:5380: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5380
  rm -rf conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5381 5382
  ac_cv_c_omit_frame_pointer=yes
else
5383 5384 5385 5386
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_omit_frame_pointer=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5387
fi
5388
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
5389
fi
5390 5391

echo "$ac_t""$ac_cv_c_omit_frame_pointer" 1>&6
5392
if test "x${ac_cv_c_omit_frame_pointer}" != "xno"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
5393
    CFLAGS_OPTIM_NODEBUG="${CFLAGS_OPTIM_NODEBUG} -fomit-frame-pointer"
Sam Hocevar's avatar
Sam Hocevar committed
5394 5395
    # this plugin does not compile without -fomit-frame-pointer, damn gcc!
    chroma_i420_yuy2_mmx_CFLAGS="${chroma_i420_yuy2_mmx_CFLAGS} -fomit-frame-pointer"
Sam Hocevar's avatar
 
Sam Hocevar committed
5396 5397
fi

5398
echo $ac_n "checking if \$CC accepts -bundle -undefined error -lcc_dynamic""... $ac_c" 1>&6
5399
echo "configure:5400: checking if \$CC accepts -bundle -undefined error -lcc_dynamic" >&5
5400 5401
if eval "test \"`echo '$''{'ac_cv_ld_darwin'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5402
else
Christophe Massiot's avatar
Christophe Massiot committed
5403
  CFLAGS="${save_CFLAGS} -bundle -undefined error -lcc_dynamic"
5404
     cat > conftest.$ac_ext <<EOF
5405
#line 5406 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5406 5407
#include "confdefs.h"

5408
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5409

5410 5411
; return 0; }
EOF
5412
if { (eval echo configure:5413: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5413
  rm -rf conftest*
5414
  ac_cv_ld_darwin=yes
Sam Hocevar's avatar
 
Sam Hocevar committed
5415
else
5416 5417 5418 5419
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_ld_darwin=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5420
fi
5421
rm -f conftest*
5422
fi
5423 5424

echo "$ac_t""$ac_cv_ld_darwin" 1>&6
5425
if test "x${ac_cv_ld_darwin}" != "xno"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
5426
    plugins_LDFLAGS="${plugins_LDFLAGS} -bundle -undefined error -lcc_dynamic"
5427
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5428

5429
echo $ac_n "checking if \$CC accepts -shared""... $ac_c" 1>&6
5430
echo "configure:5431: checking if \$CC accepts -shared" >&5
5431 5432
if eval "test \"`echo '$''{'ac_cv_ld_plugins'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5433 5434
else
  CFLAGS="${save_CFLAGS} -shared"
5435
     cat > conftest.$ac_ext <<EOF
5436
#line 5437 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5437 5438
#include "confdefs.h"

5439
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5440

5441 5442
; return 0; }
EOF
5443
if { (eval echo configure:5444: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5444
  rm -rf conftest*
5445
  ac_cv_ld_plugins=yes
Sam Hocevar's avatar
 
Sam Hocevar committed
5446
else
5447 5448 5449 5450
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_ld_plugins=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5451
fi
5452
rm -f conftest*
5453
fi
5454 5455

echo "$ac_t""$ac_cv_ld_plugins" 1>&6
5456
if test "x${ac_cv_ld_plugins}" != "xno"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
5457
    plugins_LDFLAGS="${plugins_LDFLAGS} -shared"
5458
fi
5459 5460
        
echo $ac_n "checking for variadic cpp macros""... $ac_c" 1>&6
5461
echo "configure:5462: checking for variadic cpp macros" >&5
5462 5463
if eval "test \"`echo '$''{'ac_cv_cpp_variadic_macros'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5464 5465
else
  CFLAGS="${save_CFLAGS}"
5466
     cat > conftest.$ac_ext <<EOF
5467
#line 5468 "configure"
5468 5469 5470
#include "confdefs.h"
#include <stdio.h>
          #define a(b,c...) printf(b,##c)
5471
int main() {
5472
a("foo");a("%s","bar");a("%s%s","baz","quux");
5473 5474
; return 0; }
EOF
5475
if { (eval echo configure:5476: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5476
  rm -rf conftest*
5477 5478
  ac_cv_cpp_variadic_macros=yes
else
5479 5480 5481 5482
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_cpp_variadic_macros=no
5483
fi
5484
rm -f conftest*
5485
fi
5486

5487
echo "$ac_t""$ac_cv_cpp_variadic_macros" 1>&6
5488
if test "x${ac_cv_cpp_variadic_macros}" != "xno"; then
5489
    cat >> confdefs.h <<\EOF
5490
#define HAVE_VARIADIC_MACROS 1
5491
EOF
5492 5493 5494

fi

5495
echo $ac_n "checking __attribute__ ((aligned ())) support""... $ac_c" 1>&6
5496
echo "configure:5497: checking __attribute__ ((aligned ())) support" >&5
5497 5498
if eval "test \"`echo '$''{'ac_cv_c_attribute_aligned'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5499 5500
else
  ac_cv_c_attribute_aligned=0
Sam Hocevar's avatar
 
Sam Hocevar committed
5501
        CFLAGS="${save_CFLAGS} -Werror"
5502
    for ac_cv_c_attr_align_try in 2 4 8 16 32 64; do
5503
        cat > conftest.$ac_ext <<EOF
5504
#line 5505 "configure"
5505 5506
#include "confdefs.h"

5507
int main() {
5508
static char c __attribute__ ((aligned(${ac_cv_c_attr_align_try}))) = 0; return c;
5509 5510
; return 0; }
EOF
5511
if { (eval echo configure:5512: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5512
  rm -rf conftest*
5513
  ac_cv_c_attribute_aligned="${ac_cv_c_attr_align_try}"
5514
else
5515 5516
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
5517
fi
5518
rm -f conftest*
5519
    done
5520
        CFLAGS="${save_CFLAGS}"
5521
fi
5522

5523
echo "$ac_t""$ac_cv_c_attribute_aligned" 1>&6
5524
if test "x${ac_cv_c_attribute_aligned}" != "x0"; then
5525
    cat >> confdefs.h <<EOF
5526
#define ATTRIBUTE_ALIGNED_MAX ${ac_cv_c_attribute_aligned}
5527
EOF
5528 5529 5530

fi

5531
case "x${target_cpu}" in
Sam Hocevar's avatar
 
Sam Hocevar committed
5532 5533 5534 5535
  x)
    ARCH=unknown
    ;;
  *)
Sam Hocevar's avatar
 
Sam Hocevar committed
5536
    ARCH="${target_cpu}"
Sam Hocevar's avatar
 
Sam Hocevar committed
5537 5538
    ;;
esac
Sam Hocevar's avatar
 
Sam Hocevar committed
5539

Sam Hocevar's avatar
Sam Hocevar committed
5540 5541
BUILTINS="${BUILTINS} idct idctclassic motion imdct downmix mpeg_adec ac3_adec mpeg_vdec"
PLUGINS="${PLUGINS} dummy null rc logger mpeg_es mpeg_audio mpeg_ps mpeg_ts file udp http ipv4 memcpy lpcm_adec ac3_spdif spudec filter_deinterlace filter_invert filter_wall filter_transform filter_distort filter_clone filter_crop fx_scope chroma_i420_rgb chroma_i420_yuy2 chroma_i422_yuy2 chroma_i420_ymga"
Sam Hocevar's avatar
 
Sam Hocevar committed
5542

Sam Hocevar's avatar
 
Sam Hocevar committed
5543
MMX_MODULES="memcpymmx idctmmx motionmmx chroma_i420_rgb_mmx chroma_i420_yuy2_mmx chroma_i422_yuy2_mmx chroma_i420_ymga_mmx"
Sam Hocevar's avatar
 
Sam Hocevar committed
5544 5545
MMXEXT_MODULES="memcpymmxext idctmmxext motionmmxext"
THREEDNOW_MODULES="memcpy3dn imdct3dn downmix3dn"
Gildas Bazin's avatar
 
Gildas Bazin committed
5546
SSE_MODULES="imdctsse downmixsse"
5547
ALTIVEC_MODULES="idctaltivec motionaltivec memcpyaltivec"
Sam Hocevar's avatar
 
Sam Hocevar committed
5548

5549
echo $ac_n "checking if \$CC groks MMX inline assembly""... $ac_c" 1>&6
5550
echo "configure:5551: checking if \$CC groks MMX inline assembly" >&5
5551 5552
if eval "test \"`echo '$''{'ac_cv_mmx_inline'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5553
else
Sam Hocevar's avatar
Sam Hocevar committed
5554 5555
  CFLAGS="${save_CFLAGS}"
     cat > conftest.$ac_ext <<EOF
5556
#line 5557 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5557 5558
#include "confdefs.h"

5559
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5560
void *p;asm volatile("packuswb %%mm1,%%mm2"::"r"(p));
5561 5562
; return 0; }
EOF
5563
if { (eval echo configure:5564: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5564
  rm -rf conftest*
5565
  ac_cv_mmx_inline=yes
Sam Hocevar's avatar
 
Sam Hocevar committed
5566
else
5567 5568 5569 5570
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_mmx_inline=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5571
fi
5572
rm -f conftest*
5573
fi
5574 5575

echo "$ac_t""$ac_cv_mmx_inline" 1>&6
5576
if test "x${ac_cv_mmx_inline}" != "xno"; then
5577 5578
  ACCEL_MODULES="${ACCEL_MODULES} ${MMX_MODULES}"
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5579

5580
echo $ac_n "checking if \$CC groks MMX EXT inline assembly""... $ac_c" 1>&6
5581
echo "configure:5582: checking if \$CC groks MMX EXT inline assembly" >&5
5582 5583
if eval "test \"`echo '$''{'ac_cv_mmxext_inline'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5584
else
Sam Hocevar's avatar
Sam Hocevar committed
5585 5586
  CFLAGS="${save_CFLAGS}"
     cat > conftest.$ac_ext <<EOF
5587
#line 5588 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5588 5589
#include "confdefs.h"

5590
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5591
void *p;asm volatile("maskmovq %%mm1,%%mm2"::"r"(p));
5592 5593
; return 0; }
EOF
5594
if { (eval echo configure:5595: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5595
  rm -rf conftest*
5596
  ac_cv_mmxext_inline=yes
Sam Hocevar's avatar
 
Sam Hocevar committed
5597
else
5598 5599 5600 5601
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_mmxext_inline=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5602
fi
5603
rm -f conftest*
5604
fi
5605 5606

echo "$ac_t""$ac_cv_mmxext_inline" 1>&6
5607
if test "x${ac_cv_mmxext_inline}" != "xno"; then
5608 5609
  ACCEL_MODULES="${ACCEL_MODULES} ${MMXEXT_MODULES}"
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5610

5611
echo $ac_n "checking if \$CC groks 3D Now! inline assembly""... $ac_c" 1>&6
5612
echo "configure:5613: checking if \$CC groks 3D Now! inline assembly" >&5
5613 5614
if eval "test \"`echo '$''{'ac_cv_3dnow_inline'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5615
else
Sam Hocevar's avatar
Sam Hocevar committed
5616 5617
  CFLAGS="${save_CFLAGS}"
     cat > conftest.$ac_ext <<EOF
5618
#line 5619 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5619 5620
#include "confdefs.h"

5621
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5622
void *p;asm volatile("pfadd %%mm1,%%mm2"::"r"(p));
5623 5624
; return 0; }
EOF
5625
if { (eval echo configure:5626: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5626
  rm -rf conftest*
5627
  ac_cv_3dnow_inline=yes
Sam Hocevar's avatar
 
Sam Hocevar committed
5628
else
5629 5630 5631 5632
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_3dnow_inline=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5633
fi
5634
rm -f conftest*
5635
fi
5636

5637
echo "$ac_t""$ac_cv_3dnow_inline" 1>&6
5638
if test "x${ac_cv_3dnow_inline}" != "xno"; then
5639
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
5640
#define CAN_COMPILE_3DNOW 1
5641
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
5642

5643 5644
  ACCEL_MODULES="${ACCEL_MODULES} ${THREEDNOW_MODULES}"
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5645

5646
echo $ac_n "checking if \$CC groks SSE inline assembly""... $ac_c" 1>&6
5647
echo "configure:5648: checking if \$CC groks SSE inline assembly" >&5
5648 5649
if eval "test \"`echo '$''{'ac_cv_sse_inline'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5650
else
Sam Hocevar's avatar
Sam Hocevar committed
5651 5652
  CFLAGS="${save_CFLAGS}"
     cat > conftest.$ac_ext <<EOF
5653
#line 5654 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
5654 5655
#include "confdefs.h"

5656
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5657
void *p;asm volatile("xorps %%xmm1,%%xmm2"::"r"(p));
5658 5659
; return 0; }
EOF
5660
if { (eval echo configure:5661: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5661
  rm -rf conftest*
5662
  ac_cv_sse_inline=yes
Sam Hocevar's avatar
 
Sam Hocevar committed
5663
else
5664 5665 5666 5667
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_sse_inline=no
Sam Hocevar's avatar
 
Sam Hocevar committed
5668
fi
5669
rm -f conftest*
5670
fi
5671

5672
echo "$ac_t""$ac_cv_sse_inline" 1>&6
5673
if test "x${ac_cv_sse_inline}" != "xno" -a "x${SYS}" != "xmingw32"; then
5674
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
5675
#define CAN_COMPILE_SSE 1
5676
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
5677

5678 5679 5680
  ACCEL_MODULES="${ACCEL_MODULES} ${SSE_MODULES}"
fi

Sam Hocevar's avatar
Sam Hocevar committed
5681
# don't try to grok AltiVec with native mingw32 it doesn't work right now
Gildas Bazin's avatar
 
Gildas Bazin committed
5682
# we should be able to remove this test with future versions of mingw32
5683
if test "x${SYS}" != "xmingw32"; then
Sam Hocevar's avatar
Sam Hocevar committed
5684
echo $ac_n "checking if \$CC groks AltiVec inline assembly""... $ac_c" 1>&6
5685
echo "configure:5686: checking if \$CC groks AltiVec inline assembly" >&5
5686 5687
if eval "test \"`echo '$''{'ac_cv_altivec_inline'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5688
else
Sam Hocevar's avatar
Sam Hocevar committed
5689 5690
  CFLAGS="${save_CFLAGS}"
     cat > conftest.$ac_ext <<EOF
5691
#line 5692 "configure"
5692 5693
#include "confdefs.h"

5694
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5695
asm volatile("vperm 0,1,2,3");
5696 5697
; return 0; }
EOF
5698
if { (eval echo configure:5699: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5699
  rm -rf conftest*
5700
  ac_cv_altivec_inline=yes
5701
else
5702 5703 5704
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
5705
  CFLAGS="${save_CFLAGS} -Wa,-m7400"
5706
          cat > conftest.$ac_ext <<EOF
5707
#line 5708 "configure"
5708 5709
#include "confdefs.h"

5710
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5711
asm volatile("vperm 0,1,2,3");
5712 5713
; return 0; }
EOF
5714
if { (eval echo configure:5715: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5715
  rm -rf conftest*
5716
  ac_cv_altivec_inline="-Wa,-m7400"
5717
else
5718 5719 5720 5721
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_altivec_inline=no
5722
fi
5723 5724
rm -f conftest*
         
5725
fi
5726
rm -f conftest*
5727
fi
5728

5729
echo "$ac_t""$ac_cv_altivec_inline" 1>&6
5730
if test "x${ac_cv_altivec_inline}" != "xno"; then
5731
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
5732
#define CAN_COMPILE_ALTIVEC 1
5733
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
5734

5735 5736 5737 5738 5739
  if test "x${ac_cv_altivec_inline}" != "xyes"; then
    idctaltivec_CFLAGS="${idctaltivec_CFLAGS} ${ac_cv_altivec_inline}"
    motionaltivec_CFLAGS="${motionaltivec_CFLAGS} ${ac_cv_altivec_inline}"
    memcpyaltivec_CFLAGS="${memcpyaltivec_CFLAGS} ${ac_cv_altivec_inline}"
    vlc_CFLAGS="${vlc_CFLAGS} ${ac_cv_altivec_inline}"
5740
  fi
5741 5742
  ACCEL_MODULES="${ACCEL_MODULES} ${ALTIVEC_MODULES}"
fi
5743

Sam Hocevar's avatar
Sam Hocevar committed
5744
echo $ac_n "checking if \$CC groks AltiVec C extensions""... $ac_c" 1>&6
5745
echo "configure:5746: checking if \$CC groks AltiVec C extensions" >&5
5746 5747
if eval "test \"`echo '$''{'ac_cv_c_altivec'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5748
else
5749
  CFLAGS="${save_CFLAGS} -faltivec"
5750
     # Darwin test
5751
     cat > conftest.$ac_ext <<EOF
5752
#line 5753 "configure"
5753
#include "confdefs.h"
5754

5755
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5756
vec_mtvscr((vector unsigned int)(0));
5757 5758
; return 0; }
EOF
5759
if { (eval echo configure:5760: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5760
  rm -rf conftest*
5761 5762
  ac_cv_c_altivec=-faltivec
else
5763 5764 5765 5766
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  
5767
        # Linux/PPC test
5768
        CFLAGS="${save_CFLAGS} ${idctaltivec_CFLAGS} -fvec"
5769
        cat > conftest.$ac_ext <<EOF
5770
#line 5771 "configure"
5771
#include "confdefs.h"
5772

5773
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
5774
vec_mtvscr((vector unsigned int)(0));
5775 5776
; return 0; }
EOF
5777
if { (eval echo configure:5778: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
5778
  rm -rf conftest*
5779
  ac_cv_c_altivec="-fvec"
5780
else
5781 5782 5783 5784
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_c_altivec=no
5785
fi
5786 5787
rm -f conftest*
        
5788
fi
5789
rm -f conftest*
5790
     CFLAGS="${save_CFLAGS}"
5791 5792
fi

5793
echo "$ac_t""$ac_cv_c_altivec" 1>&6
5794
if test "x${ac_cv_c_altivec}" != "xno"; then
5795
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
5796
#define CAN_COMPILE_C_ALTIVEC 1
5797
EOF
5798

5799 5800 5801 5802
  idctaltivec_CFLAGS="${idctaltivec_CFLAGS} ${ac_cv_c_altivec}"
  motionaltivec_CFLAGS="${motionaltivec_CFLAGS} ${ac_cv_c_altivec}"
  memcpyaltivec_CFLAGS="${memcpyaltivec_CFLAGS} ${ac_cv_c_altivec}"
  vlc_CFLAGS="${vlc_CFLAGS} ${ac_cv_c_altivec}"
5803
  ACCEL_MODULES="${ACCEL_MODULES} ${ALTIVEC_MODULES}"
5804 5805
fi

5806
echo $ac_n "checking if linker needs -framework vecLib""... $ac_c" 1>&6
5807
echo "configure:5808: checking if linker needs -framework vecLib" >&5
5808 5809
if eval "test \"`echo '$''{'ac_cv_ld_altivec'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5810
else
5811
  LDFLAGS="${vlc_LDFLAGS} -framework vecLib"
5812
     cat > conftest.$ac_ext <<EOF
5813
#line 5814 "configure"
5814 5815
#include "confdefs.h"

5816
int main() {
5817

5818 5819
; return 0; }
EOF
5820
if { (eval echo configure:5821: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5821
  rm -rf conftest*
5822 5823
  ac_cv_ld_altivec=yes
else
5824 5825 5826 5827
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  ac_cv_ld_altivec=no
5828
fi
5829
rm -f conftest*
5830
     LDFLAGS="${save_LDFLAGS}"
5831
    
5832
fi
5833 5834

echo "$ac_t""$ac_cv_ld_altivec" 1>&6
5835
if test "x${ac_cv_ld_altivec}" != "xno"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
5836 5837 5838 5839
  idctaltivec_LDFLAGS="${idctaltivec_LDFLAGS} -framework vecLib"
  motionaltivec_LDFLAGS="${motionaltivec_LDFLAGS} -framework vecLib"
  memcpyaltivec_LDFLAGS="${memcpyaltivec_LDFLAGS} -framework vecLib"
  vlc_LDFLAGS="${vlc_LDFLAGS} -framework vecLib"
5840
fi
Gildas Bazin's avatar
 
Gildas Bazin committed
5841
fi # end if mingw32
Sam Hocevar's avatar
 
Sam Hocevar committed
5842

5843

Sam Hocevar's avatar
 
Sam Hocevar committed
5844 5845 5846
# Check whether --with- or --without- was given.
if test "${with_+set}" = set; then
  withval="$with_"
5847 5848
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5849

Sam Hocevar's avatar
 
Sam Hocevar committed
5850 5851 5852
# Check whether --with- or --without- was given.
if test "${with_+set}" = set; then
  withval="$with_"
5853 5854
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5855

Sam Hocevar's avatar
 
Sam Hocevar committed
5856 5857 5858 5859

# Check whether --with-tuning or --without-tuning was given.
if test "${with_tuning+set}" = set; then
  withval="$with_tuning"
5860 5861
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5862

5863 5864
if test "x${with_tuning}" != "x"; then
    TUNING="${with_tuning}"
Sam Hocevar's avatar
 
Sam Hocevar committed
5865
else
5866
    if test "x${target_cpu}" = "xi686" -o "x${target_cpu}" = "xi586" -o "x${target_cpu}" = "xi486" -o "x${target_cpu}" = "xi386"; then TUNING="pentiumpro"
Sam Hocevar's avatar
 
Sam Hocevar committed
5867
    else
5868
        if test "x${target_cpu}" = "xpowerpc"; then TUNING="750"; fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5869 5870 5871
    fi
fi

5872
if test "x${target_cpu}" = "xi686" -o "x${target_cpu}" = "xi586" -o "x${target_cpu}" = "xx86" -o "x${target_cpu}" = "xi386"
Sam Hocevar's avatar
 
Sam Hocevar committed
5873 5874
then
    ARCH="${ARCH} mmx"
Sam Hocevar's avatar
Sam Hocevar committed
5875
    PLUGINS="${PLUGINS} ${ACCEL_MODULES}"
Sam Hocevar's avatar
 
Sam Hocevar committed
5876 5877 5878 5879 5880
fi

# Check whether --enable-optimizations or --disable-optimizations was given.
if test "${enable_optimizations+set}" = set; then
  enableval="$enable_optimizations"
5881
   if test "x${enable_optimizations}" = "xno"; then OPTIMS=0; fi 
Sam Hocevar's avatar
 
Sam Hocevar committed
5882
else
5883 5884 5885
   OPTIMS=1 
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
5886 5887 5888 5889

# Check whether --enable-altivec or --disable-altivec was given.
if test "${enable_altivec+set}" = set; then
  enableval="$enable_altivec"
5890
   if test "x${enable_altivec}" = "xyes"; then ARCH="${ARCH} altivec";
5891
    BUILTINS="${BUILTINS} ${ACCEL_MODULES}"; fi 
Sam Hocevar's avatar
 
Sam Hocevar committed
5892
else
5893
   if test "x${target_cpu}" = "xpowerpc"; then ARCH="${ARCH} altivec";
5894 5895 5896
    BUILTINS="${BUILTINS} ${ACCEL_MODULES}"; fi 
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
5897 5898 5899 5900 5901

DEBUG=0
# Check whether --enable-debug or --disable-debug was given.
if test "${enable_debug+set}" = set; then
  enableval="$enable_debug"
5902
   if test "x${enable_debug}" = "xyes"; then DEBUG=1; fi 
5903 5904
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
5905

Sam Hocevar's avatar
 
Sam Hocevar committed
5906
RELEASE=0
Sam Hocevar's avatar
 
Sam Hocevar committed
5907 5908 5909
# Check whether --enable-release or --disable-release was given.
if test "${enable_release+set}" = set; then
  enableval="$enable_release"
5910
   if test "x${enable_release}" = "xyes"; then RELEASE=1; fi 
Sam Hocevar's avatar
 
Sam Hocevar committed
5911
else
5912 5913
   VERSION="${VERSION}_`date +%Y-%m-%d`" 
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5914 5915 5916 5917 5918 5919



# Check whether --with- or --without- was given.
if test "${with_+set}" = set; then
  withval="$with_"
5920 5921
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5922 5923 5924 5925 5926


# Check whether --enable-dvd or --disable-dvd was given.
if test "${enable_dvd+set}" = set; then
  enableval="$enable_dvd"
5927 5928
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5929

5930
if test "x${enable_dvd}" != "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
5931
then
5932
  # Check whether --with-dvdcss or --without-dvdcss was given.
Sam Hocevar's avatar
 
Sam Hocevar committed
5933 5934
if test "${with_dvdcss+set}" = set; then
  withval="$with_dvdcss"
5935 5936
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5937

5938
  # Check whether --with-dvdcss-tree or --without-dvdcss-tree was given.
Sam Hocevar's avatar
 
Sam Hocevar committed
5939 5940
if test "${with_dvdcss_tree+set}" = set; then
  withval="$with_dvdcss_tree"
5941 5942
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
5943

5944
  case "x${with_dvdcss}" in
Sam Hocevar's avatar
 
Sam Hocevar committed
5945
  x|xyes)
5946
    if test "x${with_dvdcss_tree}" = x
Sam Hocevar's avatar
 
Sam Hocevar committed
5947
    then
5948
      for ac_hdr in dvdcss/dvdcss.h
5949
do
5950 5951
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
5952
echo "configure:5953: checking for $ac_hdr" >&5
5953 5954
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
5955
else
5956
  cat > conftest.$ac_ext <<EOF
5957
#line 5958 "configure"
5958 5959 5960 5961
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
5962
{ (eval echo configure:5963: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
5963 5964 5965 5966 5967 5968 5969
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
5970
  cat conftest.$ac_ext >&5
5971 5972
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
5973
fi
5974
rm -f conftest*
5975
fi
5976 5977 5978 5979 5980 5981
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
5982
  PLUGINS="${PLUGINS} dvd"
5983
          dvd_LDFLAGS="${dvd_LDFLAGS} -ldvdcss" 
Sam Hocevar's avatar
 
Sam Hocevar committed
5984
else
5985 5986 5987
  echo "$ac_t""no" 1>&6
echo "configure: warning: libdvdcss is no longer provided with vlc; please get libdvdcss from http://www.videolan.org/libdvdcss/ and build it. Then either use --with-dvdcss=<path/where/libdvdcss/was/installed> for dynamic linking (recommended under Unix) or --with-dvdcss-tree=<path/where/libdvdcss/was/built> for static linking (recommended under BeOS, Windows, MacOS X). Alternatively you can use --disable-dvd to disable the DVD plugin." 1>&2
          { echo "configure: error: cannot find libdvdcss headers" 1>&2; exit 1; } 
Sam Hocevar's avatar
 
Sam Hocevar committed
5988 5989 5990
fi
done

Sam Hocevar's avatar
 
Sam Hocevar committed
5991
    else
5992
      echo $ac_n "checking for libdvdcss.a in ${with_dvdcss_tree}""... $ac_c" 1>&6
5993
echo "configure:5994: checking for libdvdcss.a in ${with_dvdcss_tree}" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
5994
      real_dvdcss_tree="`cd ${with_dvdcss_tree} 2>/dev/null && pwd`"
5995
      if test "x${real_dvdcss_tree}" = "x"
Sam Hocevar's avatar
 
Sam Hocevar committed
5996
      then
5997 5998
                echo "$ac_t""no" 1>&6
        { echo "configure: error: cannot cd to ${with_dvdcss_tree}" 1>&2; exit 1; }
Sam Hocevar's avatar
 
Sam Hocevar committed
5999 6000 6001
      fi
      if test -f "${real_dvdcss_tree}/src/.libs/libdvdcss.a"
      then
6002
                echo "$ac_t""${real_dvdcss_tree}/src/.libs/libdvdcss.a" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
6003
        BUILTINS="${BUILTINS} dvd"
Sam Hocevar's avatar
 
Sam Hocevar committed
6004 6005
        dvd_LDFLAGS="${dvd_LDFLAGS} ${real_dvdcss_tree}/src/.libs/libdvdcss.a"
        dvd_CFLAGS="${dvd_CFLAGS} -I${real_dvdcss_tree}/src"
Sam Hocevar's avatar
 
Sam Hocevar committed
6006
      else
6007 6008
                echo "$ac_t""no" 1>&6
        { echo "configure: error: cannot find ${real_dvdcss_tree}/src/.libs/libdvdcss.a, make sure you compiled libdvdcss in ${with_dvdcss_tree}" 1>&2; exit 1; }
Sam Hocevar's avatar
 
Sam Hocevar committed
6009 6010
      fi
    fi
Sam Hocevar's avatar
 
Sam Hocevar committed
6011 6012
  ;;
  xno)
Sam Hocevar's avatar
 
Sam Hocevar committed
6013
        PLUGINS="${PLUGINS} dvd"
Sam Hocevar's avatar
 
Sam Hocevar committed
6014 6015
    dvd_CFLAGS="${dvd_CFLAGS} -DGOD_DAMN_DMCA"
    dvd_LDFLAGS="${dvd_LDFLAGS} -ldl"
Sam Hocevar's avatar
 
Sam Hocevar committed
6016 6017
  ;;
  *)
6018
    echo $ac_n "checking for dvdcss headers in ${with_dvdcss}""... $ac_c" 1>&6
6019
echo "configure:6020: checking for dvdcss headers in ${with_dvdcss}" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
6020
    if test -f ${with_dvdcss}/include/dvdcss/dvdcss.h
Sam Hocevar's avatar
 
Sam Hocevar committed
6021
    then
6022
            echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
6023
      PLUGINS="${PLUGINS} dvd"
Sam Hocevar's avatar
 
Sam Hocevar committed
6024 6025
      dvd_LDFLAGS="${dvd_LDFLAGS} -L${with_dvdcss}/lib -ldvdcss"
      dvd_CFLAGS="${dvd_CFLAGS} -I${with_dvdcss}/include"
Sam Hocevar's avatar
 
Sam Hocevar committed
6026
    else
6027 6028
            echo "$ac_t""no" 1>&6
      { echo "configure: error: cannot find ${with_dvdcss}/include/dvdcss/dvdcss.h" 1>&2; exit 1; }
Sam Hocevar's avatar
 
Sam Hocevar committed
6029 6030 6031 6032 6033 6034 6035 6036
    fi
  ;;
  esac
fi

# Check whether --enable-dvdread or --disable-dvdread was given.
if test "${enable_dvdread+set}" = set; then
  enableval="$enable_dvdread"
6037 6038
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
6039

6040
if test "x${enable_dvdread}" != "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
6041
then
6042
  # Check whether --with-dvdread or --without-dvdread was given.
Sam Hocevar's avatar
 
Sam Hocevar committed
6043 6044
if test "${with_dvdread+set}" = set; then
  withval="$with_dvdread"
6045 6046
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
6047

6048
  if test "x${with_dvdread}" = "x"
Sam Hocevar's avatar
 
Sam Hocevar committed
6049 6050 6051 6052
  then
    test_LDFLAGS=""
    test_CFLAGS=""
  else
6053 6054
    test_LDFLAGS="-L${with_dvdread}/lib"
    test_CFLAGS="-I${with_dvdread}/include"
Sam Hocevar's avatar
 
Sam Hocevar committed
6055
  fi
6056
  CPPFLAGS="${save_CPPFLAGS} ${test_CFLAGS}"
6057
  for ac_hdr in dvdread/dvd_reader.h
6058
do
6059 6060
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6061
echo "configure:6062: checking for $ac_hdr" >&5
6062 6063
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
6064
else
6065
  cat > conftest.$ac_ext <<EOF
6066
#line 6067 "configure"
6067 6068 6069 6070
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6071
{ (eval echo configure:6072: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6072 6073 6074 6075 6076 6077 6078
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
6079
  cat conftest.$ac_ext >&5
6080 6081
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
6082
fi
6083
rm -f conftest*
6084
fi
6085 6086 6087 6088 6089 6090 6091 6092
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
     cat > conftest.$ac_ext <<EOF
6093
#line 6094 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
6094 6095
#include "confdefs.h"
#include <dvdread/dvd_reader.h>
6096
int main() {
Sam Hocevar's avatar
 
Sam Hocevar committed
6097
void foo() { int i=DVD_VIDEO_LB_LEN; }
6098 6099
; return 0; }
EOF
6100
if { (eval echo configure:6101: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6101 6102
  rm -rf conftest*
  
Sam Hocevar's avatar
 
Sam Hocevar committed
6103 6104 6105
          PLUGINS="${PLUGINS} dvdread"
          dvdread_LDFLAGS="${dvdread_LDFLAGS} ${test_LDFLAGS} -ldvdread"
          dvdread_CFLAGS="${dvdread_CFLAGS} ${test_CFLAGS}"
6106
        
Sam Hocevar's avatar
 
Sam Hocevar committed
6107
else
6108 6109 6110 6111
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  
6112
          if test "x${enable_dvdread}" != "x"
Sam Hocevar's avatar
 
Sam Hocevar committed
6113
          then
6114
            { echo "configure: error: Cannot find DVD_VIDEO_LB_LEN in dvdread/dvd_reader.h, please install libdvdread version 0.9.2 or later" 1>&2; exit 1; }
Sam Hocevar's avatar
 
Sam Hocevar committed
6115
          fi
6116
        
Sam Hocevar's avatar
 
Sam Hocevar committed
6117
fi
6118 6119
rm -f conftest*
  
Sam Hocevar's avatar
 
Sam Hocevar committed
6120
else
6121
  echo "$ac_t""no" 1>&6
6122
if test "x${enable_dvdread}" != "x"
Sam Hocevar's avatar
 
Sam Hocevar committed
6123
    then
6124
      if test "x${with_dvdread}" != "x"
Sam Hocevar's avatar
 
Sam Hocevar committed
6125
      then
6126
        { echo "configure: error: Cannot find dvdread/dvd_reader.h in ${with_dvdread}/include" 1>&2; exit 1; }
Sam Hocevar's avatar
 
Sam Hocevar committed
6127
      else
6128
        { echo "configure: error: Cannot find dvdread/dvd_reader.h" 1>&2; exit 1; }
Sam Hocevar's avatar
 
Sam Hocevar committed
6129 6130
      fi
    fi
6131
  
6132 6133 6134
fi
done

6135
  CPPFLAGS="${save_CPPFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
6136 6137
fi

6138 6139 6140
# Check whether --enable-dvbpsi or --disable-dvbpsi was given.
if test "${enable_dvbpsi+set}" = set; then
  enableval="$enable_dvbpsi"
6141 6142
  :
fi
6143

6144
if test "x${enable_dvbpsi}" != "xno"
6145
then
6146
  # Check whether --with-dvbpsi or --without-dvbpsi was given.
6147 6148
if test "${with_dvbpsi+set}" = set; then
  withval="$with_dvbpsi"
6149 6150
  :
fi
6151

6152 6153 6154 6155 6156 6157
  # Check whether --with-dvbpsi or --without-dvbpsi was given.
if test "${with_dvbpsi+set}" = set; then
  withval="$with_dvbpsi"
  :
fi

6158
  case "x${with_dvbpsi}" in
6159
  x|xyes)
6160
    if test "x${with_dvbpsi_tree}" = "x"
6161
    then
Sam Hocevar's avatar
Sam Hocevar committed
6162
      for ac_hdr in dvbpsi/dr.h
6163 6164 6165
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6166
echo "configure:6167: checking for $ac_hdr" >&5
6167 6168 6169 6170
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  cat > conftest.$ac_ext <<EOF
6171
#line 6172 "configure"
6172
#include "confdefs.h"
6173
#include <$ac_hdr>
6174 6175
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6176
{ (eval echo configure:6177: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6177 6178 6179 6180 6181 6182 6183
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
6184
  cat conftest.$ac_ext >&5
6185 6186
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
6187
fi
6188
rm -f conftest*
6189
fi
6190 6191
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
6192 6193 6194 6195
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
Sam Hocevar's avatar
Sam Hocevar committed
6196
  PLUGINS="${PLUGINS} mpeg_ts_dvbpsi"
6197
          mpeg_ts_dvbpsi_LDFLAGS="${mpeg_ts_dvbpsi_LDFLAGS} -ldvbpsi" 
6198
else
6199
  echo "$ac_t""no" 1>&6
6200 6201
fi
done
6202

6203 6204
    else
      echo $ac_n "checking for libdvbpsi.a in ${with_dvbpsi_tree}""... $ac_c" 1>&6
6205
echo "configure:6206: checking for libdvbpsi.a in ${with_dvbpsi_tree}" >&5
6206
      real_dvbpsi_tree="`cd ${with_dvbpsi_tree} 2>/dev/null && pwd`"
6207
      if test "x${real_dvbpsi_tree}" = "x"
6208 6209 6210 6211 6212 6213 6214 6215 6216 6217 6218 6219 6220 6221 6222 6223 6224 6225 6226 6227
      then
                echo "$ac_t""no" 1>&6
        { echo "configure: error: cannot cd to ${with_dvbpsi_tree}" 1>&2; exit 1; }
      fi
      if test -f "${real_dvbpsi_tree}/src/.libs/libdvbpsi.a"
      then
                echo "$ac_t""${real_dvbpsi_tree}/src/.libs/libdvbpsi.a" 1>&6
        BUILTINS="${BUILTINS} mpeg_ts_dvbpsi"
        mpeg_ts_dvbpsi_LDFLAGS="${mpeg_ts_dvbpsi_LDFLAGS} ${real_dvbpsi_tree}/src/.libs/libdvbpsi.a"
        mpeg_ts_dvbpsi_CFLAGS="${mpeg_ts_dvbpsi_CFLAGS} -I${real_dvbpsi_tree}/src"
      else
                echo "$ac_t""no" 1>&6
        { echo "configure: error: cannot find ${real_dvbpsi_tree}/src/.libs/libdvbpsi.a, make sure you compiled libdvbpsi in ${with_dvbpsi_tree}" 1>&2; exit 1; }
      fi
    fi
  ;;
  xno)
      ;;
  *)
    echo $ac_n "checking for dvbpsi headers in ${with_dvbpsi}""... $ac_c" 1>&6
6228
echo "configure:6229: checking for dvbpsi headers in ${with_dvbpsi}" >&5
6229
    if test "x${with_dvbpsi}" = "x"
6230
    then
6231 6232 6233 6234 6235
      test_LDFLAGS=""
      test_CFLAGS=""
    else
      test_LDFLAGS="-L${with_dvbpsi}/lib"
      test_CFLAGS="-I${with_dvbpsi}/include"
6236
    fi
6237
    CPPFLAGS="${save_CPPFLAGS} ${test_CFLAGS}"
6238 6239
    ac_safe=`echo "dvbpsi/dr.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for dvbpsi/dr.h""... $ac_c" 1>&6
6240
echo "configure:6241: checking for dvbpsi/dr.h" >&5
6241 6242 6243 6244
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  cat > conftest.$ac_ext <<EOF
6245
#line 6246 "configure"
6246 6247 6248 6249
#include "confdefs.h"
#include <dvbpsi/dr.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6250
{ (eval echo configure:6251: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6251 6252 6253 6254 6255 6256 6257 6258 6259 6260 6261 6262 6263 6264 6265
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
fi
rm -f conftest*
fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
6266
  
6267 6268 6269 6270 6271 6272 6273
      PLUGINS="${PLUGINS} mpeg_ts_dvbpsi"
      mpeg_ts_dvbpsi_LDFLAGS="${mpeg_ts_dvbpsi_LDFLAGS} ${test_LDFLAGS} -ldvbpsi"
      mpeg_ts_dvbpsi_CFLAGS="${mpeg_ts_dvbpsi_CFLAGS} ${test_CFLAGS}"
      
else
  echo "$ac_t""no" 1>&6

6274
      if test "x${enable_dvbpsi}" != "x"
6275 6276 6277 6278
      then
        { echo "configure: error: Could not find libdvbpsi on your system: you may get it from www.videolan.org, you'll need at least version 0.1.1" 1>&2; exit 1; }
      fi
    
6279 6280
fi

6281
    CPPFLAGS="${save_CPPFLAGS}"
6282 6283
  ;;
  esac
6284
fi
6285

Sam Hocevar's avatar
 
Sam Hocevar committed
6286 6287 6288
# Check whether --enable-vcd or --disable-vcd was given.
if test "${enable_vcd+set}" = set; then
  enableval="$enable_vcd"
6289 6290
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
6291

Sam Hocevar's avatar
 
Sam Hocevar committed
6292

6293
if test "x${enable_vcd}" != "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
6294
then
6295
  cat > conftest.$ac_ext <<EOF
6296
#line 6297 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
6297 6298
#include "confdefs.h"
#include <linux/cdrom.h>
6299
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
6300
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
Sam Hocevar's avatar
 
Sam Hocevar committed
6301
  egrep "cdrom_msf0" >/dev/null 2>&1; then
6302 6303
  rm -rf conftest*
  
Sam Hocevar's avatar
 
Sam Hocevar committed
6304
    PLUGINS="${PLUGINS} vcd"
6305
  
Sam Hocevar's avatar
 
Sam Hocevar committed
6306 6307 6308
fi
rm -f conftest*

6309 6310
  
  cat > conftest.$ac_ext <<EOF
6311
#line 6312 "configure"
6312 6313
#include "confdefs.h"
#include <sys/cdio.h>
6314
EOF
6315 6316
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "ioc_toc_header " >/dev/null 2>&1; then
6317 6318
  rm -rf conftest*
  
6319
    PLUGINS="${PLUGINS} vcd"
6320
    cat >> confdefs.h <<\EOF
6321
#define HAVE_IOC_TOC_HEADER_IN_SYS_CDIO_H 1
6322
EOF
6323

6324
  
6325 6326 6327
fi
rm -f conftest*

6328
  
Sam Hocevar's avatar
 
Sam Hocevar committed
6329 6330 6331 6332
  if test "x${SYS}" = "xbsdi"
  then
    PLUGINS="${PLUGINS} vcd"
  fi
6333

Sam Hocevar's avatar
 
Sam Hocevar committed
6334 6335
  if test "x${SYS}" = "xdarwin"
  then
6336
    # No need to add vcd to PLUGINS, Darwin is already based on FreeBSD
6337
    vcd_LDFLAGS="${vcd_LDFLAGS} -framework IOKit -framework CoreFoundation" 
Sam Hocevar's avatar
 
Sam Hocevar committed
6338
  fi
6339 6340
fi

Johan Bilien's avatar
Johan Bilien committed
6341 6342 6343
# Check whether --enable-satellite or --disable-satellite was given.
if test "${enable_satellite+set}" = set; then
  enableval="$enable_satellite"
6344
   if test "x${enable_satellite}" = "xyes"
Johan Bilien's avatar
Johan Bilien committed
6345
    then
6346
      PLUGINS="${PLUGINS} satellite"
Johan Bilien's avatar
Johan Bilien committed
6347
    fi
6348 6349
fi

Johan Bilien's avatar
Johan Bilien committed
6350

6351
if test "x${SYS}" != "xnto" && test "x${SYS}" != "xmingw32"
6352
then
6353
  echo $ac_n "checking for inet_pton""... $ac_c" 1>&6
6354
echo "configure:6355: checking for inet_pton" >&5
6355 6356
if eval "test \"`echo '$''{'ac_cv_func_inet_pton'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
6357
else
6358
  cat > conftest.$ac_ext <<EOF
6359
#line 6360 "configure"
6360
#include "confdefs.h"
6361
/* System header to define __stub macros and hopefully few prototypes,
6362
    which can conflict with char inet_pton(); below.  */
6363 6364 6365
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
6366 6367 6368 6369
    builtin and then its argument prototype would still apply.  */
char inet_pton();

int main() {
6370 6371 6372 6373 6374 6375 6376

/* 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_inet_pton) || defined (__stub___inet_pton)
choke me
#else
6377
inet_pton();
6378 6379
#endif

6380 6381
; return 0; }
EOF
6382
if { (eval echo configure:6383: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6383 6384 6385 6386 6387 6388 6389 6390 6391 6392 6393 6394 6395
  rm -rf conftest*
  eval "ac_cv_func_inet_pton=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_func_inet_pton=no"
fi
rm -f conftest*
fi

if eval "test \"`echo '$ac_cv_func_'inet_pton`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Christophe Massiot's avatar
Christophe Massiot committed
6396
  PLUGINS="${PLUGINS} ipv6"
6397 6398
else
  echo "$ac_t""no" 1>&6
6399 6400

    echo $ac_n "checking for inet_pton in -lresolv""... $ac_c" 1>&6
6401
echo "configure:6402: checking for inet_pton in -lresolv" >&5
6402 6403 6404 6405 6406 6407 6408
ac_lib_var=`echo resolv'_'inet_pton | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  ac_save_LIBS="$LIBS"
LIBS="-lresolv  $LIBS"
cat > conftest.$ac_ext <<EOF
6409
#line 6410 "configure"
6410 6411 6412 6413 6414 6415 6416 6417 6418 6419
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char inet_pton();

int main() {
inet_pton()
; return 0; }
EOF
6420
if { (eval echo configure:6421: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6421 6422 6423 6424 6425 6426 6427 6428 6429 6430 6431 6432 6433 6434 6435 6436 6437 6438 6439 6440 6441
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  PLUGINS="${PLUGINS} ipv6"
       ipv6_LDFLAGS="${ipv6_LDFLAGS} -lresolv"
else
  echo "$ac_t""no" 1>&6
fi

  
6442
fi
6443

Gildas Bazin's avatar
 
Gildas Bazin committed
6444
fi
6445
if test "x${SYS}" = "xmingw32"
Gildas Bazin's avatar
 
Gildas Bazin committed
6446 6447
then
  echo $ac_n "checking for getaddrinfo in ws2tcpip.h""... $ac_c" 1>&6
6448
echo "configure:6449: checking for getaddrinfo in ws2tcpip.h" >&5
Gildas Bazin's avatar
 
Gildas Bazin committed
6449
  cat > conftest.$ac_ext <<EOF
6450
#line 6451 "configure"
Gildas Bazin's avatar
 
Gildas Bazin committed
6451 6452 6453 6454 6455 6456 6457 6458 6459 6460 6461 6462 6463 6464
#include "confdefs.h"
#include <ws2tcpip.h>
EOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "addrinfo" >/dev/null 2>&1; then
  rm -rf conftest*
  echo "$ac_t""yes" 1>&6
    PLUGINS="${PLUGINS} ipv6"
else
  rm -rf conftest*
  echo "$ac_t""no" 1>&6
fi
rm -f conftest*

6465
fi
6466

6467 6468 6469
# Check whether --enable-avi or --disable-avi was given.
if test "${enable_avi+set}" = set; then
  enableval="$enable_avi"
6470 6471
  :
fi
6472

6473
if test "x${enable_avi}" != "xno"
6474 6475 6476 6477
then
  PLUGINS="${PLUGINS} avi"
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
6478 6479 6480 6481

# Check whether --with- or --without- was given.
if test "${with_+set}" = set; then
  withval="$with_"
6482 6483
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
6484

Sam Hocevar's avatar
 
Sam Hocevar committed
6485

Sam Hocevar's avatar
 
Sam Hocevar committed
6486 6487 6488
# Check whether --enable-mad or --disable-mad was given.
if test "${enable_mad+set}" = set; then
  enableval="$enable_mad"
6489 6490
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
6491

6492
if test "x${enable_mad}" = "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
6493
then
6494
  # Check whether --with-mad or --without-mad was given.
Sam Hocevar's avatar
 
Sam Hocevar committed
6495 6496
if test "${with_mad+set}" = set; then
  withval="$with_mad"
6497 6498
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
6499

6500
  if test "x${with_mad}" != "xno" -a "x${with_mad}" != "x"
Gildas Bazin's avatar
 
Gildas Bazin committed
6501
  then
6502 6503
    mad_CFLAGS="${mad_CFLAGS} -I${with_mad}/include"
    mad_LDFLAGS="${mad_LDFLAGS} -L${with_mad}/lib"
Gildas Bazin's avatar
 
Gildas Bazin committed
6504 6505
  fi

6506
  # Check whether --with-mad-tree or --without-mad-tree was given.
Gildas Bazin's avatar
 
Gildas Bazin committed
6507 6508
if test "${with_mad_tree+set}" = set; then
  withval="$with_mad_tree"
6509 6510
  :
fi
Gildas Bazin's avatar
 
Gildas Bazin committed
6511

6512
  if test "x${with_mad_tree}" != "xno" -a "x${with_mad_tree}" != "x"
Gildas Bazin's avatar
 
Gildas Bazin committed
6513 6514
  then
    real_mad_tree="`cd ${with_mad_tree} 2>/dev/null && pwd`"
6515
    if test "x${real_mad_tree}" = "x"
Gildas Bazin's avatar
 
Gildas Bazin committed
6516
    then
6517 6518
            echo "$ac_t""no" 1>&6
      { echo "configure: error: ${with_mad_tree} directory doesn't exist" 1>&2; exit 1; }
Gildas Bazin's avatar
 
Gildas Bazin committed
6519
    fi
6520
        echo $ac_n "checking for mad.h in ${real_mad_tree}/libmad""... $ac_c" 1>&6
6521
echo "configure:6522: checking for mad.h in ${real_mad_tree}/libmad" >&5
Gildas Bazin's avatar
 
Gildas Bazin committed
6522 6523
    if test -f ${real_mad_tree}/libmad/mad.h
    then
6524
      echo "$ac_t""yes" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
6525 6526
      mad_CFLAGS="${mad_CFLAGS} -I${real_mad_tree}/libmad"
      mad_LDFLAGS="${mad_LDFLAGS} -L${real_mad_tree}/libmad/.libs"
6527
      LDFLAGS="${save_LDFLAGS} ${mad_LDFLAGS}"
6528
      echo $ac_n "checking for mad_bit_init in -lmad""... $ac_c" 1>&6
6529
echo "configure:6530: checking for mad_bit_init in -lmad" >&5
6530 6531 6532
ac_lib_var=`echo mad'_'mad_bit_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
6533
else
6534
  ac_save_LIBS="$LIBS"
Gildas Bazin's avatar
 
Gildas Bazin committed
6535
LIBS="-lmad  $LIBS"
6536
cat > conftest.$ac_ext <<EOF
6537
#line 6538 "configure"
Gildas Bazin's avatar
 
Gildas Bazin committed
6538 6539 6540
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
6541 6542 6543 6544 6545 6546 6547
    builtin and then its argument prototype would still apply.  */
char mad_bit_init();

int main() {
mad_bit_init()
; return 0; }
EOF
6548
if { (eval echo configure:6549: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6549 6550 6551 6552 6553 6554 6555 6556 6557 6558
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"
Gildas Bazin's avatar
 
Gildas Bazin committed
6559

6560 6561 6562 6563
fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  
Gildas Bazin's avatar
 
Gildas Bazin committed
6564 6565
        BUILTINS="${BUILTINS} mad"
        mad_LDFLAGS="${mad_LDFLAGS} -lmad"
6566
        
Gildas Bazin's avatar
 
Gildas Bazin committed
6567
else
6568 6569 6570
  echo "$ac_t""no" 1>&6
 { echo "configure: error: the specified tree hasn't been compiled " 1>&2; exit 1; }
      
Gildas Bazin's avatar
 
Gildas Bazin committed
6571 6572
fi

6573
      LDFLAGS="${save_LDFLAGS}"
Gildas Bazin's avatar
 
Gildas Bazin committed
6574
    else
6575 6576
      echo "$ac_t""no" 1>&6
      { echo "configure: error: the specified tree doesn't have mad.h" 1>&2; exit 1; }
Gildas Bazin's avatar
 
Gildas Bazin committed
6577 6578
    fi
  else
6579 6580
    CFLAGS="${save_CFLAGS} ${mad_CFLAGS}"
    LDFLAGS="${save_LDFLAGS} ${mad_LDFLAGS}"
6581
    for ac_hdr in mad.h
6582
do
6583 6584
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6585
echo "configure:6586: checking for $ac_hdr" >&5
6586 6587
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
6588
else
6589
  cat > conftest.$ac_ext <<EOF
6590
#line 6591 "configure"
6591 6592 6593 6594
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6595
{ (eval echo configure:6596: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6596 6597 6598 6599 6600 6601 6602
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
6603
  cat conftest.$ac_ext >&5
6604 6605
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
6606
fi
6607
rm -f conftest*
6608
fi
6609 6610 6611 6612 6613 6614 6615
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
6616
else
6617 6618
  echo "$ac_t""no" 1>&6
{ echo "configure: error: Cannot find development headers for libmad..." 1>&2; exit 1; } 
6619 6620 6621
fi
done

6622
    echo $ac_n "checking for mad_bit_init in -lmad""... $ac_c" 1>&6
6623
echo "configure:6624: checking for mad_bit_init in -lmad" >&5
6624 6625 6626
ac_lib_var=`echo mad'_'mad_bit_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
6627
else
6628
  ac_save_LIBS="$LIBS"
6629
LIBS="-lmad  $LIBS"
6630
cat > conftest.$ac_ext <<EOF
6631
#line 6632 "configure"
6632 6633 6634
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
6635 6636 6637 6638 6639 6640 6641
    builtin and then its argument prototype would still apply.  */
char mad_bit_init();

int main() {
mad_bit_init()
; return 0; }
EOF
6642
if { (eval echo configure:6643: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6643 6644 6645 6646 6647 6648 6649 6650 6651 6652 6653 6654 6655 6656
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
6657 6658 6659
  
      PLUGINS="${PLUGINS} mad"
      mad_LDFLAGS="${mad_LDFLAGS} -lmad" 
6660
else
6661 6662
  echo "$ac_t""no" 1>&6
 { echo "configure: error: Cannot find libmad library..." 1>&2; exit 1; } 
6663 6664
fi

6665 6666
    CFLAGS="${save_CFLAGS}"
    LDFLAGS="${save_LDFLAGS}"
Gildas Bazin's avatar
 
Gildas Bazin committed
6667
  fi
6668 6669
fi

6670 6671 6672
# Check whether --enable-ffmpeg or --disable-ffmpeg was given.
if test "${enable_ffmpeg+set}" = set; then
  enableval="$enable_ffmpeg"
6673 6674
  :
fi
6675

6676
if test "x${enable_ffmpeg}" = "xyes"
6677
then
6678 6679 6680 6681 6682 6683
  # Check whether --with-ffmpeg or --without-ffmpeg was given.
if test "${with_ffmpeg+set}" = set; then
  withval="$with_ffmpeg"
  :
fi

6684
  if test "x${with_ffmpeg}" != "xno" -a "x${with_ffmpeg}" != "x"
6685
  then
6686 6687
    ffmpeg_CFLAGS="${ffmpeg_CFLAGS} -I${with_ffmpeg}/include/libffmpeg"
    ffmpeg_LDFLAGS="${ffmpeg_LDFLAGS} -L${with_ffmpeg}/lib"
6688 6689
  fi

6690
  # Check whether --with-ffmpeg-tree or --without-ffmpeg-tree was given.
6691 6692
if test "${with_ffmpeg_tree+set}" = set; then
  withval="$with_ffmpeg_tree"
6693 6694
  :
fi
6695

6696
  if test "x${with_ffmpeg_tree}" != "x"
6697
  then
6698
    echo $ac_n "checking for libavcodec.a in ${with_ffmpeg_tree}""... $ac_c" 1>&6
6699
echo "configure:6700: checking for libavcodec.a in ${with_ffmpeg_tree}" >&5
6700
    real_ffmpeg_tree="`cd ${with_ffmpeg_tree} 2>/dev/null && pwd`"
6701
    if test "x${real_ffmpeg_tree}" = x
6702
    then
6703 6704
            echo "$ac_t""no" 1>&6
      { echo "configure: error: cannot cd to ${with_ffmpeg_tree}" 1>&2; exit 1; }
6705 6706 6707
    fi
    if test -f "${real_ffmpeg_tree}/libavcodec/libavcodec.a"
    then
6708
            echo "$ac_t""${real_ffmpeg_tree}/libavcodec/libavcodec.a" 1>&6
6709
      BUILTINS="${BUILTINS} ffmpeg"
6710
      ffmpeg_LDFLAGS="${ffmpeg_LDFLAGS} ${real_ffmpeg_tree}/libavcodec/libavcodec.a -lm"
6711 6712
      ffmpeg_CFLAGS="${ffmpeg_CFLAGS} -I${real_ffmpeg_tree}/libavcodec"
    else
6713 6714
            echo "$ac_t""no" 1>&6
      { echo "configure: error: cannot find ${real_ffmpeg_tree}/libavcodec/libavcodec.a, make sure you compiled libavcodec in ${with_ffmpeg_tree}" 1>&2; exit 1; }
6715
    fi
6716
  else
6717 6718
    CFLAGS="${save_CFLAGS} ${ffmpeg_CFLAGS}"
    LDFLAGS="${save_LDFLAGS} ${ffmpeg_LDFLAGS} -lm"
6719
    echo $ac_n "checking for avcodec_init in -lavcodec""... $ac_c" 1>&6
6720
echo "configure:6721: checking for avcodec_init in -lavcodec" >&5
6721 6722 6723 6724 6725 6726 6727
ac_lib_var=`echo avcodec'_'avcodec_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  ac_save_LIBS="$LIBS"
LIBS="-lavcodec  $LIBS"
cat > conftest.$ac_ext <<EOF
6728
#line 6729 "configure"
6729 6730 6731 6732 6733 6734 6735 6736 6737 6738
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char avcodec_init();

int main() {
avcodec_init()
; return 0; }
EOF
6739
if { (eval echo configure:6740: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6740 6741 6742 6743 6744 6745 6746 6747 6748 6749 6750 6751 6752 6753
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
6754 6755
  
      BUILTINS="${BUILTINS} ffmpeg"
6756
      ffmpeg_LDFLAGS="${ffmpeg_LDFLAGS} -lavcodec -lm" 
6757 6758 6759 6760 6761
else
  echo "$ac_t""no" 1>&6
 { echo "configure: error: Cannot find libavcodec library..." 1>&2; exit 1; } 
fi

6762 6763
    LDFLAGS="${save_LDFLAGS}"
    CFLAGS="${save_CFLAGS}"
6764 6765 6766
  fi
fi

6767 6768 6769 6770 6771 6772 6773 6774 6775 6776
# Check whether --enable-mp4 or --disable-mp4 was given.
if test "${enable_mp4+set}" = set; then
  enableval="$enable_mp4"
  :
fi

if test "x${enable_mp4}" = "xyes"
then
    ac_safe=`echo "zlib.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for zlib.h""... $ac_c" 1>&6
6777
echo "configure:6778: checking for zlib.h" >&5
6778 6779 6780 6781
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  cat > conftest.$ac_ext <<EOF
6782
#line 6783 "configure"
6783 6784 6785 6786
#include "confdefs.h"
#include <zlib.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6787
{ (eval echo configure:6788: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6788 6789 6790 6791 6792 6793 6794 6795 6796 6797 6798 6799 6800 6801 6802 6803
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
fi
rm -f conftest*
fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  echo $ac_n "checking for inflateEnd in -lz""... $ac_c" 1>&6
6804
echo "configure:6805: checking for inflateEnd in -lz" >&5
6805 6806 6807 6808 6809 6810 6811
ac_lib_var=`echo z'_'inflateEnd | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  ac_save_LIBS="$LIBS"
LIBS="-lz  $LIBS"
cat > conftest.$ac_ext <<EOF
6812
#line 6813 "configure"
6813 6814 6815 6816 6817 6818 6819 6820 6821 6822
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char inflateEnd();

int main() {
inflateEnd()
; return 0; }
EOF
6823
if { (eval echo configure:6824: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6824 6825 6826 6827 6828 6829 6830 6831 6832 6833 6834 6835 6836 6837 6838 6839 6840 6841 6842 6843 6844 6845 6846 6847 6848 6849 6850
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
   PLUGINS="${PLUGINS} mp4"
              mp4_LDFLAGS="${mp4_LDFLAGS} -lz" 
else
  echo "$ac_t""no" 1>&6
 { echo "configure: error: cannot find zlib library..." 1>&2; exit 1; } 
fi

else
  echo "$ac_t""no" 1>&6
  { echo "configure: error: cannot find zlib header..." 1>&2; exit 1; } 
fi

fi
6851

6852
if test "x${SYS}" = "xbeos"
Sam Hocevar's avatar
 
Sam Hocevar committed
6853
then
Sam Hocevar's avatar
 
Sam Hocevar committed
6854
    PLUGINS="${PLUGINS} beos"
Sam Hocevar's avatar
 
Sam Hocevar committed
6855
fi
6856

Sam Hocevar's avatar
 
Sam Hocevar committed
6857 6858 6859
# Check whether --enable-a52 or --disable-a52 was given.
if test "${enable_a52+set}" = set; then
  enableval="$enable_a52"
6860 6861
  :
fi
6862

6863
if test "x${enable_a52}" != "xno"
Gildas Bazin's avatar
 
Gildas Bazin committed
6864
then
6865
  # Check whether --with-a52-tree or --without-a52-tree was given.
Gildas Bazin's avatar
 
Gildas Bazin committed
6866 6867
if test "${with_a52_tree+set}" = set; then
  withval="$with_a52_tree"
6868 6869
  :
fi
Gildas Bazin's avatar
 
Gildas Bazin committed
6870

6871
  if test "x${with_a52_tree}" != "xno" -a "x${with_a52_tree}" != "x"
Sam Hocevar's avatar
 
Sam Hocevar committed
6872
  then
Gildas Bazin's avatar
 
Gildas Bazin committed
6873
    real_a52_tree="`cd ${with_a52_tree} 2>/dev/null && pwd`"
6874
    if test "x${real_a52_tree}" = "x"
Gildas Bazin's avatar
 
Gildas Bazin committed
6875
    then
6876 6877
            echo "$ac_t""no" 1>&6
      { echo "configure: error: ${with_a52_tree} directory doesn't exist" 1>&2; exit 1; }
Gildas Bazin's avatar
 
Gildas Bazin committed
6878
    fi
6879
        echo $ac_n "checking for a52.h in ${real_a52_tree}/include""... $ac_c" 1>&6
6880
echo "configure:6881: checking for a52.h in ${real_a52_tree}/include" >&5
Gildas Bazin's avatar
 
Gildas Bazin committed
6881 6882
    if test -f ${real_a52_tree}/include/a52.h
    then
6883
      echo "$ac_t""yes" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
6884 6885
      a52_CFLAGS="${a52_CFLAGS} -I${real_a52_tree}"
      a52_LDFLAGS="${a52_LDFLAGS} -L${real_a52_tree}/liba52/.libs"
6886
      LDFLAGS="${save_LDFLAGS} ${a52_LDFLAGS}"
6887
      echo $ac_n "checking for a52_free in -la52""... $ac_c" 1>&6
6888
echo "configure:6889: checking for a52_free in -la52" >&5
6889 6890 6891
ac_lib_var=`echo a52'_'a52_free | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
6892
else
6893
  ac_save_LIBS="$LIBS"
Gildas Bazin's avatar
 
Gildas Bazin committed
6894
LIBS="-la52 -lm $LIBS"
6895
cat > conftest.$ac_ext <<EOF
6896
#line 6897 "configure"
Gildas Bazin's avatar
 
Gildas Bazin committed
6897 6898 6899
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
6900 6901 6902 6903 6904 6905 6906
    builtin and then its argument prototype would still apply.  */
char a52_free();

int main() {
a52_free()
; return 0; }
EOF
6907
if { (eval echo configure:6908: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6908 6909 6910 6911 6912 6913 6914 6915 6916 6917
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"
Gildas Bazin's avatar
 
Gildas Bazin committed
6918

6919 6920 6921 6922
fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  
Gildas Bazin's avatar
 
Gildas Bazin committed
6923 6924 6925
        BUILTINS="${BUILTINS} a52"
        a52_LDFLAGS="${a52_LDFLAGS} -la52 -lm"
        a52_CFLAGS="${a52_CFLAGS} -DUSE_A52DEC_TREE"
6926
        
Gildas Bazin's avatar
 
Gildas Bazin committed
6927
else
6928
  echo "$ac_t""no" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
6929 6930 6931

        if test -f ${real_a52_tree}/liba52/.libs/liba52.a
        then
6932
          { echo "configure: error: make sure you have at least a52dec-0.7.3" 1>&2; exit 1; }
Gildas Bazin's avatar
 
Gildas Bazin committed
6933
        else
6934
          { echo "configure: error: the specified tree hasn't been compiled" 1>&2; exit 1; }
Gildas Bazin's avatar
 
Gildas Bazin committed
6935
        fi
6936
      
Gildas Bazin's avatar
 
Gildas Bazin committed
6937 6938
fi

6939
      LDFLAGS="${save_LDFLAGS}"
Gildas Bazin's avatar
 
Gildas Bazin committed
6940
    else
6941 6942
      echo "$ac_t""no" 1>&6
      { echo "configure: error: the specified tree doesn't have a52.h" 1>&2; exit 1; }
Gildas Bazin's avatar
 
Gildas Bazin committed
6943
    fi
6944
  else     for ac_hdr in a52dec/a52.h
6945
do
6946 6947
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
6948
echo "configure:6949: checking for $ac_hdr" >&5
6949 6950
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
6951
else
6952
  cat > conftest.$ac_ext <<EOF
6953
#line 6954 "configure"
6954 6955 6956 6957
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
6958
{ (eval echo configure:6959: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
6959 6960 6961 6962 6963 6964 6965
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
6966
  cat conftest.$ac_ext >&5
6967 6968
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
6969
fi
6970
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
6971
fi
6972 6973 6974 6975 6976 6977 6978 6979
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
      echo $ac_n "checking for a52_free in -la52""... $ac_c" 1>&6
6980
echo "configure:6981: checking for a52_free in -la52" >&5
6981 6982 6983 6984 6985
ac_lib_var=`echo a52'_'a52_free | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  ac_save_LIBS="$LIBS"
Gildas Bazin's avatar
 
Gildas Bazin committed
6986
LIBS="-la52 -lm $LIBS"
6987
cat > conftest.$ac_ext <<EOF
6988
#line 6989 "configure"
Gildas Bazin's avatar
 
Gildas Bazin committed
6989 6990 6991
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
6992 6993 6994 6995 6996 6997 6998
    builtin and then its argument prototype would still apply.  */
char a52_free();

int main() {
a52_free()
; return 0; }
EOF
6999
if { (eval echo configure:7000: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7000 7001 7002 7003 7004 7005 7006 7007 7008 7009
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"
Gildas Bazin's avatar
 
Gildas Bazin committed
7010

7011 7012 7013 7014
fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  
Gildas Bazin's avatar
 
Gildas Bazin committed
7015 7016 7017
        BUILTINS="${BUILTINS} a52"
        a52_LDFLAGS="${a52_LDFLAGS} -la52 -lm"
        a52_CFLAGS="${a52_CFLAGS}"
7018 7019 7020
      
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7021 7022
fi

7023 7024 7025
    
else
  echo "$ac_t""no" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
7026
fi
7027
done
Gildas Bazin's avatar
 
Gildas Bazin committed
7028 7029

  fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7030
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7031

7032 7033 7034 7035 7036 7037 7038 7039 7040 7041 7042
# Check whether --enable-cinepak or --disable-cinepak was given.
if test "${enable_cinepak+set}" = set; then
  enableval="$enable_cinepak"
  :
fi

if test "x${enable_cinepak}" != "xno"
then
  PLUGINS="${PLUGINS} cinepak"
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7043 7044 7045
# Check whether --enable-vorbis or --disable-vorbis was given.
if test "${enable_vorbis+set}" = set; then
  enableval="$enable_vorbis"
7046 7047
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7048

7049
if test "x${enable_vorbis}" != "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
7050
then
7051
  for ac_hdr in ogg/ogg.h
Sam Hocevar's avatar
 
Sam Hocevar committed
7052
do
7053 7054
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7055
echo "configure:7056: checking for $ac_hdr" >&5
7056 7057
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
7058
else
7059
  cat > conftest.$ac_ext <<EOF
7060
#line 7061 "configure"
7061 7062 7063 7064
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7065
{ (eval echo configure:7066: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7066 7067 7068 7069 7070 7071 7072
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
7073
  cat conftest.$ac_ext >&5
7074 7075
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
7076
fi
7077
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
7078
fi
7079 7080 7081 7082 7083 7084 7085
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
7086
        #PLUGINS="${PLUGINS} vorbis"
Sam Hocevar's avatar
 
Sam Hocevar committed
7087
    vorbis_LDFLAGS="${vorbis_LDFLAGS} -lvorbis"
7088 7089 7090
   
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7091 7092 7093 7094 7095
fi
done

fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7096

Sam Hocevar's avatar
 
Sam Hocevar committed
7097 7098 7099
# Check whether --with- or --without- was given.
if test "${with_+set}" = set; then
  withval="$with_"
7100 7101
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7102

Sam Hocevar's avatar
 
Sam Hocevar committed
7103

Sam Hocevar's avatar
 
Sam Hocevar committed
7104 7105 7106
# Check whether --enable-x11 or --disable-x11 was given.
if test "${enable_x11+set}" = set; then
  enableval="$enable_x11"
7107 7108
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7109

7110 7111 7112
if test "x${enable_x11}" != "xno" &&
  (test "x${SYS}" != "xmingw32" || test "x${enable_x11}" = "xyes"); then
  CPPFLAGS="${save_CPPFLAGS} -I${x_includes}"
7113
  for ac_hdr in X11/Xlib.h
7114
do
7115 7116
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7117
echo "configure:7118: checking for $ac_hdr" >&5
7118 7119
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7120
else
7121
  cat > conftest.$ac_ext <<EOF
7122
#line 7123 "configure"
7123 7124 7125 7126
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7127
{ (eval echo configure:7128: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7128 7129 7130 7131 7132 7133 7134
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
7135
  cat conftest.$ac_ext >&5
7136 7137
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
7138
fi
7139
rm -f conftest*
7140
fi
7141 7142 7143 7144 7145 7146 7147
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
Sam Hocevar's avatar
 
Sam Hocevar committed
7148
    PLUGINS="${PLUGINS} x11"
7149 7150
    x11_LDFLAGS="${x11_LDFLAGS} -L${x_libraries} -lX11 -lXext"
    x11_CFLAGS="${x11_CFLAGS} -I${x_includes}"
7151 7152 7153
  
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7154
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7155
done
Sam Hocevar's avatar
 
Sam Hocevar committed
7156

7157
  CPPFLAGS="${save_CPPFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
7158 7159
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7160 7161 7162
# Check whether --enable-xvideo or --disable-xvideo was given.
if test "${enable_xvideo+set}" = set; then
  enableval="$enable_xvideo"
7163 7164
  :
fi
7165

7166 7167 7168
if test "x${enable_xvideo}" != "xno" &&
  (test "x${SYS}" != "xmingw32" || test "x${enable_xvideo}" = "xyes"); then
  CPPFLAGS="${save_CPPFLAGS} -I${x_includes}"
7169
  for ac_hdr in X11/extensions/Xv.h
7170
do
7171 7172
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7173
echo "configure:7174: checking for $ac_hdr" >&5
7174 7175
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
7176
else
7177
  cat > conftest.$ac_ext <<EOF
7178
#line 7179 "configure"
7179 7180 7181 7182
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7183
{ (eval echo configure:7184: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7184 7185 7186 7187 7188 7189 7190
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
7191
  cat conftest.$ac_ext >&5
7192 7193
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
7194
fi
7195
rm -f conftest*
7196
fi
7197 7198 7199 7200 7201 7202 7203
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
7204
    CFLAGS="${save_CFLAGS} -L${x_libraries} -lX11 -lXext"
7205
    echo $ac_n "checking for XvPutImage in -lXv_pic""... $ac_c" 1>&6
7206
echo "configure:7207: checking for XvPutImage in -lXv_pic" >&5
7207
ac_lib_var=`echo Xv_pic'_'XvPutImage | sed 'y%./+-%__p_%'`
7208 7209
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
7210
else
7211
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
7212
LIBS="-lXv_pic  $LIBS"
7213
cat > conftest.$ac_ext <<EOF
7214
#line 7215 "configure"
Gildas Bazin's avatar
 
Gildas Bazin committed
7215
#include "confdefs.h"
Sam Hocevar's avatar
 
Sam Hocevar committed
7216 7217
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
7218
    builtin and then its argument prototype would still apply.  */
7219
char XvPutImage();
7220 7221

int main() {
7222
XvPutImage()
7223 7224
; return 0; }
EOF
7225
if { (eval echo configure:7226: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7226 7227 7228 7229 7230 7231 7232 7233 7234 7235 7236 7237 7238 7239
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7240 7241
  # We have Xv_pic, that's good, we can build an xvideo.so plugin !
      PLUGINS="${PLUGINS} xvideo"
7242 7243
      xvideo_LDFLAGS="${xvideo_LDFLAGS} -L${x_libraries} -lX11 -lXext -lXv_pic"
      xvideo_CFLAGS="${xvideo_CFLAGS} -I${x_includes}"
Sam Hocevar's avatar
 
Sam Hocevar committed
7244
else
7245
  echo "$ac_t""no" 1>&6
7246
echo $ac_n "checking for XvPutImage in -lXv""... $ac_c" 1>&6
7247
echo "configure:7248: checking for XvPutImage in -lXv" >&5
7248 7249 7250 7251 7252 7253 7254
ac_lib_var=`echo Xv'_'XvPutImage | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  ac_save_LIBS="$LIBS"
LIBS="-lXv  $LIBS"
cat > conftest.$ac_ext <<EOF
7255
#line 7256 "configure"
7256 7257 7258 7259 7260 7261 7262 7263 7264 7265
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
    builtin and then its argument prototype would still apply.  */
char XvPutImage();

int main() {
XvPutImage()
; return 0; }
EOF
7266
if { (eval echo configure:7267: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7267 7268 7269 7270 7271 7272 7273 7274 7275 7276 7277 7278 7279 7280 7281 7282
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  # We don't have Xv_pic, but we have Xv, let's make xvideo.a as builtin
        PLUGINS="${PLUGINS} xvideo"
7283 7284
        xvideo_LDFLAGS="${xvideo_LDFLAGS} -L${x_libraries} -lX11 -lXext -lXv"
        xvideo_CFLAGS="${xvideo_CFLAGS} -I${x_includes}"
7285 7286 7287 7288 7289 7290 7291
else
  echo "$ac_t""no" 1>&6
# Otherwise... well, do nothing.
      
fi

    
Sam Hocevar's avatar
 
Sam Hocevar committed
7292 7293
fi

7294
    CFLAGS="${save_CFLAGS}"
7295
  
7296
  CPPFLAGS="${save_CPPFLAGS}"
7297 7298
else
  echo "$ac_t""no" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
7299 7300 7301 7302 7303
fi
done

fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7304 7305 7306
# Check whether --enable-sdl or --disable-sdl was given.
if test "${enable_sdl+set}" = set; then
  enableval="$enable_sdl"
7307 7308
  :
fi
7309

7310
if test "x${enable_sdl}" != "xno"
7311
then
7312
  SDL_PATH="${PATH}"
7313
  # Check whether --with-sdl-config-path or --without-sdl-config-path was given.
7314 7315
if test "${with_sdl_config_path+set}" = set; then
  withval="$with_sdl_config_path"
7316
   if test "x${with_sdl_config_path}" != "xno"
7317
      then
7318
        SDL_PATH="${with_sdl_config_path}:${PATH}"
7319 7320 7321
      fi 
fi

7322 7323
  # Extract the first word of "sdl12-config", so it can be a program name with args.
set dummy sdl12-config; ac_word=$2
7324
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7325
echo "configure:7326: checking for $ac_word" >&5
7326 7327
if eval "test \"`echo '$''{'ac_cv_path_SDL12_CONFIG'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7328
else
7329 7330
  case "$SDL12_CONFIG" in
  /*)
7331
  ac_cv_path_SDL12_CONFIG="$SDL12_CONFIG" # Let the user override the test with a path.
7332
  ;;
7333 7334 7335
  ?:/*)			 
  ac_cv_path_SDL12_CONFIG="$SDL12_CONFIG" # Let the user override the test with a dos path.
  ;;
7336
  *)
7337
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
7338
  ac_dummy="${SDL_PATH}"
7339 7340 7341 7342 7343 7344 7345 7346
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_SDL12_CONFIG="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
7347
  test -z "$ac_cv_path_SDL12_CONFIG" && ac_cv_path_SDL12_CONFIG="no"
7348 7349 7350
  ;;
esac
fi
7351
SDL12_CONFIG="$ac_cv_path_SDL12_CONFIG"
7352
if test -n "$SDL12_CONFIG"; then
7353
  echo "$ac_t""$SDL12_CONFIG" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7354
else
7355
  echo "$ac_t""no" 1>&6
7356
fi
7357

7358
  SDL_CONFIG="${SDL12_CONFIG}"
7359
  SDL_HEADER="SDL12/SDL.h"
7360
  if test "x${SDL_CONFIG}" = "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
7361
  then
7362 7363
    # Extract the first word of "sdl11-config", so it can be a program name with args.
set dummy sdl11-config; ac_word=$2
7364
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7365
echo "configure:7366: checking for $ac_word" >&5
7366 7367
if eval "test \"`echo '$''{'ac_cv_path_SDL11_CONFIG'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
7368
else
7369 7370
  case "$SDL11_CONFIG" in
  /*)
Sam Hocevar's avatar
 
Sam Hocevar committed
7371
  ac_cv_path_SDL11_CONFIG="$SDL11_CONFIG" # Let the user override the test with a path.
7372
  ;;
7373 7374 7375
  ?:/*)			 
  ac_cv_path_SDL11_CONFIG="$SDL11_CONFIG" # Let the user override the test with a dos path.
  ;;
7376
  *)
7377
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
7378
  ac_dummy="${SDL_PATH}"
7379 7380 7381 7382 7383 7384 7385 7386
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_SDL11_CONFIG="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
Sam Hocevar's avatar
 
Sam Hocevar committed
7387
  test -z "$ac_cv_path_SDL11_CONFIG" && ac_cv_path_SDL11_CONFIG="no"
7388 7389
  ;;
esac
7390
fi
7391
SDL11_CONFIG="$ac_cv_path_SDL11_CONFIG"
Sam Hocevar's avatar
 
Sam Hocevar committed
7392
if test -n "$SDL11_CONFIG"; then
7393
  echo "$ac_t""$SDL11_CONFIG" 1>&6
7394
else
7395
  echo "$ac_t""no" 1>&6
7396 7397
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7398
    SDL_CONFIG=${SDL11_CONFIG}
7399 7400
    SDL_HEADER="SDL11/SDL.h"
  fi
7401
  if test "x${SDL_CONFIG}" = "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
7402
  then
7403 7404
    # Extract the first word of "sdl-config", so it can be a program name with args.
set dummy sdl-config; ac_word=$2
7405
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7406
echo "configure:7407: checking for $ac_word" >&5
7407 7408
if eval "test \"`echo '$''{'ac_cv_path_SDL_CONFIG'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
7409
else
7410 7411
  case "$SDL_CONFIG" in
  /*)
7412
  ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a path.
7413
  ;;
7414 7415 7416
  ?:/*)			 
  ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a dos path.
  ;;
7417
  *)
7418
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
7419
  ac_dummy="${SDL_PATH}"
7420 7421 7422 7423 7424 7425 7426 7427
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_SDL_CONFIG="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
7428
  test -z "$ac_cv_path_SDL_CONFIG" && ac_cv_path_SDL_CONFIG="no"
7429 7430 7431
  ;;
esac
fi
7432
SDL_CONFIG="$ac_cv_path_SDL_CONFIG"
7433
if test -n "$SDL_CONFIG"; then
7434
  echo "$ac_t""$SDL_CONFIG" 1>&6
7435
else
7436
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7437 7438
fi

7439
    SDL_HEADER="SDL/SDL.h"
7440
  fi
7441
  if test "x${SDL_CONFIG}" != "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
7442
  then
7443
    PLUGINS="${PLUGINS} sdl"
Sam Hocevar's avatar
 
Sam Hocevar committed
7444 7445
    sdl_CFLAGS="${sdl_CFLAGS} `${SDL_CONFIG} --cflags`"
    sdl_LDFLAGS="${sdl_LDFLAGS} `${SDL_CONFIG} --libs | sed 's,-rdynamic,,'`"
7446
    CPPFLAGS="${save_CPPFLAGS} ${sdl_CFLAGS}"
7447
    for ac_hdr in ${SDL_HEADER}
7448
do
7449 7450
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7451
echo "configure:7452: checking for $ac_hdr" >&5
7452 7453
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7454
else
7455
  cat > conftest.$ac_ext <<EOF
7456
#line 7457 "configure"
7457 7458 7459 7460
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7461
{ (eval echo configure:7462: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7462 7463 7464 7465 7466 7467 7468
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
7469
  cat conftest.$ac_ext >&5
7470 7471
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
7472
fi
7473
rm -f conftest*
7474
fi
7475 7476 7477 7478 7479 7480 7481
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 cat >> confdefs.h <<EOF
7482
#define SDL_INCLUDE_FILE <${SDL_HEADER}>
7483
EOF
7484

Sam Hocevar's avatar
 
Sam Hocevar committed
7485
else
7486 7487 7488 7489 7490
  echo "$ac_t""no" 1>&6
{ echo "configure: error: The development package for SDL is not installed. 
Please install it and try again. Alternatively you can also configure with 
--disable-sdl." 1>&2; exit 1; }
      
7491 7492 7493
fi
done

7494 7495
    CPPFLAGS="${save_CPPFLAGS}"
    if expr 1.1.5 \> `${SDL_CONFIG} --version` >/dev/null
Sam Hocevar's avatar
 
Sam Hocevar committed
7496
    then
7497
      { echo "configure: error: The development package for SDL is not installed.
7498
Please install it and try again. Alternatively you can also configure with
7499
--disable-sdl." 1>&2; exit 1; }
Sam Hocevar's avatar
 
Sam Hocevar committed
7500
    fi
7501
  elif test "x${enable_sdl}" =  "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
7502
  then
7503
    { echo "configure: error: I couldn't find the SDL package. You can download libSDL
7504
from http://www.libsdl.org/, or configure with --disable-sdl. Have a nice day.
7505
    " 1>&2; exit 1; }
7506 7507
  fi
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7508

7509 7510 7511
# Check whether --enable-directx or --disable-directx was given.
if test "${enable_directx+set}" = set; then
  enableval="$enable_directx"
7512 7513
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7514

7515
if test "x${enable_directx}" != "xno"
7516
then
7517
  if test "x${SYS}" = "xmingw32"
7518
  then
7519
    # Check whether --with-directx or --without-directx was given.
Xavier Marchesini's avatar
 
Xavier Marchesini committed
7520 7521
if test "${with_directx+set}" = set; then
  withval="$with_directx"
7522 7523
  :
fi
Gildas Bazin's avatar
 
Gildas Bazin committed
7524

7525
    if test "x${with_directx}" = "x"
7526
    then
7527
      for ac_hdr in ddraw.h
Sam Hocevar's avatar
 
Sam Hocevar committed
7528
do
7529 7530
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7531
echo "configure:7532: checking for $ac_hdr" >&5
7532 7533
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
7534
else
7535
  cat > conftest.$ac_ext <<EOF
7536
#line 7537 "configure"
7537 7538 7539 7540
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7541
{ (eval echo configure:7542: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7542 7543 7544 7545 7546 7547 7548
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
7549
  cat conftest.$ac_ext >&5
7550 7551
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
7552
fi
7553
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
7554
fi
7555 7556 7557 7558 7559 7560
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
7561
  PLUGINS="${PLUGINS} directx"
7562 7563 7564
        directx_LDFLAGS="${directx_LDFLAGS} -lgdi32" 
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7565 7566 7567
fi
done

7568
    else
7569
      echo $ac_n "checking for directX headers in ${with_directx}""... $ac_c" 1>&6
7570
echo "configure:7571: checking for directX headers in ${with_directx}" >&5
7571
      if test -f ${with_directx}/ddraw.h
7572 7573
      then
        PLUGINS="${PLUGINS} directx"
Gildas Bazin's avatar
 
Gildas Bazin committed
7574
        directx_LDFLAGS="${directx_LDFLAGS} -lgdi32"
7575
        directx_CFLAGS="${directx_CFLAGS} -I${with_directx}"
7576
        echo "$ac_t""yes" 1>&6
Gildas Bazin's avatar
 
Gildas Bazin committed
7577
      else
7578 7579
        echo "$ac_t""no" 1>&6
        { echo "configure: error: Cannot find ${with_directx}/ddraw.h!" 1>&2; exit 1; }
Gildas Bazin's avatar
 
Gildas Bazin committed
7580
      fi
7581 7582
    fi
  fi
7583 7584
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7585 7586 7587
# Check whether --enable-fb or --disable-fb was given.
if test "${enable_fb+set}" = set; then
  enableval="$enable_fb"
7588 7589
  :
fi
Gildas Bazin's avatar
 
Gildas Bazin committed
7590

7591
    if test "x${enable_fb}" != "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
7592
    then
7593
      for ac_hdr in linux/fb.h
Sam Hocevar's avatar
 
Sam Hocevar committed
7594
do
7595 7596
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7597
echo "configure:7598: checking for $ac_hdr" >&5
7598 7599
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
7600
else
7601
  cat > conftest.$ac_ext <<EOF
7602
#line 7603 "configure"
7603 7604 7605 7606
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7607
{ (eval echo configure:7608: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7608 7609 7610 7611 7612 7613 7614
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
7615
  cat conftest.$ac_ext >&5
7616 7617
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
7618
fi
7619
rm -f conftest*
Gildas Bazin's avatar
 
Gildas Bazin committed
7620
fi
7621 7622 7623 7624 7625 7626 7627
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
Sam Hocevar's avatar
 
Sam Hocevar committed
7628
        PLUGINS="${PLUGINS} fb"
7629 7630 7631
      
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7632 7633
fi
done
Gildas Bazin's avatar
 
Gildas Bazin committed
7634

Sam Hocevar's avatar
 
Sam Hocevar committed
7635 7636 7637 7638 7639
    fi

# Check whether --enable-mga or --disable-mga was given.
if test "${enable_mga+set}" = set; then
  enableval="$enable_mga"
7640
   if test "x${enable_mga}" = "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
7641
    then
Sam Hocevar's avatar
 
Sam Hocevar committed
7642
      PLUGINS="${PLUGINS} mga xmga"
7643 7644 7645
    fi 
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7646

Sam Hocevar's avatar
 
Sam Hocevar committed
7647 7648 7649
# Check whether --enable-ggi or --disable-ggi was given.
if test "${enable_ggi+set}" = set; then
  enableval="$enable_ggi"
7650 7651
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7652

7653
if test "x${enable_ggi}" = "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
7654 7655
then
  PLUGINS="${PLUGINS} ggi"
Sam Hocevar's avatar
 
Sam Hocevar committed
7656
  ggi_LDFLAGS="${ggi_LDFLAGS} -lggi"
7657
  # Check whether --with-ggi or --without-ggi was given.
Sam Hocevar's avatar
 
Sam Hocevar committed
7658 7659
if test "${with_ggi+set}" = set; then
  withval="$with_ggi"
7660
   if test "x${with_ggi}" != "xno" -a "x${with_ggi}" != "x"
Sam Hocevar's avatar
 
Sam Hocevar committed
7661
      then
7662 7663
        CFLAGS_GGI="${CFLAGS_GGI} -I${with_ggi}/include"
        ggi_LDFLAGS="${ggi_LDFLAGS} -L${with_ggi}/lib"
7664 7665 7666
      fi 
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7667 7668 7669 7670 7671
fi

# Check whether --enable-glide or --disable-glide was given.
if test "${enable_glide+set}" = set; then
  enableval="$enable_glide"
7672 7673
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7674

7675
if test "x${enable_glide}" = "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
7676 7677
then
  PLUGINS="${PLUGINS} glide"
Sam Hocevar's avatar
 
Sam Hocevar committed
7678 7679
  glide_LDFLAGS="${glide_LDFLAGS} -lglide2x -lm"
  glide_CFLAGS="${glide_CFLAGS} -I/usr/include/glide"
7680
  # Check whether --with-glide or --without-glide was given.
Christophe Massiot's avatar
Christophe Massiot committed
7681 7682
if test "${with_glide+set}" = set; then
  withval="$with_glide"
7683
   if test "x${with_glide}" != "xno" -a "x${with_glide}" != "x"
Sam Hocevar's avatar
 
Sam Hocevar committed
7684
      then
7685 7686
        glide_CFLAGS="${glide_CFLAGS} -I${with_glide}/include"
        glide_LDFLAGS="${glide_LDFLAGS} -L${with_glide}/lib"
7687 7688 7689
      fi 
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7690
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7691

Sam Hocevar's avatar
 
Sam Hocevar committed
7692 7693 7694
# Check whether --enable-aa or --disable-aa was given.
if test "${enable_aa+set}" = set; then
  enableval="$enable_aa"
7695 7696
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7697

7698
if test "x${enable_aa}" = "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
7699
then
7700 7701
  ac_safe=`echo "aalib.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for aalib.h""... $ac_c" 1>&6
7702
echo "configure:7703: checking for aalib.h" >&5
7703 7704 7705 7706
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  cat > conftest.$ac_ext <<EOF
7707
#line 7708 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
7708 7709
#include "confdefs.h"
#include <aalib.h>
7710 7711
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7712
{ (eval echo configure:7713: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7713 7714 7715 7716 7717 7718 7719
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
7720
  cat conftest.$ac_ext >&5
7721 7722
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
7723
fi
7724
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
7725
fi
7726 7727
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7728 7729
  have_aa="true"
else
7730 7731
  echo "$ac_t""no" 1>&6
have_aa="false"
Sam Hocevar's avatar
 
Sam Hocevar committed
7732 7733
fi

7734
  if test "x${have_aa}" = "xtrue"
Sam Hocevar's avatar
 
Sam Hocevar committed
7735 7736
  then
    PLUGINS="${PLUGINS} aa"
Sam Hocevar's avatar
 
Sam Hocevar committed
7737
    aa_LDFLAGS="${aa_LDFLAGS} -laa"
Sam Hocevar's avatar
 
Sam Hocevar committed
7738 7739 7740
  fi
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7741 7742 7743 7744

# Check whether --with- or --without- was given.
if test "${with_+set}" = set; then
  withval="$with_"
7745 7746
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7747

Sam Hocevar's avatar
 
Sam Hocevar committed
7748

Sam Hocevar's avatar
 
Sam Hocevar committed
7749 7750 7751
# Check whether --enable-dsp or --disable-dsp was given.
if test "${enable_dsp+set}" = set; then
  enableval="$enable_dsp"
7752 7753
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7754

Sam Hocevar's avatar
 
Sam Hocevar committed
7755

7756 7757
if test "x${enable_dsp}" != "xno" &&
  (test "x${SYS}" != "xmingw32" || test "x${enable_dsp}" = "xyes")
Sam Hocevar's avatar
 
Sam Hocevar committed
7758
then
7759
  for ac_hdr in soundcard.h sys/soundcard.h machine/soundcard.h
Sam Hocevar's avatar
 
Sam Hocevar committed
7760
do
7761 7762
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
7763
echo "configure:7764: checking for $ac_hdr" >&5
7764 7765
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
7766
else
7767
  cat > conftest.$ac_ext <<EOF
7768
#line 7769 "configure"
7769 7770 7771 7772
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7773
{ (eval echo configure:7774: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7774 7775 7776 7777 7778 7779 7780
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
7781
  cat conftest.$ac_ext >&5
7782 7783
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
7784
fi
7785
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
7786
fi
7787 7788 7789 7790 7791 7792 7793
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
Sam Hocevar's avatar
 
Sam Hocevar committed
7794
    PLUGINS="${PLUGINS} dsp"
7795
    echo $ac_n "checking for main in -lossaudio""... $ac_c" 1>&6
7796
echo "configure:7797: checking for main in -lossaudio" >&5
7797 7798 7799
ac_lib_var=`echo ossaudio'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7800
else
7801
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
7802
LIBS="-lossaudio  $LIBS"
7803
cat > conftest.$ac_ext <<EOF
7804
#line 7805 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
7805 7806
#include "confdefs.h"

7807 7808 7809 7810
int main() {
main()
; return 0; }
EOF
7811
if { (eval echo configure:7812: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7812 7813 7814 7815 7816 7817 7818 7819 7820 7821
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
7822

7823 7824 7825
fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7826
  dsp_LDFLAGS="${dsp_LDFLAGS} -lossaudio"
7827 7828
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7829 7830
fi

7831 7832 7833
  
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7834 7835 7836 7837 7838 7839 7840 7841
fi
done

fi

# Check whether --enable-esd or --disable-esd was given.
if test "${enable_esd+set}" = set; then
  enableval="$enable_esd"
7842
  if test "x${enable_esd}" = "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
7843 7844 7845
   then
     # Extract the first word of "esd-config", so it can be a program name with args.
set dummy esd-config; ac_word=$2
7846
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7847
echo "configure:7848: checking for $ac_word" >&5
7848 7849
if eval "test \"`echo '$''{'ac_cv_path_ESD_CONFIG'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7850
else
7851 7852
  case "$ESD_CONFIG" in
  /*)
Sam Hocevar's avatar
 
Sam Hocevar committed
7853 7854
  ac_cv_path_ESD_CONFIG="$ESD_CONFIG" # Let the user override the test with a path.
  ;;
7855 7856 7857
  ?:/*)			 
  ac_cv_path_ESD_CONFIG="$ESD_CONFIG" # Let the user override the test with a dos path.
  ;;
Sam Hocevar's avatar
 
Sam Hocevar committed
7858
  *)
7859 7860 7861 7862 7863 7864 7865 7866 7867 7868
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_ESD_CONFIG="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
Sam Hocevar's avatar
 
Sam Hocevar committed
7869 7870 7871 7872
  test -z "$ac_cv_path_ESD_CONFIG" && ac_cv_path_ESD_CONFIG="no"
  ;;
esac
fi
7873
ESD_CONFIG="$ac_cv_path_ESD_CONFIG"
Sam Hocevar's avatar
 
Sam Hocevar committed
7874
if test -n "$ESD_CONFIG"; then
7875
  echo "$ac_t""$ESD_CONFIG" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7876
else
7877
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7878 7879
fi

7880
     if test "x${ESD_CONFIG}" != "xno"
7881
     then
Sam Hocevar's avatar
 
Sam Hocevar committed
7882
       PLUGINS="${PLUGINS} esd"
Sam Hocevar's avatar
 
Sam Hocevar committed
7883 7884
       esd_CFLAGS="${esd_CFLAGS} `${ESD_CONFIG} --cflags`"
       esd_LDFLAGS="${esd_LDFLAGS} `${ESD_CONFIG} --libs`"
7885
     fi
Sam Hocevar's avatar
 
Sam Hocevar committed
7886
   fi
7887 7888
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7889

Sam Hocevar's avatar
 
Sam Hocevar committed
7890 7891 7892
# Check whether --enable-arts or --disable-arts was given.
if test "${enable_arts+set}" = set; then
  enableval="$enable_arts"
7893
  if test "x${enable_arts}" = "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
7894 7895 7896
   then
     # Extract the first word of "artsc-config", so it can be a program name with args.
set dummy artsc-config; ac_word=$2
7897
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
7898
echo "configure:7899: checking for $ac_word" >&5
7899 7900
if eval "test \"`echo '$''{'ac_cv_path_ARTS_CONFIG'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
7901
else
7902 7903
  case "$ARTS_CONFIG" in
  /*)
Sam Hocevar's avatar
 
Sam Hocevar committed
7904
  ac_cv_path_ARTS_CONFIG="$ARTS_CONFIG" # Let the user override the test with a path.
7905
  ;;
7906 7907 7908
  ?:/*)			 
  ac_cv_path_ARTS_CONFIG="$ARTS_CONFIG" # Let the user override the test with a dos path.
  ;;
7909
  *)
7910 7911 7912 7913 7914 7915 7916 7917 7918 7919
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_ARTS_CONFIG="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
Sam Hocevar's avatar
 
Sam Hocevar committed
7920
  test -z "$ac_cv_path_ARTS_CONFIG" && ac_cv_path_ARTS_CONFIG="no"
7921 7922 7923
  ;;
esac
fi
7924
ARTS_CONFIG="$ac_cv_path_ARTS_CONFIG"
Sam Hocevar's avatar
 
Sam Hocevar committed
7925
if test -n "$ARTS_CONFIG"; then
7926
  echo "$ac_t""$ARTS_CONFIG" 1>&6
7927
else
7928
  echo "$ac_t""no" 1>&6
7929 7930
fi

7931
     if test "x${ARTS_CONFIG}" != "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
7932 7933
     then
       PLUGINS="${PLUGINS} arts"
Sam Hocevar's avatar
 
Sam Hocevar committed
7934 7935
       arts_CFLAGS="${arts_CFLAGS} `${ARTS_CONFIG} --cflags`"
       arts_LDFLAGS="${arts_LDFLAGS} `${ARTS_CONFIG} --libs `"
Sam Hocevar's avatar
 
Sam Hocevar committed
7936 7937
     fi
   fi
7938 7939
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
7940 7941 7942 7943

# Check whether --enable-alsa or --disable-alsa was given.
if test "${enable_alsa+set}" = set; then
  enableval="$enable_alsa"
7944
  if test "x${enable_alsa}" = "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
7945
   then
7946 7947
     ac_safe=`echo "alsa/asoundlib.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for alsa/asoundlib.h""... $ac_c" 1>&6
7948
echo "configure:7949: checking for alsa/asoundlib.h" >&5
7949 7950 7951 7952
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  cat > conftest.$ac_ext <<EOF
7953
#line 7954 "configure"
7954
#include "confdefs.h"
Sam Hocevar's avatar
 
Sam Hocevar committed
7955
#include <alsa/asoundlib.h>
7956 7957
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7958
{ (eval echo configure:7959: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7959 7960 7961 7962 7963 7964 7965
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
7966
  cat conftest.$ac_ext >&5
7967 7968
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
7969
fi
7970
rm -f conftest*
7971
fi
7972 7973 7974
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  echo $ac_n "checking for main in -lasound""... $ac_c" 1>&6
7975
echo "configure:7976: checking for main in -lasound" >&5
7976 7977 7978
ac_lib_var=`echo asound'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
7979
else
7980
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
7981
LIBS="-lasound  $LIBS"
7982
cat > conftest.$ac_ext <<EOF
7983
#line 7984 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
7984 7985
#include "confdefs.h"

7986 7987 7988 7989
int main() {
main()
; return 0; }
EOF
7990
if { (eval echo configure:7991: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
7991 7992 7993 7994 7995 7996 7997 7998 7999 8000
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
8001

8002 8003 8004
fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8005 8006
  have_alsa="true"
else
8007 8008
  echo "$ac_t""no" 1>&6
have_alsa="false"
Sam Hocevar's avatar
 
Sam Hocevar committed
8009 8010
fi

8011
else
8012 8013
  echo "$ac_t""no" 1>&6
have_alsa="false"
8014 8015
fi

8016
     if test "x${have_alsa}" = "xtrue"
Sam Hocevar's avatar
 
Sam Hocevar committed
8017 8018
     then
       PLUGINS="${PLUGINS} alsa"
Sam Hocevar's avatar
 
Sam Hocevar committed
8019
       alsa_LDFLAGS="${alsa_LDFLAGS} -lasound -lm -ldl"
Sam Hocevar's avatar
 
Sam Hocevar committed
8020 8021
     fi
   fi
8022 8023
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8024 8025 8026 8027

# Check whether --enable-waveout or --disable-waveout was given.
if test "${enable_waveout+set}" = set; then
  enableval="$enable_waveout"
8028 8029
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
8030

8031
if test "x${enable_waveout}" != "xno" -a "x${SYS}" = "xmingw32"
Sam Hocevar's avatar
 
Sam Hocevar committed
8032 8033
  then
    PLUGINS="${PLUGINS} waveout"
Sam Hocevar's avatar
 
Sam Hocevar committed
8034
    waveout_LDFLAGS="-lwinmm"
Sam Hocevar's avatar
 
Sam Hocevar committed
8035 8036 8037 8038 8039 8040
fi


# Check whether --with- or --without- was given.
if test "${with_+set}" = set; then
  withval="$with_"
8041 8042
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
8043

Sam Hocevar's avatar
 
Sam Hocevar committed
8044

Sam Hocevar's avatar
 
Sam Hocevar committed
8045 8046 8047
# Check whether --enable-gtk or --disable-gtk was given.
if test "${enable_gtk+set}" = set; then
  enableval="$enable_gtk"
8048 8049
  :
fi
8050

8051
if test "x${enable_gtk}" != "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
8052
then
8053
  GTK_PATH="${PATH}"
8054
  # Check whether --with-gtk-config-path or --without-gtk-config-path was given.
8055 8056
if test "${with_gtk_config_path+set}" = set; then
  withval="$with_gtk_config_path"
8057
   if test "x${with_gtk_config_path}" != "xno"
8058
      then
8059
        GTK_PATH="${with_gtk_config_path}:${PATH}"
8060 8061 8062
      fi 
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8063
  # look for gtk-config
Sam Hocevar's avatar
 
Sam Hocevar committed
8064 8065
  # Extract the first word of "gtk12-config", so it can be a program name with args.
set dummy gtk12-config; ac_word=$2
8066
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
8067
echo "configure:8068: checking for $ac_word" >&5
8068 8069
if eval "test \"`echo '$''{'ac_cv_path_GTK12_CONFIG'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8070
else
8071 8072
  case "$GTK12_CONFIG" in
  /*)
Sam Hocevar's avatar
 
Sam Hocevar committed
8073 8074
  ac_cv_path_GTK12_CONFIG="$GTK12_CONFIG" # Let the user override the test with a path.
  ;;
8075 8076 8077
  ?:/*)			 
  ac_cv_path_GTK12_CONFIG="$GTK12_CONFIG" # Let the user override the test with a dos path.
  ;;
Sam Hocevar's avatar
 
Sam Hocevar committed
8078
  *)
8079
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
8080
  ac_dummy="${GTK_PATH}"
8081 8082 8083 8084 8085 8086 8087 8088
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_GTK12_CONFIG="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
Sam Hocevar's avatar
 
Sam Hocevar committed
8089 8090 8091 8092
  test -z "$ac_cv_path_GTK12_CONFIG" && ac_cv_path_GTK12_CONFIG="no"
  ;;
esac
fi
8093
GTK12_CONFIG="$ac_cv_path_GTK12_CONFIG"
Sam Hocevar's avatar
 
Sam Hocevar committed
8094
if test -n "$GTK12_CONFIG"; then
8095
  echo "$ac_t""$GTK12_CONFIG" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8096
else
8097
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8098 8099 8100
fi

  GTK_CONFIG=${GTK12_CONFIG}
8101
  if test "x${GTK_CONFIG}" = "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
8102 8103 8104
  then
    # Extract the first word of "gtk-config", so it can be a program name with args.
set dummy gtk-config; ac_word=$2
8105
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
8106
echo "configure:8107: checking for $ac_word" >&5
8107 8108
if eval "test \"`echo '$''{'ac_cv_path_GTK_CONFIG'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8109
else
8110 8111
  case "$GTK_CONFIG" in
  /*)
Sam Hocevar's avatar
 
Sam Hocevar committed
8112 8113
  ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a path.
  ;;
8114 8115 8116
  ?:/*)			 
  ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a dos path.
  ;;
Sam Hocevar's avatar
 
Sam Hocevar committed
8117
  *)
8118
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
8119
  ac_dummy="${GTK_PATH}"
8120 8121 8122 8123 8124 8125 8126 8127
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_GTK_CONFIG="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
Sam Hocevar's avatar
 
Sam Hocevar committed
8128 8129 8130 8131
  test -z "$ac_cv_path_GTK_CONFIG" && ac_cv_path_GTK_CONFIG="no"
  ;;
esac
fi
8132
GTK_CONFIG="$ac_cv_path_GTK_CONFIG"
Sam Hocevar's avatar
 
Sam Hocevar committed
8133
if test -n "$GTK_CONFIG"; then
8134
  echo "$ac_t""$GTK_CONFIG" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8135
else
8136
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8137 8138
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8139
  fi
8140
  if test "x${GTK_CONFIG}" != "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
8141
  then
8142
    if expr 1.2.0 \> `${GTK_CONFIG} --version` >/dev/null
Sam Hocevar's avatar
 
Sam Hocevar committed
8143
    then
8144
      { echo "configure: error: Your development package for Gtk+ is too old, you need at least version 1.2.0. Please upgrade and try again. Alternatively you can also configure with --disable-gtk." 1>&2; exit 1; }
Sam Hocevar's avatar
 
Sam Hocevar committed
8145
    fi
Sam Hocevar's avatar
 
Sam Hocevar committed
8146 8147
    gtk_CFLAGS="${gtk_CFLAGS} `${GTK_CONFIG} --cflags gtk`"
    gtk_LDFLAGS="${gtk_LDFLAGS} `${GTK_CONFIG} --libs gtk | sed 's,-rdynamic,,'`"
Sam Hocevar's avatar
 
Sam Hocevar committed
8148
    # now look for the gtk.h header
8149
    CPPFLAGS="${save_CPPFLAGS} ${gtk_CFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
8150
    ac_cv_gtk_headers=yes
8151
    for ac_hdr in gtk/gtk.h glib.h gdk/gdk.h
Sam Hocevar's avatar
 
Sam Hocevar committed
8152
do
8153 8154
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
8155
echo "configure:8156: checking for $ac_hdr" >&5
8156 8157
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
8158
else
8159
  cat > conftest.$ac_ext <<EOF
8160
#line 8161 "configure"
8161 8162 8163 8164
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
8165
{ (eval echo configure:8166: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8166 8167 8168 8169 8170 8171 8172
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
8173
  cat conftest.$ac_ext >&5
8174 8175
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
8176
fi
8177
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
8178
fi
8179 8180 8181 8182 8183 8184 8185
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
Sam Hocevar's avatar
 
Sam Hocevar committed
8186
else
8187 8188
  echo "$ac_t""no" 1>&6
ac_cv_gtk_headers=no
Sam Hocevar's avatar
 
Sam Hocevar committed
8189
      echo "Cannot find gtk development headers."
8190
    
Sam Hocevar's avatar
 
Sam Hocevar committed
8191 8192 8193
fi
done

8194
    if test "x${ac_cv_gtk_headers}" = "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
8195 8196 8197 8198
    then
      PLUGINS="${PLUGINS} gtk"
      ALIASES="${ALIASES} gvlc"
    fi
8199
    CPPFLAGS="${save_CPPFLAGS}"
8200
  fi
8201
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
8202

8203 8204 8205 8206 8207 8208 8209 8210 8211 8212 8213 8214 8215 8216 8217 8218 8219 8220 8221 8222 8223 8224 8225 8226 8227 8228 8229 8230 8231 8232 8233 8234 8235 8236 8237 8238 8239 8240 8241 8242 8243 8244 8245 8246 8247 8248 8249 8250 8251 8252 8253 8254 8255 8256 8257 8258 8259 8260 8261 8262 8263 8264 8265 8266 8267 8268 8269 8270 8271 8272 8273 8274 8275 8276 8277 8278 8279 8280 8281 8282 8283 8284 8285 8286 8287 8288 8289 8290 8291 8292 8293 8294 8295 8296 8297 8298 8299 8300 8301 8302 8303 8304 8305 8306 8307 8308 8309 8310 8311 8312 8313 8314 8315 8316 8317 8318 8319 8320 8321 8322 8323 8324 8325 8326 8327 8328 8329 8330 8331 8332 8333 8334 8335 8336 8337 8338 8339 8340 8341 8342 8343 8344 8345 8346 8347 8348 8349 8350 8351 8352 8353 8354 8355 8356 8357 8358 8359
# Check whether --enable-familiar or --disable-familiar was given.
if test "${enable_familiar+set}" = set; then
  enableval="$enable_familiar"
  :
fi

if test "x${enable_familiar}" = "xyes"
then
  GTK_PATH="${PATH}"
  # Check whether --with-gtk-config-path or --without-gtk-config-path was given.
if test "${with_gtk_config_path+set}" = set; then
  withval="$with_gtk_config_path"
   if test "x${with_gtk_config_path}" != "xno"
      then
        GTK_PATH="${with_gtk_config_path}:${PATH}"
      fi 
fi

  # look for gtk-config
  # Extract the first word of "gtk12-config", so it can be a program name with args.
set dummy gtk12-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:8226: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GTK12_CONFIG'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  case "$GTK12_CONFIG" in
  /*)
  ac_cv_path_GTK12_CONFIG="$GTK12_CONFIG" # Let the user override the test with a path.
  ;;
  ?:/*)			 
  ac_cv_path_GTK12_CONFIG="$GTK12_CONFIG" # Let the user override the test with a dos path.
  ;;
  *)
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="${GTK_PATH}"
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_GTK12_CONFIG="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_path_GTK12_CONFIG" && ac_cv_path_GTK12_CONFIG="no"
  ;;
esac
fi
GTK12_CONFIG="$ac_cv_path_GTK12_CONFIG"
if test -n "$GTK12_CONFIG"; then
  echo "$ac_t""$GTK12_CONFIG" 1>&6
else
  echo "$ac_t""no" 1>&6
fi

  GTK_CONFIG=${GTK12_CONFIG}
  if test "x${GTK_CONFIG}" = "xno"
  then
    # Extract the first word of "gtk-config", so it can be a program name with args.
set dummy gtk-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:8265: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GTK_CONFIG'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  case "$GTK_CONFIG" in
  /*)
  ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a path.
  ;;
  ?:/*)			 
  ac_cv_path_GTK_CONFIG="$GTK_CONFIG" # Let the user override the test with a dos path.
  ;;
  *)
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="${GTK_PATH}"
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_GTK_CONFIG="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_path_GTK_CONFIG" && ac_cv_path_GTK_CONFIG="no"
  ;;
esac
fi
GTK_CONFIG="$ac_cv_path_GTK_CONFIG"
if test -n "$GTK_CONFIG"; then
  echo "$ac_t""$GTK_CONFIG" 1>&6
else
  echo "$ac_t""no" 1>&6
fi

  fi
  if test "x${GTK_CONFIG}" != "xno"
  then
    if expr 1.2.0 \> `${GTK_CONFIG} --version` >/dev/null
    then
      { echo "configure: error: Your development package for Gtk+ is too old, you need at least version 1.2.0. Please upgrade and try again. Alternatively you can also configure with --disable-familiar." 1>&2; exit 1; }
    fi
    familiar_CFLAGS="${familiar_CFLAGS} `${GTK_CONFIG} --cflags gtk`"
    familiar_LDFLAGS="${familiar_LDFLAGS} `${GTK_CONFIG} --libs gtk | sed 's,-rdynamic,,'`"
    # now look for the gtk.h header
    CPPFLAGS="${save_CPPFLAGS} ${familiar_CFLAGS}"
    ac_cv_gtk_headers=yes
    for ac_hdr in gtk/gtk.h glib.h gdk/gdk.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:8314: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  cat > conftest.$ac_ext <<EOF
#line 8319 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:8324: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
fi
rm -f conftest*
fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
else
  echo "$ac_t""no" 1>&6
ac_cv_gtk_headers=no
      echo "Cannot find gtk development headers."
    
fi
done

    if test "x${ac_cv_gtk_headers}" = "xyes"
    then
      PLUGINS="${PLUGINS} familiar"
    fi
    CPPFLAGS="${save_CPPFLAGS}"
  fi
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8360 8361 8362
# Check whether --enable-gnome or --disable-gnome was given.
if test "${enable_gnome+set}" = set; then
  enableval="$enable_gnome"
8363
  if test "x${enable_gnome}" = "xyes"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
8364 8365 8366
    # look for gnome-config
    # Extract the first word of "gnome-config", so it can be a program name with args.
set dummy gnome-config; ac_word=$2
8367
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
8368
echo "configure:8369: checking for $ac_word" >&5
8369 8370
if eval "test \"`echo '$''{'ac_cv_path_GNOME_CONFIG'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8371
else
8372 8373
  case "$GNOME_CONFIG" in
  /*)
Sam Hocevar's avatar
 
Sam Hocevar committed
8374 8375
  ac_cv_path_GNOME_CONFIG="$GNOME_CONFIG" # Let the user override the test with a path.
  ;;
8376 8377 8378
  ?:/*)			 
  ac_cv_path_GNOME_CONFIG="$GNOME_CONFIG" # Let the user override the test with a dos path.
  ;;
Sam Hocevar's avatar
 
Sam Hocevar committed
8379
  *)
8380 8381 8382 8383 8384 8385 8386 8387 8388 8389
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_GNOME_CONFIG="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
Sam Hocevar's avatar
 
Sam Hocevar committed
8390 8391 8392 8393
  test -z "$ac_cv_path_GNOME_CONFIG" && ac_cv_path_GNOME_CONFIG="no"
  ;;
esac
fi
8394
GNOME_CONFIG="$ac_cv_path_GNOME_CONFIG"
Sam Hocevar's avatar
 
Sam Hocevar committed
8395
if test -n "$GNOME_CONFIG"; then
8396
  echo "$ac_t""$GNOME_CONFIG" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8397
else
8398
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8399
fi
Henri Fallon's avatar
 
Henri Fallon committed
8400

Sam Hocevar's avatar
 
Sam Hocevar committed
8401 8402
    if test -x ${GNOME_CONFIG}
    then
Sam Hocevar's avatar
 
Sam Hocevar committed
8403 8404
       gnome_CFLAGS="${gnome_CFLAGS} `${GNOME_CONFIG} --cflags gtk gnomeui`"
       gnome_LDFLAGS="${gnome_LDFLAGS} `${GNOME_CONFIG} --libs gnomeui | sed 's,-rdynamic,,'`"
Sam Hocevar's avatar
 
Sam Hocevar committed
8405 8406
    fi
    # now look for the gnome.h header
8407
    CPPFLAGS="${save_CPPFLAGS} ${gnome_CFLAGS}"
8408
    for ac_hdr in gnome.h
8409
do
8410 8411
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
8412
echo "configure:8413: checking for $ac_hdr" >&5
8413 8414
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8415
else
8416
  cat > conftest.$ac_ext <<EOF
8417
#line 8418 "configure"
8418 8419 8420 8421
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
8422
{ (eval echo configure:8423: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8423 8424 8425 8426 8427 8428 8429
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
8430
  cat conftest.$ac_ext >&5
8431 8432
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
8433
fi
8434
rm -f conftest*
8435
fi
8436 8437 8438 8439 8440 8441 8442
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
Sam Hocevar's avatar
 
Sam Hocevar committed
8443 8444
      PLUGINS="${PLUGINS} gnome"
      ALIASES="${ALIASES} gnome-vlc"
8445
     
Sam Hocevar's avatar
 
Sam Hocevar committed
8446
else
8447 8448 8449 8450
  echo "$ac_t""no" 1>&6
{ echo "configure: error: Can't find gnome headers. Please install the gnome
developement tools or remove the --enable-gnome option" 1>&2; exit 1; }
     
8451 8452 8453
fi
done

8454
    CPPFLAGS="${save_CPPFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
8455
  fi
8456 8457
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8458 8459 8460 8461

# Check whether --enable-qt or --disable-qt was given.
if test "${enable_qt+set}" = set; then
  enableval="$enable_qt"
8462
  if test "x${enable_qt}" = "xyes"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
8463 8464
     PLUGINS="${PLUGINS} qt"
     ALIASES="${ALIASES} qvlc"
Sam Hocevar's avatar
 
Sam Hocevar committed
8465 8466
     qt_LDFLAGS="${qt_LDFLAGS} -lqt -L${QTDIR}/lib"
     qt_CFLAGS="${qt_CFLAGS} -I/usr/include/qt -I${QTDIR}/include"
Sam Hocevar's avatar
 
Sam Hocevar committed
8467 8468 8469 8470 8471 8472 8473
     if test -x ${QTDIR}/bin/moc
     then
       MOC=${QTDIR}/bin/moc
     else
       MOC=moc
     fi
   fi
8474 8475
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8476 8477 8478 8479

# Check whether --enable-kde or --disable-kde was given.
if test "${enable_kde+set}" = set; then
  enableval="$enable_kde"
8480
  if test "x${enable_kde}" = "xyes"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
8481 8482
     PLUGINS="${PLUGINS} kde"
     ALIASES="${ALIASES} kvlc"
Sam Hocevar's avatar
 
Sam Hocevar committed
8483 8484 8485
     kde_LDFLAGS="${kde_LDFLAGS} -L${KDEDIR}/lib -lkfile"
     kde_CFLAGS="${kde_CFLAGS} -I/usr/include/kde -I/usr/include/qt"
     kde_CFLAGS="${kde_CFLAGS} -I${KDEDIR}/include -I${QTDIR}/include"
Sam Hocevar's avatar
 
Sam Hocevar committed
8486 8487 8488 8489 8490 8491 8492
     if test -x ${QTDIR}/bin/moc
     then
       MOC=${QTDIR}/bin/moc
     else
       MOC=moc
     fi
   fi
8493 8494
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8495 8496 8497 8498

# Check whether --enable-macosx or --disable-macosx was given.
if test "${enable_macosx+set}" = set; then
  enableval="$enable_macosx"
8499
  if test "x${enable_macosx}" = "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
8500 8501
   then
     BUILTINS="${BUILTINS} macosx"
Jon Lech Johansen's avatar
Jon Lech Johansen committed
8502
     macosx_LDFLAGS="${macosx_LDFLAGS} -framework CoreAudio -framework AudioToolbox -framework IOKit -framework Cocoa -framework Carbon -framework AGL -framework QuickTime -lobjc -ObjC"
Sam Hocevar's avatar
 
Sam Hocevar committed
8503 8504
   fi
else
8505
  for ac_hdr in Cocoa/Cocoa.h
Sam Hocevar's avatar
 
Sam Hocevar committed
8506
do
8507 8508
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
8509
echo "configure:8510: checking for $ac_hdr" >&5
8510 8511
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
8512
else
8513
  cat > conftest.$ac_ext <<EOF
8514
#line 8515 "configure"
8515 8516 8517 8518
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
8519
{ (eval echo configure:8520: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8520 8521 8522 8523 8524 8525 8526
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
8527
  cat conftest.$ac_ext >&5
8528 8529
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
8530
fi
8531
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
8532
fi
8533 8534 8535 8536 8537 8538
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
8539
 BUILTINS="${BUILTINS} macosx"
Jon Lech Johansen's avatar
Jon Lech Johansen committed
8540
     macosx_LDFLAGS="${macosx_LDFLAGS} -framework CoreAudio -framework AudioToolbox -framework IOKit -framework Cocoa -framework Carbon -framework AGL -framework QuickTime -lobjc -ObjC"
8541 8542 8543
   
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8544
fi
8545 8546
done

8547 8548
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8549 8550 8551 8552

# Check whether --enable-qnx or --disable-qnx was given.
if test "${enable_qnx+set}" = set; then
  enableval="$enable_qnx"
8553 8554
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
8555

8556
    if test "x${enable_qnx}" != "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
8557
    then
8558
      for ac_hdr in Ph.h
Sam Hocevar's avatar
 
Sam Hocevar committed
8559
do
8560 8561
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
8562
echo "configure:8563: checking for $ac_hdr" >&5
8563 8564
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
8565
else
8566
  cat > conftest.$ac_ext <<EOF
8567
#line 8568 "configure"
8568 8569 8570 8571
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
8572
{ (eval echo configure:8573: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8573 8574 8575 8576 8577 8578 8579
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
Sam Hocevar's avatar
 
Sam Hocevar committed
8580
  cat conftest.$ac_ext >&5
8581 8582
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
Sam Hocevar's avatar
 
Sam Hocevar committed
8583
fi
8584
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
8585
fi
8586 8587 8588 8589 8590 8591 8592
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
  cat >> confdefs.h <<EOF
#define $ac_tr_hdr 1
EOF
 
Sam Hocevar's avatar
 
Sam Hocevar committed
8593
        PLUGINS="${PLUGINS} qnx"
Sam Hocevar's avatar
 
Sam Hocevar committed
8594
        qnx_LDFLAGS="${qnx_LDFLAGS} -lasound -lph"
8595 8596 8597
      
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8598
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
8599
done
Sam Hocevar's avatar
 
Sam Hocevar committed
8600

Sam Hocevar's avatar
 
Sam Hocevar committed
8601 8602
    fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8603 8604 8605
# Check whether --enable-intfwin or --disable-intfwin was given.
if test "${enable_intfwin+set}" = set; then
  enableval="$enable_intfwin"
8606
   if test "x${enable_intfwin}" != "xno"
Sam Hocevar's avatar
 
Sam Hocevar committed
8607
  then
8608
    # Check whether --with-bcbuilder or --without-bcbuilder was given.
Sam Hocevar's avatar
 
Sam Hocevar committed
8609 8610
if test "${with_bcbuilder+set}" = set; then
  withval="$with_bcbuilder"
8611 8612
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
8613

8614
    if test "x${with_bcbuilder}" != "x"
Sam Hocevar's avatar
 
Sam Hocevar committed
8615
    then
8616
      BCBUILDER="${with_bcbuilder}"
Sam Hocevar's avatar
 
Sam Hocevar committed
8617 8618
    fi
    PLUGINS="${PLUGINS} intfwin"
8619 8620 8621
  fi 
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8622 8623 8624 8625

# Check whether --enable-ncurses or --disable-ncurses was given.
if test "${enable_ncurses+set}" = set; then
  enableval="$enable_ncurses"
8626
  if test "x${enable_ncurses}" = "xyes"; then
Sam Hocevar's avatar
 
Sam Hocevar committed
8627
     PLUGINS="${PLUGINS} ncurses"
Sam Hocevar's avatar
 
Sam Hocevar committed
8628
     ncurses_LDFLAGS="${ncurses_LDFLAGS} -lncurses"
Sam Hocevar's avatar
 
Sam Hocevar committed
8629
   fi
8630 8631
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8632

8633 8634 8635
# Check whether --enable-xosd or --disable-xosd was given.
if test "${enable_xosd+set}" = set; then
  enableval="$enable_xosd"
8636 8637 8638
  :
fi

8639
if test "x${enable_xosd}" = "xyes"
8640 8641 8642
then
  ac_safe=`echo "xosd.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for xosd.h""... $ac_c" 1>&6
8643
echo "configure:8644: checking for xosd.h" >&5
8644 8645 8646 8647
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  cat > conftest.$ac_ext <<EOF
8648
#line 8649 "configure"
8649 8650 8651 8652
#include "confdefs.h"
#include <xosd.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
8653
{ (eval echo configure:8654: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8654 8655 8656 8657 8658 8659 8660 8661 8662 8663 8664 8665 8666 8667
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
fi
rm -f conftest*
fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
8668 8669
  echo "$ac_t""yes" 1>&6
  have_xosd="true"
8670 8671 8672 8673 8674
else
  echo "$ac_t""no" 1>&6
have_xosd="false"
fi

8675
  if test "x${have_xosd}" = "xtrue"
8676 8677 8678 8679 8680 8681
  then
    PLUGINS="${PLUGINS} xosd"
    xosd_LDFLAGS="${xosd_LDFLAGS} -lxosd"
  fi
fi

8682 8683 8684
# Check whether --enable-lirc or --disable-lirc was given.
if test "${enable_lirc+set}" = set; then
  enableval="$enable_lirc"
8685 8686
  :
fi
8687

8688
if test "x${enable_lirc}" = "xyes"
8689
then
8690 8691
  ac_safe=`echo "lirc/lirc_client.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for lirc/lirc_client.h""... $ac_c" 1>&6
8692
echo "configure:8693: checking for lirc/lirc_client.h" >&5
8693 8694 8695 8696
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  cat > conftest.$ac_ext <<EOF
8697
#line 8698 "configure"
8698 8699
#include "confdefs.h"
#include <lirc/lirc_client.h>
8700 8701
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
8702
{ (eval echo configure:8703: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
8703 8704 8705 8706 8707 8708 8709
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=yes"
else
  echo "$ac_err" >&5
  echo "configure: failed program was:" >&5
8710
  cat conftest.$ac_ext >&5
8711 8712
  rm -rf conftest*
  eval "ac_cv_header_$ac_safe=no"
8713
fi
8714
rm -f conftest*
8715
fi
8716 8717 8718
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  echo $ac_n "checking for lirc_init in -llirc_client""... $ac_c" 1>&6
8719
echo "configure:8720: checking for lirc_init in -llirc_client" >&5
8720 8721 8722
ac_lib_var=`echo lirc_client'_'lirc_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
8723
else
8724
  ac_save_LIBS="$LIBS"
8725
LIBS="-llirc_client  $LIBS"
8726
cat > conftest.$ac_ext <<EOF
8727
#line 8728 "configure"
8728 8729 8730
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
8731 8732 8733 8734 8735 8736 8737
    builtin and then its argument prototype would still apply.  */
char lirc_init();

int main() {
lirc_init()
; return 0; }
EOF
8738
if { (eval echo configure:8739: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8739 8740
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
8741
else
8742 8743 8744 8745
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
8746
fi
8747 8748
rm -f conftest*
LIBS="$ac_save_LIBS"
8749

8750 8751 8752 8753
fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
  have_lirc="true"
8754
else
8755 8756
  echo "$ac_t""no" 1>&6
have_lirc="false"
8757 8758
fi

8759 8760 8761 8762
else
  echo "$ac_t""no" 1>&6
have_lirc="false"
fi
8763

8764
  if test "x${have_lirc}" = "xtrue"
8765 8766
  then
    PLUGINS="${PLUGINS} lirc"
Sam Hocevar's avatar
 
Sam Hocevar committed
8767
    lirc_LDFLAGS="${lirc_LDFLAGS} -llirc_client"
8768 8769 8770
  fi
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8771 8772 8773
# Check whether --with- or --without- was given.
if test "${with_+set}" = set; then
  withval="$with_"
8774 8775
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
8776 8777 8778 8779 8780


# Check whether --with-words or --without-words was given.
if test "${with_words+set}" = set; then
  withval="$with_words"
8781 8782
  :
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
8783

8784
  case "x${with_words}" in
8785
    xbig)
Sam Hocevar's avatar
 
Sam Hocevar committed
8786 8787 8788 8789 8790 8791
      ac_cv_c_bigendian=yes
      ;;
    xlittle)
      ac_cv_c_bigendian=no
      ;;
    *)
8792
                  echo $ac_n "checking whether the byte order is big-endian""... $ac_c" 1>&6
8793
echo "configure:8794: checking whether the byte order is big-endian" >&5
8794 8795
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8796
else
8797
  ac_cv_c_bigendian="unknown"
Sam Hocevar's avatar
 
Sam Hocevar committed
8798 8799 8800 8801 8802 8803 8804 8805 8806
        cat >conftest.c <<EOF
        short am[] = { 0x4249, 0x4765, 0x6e44, 0x6961, 0x6e53, 0x7953, 0 };
        short ai[] = { 0x694c, 0x5454, 0x656c, 0x6e45, 0x6944, 0x6e61, 0 };
        void _a(void) { char*s = (char*)am; s = (char *)ai; }
        short ei[] = { 0x89D3, 0xe3e3, 0x8593, 0x95c5, 0x89c4, 0x9581, 0 };
        short em[] = { 0xc2c9, 0xc785, 0x95c4, 0x8981, 0x95e2, 0xa8e2, 0 };
        void _e(void) { char*s = (char*)em; s = (char*)ei; }
        int main(void) { _a(); _e(); return 0; }
EOF
8807
        
Sam Hocevar's avatar
 
Sam Hocevar committed
8808
        if test -f conftest.c
8809
        then 
Sam Hocevar's avatar
 
Sam Hocevar committed
8810
          if ${CC-cc} -c conftest.c -o conftest.o >config.log 2>&1 \
Sam Hocevar's avatar
 
Sam Hocevar committed
8811 8812 8813 8814
              && test -f conftest.o
          then
            if test "`strings conftest.o | grep BIGenDianSyS`"
            then
8815
              ac_cv_c_bigendian="yes"
Sam Hocevar's avatar
 
Sam Hocevar committed
8816 8817 8818
            fi
            if test "`strings conftest.o | grep LiTTleEnDian`"
            then
8819
              ac_cv_c_bigendian="no"
Sam Hocevar's avatar
 
Sam Hocevar committed
8820 8821 8822
            fi
          fi
        fi
8823
      
8824
fi
8825 8826

echo "$ac_t""$ac_cv_c_bigendian" 1>&6
8827
      if test "x${ac_cv_c_bigendian}" = "xunknown"
Sam Hocevar's avatar
 
Sam Hocevar committed
8828
      then
8829
        { echo "configure: error: Could not guess endianness, please use --with-words" 1>&2; exit 1; }
Sam Hocevar's avatar
 
Sam Hocevar committed
8830 8831 8832
      fi
      ;;
  esac
8833
if test "${ac_cv_c_bigendian}" = "yes"
Sam Hocevar's avatar
 
Sam Hocevar committed
8834
then
8835
  cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
8836
#define WORDS_BIGENDIAN 1
8837
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
8838 8839 8840

fi

Sam Hocevar's avatar
Sam Hocevar committed
8841 8842
PROFILING=0

Sam Hocevar's avatar
 
Sam Hocevar committed
8843 8844 8845 8846
GPROF=0
# Check whether --enable-gprof or --disable-gprof was given.
if test "${enable_gprof+set}" = set; then
  enableval="$enable_gprof"
8847
   if test "x${enable_gprof}" = "xyes"
Sam Hocevar's avatar
Sam Hocevar committed
8848 8849 8850 8851 8852
  then
    GPROF=1
    PROFILING="gprof"
  fi

8853 8854
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8855 8856 8857 8858 8859

CPROF=0
# Check whether --enable-cprof or --disable-cprof was given.
if test "${enable_cprof+set}" = set; then
  enableval="$enable_cprof"
8860
   if test "x${enable_cprof}" = "xyes"
Sam Hocevar's avatar
 
Sam Hocevar committed
8861
  then
8862
    save_LDFLAGS="${save_LDFLAGS} -lcprof"; LDFLAGS="${save_LDFLAGS}"
Sam Hocevar's avatar
 
Sam Hocevar committed
8863
    CPROF=1
Sam Hocevar's avatar
Sam Hocevar committed
8864
    PROFILING="cprof"
Sam Hocevar's avatar
 
Sam Hocevar committed
8865 8866
  fi

8867 8868
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8869 8870 8871 8872

# Check whether --enable-pth or --disable-pth was given.
if test "${enable_pth+set}" = set; then
  enableval="$enable_pth"
8873
   if test "x${enable_pth}" = "xyes"; then
8874
    echo $ac_n "checking for pth_init in -lpth""... $ac_c" 1>&6
8875
echo "configure:8876: checking for pth_init in -lpth" >&5
8876 8877 8878
ac_lib_var=`echo pth'_'pth_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8879
else
8880
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
8881
LIBS="-lpth  $LIBS"
8882
cat > conftest.$ac_ext <<EOF
8883
#line 8884 "configure"
Henri Fallon's avatar
 
Henri Fallon committed
8884
#include "confdefs.h"
Sam Hocevar's avatar
 
Sam Hocevar committed
8885 8886
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
8887 8888 8889 8890 8891 8892 8893
    builtin and then its argument prototype would still apply.  */
char pth_init();

int main() {
pth_init()
; return 0; }
EOF
8894
if { (eval echo configure:8895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8895 8896 8897 8898 8899 8900 8901 8902 8903 8904 8905 8906 8907 8908 8909 8910 8911 8912 8913
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_lib=HAVE_LIB`echo pth | sed -e 's/[^a-zA-Z0-9_]/_/g' \
    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
  cat >> confdefs.h <<EOF
#define $ac_tr_lib 1
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
8914 8915 8916

  LIBS="-lpth $LIBS"

8917 8918
else
  echo "$ac_t""no" 1>&6
Sam Hocevar's avatar
 
Sam Hocevar committed
8919 8920
fi

8921
    cat > conftest.$ac_ext <<EOF
8922
#line 8923 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
8923 8924
#include "confdefs.h"
#include <pth.h>
8925
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
8926 8927
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "pth_init" >/dev/null 2>&1; then
8928 8929 8930
  rm -rf conftest*
  
      cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
8931
#define PTH_INIT_IN_PTH_H 1
8932
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
8933 8934 8935 8936 8937 8938 8939

    THREAD_LIB="-lpth"
    fi
fi
rm -f conftest*


8940 8941
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
8942 8943 8944 8945

# Check whether --enable-st or --disable-st was given.
if test "${enable_st+set}" = set; then
  enableval="$enable_st"
8946
   if test "x${enable_st}" = "xyes"; then
8947
    echo $ac_n "checking for st_init in -lst""... $ac_c" 1>&6
8948
echo "configure:8949: checking for st_init in -lst" >&5
8949 8950 8951
ac_lib_var=`echo st'_'st_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
Henri Fallon's avatar
 
Henri Fallon committed
8952
else
8953
  ac_save_LIBS="$LIBS"
Sam Hocevar's avatar
 
Sam Hocevar committed
8954
LIBS="-lst  $LIBS"
8955
cat > conftest.$ac_ext <<EOF
8956
#line 8957 "configure"
Henri Fallon's avatar
 
Henri Fallon committed
8957
#include "confdefs.h"
Sam Hocevar's avatar
 
Sam Hocevar committed
8958 8959
/* Override any gcc2 internal prototype to avoid an error.  */
/* We use char because int might match the return type of a gcc2
8960 8961 8962 8963 8964 8965 8966
    builtin and then its argument prototype would still apply.  */
char st_init();

int main() {
st_init()
; return 0; }
EOF
8967
if { (eval echo configure:8968: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
8968 8969 8970 8971 8972 8973 8974 8975 8976 8977 8978 8979 8980 8981 8982 8983 8984 8985 8986
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=yes"
else
  echo "configure: failed program was:" >&5
  cat conftest.$ac_ext >&5
  rm -rf conftest*
  eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
LIBS="$ac_save_LIBS"

fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
  echo "$ac_t""yes" 1>&6
    ac_tr_lib=HAVE_LIB`echo st | sed -e 's/[^a-zA-Z0-9_]/_/g' \
    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
  cat >> confdefs.h <<EOF
#define $ac_tr_lib 1
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
8987 8988

  LIBS="-lst $LIBS"
Henri Fallon's avatar
 
Henri Fallon committed
8989

8990 8991
else
  echo "$ac_t""no" 1>&6
Henri Fallon's avatar
 
Henri Fallon committed
8992
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
8993

8994
    cat > conftest.$ac_ext <<EOF
8995
#line 8996 "configure"
Sam Hocevar's avatar
 
Sam Hocevar committed
8996 8997
#include "confdefs.h"
#include <st.h>
8998
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
8999 9000
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  egrep "st_init" >/dev/null 2>&1; then
9001 9002 9003
  rm -rf conftest*
  
      cat >> confdefs.h <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
9004
#define ST_INIT_IN_ST_H 1
9005
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
9006 9007 9008

    THREAD_LIB="-lst"
    fi
Sam Hocevar's avatar
 
Sam Hocevar committed
9009
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
9010
rm -f conftest*
Sam Hocevar's avatar
 
Sam Hocevar committed
9011

Sam Hocevar's avatar
 
Sam Hocevar committed
9012

9013 9014
fi

Sam Hocevar's avatar
 
Sam Hocevar committed
9015

Sam Hocevar's avatar
Sam Hocevar committed
9016 9017
vlc_LDFLAGS="${vlc_LDFLAGS} ${THREAD_LIB}"
plugins_LDFLAGS="${plugins_LDFLAGS} ${THREAD_LIB}"
Sam Hocevar's avatar
 
Sam Hocevar committed
9018

9019 9020 9021 9022 9023 9024 9025
MOZILLA=0
# Check whether --enable-mozilla or --disable-mozilla was given.
if test "${enable_mozilla+set}" = set; then
  enableval="$enable_mozilla"
  :
fi

9026
if test "x${enable_mozilla}" = "xyes"
9027 9028 9029 9030
then
  # Extract the first word of "mozilla-config", so it can be a program name with args.
set dummy mozilla-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
9031
echo "configure:9032: checking for $ac_word" >&5
9032 9033 9034 9035 9036 9037 9038 9039 9040 9041 9042 9043 9044 9045 9046 9047 9048 9049 9050 9051 9052 9053 9054 9055 9056 9057 9058 9059 9060 9061 9062 9063
if eval "test \"`echo '$''{'ac_cv_path_MOZILLA_CONFIG'+set}'`\" = set"; then
  echo $ac_n "(cached) $ac_c" 1>&6
else
  case "$MOZILLA_CONFIG" in
  /*)
  ac_cv_path_MOZILLA_CONFIG="$MOZILLA_CONFIG" # Let the user override the test with a path.
  ;;
  ?:/*)			 
  ac_cv_path_MOZILLA_CONFIG="$MOZILLA_CONFIG" # Let the user override the test with a dos path.
  ;;
  *)
  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
  ac_dummy="$PATH"
  for ac_dir in $ac_dummy; do 
    test -z "$ac_dir" && ac_dir=.
    if test -f $ac_dir/$ac_word; then
      ac_cv_path_MOZILLA_CONFIG="$ac_dir/$ac_word"
      break
    fi
  done
  IFS="$ac_save_ifs"
  test -z "$ac_cv_path_MOZILLA_CONFIG" && ac_cv_path_MOZILLA_CONFIG="no"
  ;;
esac
fi
MOZILLA_CONFIG="$ac_cv_path_MOZILLA_CONFIG"
if test -n "$MOZILLA_CONFIG"; then
  echo "$ac_t""$MOZILLA_CONFIG" 1>&6
else
  echo "$ac_t""no" 1>&6
fi

9064
  if test "x${MOZILLA_CONFIG}" != "xno"
9065 9066 9067 9068 9069 9070 9071
  then
    MOZILLA=1
    mozilla_CFLAGS="${mozilla_CFLAGS} `${MOZILLA_CONFIG} --cflags plugin java --defines | xargs`"
    mozilla_LDFLAGS="${mozilla_LDFLAGS} `${MOZILLA_CONFIG} --libs `"
  fi
fi

9072 9073 9074
# Check whether --enable-plugins or --disable-plugins was given.
if test "${enable_plugins+set}" = set; then
  enableval="$enable_plugins"
9075
  if test "x${enable_plugins}" = "xno"
9076 9077 9078 9079
   then
     BUILTINS="${BUILTINS} ${PLUGINS}"
     PLUGINS=
   fi
9080 9081
fi

9082

9083
if test "x${ac_cv_header_dlfcn_h}" = "xno" -a "x${ac_cv_header_image_h}" = "xno" -a "x${SYS}" != "xmingw32"
9084 9085 9086 9087 9088 9089 9090
then
  echo "*** Your system doesn't have plug-in support. All plug-ins will be compiled"
  echo "as built-in"
  BUILTINS="${BUILTINS} ${PLUGINS}"
  PLUGINS=
fi

9091
cat >> confdefs.h <<EOF
9092
#define VERSION_MESSAGE "vlc ${VERSION} ${CODENAME} Copyright 1996-2002 VideoLAN"
9093
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
9094

9095
cat >> confdefs.h <<EOF
9096
#define COPYRIGHT_MESSAGE "VideoLAN Client - version ${VERSION} ${CODENAME} - (c) 1996-2002 VideoLAN"
9097
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
9098

Sam Hocevar's avatar
Sam Hocevar committed
9099
cat >> confdefs.h <<EOF
9100
#define CONFIGURE_LINE "${CONFIGURE_LINE}"
Sam Hocevar's avatar
Sam Hocevar committed
9101 9102
EOF

Sam Hocevar's avatar
 
Sam Hocevar committed
9103

Sam Hocevar's avatar
 
Sam Hocevar committed
9104
VLC_SYMBOL="`echo ${VERSION} | tr .- __`"
9105
cat >> confdefs.h <<EOF
9106
#define MODULE_SUFFIX "__MODULE_${VLC_SYMBOL}"
9107
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
9108

9109
cat >> confdefs.h <<EOF
9110
#define MODULE_SYMBOL ${VLC_SYMBOL}
9111
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
9112 9113 9114 9115 9116 9117 9118


DATA_PATH="${ac_tool_prefix}/share/videolan"

PLUGIN_PATH="${ac_tool_prefix}/share/videolan"


Sam Hocevar's avatar
Sam Hocevar committed
9119 9120 9121 9122
CPPFLAGS="${save_CPPFLAGS}"
CFLAGS="${save_CFLAGS}"
LDFLAGS="${save_LDFLAGS}"

9123 9124 9125 9126
libvlc_LDFLAGS="${vlc_LDFLAGS} ${builtins_LDFLAGS}"
for i in ${BUILTINS} ; do libvlc_LDFLAGS="${libvlc_LDFLAGS} `eval echo '$'{${i}_LDFLAGS}`" ; done


Sam Hocevar's avatar
Sam Hocevar committed
9127

9128

9129 9130 9131 9132 9133





Henri Fallon's avatar
 
Henri Fallon committed
9134 9135 9136



Christophe Massiot's avatar
Christophe Massiot committed
9137 9138 9139



Sam Hocevar's avatar
 
Sam Hocevar committed
9140 9141 9142 9143 9144 9145 9146 9147 9148 9149 9150 9151 9152 9153














Sam Hocevar's avatar
 
Sam Hocevar committed
9154

Sam Hocevar's avatar
 
Sam Hocevar committed
9155

Sam Hocevar's avatar
 
Sam Hocevar committed
9156 9157 9158 9159




Sam Hocevar's avatar
 
Sam Hocevar committed
9160

Sam Hocevar's avatar
 
Sam Hocevar committed
9161 9162


9163

Sam Hocevar's avatar
 
Sam Hocevar committed
9164

Sam Hocevar's avatar
 
Sam Hocevar committed
9165

Sam Hocevar's avatar
 
Sam Hocevar committed
9166

Sam Hocevar's avatar
 
Sam Hocevar committed
9167

Sam Hocevar's avatar
 
Sam Hocevar committed
9168

Sam Hocevar's avatar
 
Sam Hocevar committed
9169 9170 9171



Sam Hocevar's avatar
 
Sam Hocevar committed
9172

Sam Hocevar's avatar
 
Sam Hocevar committed
9173

Sam Hocevar's avatar
 
Sam Hocevar committed
9174

Sam Hocevar's avatar
 
Sam Hocevar committed
9175

Sam Hocevar's avatar
 
Sam Hocevar committed
9176

Sam Hocevar's avatar
 
Sam Hocevar committed
9177 9178


9179

Sam Hocevar's avatar
 
Sam Hocevar committed
9180

Sam Hocevar's avatar
 
Sam Hocevar committed
9181 9182 9183



9184 9185


Sam Hocevar's avatar
 
Sam Hocevar committed
9186 9187 9188



Stéphane Borel's avatar
Stéphane Borel committed
9189 9190 9191



9192

9193

9194

Sam Hocevar's avatar
 
Sam Hocevar committed
9195 9196 9197 9198 9199 9200 9201 9202 9203









9204

Sam Hocevar's avatar
 
Sam Hocevar committed
9205 9206


Sam Hocevar's avatar
 
Sam Hocevar committed
9207

Sam Hocevar's avatar
 
Sam Hocevar committed
9208

9209 9210


Sam Hocevar's avatar
 
Sam Hocevar committed
9211 9212


9213 9214


9215 9216


Sam Hocevar's avatar
 
Sam Hocevar committed
9217

Gildas Bazin's avatar
 
Gildas Bazin committed
9218

Gildas Bazin's avatar
 
Gildas Bazin committed
9219

9220 9221 9222



9223

9224

9225 9226


9227

9228

Sam Hocevar's avatar
 
Sam Hocevar committed
9229

9230 9231
trap '' 1 2 15
cat > confcache <<\EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
9232 9233
# This file is a shell script that caches the results of configure
# tests run on this system so they can be shared between configure
9234 9235
# scripts and configure runs.  It is not useful on other systems.
# If it contains results you don't want to keep, you may remove or edit it.
Sam Hocevar's avatar
 
Sam Hocevar committed
9236
#
9237 9238 9239 9240 9241 9242 9243 9244
# By default, configure uses ./config.cache as the cache file,
# creating it if it does not exist already.  You can give configure
# the --cache-file=FILE option to use a different cache file; that is
# what configure does when it calls configure scripts in
# subdirectories, so they share the cache.
# Giving --cache-file=/dev/null disables caching, for debugging configure.
# config.status only pays attention to the cache file if you give it the
# --recheck option to rerun configure.
Sam Hocevar's avatar
 
Sam Hocevar committed
9245
#
9246
EOF
Sam Hocevar's avatar
 
Sam Hocevar committed
9247 9248 9249 9250 9251
# The following way of writing the cache mishandles newlines in values,
# but we know of no workaround that is simple, portable, and efficient.
# So, don't put newlines in cache variables' values.
# Ultrix sh set writes to stderr and can't be redirected directly,
# and sets the high bit in the cache file unless we assign to the vars.
9252 9253 9254 9255 9256 9257 9258 9259 9260 9261 9262 9263 9264 9265 9266 9267 9268
(set) 2>&1 |
  case `(ac_space=' '; set | grep ac_space) 2>&1` in
  *ac_space=\ *)
    # `set' does not quote correctly, so add quotes (double-quote substitution
    # turns \\\\ into \\, and sed turns \\ into \).
    sed -n \
      -e "s/'/'\\\\''/g" \
      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
    ;;
  *)
    # `set' quotes correctly as required by POSIX, so do not add quotes.
    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
    ;;
  esac >> confcache
if cmp -s $cache_file confcache; then
  :
else
Sam Hocevar's avatar
 
Sam Hocevar committed
9269
  if test -w $cache_file; then
9270 9271
    echo "updating cache $cache_file"
    cat confcache > $cache_file
Sam Hocevar's avatar
 
Sam Hocevar committed
9272 9273 9274
  else
    echo "not updating unwritable cache $cache_file"
  fi
9275
fi
Sam Hocevar's avatar
 
Sam Hocevar committed
9276
rm -f confcache
9277

9278 9279
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15

Sam Hocevar's avatar
 
Sam Hocevar committed
9280 9281 9282
test "x$prefix" = xNONE && prefix=$ac_default_prefix
# Let make expand exec_prefix.
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
9283

9284 9285 9286
# Any assignment to VPATH causes Sun make to only execute
# the first set of double-colon rules, so remove it if not needed.
# If there is a colon in the path, we need to keep it.
Sam Hocevar's avatar
 
Sam Hocevar committed
9287
if test "x$srcdir" = x.; then
9288
  ac_vpsub='/^[ 	]*VPATH[ 	]*=[^:]*$/d'
Sam Hocevar's avatar
 
Sam Hocevar committed
9289 9290
fi

9291
trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
9292

9293
DEFS=-DHAVE_CONFIG_H
9294

9295
# Without the "./", some shells look in PATH for config.status.
9296 9297
: ${CONFIG_STATUS=./config.status}

9298 9299 9300 9301 9302 9303 9304 9305
echo creating $CONFIG_STATUS
rm -f $CONFIG_STATUS
cat > $CONFIG_STATUS <<EOF
#! /bin/sh
# Generated automatically by configure.
# Run this file to recreate the current configuration.
# This directory was configured as follows,
# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
9306
#
9307
# $0 $ac_configure_args
9308
#
9309 9310
# Compiler output produced by configure, useful for debugging
# configure, is in ./config.log if it exists.
9311

9312 9313
ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
for ac_option
9314
do
9315 9316 9317 9318 9319 9320 9321 9322 9323 9324
  case "\$ac_option" in
  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
    echo "$CONFIG_STATUS generated by autoconf version 2.13"
    exit 0 ;;
  -help | --help | --hel | --he | --h)
    echo "\$ac_cs_usage"; exit 0 ;;
  *) echo "\$ac_cs_usage"; exit 1 ;;
9325 9326 9327
  esac
done

9328 9329
ac_given_srcdir=$srcdir
ac_given_INSTALL="$INSTALL"
9330

9331
trap 'rm -fr `echo "Makefile.config Makefile.opts po/Makefile.in vlc-config include/defs.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
9332 9333
EOF
cat >> $CONFIG_STATUS <<EOF
9334

9335 9336 9337 9338 9339 9340 9341 9342 9343 9344 9345 9346 9347 9348 9349 9350 9351 9352 9353 9354 9355 9356 9357 9358 9359 9360 9361 9362 9363 9364 9365 9366 9367 9368 9369 9370 9371 9372 9373 9374 9375 9376 9377 9378 9379 9380 9381 9382 9383 9384 9385 9386 9387 9388 9389 9390 9391 9392 9393 9394 9395 9396 9397 9398 9399 9400 9401 9402 9403 9404 9405 9406 9407 9408 9409 9410 9411 9412 9413 9414 9415 9416 9417
# Protect against being on the right side of a sed subst in config.status.
sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
$ac_vpsub
$extrasub
s%@SHELL@%$SHELL%g
s%@CFLAGS@%$CFLAGS%g
s%@CPPFLAGS@%$CPPFLAGS%g
s%@CXXFLAGS@%$CXXFLAGS%g
s%@FFLAGS@%$FFLAGS%g
s%@DEFS@%$DEFS%g
s%@LDFLAGS@%$LDFLAGS%g
s%@LIBS@%$LIBS%g
s%@exec_prefix@%$exec_prefix%g
s%@prefix@%$prefix%g
s%@program_transform_name@%$program_transform_name%g
s%@bindir@%$bindir%g
s%@sbindir@%$sbindir%g
s%@libexecdir@%$libexecdir%g
s%@datadir@%$datadir%g
s%@sysconfdir@%$sysconfdir%g
s%@sharedstatedir@%$sharedstatedir%g
s%@localstatedir@%$localstatedir%g
s%@libdir@%$libdir%g
s%@includedir@%$includedir%g
s%@oldincludedir@%$oldincludedir%g
s%@infodir@%$infodir%g
s%@mandir@%$mandir%g
s%@host@%$host%g
s%@host_alias@%$host_alias%g
s%@host_cpu@%$host_cpu%g
s%@host_vendor@%$host_vendor%g
s%@host_os@%$host_os%g
s%@target@%$target%g
s%@target_alias@%$target_alias%g
s%@target_cpu@%$target_cpu%g
s%@target_vendor@%$target_vendor%g
s%@target_os@%$target_os%g
s%@build@%$build%g
s%@build_alias@%$build_alias%g
s%@build_cpu@%$build_cpu%g
s%@build_vendor@%$build_vendor%g
s%@build_os@%$build_os%g
s%@SET_MAKE@%$SET_MAKE%g
s%@CC@%$CC%g
s%@CPP@%$CPP%g
s%@RANLIB@%$RANLIB%g
s%@STRIP@%$STRIP%g
s%@GMAKE@%$GMAKE%g
s%@ALLOCA@%$ALLOCA%g
s%@GLIBC21@%$GLIBC21%g
s%@LIBICONV@%$LIBICONV%g
s%@USE_NLS@%$USE_NLS%g
s%@MSGFMT@%$MSGFMT%g
s%@GMSGFMT@%$GMSGFMT%g
s%@XGETTEXT@%$XGETTEXT%g
s%@INTLBISON@%$INTLBISON%g
s%@BUILD_INCLUDED_LIBINTL@%$BUILD_INCLUDED_LIBINTL%g
s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
s%@CATALOGS@%$CATALOGS%g
s%@CATOBJEXT@%$CATOBJEXT%g
s%@GMOFILES@%$GMOFILES%g
s%@INTLLIBS@%$INTLLIBS%g
s%@INTLOBJS@%$INTLOBJS%g
s%@POFILES@%$POFILES%g
s%@POSUB@%$POSUB%g
s%@DATADIRNAME@%$DATADIRNAME%g
s%@INSTOBJEXT@%$INSTOBJEXT%g
s%@GENCAT@%$GENCAT%g
s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
s%@INTL_LIBTOOL_SUFFIX_PREFIX@%$INTL_LIBTOOL_SUFFIX_PREFIX%g
s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
s%@INSTALL_DATA@%$INSTALL_DATA%g
s%@WINDRES@%$WINDRES%g
s%@SDL12_CONFIG@%$SDL12_CONFIG%g
s%@SDL11_CONFIG@%$SDL11_CONFIG%g
s%@SDL_CONFIG@%$SDL_CONFIG%g
s%@ESD_CONFIG@%$ESD_CONFIG%g
s%@ARTS_CONFIG@%$ARTS_CONFIG%g
s%@GTK12_CONFIG@%$GTK12_CONFIG%g
s%@GTK_CONFIG@%$GTK_CONFIG%g
s%@GNOME_CONFIG@%$GNOME_CONFIG%g
9418
s%@MOZILLA_CONFIG@%$MOZILLA_CONFIG%g
9419 9420
s%@DATA_PATH@%$DATA_PATH%g
s%@PLUGIN_PATH@%$PLUGIN_PATH%g
9421
s%@libvlc_LDFLAGS@%$libvlc_LDFLAGS%g
9422 9423 9424 9425 9426 9427 9428 9429 9430 9431 9432 9433 9434 9435 9436 9437 9438
s%@SYS@%$SYS%g
s%@ARCH@%$ARCH%g
s%@PLUGINS@%$PLUGINS%g
s%@BUILTINS@%$BUILTINS%g
s%@ALIASES@%$ALIASES%g
s%@DEBUG@%$DEBUG%g
s%@ASM@%$ASM%g
s%@CPROF@%$CPROF%g
s%@GPROF@%$GPROF%g
s%@OPTIMS@%$OPTIMS%g
s%@TUNING@%$TUNING%g
s%@RELEASE@%$RELEASE%g
s%@MOC@%$MOC%g
s%@BCBUILDER@%$BCBUILDER%g
s%@PACKAGE@%$PACKAGE%g
s%@VERSION@%$VERSION%g
s%@NEED_GETOPT@%$NEED_GETOPT%g
9439
s%@MOZILLA@%$MOZILLA%g
9440 9441 9442 9443 9444
s%@CFLAGS_OPTIM@%$CFLAGS_OPTIM%g
s%@CFLAGS_OPTIM_NODEBUG@%$CFLAGS_OPTIM_NODEBUG%g
s%@vlc_CFLAGS@%$vlc_CFLAGS%g
s%@plugins_CFLAGS@%$plugins_CFLAGS%g
s%@builtins_CFLAGS@%$builtins_CFLAGS%g
9445
s%@mozilla_CFLAGS@%$mozilla_CFLAGS%g
9446 9447
s%@a52_CFLAGS@%$a52_CFLAGS%g
s%@arts_CFLAGS@%$arts_CFLAGS%g
Sam Hocevar's avatar
Sam Hocevar committed
9448
s%@chroma_i420_yuy2_mmx_CFLAGS@%$chroma_i420_yuy2_mmx_CFLAGS%g
9449 9450 9451 9452 9453
s%@dvd_CFLAGS@%$dvd_CFLAGS%g
s%@dvdread_CFLAGS@%$dvdread_CFLAGS%g
s%@mpeg_ts_dvbpsi_CFLAGS@%$mpeg_ts_dvbpsi_CFLAGS%g
s%@directx_CFLAGS@%$directx_CFLAGS%g
s%@esd_CFLAGS@%$esd_CFLAGS%g
9454
s%@familiar_CFLAGS@%$familiar_CFLAGS%g
9455 9456 9457 9458 9459 9460 9461 9462 9463 9464 9465 9466 9467 9468 9469 9470 9471
s%@ffmpeg_CFLAGS@%$ffmpeg_CFLAGS%g
s%@glide_CFLAGS@%$glide_CFLAGS%g
s%@gnome_CFLAGS@%$gnome_CFLAGS%g
s%@gtk_CFLAGS@%$gtk_CFLAGS%g
s%@kde_CFLAGS@%$kde_CFLAGS%g
s%@idctaltivec_CFLAGS@%$idctaltivec_CFLAGS%g
s%@macosx_CFLAGS@%$macosx_CFLAGS%g
s%@mad_CFLAGS@%$mad_CFLAGS%g
s%@memcpyaltivec_CFLAGS@%$memcpyaltivec_CFLAGS%g
s%@motionaltivec_CFLAGS@%$motionaltivec_CFLAGS%g
s%@qt_CFLAGS@%$qt_CFLAGS%g
s%@sdl_CFLAGS@%$sdl_CFLAGS%g
s%@x11_CFLAGS@%$x11_CFLAGS%g
s%@xvideo_CFLAGS@%$xvideo_CFLAGS%g
s%@vlc_LDFLAGS@%$vlc_LDFLAGS%g
s%@plugins_LDFLAGS@%$plugins_LDFLAGS%g
s%@builtins_LDFLAGS@%$builtins_LDFLAGS%g
9472
s%@mozilla_LDFLAGS@%$mozilla_LDFLAGS%g
9473 9474 9475 9476 9477 9478 9479 9480 9481 9482 9483 9484
s%@a52_LDFLAGS@%$a52_LDFLAGS%g
s%@aa_LDFLAGS@%$aa_LDFLAGS%g
s%@alsa_LDFLAGS@%$alsa_LDFLAGS%g
s%@arts_LDFLAGS@%$arts_LDFLAGS%g
s%@beos_LDFLAGS@%$beos_LDFLAGS%g
s%@chroma_i420_rgb_LDFLAGS@%$chroma_i420_rgb_LDFLAGS%g
s%@directx_LDFLAGS@%$directx_LDFLAGS%g
s%@dsp_LDFLAGS@%$dsp_LDFLAGS%g
s%@dvd_LDFLAGS@%$dvd_LDFLAGS%g
s%@dvdread_LDFLAGS@%$dvdread_LDFLAGS%g
s%@mpeg_ts_dvbpsi_LDFLAGS@%$mpeg_ts_dvbpsi_LDFLAGS%g
s%@esd_LDFLAGS@%$esd_LDFLAGS%g
9485
s%@familiar_LDFLAGS@%$familiar_LDFLAGS%g
9486 9487
s%@filter_distort_LDFLAGS@%$filter_distort_LDFLAGS%g
s%@ffmpeg_LDFLAGS@%$ffmpeg_LDFLAGS%g
9488
s%@mp4_LDFLAGS@%$mp4_LDFLAGS%g
9489 9490 9491 9492
s%@ggi_LDFLAGS@%$ggi_LDFLAGS%g
s%@glide_LDFLAGS@%$glide_LDFLAGS%g
s%@gnome_LDFLAGS@%$gnome_LDFLAGS%g
s%@gtk_LDFLAGS@%$gtk_LDFLAGS%g
9493
s%@http_LDFLAGS@%$http_LDFLAGS%g
9494 9495 9496 9497 9498
s%@idctaltivec_LDFLAGS@%$idctaltivec_LDFLAGS%g
s%@imdct_LDFLAGS@%$imdct_LDFLAGS%g
s%@imdct3dn_LDFLAGS@%$imdct3dn_LDFLAGS%g
s%@imdctsse_LDFLAGS@%$imdctsse_LDFLAGS%g
s%@ipv4_LDFLAGS@%$ipv4_LDFLAGS%g
Gildas Bazin's avatar
 
Gildas Bazin committed
9499
s%@ipv6_LDFLAGS@%$ipv6_LDFLAGS%g
9500 9501 9502 9503 9504 9505 9506 9507 9508 9509 9510 9511 9512 9513 9514 9515
s%@kde_LDFLAGS@%$kde_LDFLAGS%g
s%@lirc_LDFLAGS@%$lirc_LDFLAGS%g
s%@macosx_LDFLAGS@%$macosx_LDFLAGS%g
s%@mad_LDFLAGS@%$mad_LDFLAGS%g
s%@memcpyaltivec_LDFLAGS@%$memcpyaltivec_LDFLAGS%g
s%@motionaltivec_LDFLAGS@%$motionaltivec_LDFLAGS%g
s%@ncurses_LDFLAGS@%$ncurses_LDFLAGS%g
s%@qnx_LDFLAGS@%$qnx_LDFLAGS%g
s%@qt_LDFLAGS@%$qt_LDFLAGS%g
s%@rc_LDFLAGS@%$rc_LDFLAGS%g
s%@sdl_LDFLAGS@%$sdl_LDFLAGS%g
s%@vcd_LDFLAGS@%$vcd_LDFLAGS%g
s%@vorbis_LDFLAGS@%$vorbis_LDFLAGS%g
s%@waveout_LDFLAGS@%$waveout_LDFLAGS%g
s%@x11_LDFLAGS@%$x11_LDFLAGS%g
s%@xvideo_LDFLAGS@%$xvideo_LDFLAGS%g
9516
s%@xosd_LDFLAGS@%$xosd_LDFLAGS%g
9517 9518

CEOF
9519
EOF
9520

9521 9522 9523 9524 9525 9526 9527 9528 9529 9530 9531 9532 9533 9534 9535 9536 9537 9538 9539 9540 9541 9542
cat >> $CONFIG_STATUS <<\EOF

# Split the substitutions into bite-sized pieces for seds with
# small command number limits, like on Digital OSF/1 and HP-UX.
ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
ac_file=1 # Number of current file.
ac_beg=1 # First line for current file.
ac_end=$ac_max_sed_cmds # Line after last line for current file.
ac_more_lines=:
ac_sed_cmds=""
while $ac_more_lines; do
  if test $ac_beg -gt 1; then
    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
  else
    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
  fi
  if test ! -s conftest.s$ac_file; then
    ac_more_lines=false
    rm -f conftest.s$ac_file
  else
    if test -z "$ac_sed_cmds"; then
      ac_sed_cmds="sed -f conftest.s$ac_file"
9543
    else
9544
      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
9545
    fi
9546 9547 9548
    ac_file=`expr $ac_file + 1`
    ac_beg=$ac_end
    ac_end=`expr $ac_end + $ac_max_sed_cmds`
9549
  fi
9550 9551 9552 9553 9554
done
if test -z "$ac_sed_cmds"; then
  ac_sed_cmds=cat
fi
EOF
9555

9556
cat >> $CONFIG_STATUS <<EOF
9557

9558
CONFIG_FILES=\${CONFIG_FILES-"Makefile.config Makefile.opts po/Makefile.in vlc-config"}
9559 9560 9561 9562 9563 9564 9565 9566
EOF
cat >> $CONFIG_STATUS <<\EOF
for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
  case "$ac_file" in
  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
  *) ac_file_in="${ac_file}.in" ;;
9567 9568
  esac

9569
  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
9570

9571 9572 9573 9574 9575 9576 9577 9578 9579 9580 9581
  # Remove last slash and all that follows it.  Not all systems have dirname.
  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
    # The file is in a subdirectory.
    test ! -d "$ac_dir" && mkdir "$ac_dir"
    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
    # A "../" for each directory in $ac_dir_suffix.
    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
  else
    ac_dir_suffix= ac_dots=
  fi
9582

9583 9584 9585 9586 9587
  case "$ac_given_srcdir" in
  .)  srcdir=.
      if test -z "$ac_dots"; then top_srcdir=.
      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
9588
  *) # Relative path.
9589 9590
    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
    top_srcdir="$ac_dots$ac_given_srcdir" ;;
Sam Hocevar's avatar
 
Sam Hocevar committed
9591
  esac
9592

9593 9594 9595 9596
  case "$ac_given_INSTALL" in
  [/$]*) INSTALL="$ac_given_INSTALL" ;;
  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
  esac
9597

9598 9599 9600 9601 9602 9603 9604 9605
  echo creating "$ac_file"
  rm -f "$ac_file"
  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
  case "$ac_file" in
  *Makefile*) ac_comsub="1i\\
# $configure_input" ;;
  *) ac_comsub= ;;
  esac
9606

9607 9608 9609 9610 9611 9612 9613 9614 9615
  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
  sed -e "$ac_comsub
s%@configure_input@%$configure_input%g
s%@srcdir@%$srcdir%g
s%@top_srcdir@%$top_srcdir%g
s%@INSTALL@%$INSTALL%g
" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
fi; done
rm -f conftest.s*
9616 9617 9618 9619 9620

# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
# NAME is the cpp macro being defined and VALUE is the value it is being given.
#
# ac_d sets the value in "#define NAME VALUE" lines.
9621 9622 9623 9624 9625 9626 9627
ac_dA='s%^\([ 	]*\)#\([ 	]*define[ 	][ 	]*\)'
ac_dB='\([ 	][ 	]*\)[^ 	]*%\1#\2'
ac_dC='\3'
ac_dD='%g'
# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
ac_uA='s%^\([ 	]*\)#\([ 	]*\)undef\([ 	][ 	]*\)'
ac_uB='\([ 	]\)%\1#\2define\3'
9628
ac_uC=' '
9629 9630 9631 9632 9633 9634 9635 9636 9637 9638 9639 9640 9641 9642 9643
ac_uD='\4%g'
# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
ac_eA='s%^\([ 	]*\)#\([ 	]*\)undef\([ 	][ 	]*\)'
ac_eB='$%\1#\2define\3'
ac_eC=' '
ac_eD='%g'

if test "${CONFIG_HEADERS+set}" != set; then
EOF
cat >> $CONFIG_STATUS <<EOF
  CONFIG_HEADERS="include/defs.h"
EOF
cat >> $CONFIG_STATUS <<\EOF
fi
for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
9644
  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
9645 9646 9647 9648
  case "$ac_file" in
  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
  *) ac_file_in="${ac_file}.in" ;;
9649 9650
  esac

9651 9652 9653 9654 9655 9656 9657 9658 9659 9660 9661 9662 9663 9664 9665 9666 9667 9668 9669 9670 9671 9672
  echo creating $ac_file

  rm -f conftest.frag conftest.in conftest.out
  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
  cat $ac_file_inputs > conftest.in

EOF

# Transform confdefs.h into a sed script conftest.vals that substitutes
# the proper values into config.h.in to produce config.h.  And first:
# Protect against being on the right side of a sed subst in config.status.
# Protect against being in an unquoted here document in config.status.
rm -f conftest.vals
cat > conftest.hdr <<\EOF
s/[\\&%]/\\&/g
s%[\\$`]%\\&%g
s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
s%ac_d%ac_u%gp
s%ac_u%ac_e%gp
EOF
sed -n -f conftest.hdr confdefs.h > conftest.vals
rm -f conftest.hdr
9673 9674 9675 9676

# This sed command replaces #undef with comments.  This is necessary, for
# example, in the case of _POSIX_SOURCE, which is predefined and required
# on some systems where configure will not decide to define it.
9677 9678 9679 9680 9681 9682
cat >> conftest.vals <<\EOF
s%^[ 	]*#[ 	]*undef[ 	][ 	]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
EOF

# Break up conftest.vals because some shells have a limit on
# the size of here documents, and old seds have small limits too.
9683 9684

rm -f conftest.tail
9685
while :
9686
do
9687 9688 9689 9690 9691 9692
  ac_lines=`grep -c . conftest.vals`
  # grep -c gives empty output for an empty file on some AIX systems.
  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
  # Write a limited-size here document to conftest.frag.
  echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
9693
  echo 'CEOF
9694 9695 9696 9697 9698 9699 9700
  sed -f conftest.frag conftest.in > conftest.out
  rm -f conftest.in
  mv conftest.out conftest.in
' >> $CONFIG_STATUS
  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
  rm -f conftest.vals
  mv conftest.tail conftest.vals
9701
done
9702 9703 9704 9705 9706 9707 9708 9709 9710 9711
rm -f conftest.vals

cat >> $CONFIG_STATUS <<\EOF
  rm -f conftest.frag conftest.h
  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
  cat conftest.in >> conftest.h
  rm -f conftest.in
  if cmp -s $ac_file conftest.h 2>/dev/null; then
    echo "$ac_file is unchanged"
    rm -f conftest.h
9712
  else
9713 9714 9715 9716 9717
    # Remove last slash and all that follows it.  Not all systems have dirname.
      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
      # The file is in a subdirectory.
      test ! -d "$ac_dir" && mkdir "$ac_dir"
9718
    fi
9719 9720
    rm -f $ac_file
    mv conftest.h $ac_file
9721
  fi
9722
fi; done
Sam Hocevar's avatar
 
Sam Hocevar committed
9723

9724 9725 9726 9727 9728 9729 9730
EOF
cat >> $CONFIG_STATUS <<EOF


EOF
cat >> $CONFIG_STATUS <<\EOF
for ac_file in $CONFIG_FILES; do
Sam Hocevar's avatar
 
Sam Hocevar committed
9731 9732 9733 9734 9735 9736 9737 9738 9739 9740 9741 9742 9743 9744 9745 9746 9747 9748 9749 9750 9751 9752 9753 9754 9755 9756 9757
        # Support "outfile[:infile[:infile...]]"
        case "$ac_file" in
          *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
        esac
        # PO directories have a Makefile.in generated from Makefile.in.in.
        case "$ac_file" in */Makefile.in)
          # Adjust a relative srcdir.
          ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
          ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
          ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
          # In autoconf-2.13 it is called $ac_given_srcdir.
          # In autoconf-2.50 it is called $srcdir.
          test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
          case "$ac_given_srcdir" in
            .)  top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
            /*) top_srcdir="$ac_given_srcdir" ;;
            *)  top_srcdir="$ac_dots$ac_given_srcdir" ;;
          esac
          if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
            rm -f "$ac_dir/POTFILES"
            test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
            sed -e "/^#/d" -e "/^[ 	]*\$/d" -e "s,.*,     $top_srcdir/& \\\\," -e "\$s/\(.*\) \\\\/\1/" < "$ac_given_srcdir/$ac_dir/POTFILES.in" > "$ac_dir/POTFILES"
            test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
            sed -e "/POTFILES =/r $ac_dir/POTFILES" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
          fi
          ;;
        esac
9758
      done
9759

9760 9761
exit 0
EOF
9762
chmod +x $CONFIG_STATUS
9763 9764
rm -fr confdefs* $ac_clean_files
test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
Sam Hocevar's avatar
 
Sam Hocevar committed
9765

9766
chmod a+x vlc-config
9767

9768
echo "
Sam Hocevar's avatar
 
Sam Hocevar committed
9769
vlc configuration
Sam Hocevar's avatar
 
Sam Hocevar committed
9770
--------------------
Sam Hocevar's avatar
 
Sam Hocevar committed
9771
vlc version           : ${VERSION}
Sam Hocevar's avatar
 
Sam Hocevar committed
9772 9773
system                : ${SYS}
architecture          : ${ARCH}
9774
optimizations         : ${OPTIMS}
Sam Hocevar's avatar
 
Sam Hocevar committed
9775
tuning                : ${TUNING}
9776
debug mode            : ${DEBUG}
Sam Hocevar's avatar
 
Sam Hocevar committed
9777
release               : ${RELEASE}
Sam Hocevar's avatar
Sam Hocevar committed
9778
profiling             : ${PROFILING}
Sam Hocevar's avatar
 
Sam Hocevar committed
9779
need builtin getopt   : ${NEED_GETOPT}
Sam Hocevar's avatar
 
Sam Hocevar committed
9780
built-in modules      :${BUILTINS}
9781
plug-in modules       :${PLUGINS}
9782
mozilla plugin        : ${MOZILLA}
Sam Hocevar's avatar
 
Sam Hocevar committed
9783
vlc aliases           :${ALIASES}
Sam Hocevar's avatar
 
Sam Hocevar committed
9784

Sam Hocevar's avatar
 
Sam Hocevar committed
9785 9786
You may now tune Makefile.opts at your convenience, for instance to choose
which modules get compiled as plugins.
Sam Hocevar's avatar
 
Sam Hocevar committed
9787

9788
To build vlc and its plugins, type \`${VLC_MAKE}'.
Sam Hocevar's avatar
 
Sam Hocevar committed
9789
"
9790