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

Subversion Repositories or1k

[/] [or1k/] [trunk/] [gdb-5.0/] [sim/] [ppc/] [configure] - Blame information for rev 1765

Details | Compare with Previous | View Log

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

powered by: WebSVN 2.1.0

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