OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [gdb-5.3/] [sim/] [ppc/] [configure] - Blame information for rev 1181

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 1181 sfurman
#! /bin/sh
2
 
3
 
4
 
5
 
6
 
7
 
8
 
9
 
10
 
11
 
12
 
13
 
14
 
15
 
16
 
17
 
18
 
19
 
20
 
21
 
22
 
23
 
24
 
25
 
26
 
27
 
28
 
29
 
30
 
31
 
32
 
33
 
34
 
35
 
36
 
37
 
38
 
39
 
40
 
41
 
42
 
43
 
44
 
45
sim_inline="-DDEFAULT_INLINE=0"
46
 
47
 
48
 
49
 
50
 
51
 
52
 
53
 
54
 
55
 
56
 
57
 
58
 
59
 
60
 
61
 
62
 
63
 
64
 
65
 
66
 
67
 
68
 
69
 
70
 
71
 
72
 
73
 
74
 
75
 
76
 
77
 
78
 
79
 
80
 
81
 
82
# This file is derived from `gettext.m4'.  The difference is that the
83
# included macros assume Cygnus-style source and build trees.
84
 
85
# Macro to add for using GNU gettext.
86
# Ulrich Drepper , 1995.
87
#
88
# This file file be copied and used freely without restrictions.  It can
89
# be used in projects which are not available under the GNU Public License
90
# but which still want to provide support for the GNU gettext functionality.
91
# Please note that the actual code is *not* freely available.
92
 
93
# serial 3
94
 
95
 
96
 
97
 
98
 
99
# Search path for a program which passes the given test.
100
# Ulrich Drepper , 1996.
101
#
102
# This file file be copied and used freely without restrictions.  It can
103
# be used in projects which are not available under the GNU Public License
104
# but which still want to provide support for the GNU gettext functionality.
105
# Please note that the actual code is *not* freely available.
106
 
107
# serial 1
108
 
109
 
110
 
111
# Check whether LC_MESSAGES is available in .
112
# Ulrich Drepper , 1995.
113
#
114
# This file file be copied and used freely without restrictions.  It can
115
# be used in projects which are not available under the GNU Public License
116
# but which still want to provide support for the GNU gettext functionality.
117
# Please note that the actual code is *not* freely available.
118
 
119
# serial 1
120
 
121
 
122
 
123
 
124
 
125
 
126
# Guess values for system-dependent variables and create Makefiles.
127
# Generated automatically using autoconf version 2.13
128
# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
129
#
130
# This configure script is free software; the Free Software Foundation
131
# gives unlimited permission to copy, distribute and modify it.
132
 
133
# Defaults:
134
ac_help=
135
ac_default_prefix=/usr/local
136
# Any additions from configure.in:
137
ac_help="$ac_help
138
  --disable-nls           do not use Native Language Support"
139
ac_help="$ac_help
140
  --with-included-gettext use the GNU gettext library included here"
141
ac_help="$ac_help
142
  --enable-sim-alignment=align          Specify strict or nonstrict alignment."
143
ac_help="$ac_help
144
  --enable-sim-assert                   Specify whether to perform random assertions."
145
ac_help="$ac_help
146
  --enable-sim-bitsize=n                Specify target bitsize (32 or 64)."
147
ac_help="$ac_help
148
  --enable-sim-bswap                    Use the BSWAP instruction on Intel 486s and Pentiums."
149
ac_help="$ac_help
150
  --enable-sim-cflags=opts              Extra CFLAGS for use in building simulator"
151
ac_help="$ac_help
152
  --enable-sim-config=file              Override default config file"
153
ac_help="$ac_help
154
  --enable-sim-decode-mechanism=which           Specify the instruction decode mechanism."
155
ac_help="$ac_help
156
  --enable-sim-default-model=which      Specify default PowerPC to model."
157
ac_help="$ac_help
158
  --enable-sim-duplicate                Expand (duplicate) semantic functions."
159
ac_help="$ac_help
160
  --enable-sim-endian=endian            Specify target byte endian orientation."
161
ac_help="$ac_help
162
  --enable-sim-env=env                  Specify target environment (operating, virtual, user)."
163
ac_help="$ac_help
164
  --enable-sim-filter=rule              Specify filter rules."
165
ac_help="$ac_help
166
  --enable-sim-float                    Specify whether to use host floating point or simulate."
167
ac_help="$ac_help
168
  --enable-sim-hardware=list            Specify the hardware to be included in the build."
169
ac_help="$ac_help
170
  --enable-sim-hostbitsize=32|64        Specify host bitsize (32 or 64)."
171
ac_help="$ac_help
172
  --enable-sim-hostendian=end           Specify host byte endian orientation."
173
ac_help="$ac_help
174
  --enable-sim-icache=size              Specify instruction-decode cache size and type."
175
ac_help="$ac_help
176
  --enable-sim-inline=inlines           Specify which functions should be inlined."
177
ac_help="$ac_help
178
  --enable-sim-jump             Jump between semantic code (instead of call/return)."
179
ac_help="$ac_help
180
  --enable-sim-line-nr=opts             Generate extra CPP code that references source rather than generated code"
181
ac_help="$ac_help
182
  --enable-sim-model=which              Specify PowerPC to model."
183
ac_help="$ac_help
184
  --enable-sim-model-issue              Specify whether to simulate model specific actions"
185
ac_help="$ac_help
186
  --enable-sim-monitor=mon              Specify whether to enable monitoring events."
187
ac_help="$ac_help
188
  --enable-sim-opcode=which             Override default opcode lookup."
189
ac_help="$ac_help
190
  --enable-sim-packages=list            Specify the packages to be included in the build."
191
ac_help="$ac_help
192
  --enable-sim-regparm=nr-parm          Pass parameters in registers instead of on the stack - x86/GCC specific."
193
ac_help="$ac_help
194
  --enable-sim-reserved-bits            Specify whether to check reserved bits in instruction."
195
ac_help="$ac_help
196
  --enable-sim-smp=n                    Specify number of processors to configure for."
197
ac_help="$ac_help
198
  --enable-sim-stdcall=type             Use an alternative function call/return mechanism - x86/GCC specific."
199
ac_help="$ac_help
200
  --enable-sim-stdio                    Specify whether to use stdio for console input/output."
201
ac_help="$ac_help
202
  --enable-sim-switch                   Use a switch instead of a table for instruction call."
203
ac_help="$ac_help
204
  --enable-sim-timebase                 Specify whether the PPC timebase is supported."
205
ac_help="$ac_help
206
  --enable-sim-trace                    Specify whether tracing is supported."
207
ac_help="$ac_help
208
  --enable-sim-warnings=opts            Extra CFLAGS for turning on compiler warnings except for idecode.o, semantics.o and psim.o"
209
ac_help="$ac_help
210
  --enable-sim-xor-endian=n             Specify number bytes involved in PowerPC XOR bi-endian mode (default 8)."
211
 
212
# Initialize some variables set by options.
213
# The variables have the same names as the options, with
214
# dashes changed to underlines.
215
build=NONE
216
cache_file=./config.cache
217
exec_prefix=NONE
218
host=NONE
219
no_create=
220
nonopt=NONE
221
no_recursion=
222
prefix=NONE
223
program_prefix=NONE
224
program_suffix=NONE
225
program_transform_name=s,x,x,
226
silent=
227
site=
228
sitefile=
229
srcdir=
230
target=NONE
231
verbose=
232
x_includes=NONE
233
x_libraries=NONE
234
bindir='${exec_prefix}/bin'
235
sbindir='${exec_prefix}/sbin'
236
libexecdir='${exec_prefix}/libexec'
237
datadir='${prefix}/share'
238
sysconfdir='${prefix}/etc'
239
sharedstatedir='${prefix}/com'
240
localstatedir='${prefix}/var'
241
libdir='${exec_prefix}/lib'
242
includedir='${prefix}/include'
243
oldincludedir='/usr/include'
244
infodir='${prefix}/info'
245
mandir='${prefix}/man'
246
 
247
# Initialize some other variables.
248
subdirs=
249
MFLAGS= MAKEFLAGS=
250
SHELL=${CONFIG_SHELL-/bin/sh}
251
# Maximum number of lines to put in a shell here document.
252
ac_max_here_lines=12
253
 
254
ac_prev=
255
for ac_option
256
do
257
 
258
  # If the previous option needs an argument, assign it.
259
  if test -n "$ac_prev"; then
260
    eval "$ac_prev=\$ac_option"
261
    ac_prev=
262
    continue
263
  fi
264
 
265
  case "$ac_option" in
266
  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
267
  *) ac_optarg= ;;
268
  esac
269
 
270
  # Accept the important Cygnus configure options, so we can diagnose typos.
271
 
272
  case "$ac_option" in
273
 
274
  -bindir | --bindir | --bindi | --bind | --bin | --bi)
275
    ac_prev=bindir ;;
276
  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
277
    bindir="$ac_optarg" ;;
278
 
279
  -build | --build | --buil | --bui | --bu)
280
    ac_prev=build ;;
281
  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
282
    build="$ac_optarg" ;;
283
 
284
  -cache-file | --cache-file | --cache-fil | --cache-fi \
285
  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
286
    ac_prev=cache_file ;;
287
  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
288
  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
289
    cache_file="$ac_optarg" ;;
290
 
291
  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
292
    ac_prev=datadir ;;
293
  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
294
  | --da=*)
295
    datadir="$ac_optarg" ;;
296
 
297
  -disable-* | --disable-*)
298
    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
299
    # Reject names that are not valid shell variable names.
300
    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
301
      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
302
    fi
303
    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
304
    eval "enable_${ac_feature}=no" ;;
305
 
306
  -enable-* | --enable-*)
307
    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
308
    # Reject names that are not valid shell variable names.
309
    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
310
      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
311
    fi
312
    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
313
    case "$ac_option" in
314
      *=*) ;;
315
      *) ac_optarg=yes ;;
316
    esac
317
    eval "enable_${ac_feature}='$ac_optarg'" ;;
318
 
319
  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
320
  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
321
  | --exec | --exe | --ex)
322
    ac_prev=exec_prefix ;;
323
  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
324
  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
325
  | --exec=* | --exe=* | --ex=*)
326
    exec_prefix="$ac_optarg" ;;
327
 
328
  -gas | --gas | --ga | --g)
329
    # Obsolete; use --with-gas.
330
    with_gas=yes ;;
331
 
332
  -help | --help | --hel | --he)
333
    # Omit some internal or obsolete options to make the list less imposing.
334
    # This message is too long to be a string in the A/UX 3.1 sh.
335
    cat << EOF
336
Usage: configure [options] [host]
337
Options: [defaults in brackets after descriptions]
338
Configuration:
339
  --cache-file=FILE       cache test results in FILE
340
  --help                  print this message
341
  --no-create             do not create output files
342
  --quiet, --silent       do not print \`checking...' messages
343
  --site-file=FILE        use FILE as the site file
344
  --version               print the version of autoconf that created configure
345
Directory and file names:
346
  --prefix=PREFIX         install architecture-independent files in PREFIX
347
                          [$ac_default_prefix]
348
  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
349
                          [same as prefix]
350
  --bindir=DIR            user executables in DIR [EPREFIX/bin]
351
  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
352
  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
353
  --datadir=DIR           read-only architecture-independent data in DIR
354
                          [PREFIX/share]
355
  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
356
  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
357
                          [PREFIX/com]
358
  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
359
  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
360
  --includedir=DIR        C header files in DIR [PREFIX/include]
361
  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
362
  --infodir=DIR           info documentation in DIR [PREFIX/info]
363
  --mandir=DIR            man documentation in DIR [PREFIX/man]
364
  --srcdir=DIR            find the sources in DIR [configure dir or ..]
365
  --program-prefix=PREFIX prepend PREFIX to installed program names
366
  --program-suffix=SUFFIX append SUFFIX to installed program names
367
  --program-transform-name=PROGRAM
368
                          run sed PROGRAM on installed program names
369
EOF
370
    cat << EOF
371
Host type:
372
  --build=BUILD           configure for building on BUILD [BUILD=HOST]
373
  --host=HOST             configure for HOST [guessed]
374
  --target=TARGET         configure for TARGET [TARGET=HOST]
375
Features and packages:
376
  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
377
  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
378
  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
379
  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
380
  --x-includes=DIR        X include files are in DIR
381
  --x-libraries=DIR       X library files are in DIR
382
EOF
383
    if test -n "$ac_help"; then
384
      echo "--enable and --with options recognized:$ac_help"
385
    fi
386
    exit 0 ;;
387
 
388
  -host | --host | --hos | --ho)
389
    ac_prev=host ;;
390
  -host=* | --host=* | --hos=* | --ho=*)
391
    host="$ac_optarg" ;;
392
 
393
  -includedir | --includedir | --includedi | --included | --include \
394
  | --includ | --inclu | --incl | --inc)
395
    ac_prev=includedir ;;
396
  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
397
  | --includ=* | --inclu=* | --incl=* | --inc=*)
398
    includedir="$ac_optarg" ;;
399
 
400
  -infodir | --infodir | --infodi | --infod | --info | --inf)
401
    ac_prev=infodir ;;
402
  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
403
    infodir="$ac_optarg" ;;
404
 
405
  -libdir | --libdir | --libdi | --libd)
406
    ac_prev=libdir ;;
407
  -libdir=* | --libdir=* | --libdi=* | --libd=*)
408
    libdir="$ac_optarg" ;;
409
 
410
  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
411
  | --libexe | --libex | --libe)
412
    ac_prev=libexecdir ;;
413
  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
414
  | --libexe=* | --libex=* | --libe=*)
415
    libexecdir="$ac_optarg" ;;
416
 
417
  -localstatedir | --localstatedir | --localstatedi | --localstated \
418
  | --localstate | --localstat | --localsta | --localst \
419
  | --locals | --local | --loca | --loc | --lo)
420
    ac_prev=localstatedir ;;
421
  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
422
  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
423
  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
424
    localstatedir="$ac_optarg" ;;
425
 
426
  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
427
    ac_prev=mandir ;;
428
  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
429
    mandir="$ac_optarg" ;;
430
 
431
  -nfp | --nfp | --nf)
432
    # Obsolete; use --without-fp.
433
    with_fp=no ;;
434
 
435
  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
436
  | --no-cr | --no-c)
437
    no_create=yes ;;
438
 
439
  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
440
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
441
    no_recursion=yes ;;
442
 
443
  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
444
  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
445
  | --oldin | --oldi | --old | --ol | --o)
446
    ac_prev=oldincludedir ;;
447
  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
448
  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
449
  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
450
    oldincludedir="$ac_optarg" ;;
451
 
452
  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
453
    ac_prev=prefix ;;
454
  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
455
    prefix="$ac_optarg" ;;
456
 
457
  -program-prefix | --program-prefix | --program-prefi | --program-pref \
458
  | --program-pre | --program-pr | --program-p)
459
    ac_prev=program_prefix ;;
460
  -program-prefix=* | --program-prefix=* | --program-prefi=* \
461
  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
462
    program_prefix="$ac_optarg" ;;
463
 
464
  -program-suffix | --program-suffix | --program-suffi | --program-suff \
465
  | --program-suf | --program-su | --program-s)
466
    ac_prev=program_suffix ;;
467
  -program-suffix=* | --program-suffix=* | --program-suffi=* \
468
  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
469
    program_suffix="$ac_optarg" ;;
470
 
471
  -program-transform-name | --program-transform-name \
472
  | --program-transform-nam | --program-transform-na \
473
  | --program-transform-n | --program-transform- \
474
  | --program-transform | --program-transfor \
475
  | --program-transfo | --program-transf \
476
  | --program-trans | --program-tran \
477
  | --progr-tra | --program-tr | --program-t)
478
    ac_prev=program_transform_name ;;
479
  -program-transform-name=* | --program-transform-name=* \
480
  | --program-transform-nam=* | --program-transform-na=* \
481
  | --program-transform-n=* | --program-transform-=* \
482
  | --program-transform=* | --program-transfor=* \
483
  | --program-transfo=* | --program-transf=* \
484
  | --program-trans=* | --program-tran=* \
485
  | --progr-tra=* | --program-tr=* | --program-t=*)
486
    program_transform_name="$ac_optarg" ;;
487
 
488
  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
489
  | -silent | --silent | --silen | --sile | --sil)
490
    silent=yes ;;
491
 
492
  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
493
    ac_prev=sbindir ;;
494
  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
495
  | --sbi=* | --sb=*)
496
    sbindir="$ac_optarg" ;;
497
 
498
  -sharedstatedir | --sharedstatedir | --sharedstatedi \
499
  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
500
  | --sharedst | --shareds | --shared | --share | --shar \
501
  | --sha | --sh)
502
    ac_prev=sharedstatedir ;;
503
  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
504
  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
505
  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
506
  | --sha=* | --sh=*)
507
    sharedstatedir="$ac_optarg" ;;
508
 
509
  -site | --site | --sit)
510
    ac_prev=site ;;
511
  -site=* | --site=* | --sit=*)
512
    site="$ac_optarg" ;;
513
 
514
  -site-file | --site-file | --site-fil | --site-fi | --site-f)
515
    ac_prev=sitefile ;;
516
  -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
517
    sitefile="$ac_optarg" ;;
518
 
519
  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
520
    ac_prev=srcdir ;;
521
  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
522
    srcdir="$ac_optarg" ;;
523
 
524
  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
525
  | --syscon | --sysco | --sysc | --sys | --sy)
526
    ac_prev=sysconfdir ;;
527
  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
528
  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
529
    sysconfdir="$ac_optarg" ;;
530
 
531
  -target | --target | --targe | --targ | --tar | --ta | --t)
532
    ac_prev=target ;;
533
  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
534
    target="$ac_optarg" ;;
535
 
536
  -v | -verbose | --verbose | --verbos | --verbo | --verb)
537
    verbose=yes ;;
538
 
539
  -version | --version | --versio | --versi | --vers)
540
    echo "configure generated by autoconf version 2.13"
541
    exit 0 ;;
542
 
543
  -with-* | --with-*)
544
    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
545
    # Reject names that are not valid shell variable names.
546
    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
547
      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
548
    fi
549
    ac_package=`echo $ac_package| sed 's/-/_/g'`
550
    case "$ac_option" in
551
      *=*) ;;
552
      *) ac_optarg=yes ;;
553
    esac
554
    eval "with_${ac_package}='$ac_optarg'" ;;
555
 
556
  -without-* | --without-*)
557
    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
558
    # Reject names that are not valid shell variable names.
559
    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
560
      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
561
    fi
562
    ac_package=`echo $ac_package| sed 's/-/_/g'`
563
    eval "with_${ac_package}=no" ;;
564
 
565
  --x)
566
    # Obsolete; use --with-x.
567
    with_x=yes ;;
568
 
569
  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
570
  | --x-incl | --x-inc | --x-in | --x-i)
571
    ac_prev=x_includes ;;
572
  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
573
  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
574
    x_includes="$ac_optarg" ;;
575
 
576
  -x-libraries | --x-libraries | --x-librarie | --x-librari \
577
  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
578
    ac_prev=x_libraries ;;
579
  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
580
  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
581
    x_libraries="$ac_optarg" ;;
582
 
583
  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
584
    ;;
585
 
586
  *)
587
    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
588
      echo "configure: warning: $ac_option: invalid host type" 1>&2
589
    fi
590
    if test "x$nonopt" != xNONE; then
591
      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
592
    fi
593
    nonopt="$ac_option"
594
    ;;
595
 
596
  esac
597
done
598
 
599
if test -n "$ac_prev"; then
600
  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
601
fi
602
 
603
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
604
 
605
# File descriptor usage:
606
# 0 standard input
607
# 1 file creation
608
# 2 errors and warnings
609
# 3 some systems may open it to /dev/tty
610
# 4 used on the Kubota Titan
611
# 6 checking for... messages and results
612
# 5 compiler messages saved in config.log
613
if test "$silent" = yes; then
614
  exec 6>/dev/null
615
else
616
  exec 6>&1
617
fi
618
exec 5>./config.log
619
 
620
echo "\
621
This file contains any messages produced by compilers while
622
running configure, to aid debugging if configure makes a mistake.
623
" 1>&5
624
 
625
# Strip out --no-create and --no-recursion so they do not pile up.
626
# Also quote any args containing shell metacharacters.
627
ac_configure_args=
628
for ac_arg
629
do
630
  case "$ac_arg" in
631
  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
632
  | --no-cr | --no-c) ;;
633
  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
634
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
635
  *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
636
  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
637
  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
638
  esac
639
done
640
 
641
# NLS nuisances.
642
# Only set these to C if already set.  These must not be set unconditionally
643
# because not all systems understand e.g. LANG=C (notably SCO).
644
# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
645
# Non-C LC_CTYPE values break the ctype check.
646
if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
647
if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
648
if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
649
if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
650
 
651
# confdefs.h avoids OS command line length limits that DEFS can exceed.
652
rm -rf conftest* confdefs.h
653
# AIX cpp loses on an empty file, so make sure it contains at least a newline.
654
echo > confdefs.h
655
 
656
# A filename unique to this package, relative to the directory that
657
# configure is in, which we can look for to find out if srcdir is correct.
658
ac_unique_file=Makefile.in
659
 
660
# Find the source files, if location was not specified.
661
if test -z "$srcdir"; then
662
  ac_srcdir_defaulted=yes
663
  # Try the directory containing this script, then its parent.
664
  ac_prog=$0
665
  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
666
  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
667
  srcdir=$ac_confdir
668
  if test ! -r $srcdir/$ac_unique_file; then
669
    srcdir=..
670
  fi
671
else
672
  ac_srcdir_defaulted=no
673
fi
674
if test ! -r $srcdir/$ac_unique_file; then
675
  if test "$ac_srcdir_defaulted" = yes; then
676
    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
677
  else
678
    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
679
  fi
680
fi
681
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
682
 
683
# Prefer explicitly selected file to automatically selected ones.
684
if test -z "$sitefile"; then
685
  if test -z "$CONFIG_SITE"; then
686
    if test "x$prefix" != xNONE; then
687
      CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
688
    else
689
      CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
690
    fi
691
  fi
692
else
693
  CONFIG_SITE="$sitefile"
694
fi
695
for ac_site_file in $CONFIG_SITE; do
696
  if test -r "$ac_site_file"; then
697
    echo "loading site script $ac_site_file"
698
    . "$ac_site_file"
699
  fi
700
done
701
 
702
if test -r "$cache_file"; then
703
  echo "loading cache $cache_file"
704
  . $cache_file
705
else
706
  echo "creating cache $cache_file"
707
  > $cache_file
708
fi
709
 
710
ac_ext=c
711
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
712
ac_cpp='$CPP $CPPFLAGS'
713
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
714
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
715
cross_compiling=$ac_cv_prog_cc_cross
716
 
717
ac_exeext=
718
ac_objext=o
719
if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
720
  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
721
  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
722
    ac_n= ac_c='
723
' ac_t='        '
724
  else
725
    ac_n=-n ac_c= ac_t=
726
  fi
727
else
728
  ac_n= ac_c='\c' ac_t=
729
fi
730
 
731
 
732
 
733
ac_aux_dir=
734
for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
735
  if test -f $ac_dir/install-sh; then
736
    ac_aux_dir=$ac_dir
737
    ac_install_sh="$ac_aux_dir/install-sh -c"
738
    break
739
  elif test -f $ac_dir/install.sh; then
740
    ac_aux_dir=$ac_dir
741
    ac_install_sh="$ac_aux_dir/install.sh -c"
742
    break
743
  fi
744
done
745
if test -z "$ac_aux_dir"; then
746
  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
747
fi
748
ac_config_guess=$ac_aux_dir/config.guess
749
ac_config_sub=$ac_aux_dir/config.sub
750
ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
751
 
752
# Find a good install program.  We prefer a C program (faster),
753
# so one script is as good as another.  But avoid the broken or
754
# incompatible versions:
755
# SysV /etc/install, /usr/sbin/install
756
# SunOS /usr/etc/install
757
# IRIX /sbin/install
758
# AIX /bin/install
759
# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
760
# AFS /usr/afsws/bin/install, which mishandles nonexistent args
761
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
762
# ./install, which can be erroneously created by make from ./install.sh.
763
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
764
echo "configure:765: checking for a BSD compatible install" >&5
765
if test -z "$INSTALL"; then
766
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
767
  echo $ac_n "(cached) $ac_c" 1>&6
768
else
769
    IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
770
  for ac_dir in $PATH; do
771
    # Account for people who put trailing slashes in PATH elements.
772
    case "$ac_dir/" in
773
    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
774
    *)
775
      # OSF1 and SCO ODT 3.0 have their own names for install.
776
      # Don't use installbsd from OSF since it installs stuff as root
777
      # by default.
778
      for ac_prog in ginstall scoinst install; do
779
        if test -f $ac_dir/$ac_prog; then
780
          if test $ac_prog = install &&
781
            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
782
            # AIX install.  It has an incompatible calling convention.
783
            :
784
          else
785
            ac_cv_path_install="$ac_dir/$ac_prog -c"
786
            break 2
787
          fi
788
        fi
789
      done
790
      ;;
791
    esac
792
  done
793
  IFS="$ac_save_IFS"
794
 
795
fi
796
  if test "${ac_cv_path_install+set}" = set; then
797
    INSTALL="$ac_cv_path_install"
798
  else
799
    # As a last resort, use the slow shell script.  We don't cache a
800
    # path for INSTALL within a source directory, because that will
801
    # break other packages using the cache if that directory is
802
    # removed, or if the path is relative.
803
    INSTALL="$ac_install_sh"
804
  fi
805
fi
806
echo "$ac_t""$INSTALL" 1>&6
807
 
808
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
809
# It thinks the first close brace ends the variable substitution.
810
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
811
 
812
test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
813
 
814
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
815
 
816
# Extract the first word of "gcc", so it can be a program name with args.
817
set dummy gcc; ac_word=$2
818
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
819
echo "configure:820: checking for $ac_word" >&5
820
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
821
  echo $ac_n "(cached) $ac_c" 1>&6
822
else
823
  if test -n "$CC"; then
824
  ac_cv_prog_CC="$CC" # Let the user override the test.
825
else
826
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
827
  ac_dummy="$PATH"
828
  for ac_dir in $ac_dummy; do
829
    test -z "$ac_dir" && ac_dir=.
830
    if test -f $ac_dir/$ac_word; then
831
      ac_cv_prog_CC="gcc"
832
      break
833
    fi
834
  done
835
  IFS="$ac_save_ifs"
836
fi
837
fi
838
CC="$ac_cv_prog_CC"
839
if test -n "$CC"; then
840
  echo "$ac_t""$CC" 1>&6
841
else
842
  echo "$ac_t""no" 1>&6
843
fi
844
 
845
if test -z "$CC"; then
846
  # Extract the first word of "cc", so it can be a program name with args.
847
set dummy cc; ac_word=$2
848
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
849
echo "configure:850: checking for $ac_word" >&5
850
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
851
  echo $ac_n "(cached) $ac_c" 1>&6
852
else
853
  if test -n "$CC"; then
854
  ac_cv_prog_CC="$CC" # Let the user override the test.
855
else
856
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
857
  ac_prog_rejected=no
858
  ac_dummy="$PATH"
859
  for ac_dir in $ac_dummy; do
860
    test -z "$ac_dir" && ac_dir=.
861
    if test -f $ac_dir/$ac_word; then
862
      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
863
        ac_prog_rejected=yes
864
        continue
865
      fi
866
      ac_cv_prog_CC="cc"
867
      break
868
    fi
869
  done
870
  IFS="$ac_save_ifs"
871
if test $ac_prog_rejected = yes; then
872
  # We found a bogon in the path, so make sure we never use it.
873
  set dummy $ac_cv_prog_CC
874
  shift
875
  if test $# -gt 0; then
876
    # We chose a different compiler from the bogus one.
877
    # However, it has the same basename, so the bogon will be chosen
878
    # first if we set CC to just the basename; use the full file name.
879
    shift
880
    set dummy "$ac_dir/$ac_word" "$@"
881
    shift
882
    ac_cv_prog_CC="$@"
883
  fi
884
fi
885
fi
886
fi
887
CC="$ac_cv_prog_CC"
888
if test -n "$CC"; then
889
  echo "$ac_t""$CC" 1>&6
890
else
891
  echo "$ac_t""no" 1>&6
892
fi
893
 
894
  if test -z "$CC"; then
895
    case "`uname -s`" in
896
    *win32* | *WIN32*)
897
      # Extract the first word of "cl", so it can be a program name with args.
898
set dummy cl; ac_word=$2
899
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
900
echo "configure:901: checking for $ac_word" >&5
901
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
902
  echo $ac_n "(cached) $ac_c" 1>&6
903
else
904
  if test -n "$CC"; then
905
  ac_cv_prog_CC="$CC" # Let the user override the test.
906
else
907
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
908
  ac_dummy="$PATH"
909
  for ac_dir in $ac_dummy; do
910
    test -z "$ac_dir" && ac_dir=.
911
    if test -f $ac_dir/$ac_word; then
912
      ac_cv_prog_CC="cl"
913
      break
914
    fi
915
  done
916
  IFS="$ac_save_ifs"
917
fi
918
fi
919
CC="$ac_cv_prog_CC"
920
if test -n "$CC"; then
921
  echo "$ac_t""$CC" 1>&6
922
else
923
  echo "$ac_t""no" 1>&6
924
fi
925
 ;;
926
    esac
927
  fi
928
  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
929
fi
930
 
931
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
932
echo "configure:933: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
933
 
934
ac_ext=c
935
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
936
ac_cpp='$CPP $CPPFLAGS'
937
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
938
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
939
cross_compiling=$ac_cv_prog_cc_cross
940
 
941
cat > conftest.$ac_ext << EOF
942
 
943
#line 944 "configure"
944
#include "confdefs.h"
945
 
946
main(){return(0);}
947
EOF
948
if { (eval echo configure:949: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
949
  ac_cv_prog_cc_works=yes
950
  # If we can't run a trivial program, we are probably using a cross compiler.
951
  if (./conftest; exit) 2>/dev/null; then
952
    ac_cv_prog_cc_cross=no
953
  else
954
    ac_cv_prog_cc_cross=yes
955
  fi
956
else
957
  echo "configure: failed program was:" >&5
958
  cat conftest.$ac_ext >&5
959
  ac_cv_prog_cc_works=no
960
fi
961
rm -fr conftest*
962
ac_ext=c
963
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
964
ac_cpp='$CPP $CPPFLAGS'
965
ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
966
ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
967
cross_compiling=$ac_cv_prog_cc_cross
968
 
969
echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
970
if test $ac_cv_prog_cc_works = no; then
971
  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
972
fi
973
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
974
echo "configure:975: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
975
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
976
cross_compiling=$ac_cv_prog_cc_cross
977
 
978
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
979
echo "configure:980: checking whether we are using GNU C" >&5
980
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
981
  echo $ac_n "(cached) $ac_c" 1>&6
982
else
983
  cat > conftest.c <
984
#ifdef __GNUC__
985
  yes;
986
#endif
987
EOF
988
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:989: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
989
  ac_cv_prog_gcc=yes
990
else
991
  ac_cv_prog_gcc=no
992
fi
993
fi
994
 
995
echo "$ac_t""$ac_cv_prog_gcc" 1>&6
996
 
997
if test $ac_cv_prog_gcc = yes; then
998
  GCC=yes
999
else
1000
  GCC=
1001
fi
1002
 
1003
ac_test_CFLAGS="${CFLAGS+set}"
1004
ac_save_CFLAGS="$CFLAGS"
1005
CFLAGS=
1006
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1007
echo "configure:1008: checking whether ${CC-cc} accepts -g" >&5
1008
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1009
  echo $ac_n "(cached) $ac_c" 1>&6
1010
else
1011
  echo 'void f(){}' > conftest.c
1012
if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1013
  ac_cv_prog_cc_g=yes
1014
else
1015
  ac_cv_prog_cc_g=no
1016
fi
1017
rm -f conftest*
1018
 
1019
fi
1020
 
1021
echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1022
if test "$ac_test_CFLAGS" = set; then
1023
  CFLAGS="$ac_save_CFLAGS"
1024
elif test $ac_cv_prog_cc_g = yes; then
1025
  if test "$GCC" = yes; then
1026
    CFLAGS="-g -O2"
1027
  else
1028
    CFLAGS="-g"
1029
  fi
1030
else
1031
  if test "$GCC" = yes; then
1032
    CFLAGS="-O2"
1033
  else
1034
    CFLAGS=
1035
  fi
1036
fi
1037
 
1038
 
1039
# Put a plausible default for CC_FOR_BUILD in Makefile.
1040
if test "x$cross_compiling" = "xno"; then
1041
  CC_FOR_BUILD='$(CC)'
1042
else
1043
  CC_FOR_BUILD=gcc
1044
fi
1045
 
1046
ALL_LINGUAS=
1047
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1048
echo "configure:1049: checking how to run the C preprocessor" >&5
1049
# On Suns, sometimes $CPP names a directory.
1050
if test -n "$CPP" && test -d "$CPP"; then
1051
  CPP=
1052
fi
1053
if test -z "$CPP"; then
1054
if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1055
  echo $ac_n "(cached) $ac_c" 1>&6
1056
else
1057
    # This must be in double quotes, not single quotes, because CPP may get
1058
  # substituted into the Makefile and "${CC-cc}" will confuse make.
1059
  CPP="${CC-cc} -E"
1060
  # On the NeXT, cc -E runs the code through the compiler's parser,
1061
  # not just through cpp.
1062
  cat > conftest.$ac_ext <
1063
#line 1064 "configure"
1064
#include "confdefs.h"
1065
#include 
1066
Syntax Error
1067
EOF
1068
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1069
{ (eval echo configure:1070: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1070
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1071
if test -z "$ac_err"; then
1072
  :
1073
else
1074
  echo "$ac_err" >&5
1075
  echo "configure: failed program was:" >&5
1076
  cat conftest.$ac_ext >&5
1077
  rm -rf conftest*
1078
  CPP="${CC-cc} -E -traditional-cpp"
1079
  cat > conftest.$ac_ext <
1080
#line 1081 "configure"
1081
#include "confdefs.h"
1082
#include 
1083
Syntax Error
1084
EOF
1085
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1086
{ (eval echo configure:1087: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1087
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1088
if test -z "$ac_err"; then
1089
  :
1090
else
1091
  echo "$ac_err" >&5
1092
  echo "configure: failed program was:" >&5
1093
  cat conftest.$ac_ext >&5
1094
  rm -rf conftest*
1095
  CPP="${CC-cc} -nologo -E"
1096
  cat > conftest.$ac_ext <
1097
#line 1098 "configure"
1098
#include "confdefs.h"
1099
#include 
1100
Syntax Error
1101
EOF
1102
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1103
{ (eval echo configure:1104: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1104
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1105
if test -z "$ac_err"; then
1106
  :
1107
else
1108
  echo "$ac_err" >&5
1109
  echo "configure: failed program was:" >&5
1110
  cat conftest.$ac_ext >&5
1111
  rm -rf conftest*
1112
  CPP=/lib/cpp
1113
fi
1114
rm -f conftest*
1115
fi
1116
rm -f conftest*
1117
fi
1118
rm -f conftest*
1119
  ac_cv_prog_CPP="$CPP"
1120
fi
1121
  CPP="$ac_cv_prog_CPP"
1122
else
1123
  ac_cv_prog_CPP="$CPP"
1124
fi
1125
echo "$ac_t""$CPP" 1>&6
1126
 
1127
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
1128
echo "configure:1129: checking whether ${MAKE-make} sets \${MAKE}" >&5
1129
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1130
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1131
  echo $ac_n "(cached) $ac_c" 1>&6
1132
else
1133
  cat > conftestmake <<\EOF
1134
all:
1135
        @echo 'ac_maketemp="${MAKE}"'
1136
EOF
1137
# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1138
eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1139
if test -n "$ac_maketemp"; then
1140
  eval ac_cv_prog_make_${ac_make}_set=yes
1141
else
1142
  eval ac_cv_prog_make_${ac_make}_set=no
1143
fi
1144
rm -f conftestmake
1145
fi
1146
if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1147
  echo "$ac_t""yes" 1>&6
1148
  SET_MAKE=
1149
else
1150
  echo "$ac_t""no" 1>&6
1151
  SET_MAKE="MAKE=${MAKE-make}"
1152
fi
1153
 
1154
# Extract the first word of "ranlib", so it can be a program name with args.
1155
set dummy ranlib; ac_word=$2
1156
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1157
echo "configure:1158: checking for $ac_word" >&5
1158
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1159
  echo $ac_n "(cached) $ac_c" 1>&6
1160
else
1161
  if test -n "$RANLIB"; then
1162
  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1163
else
1164
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1165
  ac_dummy="$PATH"
1166
  for ac_dir in $ac_dummy; do
1167
    test -z "$ac_dir" && ac_dir=.
1168
    if test -f $ac_dir/$ac_word; then
1169
      ac_cv_prog_RANLIB="ranlib"
1170
      break
1171
    fi
1172
  done
1173
  IFS="$ac_save_ifs"
1174
  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1175
fi
1176
fi
1177
RANLIB="$ac_cv_prog_RANLIB"
1178
if test -n "$RANLIB"; then
1179
  echo "$ac_t""$RANLIB" 1>&6
1180
else
1181
  echo "$ac_t""no" 1>&6
1182
fi
1183
 
1184
echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
1185
echo "configure:1186: checking for POSIXized ISC" >&5
1186
if test -d /etc/conf/kconfig.d &&
1187
  grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
1188
then
1189
  echo "$ac_t""yes" 1>&6
1190
  ISC=yes # If later tests want to check for ISC.
1191
  cat >> confdefs.h <<\EOF
1192
#define _POSIX_SOURCE 1
1193
EOF
1194
 
1195
  if test "$GCC" = yes; then
1196
    CC="$CC -posix"
1197
  else
1198
    CC="$CC -Xp"
1199
  fi
1200
else
1201
  echo "$ac_t""no" 1>&6
1202
  ISC=
1203
fi
1204
 
1205
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1206
echo "configure:1207: checking for ANSI C header files" >&5
1207
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1208
  echo $ac_n "(cached) $ac_c" 1>&6
1209
else
1210
  cat > conftest.$ac_ext <
1211
#line 1212 "configure"
1212
#include "confdefs.h"
1213
#include 
1214
#include 
1215
#include 
1216
#include 
1217
EOF
1218
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1219
{ (eval echo configure:1220: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1220
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1221
if test -z "$ac_err"; then
1222
  rm -rf conftest*
1223
  ac_cv_header_stdc=yes
1224
else
1225
  echo "$ac_err" >&5
1226
  echo "configure: failed program was:" >&5
1227
  cat conftest.$ac_ext >&5
1228
  rm -rf conftest*
1229
  ac_cv_header_stdc=no
1230
fi
1231
rm -f conftest*
1232
 
1233
if test $ac_cv_header_stdc = yes; then
1234
  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1235
cat > conftest.$ac_ext <
1236
#line 1237 "configure"
1237
#include "confdefs.h"
1238
#include 
1239
EOF
1240
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1241
  egrep "memchr" >/dev/null 2>&1; then
1242
  :
1243
else
1244
  rm -rf conftest*
1245
  ac_cv_header_stdc=no
1246
fi
1247
rm -f conftest*
1248
 
1249
fi
1250
 
1251
if test $ac_cv_header_stdc = yes; then
1252
  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1253
cat > conftest.$ac_ext <
1254
#line 1255 "configure"
1255
#include "confdefs.h"
1256
#include 
1257
EOF
1258
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1259
  egrep "free" >/dev/null 2>&1; then
1260
  :
1261
else
1262
  rm -rf conftest*
1263
  ac_cv_header_stdc=no
1264
fi
1265
rm -f conftest*
1266
 
1267
fi
1268
 
1269
if test $ac_cv_header_stdc = yes; then
1270
  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1271
if test "$cross_compiling" = yes; then
1272
  :
1273
else
1274
  cat > conftest.$ac_ext <
1275
#line 1276 "configure"
1276
#include "confdefs.h"
1277
#include 
1278
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1279
#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1280
#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1281
int main () { int i; for (i = 0; i < 256; i++)
1282
if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1283
exit (0); }
1284
 
1285
EOF
1286
if { (eval echo configure:1287: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1287
then
1288
  :
1289
else
1290
  echo "configure: failed program was:" >&5
1291
  cat conftest.$ac_ext >&5
1292
  rm -fr conftest*
1293
  ac_cv_header_stdc=no
1294
fi
1295
rm -fr conftest*
1296
fi
1297
 
1298
fi
1299
fi
1300
 
1301
echo "$ac_t""$ac_cv_header_stdc" 1>&6
1302
if test $ac_cv_header_stdc = yes; then
1303
  cat >> confdefs.h <<\EOF
1304
#define STDC_HEADERS 1
1305
EOF
1306
 
1307
fi
1308
 
1309
echo $ac_n "checking for working const""... $ac_c" 1>&6
1310
echo "configure:1311: checking for working const" >&5
1311
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
1312
  echo $ac_n "(cached) $ac_c" 1>&6
1313
else
1314
  cat > conftest.$ac_ext <
1315
#line 1316 "configure"
1316
#include "confdefs.h"
1317
 
1318
int main() {
1319
 
1320
/* Ultrix mips cc rejects this.  */
1321
typedef int charset[2]; const charset x;
1322
/* SunOS 4.1.1 cc rejects this.  */
1323
char const *const *ccp;
1324
char **p;
1325
/* NEC SVR4.0.2 mips cc rejects this.  */
1326
struct point {int x, y;};
1327
static struct point const zero = {0,0};
1328
/* AIX XL C 1.02.0.0 rejects this.
1329
   It does not let you subtract one const X* pointer from another in an arm
1330
   of an if-expression whose if-part is not a constant expression */
1331
const char *g = "string";
1332
ccp = &g + (g ? g-g : 0);
1333
/* HPUX 7.0 cc rejects these. */
1334
++ccp;
1335
p = (char**) ccp;
1336
ccp = (char const *const *) p;
1337
{ /* SCO 3.2v4 cc rejects this.  */
1338
  char *t;
1339
  char const *s = 0 ? (char *) 0 : (char const *) 0;
1340
 
1341
  *t++ = 0;
1342
}
1343
{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
1344
  int x[] = {25, 17};
1345
  const int *foo = &x[0];
1346
  ++foo;
1347
}
1348
{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
1349
  typedef const int *iptr;
1350
  iptr p = 0;
1351
  ++p;
1352
}
1353
{ /* AIX XL C 1.02.0.0 rejects this saying
1354
     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
1355
  struct s { int j; const int *ap[3]; };
1356
  struct s *b; b->j = 5;
1357
}
1358
{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
1359
  const int foo = 10;
1360
}
1361
 
1362
; return 0; }
1363
EOF
1364
if { (eval echo configure:1365: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1365
  rm -rf conftest*
1366
  ac_cv_c_const=yes
1367
else
1368
  echo "configure: failed program was:" >&5
1369
  cat conftest.$ac_ext >&5
1370
  rm -rf conftest*
1371
  ac_cv_c_const=no
1372
fi
1373
rm -f conftest*
1374
fi
1375
 
1376
echo "$ac_t""$ac_cv_c_const" 1>&6
1377
if test $ac_cv_c_const = no; then
1378
  cat >> confdefs.h <<\EOF
1379
#define const
1380
EOF
1381
 
1382
fi
1383
 
1384
echo $ac_n "checking for inline""... $ac_c" 1>&6
1385
echo "configure:1386: checking for inline" >&5
1386
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
1387
  echo $ac_n "(cached) $ac_c" 1>&6
1388
else
1389
  ac_cv_c_inline=no
1390
for ac_kw in inline __inline__ __inline; do
1391
  cat > conftest.$ac_ext <
1392
#line 1393 "configure"
1393
#include "confdefs.h"
1394
 
1395
int main() {
1396
} $ac_kw foo() {
1397
; return 0; }
1398
EOF
1399
if { (eval echo configure:1400: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1400
  rm -rf conftest*
1401
  ac_cv_c_inline=$ac_kw; break
1402
else
1403
  echo "configure: failed program was:" >&5
1404
  cat conftest.$ac_ext >&5
1405
fi
1406
rm -f conftest*
1407
done
1408
 
1409
fi
1410
 
1411
echo "$ac_t""$ac_cv_c_inline" 1>&6
1412
case "$ac_cv_c_inline" in
1413
  inline | yes) ;;
1414
  no) cat >> confdefs.h <<\EOF
1415
#define inline
1416
EOF
1417
 ;;
1418
  *)  cat >> confdefs.h <
1419
#define inline $ac_cv_c_inline
1420
EOF
1421
 ;;
1422
esac
1423
 
1424
echo $ac_n "checking for off_t""... $ac_c" 1>&6
1425
echo "configure:1426: checking for off_t" >&5
1426
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
1427
  echo $ac_n "(cached) $ac_c" 1>&6
1428
else
1429
  cat > conftest.$ac_ext <
1430
#line 1431 "configure"
1431
#include "confdefs.h"
1432
#include 
1433
#if STDC_HEADERS
1434
#include 
1435
#include 
1436
#endif
1437
EOF
1438
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1439
  egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1440
  rm -rf conftest*
1441
  ac_cv_type_off_t=yes
1442
else
1443
  rm -rf conftest*
1444
  ac_cv_type_off_t=no
1445
fi
1446
rm -f conftest*
1447
 
1448
fi
1449
echo "$ac_t""$ac_cv_type_off_t" 1>&6
1450
if test $ac_cv_type_off_t = no; then
1451
  cat >> confdefs.h <<\EOF
1452
#define off_t long
1453
EOF
1454
 
1455
fi
1456
 
1457
echo $ac_n "checking for size_t""... $ac_c" 1>&6
1458
echo "configure:1459: checking for size_t" >&5
1459
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
1460
  echo $ac_n "(cached) $ac_c" 1>&6
1461
else
1462
  cat > conftest.$ac_ext <
1463
#line 1464 "configure"
1464
#include "confdefs.h"
1465
#include 
1466
#if STDC_HEADERS
1467
#include 
1468
#include 
1469
#endif
1470
EOF
1471
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1472
  egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1473
  rm -rf conftest*
1474
  ac_cv_type_size_t=yes
1475
else
1476
  rm -rf conftest*
1477
  ac_cv_type_size_t=no
1478
fi
1479
rm -f conftest*
1480
 
1481
fi
1482
echo "$ac_t""$ac_cv_type_size_t" 1>&6
1483
if test $ac_cv_type_size_t = no; then
1484
  cat >> confdefs.h <<\EOF
1485
#define size_t unsigned
1486
EOF
1487
 
1488
fi
1489
 
1490
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
1491
# for constant arguments.  Useless!
1492
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
1493
echo "configure:1494: checking for working alloca.h" >&5
1494
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
1495
  echo $ac_n "(cached) $ac_c" 1>&6
1496
else
1497
  cat > conftest.$ac_ext <
1498
#line 1499 "configure"
1499
#include "confdefs.h"
1500
#include 
1501
int main() {
1502
char *p = alloca(2 * sizeof(int));
1503
; return 0; }
1504
EOF
1505
if { (eval echo configure:1506: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1506
  rm -rf conftest*
1507
  ac_cv_header_alloca_h=yes
1508
else
1509
  echo "configure: failed program was:" >&5
1510
  cat conftest.$ac_ext >&5
1511
  rm -rf conftest*
1512
  ac_cv_header_alloca_h=no
1513
fi
1514
rm -f conftest*
1515
fi
1516
 
1517
echo "$ac_t""$ac_cv_header_alloca_h" 1>&6
1518
if test $ac_cv_header_alloca_h = yes; then
1519
  cat >> confdefs.h <<\EOF
1520
#define HAVE_ALLOCA_H 1
1521
EOF
1522
 
1523
fi
1524
 
1525
echo $ac_n "checking for alloca""... $ac_c" 1>&6
1526
echo "configure:1527: checking for alloca" >&5
1527
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
1528
  echo $ac_n "(cached) $ac_c" 1>&6
1529
else
1530
  cat > conftest.$ac_ext <
1531
#line 1532 "configure"
1532
#include "confdefs.h"
1533
 
1534
#ifdef __GNUC__
1535
# define alloca __builtin_alloca
1536
#else
1537
# ifdef _MSC_VER
1538
#  include 
1539
#  define alloca _alloca
1540
# else
1541
#  if HAVE_ALLOCA_H
1542
#   include 
1543
#  else
1544
#   ifdef _AIX
1545
 #pragma alloca
1546
#   else
1547
#    ifndef alloca /* predefined by HP cc +Olibcalls */
1548
char *alloca ();
1549
#    endif
1550
#   endif
1551
#  endif
1552
# endif
1553
#endif
1554
 
1555
int main() {
1556
char *p = (char *) alloca(1);
1557
; return 0; }
1558
EOF
1559
if { (eval echo configure:1560: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1560
  rm -rf conftest*
1561
  ac_cv_func_alloca_works=yes
1562
else
1563
  echo "configure: failed program was:" >&5
1564
  cat conftest.$ac_ext >&5
1565
  rm -rf conftest*
1566
  ac_cv_func_alloca_works=no
1567
fi
1568
rm -f conftest*
1569
fi
1570
 
1571
echo "$ac_t""$ac_cv_func_alloca_works" 1>&6
1572
if test $ac_cv_func_alloca_works = yes; then
1573
  cat >> confdefs.h <<\EOF
1574
#define HAVE_ALLOCA 1
1575
EOF
1576
 
1577
fi
1578
 
1579
if test $ac_cv_func_alloca_works = no; then
1580
  # The SVR3 libPW and SVR4 libucb both contain incompatible functions
1581
  # that cause trouble.  Some versions do not even contain alloca or
1582
  # contain a buggy version.  If you still want to use their alloca,
1583
  # use ar to extract alloca.o from them instead of compiling alloca.c.
1584
  ALLOCA=alloca.${ac_objext}
1585
  cat >> confdefs.h <<\EOF
1586
#define C_ALLOCA 1
1587
EOF
1588
 
1589
 
1590
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
1591
echo "configure:1592: checking whether alloca needs Cray hooks" >&5
1592
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
1593
  echo $ac_n "(cached) $ac_c" 1>&6
1594
else
1595
  cat > conftest.$ac_ext <
1596
#line 1597 "configure"
1597
#include "confdefs.h"
1598
#if defined(CRAY) && ! defined(CRAY2)
1599
webecray
1600
#else
1601
wenotbecray
1602
#endif
1603
 
1604
EOF
1605
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1606
  egrep "webecray" >/dev/null 2>&1; then
1607
  rm -rf conftest*
1608
  ac_cv_os_cray=yes
1609
else
1610
  rm -rf conftest*
1611
  ac_cv_os_cray=no
1612
fi
1613
rm -f conftest*
1614
 
1615
fi
1616
 
1617
echo "$ac_t""$ac_cv_os_cray" 1>&6
1618
if test $ac_cv_os_cray = yes; then
1619
for ac_func in _getb67 GETB67 getb67; do
1620
  echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1621
echo "configure:1622: checking for $ac_func" >&5
1622
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1623
  echo $ac_n "(cached) $ac_c" 1>&6
1624
else
1625
  cat > conftest.$ac_ext <
1626
#line 1627 "configure"
1627
#include "confdefs.h"
1628
/* System header to define __stub macros and hopefully few prototypes,
1629
    which can conflict with char $ac_func(); below.  */
1630
#include 
1631
/* Override any gcc2 internal prototype to avoid an error.  */
1632
/* We use char because int might match the return type of a gcc2
1633
    builtin and then its argument prototype would still apply.  */
1634
char $ac_func();
1635
 
1636
int main() {
1637
 
1638
/* The GNU C library defines this for functions which it implements
1639
    to always fail with ENOSYS.  Some functions are actually named
1640
    something starting with __ and the normal name is an alias.  */
1641
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1642
choke me
1643
#else
1644
$ac_func();
1645
#endif
1646
 
1647
; return 0; }
1648
EOF
1649
if { (eval echo configure:1650: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1650
  rm -rf conftest*
1651
  eval "ac_cv_func_$ac_func=yes"
1652
else
1653
  echo "configure: failed program was:" >&5
1654
  cat conftest.$ac_ext >&5
1655
  rm -rf conftest*
1656
  eval "ac_cv_func_$ac_func=no"
1657
fi
1658
rm -f conftest*
1659
fi
1660
 
1661
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1662
  echo "$ac_t""yes" 1>&6
1663
  cat >> confdefs.h <
1664
#define CRAY_STACKSEG_END $ac_func
1665
EOF
1666
 
1667
  break
1668
else
1669
  echo "$ac_t""no" 1>&6
1670
fi
1671
 
1672
done
1673
fi
1674
 
1675
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
1676
echo "configure:1677: checking stack direction for C alloca" >&5
1677
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
1678
  echo $ac_n "(cached) $ac_c" 1>&6
1679
else
1680
  if test "$cross_compiling" = yes; then
1681
  ac_cv_c_stack_direction=0
1682
else
1683
  cat > conftest.$ac_ext <
1684
#line 1685 "configure"
1685
#include "confdefs.h"
1686
find_stack_direction ()
1687
{
1688
  static char *addr = 0;
1689
  auto char dummy;
1690
  if (addr == 0)
1691
    {
1692
      addr = &dummy;
1693
      return find_stack_direction ();
1694
    }
1695
  else
1696
    return (&dummy > addr) ? 1 : -1;
1697
}
1698
main ()
1699
{
1700
  exit (find_stack_direction() < 0);
1701
}
1702
EOF
1703
if { (eval echo configure:1704: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1704
then
1705
  ac_cv_c_stack_direction=1
1706
else
1707
  echo "configure: failed program was:" >&5
1708
  cat conftest.$ac_ext >&5
1709
  rm -fr conftest*
1710
  ac_cv_c_stack_direction=-1
1711
fi
1712
rm -fr conftest*
1713
fi
1714
 
1715
fi
1716
 
1717
echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
1718
cat >> confdefs.h <
1719
#define STACK_DIRECTION $ac_cv_c_stack_direction
1720
EOF
1721
 
1722
fi
1723
 
1724
for ac_hdr in unistd.h
1725
do
1726
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1727
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1728
echo "configure:1729: checking for $ac_hdr" >&5
1729
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1730
  echo $ac_n "(cached) $ac_c" 1>&6
1731
else
1732
  cat > conftest.$ac_ext <
1733
#line 1734 "configure"
1734
#include "confdefs.h"
1735
#include <$ac_hdr>
1736
EOF
1737
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1738
{ (eval echo configure:1739: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1739
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1740
if test -z "$ac_err"; then
1741
  rm -rf conftest*
1742
  eval "ac_cv_header_$ac_safe=yes"
1743
else
1744
  echo "$ac_err" >&5
1745
  echo "configure: failed program was:" >&5
1746
  cat conftest.$ac_ext >&5
1747
  rm -rf conftest*
1748
  eval "ac_cv_header_$ac_safe=no"
1749
fi
1750
rm -f conftest*
1751
fi
1752
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1753
  echo "$ac_t""yes" 1>&6
1754
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1755
  cat >> confdefs.h <
1756
#define $ac_tr_hdr 1
1757
EOF
1758
 
1759
else
1760
  echo "$ac_t""no" 1>&6
1761
fi
1762
done
1763
 
1764
for ac_func in getpagesize
1765
do
1766
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1767
echo "configure:1768: checking for $ac_func" >&5
1768
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1769
  echo $ac_n "(cached) $ac_c" 1>&6
1770
else
1771
  cat > conftest.$ac_ext <
1772
#line 1773 "configure"
1773
#include "confdefs.h"
1774
/* System header to define __stub macros and hopefully few prototypes,
1775
    which can conflict with char $ac_func(); below.  */
1776
#include 
1777
/* Override any gcc2 internal prototype to avoid an error.  */
1778
/* We use char because int might match the return type of a gcc2
1779
    builtin and then its argument prototype would still apply.  */
1780
char $ac_func();
1781
 
1782
int main() {
1783
 
1784
/* The GNU C library defines this for functions which it implements
1785
    to always fail with ENOSYS.  Some functions are actually named
1786
    something starting with __ and the normal name is an alias.  */
1787
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1788
choke me
1789
#else
1790
$ac_func();
1791
#endif
1792
 
1793
; return 0; }
1794
EOF
1795
if { (eval echo configure:1796: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1796
  rm -rf conftest*
1797
  eval "ac_cv_func_$ac_func=yes"
1798
else
1799
  echo "configure: failed program was:" >&5
1800
  cat conftest.$ac_ext >&5
1801
  rm -rf conftest*
1802
  eval "ac_cv_func_$ac_func=no"
1803
fi
1804
rm -f conftest*
1805
fi
1806
 
1807
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1808
  echo "$ac_t""yes" 1>&6
1809
    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1810
  cat >> confdefs.h <
1811
#define $ac_tr_func 1
1812
EOF
1813
 
1814
else
1815
  echo "$ac_t""no" 1>&6
1816
fi
1817
done
1818
 
1819
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
1820
echo "configure:1821: checking for working mmap" >&5
1821
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
1822
  echo $ac_n "(cached) $ac_c" 1>&6
1823
else
1824
  if test "$cross_compiling" = yes; then
1825
  ac_cv_func_mmap_fixed_mapped=no
1826
else
1827
  cat > conftest.$ac_ext <
1828
#line 1829 "configure"
1829
#include "confdefs.h"
1830
 
1831
/* Thanks to Mike Haertel and Jim Avera for this test.
1832
   Here is a matrix of mmap possibilities:
1833
        mmap private not fixed
1834
        mmap private fixed at somewhere currently unmapped
1835
        mmap private fixed at somewhere already mapped
1836
        mmap shared not fixed
1837
        mmap shared fixed at somewhere currently unmapped
1838
        mmap shared fixed at somewhere already mapped
1839
   For private mappings, we should verify that changes cannot be read()
1840
   back from the file, nor mmap's back from the file at a different
1841
   address.  (There have been systems where private was not correctly
1842
   implemented like the infamous i386 svr4.0, and systems where the
1843
   VM page cache was not coherent with the filesystem buffer cache
1844
   like early versions of FreeBSD and possibly contemporary NetBSD.)
1845
   For shared mappings, we should conversely verify that changes get
1846
   propogated back to all the places they're supposed to be.
1847
 
1848
   Grep wants private fixed already mapped.
1849
   The main things grep needs to know about mmap are:
1850
   * does it exist and is it safe to write into the mmap'd area
1851
   * how to use it (BSD variants)  */
1852
#include 
1853
#include 
1854
#include 
1855
 
1856
/* This mess was copied from the GNU getpagesize.h.  */
1857
#ifndef HAVE_GETPAGESIZE
1858
# ifdef HAVE_UNISTD_H
1859
#  include 
1860
# endif
1861
 
1862
/* Assume that all systems that can run configure have sys/param.h.  */
1863
# ifndef HAVE_SYS_PARAM_H
1864
#  define HAVE_SYS_PARAM_H 1
1865
# endif
1866
 
1867
# ifdef _SC_PAGESIZE
1868
#  define getpagesize() sysconf(_SC_PAGESIZE)
1869
# else /* no _SC_PAGESIZE */
1870
#  ifdef HAVE_SYS_PARAM_H
1871
#   include 
1872
#   ifdef EXEC_PAGESIZE
1873
#    define getpagesize() EXEC_PAGESIZE
1874
#   else /* no EXEC_PAGESIZE */
1875
#    ifdef NBPG
1876
#     define getpagesize() NBPG * CLSIZE
1877
#     ifndef CLSIZE
1878
#      define CLSIZE 1
1879
#     endif /* no CLSIZE */
1880
#    else /* no NBPG */
1881
#     ifdef NBPC
1882
#      define getpagesize() NBPC
1883
#     else /* no NBPC */
1884
#      ifdef PAGESIZE
1885
#       define getpagesize() PAGESIZE
1886
#      endif /* PAGESIZE */
1887
#     endif /* no NBPC */
1888
#    endif /* no NBPG */
1889
#   endif /* no EXEC_PAGESIZE */
1890
#  else /* no HAVE_SYS_PARAM_H */
1891
#   define getpagesize() 8192   /* punt totally */
1892
#  endif /* no HAVE_SYS_PARAM_H */
1893
# endif /* no _SC_PAGESIZE */
1894
 
1895
#endif /* no HAVE_GETPAGESIZE */
1896
 
1897
#ifdef __cplusplus
1898
extern "C" { void *malloc(unsigned); }
1899
#else
1900
char *malloc();
1901
#endif
1902
 
1903
int
1904
main()
1905
{
1906
        char *data, *data2, *data3;
1907
        int i, pagesize;
1908
        int fd;
1909
 
1910
        pagesize = getpagesize();
1911
 
1912
        /*
1913
         * First, make a file with some known garbage in it.
1914
         */
1915
        data = malloc(pagesize);
1916
        if (!data)
1917
                exit(1);
1918
        for (i = 0; i < pagesize; ++i)
1919
                *(data + i) = rand();
1920
        umask(0);
1921
        fd = creat("conftestmmap", 0600);
1922
        if (fd < 0)
1923
                exit(1);
1924
        if (write(fd, data, pagesize) != pagesize)
1925
                exit(1);
1926
        close(fd);
1927
 
1928
        /*
1929
         * Next, try to mmap the file at a fixed address which
1930
         * already has something else allocated at it.  If we can,
1931
         * also make sure that we see the same garbage.
1932
         */
1933
        fd = open("conftestmmap", O_RDWR);
1934
        if (fd < 0)
1935
                exit(1);
1936
        data2 = malloc(2 * pagesize);
1937
        if (!data2)
1938
                exit(1);
1939
        data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
1940
        if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
1941
            MAP_PRIVATE | MAP_FIXED, fd, 0L))
1942
                exit(1);
1943
        for (i = 0; i < pagesize; ++i)
1944
                if (*(data + i) != *(data2 + i))
1945
                        exit(1);
1946
 
1947
        /*
1948
         * Finally, make sure that changes to the mapped area
1949
         * do not percolate back to the file as seen by read().
1950
         * (This is a bug on some variants of i386 svr4.0.)
1951
         */
1952
        for (i = 0; i < pagesize; ++i)
1953
                *(data2 + i) = *(data2 + i) + 1;
1954
        data3 = malloc(pagesize);
1955
        if (!data3)
1956
                exit(1);
1957
        if (read(fd, data3, pagesize) != pagesize)
1958
                exit(1);
1959
        for (i = 0; i < pagesize; ++i)
1960
                if (*(data + i) != *(data3 + i))
1961
                        exit(1);
1962
        close(fd);
1963
        unlink("conftestmmap");
1964
        exit(0);
1965
}
1966
 
1967
EOF
1968
if { (eval echo configure:1969: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1969
then
1970
  ac_cv_func_mmap_fixed_mapped=yes
1971
else
1972
  echo "configure: failed program was:" >&5
1973
  cat conftest.$ac_ext >&5
1974
  rm -fr conftest*
1975
  ac_cv_func_mmap_fixed_mapped=no
1976
fi
1977
rm -fr conftest*
1978
fi
1979
 
1980
fi
1981
 
1982
echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
1983
if test $ac_cv_func_mmap_fixed_mapped = yes; then
1984
  cat >> confdefs.h <<\EOF
1985
#define HAVE_MMAP 1
1986
EOF
1987
 
1988
fi
1989
 
1990
 
1991
   for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \
1992
unistd.h values.h sys/param.h
1993
do
1994
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1995
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1996
echo "configure:1997: checking for $ac_hdr" >&5
1997
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1998
  echo $ac_n "(cached) $ac_c" 1>&6
1999
else
2000
  cat > conftest.$ac_ext <
2001
#line 2002 "configure"
2002
#include "confdefs.h"
2003
#include <$ac_hdr>
2004
EOF
2005
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2006
{ (eval echo configure:2007: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2007
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2008
if test -z "$ac_err"; then
2009
  rm -rf conftest*
2010
  eval "ac_cv_header_$ac_safe=yes"
2011
else
2012
  echo "$ac_err" >&5
2013
  echo "configure: failed program was:" >&5
2014
  cat conftest.$ac_ext >&5
2015
  rm -rf conftest*
2016
  eval "ac_cv_header_$ac_safe=no"
2017
fi
2018
rm -f conftest*
2019
fi
2020
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2021
  echo "$ac_t""yes" 1>&6
2022
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2023
  cat >> confdefs.h <
2024
#define $ac_tr_hdr 1
2025
EOF
2026
 
2027
else
2028
  echo "$ac_t""no" 1>&6
2029
fi
2030
done
2031
 
2032
   for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \
2033
__argz_count __argz_stringify __argz_next
2034
do
2035
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2036
echo "configure:2037: checking for $ac_func" >&5
2037
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2038
  echo $ac_n "(cached) $ac_c" 1>&6
2039
else
2040
  cat > conftest.$ac_ext <
2041
#line 2042 "configure"
2042
#include "confdefs.h"
2043
/* System header to define __stub macros and hopefully few prototypes,
2044
    which can conflict with char $ac_func(); below.  */
2045
#include 
2046
/* Override any gcc2 internal prototype to avoid an error.  */
2047
/* We use char because int might match the return type of a gcc2
2048
    builtin and then its argument prototype would still apply.  */
2049
char $ac_func();
2050
 
2051
int main() {
2052
 
2053
/* The GNU C library defines this for functions which it implements
2054
    to always fail with ENOSYS.  Some functions are actually named
2055
    something starting with __ and the normal name is an alias.  */
2056
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2057
choke me
2058
#else
2059
$ac_func();
2060
#endif
2061
 
2062
; return 0; }
2063
EOF
2064
if { (eval echo configure:2065: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2065
  rm -rf conftest*
2066
  eval "ac_cv_func_$ac_func=yes"
2067
else
2068
  echo "configure: failed program was:" >&5
2069
  cat conftest.$ac_ext >&5
2070
  rm -rf conftest*
2071
  eval "ac_cv_func_$ac_func=no"
2072
fi
2073
rm -f conftest*
2074
fi
2075
 
2076
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2077
  echo "$ac_t""yes" 1>&6
2078
    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2079
  cat >> confdefs.h <
2080
#define $ac_tr_func 1
2081
EOF
2082
 
2083
else
2084
  echo "$ac_t""no" 1>&6
2085
fi
2086
done
2087
 
2088
 
2089
   if test "${ac_cv_func_stpcpy+set}" != "set"; then
2090
     for ac_func in stpcpy
2091
do
2092
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2093
echo "configure:2094: checking for $ac_func" >&5
2094
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2095
  echo $ac_n "(cached) $ac_c" 1>&6
2096
else
2097
  cat > conftest.$ac_ext <
2098
#line 2099 "configure"
2099
#include "confdefs.h"
2100
/* System header to define __stub macros and hopefully few prototypes,
2101
    which can conflict with char $ac_func(); below.  */
2102
#include 
2103
/* Override any gcc2 internal prototype to avoid an error.  */
2104
/* We use char because int might match the return type of a gcc2
2105
    builtin and then its argument prototype would still apply.  */
2106
char $ac_func();
2107
 
2108
int main() {
2109
 
2110
/* The GNU C library defines this for functions which it implements
2111
    to always fail with ENOSYS.  Some functions are actually named
2112
    something starting with __ and the normal name is an alias.  */
2113
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2114
choke me
2115
#else
2116
$ac_func();
2117
#endif
2118
 
2119
; return 0; }
2120
EOF
2121
if { (eval echo configure:2122: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2122
  rm -rf conftest*
2123
  eval "ac_cv_func_$ac_func=yes"
2124
else
2125
  echo "configure: failed program was:" >&5
2126
  cat conftest.$ac_ext >&5
2127
  rm -rf conftest*
2128
  eval "ac_cv_func_$ac_func=no"
2129
fi
2130
rm -f conftest*
2131
fi
2132
 
2133
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2134
  echo "$ac_t""yes" 1>&6
2135
    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2136
  cat >> confdefs.h <
2137
#define $ac_tr_func 1
2138
EOF
2139
 
2140
else
2141
  echo "$ac_t""no" 1>&6
2142
fi
2143
done
2144
 
2145
   fi
2146
   if test "${ac_cv_func_stpcpy}" = "yes"; then
2147
     cat >> confdefs.h <<\EOF
2148
#define HAVE_STPCPY 1
2149
EOF
2150
 
2151
   fi
2152
 
2153
   if test $ac_cv_header_locale_h = yes; then
2154
    echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
2155
echo "configure:2156: checking for LC_MESSAGES" >&5
2156
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
2157
  echo $ac_n "(cached) $ac_c" 1>&6
2158
else
2159
  cat > conftest.$ac_ext <
2160
#line 2161 "configure"
2161
#include "confdefs.h"
2162
#include 
2163
int main() {
2164
return LC_MESSAGES
2165
; return 0; }
2166
EOF
2167
if { (eval echo configure:2168: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2168
  rm -rf conftest*
2169
  am_cv_val_LC_MESSAGES=yes
2170
else
2171
  echo "configure: failed program was:" >&5
2172
  cat conftest.$ac_ext >&5
2173
  rm -rf conftest*
2174
  am_cv_val_LC_MESSAGES=no
2175
fi
2176
rm -f conftest*
2177
fi
2178
 
2179
echo "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
2180
    if test $am_cv_val_LC_MESSAGES = yes; then
2181
      cat >> confdefs.h <<\EOF
2182
#define HAVE_LC_MESSAGES 1
2183
EOF
2184
 
2185
    fi
2186
  fi
2187
   echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
2188
echo "configure:2189: checking whether NLS is requested" >&5
2189
        # Check whether --enable-nls or --disable-nls was given.
2190
if test "${enable_nls+set}" = set; then
2191
  enableval="$enable_nls"
2192
  USE_NLS=$enableval
2193
else
2194
  USE_NLS=yes
2195
fi
2196
 
2197
    echo "$ac_t""$USE_NLS" 1>&6
2198
 
2199
 
2200
    USE_INCLUDED_LIBINTL=no
2201
 
2202
        if test "$USE_NLS" = "yes"; then
2203
      cat >> confdefs.h <<\EOF
2204
#define ENABLE_NLS 1
2205
EOF
2206
 
2207
      echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
2208
echo "configure:2209: checking whether included gettext is requested" >&5
2209
      # Check whether --with-included-gettext or --without-included-gettext was given.
2210
if test "${with_included_gettext+set}" = set; then
2211
  withval="$with_included_gettext"
2212
  nls_cv_force_use_gnu_gettext=$withval
2213
else
2214
  nls_cv_force_use_gnu_gettext=no
2215
fi
2216
 
2217
      echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
2218
 
2219
      nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
2220
      if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
2221
                                        nls_cv_header_intl=
2222
        nls_cv_header_libgt=
2223
        CATOBJEXT=NONE
2224
 
2225
        ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
2226
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
2227
echo "configure:2228: checking for libintl.h" >&5
2228
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2229
  echo $ac_n "(cached) $ac_c" 1>&6
2230
else
2231
  cat > conftest.$ac_ext <
2232
#line 2233 "configure"
2233
#include "confdefs.h"
2234
#include 
2235
EOF
2236
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2237
{ (eval echo configure:2238: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2238
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2239
if test -z "$ac_err"; then
2240
  rm -rf conftest*
2241
  eval "ac_cv_header_$ac_safe=yes"
2242
else
2243
  echo "$ac_err" >&5
2244
  echo "configure: failed program was:" >&5
2245
  cat conftest.$ac_ext >&5
2246
  rm -rf conftest*
2247
  eval "ac_cv_header_$ac_safe=no"
2248
fi
2249
rm -f conftest*
2250
fi
2251
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2252
  echo "$ac_t""yes" 1>&6
2253
  echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
2254
echo "configure:2255: checking for gettext in libc" >&5
2255
if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
2256
  echo $ac_n "(cached) $ac_c" 1>&6
2257
else
2258
  cat > conftest.$ac_ext <
2259
#line 2260 "configure"
2260
#include "confdefs.h"
2261
#include 
2262
int main() {
2263
return (int) gettext ("")
2264
; return 0; }
2265
EOF
2266
if { (eval echo configure:2267: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2267
  rm -rf conftest*
2268
  gt_cv_func_gettext_libc=yes
2269
else
2270
  echo "configure: failed program was:" >&5
2271
  cat conftest.$ac_ext >&5
2272
  rm -rf conftest*
2273
  gt_cv_func_gettext_libc=no
2274
fi
2275
rm -f conftest*
2276
fi
2277
 
2278
echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
2279
 
2280
           if test "$gt_cv_func_gettext_libc" != "yes"; then
2281
             echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
2282
echo "configure:2283: checking for bindtextdomain in -lintl" >&5
2283
ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
2284
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2285
  echo $ac_n "(cached) $ac_c" 1>&6
2286
else
2287
  ac_save_LIBS="$LIBS"
2288
LIBS="-lintl  $LIBS"
2289
cat > conftest.$ac_ext <
2290
#line 2291 "configure"
2291
#include "confdefs.h"
2292
/* Override any gcc2 internal prototype to avoid an error.  */
2293
/* We use char because int might match the return type of a gcc2
2294
    builtin and then its argument prototype would still apply.  */
2295
char bindtextdomain();
2296
 
2297
int main() {
2298
bindtextdomain()
2299
; return 0; }
2300
EOF
2301
if { (eval echo configure:2302: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2302
  rm -rf conftest*
2303
  eval "ac_cv_lib_$ac_lib_var=yes"
2304
else
2305
  echo "configure: failed program was:" >&5
2306
  cat conftest.$ac_ext >&5
2307
  rm -rf conftest*
2308
  eval "ac_cv_lib_$ac_lib_var=no"
2309
fi
2310
rm -f conftest*
2311
LIBS="$ac_save_LIBS"
2312
 
2313
fi
2314
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2315
  echo "$ac_t""yes" 1>&6
2316
  echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
2317
echo "configure:2318: checking for gettext in libintl" >&5
2318
if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
2319
  echo $ac_n "(cached) $ac_c" 1>&6
2320
else
2321
  cat > conftest.$ac_ext <
2322
#line 2323 "configure"
2323
#include "confdefs.h"
2324
 
2325
int main() {
2326
return (int) gettext ("")
2327
; return 0; }
2328
EOF
2329
if { (eval echo configure:2330: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2330
  rm -rf conftest*
2331
  gt_cv_func_gettext_libintl=yes
2332
else
2333
  echo "configure: failed program was:" >&5
2334
  cat conftest.$ac_ext >&5
2335
  rm -rf conftest*
2336
  gt_cv_func_gettext_libintl=no
2337
fi
2338
rm -f conftest*
2339
fi
2340
 
2341
echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
2342
else
2343
  echo "$ac_t""no" 1>&6
2344
fi
2345
 
2346
           fi
2347
 
2348
           if test "$gt_cv_func_gettext_libc" = "yes" \
2349
              || test "$gt_cv_func_gettext_libintl" = "yes"; then
2350
              cat >> confdefs.h <<\EOF
2351
#define HAVE_GETTEXT 1
2352
EOF
2353
 
2354
              # Extract the first word of "msgfmt", so it can be a program name with args.
2355
set dummy msgfmt; ac_word=$2
2356
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2357
echo "configure:2358: checking for $ac_word" >&5
2358
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
2359
  echo $ac_n "(cached) $ac_c" 1>&6
2360
else
2361
  case "$MSGFMT" in
2362
  /*)
2363
  ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
2364
  ;;
2365
  *)
2366
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2367
  for ac_dir in $PATH; do
2368
    test -z "$ac_dir" && ac_dir=.
2369
    if test -f $ac_dir/$ac_word; then
2370
      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
2371
        ac_cv_path_MSGFMT="$ac_dir/$ac_word"
2372
        break
2373
      fi
2374
    fi
2375
  done
2376
  IFS="$ac_save_ifs"
2377
  test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no"
2378
  ;;
2379
esac
2380
fi
2381
MSGFMT="$ac_cv_path_MSGFMT"
2382
if test -n "$MSGFMT"; then
2383
  echo "$ac_t""$MSGFMT" 1>&6
2384
else
2385
  echo "$ac_t""no" 1>&6
2386
fi
2387
              if test "$MSGFMT" != "no"; then
2388
                for ac_func in dcgettext
2389
do
2390
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2391
echo "configure:2392: checking for $ac_func" >&5
2392
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2393
  echo $ac_n "(cached) $ac_c" 1>&6
2394
else
2395
  cat > conftest.$ac_ext <
2396
#line 2397 "configure"
2397
#include "confdefs.h"
2398
/* System header to define __stub macros and hopefully few prototypes,
2399
    which can conflict with char $ac_func(); below.  */
2400
#include 
2401
/* Override any gcc2 internal prototype to avoid an error.  */
2402
/* We use char because int might match the return type of a gcc2
2403
    builtin and then its argument prototype would still apply.  */
2404
char $ac_func();
2405
 
2406
int main() {
2407
 
2408
/* The GNU C library defines this for functions which it implements
2409
    to always fail with ENOSYS.  Some functions are actually named
2410
    something starting with __ and the normal name is an alias.  */
2411
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2412
choke me
2413
#else
2414
$ac_func();
2415
#endif
2416
 
2417
; return 0; }
2418
EOF
2419
if { (eval echo configure:2420: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2420
  rm -rf conftest*
2421
  eval "ac_cv_func_$ac_func=yes"
2422
else
2423
  echo "configure: failed program was:" >&5
2424
  cat conftest.$ac_ext >&5
2425
  rm -rf conftest*
2426
  eval "ac_cv_func_$ac_func=no"
2427
fi
2428
rm -f conftest*
2429
fi
2430
 
2431
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2432
  echo "$ac_t""yes" 1>&6
2433
    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2434
  cat >> confdefs.h <
2435
#define $ac_tr_func 1
2436
EOF
2437
 
2438
else
2439
  echo "$ac_t""no" 1>&6
2440
fi
2441
done
2442
 
2443
                # Extract the first word of "gmsgfmt", so it can be a program name with args.
2444
set dummy gmsgfmt; ac_word=$2
2445
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2446
echo "configure:2447: checking for $ac_word" >&5
2447
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
2448
  echo $ac_n "(cached) $ac_c" 1>&6
2449
else
2450
  case "$GMSGFMT" in
2451
  /*)
2452
  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
2453
  ;;
2454
  ?:/*)
2455
  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
2456
  ;;
2457
  *)
2458
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
2459
  ac_dummy="$PATH"
2460
  for ac_dir in $ac_dummy; do
2461
    test -z "$ac_dir" && ac_dir=.
2462
    if test -f $ac_dir/$ac_word; then
2463
      ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
2464
      break
2465
    fi
2466
  done
2467
  IFS="$ac_save_ifs"
2468
  test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
2469
  ;;
2470
esac
2471
fi
2472
GMSGFMT="$ac_cv_path_GMSGFMT"
2473
if test -n "$GMSGFMT"; then
2474
  echo "$ac_t""$GMSGFMT" 1>&6
2475
else
2476
  echo "$ac_t""no" 1>&6
2477
fi
2478
 
2479
                # Extract the first word of "xgettext", so it can be a program name with args.
2480
set dummy xgettext; ac_word=$2
2481
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2482
echo "configure:2483: checking for $ac_word" >&5
2483
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
2484
  echo $ac_n "(cached) $ac_c" 1>&6
2485
else
2486
  case "$XGETTEXT" in
2487
  /*)
2488
  ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
2489
  ;;
2490
  *)
2491
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2492
  for ac_dir in $PATH; do
2493
    test -z "$ac_dir" && ac_dir=.
2494
    if test -f $ac_dir/$ac_word; then
2495
      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
2496
        ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
2497
        break
2498
      fi
2499
    fi
2500
  done
2501
  IFS="$ac_save_ifs"
2502
  test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
2503
  ;;
2504
esac
2505
fi
2506
XGETTEXT="$ac_cv_path_XGETTEXT"
2507
if test -n "$XGETTEXT"; then
2508
  echo "$ac_t""$XGETTEXT" 1>&6
2509
else
2510
  echo "$ac_t""no" 1>&6
2511
fi
2512
 
2513
                cat > conftest.$ac_ext <
2514
#line 2515 "configure"
2515
#include "confdefs.h"
2516
 
2517
int main() {
2518
extern int _nl_msg_cat_cntr;
2519
                               return _nl_msg_cat_cntr
2520
; return 0; }
2521
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*
2524
  CATOBJEXT=.gmo
2525
                   DATADIRNAME=share
2526
else
2527
  echo "configure: failed program was:" >&5
2528
  cat conftest.$ac_ext >&5
2529
  rm -rf conftest*
2530
  CATOBJEXT=.mo
2531
                   DATADIRNAME=lib
2532
fi
2533
rm -f conftest*
2534
                INSTOBJEXT=.mo
2535
              fi
2536
            fi
2537
 
2538
else
2539
  echo "$ac_t""no" 1>&6
2540
fi
2541
 
2542
 
2543
 
2544
        if test "$CATOBJEXT" = "NONE"; then
2545
                          nls_cv_use_gnu_gettext=yes
2546
        fi
2547
      fi
2548
 
2549
      if test "$nls_cv_use_gnu_gettext" = "yes"; then
2550
                INTLOBJS="\$(GETTOBJS)"
2551
        # Extract the first word of "msgfmt", so it can be a program name with args.
2552
set dummy msgfmt; ac_word=$2
2553
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2554
echo "configure:2555: checking for $ac_word" >&5
2555
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
2556
  echo $ac_n "(cached) $ac_c" 1>&6
2557
else
2558
  case "$MSGFMT" in
2559
  /*)
2560
  ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
2561
  ;;
2562
  *)
2563
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2564
  for ac_dir in $PATH; do
2565
    test -z "$ac_dir" && ac_dir=.
2566
    if test -f $ac_dir/$ac_word; then
2567
      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
2568
        ac_cv_path_MSGFMT="$ac_dir/$ac_word"
2569
        break
2570
      fi
2571
    fi
2572
  done
2573
  IFS="$ac_save_ifs"
2574
  test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt"
2575
  ;;
2576
esac
2577
fi
2578
MSGFMT="$ac_cv_path_MSGFMT"
2579
if test -n "$MSGFMT"; then
2580
  echo "$ac_t""$MSGFMT" 1>&6
2581
else
2582
  echo "$ac_t""no" 1>&6
2583
fi
2584
 
2585
        # Extract the first word of "gmsgfmt", so it can be a program name with args.
2586
set dummy gmsgfmt; ac_word=$2
2587
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2588
echo "configure:2589: checking for $ac_word" >&5
2589
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
2590
  echo $ac_n "(cached) $ac_c" 1>&6
2591
else
2592
  case "$GMSGFMT" in
2593
  /*)
2594
  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
2595
  ;;
2596
  ?:/*)
2597
  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
2598
  ;;
2599
  *)
2600
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
2601
  ac_dummy="$PATH"
2602
  for ac_dir in $ac_dummy; do
2603
    test -z "$ac_dir" && ac_dir=.
2604
    if test -f $ac_dir/$ac_word; then
2605
      ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
2606
      break
2607
    fi
2608
  done
2609
  IFS="$ac_save_ifs"
2610
  test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
2611
  ;;
2612
esac
2613
fi
2614
GMSGFMT="$ac_cv_path_GMSGFMT"
2615
if test -n "$GMSGFMT"; then
2616
  echo "$ac_t""$GMSGFMT" 1>&6
2617
else
2618
  echo "$ac_t""no" 1>&6
2619
fi
2620
 
2621
        # Extract the first word of "xgettext", so it can be a program name with args.
2622
set dummy xgettext; ac_word=$2
2623
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2624
echo "configure:2625: checking for $ac_word" >&5
2625
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
2626
  echo $ac_n "(cached) $ac_c" 1>&6
2627
else
2628
  case "$XGETTEXT" in
2629
  /*)
2630
  ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
2631
  ;;
2632
  *)
2633
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2634
  for ac_dir in $PATH; do
2635
    test -z "$ac_dir" && ac_dir=.
2636
    if test -f $ac_dir/$ac_word; then
2637
      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
2638
        ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
2639
        break
2640
      fi
2641
    fi
2642
  done
2643
  IFS="$ac_save_ifs"
2644
  test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
2645
  ;;
2646
esac
2647
fi
2648
XGETTEXT="$ac_cv_path_XGETTEXT"
2649
if test -n "$XGETTEXT"; then
2650
  echo "$ac_t""$XGETTEXT" 1>&6
2651
else
2652
  echo "$ac_t""no" 1>&6
2653
fi
2654
 
2655
 
2656
        USE_INCLUDED_LIBINTL=yes
2657
        CATOBJEXT=.gmo
2658
        INSTOBJEXT=.mo
2659
        DATADIRNAME=share
2660
        INTLDEPS='$(top_builddir)/../intl/libintl.a'
2661
        INTLLIBS=$INTLDEPS
2662
        LIBS=`echo $LIBS | sed -e 's/-lintl//'`
2663
        nls_cv_header_intl=libintl.h
2664
        nls_cv_header_libgt=libgettext.h
2665
      fi
2666
 
2667
            if test "$XGETTEXT" != ":"; then
2668
                        if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
2669
          : ;
2670
        else
2671
          echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6
2672
          XGETTEXT=":"
2673
        fi
2674
      fi
2675
 
2676
      # We need to process the po/ directory.
2677
      POSUB=po
2678
    else
2679
      DATADIRNAME=share
2680
      nls_cv_header_intl=libintl.h
2681
      nls_cv_header_libgt=libgettext.h
2682
    fi
2683
 
2684
    # If this is used in GNU gettext we have to set USE_NLS to `yes'
2685
    # because some of the sources are only built for this goal.
2686
    if test "$PACKAGE" = gettext; then
2687
      USE_NLS=yes
2688
      USE_INCLUDED_LIBINTL=yes
2689
    fi
2690
 
2691
                for lang in $ALL_LINGUAS; do
2692
      GMOFILES="$GMOFILES $lang.gmo"
2693
      POFILES="$POFILES $lang.po"
2694
    done
2695
 
2696
 
2697
 
2698
 
2699
 
2700
 
2701
 
2702
 
2703
 
2704
 
2705
 
2706
 
2707
 
2708
 
2709
   if test "x$CATOBJEXT" != "x"; then
2710
     if test "x$ALL_LINGUAS" = "x"; then
2711
       LINGUAS=
2712
     else
2713
       echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
2714
echo "configure:2715: checking for catalogs to be installed" >&5
2715
       NEW_LINGUAS=
2716
       for lang in ${LINGUAS=$ALL_LINGUAS}; do
2717
         case "$ALL_LINGUAS" in
2718
          *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
2719
         esac
2720
       done
2721
       LINGUAS=$NEW_LINGUAS
2722
       echo "$ac_t""$LINGUAS" 1>&6
2723
     fi
2724
 
2725
          if test -n "$LINGUAS"; then
2726
       for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
2727
     fi
2728
   fi
2729
 
2730
            if test $ac_cv_header_locale_h = yes; then
2731
     INCLUDE_LOCALE_H="#include "
2732
   else
2733
     INCLUDE_LOCALE_H="\
2734
/* The system does not provide the header .  Take care yourself.  */"
2735
   fi
2736
 
2737
 
2738
            if test -f $srcdir/po2tbl.sed.in; then
2739
      if test "$CATOBJEXT" = ".cat"; then
2740
         ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
2741
echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
2742
echo "configure:2743: checking for linux/version.h" >&5
2743
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2744
  echo $ac_n "(cached) $ac_c" 1>&6
2745
else
2746
  cat > conftest.$ac_ext <
2747
#line 2748 "configure"
2748
#include "confdefs.h"
2749
#include 
2750
EOF
2751
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2752
{ (eval echo configure:2753: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2753
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2754
if test -z "$ac_err"; then
2755
  rm -rf conftest*
2756
  eval "ac_cv_header_$ac_safe=yes"
2757
else
2758
  echo "$ac_err" >&5
2759
  echo "configure: failed program was:" >&5
2760
  cat conftest.$ac_ext >&5
2761
  rm -rf conftest*
2762
  eval "ac_cv_header_$ac_safe=no"
2763
fi
2764
rm -f conftest*
2765
fi
2766
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2767
  echo "$ac_t""yes" 1>&6
2768
  msgformat=linux
2769
else
2770
  echo "$ac_t""no" 1>&6
2771
msgformat=xopen
2772
fi
2773
 
2774
 
2775
                         sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed
2776
      fi
2777
            sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
2778
         $srcdir/po2tbl.sed.in > po2tbl.sed
2779
   fi
2780
 
2781
            if test "$PACKAGE" = "gettext"; then
2782
     GT_NO="#NO#"
2783
     GT_YES=
2784
   else
2785
     GT_NO=
2786
     GT_YES="#YES#"
2787
   fi
2788
 
2789
 
2790
 
2791
   MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs"
2792
 
2793
 
2794
      l=
2795
 
2796
 
2797
            if test -d $srcdir/po; then
2798
      test -d po || mkdir po
2799
      if test "x$srcdir" != "x."; then
2800
         if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
2801
            posrcprefix="$srcdir/"
2802
         else
2803
            posrcprefix="../$srcdir/"
2804
         fi
2805
      else
2806
         posrcprefix="../"
2807
      fi
2808
      rm -f po/POTFILES
2809
      sed -e "/^#/d" -e "/^\$/d" -e "s,.*,      $posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
2810
         < $srcdir/po/POTFILES.in > po/POTFILES
2811
   fi
2812
 
2813
 
2814
 
2815
# Check whether --enable-sim-alignment or --disable-sim-alignment was given.
2816
if test "${enable_sim_alignment+set}" = set; then
2817
  enableval="$enable_sim_alignment"
2818
  case "${enableval}" in
2819
  yes | strict | STRICT)        sim_alignment="-DWITH_ALIGNMENT=STRICT_ALIGNMENT";;
2820
  no | nonstrict | NONSTRICT)   sim_alignment="-DWITH_ALIGNMENT=NONSTRICT_ALIGNMENT";;
2821
 
2822
  *)                            { echo "configure: error: "Unknown value $enableval passed to --enable-sim-alignment"" 1>&2; exit 1; }; sim_alignment="";;
2823
esac
2824
if test x"$silent" != x"yes" && test x"$sim_alignment" != x""; then
2825
  echo "Setting alignment flags = $sim_alignment" 6>&1
2826
fi
2827
else
2828
  sim_alignment=""
2829
fi
2830
 
2831
 
2832
# Check whether --enable-sim-assert or --disable-sim-assert was given.
2833
if test "${enable_sim_assert+set}" = set; then
2834
  enableval="$enable_sim_assert"
2835
  case "${enableval}" in
2836
  yes)  sim_assert="-DWITH_ASSERT=1";;
2837
  no)   sim_assert="-DWITH_ASSERT=0";;
2838
  *)    { echo "configure: error: "--enable-sim-assert does not take a value"" 1>&2; exit 1; }; sim_assert="";;
2839
esac
2840
if test x"$silent" != x"yes" && test x"$sim_assert" != x""; then
2841
  echo "Setting assert flags = $sim_assert" 6>&1
2842
fi
2843
else
2844
  sim_assert=""
2845
fi
2846
 
2847
 
2848
# Check whether --enable-sim-bitsize or --disable-sim-bitsize was given.
2849
if test "${enable_sim_bitsize+set}" = set; then
2850
  enableval="$enable_sim_bitsize"
2851
  case "${enableval}" in
2852
  32|64) sim_bitsize="-DWITH_TARGET_WORD_BITSIZE=$enableval";;
2853
  *)     { echo "configure: error: "--enable-sim-bitsize was given $enableval.  Expected 32 or 64"" 1>&2; exit 1; }; sim_bitsize="";;
2854
esac
2855
if test x"$silent" != x"yes" && test x"$sim_bitsize" != x""; then
2856
  echo "Setting bitsize flags = $sim_bitsize" 6>&1
2857
fi
2858
else
2859
  sim_bitsize=""
2860
fi
2861
 
2862
 
2863
# Check whether --enable-sim-bswap or --disable-sim-bswap was given.
2864
if test "${enable_sim_bswap+set}" = set; then
2865
  enableval="$enable_sim_bswap"
2866
  case "${enableval}" in
2867
  yes)  sim_bswap="-DWITH_BSWAP=1";;
2868
  no)   sim_bswap="-DWITH_BSWAP=0";;
2869
  *)    { echo "configure: error: "--enable-sim-bswap does not take a value"" 1>&2; exit 1; }; sim_bswap="";;
2870
esac
2871
if test x"$silent" != x"yes" && test x"$sim_bswap" != x""; then
2872
  echo "Setting bswap flags = $sim_bswap" 6>&1
2873
fi
2874
else
2875
  sim_bswap=""
2876
fi
2877
 
2878
 
2879
# Check whether --enable-sim-cflags or --disable-sim-cflags was given.
2880
if test "${enable_sim_cflags+set}" = set; then
2881
  enableval="$enable_sim_cflags"
2882
  case "${enableval}" in
2883
  yes)  sim_cflags="-O2 -fomit-frame-pointer";;
2884
  no)   sim_cflags="";;
2885
  *)    sim_cflags=`echo "${enableval}" | sed -e "s/,/ /g"`;;
2886
esac
2887
if test x"$silent" != x"yes" && test x"$sim_cflags" != x""; then
2888
  echo "Setting sim cflags = $sim_cflags" 6>&1
2889
fi
2890
else
2891
  sim_cflags=""
2892
fi
2893
 
2894
 
2895
# Check whether --enable-sim-config or --disable-sim-config was given.
2896
if test "${enable_sim_config+set}" = set; then
2897
  enableval="$enable_sim_config"
2898
  case "${enableval}" in
2899
  yes|no)       { echo "configure: error: "No value supplied for --enable-sim-config=file"" 1>&2; exit 1; };;
2900
  *)            if test -f "${srcdir}/${enableval}"; then
2901
                  sim_config="${enableval}";
2902
                elif test -f "${srcdir}/${enableval}-config.h"; then
2903
                  sim_config="${enableval}-config.h"
2904
                else
2905
                  { echo "configure: error: "Config file $enableval was not found"" 1>&2; exit 1; };
2906
                  sim_config=std-config.h
2907
                fi;;
2908
esac
2909
if test x"$silent" != x"yes" && test x"$sim_config" != x""; then
2910
  echo "Setting config flags = $sim_config" 6>&1
2911
fi
2912
else
2913
  sim_config="std-config.h"
2914
if test x"$silent" != x"yes"; then
2915
  echo "Setting config flags = $sim_config" 6>&1
2916
fi
2917
fi
2918
 
2919
 
2920
# Check whether --enable-sim-decode-mechanism or --disable-sim-decode-mechanism was given.
2921
if test "${enable_sim_decode_mechanism+set}" = set; then
2922
  enableval="$enable_sim_decode_mechanism"
2923
  case "${enableval}" in
2924
  yes|no)       { echo "configure: error: "No value supplied for --enable-sim-decode-mechanism=file"" 1>&2; exit 1; };;
2925
  array|switch|padded-switch|goto-switch)       sim_decode_mechanism="-T ${enableval}";;
2926
  *)            { echo "configure: error: "File $enableval is not an opcode rules file"" 1>&2; exit 1; };
2927
                sim_decode_mechanism="switch";;
2928
esac
2929
if test x"$silent" != x"yes" && test x"$sim_decode_mechanism" != x""; then
2930
  echo "Setting decode mechanism flags = $sim_decode_mechanism" 6>&1
2931
fi
2932
else
2933
  sim_decode_mechanism=""
2934
if test x"$silent" != x"yes"; then
2935
  echo "Setting decode mechanism flags = $sim_decode_mechanism"
2936
fi
2937
fi
2938
 
2939
 
2940
# Check whether --enable-sim-default-model or --disable-sim-default-model was given.
2941
if test "${enable_sim_default_model+set}" = set; then
2942
  enableval="$enable_sim_default_model"
2943
  case "${enableval}" in
2944
  yes|no)       { echo "configure: error: "No value supplied for --enable-sim-default-model=model"" 1>&2; exit 1; };;
2945
  *)            sim_default_model="-DWITH_DEFAULT_MODEL=${enableval}";;
2946
esac
2947
if test x"$silent" != x"yes" && test x"$sim_default_model" != x""; then
2948
  echo "Setting default-model flags = $sim_default_model" 6>&1
2949
fi
2950
else
2951
  sim_default_model=""
2952
fi
2953
 
2954
 
2955
# Check whether --enable-sim-duplicate or --disable-sim-duplicate was given.
2956
if test "${enable_sim_duplicate+set}" = set; then
2957
  enableval="$enable_sim_duplicate"
2958
  case "${enableval}" in
2959
  yes)  sim_dup="-E";;
2960
  no)   sim_dup="";;
2961
  *)    { echo "configure: error: "--enable-sim-duplicate does not take a value"" 1>&2; exit 1; }; sim_dup="";;
2962
esac
2963
if test x"$silent" != x"yes" && test x"$sim_dup" != x""; then
2964
  echo "Setting duplicate flags = $sim_dup" 6>&1
2965
fi
2966
else
2967
  sim_dup="-E"
2968
if test x"$silent" != x"yes"; then
2969
  echo "Setting duplicate flags = $sim_dup" 6>&1
2970
fi
2971
fi
2972
 
2973
 
2974
# Check whether --enable-sim-endian or --disable-sim-endian was given.
2975
if test "${enable_sim_endian+set}" = set; then
2976
  enableval="$enable_sim_endian"
2977
  case "${enableval}" in
2978
  yes)  case "$target" in
2979
          *powerpc-*) sim_endian="-DWITH_TARGET_BYTE_ORDER=BIG_ENDIAN";;
2980
          *powerpcle-*) sim_endian="-DWITH_TARGET_BYTE_ORDER=LITTLE_ENDIAN";;
2981
          *) echo "Unknown target $target" 1>&6; sim_endian="-DWITH_TARGET_BYTE_ORDER=0";;
2982
        esac;;
2983
  no)    sim_endian="-DWITH_TARGET_BYTE_ORDER=0";;
2984
  b*|B*) sim_endian="-DWITH_TARGET_BYTE_ORDER=BIG_ENDIAN";;
2985
  l*|L*) sim_endian="-DWITH_TARGET_BYTE_ORDER=LITTLE_ENDIAN";;
2986
  *)     { echo "configure: error: "Unknown value $enableval for --enable-sim-endian"" 1>&2; exit 1; }; sim_endian="";;
2987
esac
2988
if test x"$silent" != x"yes" && test x"$sim_endian" != x""; then
2989
  echo "Setting endian flags = $sim_endian" 6>&1
2990
fi
2991
else
2992
  sim_endian=""
2993
fi
2994
 
2995
 
2996
# Check whether --enable-sim-env or --disable-sim-env was given.
2997
if test "${enable_sim_env+set}" = set; then
2998
  enableval="$enable_sim_env"
2999
  case "${enableval}" in
3000
  operating | os | oea) sim_env="-DWITH_ENVIRONMENT=OPERATING_ENVIRONMENT";;
3001
  virtual | vea)        sim_env="-DWITH_ENVIRONMENT=VIRTUAL_ENVIRONMENT";;
3002
  user | uea)           sim_env="-DWITH_ENVIRONMENT=USER_ENVIRONMENT";;
3003
  no)                   sim_env="-DWITH_ENVIRONMENT=0";;
3004
  *)                    { echo "configure: error: "Unknown value $enableval passed to --enable-sim-env"" 1>&2; exit 1; }; sim_env="";;
3005
esac
3006
if test x"$silent" != x"yes" && test x"$sim_env" != x""; then
3007
  echo "Setting env flags = $sim_env" 6>&1
3008
fi
3009
else
3010
  sim_env=""
3011
fi
3012
 
3013
 
3014
# Check whether --enable-sim-filter or --disable-sim-filter was given.
3015
if test "${enable_sim_filter+set}" = set; then
3016
  enableval="$enable_sim_filter"
3017
  case "${enableval}" in
3018
  yes)  { echo "configure: error: "--enable-sim-filter must be specified with a rule to filter or no"" 1>&2; exit 1; }; sim_filter="";;
3019
  no)   sim_filter="";;
3020
  *)    sim_filter="-F $enableval";;
3021
esac
3022
if test x"$silent" != x"yes" && test x"$sim_filter" != x""; then
3023
  echo "Setting filter flags = $sim_filter" 6>&1
3024
fi
3025
else
3026
  sim_filter="-F 32,f,o"
3027
if test x"$silent" != x"yes"; then
3028
  echo "Setting filter flags = $sim_filter" 6>&1
3029
fi
3030
fi
3031
 
3032
 
3033
# Check whether --enable-sim-float or --disable-sim-float was given.
3034
if test "${enable_sim_float+set}" = set; then
3035
  enableval="$enable_sim_float"
3036
  case "${enableval}" in
3037
  yes | hard)   sim_float="-DWITH_FLOATING_POINT=HARD_FLOATING_POINT";;
3038
  no | soft)    sim_float="-DWITH_FLOATING_POINT=SOFT_FLOATING_POINT";;
3039
  *)            { echo "configure: error: "Unknown value $enableval passed to --enable-sim-float"" 1>&2; exit 1; }; sim_float="";;
3040
esac
3041
if test x"$silent" != x"yes" && test x"$sim_float" != x""; then
3042
  echo "Setting float flags = $sim_float" 6>&1
3043
fi
3044
else
3045
  sim_float=""
3046
fi
3047
 
3048
 
3049
# Check whether --enable-sim-hardware or --disable-sim-hardware was given.
3050
if test "${enable_sim_hardware+set}" = set; then
3051
  enableval="$enable_sim_hardware"
3052
  hardware="cpu,memory,nvram,iobus,htab,disk,trace,register,vm,init,core,pal,com,eeprom,opic,glue,phb,ide"
3053
case "${enableval}" in
3054
  yes)  ;;
3055
  no)   { echo "configure: error: "List of hardware must be specified for --enable-sim-hardware"" 1>&2; exit 1; }; hardware="";;
3056
  ,*)   hardware="${hardware}${enableval}";;
3057
  *,)   hardware="${enableval}${hardware}";;
3058
  *)    hardware="${enableval}"'';;
3059
esac
3060
sim_hw_src=`echo $hardware | sed -e 's/,/.c hw_/g' -e 's/^/hw_/' -e s'/$/.c/'`
3061
sim_hw_obj=`echo $sim_hw_src | sed -e 's/\.c/.o/g'`
3062
if test x"$silent" != x"yes" && test x"$hardware" != x""; then
3063
  echo "Setting hardware to $sim_hw_src, $sim_hw_obj"
3064
fi
3065
else
3066
  hardware="cpu,memory,nvram,iobus,htab,disk,trace,register,vm,init,core,pal,com,eeprom,opic,glue,phb,ide"
3067
sim_hw_src=`echo $hardware | sed -e 's/,/.c hw_/g' -e 's/^/hw_/' -e s'/$/.c/'`
3068
sim_hw_obj=`echo $sim_hw_src | sed -e 's/\.c/.o/g'`
3069
if test x"$silent" != x"yes"; then
3070
  echo "Setting hardware to $sim_hw_src, $sim_hw_obj"
3071
fi
3072
fi
3073
 
3074
 
3075
# Check whether --enable-sim-hostbitsize or --disable-sim-hostbitsize was given.
3076
if test "${enable_sim_hostbitsize+set}" = set; then
3077
  enableval="$enable_sim_hostbitsize"
3078
  case "${enableval}" in
3079
  32|64) sim_hostbitsize="-DWITH_HOST_WORD_BITSIZE=$enableval";;
3080
  *)     { echo "configure: error: "--enable-sim-hostbitsize was given $enableval.  Expected 32 or 64"" 1>&2; exit 1; }; sim_hostbitsize="";;
3081
esac
3082
if test x"$silent" != x"yes" && test x"$sim_hostbitsize" != x""; then
3083
  echo "Setting hostbitsize flags = $sim_hostbitsize" 6>&1
3084
fi
3085
else
3086
  sim_hostbitsize=""
3087
fi
3088
 
3089
 
3090
# Check whether --enable-sim-hostendian or --disable-sim-hostendian was given.
3091
if test "${enable_sim_hostendian+set}" = set; then
3092
  enableval="$enable_sim_hostendian"
3093
  case "${enableval}" in
3094
  no)    sim_hostendian="-DWITH_HOST_BYTE_ORDER=0";;
3095
  b*|B*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=BIG_ENDIAN";;
3096
  l*|L*) sim_hostendian="-DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN";;
3097
  *)     { echo "configure: error: "Unknown value $enableval for --enable-sim-hostendian"" 1>&2; exit 1; }; sim_hostendian="";;
3098
esac
3099
if test x"$silent" != x"yes" && test x"$sim_hostendian" != x""; then
3100
  echo "Setting hostendian flags = $sim_hostendian" 6>&1
3101
fi
3102
else
3103
 
3104
if test "x$cross_compiling" = "xno"; then
3105
  echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
3106
echo "configure:3107: checking whether byte ordering is bigendian" >&5
3107
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
3108
  echo $ac_n "(cached) $ac_c" 1>&6
3109
else
3110
  ac_cv_c_bigendian=unknown
3111
# See if sys/param.h defines the BYTE_ORDER macro.
3112
cat > conftest.$ac_ext <
3113
#line 3114 "configure"
3114
#include "confdefs.h"
3115
#include 
3116
#include 
3117
int main() {
3118
 
3119
#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
3120
 bogus endian macros
3121
#endif
3122
; return 0; }
3123
EOF
3124
if { (eval echo configure:3125: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3125
  rm -rf conftest*
3126
  # It does; now see whether it defined to BIG_ENDIAN or not.
3127
cat > conftest.$ac_ext <
3128
#line 3129 "configure"
3129
#include "confdefs.h"
3130
#include 
3131
#include 
3132
int main() {
3133
 
3134
#if BYTE_ORDER != BIG_ENDIAN
3135
 not big endian
3136
#endif
3137
; return 0; }
3138
EOF
3139
if { (eval echo configure:3140: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3140
  rm -rf conftest*
3141
  ac_cv_c_bigendian=yes
3142
else
3143
  echo "configure: failed program was:" >&5
3144
  cat conftest.$ac_ext >&5
3145
  rm -rf conftest*
3146
  ac_cv_c_bigendian=no
3147
fi
3148
rm -f conftest*
3149
else
3150
  echo "configure: failed program was:" >&5
3151
  cat conftest.$ac_ext >&5
3152
fi
3153
rm -f conftest*
3154
if test $ac_cv_c_bigendian = unknown; then
3155
if test "$cross_compiling" = yes; then
3156
    { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
3157
else
3158
  cat > conftest.$ac_ext <
3159
#line 3160 "configure"
3160
#include "confdefs.h"
3161
main () {
3162
  /* Are we little or big endian?  From Harbison&Steele.  */
3163
  union
3164
  {
3165
    long l;
3166
    char c[sizeof (long)];
3167
  } u;
3168
  u.l = 1;
3169
  exit (u.c[sizeof (long) - 1] == 1);
3170
}
3171
EOF
3172
if { (eval echo configure:3173: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3173
then
3174
  ac_cv_c_bigendian=no
3175
else
3176
  echo "configure: failed program was:" >&5
3177
  cat conftest.$ac_ext >&5
3178
  rm -fr conftest*
3179
  ac_cv_c_bigendian=yes
3180
fi
3181
rm -fr conftest*
3182
fi
3183
 
3184
fi
3185
fi
3186
 
3187
echo "$ac_t""$ac_cv_c_bigendian" 1>&6
3188
if test $ac_cv_c_bigendian = yes; then
3189
  cat >> confdefs.h <<\EOF
3190
#define WORDS_BIGENDIAN 1
3191
EOF
3192
 
3193
fi
3194
 
3195
  if test $ac_cv_c_bigendian = yes; then
3196
    sim_hostendian="-DWITH_HOST_BYTE_ORDER=BIG_ENDIAN"
3197
  else
3198
    sim_hostendian="-DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN"
3199
  fi
3200
else
3201
  sim_hostendian="-DWITH_HOST_BYTE_ORDER=0"
3202
fi
3203
fi
3204
 
3205
 
3206
# Check whether --enable-sim-icache or --disable-sim-icache was given.
3207
if test "${enable_sim_icache+set}" = set; then
3208
  enableval="$enable_sim_icache"
3209
  icache="-R"
3210
 case "${enableval}" in
3211
  yes)          icache="1024"; sim_icache="-I $icache";;
3212
  no)           sim_icache="-R";;
3213
  *) icache=1024
3214
     sim_icache="-"
3215
     for x in `echo "${enableval}" | sed -e "s/,/ /g"`; do
3216
       case "$x" in
3217
         define)        sim_icache="${sim_icache}R";;
3218
         semantic)      sim_icache="${sim_icache}C";;
3219
         insn)          sim_icache="${sim_icache}S";;
3220
         0*|1*|2*|3*|4*|5*|6*|7*|8*|9*) icache=$x;;
3221
         *)             { echo "configure: error: "Unknown value $x for --enable-sim-icache"" 1>&2; exit 1; }; sim_icache="";;
3222
       esac
3223
     done
3224
     sim_icache="${sim_icache}I $icache";;
3225
esac
3226
if test x"$silent" != x"yes" && test x"$icache" != x""; then
3227
  echo "Setting instruction cache size to $icache ($sim_icache)"
3228
fi
3229
else
3230
  sim_icache="-CSRI 1024"
3231
if test x"$silent" != x"yes"; then
3232
  echo "Setting instruction cache size to 1024 ($sim_icache)"
3233
fi
3234
fi
3235
 
3236
 
3237
# Check whether --enable-sim-inline or --disable-sim-inline was given.
3238
if test "${enable_sim_inline+set}" = set; then
3239
  enableval="$enable_sim_inline"
3240
  sim_inline=""
3241
case "$enableval" in
3242
  no)           sim_inline="-DDEFAULT_INLINE=0";;
3243
  0)            sim_inline="-DDEFAULT_INLINE=0";;
3244
  yes | 2)      sim_inline="-DDEFAULT_INLINE=ALL_INLINE";;
3245
  1)            sim_inline="-DDEFAULT_INLINE=PSIM_INLINE_LOCALS";;
3246
  *) for x in `echo "$enableval" | sed -e "s/,/ /g"`; do
3247
       new_flag=""
3248
       case "$x" in
3249
         *_INLINE=*)    new_flag="-D$x";;
3250
         *=*)           new_flag=`echo "$x" | sed -e "s/=/_INLINE=/" -e "s/^/-D/"`;;
3251
         *_INLINE)      new_flag="-D$x=ALL_INLINE";;
3252
         *)             new_flag="-D$x""_INLINE=ALL_INLINE";;
3253
       esac
3254
       if test x"$sim_inline" = x""; then
3255
         sim_inline="$new_flag"
3256
       else
3257
         sim_inline="$sim_inline $new_flag"
3258
       fi
3259
     done;;
3260
esac
3261
if test x"$silent" != x"yes" && test x"$sim_inline" != x""; then
3262
  echo "Setting inline flags = $sim_inline" 6>&1
3263
fi
3264
else
3265
  if test x"$GCC" != ""; then
3266
  sim_inline="-DDEFAULT_INLINE=PSIM_INLINE_LOCALS"
3267
  if test x"$silent" != x"yes"; then
3268
    echo "Setting inline flags = $sim_inline" 6>&1
3269
  fi
3270
else
3271
  sim_inline=""
3272
fi
3273
fi
3274
 
3275
 
3276
# Check whether --enable-sim-jump or --disable-sim-jump was given.
3277
if test "${enable_sim_jump+set}" = set; then
3278
  enableval="$enable_sim_jump"
3279
  case "${enableval}" in
3280
  yes)  sim_jump="-J";;
3281
  no)   sim_jump="";;
3282
  *)    { echo "configure: error: "--enable-sim-jump does not take a value"" 1>&2; exit 1; }; sim_jump="";;
3283
esac
3284
if test x"$silent" != x"yes" && test x"$sim_jump" != x""; then
3285
  echo "Setting jump flag = $sim_jump" 6>&1
3286
fi
3287
else
3288
  sim_jump=""
3289
if test x"$silent" != x"yes"; then
3290
  echo "Setting jump flag = $sim_jump" 6>&1
3291
fi
3292
fi
3293
 
3294
 
3295
# Check whether --enable-sim-line-nr or --disable-sim-line-nr was given.
3296
if test "${enable_sim_line_nr+set}" = set; then
3297
  enableval="$enable_sim_line_nr"
3298
  case "${enableval}" in
3299
  yes)  sim_line_nr="";;
3300
  no)   sim_line_nr="-L";;
3301
  *)    { echo "configure: error: "--enable-sim-line-nr does not take a value"" 1>&2; exit 1; }; sim_line_nr="";;
3302
esac
3303
if test x"$silent" != x"yes" && test x"$sim_line_nr" != x""; then
3304
  echo "Setting warning flags = $sim_line_nr" 6>&1
3305
fi
3306
else
3307
  sim_line_nr=""
3308
fi
3309
 
3310
 
3311
# Check whether --enable-sim-model or --disable-sim-model was given.
3312
if test "${enable_sim_model+set}" = set; then
3313
  enableval="$enable_sim_model"
3314
  case "${enableval}" in
3315
  yes|no)       { echo "configure: error: "No value supplied for --enable-sim-model=model"" 1>&2; exit 1; };;
3316
  *)            sim_model="-DWITH_MODEL=${enableval}";;
3317
esac
3318
if test x"$silent" != x"yes" && test x"$sim_model" != x""; then
3319
  echo "Setting model flags = $sim_model" 6>&1
3320
fi
3321
else
3322
  sim_model=""
3323
fi
3324
 
3325
 
3326
# Check whether --enable-sim-model-issue or --disable-sim-model-issue was given.
3327
if test "${enable_sim_model_issue+set}" = set; then
3328
  enableval="$enable_sim_model_issue"
3329
  case "${enableval}" in
3330
  yes)  sim_model_issue="-DWITH_MODEL_ISSUE=MODEL_ISSUE_PROCESS";;
3331
  no)   sim_model_issue="-DWITH_MODEL_ISSUE=MODEL_ISSUE_IGNORE";;
3332
  *)    { echo "configure: error: "--enable-sim-model-issue does not take a value"" 1>&2; exit 1; }; sim_model_issue="";;
3333
esac
3334
if test x"$silent" != x"yes"; then
3335
  echo "Setting model-issue flags = $sim_model_issue" 6>&1
3336
fi
3337
else
3338
  sim_model_issue=""
3339
fi
3340
 
3341
 
3342
# Check whether --enable-sim-monitor or --disable-sim-monitor was given.
3343
if test "${enable_sim_monitor+set}" = set; then
3344
  enableval="$enable_sim_monitor"
3345
  case "${enableval}" in
3346
  yes)          sim_monitor="-DWITH_MON='MONITOR_INSTRUCTION_ISSUE | MONITOR_LOAD_STORE_UNIT'";;
3347
  no)           sim_monitor="-DWITH_MON=0";;
3348
  instruction)  sim_monitor="-DWITH_MON=MONITOR_INSTRUCTION_ISSUE";;
3349
  memory)       sim_monitor="-DWITH_MON=MONITOR_LOAD_STORE_UNIT";;
3350
  *)            { echo "configure: error: "Unknown value $enableval passed to --enable-sim-mon"" 1>&2; exit 1; }; sim_env="";;
3351
esac
3352
if test x"$silent" != x"yes" && test x"$sim_monitor" != x""; then
3353
  echo "Setting monitor flags = $sim_monitor" 6>&1
3354
fi
3355
else
3356
  sim_monitor=""
3357
fi
3358
 
3359
 
3360
# Check whether --enable-sim-opcode or --disable-sim-opcode was given.
3361
if test "${enable_sim_opcode+set}" = set; then
3362
  enableval="$enable_sim_opcode"
3363
  case "${enableval}" in
3364
  yes|no)       { echo "configure: error: "No value supplied for --enable-sim-opcode=file"" 1>&2; exit 1; };;
3365
  *)            if test -f "${srcdir}/${enableval}"; then
3366
                  sim_opcode="${enableval}"
3367
                elif test -f "${srcdir}/dc-${enableval}"; then
3368
                  sim_opcode="dc-${enableval}"
3369
                else
3370
                  { echo "configure: error: "File $enableval is not an opcode rules file"" 1>&2; exit 1; };
3371
                  sim_opcode="dc-complex"
3372
                fi;;
3373
esac
3374
if test x"$silent" != x"yes" && test x"$sim_opcode" != x""; then
3375
  echo "Setting opcode flags = $sim_opcode" 6>&1
3376
fi
3377
else
3378
  sim_opcode="dc-complex"
3379
if test x"$silent" != x"yes"; then
3380
  echo "Setting opcode flags = $sim_opcode"
3381
fi
3382
fi
3383
 
3384
 
3385
# Check whether --enable-sim-packages or --disable-sim-packages was given.
3386
if test "${enable_sim_packages+set}" = set; then
3387
  enableval="$enable_sim_packages"
3388
  packages=disklabel
3389
case "${enableval}" in
3390
  yes)  ;;
3391
  no)   { echo "configure: error: "List of packages must be specified for --enable-sim-packages"" 1>&2; exit 1; }; packages="";;
3392
  ,*)   packages="${packages}${enableval}";;
3393
  *,)   packages="${enableval}${packages}";;
3394
  *)    packages="${enableval}"'';;
3395
esac
3396
sim_pk_src=`echo $packages | sed -e 's/,/.c pk_/g' -e 's/^/pk_/' -e 's/$/.c/'`
3397
sim_pk_obj=`echo $sim_pk_src | sed -e 's/\.c/.o/g'`
3398
if test x"$silent" != x"yes" && test x"$packages" != x""; then
3399
  echo "Setting packages to $sim_pk_src, $sim_pk_obj"
3400
fi
3401
else
3402
  packages=disklabel
3403
sim_pk_src=`echo $packages | sed -e 's/,/.c pk_/g' -e 's/^/pk_/' -e 's/$/.c/'`
3404
sim_pk_obj=`echo $sim_pk_src | sed -e 's/\.c/.o/g'`
3405
if test x"$silent" != x"yes"; then
3406
  echo "Setting packages to $sim_pk_src, $sim_pk_obj"
3407
fi
3408
fi
3409
 
3410
 
3411
# Check whether --enable-sim-regparm or --disable-sim-regparm was given.
3412
if test "${enable_sim_regparm+set}" = set; then
3413
  enableval="$enable_sim_regparm"
3414
  case "${enableval}" in
3415
  0*|1*|2*|3*|4*|5*|6*|7*|8*|9*) sim_regparm="-DWITH_REGPARM=${enableval}";;
3416
  no)                            sim_regparm="" ;;
3417
  yes)                           sim_regparm="-DWITH_REGPARM=3";;
3418
  *)   { echo "configure: error: "Unknown value $enableval for --enable-sim-regparm"" 1>&2; exit 1; }; sim_regparm="";;
3419
esac
3420
if test x"$silent" != x"yes" && test x"$sim_regparm" != x""; then
3421
  echo "Setting regparm flags = $sim_regparm" 6>&1
3422
fi
3423
else
3424
  sim_regparm=""
3425
fi
3426
 
3427
 
3428
# Check whether --enable-sim-reserved-bits or --disable-sim-reserved-bits was given.
3429
if test "${enable_sim_reserved_bits+set}" = set; then
3430
  enableval="$enable_sim_reserved_bits"
3431
  case "${enableval}" in
3432
  yes)  sim_reserved="-DWITH_RESERVED_BITS=1";;
3433
  no)   sim_reserved="-DWITH_RESERVED_BITS=0";;
3434
  *)    { echo "configure: error: "--enable-sim-reserved-bits does not take a value"" 1>&2; exit 1; }; sim_reserved="";;
3435
esac
3436
if test x"$silent" != x"yes" && test x"$sim_reserved" != x""; then
3437
  echo "Setting reserved flags = $sim_reserved" 6>&1
3438
fi
3439
else
3440
  sim_reserved=""
3441
fi
3442
 
3443
 
3444
# Check whether --enable-sim-smp or --disable-sim-smp was given.
3445
if test "${enable_sim_smp+set}" = set; then
3446
  enableval="$enable_sim_smp"
3447
  case "${enableval}" in
3448
  yes)  sim_smp="-DWITH_SMP=5" ; sim_igen_smp="-N 5";;
3449
  no)   sim_smp="-DWITH_SMP=0" ; sim_igen_smp="-N 0";;
3450
  *)    sim_smp="-DWITH_SMP=$enableval" ; sim_igen_smp="-N $enableval";;
3451
esac
3452
if test x"$silent" != x"yes" && test x"$sim_smp" != x""; then
3453
  echo "Setting smp flags = $sim_smp" 6>&1
3454
fi
3455
else
3456
  sim_smp="-DWITH_SMP=5" ; sim_igen_smp="-N 5"
3457
if test x"$silent" != x"yes"; then
3458
  echo "Setting smp flags = $sim_smp" 6>&1
3459
fi
3460
fi
3461
 
3462
 
3463
# Check whether --enable-sim-stdcall or --disable-sim-stdcall was given.
3464
if test "${enable_sim_stdcall+set}" = set; then
3465
  enableval="$enable_sim_stdcall"
3466
  case "${enableval}" in
3467
  no)           sim_stdcall="" ;;
3468
  std*)         sim_stdcall="-DWITH_STDCALL=1";;
3469
  yes)          sim_stdcall="-DWITH_STDCALL=1";;
3470
  *)   { echo "configure: error: "Unknown value $enableval for --enable-sim-stdcall"" 1>&2; exit 1; }; sim_stdcall="";;
3471
esac
3472
if test x"$silent" != x"yes" && test x"$sim_stdcall" != x""; then
3473
  echo "Setting function call flags = $sim_stdcall" 6>&1
3474
fi
3475
else
3476
  sim_stdcall=""
3477
fi
3478
 
3479
 
3480
# Check whether --enable-sim-stdio or --disable-sim-stdio was given.
3481
if test "${enable_sim_stdio+set}" = set; then
3482
  enableval="$enable_sim_stdio"
3483
  case "${enableval}" in
3484
  yes)  sim_stdio="-DWITH_STDIO=DO_USE_STDIO";;
3485
  no)   sim_stdio="-DWITH_STDIO=DONT_USE_STDIO";;
3486
  *)    { echo "configure: error: "Unknown value $enableval passed to --enable-sim-stdio"" 1>&2; exit 1; }; sim_stdio="";;
3487
esac
3488
if test x"$silent" != x"yes" && test x"$sim_stdio" != x""; then
3489
  echo "Setting stdio flags = $sim_stdio" 6>&1
3490
fi
3491
else
3492
  sim_stdio=""
3493
fi
3494
 
3495
 
3496
# Check whether --enable-sim-switch or --disable-sim-switch was given.
3497
if test "${enable_sim_switch+set}" = set; then
3498
  enableval="$enable_sim_switch"
3499
  case "${enableval}" in
3500
  yes)  sim_switch="-s";;
3501
  no)   sim_switch="";;
3502
  *)    { echo "configure: error: "--enable-sim-switch does not take a value"" 1>&2; exit 1; }; sim_switch="";;
3503
esac
3504
if test x"$silent" != x"yes" && test x"$sim_switch" != x""; then
3505
  echo "Setting switch flags = $sim_switch" 6>&1
3506
fi
3507
else
3508
  sim_switch="";
3509
if test x"$silent" != x"yes"; then
3510
  echo "Setting switch flags = $sim_switch" 6>&1
3511
fi
3512
fi
3513
 
3514
 
3515
# Check whether --enable-sim-timebase or --disable-sim-timebase was given.
3516
if test "${enable_sim_timebase+set}" = set; then
3517
  enableval="$enable_sim_timebase"
3518
  case "${enableval}" in
3519
  yes)  sim_timebase="-DWITH_TIME_BASE=1";;
3520
  no)   sim_timebase="-DWITH_TIME_BASE=0";;
3521
  *)    { echo "configure: error: "--enable-sim-timebase does not take a value"" 1>&2; exit 1; }; sim_timebase="";;
3522
esac
3523
if test x"$silent" != x"yes" && test x"$sim_timebase" != x""; then
3524
  echo "Setting timebase flags = $sim_timebase" 6>&1
3525
fi
3526
else
3527
  sim_timebase=""
3528
fi
3529
 
3530
 
3531
# Check whether --enable-sim-trace or --disable-sim-trace was given.
3532
if test "${enable_sim_trace+set}" = set; then
3533
  enableval="$enable_sim_trace"
3534
  case "${enableval}" in
3535
  yes)  sim_trace="-DWITH_TRACE=1";;
3536
  no)   sim_trace="-DWITH_TRACE=0";;
3537
  *)    { echo "configure: error: "--enable-sim-trace does not take a value"" 1>&2; exit 1; }; sim_trace="";;
3538
esac
3539
if test x"$silent" != x"yes" && test x"$sim_trace" != x""; then
3540
  echo "Setting trace flags = $sim_trace" 6>&1
3541
fi
3542
else
3543
  sim_trace=""
3544
fi
3545
 
3546
 
3547
# Check whether --enable-sim-warnings or --disable-sim-warnings was given.
3548
if test "${enable_sim_warnings+set}" = set; then
3549
  enableval="$enable_sim_warnings"
3550
  case "${enableval}" in
3551
  yes)  sim_warnings="-Werror -Wall -Wpointer-arith -Wmissing-prototypes -Wmissing-declarations ";;
3552
  no)   sim_warnings="-w";;
3553
  *)    sim_warnings=`echo "${enableval}" | sed -e "s/,/ /g"`;;
3554
esac
3555
if test x"$silent" != x"yes" && test x"$sim_warnings" != x""; then
3556
  echo "Setting warning flags = $sim_warnings" 6>&1
3557
fi
3558
else
3559
  sim_warnings=""
3560
fi
3561
 
3562
 
3563
# Check whether --enable-sim-xor-endian or --disable-sim-xor-endian was given.
3564
if test "${enable_sim_xor_endian+set}" = set; then
3565
  enableval="$enable_sim_xor_endian"
3566
  case "${enableval}" in
3567
  yes)  sim_xor_endian="-DWITH_XOR_ENDIAN=8";;
3568
  no)   sim_xor_endian="-DWITH_XOR_ENDIAN=0";;
3569
  *)    sim_xor_endian="-DWITH_XOR_ENDIAN=$enableval";;
3570
esac
3571
if test x"$silent" != x"yes" && test x"$sim_xor_endian" != x""; then
3572
  echo "Setting xor-endian flag = $sim_xor_endian" 6>&1
3573
fi
3574
else
3575
  sim_xor_endian=""
3576
fi
3577
 
3578
 
3579
ac_aux_dir=
3580
for ac_dir in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../..; do
3581
  if test -f $ac_dir/install-sh; then
3582
    ac_aux_dir=$ac_dir
3583
    ac_install_sh="$ac_aux_dir/install-sh -c"
3584
    break
3585
  elif test -f $ac_dir/install.sh; then
3586
    ac_aux_dir=$ac_dir
3587
    ac_install_sh="$ac_aux_dir/install.sh -c"
3588
    break
3589
  fi
3590
done
3591
if test -z "$ac_aux_dir"; then
3592
  { echo "configure: error: can not find install-sh or install.sh in `cd $srcdir;pwd`/../.. $srcdir/`cd $srcdir;pwd`/../.." 1>&2; exit 1; }
3593
fi
3594
ac_config_guess=$ac_aux_dir/config.guess
3595
ac_config_sub=$ac_aux_dir/config.sub
3596
ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
3597
 
3598
 
3599
# Do some error checking and defaulting for the host and target type.
3600
# The inputs are:
3601
#    configure --host=HOST --target=TARGET --build=BUILD NONOPT
3602
#
3603
# The rules are:
3604
# 1. You are not allowed to specify --host, --target, and nonopt at the
3605
#    same time.
3606
# 2. Host defaults to nonopt.
3607
# 3. If nonopt is not specified, then host defaults to the current host,
3608
#    as determined by config.guess.
3609
# 4. Target and build default to nonopt.
3610
# 5. If nonopt is not specified, then target and build default to host.
3611
 
3612
# The aliases save the names the user supplied, while $host etc.
3613
# will get canonicalized.
3614
case $host---$target---$nonopt in
3615
NONE---*---* | *---NONE---* | *---*---NONE) ;;
3616
*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
3617
esac
3618
 
3619
 
3620
# Make sure we can run config.sub.
3621
if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
3622
else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
3623
fi
3624
 
3625
echo $ac_n "checking host system type""... $ac_c" 1>&6
3626
echo "configure:3627: checking host system type" >&5
3627
 
3628
host_alias=$host
3629
case "$host_alias" in
3630
NONE)
3631
  case $nonopt in
3632
  NONE)
3633
    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
3634
    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
3635
    fi ;;
3636
  *) host_alias=$nonopt ;;
3637
  esac ;;
3638
esac
3639
 
3640
host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
3641
host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
3642
host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
3643
host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
3644
echo "$ac_t""$host" 1>&6
3645
 
3646
echo $ac_n "checking target system type""... $ac_c" 1>&6
3647
echo "configure:3648: checking target system type" >&5
3648
 
3649
target_alias=$target
3650
case "$target_alias" in
3651
NONE)
3652
  case $nonopt in
3653
  NONE) target_alias=$host_alias ;;
3654
  *) target_alias=$nonopt ;;
3655
  esac ;;
3656
esac
3657
 
3658
target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
3659
target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
3660
target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
3661
target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
3662
echo "$ac_t""$target" 1>&6
3663
 
3664
echo $ac_n "checking build system type""... $ac_c" 1>&6
3665
echo "configure:3666: checking build system type" >&5
3666
 
3667
build_alias=$build
3668
case "$build_alias" in
3669
NONE)
3670
  case $nonopt in
3671
  NONE) build_alias=$host_alias ;;
3672
  *) build_alias=$nonopt ;;
3673
  esac ;;
3674
esac
3675
 
3676
build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
3677
build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
3678
build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
3679
build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
3680
echo "$ac_t""$build" 1>&6
3681
 
3682
test "$host_alias" != "$target_alias" &&
3683
  test "$program_prefix$program_suffix$program_transform_name" = \
3684
    NONENONEs,x,x, &&
3685
  program_prefix=${target_alias}-
3686
 
3687
if test "$program_transform_name" = s,x,x,; then
3688
  program_transform_name=
3689
else
3690
  # Double any \ or $.  echo might interpret backslashes.
3691
  cat <<\EOF_SED > conftestsed
3692
s,\\,\\\\,g; s,\$,$$,g
3693
EOF_SED
3694
  program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
3695
  rm -f conftestsed
3696
fi
3697
test "$program_prefix" != NONE &&
3698
  program_transform_name="s,^,${program_prefix},; $program_transform_name"
3699
# Use a double $ so make ignores it.
3700
test "$program_suffix" != NONE &&
3701
  program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
3702
 
3703
# sed with no file args requires a program.
3704
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
3705
 
3706
 
3707
. ${srcdir}/../../bfd/configure.host
3708
 
3709
 
3710
 
3711
echo $ac_n "checking for st_blksize in struct stat""... $ac_c" 1>&6
3712
echo "configure:3713: checking for st_blksize in struct stat" >&5
3713
if eval "test \"`echo '$''{'ac_cv_struct_st_blksize'+set}'`\" = set"; then
3714
  echo $ac_n "(cached) $ac_c" 1>&6
3715
else
3716
  cat > conftest.$ac_ext <
3717
#line 3718 "configure"
3718
#include "confdefs.h"
3719
#include 
3720
#include 
3721
int main() {
3722
struct stat s; s.st_blksize;
3723
; return 0; }
3724
EOF
3725
if { (eval echo configure:3726: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3726
  rm -rf conftest*
3727
  ac_cv_struct_st_blksize=yes
3728
else
3729
  echo "configure: failed program was:" >&5
3730
  cat conftest.$ac_ext >&5
3731
  rm -rf conftest*
3732
  ac_cv_struct_st_blksize=no
3733
fi
3734
rm -f conftest*
3735
fi
3736
 
3737
echo "$ac_t""$ac_cv_struct_st_blksize" 1>&6
3738
if test $ac_cv_struct_st_blksize = yes; then
3739
  cat >> confdefs.h <<\EOF
3740
#define HAVE_ST_BLKSIZE 1
3741
EOF
3742
 
3743
fi
3744
 
3745
echo $ac_n "checking for st_blocks in struct stat""... $ac_c" 1>&6
3746
echo "configure:3747: checking for st_blocks in struct stat" >&5
3747
if eval "test \"`echo '$''{'ac_cv_struct_st_blocks'+set}'`\" = set"; then
3748
  echo $ac_n "(cached) $ac_c" 1>&6
3749
else
3750
  cat > conftest.$ac_ext <
3751
#line 3752 "configure"
3752
#include "confdefs.h"
3753
#include 
3754
#include 
3755
int main() {
3756
struct stat s; s.st_blocks;
3757
; return 0; }
3758
EOF
3759
if { (eval echo configure:3760: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3760
  rm -rf conftest*
3761
  ac_cv_struct_st_blocks=yes
3762
else
3763
  echo "configure: failed program was:" >&5
3764
  cat conftest.$ac_ext >&5
3765
  rm -rf conftest*
3766
  ac_cv_struct_st_blocks=no
3767
fi
3768
rm -f conftest*
3769
fi
3770
 
3771
echo "$ac_t""$ac_cv_struct_st_blocks" 1>&6
3772
if test $ac_cv_struct_st_blocks = yes; then
3773
  cat >> confdefs.h <<\EOF
3774
#define HAVE_ST_BLOCKS 1
3775
EOF
3776
 
3777
else
3778
  LIBOBJS="$LIBOBJS fileblocks.${ac_objext}"
3779
fi
3780
 
3781
echo $ac_n "checking for st_rdev in struct stat""... $ac_c" 1>&6
3782
echo "configure:3783: checking for st_rdev in struct stat" >&5
3783
if eval "test \"`echo '$''{'ac_cv_struct_st_rdev'+set}'`\" = set"; then
3784
  echo $ac_n "(cached) $ac_c" 1>&6
3785
else
3786
  cat > conftest.$ac_ext <
3787
#line 3788 "configure"
3788
#include "confdefs.h"
3789
#include 
3790
#include 
3791
int main() {
3792
struct stat s; s.st_rdev;
3793
; return 0; }
3794
EOF
3795
if { (eval echo configure:3796: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3796
  rm -rf conftest*
3797
  ac_cv_struct_st_rdev=yes
3798
else
3799
  echo "configure: failed program was:" >&5
3800
  cat conftest.$ac_ext >&5
3801
  rm -rf conftest*
3802
  ac_cv_struct_st_rdev=no
3803
fi
3804
rm -f conftest*
3805
fi
3806
 
3807
echo "$ac_t""$ac_cv_struct_st_rdev" 1>&6
3808
if test $ac_cv_struct_st_rdev = yes; then
3809
  cat >> confdefs.h <<\EOF
3810
#define HAVE_ST_RDEV 1
3811
EOF
3812
 
3813
fi
3814
 
3815
echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
3816
echo "configure:3817: checking whether struct tm is in sys/time.h or time.h" >&5
3817
if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
3818
  echo $ac_n "(cached) $ac_c" 1>&6
3819
else
3820
  cat > conftest.$ac_ext <
3821
#line 3822 "configure"
3822
#include "confdefs.h"
3823
#include 
3824
#include 
3825
int main() {
3826
struct tm *tp; tp->tm_sec;
3827
; return 0; }
3828
EOF
3829
if { (eval echo configure:3830: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3830
  rm -rf conftest*
3831
  ac_cv_struct_tm=time.h
3832
else
3833
  echo "configure: failed program was:" >&5
3834
  cat conftest.$ac_ext >&5
3835
  rm -rf conftest*
3836
  ac_cv_struct_tm=sys/time.h
3837
fi
3838
rm -f conftest*
3839
fi
3840
 
3841
echo "$ac_t""$ac_cv_struct_tm" 1>&6
3842
if test $ac_cv_struct_tm = sys/time.h; then
3843
  cat >> confdefs.h <<\EOF
3844
#define TM_IN_SYS_TIME 1
3845
EOF
3846
 
3847
fi
3848
 
3849
echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6
3850
echo "configure:3851: checking for tm_zone in struct tm" >&5
3851
if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then
3852
  echo $ac_n "(cached) $ac_c" 1>&6
3853
else
3854
  cat > conftest.$ac_ext <
3855
#line 3856 "configure"
3856
#include "confdefs.h"
3857
#include 
3858
#include <$ac_cv_struct_tm>
3859
int main() {
3860
struct tm tm; tm.tm_zone;
3861
; return 0; }
3862
EOF
3863
if { (eval echo configure:3864: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3864
  rm -rf conftest*
3865
  ac_cv_struct_tm_zone=yes
3866
else
3867
  echo "configure: failed program was:" >&5
3868
  cat conftest.$ac_ext >&5
3869
  rm -rf conftest*
3870
  ac_cv_struct_tm_zone=no
3871
fi
3872
rm -f conftest*
3873
fi
3874
 
3875
echo "$ac_t""$ac_cv_struct_tm_zone" 1>&6
3876
if test "$ac_cv_struct_tm_zone" = yes; then
3877
  cat >> confdefs.h <<\EOF
3878
#define HAVE_TM_ZONE 1
3879
EOF
3880
 
3881
else
3882
  echo $ac_n "checking for tzname""... $ac_c" 1>&6
3883
echo "configure:3884: checking for tzname" >&5
3884
if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then
3885
  echo $ac_n "(cached) $ac_c" 1>&6
3886
else
3887
  cat > conftest.$ac_ext <
3888
#line 3889 "configure"
3889
#include "confdefs.h"
3890
#include 
3891
#ifndef tzname /* For SGI.  */
3892
extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
3893
#endif
3894
int main() {
3895
atoi(*tzname);
3896
; return 0; }
3897
EOF
3898
if { (eval echo configure:3899: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3899
  rm -rf conftest*
3900
  ac_cv_var_tzname=yes
3901
else
3902
  echo "configure: failed program was:" >&5
3903
  cat conftest.$ac_ext >&5
3904
  rm -rf conftest*
3905
  ac_cv_var_tzname=no
3906
fi
3907
rm -f conftest*
3908
fi
3909
 
3910
echo "$ac_t""$ac_cv_var_tzname" 1>&6
3911
  if test $ac_cv_var_tzname = yes; then
3912
    cat >> confdefs.h <<\EOF
3913
#define HAVE_TZNAME 1
3914
EOF
3915
 
3916
  fi
3917
fi
3918
 
3919
 
3920
echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
3921
echo "configure:3922: checking for uid_t in sys/types.h" >&5
3922
if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
3923
  echo $ac_n "(cached) $ac_c" 1>&6
3924
else
3925
  cat > conftest.$ac_ext <
3926
#line 3927 "configure"
3927
#include "confdefs.h"
3928
#include 
3929
EOF
3930
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3931
  egrep "uid_t" >/dev/null 2>&1; then
3932
  rm -rf conftest*
3933
  ac_cv_type_uid_t=yes
3934
else
3935
  rm -rf conftest*
3936
  ac_cv_type_uid_t=no
3937
fi
3938
rm -f conftest*
3939
 
3940
fi
3941
 
3942
echo "$ac_t""$ac_cv_type_uid_t" 1>&6
3943
if test $ac_cv_type_uid_t = no; then
3944
  cat >> confdefs.h <<\EOF
3945
#define uid_t int
3946
EOF
3947
 
3948
  cat >> confdefs.h <<\EOF
3949
#define gid_t int
3950
EOF
3951
 
3952
fi
3953
 
3954
echo $ac_n "checking type of array argument to getgroups""... $ac_c" 1>&6
3955
echo "configure:3956: checking type of array argument to getgroups" >&5
3956
if eval "test \"`echo '$''{'ac_cv_type_getgroups'+set}'`\" = set"; then
3957
  echo $ac_n "(cached) $ac_c" 1>&6
3958
else
3959
  if test "$cross_compiling" = yes; then
3960
  ac_cv_type_getgroups=cross
3961
else
3962
  cat > conftest.$ac_ext <
3963
#line 3964 "configure"
3964
#include "confdefs.h"
3965
 
3966
/* Thanks to Mike Rendell for this test.  */
3967
#include 
3968
#define NGID 256
3969
#undef MAX
3970
#define MAX(x, y) ((x) > (y) ? (x) : (y))
3971
main()
3972
{
3973
  gid_t gidset[NGID];
3974
  int i, n;
3975
  union { gid_t gval; long lval; }  val;
3976
 
3977
  val.lval = -1;
3978
  for (i = 0; i < NGID; i++)
3979
    gidset[i] = val.gval;
3980
  n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
3981
                 gidset);
3982
  /* Exit non-zero if getgroups seems to require an array of ints.  This
3983
     happens when gid_t is short but getgroups modifies an array of ints.  */
3984
  exit ((n > 0 && gidset[n] != val.gval) ? 1 : 0);
3985
}
3986
 
3987
EOF
3988
if { (eval echo configure:3989: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3989
then
3990
    ac_cv_type_getgroups=gid_t
3991
else
3992
  echo "configure: failed program was:" >&5
3993
  cat conftest.$ac_ext >&5
3994
  rm -fr conftest*
3995
  ac_cv_type_getgroups=int
3996
fi
3997
rm -fr conftest*
3998
fi
3999
 
4000
if test $ac_cv_type_getgroups = cross; then
4001
        cat > conftest.$ac_ext <
4002
#line 4003 "configure"
4003
#include "confdefs.h"
4004
#include 
4005
EOF
4006
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4007
  egrep "getgroups.*int.*gid_t" >/dev/null 2>&1; then
4008
  rm -rf conftest*
4009
  ac_cv_type_getgroups=gid_t
4010
else
4011
  rm -rf conftest*
4012
  ac_cv_type_getgroups=int
4013
fi
4014
rm -f conftest*
4015
 
4016
fi
4017
fi
4018
 
4019
echo "$ac_t""$ac_cv_type_getgroups" 1>&6
4020
cat >> confdefs.h <
4021
#define GETGROUPS_T $ac_cv_type_getgroups
4022
EOF
4023
 
4024
 
4025
echo $ac_n "checking for mode_t""... $ac_c" 1>&6
4026
echo "configure:4027: checking for mode_t" >&5
4027
if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
4028
  echo $ac_n "(cached) $ac_c" 1>&6
4029
else
4030
  cat > conftest.$ac_ext <
4031
#line 4032 "configure"
4032
#include "confdefs.h"
4033
#include 
4034
#if STDC_HEADERS
4035
#include 
4036
#include 
4037
#endif
4038
EOF
4039
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4040
  egrep "(^|[^a-zA-Z_0-9])mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4041
  rm -rf conftest*
4042
  ac_cv_type_mode_t=yes
4043
else
4044
  rm -rf conftest*
4045
  ac_cv_type_mode_t=no
4046
fi
4047
rm -f conftest*
4048
 
4049
fi
4050
echo "$ac_t""$ac_cv_type_mode_t" 1>&6
4051
if test $ac_cv_type_mode_t = no; then
4052
  cat >> confdefs.h <<\EOF
4053
#define mode_t int
4054
EOF
4055
 
4056
fi
4057
 
4058
echo $ac_n "checking for off_t""... $ac_c" 1>&6
4059
echo "configure:4060: checking for off_t" >&5
4060
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
4061
  echo $ac_n "(cached) $ac_c" 1>&6
4062
else
4063
  cat > conftest.$ac_ext <
4064
#line 4065 "configure"
4065
#include "confdefs.h"
4066
#include 
4067
#if STDC_HEADERS
4068
#include 
4069
#include 
4070
#endif
4071
EOF
4072
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4073
  egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4074
  rm -rf conftest*
4075
  ac_cv_type_off_t=yes
4076
else
4077
  rm -rf conftest*
4078
  ac_cv_type_off_t=no
4079
fi
4080
rm -f conftest*
4081
 
4082
fi
4083
echo "$ac_t""$ac_cv_type_off_t" 1>&6
4084
if test $ac_cv_type_off_t = no; then
4085
  cat >> confdefs.h <<\EOF
4086
#define off_t long
4087
EOF
4088
 
4089
fi
4090
 
4091
echo $ac_n "checking for pid_t""... $ac_c" 1>&6
4092
echo "configure:4093: checking for pid_t" >&5
4093
if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
4094
  echo $ac_n "(cached) $ac_c" 1>&6
4095
else
4096
  cat > conftest.$ac_ext <
4097
#line 4098 "configure"
4098
#include "confdefs.h"
4099
#include 
4100
#if STDC_HEADERS
4101
#include 
4102
#include 
4103
#endif
4104
EOF
4105
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4106
  egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4107
  rm -rf conftest*
4108
  ac_cv_type_pid_t=yes
4109
else
4110
  rm -rf conftest*
4111
  ac_cv_type_pid_t=no
4112
fi
4113
rm -f conftest*
4114
 
4115
fi
4116
echo "$ac_t""$ac_cv_type_pid_t" 1>&6
4117
if test $ac_cv_type_pid_t = no; then
4118
  cat >> confdefs.h <<\EOF
4119
#define pid_t int
4120
EOF
4121
 
4122
fi
4123
 
4124
echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
4125
echo "configure:4126: checking return type of signal handlers" >&5
4126
if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
4127
  echo $ac_n "(cached) $ac_c" 1>&6
4128
else
4129
  cat > conftest.$ac_ext <
4130
#line 4131 "configure"
4131
#include "confdefs.h"
4132
#include 
4133
#include 
4134
#ifdef signal
4135
#undef signal
4136
#endif
4137
#ifdef __cplusplus
4138
extern "C" void (*signal (int, void (*)(int)))(int);
4139
#else
4140
void (*signal ()) ();
4141
#endif
4142
 
4143
int main() {
4144
int i;
4145
; return 0; }
4146
EOF
4147
if { (eval echo configure:4148: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4148
  rm -rf conftest*
4149
  ac_cv_type_signal=void
4150
else
4151
  echo "configure: failed program was:" >&5
4152
  cat conftest.$ac_ext >&5
4153
  rm -rf conftest*
4154
  ac_cv_type_signal=int
4155
fi
4156
rm -f conftest*
4157
fi
4158
 
4159
echo "$ac_t""$ac_cv_type_signal" 1>&6
4160
cat >> confdefs.h <
4161
#define RETSIGTYPE $ac_cv_type_signal
4162
EOF
4163
 
4164
 
4165
echo $ac_n "checking for size_t""... $ac_c" 1>&6
4166
echo "configure:4167: checking for size_t" >&5
4167
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
4168
  echo $ac_n "(cached) $ac_c" 1>&6
4169
else
4170
  cat > conftest.$ac_ext <
4171
#line 4172 "configure"
4172
#include "confdefs.h"
4173
#include 
4174
#if STDC_HEADERS
4175
#include 
4176
#include 
4177
#endif
4178
EOF
4179
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4180
  egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4181
  rm -rf conftest*
4182
  ac_cv_type_size_t=yes
4183
else
4184
  rm -rf conftest*
4185
  ac_cv_type_size_t=no
4186
fi
4187
rm -f conftest*
4188
 
4189
fi
4190
echo "$ac_t""$ac_cv_type_size_t" 1>&6
4191
if test $ac_cv_type_size_t = no; then
4192
  cat >> confdefs.h <<\EOF
4193
#define size_t unsigned
4194
EOF
4195
 
4196
fi
4197
 
4198
echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
4199
echo "configure:4200: checking for uid_t in sys/types.h" >&5
4200
if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
4201
  echo $ac_n "(cached) $ac_c" 1>&6
4202
else
4203
  cat > conftest.$ac_ext <
4204
#line 4205 "configure"
4205
#include "confdefs.h"
4206
#include 
4207
EOF
4208
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4209
  egrep "uid_t" >/dev/null 2>&1; then
4210
  rm -rf conftest*
4211
  ac_cv_type_uid_t=yes
4212
else
4213
  rm -rf conftest*
4214
  ac_cv_type_uid_t=no
4215
fi
4216
rm -f conftest*
4217
 
4218
fi
4219
 
4220
echo "$ac_t""$ac_cv_type_uid_t" 1>&6
4221
if test $ac_cv_type_uid_t = no; then
4222
  cat >> confdefs.h <<\EOF
4223
#define uid_t int
4224
EOF
4225
 
4226
  cat >> confdefs.h <<\EOF
4227
#define gid_t int
4228
EOF
4229
 
4230
fi
4231
 
4232
 
4233
for ac_func in access cfgetispeed cfgetospeed cfsetispeed cfsetospeed chdir chmod chown dup dup2 fchmod fchown fcntl fstat fstatfs getdirentries getegid geteuid getgid getpid getppid getrusage gettimeofday getuid ioctl kill link lseek lstat mkdir pipe readlink rmdir setreuid setregid stat sigprocmask stat symlink tcgetattr tcsetattr tcsendbreak tcdrain tcflush tcflow tcgetpgrp tcsetpgrp time umask unlink
4234
do
4235
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
4236
echo "configure:4237: checking for $ac_func" >&5
4237
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
4238
  echo $ac_n "(cached) $ac_c" 1>&6
4239
else
4240
  cat > conftest.$ac_ext <
4241
#line 4242 "configure"
4242
#include "confdefs.h"
4243
/* System header to define __stub macros and hopefully few prototypes,
4244
    which can conflict with char $ac_func(); below.  */
4245
#include 
4246
/* Override any gcc2 internal prototype to avoid an error.  */
4247
/* We use char because int might match the return type of a gcc2
4248
    builtin and then its argument prototype would still apply.  */
4249
char $ac_func();
4250
 
4251
int main() {
4252
 
4253
/* The GNU C library defines this for functions which it implements
4254
    to always fail with ENOSYS.  Some functions are actually named
4255
    something starting with __ and the normal name is an alias.  */
4256
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
4257
choke me
4258
#else
4259
$ac_func();
4260
#endif
4261
 
4262
; return 0; }
4263
EOF
4264
if { (eval echo configure:4265: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4265
  rm -rf conftest*
4266
  eval "ac_cv_func_$ac_func=yes"
4267
else
4268
  echo "configure: failed program was:" >&5
4269
  cat conftest.$ac_ext >&5
4270
  rm -rf conftest*
4271
  eval "ac_cv_func_$ac_func=no"
4272
fi
4273
rm -f conftest*
4274
fi
4275
 
4276
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
4277
  echo "$ac_t""yes" 1>&6
4278
    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
4279
  cat >> confdefs.h <
4280
#define $ac_tr_func 1
4281
EOF
4282
 
4283
else
4284
  echo "$ac_t""no" 1>&6
4285
fi
4286
done
4287
 
4288
 
4289
for ac_hdr in fcntl.h stdlib.h string.h strings.h sys/ioctl.h sys/param.h sys/resource.h sys/stat.h sys/termio.h sys/termios.h sys/time.h sys/times.h sys/types.h time.h unistd.h
4290
do
4291
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4292
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
4293
echo "configure:4294: checking for $ac_hdr" >&5
4294
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
4295
  echo $ac_n "(cached) $ac_c" 1>&6
4296
else
4297
  cat > conftest.$ac_ext <
4298
#line 4299 "configure"
4299
#include "confdefs.h"
4300
#include <$ac_hdr>
4301
EOF
4302
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
4303
{ (eval echo configure:4304: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
4304
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
4305
if test -z "$ac_err"; then
4306
  rm -rf conftest*
4307
  eval "ac_cv_header_$ac_safe=yes"
4308
else
4309
  echo "$ac_err" >&5
4310
  echo "configure: failed program was:" >&5
4311
  cat conftest.$ac_ext >&5
4312
  rm -rf conftest*
4313
  eval "ac_cv_header_$ac_safe=no"
4314
fi
4315
rm -f conftest*
4316
fi
4317
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
4318
  echo "$ac_t""yes" 1>&6
4319
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4320
  cat >> confdefs.h <
4321
#define $ac_tr_hdr 1
4322
EOF
4323
 
4324
else
4325
  echo "$ac_t""no" 1>&6
4326
fi
4327
done
4328
 
4329
ac_header_dirent=no
4330
for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
4331
do
4332
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
4333
echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
4334
echo "configure:4335: checking for $ac_hdr that defines DIR" >&5
4335
if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
4336
  echo $ac_n "(cached) $ac_c" 1>&6
4337
else
4338
  cat > conftest.$ac_ext <
4339
#line 4340 "configure"
4340
#include "confdefs.h"
4341
#include 
4342
#include <$ac_hdr>
4343
int main() {
4344
DIR *dirp = 0;
4345
; return 0; }
4346
EOF
4347
if { (eval echo configure:4348: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4348
  rm -rf conftest*
4349
  eval "ac_cv_header_dirent_$ac_safe=yes"
4350
else
4351
  echo "configure: failed program was:" >&5
4352
  cat conftest.$ac_ext >&5
4353
  rm -rf conftest*
4354
  eval "ac_cv_header_dirent_$ac_safe=no"
4355
fi
4356
rm -f conftest*
4357
fi
4358
if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
4359
  echo "$ac_t""yes" 1>&6
4360
    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
4361
  cat >> confdefs.h <
4362
#define $ac_tr_hdr 1
4363
EOF
4364
 ac_header_dirent=$ac_hdr; break
4365
else
4366
  echo "$ac_t""no" 1>&6
4367
fi
4368
done
4369
# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
4370
if test $ac_header_dirent = dirent.h; then
4371
echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
4372
echo "configure:4373: checking for opendir in -ldir" >&5
4373
ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
4374
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4375
  echo $ac_n "(cached) $ac_c" 1>&6
4376
else
4377
  ac_save_LIBS="$LIBS"
4378
LIBS="-ldir  $LIBS"
4379
cat > conftest.$ac_ext <
4380
#line 4381 "configure"
4381
#include "confdefs.h"
4382
/* Override any gcc2 internal prototype to avoid an error.  */
4383
/* We use char because int might match the return type of a gcc2
4384
    builtin and then its argument prototype would still apply.  */
4385
char opendir();
4386
 
4387
int main() {
4388
opendir()
4389
; return 0; }
4390
EOF
4391
if { (eval echo configure:4392: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4392
  rm -rf conftest*
4393
  eval "ac_cv_lib_$ac_lib_var=yes"
4394
else
4395
  echo "configure: failed program was:" >&5
4396
  cat conftest.$ac_ext >&5
4397
  rm -rf conftest*
4398
  eval "ac_cv_lib_$ac_lib_var=no"
4399
fi
4400
rm -f conftest*
4401
LIBS="$ac_save_LIBS"
4402
 
4403
fi
4404
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4405
  echo "$ac_t""yes" 1>&6
4406
  LIBS="$LIBS -ldir"
4407
else
4408
  echo "$ac_t""no" 1>&6
4409
fi
4410
 
4411
else
4412
echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
4413
echo "configure:4414: checking for opendir in -lx" >&5
4414
ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
4415
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
4416
  echo $ac_n "(cached) $ac_c" 1>&6
4417
else
4418
  ac_save_LIBS="$LIBS"
4419
LIBS="-lx  $LIBS"
4420
cat > conftest.$ac_ext <
4421
#line 4422 "configure"
4422
#include "confdefs.h"
4423
/* Override any gcc2 internal prototype to avoid an error.  */
4424
/* We use char because int might match the return type of a gcc2
4425
    builtin and then its argument prototype would still apply.  */
4426
char opendir();
4427
 
4428
int main() {
4429
opendir()
4430
; return 0; }
4431
EOF
4432
if { (eval echo configure:4433: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
4433
  rm -rf conftest*
4434
  eval "ac_cv_lib_$ac_lib_var=yes"
4435
else
4436
  echo "configure: failed program was:" >&5
4437
  cat conftest.$ac_ext >&5
4438
  rm -rf conftest*
4439
  eval "ac_cv_lib_$ac_lib_var=no"
4440
fi
4441
rm -f conftest*
4442
LIBS="$ac_save_LIBS"
4443
 
4444
fi
4445
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
4446
  echo "$ac_t""yes" 1>&6
4447
  LIBS="$LIBS -lx"
4448
else
4449
  echo "$ac_t""no" 1>&6
4450
fi
4451
 
4452
fi
4453
 
4454
 
4455
sim_termio=""
4456
echo $ac_n "checking for struct termios""... $ac_c" 1>&6
4457
echo "configure:4458: checking for struct termios" >&5
4458
if eval "test \"`echo '$''{'ac_cv_termios_struct'+set}'`\" = set"; then
4459
  echo $ac_n "(cached) $ac_c" 1>&6
4460
else
4461
  cat > conftest.$ac_ext <
4462
#line 4463 "configure"
4463
#include "confdefs.h"
4464
#include 
4465
#include 
4466
int main() {
4467
static struct termios x;
4468
 x.c_iflag = 0;
4469
 x.c_oflag = 0;
4470
 x.c_cflag = 0;
4471
 x.c_lflag = 0;
4472
 x.c_cc[NCCS] = 0;
4473
; return 0; }
4474
EOF
4475
if { (eval echo configure:4476: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4476
  rm -rf conftest*
4477
  ac_cv_termios_struct=yes
4478
else
4479
  echo "configure: failed program was:" >&5
4480
  cat conftest.$ac_ext >&5
4481
  rm -rf conftest*
4482
  ac_cv_termios_struct=no
4483
fi
4484
rm -f conftest*
4485
fi
4486
 
4487
echo "$ac_t""$ac_cv_termios_struct" 1>&6
4488
if test $ac_cv_termios_struct = yes; then
4489
  sim_termio="$sim_termio -DHAVE_TERMIOS_STRUCTURE"
4490
fi
4491
 
4492
if test "$ac_cv_termios_struct" = "yes"; then
4493
  echo $ac_n "checking for c_line field in struct termios""... $ac_c" 1>&6
4494
echo "configure:4495: checking for c_line field in struct termios" >&5
4495
  if eval "test \"`echo '$''{'ac_cv_termios_cline'+set}'`\" = set"; then
4496
  echo $ac_n "(cached) $ac_c" 1>&6
4497
else
4498
  cat > conftest.$ac_ext <
4499
#line 4500 "configure"
4500
#include "confdefs.h"
4501
#include 
4502
#include 
4503
int main() {
4504
static struct termios x; x.c_line = 0;
4505
; return 0; }
4506
EOF
4507
if { (eval echo configure:4508: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4508
  rm -rf conftest*
4509
  ac_cv_termios_cline=yes
4510
else
4511
  echo "configure: failed program was:" >&5
4512
  cat conftest.$ac_ext >&5
4513
  rm -rf conftest*
4514
  ac_cv_termios_cline=no
4515
fi
4516
rm -f conftest*
4517
fi
4518
 
4519
 
4520
  echo "$ac_t""$ac_cv_termios_cline" 1>&6
4521
  if test $ac_cv_termios_cline = yes; then
4522
    sim_termio="$sim_termio -DHAVE_TERMIOS_CLINE"
4523
  fi
4524
else
4525
  ac_cv_termios_cline=no
4526
fi
4527
 
4528
if test "$ac_cv_termios_struct" != "yes"; then
4529
  echo $ac_n "checking for struct termio""... $ac_c" 1>&6
4530
echo "configure:4531: checking for struct termio" >&5
4531
  if eval "test \"`echo '$''{'ac_cv_termio_struct'+set}'`\" = set"; then
4532
  echo $ac_n "(cached) $ac_c" 1>&6
4533
else
4534
  cat > conftest.$ac_ext <
4535
#line 4536 "configure"
4536
#include "confdefs.h"
4537
#include 
4538
#include 
4539
int main() {
4540
static struct termio x;
4541
 x.c_iflag = 0;
4542
 x.c_oflag = 0;
4543
 x.c_cflag = 0;
4544
 x.c_lflag = 0;
4545
 x.c_cc[NCC] = 0;
4546
; return 0; }
4547
EOF
4548
if { (eval echo configure:4549: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4549
  rm -rf conftest*
4550
  ac_cv_termio_struct=yes
4551
else
4552
  echo "configure: failed program was:" >&5
4553
  cat conftest.$ac_ext >&5
4554
  rm -rf conftest*
4555
  ac_cv_termio_struct=no
4556
fi
4557
rm -f conftest*
4558
fi
4559
 
4560
  echo "$ac_t""$ac_cv_termio_struct" 1>&6
4561
  if test $ac_cv_termio_struct = yes; then
4562
    sim_termio="$sim_termio -DHAVE_TERMIO_STRUCTURE"
4563
  fi
4564
else
4565
  ac_cv_termio_struct=no
4566
fi
4567
 
4568
if test "$ac_cv_termio_struct" = "yes"; then
4569
  echo $ac_n "checking for c_line field in struct termio""... $ac_c" 1>&6
4570
echo "configure:4571: checking for c_line field in struct termio" >&5
4571
  if eval "test \"`echo '$''{'ac_cv_termio_cline'+set}'`\" = set"; then
4572
  echo $ac_n "(cached) $ac_c" 1>&6
4573
else
4574
  cat > conftest.$ac_ext <
4575
#line 4576 "configure"
4576
#include "confdefs.h"
4577
#include 
4578
#include 
4579
int main() {
4580
static struct termio x; x.c_line = 0;
4581
; return 0; }
4582
EOF
4583
if { (eval echo configure:4584: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4584
  rm -rf conftest*
4585
  ac_cv_termio_cline=yes
4586
else
4587
  echo "configure: failed program was:" >&5
4588
  cat conftest.$ac_ext >&5
4589
  rm -rf conftest*
4590
  ac_cv_termio_cline=no
4591
fi
4592
rm -f conftest*
4593
fi
4594
 
4595
 
4596
  echo "$ac_t""$ac_cv_termio_cline" 1>&6
4597
  if test $ac_cv_termio_cline = yes; then
4598
    sim_termio="$sim_termio -DHAVE_TERMIO_CLINE"
4599
  fi
4600
else
4601
  ac_cv_termio_cline=no
4602
fi
4603
 
4604
sim_devzero=""
4605
echo $ac_n "checking for /dev/zero""... $ac_c" 1>&6
4606
echo "configure:4607: checking for /dev/zero" >&5
4607
if eval "test \"`echo '$''{'ac_cv_devzero'+set}'`\" = set"; then
4608
  echo $ac_n "(cached) $ac_c" 1>&6
4609
else
4610
  if test "$cross_compiling" = yes; then
4611
  ac_cv_devzero=no
4612
else
4613
  cat > conftest.$ac_ext <
4614
#line 4615 "configure"
4615
#include "confdefs.h"
4616
#include 
4617
main () {
4618
  char buf[2048];
4619
  int i;
4620
  int fd = open ("/dev/zero", O_RDONLY);
4621
  if (fd < 0)
4622
    return 1;
4623
  for (i = 0; i < sizeof (buf); i++)
4624
    buf[i] = 1;
4625
  if (read (fd, buf, sizeof (buf)) != sizeof (buf))
4626
    return 1;
4627
  for (i = 0; i < sizeof (buf); i++)
4628
    if (buf[i])
4629
      return 1;
4630
  return 0;
4631
}
4632
EOF
4633
if { (eval echo configure:4634: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4634
then
4635
  ac_cv_devzero=yes
4636
else
4637
  echo "configure: failed program was:" >&5
4638
  cat conftest.$ac_ext >&5
4639
  rm -fr conftest*
4640
  ac_cv_devzero=no
4641
fi
4642
rm -fr conftest*
4643
fi
4644
 
4645
fi
4646
 
4647
echo "$ac_t""$ac_cv_devzero" 1>&6
4648
if test $ac_cv_devzero = yes; then
4649
  sim_devzero="-DHAVE_DEVZERO"
4650
else
4651
  sim_devzero=""
4652
fi
4653
 
4654
echo $ac_n "checking for common simulator directory""... $ac_c" 1>&6
4655
echo "configure:4656: checking for common simulator directory" >&5
4656
if test -f "${srcdir}/../common/callback.c"; then
4657
  echo "$ac_t""yes" 1>&6
4658
  sim_callback="callback.o targ-map.o"
4659
  sim_targ_vals="targ-vals.h targ-map.c targ-vals.def"
4660
else
4661
  echo "$ac_t""no" 1>&6
4662
  sim_callback=""
4663
  sim_targ_vals=""
4664
fi
4665
 
4666
echo $ac_n "checking for common simulator directory fpu implementation""... $ac_c" 1>&6
4667
echo "configure:4668: checking for common simulator directory fpu implementation" >&5
4668
if test -f "${srcdir}/../common/sim-fpu.c"; then
4669
  echo "$ac_t""yes" 1>&6
4670
  sim_fpu_cflags="-DHAVE_COMMON_FPU -I${srcdir}/../common"
4671
  sim_fpu="sim-fpu.o"
4672
else
4673
  echo "$ac_t""no" 1>&6
4674
  sim_fpu_cflags=
4675
  sim_fpu=
4676
fi
4677
 
4678
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
4679
echo "configure:4680: checking for Cygwin environment" >&5
4680
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
4681
  echo $ac_n "(cached) $ac_c" 1>&6
4682
else
4683
  cat > conftest.$ac_ext <
4684
#line 4685 "configure"
4685
#include "confdefs.h"
4686
 
4687
int main() {
4688
 
4689
#ifndef __CYGWIN__
4690
#define __CYGWIN__ __CYGWIN32__
4691
#endif
4692
return __CYGWIN__;
4693
; return 0; }
4694
EOF
4695
if { (eval echo configure:4696: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4696
  rm -rf conftest*
4697
  ac_cv_cygwin=yes
4698
else
4699
  echo "configure: failed program was:" >&5
4700
  cat conftest.$ac_ext >&5
4701
  rm -rf conftest*
4702
  ac_cv_cygwin=no
4703
fi
4704
rm -f conftest*
4705
rm -f conftest*
4706
fi
4707
 
4708
echo "$ac_t""$ac_cv_cygwin" 1>&6
4709
CYGWIN=
4710
test "$ac_cv_cygwin" = yes && CYGWIN=yes
4711
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
4712
echo "configure:4713: checking for mingw32 environment" >&5
4713
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
4714
  echo $ac_n "(cached) $ac_c" 1>&6
4715
else
4716
  cat > conftest.$ac_ext <
4717
#line 4718 "configure"
4718
#include "confdefs.h"
4719
 
4720
int main() {
4721
return __MINGW32__;
4722
; return 0; }
4723
EOF
4724
if { (eval echo configure:4725: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4725
  rm -rf conftest*
4726
  ac_cv_mingw32=yes
4727
else
4728
  echo "configure: failed program was:" >&5
4729
  cat conftest.$ac_ext >&5
4730
  rm -rf conftest*
4731
  ac_cv_mingw32=no
4732
fi
4733
rm -f conftest*
4734
rm -f conftest*
4735
fi
4736
 
4737
echo "$ac_t""$ac_cv_mingw32" 1>&6
4738
MINGW32=
4739
test "$ac_cv_mingw32" = yes && MINGW32=yes
4740
 
4741
 
4742
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
4743
echo "configure:4744: checking for executable suffix" >&5
4744
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
4745
  echo $ac_n "(cached) $ac_c" 1>&6
4746
else
4747
  if test "$CYGWIN" = yes || test "$MINGW32" = yes; then
4748
  ac_cv_exeext=.exe
4749
else
4750
  rm -f conftest*
4751
  echo 'int main () { return 0; }' > conftest.$ac_ext
4752
  ac_cv_exeext=
4753
  if { (eval echo configure:4754: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
4754
    for file in conftest.*; do
4755
      case $file in
4756
      *.c | *.o | *.obj | *.ilk | *.pdb) ;;
4757
      *) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
4758
      esac
4759
    done
4760
  else
4761
    { echo "configure: error: installation or configuration problem: compiler cannot create executables." 1>&2; exit 1; }
4762
  fi
4763
  rm -f conftest*
4764
  test x"${ac_cv_exeext}" = x && ac_cv_exeext=no
4765
fi
4766
fi
4767
 
4768
EXEEXT=""
4769
test x"${ac_cv_exeext}" != xno && EXEEXT=${ac_cv_exeext}
4770
echo "$ac_t""${ac_cv_exeext}" 1>&6
4771
ac_exeext=$EXEEXT
4772
 
4773
 
4774
 
4775
 
4776
 
4777
AR=${AR-ar}
4778
 
4779
# Extract the first word of "ranlib", so it can be a program name with args.
4780
set dummy ranlib; ac_word=$2
4781
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
4782
echo "configure:4783: checking for $ac_word" >&5
4783
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
4784
  echo $ac_n "(cached) $ac_c" 1>&6
4785
else
4786
  if test -n "$RANLIB"; then
4787
  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4788
else
4789
  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
4790
  ac_dummy="$PATH"
4791
  for ac_dir in $ac_dummy; do
4792
    test -z "$ac_dir" && ac_dir=.
4793
    if test -f $ac_dir/$ac_word; then
4794
      ac_cv_prog_RANLIB="ranlib"
4795
      break
4796
    fi
4797
  done
4798
  IFS="$ac_save_ifs"
4799
  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
4800
fi
4801
fi
4802
RANLIB="$ac_cv_prog_RANLIB"
4803
if test -n "$RANLIB"; then
4804
  echo "$ac_t""$RANLIB" 1>&6
4805
else
4806
  echo "$ac_t""no" 1>&6
4807
fi
4808
 
4809
 
4810
 
4811
 
4812
 
4813
 
4814
 
4815
 
4816
 
4817
 
4818
 
4819
 
4820
 
4821
 
4822
 
4823
 
4824
 
4825
 
4826
 
4827
 
4828
 
4829
 
4830
 
4831
 
4832
 
4833
 
4834
 
4835
 
4836
 
4837
 
4838
 
4839
 
4840
 
4841
 
4842
 
4843
 
4844
 
4845
 
4846
 
4847
 
4848
 
4849
 
4850
 
4851
 
4852
 
4853
 
4854
trap '' 1 2 15
4855
cat > confcache <<\EOF
4856
# This file is a shell script that caches the results of configure
4857
# tests run on this system so they can be shared between configure
4858
# scripts and configure runs.  It is not useful on other systems.
4859
# If it contains results you don't want to keep, you may remove or edit it.
4860
#
4861
# By default, configure uses ./config.cache as the cache file,
4862
# creating it if it does not exist already.  You can give configure
4863
# the --cache-file=FILE option to use a different cache file; that is
4864
# what configure does when it calls configure scripts in
4865
# subdirectories, so they share the cache.
4866
# Giving --cache-file=/dev/null disables caching, for debugging configure.
4867
# config.status only pays attention to the cache file if you give it the
4868
# --recheck option to rerun configure.
4869
#
4870
EOF
4871
# The following way of writing the cache mishandles newlines in values,
4872
# but we know of no workaround that is simple, portable, and efficient.
4873
# So, don't put newlines in cache variables' values.
4874
# Ultrix sh set writes to stderr and can't be redirected directly,
4875
# and sets the high bit in the cache file unless we assign to the vars.
4876
(set) 2>&1 |
4877
  case `(ac_space=' '; set | grep ac_space) 2>&1` in
4878
  *ac_space=\ *)
4879
    # `set' does not quote correctly, so add quotes (double-quote substitution
4880
    # turns \\\\ into \\, and sed turns \\ into \).
4881
    sed -n \
4882
      -e "s/'/'\\\\''/g" \
4883
      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
4884
    ;;
4885
  *)
4886
    # `set' quotes correctly as required by POSIX, so do not add quotes.
4887
    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
4888
    ;;
4889
  esac >> confcache
4890
if cmp -s $cache_file confcache; then
4891
  :
4892
else
4893
  if test -w $cache_file; then
4894
    echo "updating cache $cache_file"
4895
    cat confcache > $cache_file
4896
  else
4897
    echo "not updating unwritable cache $cache_file"
4898
  fi
4899
fi
4900
rm -f confcache
4901
 
4902
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
4903
 
4904
test "x$prefix" = xNONE && prefix=$ac_default_prefix
4905
# Let make expand exec_prefix.
4906
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4907
 
4908
# Any assignment to VPATH causes Sun make to only execute
4909
# the first set of double-colon rules, so remove it if not needed.
4910
# If there is a colon in the path, we need to keep it.
4911
if test "x$srcdir" = x.; then
4912
  ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
4913
fi
4914
 
4915
trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
4916
 
4917
DEFS=-DHAVE_CONFIG_H
4918
 
4919
# Without the "./", some shells look in PATH for config.status.
4920
: ${CONFIG_STATUS=./config.status}
4921
 
4922
echo creating $CONFIG_STATUS
4923
rm -f $CONFIG_STATUS
4924
cat > $CONFIG_STATUS <
4925
#! /bin/sh
4926
# Generated automatically by configure.
4927
# Run this file to recreate the current configuration.
4928
# This directory was configured as follows,
4929
# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
4930
#
4931
# $0 $ac_configure_args
4932
#
4933
# Compiler output produced by configure, useful for debugging
4934
# configure, is in ./config.log if it exists.
4935
 
4936
ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
4937
for ac_option
4938
do
4939
  case "\$ac_option" in
4940
  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
4941
    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
4942
    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
4943
  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
4944
    echo "$CONFIG_STATUS generated by autoconf version 2.13"
4945
    exit 0 ;;
4946
  -help | --help | --hel | --he | --h)
4947
    echo "\$ac_cs_usage"; exit 0 ;;
4948
  *) echo "\$ac_cs_usage"; exit 1 ;;
4949
  esac
4950
done
4951
 
4952
ac_given_srcdir=$srcdir
4953
ac_given_INSTALL="$INSTALL"
4954
 
4955
trap 'rm -fr `echo "Makefile config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
4956
EOF
4957
cat >> $CONFIG_STATUS <
4958
 
4959
# Protect against being on the right side of a sed subst in config.status.
4960
sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
4961
 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
4962
$ac_vpsub
4963
$extrasub
4964
s%@sim_environment@%$sim_environment%g
4965
s%@sim_alignment@%$sim_alignment%g
4966
s%@sim_assert@%$sim_assert%g
4967
s%@sim_bitsize@%$sim_bitsize%g
4968
s%@sim_endian@%$sim_endian%g
4969
s%@sim_hostendian@%$sim_hostendian%g
4970
s%@sim_float@%$sim_float%g
4971
s%@sim_scache@%$sim_scache%g
4972
s%@sim_default_model@%$sim_default_model%g
4973
s%@sim_hw_cflags@%$sim_hw_cflags%g
4974
s%@sim_hw_objs@%$sim_hw_objs%g
4975
s%@sim_hw@%$sim_hw%g
4976
s%@sim_inline@%$sim_inline%g
4977
s%@sim_packages@%$sim_packages%g
4978
s%@sim_regparm@%$sim_regparm%g
4979
s%@sim_reserved_bits@%$sim_reserved_bits%g
4980
s%@sim_smp@%$sim_smp%g
4981
s%@sim_stdcall@%$sim_stdcall%g
4982
s%@sim_xor_endian@%$sim_xor_endian%g
4983
s%@WARN_CFLAGS@%$WARN_CFLAGS%g
4984
s%@WERROR_CFLAGS@%$WERROR_CFLAGS%g
4985
s%@SHELL@%$SHELL%g
4986
s%@CFLAGS@%$CFLAGS%g
4987
s%@CPPFLAGS@%$CPPFLAGS%g
4988
s%@CXXFLAGS@%$CXXFLAGS%g
4989
s%@FFLAGS@%$FFLAGS%g
4990
s%@DEFS@%$DEFS%g
4991
s%@LDFLAGS@%$LDFLAGS%g
4992
s%@LIBS@%$LIBS%g
4993
s%@exec_prefix@%$exec_prefix%g
4994
s%@prefix@%$prefix%g
4995
s%@program_transform_name@%$program_transform_name%g
4996
s%@bindir@%$bindir%g
4997
s%@sbindir@%$sbindir%g
4998
s%@libexecdir@%$libexecdir%g
4999
s%@datadir@%$datadir%g
5000
s%@sysconfdir@%$sysconfdir%g
5001
s%@sharedstatedir@%$sharedstatedir%g
5002
s%@localstatedir@%$localstatedir%g
5003
s%@libdir@%$libdir%g
5004
s%@includedir@%$includedir%g
5005
s%@oldincludedir@%$oldincludedir%g
5006
s%@infodir@%$infodir%g
5007
s%@mandir@%$mandir%g
5008
s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
5009
s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
5010
s%@INSTALL_DATA@%$INSTALL_DATA%g
5011
s%@CC@%$CC%g
5012
s%@SET_MAKE@%$SET_MAKE%g
5013
s%@RANLIB@%$RANLIB%g
5014
s%@CPP@%$CPP%g
5015
s%@ALLOCA@%$ALLOCA%g
5016
s%@USE_NLS@%$USE_NLS%g
5017
s%@MSGFMT@%$MSGFMT%g
5018
s%@GMSGFMT@%$GMSGFMT%g
5019
s%@XGETTEXT@%$XGETTEXT%g
5020
s%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
5021
s%@CATALOGS@%$CATALOGS%g
5022
s%@CATOBJEXT@%$CATOBJEXT%g
5023
s%@DATADIRNAME@%$DATADIRNAME%g
5024
s%@GMOFILES@%$GMOFILES%g
5025
s%@INSTOBJEXT@%$INSTOBJEXT%g
5026
s%@INTLDEPS@%$INTLDEPS%g
5027
s%@INTLLIBS@%$INTLLIBS%g
5028
s%@INTLOBJS@%$INTLOBJS%g
5029
s%@POFILES@%$POFILES%g
5030
s%@POSUB@%$POSUB%g
5031
s%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g
5032
s%@GT_NO@%$GT_NO%g
5033
s%@GT_YES@%$GT_YES%g
5034
s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
5035
s%@l@%$l%g
5036
s%@host@%$host%g
5037
s%@host_alias@%$host_alias%g
5038
s%@host_cpu@%$host_cpu%g
5039
s%@host_vendor@%$host_vendor%g
5040
s%@host_os@%$host_os%g
5041
s%@target@%$target%g
5042
s%@target_alias@%$target_alias%g
5043
s%@target_cpu@%$target_cpu%g
5044
s%@target_vendor@%$target_vendor%g
5045
s%@target_os@%$target_os%g
5046
s%@build@%$build%g
5047
s%@build_alias@%$build_alias%g
5048
s%@build_cpu@%$build_cpu%g
5049
s%@build_vendor@%$build_vendor%g
5050
s%@build_os@%$build_os%g
5051
s%@LIBOBJS@%$LIBOBJS%g
5052
s%@EXEEXT@%$EXEEXT%g
5053
s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
5054
s%@HDEFINES@%$HDEFINES%g
5055
s%@AR@%$AR%g
5056
s%@sim_cflags@%$sim_cflags%g
5057
s%@sim_warnings@%$sim_warnings%g
5058
s%@sim_line_nr@%$sim_line_nr%g
5059
s%@sim_config@%$sim_config%g
5060
s%@sim_opcode@%$sim_opcode%g
5061
s%@sim_switch@%$sim_switch%g
5062
s%@sim_dup@%$sim_dup%g
5063
s%@sim_decode_mechanism@%$sim_decode_mechanism%g
5064
s%@sim_jump@%$sim_jump%g
5065
s%@sim_filter@%$sim_filter%g
5066
s%@sim_icache@%$sim_icache%g
5067
s%@sim_hw_src@%$sim_hw_src%g
5068
s%@sim_hw_obj@%$sim_hw_obj%g
5069
s%@sim_pk_src@%$sim_pk_src%g
5070
s%@sim_pk_obj@%$sim_pk_obj%g
5071
s%@sim_bswap@%$sim_bswap%g
5072
s%@sim_igen_smp@%$sim_igen_smp%g
5073
s%@sim_hostbitsize@%$sim_hostbitsize%g
5074
s%@sim_env@%$sim_env%g
5075
s%@sim_timebase@%$sim_timebase%g
5076
s%@sim_trace@%$sim_trace%g
5077
s%@sim_reserved@%$sim_reserved%g
5078
s%@sim_monitor@%$sim_monitor%g
5079
s%@sim_model@%$sim_model%g
5080
s%@sim_model_issue@%$sim_model_issue%g
5081
s%@sim_stdio@%$sim_stdio%g
5082
s%@sim_termio@%$sim_termio%g
5083
s%@sim_devzero@%$sim_devzero%g
5084
s%@sim_callback@%$sim_callback%g
5085
s%@sim_targ_vals@%$sim_targ_vals%g
5086
s%@sim_fpu_cflags@%$sim_fpu_cflags%g
5087
s%@sim_fpu@%$sim_fpu%g
5088
 
5089
CEOF
5090
EOF
5091
 
5092
cat >> $CONFIG_STATUS <<\EOF
5093
 
5094
# Split the substitutions into bite-sized pieces for seds with
5095
# small command number limits, like on Digital OSF/1 and HP-UX.
5096
ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
5097
ac_file=1 # Number of current file.
5098
ac_beg=1 # First line for current file.
5099
ac_end=$ac_max_sed_cmds # Line after last line for current file.
5100
ac_more_lines=:
5101
ac_sed_cmds=""
5102
while $ac_more_lines; do
5103
  if test $ac_beg -gt 1; then
5104
    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
5105
  else
5106
    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
5107
  fi
5108
  if test ! -s conftest.s$ac_file; then
5109
    ac_more_lines=false
5110
    rm -f conftest.s$ac_file
5111
  else
5112
    if test -z "$ac_sed_cmds"; then
5113
      ac_sed_cmds="sed -f conftest.s$ac_file"
5114
    else
5115
      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
5116
    fi
5117
    ac_file=`expr $ac_file + 1`
5118
    ac_beg=$ac_end
5119
    ac_end=`expr $ac_end + $ac_max_sed_cmds`
5120
  fi
5121
done
5122
if test -z "$ac_sed_cmds"; then
5123
  ac_sed_cmds=cat
5124
fi
5125
EOF
5126
 
5127
cat >> $CONFIG_STATUS <
5128
 
5129
CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
5130
EOF
5131
cat >> $CONFIG_STATUS <<\EOF
5132
for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
5133
  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
5134
  case "$ac_file" in
5135
  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
5136
       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
5137
  *) ac_file_in="${ac_file}.in" ;;
5138
  esac
5139
 
5140
  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
5141
 
5142
  # Remove last slash and all that follows it.  Not all systems have dirname.
5143
  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
5144
  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5145
    # The file is in a subdirectory.
5146
    test ! -d "$ac_dir" && mkdir "$ac_dir"
5147
    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
5148
    # A "../" for each directory in $ac_dir_suffix.
5149
    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
5150
  else
5151
    ac_dir_suffix= ac_dots=
5152
  fi
5153
 
5154
  case "$ac_given_srcdir" in
5155
  .)  srcdir=.
5156
      if test -z "$ac_dots"; then top_srcdir=.
5157
      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
5158
  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
5159
  *) # Relative path.
5160
    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
5161
    top_srcdir="$ac_dots$ac_given_srcdir" ;;
5162
  esac
5163
 
5164
  case "$ac_given_INSTALL" in
5165
  [/$]*) INSTALL="$ac_given_INSTALL" ;;
5166
  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
5167
  esac
5168
 
5169
  echo creating "$ac_file"
5170
  rm -f "$ac_file"
5171
  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
5172
  case "$ac_file" in
5173
  *Makefile*) ac_comsub="1i\\
5174
# $configure_input" ;;
5175
  *) ac_comsub= ;;
5176
  esac
5177
 
5178
  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
5179
  sed -e "$ac_comsub
5180
s%@configure_input@%$configure_input%g
5181
s%@srcdir@%$srcdir%g
5182
s%@top_srcdir@%$top_srcdir%g
5183
s%@INSTALL@%$INSTALL%g
5184
" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
5185
fi; done
5186
rm -f conftest.s*
5187
 
5188
# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
5189
# NAME is the cpp macro being defined and VALUE is the value it is being given.
5190
#
5191
# ac_d sets the value in "#define NAME VALUE" lines.
5192
ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
5193
ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
5194
ac_dC='\3'
5195
ac_dD='%g'
5196
# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
5197
ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
5198
ac_uB='\([      ]\)%\1#\2define\3'
5199
ac_uC=' '
5200
ac_uD='\4%g'
5201
# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
5202
ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
5203
ac_eB='$%\1#\2define\3'
5204
ac_eC=' '
5205
ac_eD='%g'
5206
 
5207
if test "${CONFIG_HEADERS+set}" != set; then
5208
EOF
5209
cat >> $CONFIG_STATUS <
5210
  CONFIG_HEADERS="config.h:config.in"
5211
EOF
5212
cat >> $CONFIG_STATUS <<\EOF
5213
fi
5214
for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
5215
  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
5216
  case "$ac_file" in
5217
  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
5218
       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
5219
  *) ac_file_in="${ac_file}.in" ;;
5220
  esac
5221
 
5222
  echo creating $ac_file
5223
 
5224
  rm -f conftest.frag conftest.in conftest.out
5225
  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
5226
  cat $ac_file_inputs > conftest.in
5227
 
5228
EOF
5229
 
5230
# Transform confdefs.h into a sed script conftest.vals that substitutes
5231
# the proper values into config.h.in to produce config.h.  And first:
5232
# Protect against being on the right side of a sed subst in config.status.
5233
# Protect against being in an unquoted here document in config.status.
5234
rm -f conftest.vals
5235
cat > conftest.hdr <<\EOF
5236
s/[\\&%]/\\&/g
5237
s%[\\$`]%\\&%g
5238
s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
5239
s%ac_d%ac_u%gp
5240
s%ac_u%ac_e%gp
5241
EOF
5242
sed -n -f conftest.hdr confdefs.h > conftest.vals
5243
rm -f conftest.hdr
5244
 
5245
# This sed command replaces #undef with comments.  This is necessary, for
5246
# example, in the case of _POSIX_SOURCE, which is predefined and required
5247
# on some systems where configure will not decide to define it.
5248
cat >> conftest.vals <<\EOF
5249
s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
5250
EOF
5251
 
5252
# Break up conftest.vals because some shells have a limit on
5253
# the size of here documents, and old seds have small limits too.
5254
 
5255
rm -f conftest.tail
5256
while :
5257
do
5258
  ac_lines=`grep -c . conftest.vals`
5259
  # grep -c gives empty output for an empty file on some AIX systems.
5260
  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
5261
  # Write a limited-size here document to conftest.frag.
5262
  echo '  cat > conftest.frag <> $CONFIG_STATUS
5263
  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
5264
  echo 'CEOF
5265
  sed -f conftest.frag conftest.in > conftest.out
5266
  rm -f conftest.in
5267
  mv conftest.out conftest.in
5268
' >> $CONFIG_STATUS
5269
  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
5270
  rm -f conftest.vals
5271
  mv conftest.tail conftest.vals
5272
done
5273
rm -f conftest.vals
5274
 
5275
cat >> $CONFIG_STATUS <<\EOF
5276
  rm -f conftest.frag conftest.h
5277
  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
5278
  cat conftest.in >> conftest.h
5279
  rm -f conftest.in
5280
  if cmp -s $ac_file conftest.h 2>/dev/null; then
5281
    echo "$ac_file is unchanged"
5282
    rm -f conftest.h
5283
  else
5284
    # Remove last slash and all that follows it.  Not all systems have dirname.
5285
      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
5286
      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
5287
      # The file is in a subdirectory.
5288
      test ! -d "$ac_dir" && mkdir "$ac_dir"
5289
    fi
5290
    rm -f $ac_file
5291
    mv conftest.h $ac_file
5292
  fi
5293
fi; done
5294
 
5295
EOF
5296
cat >> $CONFIG_STATUS <
5297
 
5298
EOF
5299
cat >> $CONFIG_STATUS <<\EOF
5300
case x$CONFIG_HEADERS in xconfig.h:config.in) echo > stamp-h ;; esac
5301
exit 0
5302
EOF
5303
chmod +x $CONFIG_STATUS
5304
rm -fr confdefs* $ac_clean_files
5305
test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
5306
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.