~gunchleoc/widelands/bug-1818494-ingame-zoom-freezes

« back to all changes in this revision

Viewing changes to configure

  • Committer: sirver
  • Date: 2002-02-05 20:54:08 UTC
  • Revision ID: git-v1:df384fd3a5e53be1f37803d1c0381fa993844bf5
Initial revision


git-svn-id: https://widelands.svn.sourceforge.net/svnroot/widelands/trunk@2 37b2a8de-5219-0410-9f54-a31bc463ab9c

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#! /bin/sh
 
2
 
 
3
# Guess values for system-dependent variables and create Makefiles.
 
4
# Generated automatically using autoconf version 2.13 
 
5
# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
 
6
#
 
7
# This configure script is free software; the Free Software Foundation
 
8
# gives unlimited permission to copy, distribute and modify it.
 
9
 
 
10
# Defaults:
 
11
ac_help=
 
12
ac_default_prefix=/usr/local
 
13
# Any additions from configure.in:
 
14
ac_help="$ac_help
 
15
  --enable-libsdl    Use libsdl (yes)"
 
16
ac_help="$ac_help
 
17
  --with-sdl-prefix=PFX   Prefix where SDL is installed (optional)"
 
18
ac_help="$ac_help
 
19
  --with-sdl-exec-prefix=PFX Exec prefix where SDL is installed (optional)"
 
20
ac_help="$ac_help
 
21
  --disable-sdltest       Do not try to compile and run a test SDL program"
 
22
 
 
23
# Initialize some variables set by options.
 
24
# The variables have the same names as the options, with
 
25
# dashes changed to underlines.
 
26
build=NONE
 
27
cache_file=./config.cache
 
28
exec_prefix=NONE
 
29
host=NONE
 
30
no_create=
 
31
nonopt=NONE
 
32
no_recursion=
 
33
prefix=NONE
 
34
program_prefix=NONE
 
35
program_suffix=NONE
 
36
program_transform_name=s,x,x,
 
37
silent=
 
38
site=
 
39
srcdir=
 
40
target=NONE
 
41
verbose=
 
42
x_includes=NONE
 
43
x_libraries=NONE
 
44
bindir='${exec_prefix}/bin'
 
45
sbindir='${exec_prefix}/sbin'
 
46
libexecdir='${exec_prefix}/libexec'
 
47
datadir='${prefix}/share'
 
48
sysconfdir='${prefix}/etc'
 
49
sharedstatedir='${prefix}/com'
 
50
localstatedir='${prefix}/var'
 
51
libdir='${exec_prefix}/lib'
 
52
includedir='${prefix}/include'
 
53
oldincludedir='/usr/include'
 
54
infodir='${prefix}/info'
 
55
mandir='${prefix}/man'
 
56
 
 
57
# Initialize some other variables.
 
58
subdirs=
 
59
MFLAGS= MAKEFLAGS=
 
60
SHELL=${CONFIG_SHELL-/bin/sh}
 
61
# Maximum number of lines to put in a shell here document.
 
62
ac_max_here_lines=12
 
63
 
 
64
ac_prev=
 
65
for ac_option
 
66
do
 
67
 
 
68
  # If the previous option needs an argument, assign it.
 
69
  if test -n "$ac_prev"; then
 
70
    eval "$ac_prev=\$ac_option"
 
71
    ac_prev=
 
72
    continue
 
73
  fi
 
74
 
 
75
  case "$ac_option" in
 
76
  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
 
77
  *) ac_optarg= ;;
 
78
  esac
 
79
 
 
80
  # Accept the important Cygnus configure options, so we can diagnose typos.
 
81
 
 
82
  case "$ac_option" in
 
83
 
 
84
  -bindir | --bindir | --bindi | --bind | --bin | --bi)
 
85
    ac_prev=bindir ;;
 
86
  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
 
87
    bindir="$ac_optarg" ;;
 
88
 
 
89
  -build | --build | --buil | --bui | --bu)
 
90
    ac_prev=build ;;
 
91
  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
 
92
    build="$ac_optarg" ;;
 
93
 
 
94
  -cache-file | --cache-file | --cache-fil | --cache-fi \
 
95
  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
 
96
    ac_prev=cache_file ;;
 
97
  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
 
98
  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
 
99
    cache_file="$ac_optarg" ;;
 
100
 
 
101
  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
 
102
    ac_prev=datadir ;;
 
103
  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
 
104
  | --da=*)
 
105
    datadir="$ac_optarg" ;;
 
106
 
 
107
  -disable-* | --disable-*)
 
108
    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
 
109
    # Reject names that are not valid shell variable names.
 
110
    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
 
111
      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
 
112
    fi
 
113
    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
 
114
    eval "enable_${ac_feature}=no" ;;
 
115
 
 
116
  -enable-* | --enable-*)
 
117
    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
 
118
    # Reject names that are not valid shell variable names.
 
119
    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
 
120
      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
 
121
    fi
 
122
    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
 
123
    case "$ac_option" in
 
124
      *=*) ;;
 
125
      *) ac_optarg=yes ;;
 
126
    esac
 
127
    eval "enable_${ac_feature}='$ac_optarg'" ;;
 
128
 
 
129
  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
 
130
  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
 
131
  | --exec | --exe | --ex)
 
132
    ac_prev=exec_prefix ;;
 
133
  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
 
134
  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
 
135
  | --exec=* | --exe=* | --ex=*)
 
136
    exec_prefix="$ac_optarg" ;;
 
137
 
 
138
  -gas | --gas | --ga | --g)
 
139
    # Obsolete; use --with-gas.
 
140
    with_gas=yes ;;
 
141
 
 
142
  -help | --help | --hel | --he)
 
143
    # Omit some internal or obsolete options to make the list less imposing.
 
144
    # This message is too long to be a string in the A/UX 3.1 sh.
 
145
    cat << EOF
 
146
Usage: configure [options] [host]
 
147
Options: [defaults in brackets after descriptions]
 
148
Configuration:
 
149
  --cache-file=FILE       cache test results in FILE
 
150
  --help                  print this message
 
151
  --no-create             do not create output files
 
152
  --quiet, --silent       do not print \`checking...' messages
 
153
  --version               print the version of autoconf that created configure
 
154
Directory and file names:
 
155
  --prefix=PREFIX         install architecture-independent files in PREFIX
 
156
                          [$ac_default_prefix]
 
157
  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
 
158
                          [same as prefix]
 
159
  --bindir=DIR            user executables in DIR [EPREFIX/bin]
 
160
  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
 
161
  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
 
162
  --datadir=DIR           read-only architecture-independent data in DIR
 
163
                          [PREFIX/share]
 
164
  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
 
165
  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
 
166
                          [PREFIX/com]
 
167
  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
 
168
  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
 
169
  --includedir=DIR        C header files in DIR [PREFIX/include]
 
170
  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
 
171
  --infodir=DIR           info documentation in DIR [PREFIX/info]
 
172
  --mandir=DIR            man documentation in DIR [PREFIX/man]
 
173
  --srcdir=DIR            find the sources in DIR [configure dir or ..]
 
174
  --program-prefix=PREFIX prepend PREFIX to installed program names
 
175
  --program-suffix=SUFFIX append SUFFIX to installed program names
 
176
  --program-transform-name=PROGRAM
 
177
                          run sed PROGRAM on installed program names
 
178
EOF
 
179
    cat << EOF
 
180
Host type:
 
181
  --build=BUILD           configure for building on BUILD [BUILD=HOST]
 
182
  --host=HOST             configure for HOST [guessed]
 
183
  --target=TARGET         configure for TARGET [TARGET=HOST]
 
184
Features and packages:
 
185
  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
 
186
  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
 
187
  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
 
188
  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
 
189
  --x-includes=DIR        X include files are in DIR
 
190
  --x-libraries=DIR       X library files are in DIR
 
191
EOF
 
192
    if test -n "$ac_help"; then
 
193
      echo "--enable and --with options recognized:$ac_help"
 
194
    fi
 
195
    exit 0 ;;
 
196
 
 
197
  -host | --host | --hos | --ho)
 
198
    ac_prev=host ;;
 
199
  -host=* | --host=* | --hos=* | --ho=*)
 
200
    host="$ac_optarg" ;;
 
201
 
 
202
  -includedir | --includedir | --includedi | --included | --include \
 
203
  | --includ | --inclu | --incl | --inc)
 
204
    ac_prev=includedir ;;
 
205
  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
 
206
  | --includ=* | --inclu=* | --incl=* | --inc=*)
 
207
    includedir="$ac_optarg" ;;
 
208
 
 
209
  -infodir | --infodir | --infodi | --infod | --info | --inf)
 
210
    ac_prev=infodir ;;
 
211
  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
 
212
    infodir="$ac_optarg" ;;
 
213
 
 
214
  -libdir | --libdir | --libdi | --libd)
 
215
    ac_prev=libdir ;;
 
216
  -libdir=* | --libdir=* | --libdi=* | --libd=*)
 
217
    libdir="$ac_optarg" ;;
 
218
 
 
219
  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
 
220
  | --libexe | --libex | --libe)
 
221
    ac_prev=libexecdir ;;
 
222
  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
 
223
  | --libexe=* | --libex=* | --libe=*)
 
224
    libexecdir="$ac_optarg" ;;
 
225
 
 
226
  -localstatedir | --localstatedir | --localstatedi | --localstated \
 
227
  | --localstate | --localstat | --localsta | --localst \
 
228
  | --locals | --local | --loca | --loc | --lo)
 
229
    ac_prev=localstatedir ;;
 
230
  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
 
231
  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
 
232
  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
 
233
    localstatedir="$ac_optarg" ;;
 
234
 
 
235
  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
 
236
    ac_prev=mandir ;;
 
237
  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
 
238
    mandir="$ac_optarg" ;;
 
239
 
 
240
  -nfp | --nfp | --nf)
 
241
    # Obsolete; use --without-fp.
 
242
    with_fp=no ;;
 
243
 
 
244
  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
 
245
  | --no-cr | --no-c)
 
246
    no_create=yes ;;
 
247
 
 
248
  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
 
249
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
 
250
    no_recursion=yes ;;
 
251
 
 
252
  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
 
253
  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
 
254
  | --oldin | --oldi | --old | --ol | --o)
 
255
    ac_prev=oldincludedir ;;
 
256
  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
 
257
  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
 
258
  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
 
259
    oldincludedir="$ac_optarg" ;;
 
260
 
 
261
  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
 
262
    ac_prev=prefix ;;
 
263
  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
 
264
    prefix="$ac_optarg" ;;
 
265
 
 
266
  -program-prefix | --program-prefix | --program-prefi | --program-pref \
 
267
  | --program-pre | --program-pr | --program-p)
 
268
    ac_prev=program_prefix ;;
 
269
  -program-prefix=* | --program-prefix=* | --program-prefi=* \
 
270
  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
 
271
    program_prefix="$ac_optarg" ;;
 
272
 
 
273
  -program-suffix | --program-suffix | --program-suffi | --program-suff \
 
274
  | --program-suf | --program-su | --program-s)
 
275
    ac_prev=program_suffix ;;
 
276
  -program-suffix=* | --program-suffix=* | --program-suffi=* \
 
277
  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
 
278
    program_suffix="$ac_optarg" ;;
 
279
 
 
280
  -program-transform-name | --program-transform-name \
 
281
  | --program-transform-nam | --program-transform-na \
 
282
  | --program-transform-n | --program-transform- \
 
283
  | --program-transform | --program-transfor \
 
284
  | --program-transfo | --program-transf \
 
285
  | --program-trans | --program-tran \
 
286
  | --progr-tra | --program-tr | --program-t)
 
287
    ac_prev=program_transform_name ;;
 
288
  -program-transform-name=* | --program-transform-name=* \
 
289
  | --program-transform-nam=* | --program-transform-na=* \
 
290
  | --program-transform-n=* | --program-transform-=* \
 
291
  | --program-transform=* | --program-transfor=* \
 
292
  | --program-transfo=* | --program-transf=* \
 
293
  | --program-trans=* | --program-tran=* \
 
294
  | --progr-tra=* | --program-tr=* | --program-t=*)
 
295
    program_transform_name="$ac_optarg" ;;
 
296
 
 
297
  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
 
298
  | -silent | --silent | --silen | --sile | --sil)
 
299
    silent=yes ;;
 
300
 
 
301
  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
 
302
    ac_prev=sbindir ;;
 
303
  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
 
304
  | --sbi=* | --sb=*)
 
305
    sbindir="$ac_optarg" ;;
 
306
 
 
307
  -sharedstatedir | --sharedstatedir | --sharedstatedi \
 
308
  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
 
309
  | --sharedst | --shareds | --shared | --share | --shar \
 
310
  | --sha | --sh)
 
311
    ac_prev=sharedstatedir ;;
 
312
  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
 
313
  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
 
314
  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
 
315
  | --sha=* | --sh=*)
 
316
    sharedstatedir="$ac_optarg" ;;
 
317
 
 
318
  -site | --site | --sit)
 
319
    ac_prev=site ;;
 
320
  -site=* | --site=* | --sit=*)
 
321
    site="$ac_optarg" ;;
 
322
 
 
323
  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
 
324
    ac_prev=srcdir ;;
 
325
  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
 
326
    srcdir="$ac_optarg" ;;
 
327
 
 
328
  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
 
329
  | --syscon | --sysco | --sysc | --sys | --sy)
 
330
    ac_prev=sysconfdir ;;
 
331
  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
 
332
  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
 
333
    sysconfdir="$ac_optarg" ;;
 
334
 
 
335
  -target | --target | --targe | --targ | --tar | --ta | --t)
 
336
    ac_prev=target ;;
 
337
  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
 
338
    target="$ac_optarg" ;;
 
339
 
 
340
  -v | -verbose | --verbose | --verbos | --verbo | --verb)
 
341
    verbose=yes ;;
 
342
 
 
343
  -version | --version | --versio | --versi | --vers)
 
344
    echo "configure generated by autoconf version 2.13"
 
345
    exit 0 ;;
 
346
 
 
347
  -with-* | --with-*)
 
348
    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
 
349
    # Reject names that are not valid shell variable names.
 
350
    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
 
351
      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
 
352
    fi
 
353
    ac_package=`echo $ac_package| sed 's/-/_/g'`
 
354
    case "$ac_option" in
 
355
      *=*) ;;
 
356
      *) ac_optarg=yes ;;
 
357
    esac
 
358
    eval "with_${ac_package}='$ac_optarg'" ;;
 
359
 
 
360
  -without-* | --without-*)
 
361
    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
 
362
    # Reject names that are not valid shell variable names.
 
363
    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
 
364
      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
 
365
    fi
 
366
    ac_package=`echo $ac_package| sed 's/-/_/g'`
 
367
    eval "with_${ac_package}=no" ;;
 
368
 
 
369
  --x)
 
370
    # Obsolete; use --with-x.
 
371
    with_x=yes ;;
 
372
 
 
373
  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
 
374
  | --x-incl | --x-inc | --x-in | --x-i)
 
375
    ac_prev=x_includes ;;
 
376
  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
 
377
  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
 
378
    x_includes="$ac_optarg" ;;
 
379
 
 
380
  -x-libraries | --x-libraries | --x-librarie | --x-librari \
 
381
  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
 
382
    ac_prev=x_libraries ;;
 
383
  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
 
384
  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
 
385
    x_libraries="$ac_optarg" ;;
 
386
 
 
387
  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
 
388
    ;;
 
389
 
 
390
  *)
 
391
    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
 
392
      echo "configure: warning: $ac_option: invalid host type" 1>&2
 
393
    fi
 
394
    if test "x$nonopt" != xNONE; then
 
395
      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
 
396
    fi
 
397
    nonopt="$ac_option"
 
398
    ;;
 
399
 
 
400
  esac
 
401
done
 
402
 
 
403
if test -n "$ac_prev"; then
 
404
  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
 
405
fi
 
406
 
 
407
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
 
408
 
 
409
# File descriptor usage:
 
410
# 0 standard input
 
411
# 1 file creation
 
412
# 2 errors and warnings
 
413
# 3 some systems may open it to /dev/tty
 
414
# 4 used on the Kubota Titan
 
415
# 6 checking for... messages and results
 
416
# 5 compiler messages saved in config.log
 
417
if test "$silent" = yes; then
 
418
  exec 6>/dev/null
 
419
else
 
420
  exec 6>&1
 
421
fi
 
422
exec 5>./config.log
 
423
 
 
424
echo "\
 
425
This file contains any messages produced by compilers while
 
426
running configure, to aid debugging if configure makes a mistake.
 
427
" 1>&5
 
428
 
 
429
# Strip out --no-create and --no-recursion so they do not pile up.
 
430
# Also quote any args containing shell metacharacters.
 
431
ac_configure_args=
 
432
for ac_arg
 
433
do
 
434
  case "$ac_arg" in
 
435
  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
 
436
  | --no-cr | --no-c) ;;
 
437
  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
 
438
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
 
439
  *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
 
440
  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
 
441
  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
 
442
  esac
 
443
done
 
444
 
 
445
# NLS nuisances.
 
446
# Only set these to C if already set.  These must not be set unconditionally
 
447
# because not all systems understand e.g. LANG=C (notably SCO).
 
448
# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
 
449
# Non-C LC_CTYPE values break the ctype check.
 
450
if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
 
451
if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
 
452
if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
 
453
if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
 
454
 
 
455
# confdefs.h avoids OS command line length limits that DEFS can exceed.
 
456
rm -rf conftest* confdefs.h
 
457
# AIX cpp loses on an empty file, so make sure it contains at least a newline.
 
458
echo > confdefs.h
 
459
 
 
460
# A filename unique to this package, relative to the directory that
 
461
# configure is in, which we can look for to find out if srcdir is correct.
 
462
ac_unique_file=README
 
463
 
 
464
# Find the source files, if location was not specified.
 
465
if test -z "$srcdir"; then
 
466
  ac_srcdir_defaulted=yes
 
467
  # Try the directory containing this script, then its parent.
 
468
  ac_prog=$0
 
469
  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
 
470
  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
 
471
  srcdir=$ac_confdir
 
472
  if test ! -r $srcdir/$ac_unique_file; then
 
473
    srcdir=..
 
474
  fi
 
475
else
 
476
  ac_srcdir_defaulted=no
 
477
fi
 
478
if test ! -r $srcdir/$ac_unique_file; then
 
479
  if test "$ac_srcdir_defaulted" = yes; then
 
480
    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
 
481
  else
 
482
    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
 
483
  fi
 
484
fi
 
485
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
 
486
 
 
487
# Prefer explicitly selected file to automatically selected ones.
 
488
if test -z "$CONFIG_SITE"; then
 
489
  if test "x$prefix" != xNONE; then
 
490
    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
 
491
  else
 
492
    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
 
493
  fi
 
494
fi
 
495
for ac_site_file in $CONFIG_SITE; do
 
496
  if test -r "$ac_site_file"; then
 
497
    echo "loading site script $ac_site_file"
 
498
    . "$ac_site_file"
 
499
  fi
 
500
done
 
501
 
 
502
if test -r "$cache_file"; then
 
503
  echo "loading cache $cache_file"
 
504
  . $cache_file
 
505
else
 
506
  echo "creating cache $cache_file"
 
507
  > $cache_file
 
508
fi
 
509
 
 
510
ac_ext=c
 
511
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
 
512
ac_cpp='$CPP $CPPFLAGS'
 
513
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
 
514
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
 
515
cross_compiling=$ac_cv_prog_cc_cross
 
516
 
 
517
ac_exeext=
 
518
ac_objext=o
 
519
if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
 
520
  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
 
521
  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
 
522
    ac_n= ac_c='
 
523
' ac_t='        '
 
524
  else
 
525
    ac_n=-n ac_c= ac_t=
 
526
  fi
 
527
else
 
528
  ac_n= ac_c='\c' ac_t=
 
529
fi
 
530
 
 
531
 
 
532
ac_aux_dir=
 
533
for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
 
534
  if test -f $ac_dir/install-sh; then
 
535
    ac_aux_dir=$ac_dir
 
536
    ac_install_sh="$ac_aux_dir/install-sh -c"
 
537
    break
 
538
  elif test -f $ac_dir/install.sh; then
 
539
    ac_aux_dir=$ac_dir
 
540
    ac_install_sh="$ac_aux_dir/install.sh -c"
 
541
    break
 
542
  fi
 
543
done
 
544
if test -z "$ac_aux_dir"; then
 
545
  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
 
546
fi
 
547
ac_config_guess=$ac_aux_dir/config.guess
 
548
ac_config_sub=$ac_aux_dir/config.sub
 
549
ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
 
550
 
 
551
# Find a good install program.  We prefer a C program (faster),
 
552
# so one script is as good as another.  But avoid the broken or
 
553
# incompatible versions:
 
554
# SysV /etc/install, /usr/sbin/install
 
555
# SunOS /usr/etc/install
 
556
# IRIX /sbin/install
 
557
# AIX /bin/install
 
558
# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
 
559
# AFS /usr/afsws/bin/install, which mishandles nonexistent args
 
560
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
 
561
# ./install, which can be erroneously created by make from ./install.sh.
 
562
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
 
563
echo "configure:564: checking for a BSD compatible install" >&5
 
564
if test -z "$INSTALL"; then
 
565
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
 
566
  echo $ac_n "(cached) $ac_c" 1>&6
 
567
else
 
568
    IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
 
569
  for ac_dir in $PATH; do
 
570
    # Account for people who put trailing slashes in PATH elements.
 
571
    case "$ac_dir/" in
 
572
    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
 
573
    *)
 
574
      # OSF1 and SCO ODT 3.0 have their own names for install.
 
575
      # Don't use installbsd from OSF since it installs stuff as root
 
576
      # by default.
 
577
      for ac_prog in ginstall scoinst install; do
 
578
        if test -f $ac_dir/$ac_prog; then
 
579
          if test $ac_prog = install &&
 
580
            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
 
581
            # AIX install.  It has an incompatible calling convention.
 
582
            :
 
583
          else
 
584
            ac_cv_path_install="$ac_dir/$ac_prog -c"
 
585
            break 2
 
586
          fi
 
587
        fi
 
588
      done
 
589
      ;;
 
590
    esac
 
591
  done
 
592
  IFS="$ac_save_IFS"
 
593
 
 
594
fi
 
595
  if test "${ac_cv_path_install+set}" = set; then
 
596
    INSTALL="$ac_cv_path_install"
 
597
  else
 
598
    # As a last resort, use the slow shell script.  We don't cache a
 
599
    # path for INSTALL within a source directory, because that will
 
600
    # break other packages using the cache if that directory is
 
601
    # removed, or if the path is relative.
 
602
    INSTALL="$ac_install_sh"
 
603
  fi
 
604
fi
 
605
echo "$ac_t""$INSTALL" 1>&6
 
606
 
 
607
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
 
608
# It thinks the first close brace ends the variable substitution.
 
609
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
 
610
 
 
611
test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
 
612
 
 
613
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
 
614
 
 
615
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
 
616
echo "configure:617: checking whether build environment is sane" >&5
 
617
# Just in case
 
618
sleep 1
 
619
echo timestamp > conftestfile
 
620
# Do `set' in a subshell so we don't clobber the current shell's
 
621
# arguments.  Must try -L first in case configure is actually a
 
622
# symlink; some systems play weird games with the mod time of symlinks
 
623
# (eg FreeBSD returns the mod time of the symlink's containing
 
624
# directory).
 
625
if (
 
626
   set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
 
627
   if test "$*" = "X"; then
 
628
      # -L didn't work.
 
629
      set X `ls -t $srcdir/configure conftestfile`
 
630
   fi
 
631
   if test "$*" != "X $srcdir/configure conftestfile" \
 
632
      && test "$*" != "X conftestfile $srcdir/configure"; then
 
633
 
 
634
      # If neither matched, then we have a broken ls.  This can happen
 
635
      # if, for instance, CONFIG_SHELL is bash and it inherits a
 
636
      # broken ls alias from the environment.  This has actually
 
637
      # happened.  Such a system could not be considered "sane".
 
638
      { echo "configure: error: ls -t appears to fail.  Make sure there is not a broken
 
639
alias in your environment" 1>&2; exit 1; }
 
640
   fi
 
641
 
 
642
   test "$2" = conftestfile
 
643
   )
 
644
then
 
645
   # Ok.
 
646
   :
 
647
else
 
648
   { echo "configure: error: newly created file is older than distributed files!
 
649
Check your system clock" 1>&2; exit 1; }
 
650
fi
 
651
rm -f conftest*
 
652
echo "$ac_t""yes" 1>&6
 
653
if test "$program_transform_name" = s,x,x,; then
 
654
  program_transform_name=
 
655
else
 
656
  # Double any \ or $.  echo might interpret backslashes.
 
657
  cat <<\EOF_SED > conftestsed
 
658
s,\\,\\\\,g; s,\$,$$,g
 
659
EOF_SED
 
660
  program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
 
661
  rm -f conftestsed
 
662
fi
 
663
test "$program_prefix" != NONE &&
 
664
  program_transform_name="s,^,${program_prefix},; $program_transform_name"
 
665
# Use a double $ so make ignores it.
 
666
test "$program_suffix" != NONE &&
 
667
  program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
 
668
 
 
669
# sed with no file args requires a program.
 
670
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
 
671
 
 
672
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
 
673
echo "configure:674: checking whether ${MAKE-make} sets \${MAKE}" >&5
 
674
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
 
675
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
 
676
  echo $ac_n "(cached) $ac_c" 1>&6
 
677
else
 
678
  cat > conftestmake <<\EOF
 
679
all:
 
680
        @echo 'ac_maketemp="${MAKE}"'
 
681
EOF
 
682
# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
 
683
eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
 
684
if test -n "$ac_maketemp"; then
 
685
  eval ac_cv_prog_make_${ac_make}_set=yes
 
686
else
 
687
  eval ac_cv_prog_make_${ac_make}_set=no
 
688
fi
 
689
rm -f conftestmake
 
690
fi
 
691
if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
 
692
  echo "$ac_t""yes" 1>&6
 
693
  SET_MAKE=
 
694
else
 
695
  echo "$ac_t""no" 1>&6
 
696
  SET_MAKE="MAKE=${MAKE-make}"
 
697
fi
 
698
 
 
699
 
 
700
PACKAGE=widelands
 
701
 
 
702
VERSION=0.0.15
 
703
 
 
704
if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
 
705
  { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
 
706
fi
 
707
cat >> confdefs.h <<EOF
 
708
#define PACKAGE "$PACKAGE"
 
709
EOF
 
710
 
 
711
cat >> confdefs.h <<EOF
 
712
#define VERSION "$VERSION"
 
713
EOF
 
714
 
 
715
 
 
716
 
 
717
missing_dir=`cd $ac_aux_dir && pwd`
 
718
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
 
719
echo "configure:720: checking for working aclocal" >&5
 
720
# Run test in a subshell; some versions of sh will print an error if
 
721
# an executable is not found, even if stderr is redirected.
 
722
# Redirect stdin to placate older versions of autoconf.  Sigh.
 
723
if (aclocal --version) < /dev/null > /dev/null 2>&1; then
 
724
   ACLOCAL=aclocal
 
725
   echo "$ac_t""found" 1>&6
 
726
else
 
727
   ACLOCAL="$missing_dir/missing aclocal"
 
728
   echo "$ac_t""missing" 1>&6
 
729
fi
 
730
 
 
731
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
 
732
echo "configure:733: checking for working autoconf" >&5
 
733
# Run test in a subshell; some versions of sh will print an error if
 
734
# an executable is not found, even if stderr is redirected.
 
735
# Redirect stdin to placate older versions of autoconf.  Sigh.
 
736
if (autoconf --version) < /dev/null > /dev/null 2>&1; then
 
737
   AUTOCONF=autoconf
 
738
   echo "$ac_t""found" 1>&6
 
739
else
 
740
   AUTOCONF="$missing_dir/missing autoconf"
 
741
   echo "$ac_t""missing" 1>&6
 
742
fi
 
743
 
 
744
echo $ac_n "checking for working automake""... $ac_c" 1>&6
 
745
echo "configure:746: checking for working automake" >&5
 
746
# Run test in a subshell; some versions of sh will print an error if
 
747
# an executable is not found, even if stderr is redirected.
 
748
# Redirect stdin to placate older versions of autoconf.  Sigh.
 
749
if (automake --version) < /dev/null > /dev/null 2>&1; then
 
750
   AUTOMAKE=automake
 
751
   echo "$ac_t""found" 1>&6
 
752
else
 
753
   AUTOMAKE="$missing_dir/missing automake"
 
754
   echo "$ac_t""missing" 1>&6
 
755
fi
 
756
 
 
757
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
 
758
echo "configure:759: checking for working autoheader" >&5
 
759
# Run test in a subshell; some versions of sh will print an error if
 
760
# an executable is not found, even if stderr is redirected.
 
761
# Redirect stdin to placate older versions of autoconf.  Sigh.
 
762
if (autoheader --version) < /dev/null > /dev/null 2>&1; then
 
763
   AUTOHEADER=autoheader
 
764
   echo "$ac_t""found" 1>&6
 
765
else
 
766
   AUTOHEADER="$missing_dir/missing autoheader"
 
767
   echo "$ac_t""missing" 1>&6
 
768
fi
 
769
 
 
770
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
 
771
echo "configure:772: checking for working makeinfo" >&5
 
772
# Run test in a subshell; some versions of sh will print an error if
 
773
# an executable is not found, even if stderr is redirected.
 
774
# Redirect stdin to placate older versions of autoconf.  Sigh.
 
775
if (makeinfo --version) < /dev/null > /dev/null 2>&1; then
 
776
   MAKEINFO=makeinfo
 
777
   echo "$ac_t""found" 1>&6
 
778
else
 
779
   MAKEINFO="$missing_dir/missing makeinfo"
 
780
   echo "$ac_t""missing" 1>&6
 
781
fi
 
782
 
 
783
 
 
784
 
 
785
 
 
786
 
 
787
 
 
788
 
 
789
 
 
790
 
 
791
ISODATE=`date +%Y-%m-%d`
 
792
 
 
793
 
 
794
 
 
795
# Make sure we can run config.sub.
 
796
if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
 
797
else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
 
798
fi
 
799
 
 
800
echo $ac_n "checking host system type""... $ac_c" 1>&6
 
801
echo "configure:802: checking host system type" >&5
 
802
 
 
803
host_alias=$host
 
804
case "$host_alias" in
 
805
NONE)
 
806
  case $nonopt in
 
807
  NONE)
 
808
    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
 
809
    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
 
810
    fi ;;
 
811
  *) host_alias=$nonopt ;;
 
812
  esac ;;
 
813
esac
 
814
 
 
815
host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
 
816
host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
 
817
host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
 
818
host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
 
819
echo "$ac_t""$host" 1>&6
 
820
 
 
821
# Check whether --enable-libsdl or --disable-libsdl was given.
 
822
if test "${enable_libsdl+set}" = set; then
 
823
  enableval="$enable_libsdl"
 
824
  libsdl_try=no
 
825
else
 
826
  libsdl_try=yes
 
827
fi
 
828
 
 
829
 
 
830
# Find a good install program.  We prefer a C program (faster),
 
831
# so one script is as good as another.  But avoid the broken or
 
832
# incompatible versions:
 
833
# SysV /etc/install, /usr/sbin/install
 
834
# SunOS /usr/etc/install
 
835
# IRIX /sbin/install
 
836
# AIX /bin/install
 
837
# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
 
838
# AFS /usr/afsws/bin/install, which mishandles nonexistent args
 
839
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
 
840
# ./install, which can be erroneously created by make from ./install.sh.
 
841
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
 
842
echo "configure:843: checking for a BSD compatible install" >&5
 
843
if test -z "$INSTALL"; then
 
844
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
 
845
  echo $ac_n "(cached) $ac_c" 1>&6
 
846
else
 
847
    IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
 
848
  for ac_dir in $PATH; do
 
849
    # Account for people who put trailing slashes in PATH elements.
 
850
    case "$ac_dir/" in
 
851
    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
 
852
    *)
 
853
      # OSF1 and SCO ODT 3.0 have their own names for install.
 
854
      # Don't use installbsd from OSF since it installs stuff as root
 
855
      # by default.
 
856
      for ac_prog in ginstall scoinst install; do
 
857
        if test -f $ac_dir/$ac_prog; then
 
858
          if test $ac_prog = install &&
 
859
            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
 
860
            # AIX install.  It has an incompatible calling convention.
 
861
            :
 
862
          else
 
863
            ac_cv_path_install="$ac_dir/$ac_prog -c"
 
864
            break 2
 
865
          fi
 
866
        fi
 
867
      done
 
868
      ;;
 
869
    esac
 
870
  done
 
871
  IFS="$ac_save_IFS"
 
872
 
 
873
fi
 
874
  if test "${ac_cv_path_install+set}" = set; then
 
875
    INSTALL="$ac_cv_path_install"
 
876
  else
 
877
    # As a last resort, use the slow shell script.  We don't cache a
 
878
    # path for INSTALL within a source directory, because that will
 
879
    # break other packages using the cache if that directory is
 
880
    # removed, or if the path is relative.
 
881
    INSTALL="$ac_install_sh"
 
882
  fi
 
883
fi
 
884
echo "$ac_t""$INSTALL" 1>&6
 
885
 
 
886
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
 
887
# It thinks the first close brace ends the variable substitution.
 
888
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
 
889
 
 
890
test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
 
891
 
 
892
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
 
893
 
 
894
# Extract the first word of "gcc", so it can be a program name with args.
 
895
set dummy gcc; ac_word=$2
 
896
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
 
897
echo "configure:898: checking for $ac_word" >&5
 
898
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
 
899
  echo $ac_n "(cached) $ac_c" 1>&6
 
900
else
 
901
  if test -n "$CC"; then
 
902
  ac_cv_prog_CC="$CC" # Let the user override the test.
 
903
else
 
904
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
 
905
  ac_dummy="$PATH"
 
906
  for ac_dir in $ac_dummy; do
 
907
    test -z "$ac_dir" && ac_dir=.
 
908
    if test -f $ac_dir/$ac_word; then
 
909
      ac_cv_prog_CC="gcc"
 
910
      break
 
911
    fi
 
912
  done
 
913
  IFS="$ac_save_ifs"
 
914
fi
 
915
fi
 
916
CC="$ac_cv_prog_CC"
 
917
if test -n "$CC"; then
 
918
  echo "$ac_t""$CC" 1>&6
 
919
else
 
920
  echo "$ac_t""no" 1>&6
 
921
fi
 
922
 
 
923
if test -z "$CC"; then
 
924
  # Extract the first word of "cc", so it can be a program name with args.
 
925
set dummy cc; ac_word=$2
 
926
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
 
927
echo "configure:928: checking for $ac_word" >&5
 
928
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
 
929
  echo $ac_n "(cached) $ac_c" 1>&6
 
930
else
 
931
  if test -n "$CC"; then
 
932
  ac_cv_prog_CC="$CC" # Let the user override the test.
 
933
else
 
934
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
 
935
  ac_prog_rejected=no
 
936
  ac_dummy="$PATH"
 
937
  for ac_dir in $ac_dummy; do
 
938
    test -z "$ac_dir" && ac_dir=.
 
939
    if test -f $ac_dir/$ac_word; then
 
940
      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
 
941
        ac_prog_rejected=yes
 
942
        continue
 
943
      fi
 
944
      ac_cv_prog_CC="cc"
 
945
      break
 
946
    fi
 
947
  done
 
948
  IFS="$ac_save_ifs"
 
949
if test $ac_prog_rejected = yes; then
 
950
  # We found a bogon in the path, so make sure we never use it.
 
951
  set dummy $ac_cv_prog_CC
 
952
  shift
 
953
  if test $# -gt 0; then
 
954
    # We chose a different compiler from the bogus one.
 
955
    # However, it has the same basename, so the bogon will be chosen
 
956
    # first if we set CC to just the basename; use the full file name.
 
957
    shift
 
958
    set dummy "$ac_dir/$ac_word" "$@"
 
959
    shift
 
960
    ac_cv_prog_CC="$@"
 
961
  fi
 
962
fi
 
963
fi
 
964
fi
 
965
CC="$ac_cv_prog_CC"
 
966
if test -n "$CC"; then
 
967
  echo "$ac_t""$CC" 1>&6
 
968
else
 
969
  echo "$ac_t""no" 1>&6
 
970
fi
 
971
 
 
972
  if test -z "$CC"; then
 
973
    case "`uname -s`" in
 
974
    *win32* | *WIN32*)
 
975
      # Extract the first word of "cl", so it can be a program name with args.
 
976
set dummy cl; ac_word=$2
 
977
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
 
978
echo "configure:979: checking for $ac_word" >&5
 
979
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
 
980
  echo $ac_n "(cached) $ac_c" 1>&6
 
981
else
 
982
  if test -n "$CC"; then
 
983
  ac_cv_prog_CC="$CC" # Let the user override the test.
 
984
else
 
985
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
 
986
  ac_dummy="$PATH"
 
987
  for ac_dir in $ac_dummy; do
 
988
    test -z "$ac_dir" && ac_dir=.
 
989
    if test -f $ac_dir/$ac_word; then
 
990
      ac_cv_prog_CC="cl"
 
991
      break
 
992
    fi
 
993
  done
 
994
  IFS="$ac_save_ifs"
 
995
fi
 
996
fi
 
997
CC="$ac_cv_prog_CC"
 
998
if test -n "$CC"; then
 
999
  echo "$ac_t""$CC" 1>&6
 
1000
else
 
1001
  echo "$ac_t""no" 1>&6
 
1002
fi
 
1003
 ;;
 
1004
    esac
 
1005
  fi
 
1006
  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
 
1007
fi
 
1008
 
 
1009
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
 
1010
echo "configure:1011: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
 
1011
 
 
1012
ac_ext=c
 
1013
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
 
1014
ac_cpp='$CPP $CPPFLAGS'
 
1015
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
 
1016
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
 
1017
cross_compiling=$ac_cv_prog_cc_cross
 
1018
 
 
1019
cat > conftest.$ac_ext << EOF
 
1020
 
 
1021
#line 1022 "configure"
 
1022
#include "confdefs.h"
 
1023
 
 
1024
main(){return(0);}
 
1025
EOF
 
1026
if { (eval echo configure:1027: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
 
1027
  ac_cv_prog_cc_works=yes
 
1028
  # If we can't run a trivial program, we are probably using a cross compiler.
 
1029
  if (./conftest; exit) 2>/dev/null; then
 
1030
    ac_cv_prog_cc_cross=no
 
1031
  else
 
1032
    ac_cv_prog_cc_cross=yes
 
1033
  fi
 
1034
else
 
1035
  echo "configure: failed program was:" >&5
 
1036
  cat conftest.$ac_ext >&5
 
1037
  ac_cv_prog_cc_works=no
 
1038
fi
 
1039
rm -fr conftest*
 
1040
ac_ext=c
 
1041
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
 
1042
ac_cpp='$CPP $CPPFLAGS'
 
1043
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
 
1044
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
 
1045
cross_compiling=$ac_cv_prog_cc_cross
 
1046
 
 
1047
echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
 
1048
if test $ac_cv_prog_cc_works = no; then
 
1049
  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
 
1050
fi
 
1051
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
 
1052
echo "configure:1053: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
 
1053
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
 
1054
cross_compiling=$ac_cv_prog_cc_cross
 
1055
 
 
1056
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
 
1057
echo "configure:1058: checking whether we are using GNU C" >&5
 
1058
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
 
1059
  echo $ac_n "(cached) $ac_c" 1>&6
 
1060
else
 
1061
  cat > conftest.c <<EOF
 
1062
#ifdef __GNUC__
 
1063
  yes;
 
1064
#endif
 
1065
EOF
 
1066
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1067: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
 
1067
  ac_cv_prog_gcc=yes
 
1068
else
 
1069
  ac_cv_prog_gcc=no
 
1070
fi
 
1071
fi
 
1072
 
 
1073
echo "$ac_t""$ac_cv_prog_gcc" 1>&6
 
1074
 
 
1075
if test $ac_cv_prog_gcc = yes; then
 
1076
  GCC=yes
 
1077
else
 
1078
  GCC=
 
1079
fi
 
1080
 
 
1081
ac_test_CFLAGS="${CFLAGS+set}"
 
1082
ac_save_CFLAGS="$CFLAGS"
 
1083
CFLAGS=
 
1084
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
 
1085
echo "configure:1086: checking whether ${CC-cc} accepts -g" >&5
 
1086
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
 
1087
  echo $ac_n "(cached) $ac_c" 1>&6
 
1088
else
 
1089
  echo 'void f(){}' > conftest.c
 
1090
if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
 
1091
  ac_cv_prog_cc_g=yes
 
1092
else
 
1093
  ac_cv_prog_cc_g=no
 
1094
fi
 
1095
rm -f conftest*
 
1096
 
 
1097
fi
 
1098
 
 
1099
echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
 
1100
if test "$ac_test_CFLAGS" = set; then
 
1101
  CFLAGS="$ac_save_CFLAGS"
 
1102
elif test $ac_cv_prog_cc_g = yes; then
 
1103
  if test "$GCC" = yes; then
 
1104
    CFLAGS="-g -O2"
 
1105
  else
 
1106
    CFLAGS="-g"
 
1107
  fi
 
1108
else
 
1109
  if test "$GCC" = yes; then
 
1110
    CFLAGS="-O2"
 
1111
  else
 
1112
    CFLAGS=
 
1113
  fi
 
1114
fi
 
1115
 
 
1116
for ac_prog in $CCC c++ g++ gcc CC cxx cc++ cl
 
1117
do
 
1118
# Extract the first word of "$ac_prog", so it can be a program name with args.
 
1119
set dummy $ac_prog; ac_word=$2
 
1120
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
 
1121
echo "configure:1122: checking for $ac_word" >&5
 
1122
if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
 
1123
  echo $ac_n "(cached) $ac_c" 1>&6
 
1124
else
 
1125
  if test -n "$CXX"; then
 
1126
  ac_cv_prog_CXX="$CXX" # Let the user override the test.
 
1127
else
 
1128
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
 
1129
  ac_dummy="$PATH"
 
1130
  for ac_dir in $ac_dummy; do
 
1131
    test -z "$ac_dir" && ac_dir=.
 
1132
    if test -f $ac_dir/$ac_word; then
 
1133
      ac_cv_prog_CXX="$ac_prog"
 
1134
      break
 
1135
    fi
 
1136
  done
 
1137
  IFS="$ac_save_ifs"
 
1138
fi
 
1139
fi
 
1140
CXX="$ac_cv_prog_CXX"
 
1141
if test -n "$CXX"; then
 
1142
  echo "$ac_t""$CXX" 1>&6
 
1143
else
 
1144
  echo "$ac_t""no" 1>&6
 
1145
fi
 
1146
 
 
1147
test -n "$CXX" && break
 
1148
done
 
1149
test -n "$CXX" || CXX="gcc"
 
1150
 
 
1151
 
 
1152
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
 
1153
echo "configure:1154: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
 
1154
 
 
1155
ac_ext=C
 
1156
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
 
1157
ac_cpp='$CXXCPP $CPPFLAGS'
 
1158
ac_compile='${CXX-g++} -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
 
1159
ac_link='${CXX-g++} -o conftest${ac_exeext} $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
 
1160
cross_compiling=$ac_cv_prog_cxx_cross
 
1161
 
 
1162
cat > conftest.$ac_ext << EOF
 
1163
 
 
1164
#line 1165 "configure"
 
1165
#include "confdefs.h"
 
1166
 
 
1167
int main(){return(0);}
 
1168
EOF
 
1169
if { (eval echo configure:1170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
 
1170
  ac_cv_prog_cxx_works=yes
 
1171
  # If we can't run a trivial program, we are probably using a cross compiler.
 
1172
  if (./conftest; exit) 2>/dev/null; then
 
1173
    ac_cv_prog_cxx_cross=no
 
1174
  else
 
1175
    ac_cv_prog_cxx_cross=yes
 
1176
  fi
 
1177
else
 
1178
  echo "configure: failed program was:" >&5
 
1179
  cat conftest.$ac_ext >&5
 
1180
  ac_cv_prog_cxx_works=no
 
1181
fi
 
1182
rm -fr conftest*
 
1183
ac_ext=c
 
1184
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
 
1185
ac_cpp='$CPP $CPPFLAGS'
 
1186
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
 
1187
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
 
1188
cross_compiling=$ac_cv_prog_cc_cross
 
1189
 
 
1190
echo "$ac_t""$ac_cv_prog_cxx_works" 1>&6
 
1191
if test $ac_cv_prog_cxx_works = no; then
 
1192
  { echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
 
1193
fi
 
1194
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
 
1195
echo "configure:1196: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
 
1196
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
 
1197
cross_compiling=$ac_cv_prog_cxx_cross
 
1198
 
 
1199
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
 
1200
echo "configure:1201: checking whether we are using GNU C++" >&5
 
1201
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
 
1202
  echo $ac_n "(cached) $ac_c" 1>&6
 
1203
else
 
1204
  cat > conftest.C <<EOF
 
1205
#ifdef __GNUC__
 
1206
  yes;
 
1207
#endif
 
1208
EOF
 
1209
if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:1210: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
 
1210
  ac_cv_prog_gxx=yes
 
1211
else
 
1212
  ac_cv_prog_gxx=no
 
1213
fi
 
1214
fi
 
1215
 
 
1216
echo "$ac_t""$ac_cv_prog_gxx" 1>&6
 
1217
 
 
1218
if test $ac_cv_prog_gxx = yes; then
 
1219
  GXX=yes
 
1220
else
 
1221
  GXX=
 
1222
fi
 
1223
 
 
1224
ac_test_CXXFLAGS="${CXXFLAGS+set}"
 
1225
ac_save_CXXFLAGS="$CXXFLAGS"
 
1226
CXXFLAGS=
 
1227
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
 
1228
echo "configure:1229: checking whether ${CXX-g++} accepts -g" >&5
 
1229
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
 
1230
  echo $ac_n "(cached) $ac_c" 1>&6
 
1231
else
 
1232
  echo 'void f(){}' > conftest.cc
 
1233
if test -z "`${CXX-g++} -g -c conftest.cc 2>&1`"; then
 
1234
  ac_cv_prog_cxx_g=yes
 
1235
else
 
1236
  ac_cv_prog_cxx_g=no
 
1237
fi
 
1238
rm -f conftest*
 
1239
 
 
1240
fi
 
1241
 
 
1242
echo "$ac_t""$ac_cv_prog_cxx_g" 1>&6
 
1243
if test "$ac_test_CXXFLAGS" = set; then
 
1244
  CXXFLAGS="$ac_save_CXXFLAGS"
 
1245
elif test $ac_cv_prog_cxx_g = yes; then
 
1246
  if test "$GXX" = yes; then
 
1247
    CXXFLAGS="-g -O2"
 
1248
  else
 
1249
    CXXFLAGS="-g"
 
1250
  fi
 
1251
else
 
1252
  if test "$GXX" = yes; then
 
1253
    CXXFLAGS="-O2"
 
1254
  else
 
1255
    CXXFLAGS=
 
1256
  fi
 
1257
fi
 
1258
 
 
1259
 
 
1260
if test "$libsdl_try" = "yes" ; then 
 
1261
                  # Check whether --with-sdl-prefix or --without-sdl-prefix was given.
 
1262
if test "${with_sdl_prefix+set}" = set; then
 
1263
  withval="$with_sdl_prefix"
 
1264
  sdl_prefix="$withval"
 
1265
else
 
1266
  sdl_prefix=""
 
1267
fi
 
1268
 
 
1269
# Check whether --with-sdl-exec-prefix or --without-sdl-exec-prefix was given.
 
1270
if test "${with_sdl_exec_prefix+set}" = set; then
 
1271
  withval="$with_sdl_exec_prefix"
 
1272
  sdl_exec_prefix="$withval"
 
1273
else
 
1274
  sdl_exec_prefix=""
 
1275
fi
 
1276
 
 
1277
# Check whether --enable-sdltest or --disable-sdltest was given.
 
1278
if test "${enable_sdltest+set}" = set; then
 
1279
  enableval="$enable_sdltest"
 
1280
  :
 
1281
else
 
1282
  enable_sdltest=yes
 
1283
fi
 
1284
 
 
1285
 
 
1286
  if test x$sdl_exec_prefix != x ; then
 
1287
     sdl_args="$sdl_args --exec-prefix=$sdl_exec_prefix"
 
1288
     if test x${SDL_CONFIG+set} != xset ; then
 
1289
        SDL_CONFIG=$sdl_exec_prefix/bin/sdl-config
 
1290
     fi
 
1291
  fi
 
1292
  if test x$sdl_prefix != x ; then
 
1293
     sdl_args="$sdl_args --prefix=$sdl_prefix"
 
1294
     if test x${SDL_CONFIG+set} != xset ; then
 
1295
        SDL_CONFIG=$sdl_prefix/bin/sdl-config
 
1296
     fi
 
1297
  fi
 
1298
 
 
1299
  # Extract the first word of "sdl-config", so it can be a program name with args.
 
1300
set dummy sdl-config; ac_word=$2
 
1301
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
 
1302
echo "configure:1303: checking for $ac_word" >&5
 
1303
if eval "test \"`echo '$''{'ac_cv_path_SDL_CONFIG'+set}'`\" = set"; then
 
1304
  echo $ac_n "(cached) $ac_c" 1>&6
 
1305
else
 
1306
  case "$SDL_CONFIG" in
 
1307
  /*)
 
1308
  ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a path.
 
1309
  ;;
 
1310
  ?:/*)                  
 
1311
  ac_cv_path_SDL_CONFIG="$SDL_CONFIG" # Let the user override the test with a dos path.
 
1312
  ;;
 
1313
  *)
 
1314
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
 
1315
  ac_dummy="$PATH"
 
1316
  for ac_dir in $ac_dummy; do 
 
1317
    test -z "$ac_dir" && ac_dir=.
 
1318
    if test -f $ac_dir/$ac_word; then
 
1319
      ac_cv_path_SDL_CONFIG="$ac_dir/$ac_word"
 
1320
      break
 
1321
    fi
 
1322
  done
 
1323
  IFS="$ac_save_ifs"
 
1324
  test -z "$ac_cv_path_SDL_CONFIG" && ac_cv_path_SDL_CONFIG="no"
 
1325
  ;;
 
1326
esac
 
1327
fi
 
1328
SDL_CONFIG="$ac_cv_path_SDL_CONFIG"
 
1329
if test -n "$SDL_CONFIG"; then
 
1330
  echo "$ac_t""$SDL_CONFIG" 1>&6
 
1331
else
 
1332
  echo "$ac_t""no" 1>&6
 
1333
fi
 
1334
 
 
1335
  min_sdl_version=1.0.0
 
1336
  echo $ac_n "checking for SDL - version >= $min_sdl_version""... $ac_c" 1>&6
 
1337
echo "configure:1338: checking for SDL - version >= $min_sdl_version" >&5
 
1338
  no_sdl=""
 
1339
  if test "$SDL_CONFIG" = "no" ; then
 
1340
    no_sdl=yes
 
1341
  else
 
1342
    SDL_CFLAGS=`$SDL_CONFIG $sdlconf_args --cflags`
 
1343
    SDL_LIBS=`$SDL_CONFIG $sdlconf_args --libs`
 
1344
    SDL_LIBS_FOR_LIBS=`$SDL_CONFIG $sdlconf_args --library-libs`
 
1345
    SDL_LIBS_FOR_PLUGINS=`$SDL_CONFIG $sdlconf_args --plugin-libs`
 
1346
 
 
1347
    sdl_major_version=`$SDL_CONFIG $sdl_args --version | \
 
1348
           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\1/'`
 
1349
    sdl_minor_version=`$SDL_CONFIG $sdl_args --version | \
 
1350
           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\2/'`
 
1351
    sdl_micro_version=`$SDL_CONFIG $sdl_config_args --version | \
 
1352
           sed 's/\([0-9]*\).\([0-9]*\).\([0-9]*\)/\3/'`
 
1353
    if test "x$enable_sdltest" = "xyes" ; then
 
1354
      ac_save_CFLAGS="$CFLAGS"
 
1355
      ac_save_LIBS="$LIBS"
 
1356
      CFLAGS="$CFLAGS $SDL_CFLAGS"
 
1357
      LIBS="$LIBS $SDL_LIBS"
 
1358
      rm -f conf.sdltest
 
1359
      if test "$cross_compiling" = yes; then
 
1360
  echo $ac_n "cross compiling; assumed OK... $ac_c"
 
1361
else
 
1362
  cat > conftest.$ac_ext <<EOF
 
1363
#line 1364 "configure"
 
1364
#include "confdefs.h"
 
1365
 
 
1366
#include <stdio.h>
 
1367
#include <stdlib.h>
 
1368
#include <string.h>
 
1369
#include "SDL.h"
 
1370
 
 
1371
char*
 
1372
my_strdup (char *str)
 
1373
{
 
1374
  char *new_str;
 
1375
  
 
1376
  if (str)
 
1377
    {
 
1378
      new_str = (char *)malloc ((strlen (str) + 1) * sizeof(char));
 
1379
      strcpy (new_str, str);
 
1380
    }
 
1381
  else
 
1382
    new_str = NULL;
 
1383
  
 
1384
  return new_str;
 
1385
}
 
1386
 
 
1387
int main (int argc, char *argv[])
 
1388
{
 
1389
  int major, minor, micro;
 
1390
  char *tmp_version;
 
1391
 
 
1392
  /* This hangs on some systems (?)
 
1393
  system ("touch conf.sdltest");
 
1394
  */
 
1395
  { FILE *fp = fopen("conf.sdltest", "a"); if ( fp ) fclose(fp); }
 
1396
 
 
1397
  /* HP/UX 9 (%@#!) writes to sscanf strings */
 
1398
  tmp_version = my_strdup("$min_sdl_version");
 
1399
  if (sscanf(tmp_version, "%d.%d.%d", &major, &minor, &micro) != 3) {
 
1400
     printf("%s, bad version string\n", "$min_sdl_version");
 
1401
     exit(1);
 
1402
   }
 
1403
 
 
1404
   if (($sdl_major_version > major) ||
 
1405
      (($sdl_major_version == major) && ($sdl_minor_version > minor)) ||
 
1406
      (($sdl_major_version == major) && ($sdl_minor_version == minor) && ($sdl_micro_version >= micro)))
 
1407
    {
 
1408
      return 0;
 
1409
    }
 
1410
  else
 
1411
    {
 
1412
      printf("\n*** 'sdl-config --version' returned %d.%d.%d, but the minimum version\n", $sdl_major_version, $sdl_minor_version, $sdl_micro_version);
 
1413
      printf("*** of SDL required is %d.%d.%d. If sdl-config is correct, then it is\n", major, minor, micro);
 
1414
      printf("*** best to upgrade to the required version.\n");
 
1415
      printf("*** If sdl-config was wrong, set the environment variable SDL_CONFIG\n");
 
1416
      printf("*** to point to the correct copy of sdl-config, and remove the file\n");
 
1417
      printf("*** config.cache before re-running configure\n");
 
1418
      return 1;
 
1419
    }
 
1420
}
 
1421
 
 
1422
 
 
1423
EOF
 
1424
if { (eval echo configure:1425: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 
1425
then
 
1426
  :
 
1427
else
 
1428
  echo "configure: failed program was:" >&5
 
1429
  cat conftest.$ac_ext >&5
 
1430
  rm -fr conftest*
 
1431
  no_sdl=yes
 
1432
fi
 
1433
rm -fr conftest*
 
1434
fi
 
1435
 
 
1436
       CFLAGS="$ac_save_CFLAGS"
 
1437
       LIBS="$ac_save_LIBS"
 
1438
     fi
 
1439
  fi
 
1440
  if test "x$no_sdl" = x ; then
 
1441
     echo "$ac_t""yes" 1>&6
 
1442
     has_sdl=1     
 
1443
  else
 
1444
     echo "$ac_t""no" 1>&6
 
1445
     if test "$SDL_CONFIG" = "no" ; then
 
1446
       echo "*** The sdl-config script installed by SDL could not be found"
 
1447
       echo "*** If SDL was installed in PREFIX, make sure PREFIX/bin is in"
 
1448
       echo "*** your path, or set the SDL_CONFIG environment variable to the"
 
1449
       echo "*** full path to sdl-config."
 
1450
     else
 
1451
       if test -f conf.sdltest ; then
 
1452
        :
 
1453
       else
 
1454
          echo "*** Could not run SDL test program, checking why..."
 
1455
          CFLAGS="$CFLAGS $SDL_CFLAGS"
 
1456
          LIBS="$LIBS $SDL_LIBS"
 
1457
          cat > conftest.$ac_ext <<EOF
 
1458
#line 1459 "configure"
 
1459
#include "confdefs.h"
 
1460
 
 
1461
#include <stdio.h>
 
1462
#include "SDL.h"
 
1463
 
 
1464
int main(int argc, char *argv[])
 
1465
{ return 0; }
 
1466
#undef  main
 
1467
#define main K_and_R_C_main
 
1468
 
 
1469
int main() {
 
1470
 return 0; 
 
1471
; return 0; }
 
1472
EOF
 
1473
if { (eval echo configure:1474: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
 
1474
  rm -rf conftest*
 
1475
   echo "*** The test program compiled, but did not run. This usually means"
 
1476
          echo "*** that the run-time linker is not finding SDL or finding the wrong"
 
1477
          echo "*** version of SDL. If it is not finding SDL, you'll need to set your"
 
1478
          echo "*** LD_LIBRARY_PATH environment variable, or edit /etc/ld.so.conf to point"
 
1479
          echo "*** to the installed location  Also, make sure you have run ldconfig if that"
 
1480
          echo "*** is required on your system"
 
1481
          echo "***"
 
1482
          echo "*** If you have an old version installed, it is best to remove it, although"
 
1483
          echo "*** you may also be able to get things to work by modifying LD_LIBRARY_PATH"
 
1484
else
 
1485
  echo "configure: failed program was:" >&5
 
1486
  cat conftest.$ac_ext >&5
 
1487
  rm -rf conftest*
 
1488
   echo "*** The test program failed to compile or link. See the file config.log for the"
 
1489
          echo "*** exact error that occured. This usually means SDL was incorrectly installed"
 
1490
          echo "*** or that you have moved SDL since it was installed. In the latter case, you"
 
1491
          echo "*** may want to edit the sdl-config script: $SDL_CONFIG" 
 
1492
fi
 
1493
rm -f conftest*
 
1494
          CFLAGS="$ac_save_CFLAGS"
 
1495
          LIBS="$ac_save_LIBS"
 
1496
       fi
 
1497
     fi
 
1498
     SDL_CFLAGS=""
 
1499
     SDL_LIBS=""
 
1500
     has_sdl=0 
 
1501
  fi
 
1502
  
 
1503
  
 
1504
  
 
1505
  
 
1506
  rm -f conf.sdltest
 
1507
 
 
1508
                  if test  ! $has_sdl ; then
 
1509
                                         echo "configure: warning: There is no libsdl found! e
 
1510
                                         xit!!" 1>&2;
 
1511
                                         exit -1;
 
1512
                  fi;
 
1513
fi
 
1514
 
 
1515
 
 
1516
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
 
1517
echo "configure:1518: checking how to run the C preprocessor" >&5
 
1518
# On Suns, sometimes $CPP names a directory.
 
1519
if test -n "$CPP" && test -d "$CPP"; then
 
1520
  CPP=
 
1521
fi
 
1522
if test -z "$CPP"; then
 
1523
if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
 
1524
  echo $ac_n "(cached) $ac_c" 1>&6
 
1525
else
 
1526
    # This must be in double quotes, not single quotes, because CPP may get
 
1527
  # substituted into the Makefile and "${CC-cc}" will confuse make.
 
1528
  CPP="${CC-cc} -E"
 
1529
  # On the NeXT, cc -E runs the code through the compiler's parser,
 
1530
  # not just through cpp.
 
1531
  cat > conftest.$ac_ext <<EOF
 
1532
#line 1533 "configure"
 
1533
#include "confdefs.h"
 
1534
#include <assert.h>
 
1535
Syntax Error
 
1536
EOF
 
1537
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
 
1538
{ (eval echo configure:1539: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 
1539
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 
1540
if test -z "$ac_err"; then
 
1541
  :
 
1542
else
 
1543
  echo "$ac_err" >&5
 
1544
  echo "configure: failed program was:" >&5
 
1545
  cat conftest.$ac_ext >&5
 
1546
  rm -rf conftest*
 
1547
  CPP="${CC-cc} -E -traditional-cpp"
 
1548
  cat > conftest.$ac_ext <<EOF
 
1549
#line 1550 "configure"
 
1550
#include "confdefs.h"
 
1551
#include <assert.h>
 
1552
Syntax Error
 
1553
EOF
 
1554
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
 
1555
{ (eval echo configure:1556: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 
1556
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 
1557
if test -z "$ac_err"; then
 
1558
  :
 
1559
else
 
1560
  echo "$ac_err" >&5
 
1561
  echo "configure: failed program was:" >&5
 
1562
  cat conftest.$ac_ext >&5
 
1563
  rm -rf conftest*
 
1564
  CPP="${CC-cc} -nologo -E"
 
1565
  cat > conftest.$ac_ext <<EOF
 
1566
#line 1567 "configure"
 
1567
#include "confdefs.h"
 
1568
#include <assert.h>
 
1569
Syntax Error
 
1570
EOF
 
1571
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
 
1572
{ (eval echo configure:1573: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 
1573
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 
1574
if test -z "$ac_err"; then
 
1575
  :
 
1576
else
 
1577
  echo "$ac_err" >&5
 
1578
  echo "configure: failed program was:" >&5
 
1579
  cat conftest.$ac_ext >&5
 
1580
  rm -rf conftest*
 
1581
  CPP=/lib/cpp
 
1582
fi
 
1583
rm -f conftest*
 
1584
fi
 
1585
rm -f conftest*
 
1586
fi
 
1587
rm -f conftest*
 
1588
  ac_cv_prog_CPP="$CPP"
 
1589
fi
 
1590
  CPP="$ac_cv_prog_CPP"
 
1591
else
 
1592
  ac_cv_prog_CPP="$CPP"
 
1593
fi
 
1594
echo "$ac_t""$CPP" 1>&6
 
1595
 
 
1596
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
 
1597
echo "configure:1598: checking for ANSI C header files" >&5
 
1598
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
 
1599
  echo $ac_n "(cached) $ac_c" 1>&6
 
1600
else
 
1601
  cat > conftest.$ac_ext <<EOF
 
1602
#line 1603 "configure"
 
1603
#include "confdefs.h"
 
1604
#include <stdlib.h>
 
1605
#include <stdarg.h>
 
1606
#include <string.h>
 
1607
#include <float.h>
 
1608
EOF
 
1609
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
 
1610
{ (eval echo configure:1611: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 
1611
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 
1612
if test -z "$ac_err"; then
 
1613
  rm -rf conftest*
 
1614
  ac_cv_header_stdc=yes
 
1615
else
 
1616
  echo "$ac_err" >&5
 
1617
  echo "configure: failed program was:" >&5
 
1618
  cat conftest.$ac_ext >&5
 
1619
  rm -rf conftest*
 
1620
  ac_cv_header_stdc=no
 
1621
fi
 
1622
rm -f conftest*
 
1623
 
 
1624
if test $ac_cv_header_stdc = yes; then
 
1625
  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
 
1626
cat > conftest.$ac_ext <<EOF
 
1627
#line 1628 "configure"
 
1628
#include "confdefs.h"
 
1629
#include <string.h>
 
1630
EOF
 
1631
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
 
1632
  egrep "memchr" >/dev/null 2>&1; then
 
1633
  :
 
1634
else
 
1635
  rm -rf conftest*
 
1636
  ac_cv_header_stdc=no
 
1637
fi
 
1638
rm -f conftest*
 
1639
 
 
1640
fi
 
1641
 
 
1642
if test $ac_cv_header_stdc = yes; then
 
1643
  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
 
1644
cat > conftest.$ac_ext <<EOF
 
1645
#line 1646 "configure"
 
1646
#include "confdefs.h"
 
1647
#include <stdlib.h>
 
1648
EOF
 
1649
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
 
1650
  egrep "free" >/dev/null 2>&1; then
 
1651
  :
 
1652
else
 
1653
  rm -rf conftest*
 
1654
  ac_cv_header_stdc=no
 
1655
fi
 
1656
rm -f conftest*
 
1657
 
 
1658
fi
 
1659
 
 
1660
if test $ac_cv_header_stdc = yes; then
 
1661
  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
 
1662
if test "$cross_compiling" = yes; then
 
1663
  :
 
1664
else
 
1665
  cat > conftest.$ac_ext <<EOF
 
1666
#line 1667 "configure"
 
1667
#include "confdefs.h"
 
1668
#include <ctype.h>
 
1669
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
 
1670
#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
 
1671
#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
 
1672
int main () { int i; for (i = 0; i < 256; i++)
 
1673
if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
 
1674
exit (0); }
 
1675
 
 
1676
EOF
 
1677
if { (eval echo configure:1678: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 
1678
then
 
1679
  :
 
1680
else
 
1681
  echo "configure: failed program was:" >&5
 
1682
  cat conftest.$ac_ext >&5
 
1683
  rm -fr conftest*
 
1684
  ac_cv_header_stdc=no
 
1685
fi
 
1686
rm -fr conftest*
 
1687
fi
 
1688
 
 
1689
fi
 
1690
fi
 
1691
 
 
1692
echo "$ac_t""$ac_cv_header_stdc" 1>&6
 
1693
if test $ac_cv_header_stdc = yes; then
 
1694
  cat >> confdefs.h <<\EOF
 
1695
#define STDC_HEADERS 1
 
1696
EOF
 
1697
 
 
1698
fi
 
1699
 
 
1700
for ac_hdr in unistd.h
 
1701
do
 
1702
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 
1703
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
 
1704
echo "configure:1705: checking for $ac_hdr" >&5
 
1705
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
 
1706
  echo $ac_n "(cached) $ac_c" 1>&6
 
1707
else
 
1708
  cat > conftest.$ac_ext <<EOF
 
1709
#line 1710 "configure"
 
1710
#include "confdefs.h"
 
1711
#include <$ac_hdr>
 
1712
EOF
 
1713
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
 
1714
{ (eval echo configure:1715: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 
1715
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 
1716
if test -z "$ac_err"; then
 
1717
  rm -rf conftest*
 
1718
  eval "ac_cv_header_$ac_safe=yes"
 
1719
else
 
1720
  echo "$ac_err" >&5
 
1721
  echo "configure: failed program was:" >&5
 
1722
  cat conftest.$ac_ext >&5
 
1723
  rm -rf conftest*
 
1724
  eval "ac_cv_header_$ac_safe=no"
 
1725
fi
 
1726
rm -f conftest*
 
1727
fi
 
1728
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
 
1729
  echo "$ac_t""yes" 1>&6
 
1730
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
 
1731
  cat >> confdefs.h <<EOF
 
1732
#define $ac_tr_hdr 1
 
1733
EOF
 
1734
 
 
1735
else
 
1736
  echo "$ac_t""no" 1>&6
 
1737
fi
 
1738
done
 
1739
 
 
1740
 
 
1741
 
 
1742
 
 
1743
 
 
1744
 
 
1745
trap '' 1 2 15
 
1746
cat > confcache <<\EOF
 
1747
# This file is a shell script that caches the results of configure
 
1748
# tests run on this system so they can be shared between configure
 
1749
# scripts and configure runs.  It is not useful on other systems.
 
1750
# If it contains results you don't want to keep, you may remove or edit it.
 
1751
#
 
1752
# By default, configure uses ./config.cache as the cache file,
 
1753
# creating it if it does not exist already.  You can give configure
 
1754
# the --cache-file=FILE option to use a different cache file; that is
 
1755
# what configure does when it calls configure scripts in
 
1756
# subdirectories, so they share the cache.
 
1757
# Giving --cache-file=/dev/null disables caching, for debugging configure.
 
1758
# config.status only pays attention to the cache file if you give it the
 
1759
# --recheck option to rerun configure.
 
1760
#
 
1761
EOF
 
1762
# The following way of writing the cache mishandles newlines in values,
 
1763
# but we know of no workaround that is simple, portable, and efficient.
 
1764
# So, don't put newlines in cache variables' values.
 
1765
# Ultrix sh set writes to stderr and can't be redirected directly,
 
1766
# and sets the high bit in the cache file unless we assign to the vars.
 
1767
(set) 2>&1 |
 
1768
  case `(ac_space=' '; set | grep ac_space) 2>&1` in
 
1769
  *ac_space=\ *)
 
1770
    # `set' does not quote correctly, so add quotes (double-quote substitution
 
1771
    # turns \\\\ into \\, and sed turns \\ into \).
 
1772
    sed -n \
 
1773
      -e "s/'/'\\\\''/g" \
 
1774
      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
 
1775
    ;;
 
1776
  *)
 
1777
    # `set' quotes correctly as required by POSIX, so do not add quotes.
 
1778
    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
 
1779
    ;;
 
1780
  esac >> confcache
 
1781
if cmp -s $cache_file confcache; then
 
1782
  :
 
1783
else
 
1784
  if test -w $cache_file; then
 
1785
    echo "updating cache $cache_file"
 
1786
    cat confcache > $cache_file
 
1787
  else
 
1788
    echo "not updating unwritable cache $cache_file"
 
1789
  fi
 
1790
fi
 
1791
rm -f confcache
 
1792
 
 
1793
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
 
1794
 
 
1795
test "x$prefix" = xNONE && prefix=$ac_default_prefix
 
1796
# Let make expand exec_prefix.
 
1797
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
 
1798
 
 
1799
# Any assignment to VPATH causes Sun make to only execute
 
1800
# the first set of double-colon rules, so remove it if not needed.
 
1801
# If there is a colon in the path, we need to keep it.
 
1802
if test "x$srcdir" = x.; then
 
1803
  ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
 
1804
fi
 
1805
 
 
1806
trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
 
1807
 
 
1808
DEFS=-DHAVE_CONFIG_H
 
1809
 
 
1810
# Without the "./", some shells look in PATH for config.status.
 
1811
: ${CONFIG_STATUS=./config.status}
 
1812
 
 
1813
echo creating $CONFIG_STATUS
 
1814
rm -f $CONFIG_STATUS
 
1815
cat > $CONFIG_STATUS <<EOF
 
1816
#! /bin/sh
 
1817
# Generated automatically by configure.
 
1818
# Run this file to recreate the current configuration.
 
1819
# This directory was configured as follows,
 
1820
# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
 
1821
#
 
1822
# $0 $ac_configure_args
 
1823
#
 
1824
# Compiler output produced by configure, useful for debugging
 
1825
# configure, is in ./config.log if it exists.
 
1826
 
 
1827
ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
 
1828
for ac_option
 
1829
do
 
1830
  case "\$ac_option" in
 
1831
  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
 
1832
    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
 
1833
    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
 
1834
  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
 
1835
    echo "$CONFIG_STATUS generated by autoconf version 2.13"
 
1836
    exit 0 ;;
 
1837
  -help | --help | --hel | --he | --h)
 
1838
    echo "\$ac_cs_usage"; exit 0 ;;
 
1839
  *) echo "\$ac_cs_usage"; exit 1 ;;
 
1840
  esac
 
1841
done
 
1842
 
 
1843
ac_given_srcdir=$srcdir
 
1844
ac_given_INSTALL="$INSTALL"
 
1845
 
 
1846
trap 'rm -fr `echo "Makefile src/Makefile src/config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
 
1847
EOF
 
1848
cat >> $CONFIG_STATUS <<EOF
 
1849
 
 
1850
# Protect against being on the right side of a sed subst in config.status.
 
1851
sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
 
1852
 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
 
1853
$ac_vpsub
 
1854
$extrasub
 
1855
s%@SHELL@%$SHELL%g
 
1856
s%@CFLAGS@%$CFLAGS%g
 
1857
s%@CPPFLAGS@%$CPPFLAGS%g
 
1858
s%@CXXFLAGS@%$CXXFLAGS%g
 
1859
s%@FFLAGS@%$FFLAGS%g
 
1860
s%@DEFS@%$DEFS%g
 
1861
s%@LDFLAGS@%$LDFLAGS%g
 
1862
s%@LIBS@%$LIBS%g
 
1863
s%@exec_prefix@%$exec_prefix%g
 
1864
s%@prefix@%$prefix%g
 
1865
s%@program_transform_name@%$program_transform_name%g
 
1866
s%@bindir@%$bindir%g
 
1867
s%@sbindir@%$sbindir%g
 
1868
s%@libexecdir@%$libexecdir%g
 
1869
s%@datadir@%$datadir%g
 
1870
s%@sysconfdir@%$sysconfdir%g
 
1871
s%@sharedstatedir@%$sharedstatedir%g
 
1872
s%@localstatedir@%$localstatedir%g
 
1873
s%@libdir@%$libdir%g
 
1874
s%@includedir@%$includedir%g
 
1875
s%@oldincludedir@%$oldincludedir%g
 
1876
s%@infodir@%$infodir%g
 
1877
s%@mandir@%$mandir%g
 
1878
s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
 
1879
s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
 
1880
s%@INSTALL_DATA@%$INSTALL_DATA%g
 
1881
s%@PACKAGE@%$PACKAGE%g
 
1882
s%@VERSION@%$VERSION%g
 
1883
s%@ACLOCAL@%$ACLOCAL%g
 
1884
s%@AUTOCONF@%$AUTOCONF%g
 
1885
s%@AUTOMAKE@%$AUTOMAKE%g
 
1886
s%@AUTOHEADER@%$AUTOHEADER%g
 
1887
s%@MAKEINFO@%$MAKEINFO%g
 
1888
s%@SET_MAKE@%$SET_MAKE%g
 
1889
s%@ISODATE@%$ISODATE%g
 
1890
s%@host@%$host%g
 
1891
s%@host_alias@%$host_alias%g
 
1892
s%@host_cpu@%$host_cpu%g
 
1893
s%@host_vendor@%$host_vendor%g
 
1894
s%@host_os@%$host_os%g
 
1895
s%@CC@%$CC%g
 
1896
s%@CXX@%$CXX%g
 
1897
s%@SDL_CONFIG@%$SDL_CONFIG%g
 
1898
s%@SDL_CFLAGS@%$SDL_CFLAGS%g
 
1899
s%@SDL_LIBS@%$SDL_LIBS%g
 
1900
s%@SDL_LIBS_FOR_LIBS@%$SDL_LIBS_FOR_LIBS%g
 
1901
s%@SDL_LIBS_FOR_PLUGINS@%$SDL_LIBS_FOR_PLUGINS%g
 
1902
s%@CPP@%$CPP%g
 
1903
s%@LIBSDL_LIB@%$LIBSDL_LIB%g
 
1904
s%@src pkgdatadir@%$src pkgdatadir%g
 
1905
 
 
1906
CEOF
 
1907
EOF
 
1908
 
 
1909
cat >> $CONFIG_STATUS <<\EOF
 
1910
 
 
1911
# Split the substitutions into bite-sized pieces for seds with
 
1912
# small command number limits, like on Digital OSF/1 and HP-UX.
 
1913
ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
 
1914
ac_file=1 # Number of current file.
 
1915
ac_beg=1 # First line for current file.
 
1916
ac_end=$ac_max_sed_cmds # Line after last line for current file.
 
1917
ac_more_lines=:
 
1918
ac_sed_cmds=""
 
1919
while $ac_more_lines; do
 
1920
  if test $ac_beg -gt 1; then
 
1921
    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
 
1922
  else
 
1923
    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
 
1924
  fi
 
1925
  if test ! -s conftest.s$ac_file; then
 
1926
    ac_more_lines=false
 
1927
    rm -f conftest.s$ac_file
 
1928
  else
 
1929
    if test -z "$ac_sed_cmds"; then
 
1930
      ac_sed_cmds="sed -f conftest.s$ac_file"
 
1931
    else
 
1932
      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
 
1933
    fi
 
1934
    ac_file=`expr $ac_file + 1`
 
1935
    ac_beg=$ac_end
 
1936
    ac_end=`expr $ac_end + $ac_max_sed_cmds`
 
1937
  fi
 
1938
done
 
1939
if test -z "$ac_sed_cmds"; then
 
1940
  ac_sed_cmds=cat
 
1941
fi
 
1942
EOF
 
1943
 
 
1944
cat >> $CONFIG_STATUS <<EOF
 
1945
 
 
1946
CONFIG_FILES=\${CONFIG_FILES-"Makefile src/Makefile"}
 
1947
EOF
 
1948
cat >> $CONFIG_STATUS <<\EOF
 
1949
for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
 
1950
  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
 
1951
  case "$ac_file" in
 
1952
  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
 
1953
       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
 
1954
  *) ac_file_in="${ac_file}.in" ;;
 
1955
  esac
 
1956
 
 
1957
  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
 
1958
 
 
1959
  # Remove last slash and all that follows it.  Not all systems have dirname.
 
1960
  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
 
1961
  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
 
1962
    # The file is in a subdirectory.
 
1963
    test ! -d "$ac_dir" && mkdir "$ac_dir"
 
1964
    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
 
1965
    # A "../" for each directory in $ac_dir_suffix.
 
1966
    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
 
1967
  else
 
1968
    ac_dir_suffix= ac_dots=
 
1969
  fi
 
1970
 
 
1971
  case "$ac_given_srcdir" in
 
1972
  .)  srcdir=.
 
1973
      if test -z "$ac_dots"; then top_srcdir=.
 
1974
      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
 
1975
  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
 
1976
  *) # Relative path.
 
1977
    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
 
1978
    top_srcdir="$ac_dots$ac_given_srcdir" ;;
 
1979
  esac
 
1980
 
 
1981
  case "$ac_given_INSTALL" in
 
1982
  [/$]*) INSTALL="$ac_given_INSTALL" ;;
 
1983
  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
 
1984
  esac
 
1985
 
 
1986
  echo creating "$ac_file"
 
1987
  rm -f "$ac_file"
 
1988
  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
 
1989
  case "$ac_file" in
 
1990
  *Makefile*) ac_comsub="1i\\
 
1991
# $configure_input" ;;
 
1992
  *) ac_comsub= ;;
 
1993
  esac
 
1994
 
 
1995
  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
 
1996
  sed -e "$ac_comsub
 
1997
s%@configure_input@%$configure_input%g
 
1998
s%@srcdir@%$srcdir%g
 
1999
s%@top_srcdir@%$top_srcdir%g
 
2000
s%@INSTALL@%$INSTALL%g
 
2001
" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
 
2002
fi; done
 
2003
rm -f conftest.s*
 
2004
 
 
2005
# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
 
2006
# NAME is the cpp macro being defined and VALUE is the value it is being given.
 
2007
#
 
2008
# ac_d sets the value in "#define NAME VALUE" lines.
 
2009
ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
 
2010
ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
 
2011
ac_dC='\3'
 
2012
ac_dD='%g'
 
2013
# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
 
2014
ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
 
2015
ac_uB='\([      ]\)%\1#\2define\3'
 
2016
ac_uC=' '
 
2017
ac_uD='\4%g'
 
2018
# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
 
2019
ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
 
2020
ac_eB='$%\1#\2define\3'
 
2021
ac_eC=' '
 
2022
ac_eD='%g'
 
2023
 
 
2024
if test "${CONFIG_HEADERS+set}" != set; then
 
2025
EOF
 
2026
cat >> $CONFIG_STATUS <<EOF
 
2027
  CONFIG_HEADERS="src/config.h"
 
2028
EOF
 
2029
cat >> $CONFIG_STATUS <<\EOF
 
2030
fi
 
2031
for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
 
2032
  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
 
2033
  case "$ac_file" in
 
2034
  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
 
2035
       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
 
2036
  *) ac_file_in="${ac_file}.in" ;;
 
2037
  esac
 
2038
 
 
2039
  echo creating $ac_file
 
2040
 
 
2041
  rm -f conftest.frag conftest.in conftest.out
 
2042
  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
 
2043
  cat $ac_file_inputs > conftest.in
 
2044
 
 
2045
EOF
 
2046
 
 
2047
# Transform confdefs.h into a sed script conftest.vals that substitutes
 
2048
# the proper values into config.h.in to produce config.h.  And first:
 
2049
# Protect against being on the right side of a sed subst in config.status.
 
2050
# Protect against being in an unquoted here document in config.status.
 
2051
rm -f conftest.vals
 
2052
cat > conftest.hdr <<\EOF
 
2053
s/[\\&%]/\\&/g
 
2054
s%[\\$`]%\\&%g
 
2055
s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
 
2056
s%ac_d%ac_u%gp
 
2057
s%ac_u%ac_e%gp
 
2058
EOF
 
2059
sed -n -f conftest.hdr confdefs.h > conftest.vals
 
2060
rm -f conftest.hdr
 
2061
 
 
2062
# This sed command replaces #undef with comments.  This is necessary, for
 
2063
# example, in the case of _POSIX_SOURCE, which is predefined and required
 
2064
# on some systems where configure will not decide to define it.
 
2065
cat >> conftest.vals <<\EOF
 
2066
s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
 
2067
EOF
 
2068
 
 
2069
# Break up conftest.vals because some shells have a limit on
 
2070
# the size of here documents, and old seds have small limits too.
 
2071
 
 
2072
rm -f conftest.tail
 
2073
while :
 
2074
do
 
2075
  ac_lines=`grep -c . conftest.vals`
 
2076
  # grep -c gives empty output for an empty file on some AIX systems.
 
2077
  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
 
2078
  # Write a limited-size here document to conftest.frag.
 
2079
  echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
 
2080
  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
 
2081
  echo 'CEOF
 
2082
  sed -f conftest.frag conftest.in > conftest.out
 
2083
  rm -f conftest.in
 
2084
  mv conftest.out conftest.in
 
2085
' >> $CONFIG_STATUS
 
2086
  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
 
2087
  rm -f conftest.vals
 
2088
  mv conftest.tail conftest.vals
 
2089
done
 
2090
rm -f conftest.vals
 
2091
 
 
2092
cat >> $CONFIG_STATUS <<\EOF
 
2093
  rm -f conftest.frag conftest.h
 
2094
  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
 
2095
  cat conftest.in >> conftest.h
 
2096
  rm -f conftest.in
 
2097
  if cmp -s $ac_file conftest.h 2>/dev/null; then
 
2098
    echo "$ac_file is unchanged"
 
2099
    rm -f conftest.h
 
2100
  else
 
2101
    # Remove last slash and all that follows it.  Not all systems have dirname.
 
2102
      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
 
2103
      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
 
2104
      # The file is in a subdirectory.
 
2105
      test ! -d "$ac_dir" && mkdir "$ac_dir"
 
2106
    fi
 
2107
    rm -f $ac_file
 
2108
    mv conftest.h $ac_file
 
2109
  fi
 
2110
fi; done
 
2111
 
 
2112
EOF
 
2113
cat >> $CONFIG_STATUS <<EOF
 
2114
 
 
2115
 
 
2116
EOF
 
2117
cat >> $CONFIG_STATUS <<\EOF
 
2118
test -z "$CONFIG_HEADERS" || echo timestamp > src/stamp-h
 
2119
 
 
2120
exit 0
 
2121
EOF
 
2122
chmod +x $CONFIG_STATUS
 
2123
rm -fr confdefs* $ac_clean_files
 
2124
test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
 
2125