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