xref: /openbsd-src/gnu/usr.bin/binutils/intl/configure (revision c074d1c999f3e07019cd5e9a2f190b057ef3b935)
1f7cc78ecSespie#! /bin/sh
2f7cc78ecSespie
3f7cc78ecSespie# Guess values for system-dependent variables and create Makefiles.
4f7cc78ecSespie# Generated automatically using autoconf version 2.12.1
5f7cc78ecSespie# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6f7cc78ecSespie#
7f7cc78ecSespie# This configure script is free software; the Free Software Foundation
8f7cc78ecSespie# gives unlimited permission to copy, distribute and modify it.
9f7cc78ecSespie
10f7cc78ecSespie# Defaults:
11f7cc78ecSespieac_help=
12f7cc78ecSespieac_default_prefix=/usr/local
13f7cc78ecSespie# Any additions from configure.in:
14f7cc78ecSespieac_help="$ac_help
15f7cc78ecSespie  --disable-nls           do not use Native Language Support"
16f7cc78ecSespieac_help="$ac_help
17f7cc78ecSespie  --with-included-gettext use the GNU gettext library included here"
18f7cc78ecSespie
19f7cc78ecSespie# Initialize some variables set by options.
20f7cc78ecSespie# The variables have the same names as the options, with
21f7cc78ecSespie# dashes changed to underlines.
22f7cc78ecSespiebuild=NONE
23f7cc78ecSespiecache_file=./config.cache
24f7cc78ecSespieexec_prefix=NONE
25f7cc78ecSespiehost=NONE
26f7cc78ecSespieno_create=
27f7cc78ecSespienonopt=NONE
28f7cc78ecSespieno_recursion=
29f7cc78ecSespieprefix=NONE
30f7cc78ecSespieprogram_prefix=NONE
31f7cc78ecSespieprogram_suffix=NONE
32f7cc78ecSespieprogram_transform_name=s,x,x,
33f7cc78ecSespiesilent=
34f7cc78ecSespiesite=
35f7cc78ecSespiesrcdir=
36f7cc78ecSespietarget=NONE
37f7cc78ecSespieverbose=
38f7cc78ecSespiex_includes=NONE
39f7cc78ecSespiex_libraries=NONE
40f7cc78ecSespiebindir='${exec_prefix}/bin'
41f7cc78ecSespiesbindir='${exec_prefix}/sbin'
42f7cc78ecSespielibexecdir='${exec_prefix}/libexec'
43f7cc78ecSespiedatadir='${prefix}/share'
44f7cc78ecSespiesysconfdir='${prefix}/etc'
45f7cc78ecSespiesharedstatedir='${prefix}/com'
46f7cc78ecSespielocalstatedir='${prefix}/var'
47f7cc78ecSespielibdir='${exec_prefix}/lib'
48f7cc78ecSespieincludedir='${prefix}/include'
49f7cc78ecSespieoldincludedir='/usr/include'
50f7cc78ecSespieinfodir='${prefix}/info'
51f7cc78ecSespiemandir='${prefix}/man'
52f7cc78ecSespie
53f7cc78ecSespie# Initialize some other variables.
54f7cc78ecSespiesubdirs=
55f7cc78ecSespieMFLAGS= MAKEFLAGS=
56f7cc78ecSespieSHELL=${CONFIG_SHELL-/bin/sh}
57f7cc78ecSespie# Maximum number of lines to put in a shell here document.
58f7cc78ecSespieac_max_here_lines=12
59f7cc78ecSespie
60f7cc78ecSespieac_prev=
61f7cc78ecSespiefor ac_option
62f7cc78ecSespiedo
63f7cc78ecSespie
64f7cc78ecSespie  # If the previous option needs an argument, assign it.
65f7cc78ecSespie  if test -n "$ac_prev"; then
66f7cc78ecSespie    eval "$ac_prev=\$ac_option"
67f7cc78ecSespie    ac_prev=
68f7cc78ecSespie    continue
69f7cc78ecSespie  fi
70f7cc78ecSespie
71f7cc78ecSespie  case "$ac_option" in
72f7cc78ecSespie  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
73f7cc78ecSespie  *) ac_optarg= ;;
74f7cc78ecSespie  esac
75f7cc78ecSespie
76f7cc78ecSespie  # Accept the important Cygnus configure options, so we can diagnose typos.
77f7cc78ecSespie
78f7cc78ecSespie  case "$ac_option" in
79f7cc78ecSespie
80f7cc78ecSespie  -bindir | --bindir | --bindi | --bind | --bin | --bi)
81f7cc78ecSespie    ac_prev=bindir ;;
82f7cc78ecSespie  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
83f7cc78ecSespie    bindir="$ac_optarg" ;;
84f7cc78ecSespie
85f7cc78ecSespie  -build | --build | --buil | --bui | --bu)
86f7cc78ecSespie    ac_prev=build ;;
87f7cc78ecSespie  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
88f7cc78ecSespie    build="$ac_optarg" ;;
89f7cc78ecSespie
90f7cc78ecSespie  -cache-file | --cache-file | --cache-fil | --cache-fi \
91f7cc78ecSespie  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
92f7cc78ecSespie    ac_prev=cache_file ;;
93f7cc78ecSespie  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
94f7cc78ecSespie  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
95f7cc78ecSespie    cache_file="$ac_optarg" ;;
96f7cc78ecSespie
97f7cc78ecSespie  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
98f7cc78ecSespie    ac_prev=datadir ;;
99f7cc78ecSespie  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
100f7cc78ecSespie  | --da=*)
101f7cc78ecSespie    datadir="$ac_optarg" ;;
102f7cc78ecSespie
103f7cc78ecSespie  -disable-* | --disable-*)
104f7cc78ecSespie    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
105f7cc78ecSespie    # Reject names that are not valid shell variable names.
106f7cc78ecSespie    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
107f7cc78ecSespie      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
108f7cc78ecSespie    fi
109f7cc78ecSespie    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
110f7cc78ecSespie    eval "enable_${ac_feature}=no" ;;
111f7cc78ecSespie
112f7cc78ecSespie  -enable-* | --enable-*)
113f7cc78ecSespie    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
114f7cc78ecSespie    # Reject names that are not valid shell variable names.
115f7cc78ecSespie    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
116f7cc78ecSespie      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
117f7cc78ecSespie    fi
118f7cc78ecSespie    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
119f7cc78ecSespie    case "$ac_option" in
120f7cc78ecSespie      *=*) ;;
121f7cc78ecSespie      *) ac_optarg=yes ;;
122f7cc78ecSespie    esac
123f7cc78ecSespie    eval "enable_${ac_feature}='$ac_optarg'" ;;
124f7cc78ecSespie
125f7cc78ecSespie  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
126f7cc78ecSespie  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
127f7cc78ecSespie  | --exec | --exe | --ex)
128f7cc78ecSespie    ac_prev=exec_prefix ;;
129f7cc78ecSespie  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
130f7cc78ecSespie  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
131f7cc78ecSespie  | --exec=* | --exe=* | --ex=*)
132f7cc78ecSespie    exec_prefix="$ac_optarg" ;;
133f7cc78ecSespie
134f7cc78ecSespie  -gas | --gas | --ga | --g)
135f7cc78ecSespie    # Obsolete; use --with-gas.
136f7cc78ecSespie    with_gas=yes ;;
137f7cc78ecSespie
138f7cc78ecSespie  -help | --help | --hel | --he)
139f7cc78ecSespie    # Omit some internal or obsolete options to make the list less imposing.
140f7cc78ecSespie    # This message is too long to be a string in the A/UX 3.1 sh.
141f7cc78ecSespie    cat << EOF
142f7cc78ecSespieUsage: configure [options] [host]
143f7cc78ecSespieOptions: [defaults in brackets after descriptions]
144f7cc78ecSespieConfiguration:
145f7cc78ecSespie  --cache-file=FILE       cache test results in FILE
146f7cc78ecSespie  --help                  print this message
147f7cc78ecSespie  --no-create             do not create output files
148f7cc78ecSespie  --quiet, --silent       do not print \`checking...' messages
149f7cc78ecSespie  --version               print the version of autoconf that created configure
150f7cc78ecSespieDirectory and file names:
151f7cc78ecSespie  --prefix=PREFIX         install architecture-independent files in PREFIX
152f7cc78ecSespie                          [$ac_default_prefix]
153f7cc78ecSespie  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
154f7cc78ecSespie                          [same as prefix]
155f7cc78ecSespie  --bindir=DIR            user executables in DIR [EPREFIX/bin]
156f7cc78ecSespie  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
157f7cc78ecSespie  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
158f7cc78ecSespie  --datadir=DIR           read-only architecture-independent data in DIR
159f7cc78ecSespie                          [PREFIX/share]
160f7cc78ecSespie  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
161f7cc78ecSespie  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
162f7cc78ecSespie                          [PREFIX/com]
163f7cc78ecSespie  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
164f7cc78ecSespie  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
165f7cc78ecSespie  --includedir=DIR        C header files in DIR [PREFIX/include]
166f7cc78ecSespie  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
167f7cc78ecSespie  --infodir=DIR           info documentation in DIR [PREFIX/info]
168f7cc78ecSespie  --mandir=DIR            man documentation in DIR [PREFIX/man]
169f7cc78ecSespie  --srcdir=DIR            find the sources in DIR [configure dir or ..]
170f7cc78ecSespie  --program-prefix=PREFIX prepend PREFIX to installed program names
171f7cc78ecSespie  --program-suffix=SUFFIX append SUFFIX to installed program names
172f7cc78ecSespie  --program-transform-name=PROGRAM
173f7cc78ecSespie                          run sed PROGRAM on installed program names
174f7cc78ecSespieEOF
175f7cc78ecSespie    cat << EOF
176f7cc78ecSespieHost type:
177f7cc78ecSespie  --build=BUILD           configure for building on BUILD [BUILD=HOST]
178f7cc78ecSespie  --host=HOST             configure for HOST [guessed]
179f7cc78ecSespie  --target=TARGET         configure for TARGET [TARGET=HOST]
180f7cc78ecSespieFeatures and packages:
181f7cc78ecSespie  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
182f7cc78ecSespie  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
183f7cc78ecSespie  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
184f7cc78ecSespie  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
185f7cc78ecSespie  --x-includes=DIR        X include files are in DIR
186f7cc78ecSespie  --x-libraries=DIR       X library files are in DIR
187f7cc78ecSespieEOF
188f7cc78ecSespie    if test -n "$ac_help"; then
189f7cc78ecSespie      echo "--enable and --with options recognized:$ac_help"
190f7cc78ecSespie    fi
191f7cc78ecSespie    exit 0 ;;
192f7cc78ecSespie
193f7cc78ecSespie  -host | --host | --hos | --ho)
194f7cc78ecSespie    ac_prev=host ;;
195f7cc78ecSespie  -host=* | --host=* | --hos=* | --ho=*)
196f7cc78ecSespie    host="$ac_optarg" ;;
197f7cc78ecSespie
198f7cc78ecSespie  -includedir | --includedir | --includedi | --included | --include \
199f7cc78ecSespie  | --includ | --inclu | --incl | --inc)
200f7cc78ecSespie    ac_prev=includedir ;;
201f7cc78ecSespie  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
202f7cc78ecSespie  | --includ=* | --inclu=* | --incl=* | --inc=*)
203f7cc78ecSespie    includedir="$ac_optarg" ;;
204f7cc78ecSespie
205f7cc78ecSespie  -infodir | --infodir | --infodi | --infod | --info | --inf)
206f7cc78ecSespie    ac_prev=infodir ;;
207f7cc78ecSespie  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
208f7cc78ecSespie    infodir="$ac_optarg" ;;
209f7cc78ecSespie
210f7cc78ecSespie  -libdir | --libdir | --libdi | --libd)
211f7cc78ecSespie    ac_prev=libdir ;;
212f7cc78ecSespie  -libdir=* | --libdir=* | --libdi=* | --libd=*)
213f7cc78ecSespie    libdir="$ac_optarg" ;;
214f7cc78ecSespie
215f7cc78ecSespie  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
216f7cc78ecSespie  | --libexe | --libex | --libe)
217f7cc78ecSespie    ac_prev=libexecdir ;;
218f7cc78ecSespie  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
219f7cc78ecSespie  | --libexe=* | --libex=* | --libe=*)
220f7cc78ecSespie    libexecdir="$ac_optarg" ;;
221f7cc78ecSespie
222f7cc78ecSespie  -localstatedir | --localstatedir | --localstatedi | --localstated \
223f7cc78ecSespie  | --localstate | --localstat | --localsta | --localst \
224f7cc78ecSespie  | --locals | --local | --loca | --loc | --lo)
225f7cc78ecSespie    ac_prev=localstatedir ;;
226f7cc78ecSespie  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
227f7cc78ecSespie  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
228f7cc78ecSespie  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
229f7cc78ecSespie    localstatedir="$ac_optarg" ;;
230f7cc78ecSespie
231f7cc78ecSespie  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
232f7cc78ecSespie    ac_prev=mandir ;;
233f7cc78ecSespie  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
234f7cc78ecSespie    mandir="$ac_optarg" ;;
235f7cc78ecSespie
236f7cc78ecSespie  -nfp | --nfp | --nf)
237f7cc78ecSespie    # Obsolete; use --without-fp.
238f7cc78ecSespie    with_fp=no ;;
239f7cc78ecSespie
240f7cc78ecSespie  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
241f7cc78ecSespie  | --no-cr | --no-c)
242f7cc78ecSespie    no_create=yes ;;
243f7cc78ecSespie
244f7cc78ecSespie  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
245f7cc78ecSespie  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
246f7cc78ecSespie    no_recursion=yes ;;
247f7cc78ecSespie
248f7cc78ecSespie  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
249f7cc78ecSespie  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
250f7cc78ecSespie  | --oldin | --oldi | --old | --ol | --o)
251f7cc78ecSespie    ac_prev=oldincludedir ;;
252f7cc78ecSespie  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
253f7cc78ecSespie  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
254f7cc78ecSespie  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
255f7cc78ecSespie    oldincludedir="$ac_optarg" ;;
256f7cc78ecSespie
257f7cc78ecSespie  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
258f7cc78ecSespie    ac_prev=prefix ;;
259f7cc78ecSespie  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
260f7cc78ecSespie    prefix="$ac_optarg" ;;
261f7cc78ecSespie
262f7cc78ecSespie  -program-prefix | --program-prefix | --program-prefi | --program-pref \
263f7cc78ecSespie  | --program-pre | --program-pr | --program-p)
264f7cc78ecSespie    ac_prev=program_prefix ;;
265f7cc78ecSespie  -program-prefix=* | --program-prefix=* | --program-prefi=* \
266f7cc78ecSespie  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
267f7cc78ecSespie    program_prefix="$ac_optarg" ;;
268f7cc78ecSespie
269f7cc78ecSespie  -program-suffix | --program-suffix | --program-suffi | --program-suff \
270f7cc78ecSespie  | --program-suf | --program-su | --program-s)
271f7cc78ecSespie    ac_prev=program_suffix ;;
272f7cc78ecSespie  -program-suffix=* | --program-suffix=* | --program-suffi=* \
273f7cc78ecSespie  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
274f7cc78ecSespie    program_suffix="$ac_optarg" ;;
275f7cc78ecSespie
276f7cc78ecSespie  -program-transform-name | --program-transform-name \
277f7cc78ecSespie  | --program-transform-nam | --program-transform-na \
278f7cc78ecSespie  | --program-transform-n | --program-transform- \
279f7cc78ecSespie  | --program-transform | --program-transfor \
280f7cc78ecSespie  | --program-transfo | --program-transf \
281f7cc78ecSespie  | --program-trans | --program-tran \
282f7cc78ecSespie  | --progr-tra | --program-tr | --program-t)
283f7cc78ecSespie    ac_prev=program_transform_name ;;
284f7cc78ecSespie  -program-transform-name=* | --program-transform-name=* \
285f7cc78ecSespie  | --program-transform-nam=* | --program-transform-na=* \
286f7cc78ecSespie  | --program-transform-n=* | --program-transform-=* \
287f7cc78ecSespie  | --program-transform=* | --program-transfor=* \
288f7cc78ecSespie  | --program-transfo=* | --program-transf=* \
289f7cc78ecSespie  | --program-trans=* | --program-tran=* \
290f7cc78ecSespie  | --progr-tra=* | --program-tr=* | --program-t=*)
291f7cc78ecSespie    program_transform_name="$ac_optarg" ;;
292f7cc78ecSespie
293f7cc78ecSespie  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
294f7cc78ecSespie  | -silent | --silent | --silen | --sile | --sil)
295f7cc78ecSespie    silent=yes ;;
296f7cc78ecSespie
297f7cc78ecSespie  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
298f7cc78ecSespie    ac_prev=sbindir ;;
299f7cc78ecSespie  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
300f7cc78ecSespie  | --sbi=* | --sb=*)
301f7cc78ecSespie    sbindir="$ac_optarg" ;;
302f7cc78ecSespie
303f7cc78ecSespie  -sharedstatedir | --sharedstatedir | --sharedstatedi \
304f7cc78ecSespie  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
305f7cc78ecSespie  | --sharedst | --shareds | --shared | --share | --shar \
306f7cc78ecSespie  | --sha | --sh)
307f7cc78ecSespie    ac_prev=sharedstatedir ;;
308f7cc78ecSespie  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
309f7cc78ecSespie  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
310f7cc78ecSespie  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
311f7cc78ecSespie  | --sha=* | --sh=*)
312f7cc78ecSespie    sharedstatedir="$ac_optarg" ;;
313f7cc78ecSespie
314f7cc78ecSespie  -site | --site | --sit)
315f7cc78ecSespie    ac_prev=site ;;
316f7cc78ecSespie  -site=* | --site=* | --sit=*)
317f7cc78ecSespie    site="$ac_optarg" ;;
318f7cc78ecSespie
319f7cc78ecSespie  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
320f7cc78ecSespie    ac_prev=srcdir ;;
321f7cc78ecSespie  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
322f7cc78ecSespie    srcdir="$ac_optarg" ;;
323f7cc78ecSespie
324f7cc78ecSespie  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
325f7cc78ecSespie  | --syscon | --sysco | --sysc | --sys | --sy)
326f7cc78ecSespie    ac_prev=sysconfdir ;;
327f7cc78ecSespie  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
328f7cc78ecSespie  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
329f7cc78ecSespie    sysconfdir="$ac_optarg" ;;
330f7cc78ecSespie
331f7cc78ecSespie  -target | --target | --targe | --targ | --tar | --ta | --t)
332f7cc78ecSespie    ac_prev=target ;;
333f7cc78ecSespie  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
334f7cc78ecSespie    target="$ac_optarg" ;;
335f7cc78ecSespie
336f7cc78ecSespie  -v | -verbose | --verbose | --verbos | --verbo | --verb)
337f7cc78ecSespie    verbose=yes ;;
338f7cc78ecSespie
339f7cc78ecSespie  -version | --version | --versio | --versi | --vers)
340f7cc78ecSespie    echo "configure generated by autoconf version 2.12.1"
341f7cc78ecSespie    exit 0 ;;
342f7cc78ecSespie
343f7cc78ecSespie  -with-* | --with-*)
344f7cc78ecSespie    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
345f7cc78ecSespie    # Reject names that are not valid shell variable names.
346f7cc78ecSespie    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
347f7cc78ecSespie      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
348f7cc78ecSespie    fi
349f7cc78ecSespie    ac_package=`echo $ac_package| sed 's/-/_/g'`
350f7cc78ecSespie    case "$ac_option" in
351f7cc78ecSespie      *=*) ;;
352f7cc78ecSespie      *) ac_optarg=yes ;;
353f7cc78ecSespie    esac
354f7cc78ecSespie    eval "with_${ac_package}='$ac_optarg'" ;;
355f7cc78ecSespie
356f7cc78ecSespie  -without-* | --without-*)
357f7cc78ecSespie    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
358f7cc78ecSespie    # Reject names that are not valid shell variable names.
359f7cc78ecSespie    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
360f7cc78ecSespie      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
361f7cc78ecSespie    fi
362f7cc78ecSespie    ac_package=`echo $ac_package| sed 's/-/_/g'`
363f7cc78ecSespie    eval "with_${ac_package}=no" ;;
364f7cc78ecSespie
365f7cc78ecSespie  --x)
366f7cc78ecSespie    # Obsolete; use --with-x.
367f7cc78ecSespie    with_x=yes ;;
368f7cc78ecSespie
369f7cc78ecSespie  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
370f7cc78ecSespie  | --x-incl | --x-inc | --x-in | --x-i)
371f7cc78ecSespie    ac_prev=x_includes ;;
372f7cc78ecSespie  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
373f7cc78ecSespie  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
374f7cc78ecSespie    x_includes="$ac_optarg" ;;
375f7cc78ecSespie
376f7cc78ecSespie  -x-libraries | --x-libraries | --x-librarie | --x-librari \
377f7cc78ecSespie  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
378f7cc78ecSespie    ac_prev=x_libraries ;;
379f7cc78ecSespie  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
380f7cc78ecSespie  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
381f7cc78ecSespie    x_libraries="$ac_optarg" ;;
382f7cc78ecSespie
383f7cc78ecSespie  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
384f7cc78ecSespie    ;;
385f7cc78ecSespie
386f7cc78ecSespie  *)
387f7cc78ecSespie    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
388f7cc78ecSespie      echo "configure: warning: $ac_option: invalid host type" 1>&2
389f7cc78ecSespie    fi
390f7cc78ecSespie    if test "x$nonopt" != xNONE; then
391f7cc78ecSespie      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
392f7cc78ecSespie    fi
393f7cc78ecSespie    nonopt="$ac_option"
394f7cc78ecSespie    ;;
395f7cc78ecSespie
396f7cc78ecSespie  esac
397f7cc78ecSespiedone
398f7cc78ecSespie
399f7cc78ecSespieif test -n "$ac_prev"; then
400f7cc78ecSespie  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
401f7cc78ecSespiefi
402f7cc78ecSespie
403f7cc78ecSespietrap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
404f7cc78ecSespie
405f7cc78ecSespie# File descriptor usage:
406f7cc78ecSespie# 0 standard input
407f7cc78ecSespie# 1 file creation
408f7cc78ecSespie# 2 errors and warnings
409f7cc78ecSespie# 3 some systems may open it to /dev/tty
410f7cc78ecSespie# 4 used on the Kubota Titan
411f7cc78ecSespie# 6 checking for... messages and results
412f7cc78ecSespie# 5 compiler messages saved in config.log
413f7cc78ecSespieif test "$silent" = yes; then
414f7cc78ecSespie  exec 6>/dev/null
415f7cc78ecSespieelse
416f7cc78ecSespie  exec 6>&1
417f7cc78ecSespiefi
418f7cc78ecSespieexec 5>./config.log
419f7cc78ecSespie
420f7cc78ecSespieecho "\
421f7cc78ecSespieThis file contains any messages produced by compilers while
422f7cc78ecSespierunning configure, to aid debugging if configure makes a mistake.
423f7cc78ecSespie" 1>&5
424f7cc78ecSespie
425f7cc78ecSespie# Strip out --no-create and --no-recursion so they do not pile up.
426f7cc78ecSespie# Also quote any args containing shell metacharacters.
427f7cc78ecSespieac_configure_args=
428f7cc78ecSespiefor ac_arg
429f7cc78ecSespiedo
430f7cc78ecSespie  case "$ac_arg" in
431f7cc78ecSespie  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
432f7cc78ecSespie  | --no-cr | --no-c) ;;
433f7cc78ecSespie  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
434f7cc78ecSespie  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
435f7cc78ecSespie  *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
436f7cc78ecSespie  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
437f7cc78ecSespie  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
438f7cc78ecSespie  esac
439f7cc78ecSespiedone
440f7cc78ecSespie
441f7cc78ecSespie# NLS nuisances.
442f7cc78ecSespie# Only set these to C if already set.  These must not be set unconditionally
443f7cc78ecSespie# because not all systems understand e.g. LANG=C (notably SCO).
444f7cc78ecSespie# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
445f7cc78ecSespie# Non-C LC_CTYPE values break the ctype check.
446f7cc78ecSespieif test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
447f7cc78ecSespieif test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
448f7cc78ecSespieif test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
449f7cc78ecSespieif test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
450f7cc78ecSespie
451f7cc78ecSespie# confdefs.h avoids OS command line length limits that DEFS can exceed.
452f7cc78ecSespierm -rf conftest* confdefs.h
453f7cc78ecSespie# AIX cpp loses on an empty file, so make sure it contains at least a newline.
454f7cc78ecSespieecho > confdefs.h
455f7cc78ecSespie
456f7cc78ecSespie# A filename unique to this package, relative to the directory that
457f7cc78ecSespie# configure is in, which we can look for to find out if srcdir is correct.
458f7cc78ecSespieac_unique_file=dgettext.c
459f7cc78ecSespie
460f7cc78ecSespie# Find the source files, if location was not specified.
461f7cc78ecSespieif test -z "$srcdir"; then
462f7cc78ecSespie  ac_srcdir_defaulted=yes
463f7cc78ecSespie  # Try the directory containing this script, then its parent.
464f7cc78ecSespie  ac_prog=$0
465f7cc78ecSespie  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
466f7cc78ecSespie  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
467f7cc78ecSespie  srcdir=$ac_confdir
468f7cc78ecSespie  if test ! -r $srcdir/$ac_unique_file; then
469f7cc78ecSespie    srcdir=..
470f7cc78ecSespie  fi
471f7cc78ecSespieelse
472f7cc78ecSespie  ac_srcdir_defaulted=no
473f7cc78ecSespiefi
474f7cc78ecSespieif test ! -r $srcdir/$ac_unique_file; then
475f7cc78ecSespie  if test "$ac_srcdir_defaulted" = yes; then
476f7cc78ecSespie    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
477f7cc78ecSespie  else
478f7cc78ecSespie    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
479f7cc78ecSespie  fi
480f7cc78ecSespiefi
481f7cc78ecSespiesrcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
482f7cc78ecSespie
483f7cc78ecSespie# Prefer explicitly selected file to automatically selected ones.
484f7cc78ecSespieif test -z "$CONFIG_SITE"; then
485f7cc78ecSespie  if test "x$prefix" != xNONE; then
486f7cc78ecSespie    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
487f7cc78ecSespie  else
488f7cc78ecSespie    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
489f7cc78ecSespie  fi
490f7cc78ecSespiefi
491f7cc78ecSespiefor ac_site_file in $CONFIG_SITE; do
492f7cc78ecSespie  if test -r "$ac_site_file"; then
493f7cc78ecSespie    echo "loading site script $ac_site_file"
494f7cc78ecSespie    . "$ac_site_file"
495f7cc78ecSespie  fi
496f7cc78ecSespiedone
497f7cc78ecSespie
498f7cc78ecSespieif test -r "$cache_file"; then
499f7cc78ecSespie  echo "loading cache $cache_file"
500f7cc78ecSespie  . $cache_file
501f7cc78ecSespieelse
502f7cc78ecSespie  echo "creating cache $cache_file"
503f7cc78ecSespie  > $cache_file
504f7cc78ecSespiefi
505f7cc78ecSespie
506f7cc78ecSespieac_ext=c
507f7cc78ecSespie# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
508f7cc78ecSespieac_cpp='$CPP $CPPFLAGS'
509f7cc78ecSespieac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
510f7cc78ecSespieac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
511f7cc78ecSespiecross_compiling=$ac_cv_prog_cc_cross
512f7cc78ecSespie
513f7cc78ecSespieif (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
514f7cc78ecSespie  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
515f7cc78ecSespie  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
516f7cc78ecSespie    ac_n= ac_c='
517f7cc78ecSespie' ac_t='	'
518f7cc78ecSespie  else
519f7cc78ecSespie    ac_n=-n ac_c= ac_t=
520f7cc78ecSespie  fi
521f7cc78ecSespieelse
522f7cc78ecSespie  ac_n= ac_c='\c' ac_t=
523f7cc78ecSespiefi
524f7cc78ecSespie
525f7cc78ecSespie
526f7cc78ecSespie
527f7cc78ecSespie
528f7cc78ecSespie
529f7cc78ecSespie
530f7cc78ecSespieac_aux_dir=
531*c074d1c9Sdrahnfor ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
532f7cc78ecSespie  if test -f $ac_dir/install-sh; then
533f7cc78ecSespie    ac_aux_dir=$ac_dir
534f7cc78ecSespie    ac_install_sh="$ac_aux_dir/install-sh -c"
535f7cc78ecSespie    break
536f7cc78ecSespie  elif test -f $ac_dir/install.sh; then
537f7cc78ecSespie    ac_aux_dir=$ac_dir
538f7cc78ecSespie    ac_install_sh="$ac_aux_dir/install.sh -c"
539f7cc78ecSespie    break
540f7cc78ecSespie  fi
541f7cc78ecSespiedone
542f7cc78ecSespieif test -z "$ac_aux_dir"; then
543f7cc78ecSespie  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
544f7cc78ecSespiefi
545f7cc78ecSespieac_config_guess=$ac_aux_dir/config.guess
546f7cc78ecSespieac_config_sub=$ac_aux_dir/config.sub
547f7cc78ecSespieac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
548f7cc78ecSespie
549f7cc78ecSespie# Find a good install program.  We prefer a C program (faster),
550f7cc78ecSespie# so one script is as good as another.  But avoid the broken or
551f7cc78ecSespie# incompatible versions:
552f7cc78ecSespie# SysV /etc/install, /usr/sbin/install
553f7cc78ecSespie# SunOS /usr/etc/install
554f7cc78ecSespie# IRIX /sbin/install
555f7cc78ecSespie# AIX /bin/install
556f7cc78ecSespie# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
557f7cc78ecSespie# AFS /usr/afsws/bin/install, which mishandles nonexistent args
558f7cc78ecSespie# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
559f7cc78ecSespie# ./install, which can be erroneously created by make from ./install.sh.
560f7cc78ecSespieecho $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
561f7cc78ecSespieecho "configure:562: checking for a BSD compatible install" >&5
562f7cc78ecSespieif test -z "$INSTALL"; then
563f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
564f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
565f7cc78ecSespieelse
566f7cc78ecSespie    IFS="${IFS= 	}"; ac_save_IFS="$IFS"; IFS="${IFS}:"
567f7cc78ecSespie  for ac_dir in $PATH; do
568f7cc78ecSespie    # Account for people who put trailing slashes in PATH elements.
569f7cc78ecSespie    case "$ac_dir/" in
570f7cc78ecSespie    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
571f7cc78ecSespie    *)
572f7cc78ecSespie      # OSF1 and SCO ODT 3.0 have their own names for install.
573f7cc78ecSespie      # Don't use installbsd from OSF since it installs stuff as root
574f7cc78ecSespie      # by default.
575f7cc78ecSespie      for ac_prog in ginstall scoinst install; do
576f7cc78ecSespie        if test -f $ac_dir/$ac_prog; then
577f7cc78ecSespie	  if test $ac_prog = install &&
578f7cc78ecSespie            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
579f7cc78ecSespie	    # AIX install.  It has an incompatible calling convention.
580f7cc78ecSespie	    :
581f7cc78ecSespie	  else
582f7cc78ecSespie	    ac_cv_path_install="$ac_dir/$ac_prog -c"
583f7cc78ecSespie	    break 2
584f7cc78ecSespie	  fi
585f7cc78ecSespie	fi
586f7cc78ecSespie      done
587f7cc78ecSespie      ;;
588f7cc78ecSespie    esac
589f7cc78ecSespie  done
590f7cc78ecSespie  IFS="$ac_save_IFS"
591f7cc78ecSespie
592f7cc78ecSespiefi
593f7cc78ecSespie  if test "${ac_cv_path_install+set}" = set; then
594f7cc78ecSespie    INSTALL="$ac_cv_path_install"
595f7cc78ecSespie  else
596f7cc78ecSespie    # As a last resort, use the slow shell script.  We don't cache a
597f7cc78ecSespie    # path for INSTALL within a source directory, because that will
598f7cc78ecSespie    # break other packages using the cache if that directory is
599f7cc78ecSespie    # removed, or if the path is relative.
600f7cc78ecSespie    INSTALL="$ac_install_sh"
601f7cc78ecSespie  fi
602f7cc78ecSespiefi
603f7cc78ecSespieecho "$ac_t""$INSTALL" 1>&6
604f7cc78ecSespie
605f7cc78ecSespie# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
606f7cc78ecSespie# It thinks the first close brace ends the variable substitution.
607f7cc78ecSespietest -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
608f7cc78ecSespie
609f7cc78ecSespietest -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
610f7cc78ecSespie
611f7cc78ecSespie
612f7cc78ecSespietest -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
613f7cc78ecSespie
614f7cc78ecSespieecho $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
615f7cc78ecSespieecho "configure:616: checking how to run the C preprocessor" >&5
616f7cc78ecSespie# On Suns, sometimes $CPP names a directory.
617f7cc78ecSespieif test -n "$CPP" && test -d "$CPP"; then
618f7cc78ecSespie  CPP=
619f7cc78ecSespiefi
620f7cc78ecSespieif test -z "$CPP"; then
621f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
622f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
623f7cc78ecSespieelse
624f7cc78ecSespie    # This must be in double quotes, not single quotes, because CPP may get
625f7cc78ecSespie  # substituted into the Makefile and "${CC-cc}" will confuse make.
626f7cc78ecSespie  CPP="${CC-cc} -E"
627f7cc78ecSespie  # On the NeXT, cc -E runs the code through the compiler's parser,
628f7cc78ecSespie  # not just through cpp.
629f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
630f7cc78ecSespie#line 631 "configure"
631f7cc78ecSespie#include "confdefs.h"
632f7cc78ecSespie#include <assert.h>
633f7cc78ecSespieSyntax Error
634f7cc78ecSespieEOF
635f7cc78ecSespieac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
636f7cc78ecSespie{ (eval echo configure:637: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
637f7cc78ecSespieac_err=`grep -v '^ *+' conftest.out`
638f7cc78ecSespieif test -z "$ac_err"; then
639f7cc78ecSespie  :
640f7cc78ecSespieelse
641f7cc78ecSespie  echo "$ac_err" >&5
642f7cc78ecSespie  echo "configure: failed program was:" >&5
643f7cc78ecSespie  cat conftest.$ac_ext >&5
644f7cc78ecSespie  rm -rf conftest*
645f7cc78ecSespie  CPP="${CC-cc} -E -traditional-cpp"
646f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
647f7cc78ecSespie#line 648 "configure"
648f7cc78ecSespie#include "confdefs.h"
649f7cc78ecSespie#include <assert.h>
650f7cc78ecSespieSyntax Error
651f7cc78ecSespieEOF
652f7cc78ecSespieac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
653f7cc78ecSespie{ (eval echo configure:654: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
654f7cc78ecSespieac_err=`grep -v '^ *+' conftest.out`
655f7cc78ecSespieif test -z "$ac_err"; then
656f7cc78ecSespie  :
657f7cc78ecSespieelse
658f7cc78ecSespie  echo "$ac_err" >&5
659f7cc78ecSespie  echo "configure: failed program was:" >&5
660f7cc78ecSespie  cat conftest.$ac_ext >&5
661f7cc78ecSespie  rm -rf conftest*
662f7cc78ecSespie  CPP=/lib/cpp
663f7cc78ecSespiefi
664f7cc78ecSespierm -f conftest*
665f7cc78ecSespiefi
666f7cc78ecSespierm -f conftest*
667f7cc78ecSespie  ac_cv_prog_CPP="$CPP"
668f7cc78ecSespiefi
669f7cc78ecSespie  CPP="$ac_cv_prog_CPP"
670f7cc78ecSespieelse
671f7cc78ecSespie  ac_cv_prog_CPP="$CPP"
672f7cc78ecSespiefi
673f7cc78ecSespieecho "$ac_t""$CPP" 1>&6
674f7cc78ecSespie
675f7cc78ecSespieecho $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
676f7cc78ecSespieecho "configure:677: checking whether ${MAKE-make} sets \${MAKE}" >&5
677f7cc78ecSespieset dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
678f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
679f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
680f7cc78ecSespieelse
681f7cc78ecSespie  cat > conftestmake <<\EOF
682f7cc78ecSespieall:
683f7cc78ecSespie	@echo 'ac_maketemp="${MAKE}"'
684f7cc78ecSespieEOF
685f7cc78ecSespie# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
686f7cc78ecSespieeval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
687f7cc78ecSespieif test -n "$ac_maketemp"; then
688f7cc78ecSespie  eval ac_cv_prog_make_${ac_make}_set=yes
689f7cc78ecSespieelse
690f7cc78ecSespie  eval ac_cv_prog_make_${ac_make}_set=no
691f7cc78ecSespiefi
692f7cc78ecSespierm -f conftestmake
693f7cc78ecSespiefi
694f7cc78ecSespieif eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
695f7cc78ecSespie  echo "$ac_t""yes" 1>&6
696f7cc78ecSespie  SET_MAKE=
697f7cc78ecSespieelse
698f7cc78ecSespie  echo "$ac_t""no" 1>&6
699f7cc78ecSespie  SET_MAKE="MAKE=${MAKE-make}"
700f7cc78ecSespiefi
701f7cc78ecSespie
702f7cc78ecSespie# Extract the first word of "gcc", so it can be a program name with args.
703f7cc78ecSespieset dummy gcc; ac_word=$2
704f7cc78ecSespieecho $ac_n "checking for $ac_word""... $ac_c" 1>&6
705f7cc78ecSespieecho "configure:706: checking for $ac_word" >&5
706f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
707f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
708f7cc78ecSespieelse
709f7cc78ecSespie  if test -n "$CC"; then
710f7cc78ecSespie  ac_cv_prog_CC="$CC" # Let the user override the test.
711f7cc78ecSespieelse
712f7cc78ecSespie  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
713f7cc78ecSespie  for ac_dir in $PATH; do
714f7cc78ecSespie    test -z "$ac_dir" && ac_dir=.
715f7cc78ecSespie    if test -f $ac_dir/$ac_word; then
716f7cc78ecSespie      ac_cv_prog_CC="gcc"
717f7cc78ecSespie      break
718f7cc78ecSespie    fi
719f7cc78ecSespie  done
720f7cc78ecSespie  IFS="$ac_save_ifs"
721f7cc78ecSespiefi
722f7cc78ecSespiefi
723f7cc78ecSespieCC="$ac_cv_prog_CC"
724f7cc78ecSespieif test -n "$CC"; then
725f7cc78ecSespie  echo "$ac_t""$CC" 1>&6
726f7cc78ecSespieelse
727f7cc78ecSespie  echo "$ac_t""no" 1>&6
728f7cc78ecSespiefi
729f7cc78ecSespie
730f7cc78ecSespieif test -z "$CC"; then
731f7cc78ecSespie  # Extract the first word of "cc", so it can be a program name with args.
732f7cc78ecSespieset dummy cc; ac_word=$2
733f7cc78ecSespieecho $ac_n "checking for $ac_word""... $ac_c" 1>&6
734f7cc78ecSespieecho "configure:735: checking for $ac_word" >&5
735f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
736f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
737f7cc78ecSespieelse
738f7cc78ecSespie  if test -n "$CC"; then
739f7cc78ecSespie  ac_cv_prog_CC="$CC" # Let the user override the test.
740f7cc78ecSespieelse
741f7cc78ecSespie  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
742f7cc78ecSespie  ac_prog_rejected=no
743f7cc78ecSespie  for ac_dir in $PATH; do
744f7cc78ecSespie    test -z "$ac_dir" && ac_dir=.
745f7cc78ecSespie    if test -f $ac_dir/$ac_word; then
746f7cc78ecSespie      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
747f7cc78ecSespie        ac_prog_rejected=yes
748f7cc78ecSespie	continue
749f7cc78ecSespie      fi
750f7cc78ecSespie      ac_cv_prog_CC="cc"
751f7cc78ecSespie      break
752f7cc78ecSespie    fi
753f7cc78ecSespie  done
754f7cc78ecSespie  IFS="$ac_save_ifs"
755f7cc78ecSespieif test $ac_prog_rejected = yes; then
756f7cc78ecSespie  # We found a bogon in the path, so make sure we never use it.
757f7cc78ecSespie  set dummy $ac_cv_prog_CC
758f7cc78ecSespie  shift
759f7cc78ecSespie  if test $# -gt 0; then
760f7cc78ecSespie    # We chose a different compiler from the bogus one.
761f7cc78ecSespie    # However, it has the same basename, so the bogon will be chosen
762f7cc78ecSespie    # first if we set CC to just the basename; use the full file name.
763f7cc78ecSespie    shift
764f7cc78ecSespie    set dummy "$ac_dir/$ac_word" "$@"
765f7cc78ecSespie    shift
766f7cc78ecSespie    ac_cv_prog_CC="$@"
767f7cc78ecSespie  fi
768f7cc78ecSespiefi
769f7cc78ecSespiefi
770f7cc78ecSespiefi
771f7cc78ecSespieCC="$ac_cv_prog_CC"
772f7cc78ecSespieif test -n "$CC"; then
773f7cc78ecSespie  echo "$ac_t""$CC" 1>&6
774f7cc78ecSespieelse
775f7cc78ecSespie  echo "$ac_t""no" 1>&6
776f7cc78ecSespiefi
777f7cc78ecSespie
778f7cc78ecSespie  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
779f7cc78ecSespiefi
780f7cc78ecSespie
781f7cc78ecSespieecho $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
782f7cc78ecSespieecho "configure:783: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
783f7cc78ecSespie
784f7cc78ecSespieac_ext=c
785f7cc78ecSespie# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
786f7cc78ecSespieac_cpp='$CPP $CPPFLAGS'
787f7cc78ecSespieac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
788f7cc78ecSespieac_link='${CC-cc} -o conftest $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
789f7cc78ecSespiecross_compiling=$ac_cv_prog_cc_cross
790f7cc78ecSespie
791f7cc78ecSespiecat > conftest.$ac_ext <<EOF
792f7cc78ecSespie#line 793 "configure"
793f7cc78ecSespie#include "confdefs.h"
794f7cc78ecSespiemain(){return(0);}
795f7cc78ecSespieEOF
796f7cc78ecSespieif { (eval echo configure:797: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
797f7cc78ecSespie  ac_cv_prog_cc_works=yes
798f7cc78ecSespie  # If we can't run a trivial program, we are probably using a cross compiler.
799f7cc78ecSespie  if (./conftest; exit) 2>/dev/null; then
800f7cc78ecSespie    ac_cv_prog_cc_cross=no
801f7cc78ecSespie  else
802f7cc78ecSespie    ac_cv_prog_cc_cross=yes
803f7cc78ecSespie  fi
804f7cc78ecSespieelse
805f7cc78ecSespie  echo "configure: failed program was:" >&5
806f7cc78ecSespie  cat conftest.$ac_ext >&5
807f7cc78ecSespie  ac_cv_prog_cc_works=no
808f7cc78ecSespiefi
809f7cc78ecSespierm -fr conftest*
810f7cc78ecSespie
811f7cc78ecSespieecho "$ac_t""$ac_cv_prog_cc_works" 1>&6
812f7cc78ecSespieif test $ac_cv_prog_cc_works = no; then
813f7cc78ecSespie  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
814f7cc78ecSespiefi
815f7cc78ecSespieecho $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
816f7cc78ecSespieecho "configure:817: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
817f7cc78ecSespieecho "$ac_t""$ac_cv_prog_cc_cross" 1>&6
818f7cc78ecSespiecross_compiling=$ac_cv_prog_cc_cross
819f7cc78ecSespie
820f7cc78ecSespieecho $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
821f7cc78ecSespieecho "configure:822: checking whether we are using GNU C" >&5
822f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
823f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
824f7cc78ecSespieelse
825f7cc78ecSespie  cat > conftest.c <<EOF
826f7cc78ecSespie#ifdef __GNUC__
827f7cc78ecSespie  yes;
828f7cc78ecSespie#endif
829f7cc78ecSespieEOF
830f7cc78ecSespieif { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:831: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
831f7cc78ecSespie  ac_cv_prog_gcc=yes
832f7cc78ecSespieelse
833f7cc78ecSespie  ac_cv_prog_gcc=no
834f7cc78ecSespiefi
835f7cc78ecSespiefi
836f7cc78ecSespie
837f7cc78ecSespieecho "$ac_t""$ac_cv_prog_gcc" 1>&6
838f7cc78ecSespie
839f7cc78ecSespieif test $ac_cv_prog_gcc = yes; then
840f7cc78ecSespie  GCC=yes
841f7cc78ecSespie  ac_test_CFLAGS="${CFLAGS+set}"
842f7cc78ecSespie  ac_save_CFLAGS="$CFLAGS"
843f7cc78ecSespie  CFLAGS=
844f7cc78ecSespie  echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
845f7cc78ecSespieecho "configure:846: checking whether ${CC-cc} accepts -g" >&5
846f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
847f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
848f7cc78ecSespieelse
849f7cc78ecSespie  echo 'void f(){}' > conftest.c
850f7cc78ecSespieif test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
851f7cc78ecSespie  ac_cv_prog_cc_g=yes
852f7cc78ecSespieelse
853f7cc78ecSespie  ac_cv_prog_cc_g=no
854f7cc78ecSespiefi
855f7cc78ecSespierm -f conftest*
856f7cc78ecSespie
857f7cc78ecSespiefi
858f7cc78ecSespie
859f7cc78ecSespieecho "$ac_t""$ac_cv_prog_cc_g" 1>&6
860f7cc78ecSespie  if test "$ac_test_CFLAGS" = set; then
861f7cc78ecSespie    CFLAGS="$ac_save_CFLAGS"
862f7cc78ecSespie  elif test $ac_cv_prog_cc_g = yes; then
863f7cc78ecSespie    CFLAGS="-g -O2"
864f7cc78ecSespie  else
865f7cc78ecSespie    CFLAGS="-O2"
866f7cc78ecSespie  fi
867f7cc78ecSespieelse
868f7cc78ecSespie  GCC=
869f7cc78ecSespie  test "${CFLAGS+set}" = set || CFLAGS="-g"
870f7cc78ecSespiefi
871f7cc78ecSespie
872f7cc78ecSespie# Extract the first word of "ranlib", so it can be a program name with args.
873f7cc78ecSespieset dummy ranlib; ac_word=$2
874f7cc78ecSespieecho $ac_n "checking for $ac_word""... $ac_c" 1>&6
875f7cc78ecSespieecho "configure:876: checking for $ac_word" >&5
876f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
877f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
878f7cc78ecSespieelse
879f7cc78ecSespie  if test -n "$RANLIB"; then
880f7cc78ecSespie  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
881f7cc78ecSespieelse
882f7cc78ecSespie  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
883f7cc78ecSespie  for ac_dir in $PATH; do
884f7cc78ecSespie    test -z "$ac_dir" && ac_dir=.
885f7cc78ecSespie    if test -f $ac_dir/$ac_word; then
886f7cc78ecSespie      ac_cv_prog_RANLIB="ranlib"
887f7cc78ecSespie      break
888f7cc78ecSespie    fi
889f7cc78ecSespie  done
890f7cc78ecSespie  IFS="$ac_save_ifs"
891f7cc78ecSespie  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
892f7cc78ecSespiefi
893f7cc78ecSespiefi
894f7cc78ecSespieRANLIB="$ac_cv_prog_RANLIB"
895f7cc78ecSespieif test -n "$RANLIB"; then
896f7cc78ecSespie  echo "$ac_t""$RANLIB" 1>&6
897f7cc78ecSespieelse
898f7cc78ecSespie  echo "$ac_t""no" 1>&6
899f7cc78ecSespiefi
900f7cc78ecSespie
901f7cc78ecSespieecho $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
902f7cc78ecSespieecho "configure:903: checking for POSIXized ISC" >&5
903f7cc78ecSespieif test -d /etc/conf/kconfig.d &&
904f7cc78ecSespie  grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
905f7cc78ecSespiethen
906f7cc78ecSespie  echo "$ac_t""yes" 1>&6
907f7cc78ecSespie  ISC=yes # If later tests want to check for ISC.
908f7cc78ecSespie  cat >> confdefs.h <<\EOF
909f7cc78ecSespie#define _POSIX_SOURCE 1
910f7cc78ecSespieEOF
911f7cc78ecSespie
912f7cc78ecSespie  if test "$GCC" = yes; then
913f7cc78ecSespie    CC="$CC -posix"
914f7cc78ecSespie  else
915f7cc78ecSespie    CC="$CC -Xp"
916f7cc78ecSespie  fi
917f7cc78ecSespieelse
918f7cc78ecSespie  echo "$ac_t""no" 1>&6
919f7cc78ecSespie  ISC=
920f7cc78ecSespiefi
921f7cc78ecSespie
922f7cc78ecSespieecho $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
923f7cc78ecSespieecho "configure:924: checking for ANSI C header files" >&5
924f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
925f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
926f7cc78ecSespieelse
927f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
928f7cc78ecSespie#line 929 "configure"
929f7cc78ecSespie#include "confdefs.h"
930f7cc78ecSespie#include <stdlib.h>
931f7cc78ecSespie#include <stdarg.h>
932f7cc78ecSespie#include <string.h>
933f7cc78ecSespie#include <float.h>
934f7cc78ecSespieEOF
935f7cc78ecSespieac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
936f7cc78ecSespie{ (eval echo configure:937: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
937f7cc78ecSespieac_err=`grep -v '^ *+' conftest.out`
938f7cc78ecSespieif test -z "$ac_err"; then
939f7cc78ecSespie  rm -rf conftest*
940f7cc78ecSespie  ac_cv_header_stdc=yes
941f7cc78ecSespieelse
942f7cc78ecSespie  echo "$ac_err" >&5
943f7cc78ecSespie  echo "configure: failed program was:" >&5
944f7cc78ecSespie  cat conftest.$ac_ext >&5
945f7cc78ecSespie  rm -rf conftest*
946f7cc78ecSespie  ac_cv_header_stdc=no
947f7cc78ecSespiefi
948f7cc78ecSespierm -f conftest*
949f7cc78ecSespie
950f7cc78ecSespieif test $ac_cv_header_stdc = yes; then
951f7cc78ecSespie  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
952f7cc78ecSespiecat > conftest.$ac_ext <<EOF
953f7cc78ecSespie#line 954 "configure"
954f7cc78ecSespie#include "confdefs.h"
955f7cc78ecSespie#include <string.h>
956f7cc78ecSespieEOF
957f7cc78ecSespieif (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
958f7cc78ecSespie  egrep "memchr" >/dev/null 2>&1; then
959f7cc78ecSespie  :
960f7cc78ecSespieelse
961f7cc78ecSespie  rm -rf conftest*
962f7cc78ecSespie  ac_cv_header_stdc=no
963f7cc78ecSespiefi
964f7cc78ecSespierm -f conftest*
965f7cc78ecSespie
966f7cc78ecSespiefi
967f7cc78ecSespie
968f7cc78ecSespieif test $ac_cv_header_stdc = yes; then
969f7cc78ecSespie  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
970f7cc78ecSespiecat > conftest.$ac_ext <<EOF
971f7cc78ecSespie#line 972 "configure"
972f7cc78ecSespie#include "confdefs.h"
973f7cc78ecSespie#include <stdlib.h>
974f7cc78ecSespieEOF
975f7cc78ecSespieif (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
976f7cc78ecSespie  egrep "free" >/dev/null 2>&1; then
977f7cc78ecSespie  :
978f7cc78ecSespieelse
979f7cc78ecSespie  rm -rf conftest*
980f7cc78ecSespie  ac_cv_header_stdc=no
981f7cc78ecSespiefi
982f7cc78ecSespierm -f conftest*
983f7cc78ecSespie
984f7cc78ecSespiefi
985f7cc78ecSespie
986f7cc78ecSespieif test $ac_cv_header_stdc = yes; then
987f7cc78ecSespie  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
988f7cc78ecSespieif test "$cross_compiling" = yes; then
989f7cc78ecSespie  :
990f7cc78ecSespieelse
991f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
992f7cc78ecSespie#line 993 "configure"
993f7cc78ecSespie#include "confdefs.h"
994f7cc78ecSespie#include <ctype.h>
995f7cc78ecSespie#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
996f7cc78ecSespie#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
997f7cc78ecSespie#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
998f7cc78ecSespieint main () { int i; for (i = 0; i < 256; i++)
999f7cc78ecSespieif (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1000f7cc78ecSespieexit (0); }
1001f7cc78ecSespie
1002f7cc78ecSespieEOF
1003f7cc78ecSespieif { (eval echo configure:1004: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
1004f7cc78ecSespiethen
1005f7cc78ecSespie  :
1006f7cc78ecSespieelse
1007f7cc78ecSespie  echo "configure: failed program was:" >&5
1008f7cc78ecSespie  cat conftest.$ac_ext >&5
1009f7cc78ecSespie  rm -fr conftest*
1010f7cc78ecSespie  ac_cv_header_stdc=no
1011f7cc78ecSespiefi
1012f7cc78ecSespierm -fr conftest*
1013f7cc78ecSespiefi
1014f7cc78ecSespie
1015f7cc78ecSespiefi
1016f7cc78ecSespiefi
1017f7cc78ecSespie
1018f7cc78ecSespieecho "$ac_t""$ac_cv_header_stdc" 1>&6
1019f7cc78ecSespieif test $ac_cv_header_stdc = yes; then
1020f7cc78ecSespie  cat >> confdefs.h <<\EOF
1021f7cc78ecSespie#define STDC_HEADERS 1
1022f7cc78ecSespieEOF
1023f7cc78ecSespie
1024f7cc78ecSespiefi
1025f7cc78ecSespie
1026f7cc78ecSespieecho $ac_n "checking for working const""... $ac_c" 1>&6
1027f7cc78ecSespieecho "configure:1028: checking for working const" >&5
1028f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
1029f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1030f7cc78ecSespieelse
1031f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1032f7cc78ecSespie#line 1033 "configure"
1033f7cc78ecSespie#include "confdefs.h"
1034f7cc78ecSespie
1035f7cc78ecSespieint main() {
1036f7cc78ecSespie
1037f7cc78ecSespie/* Ultrix mips cc rejects this.  */
1038f7cc78ecSespietypedef int charset[2]; const charset x;
1039f7cc78ecSespie/* SunOS 4.1.1 cc rejects this.  */
1040f7cc78ecSespiechar const *const *ccp;
1041f7cc78ecSespiechar **p;
1042f7cc78ecSespie/* NEC SVR4.0.2 mips cc rejects this.  */
1043f7cc78ecSespiestruct point {int x, y;};
1044f7cc78ecSespiestatic struct point const zero = {0,0};
1045f7cc78ecSespie/* AIX XL C 1.02.0.0 rejects this.
1046f7cc78ecSespie   It does not let you subtract one const X* pointer from another in an arm
1047f7cc78ecSespie   of an if-expression whose if-part is not a constant expression */
1048f7cc78ecSespieconst char *g = "string";
1049f7cc78ecSespieccp = &g + (g ? g-g : 0);
1050f7cc78ecSespie/* HPUX 7.0 cc rejects these. */
1051f7cc78ecSespie++ccp;
1052f7cc78ecSespiep = (char**) ccp;
1053f7cc78ecSespieccp = (char const *const *) p;
1054f7cc78ecSespie{ /* SCO 3.2v4 cc rejects this.  */
1055f7cc78ecSespie  char *t;
1056f7cc78ecSespie  char const *s = 0 ? (char *) 0 : (char const *) 0;
1057f7cc78ecSespie
1058f7cc78ecSespie  *t++ = 0;
1059f7cc78ecSespie}
1060f7cc78ecSespie{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
1061f7cc78ecSespie  int x[] = {25, 17};
1062f7cc78ecSespie  const int *foo = &x[0];
1063f7cc78ecSespie  ++foo;
1064f7cc78ecSespie}
1065f7cc78ecSespie{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
1066f7cc78ecSespie  typedef const int *iptr;
1067f7cc78ecSespie  iptr p = 0;
1068f7cc78ecSespie  ++p;
1069f7cc78ecSespie}
1070f7cc78ecSespie{ /* AIX XL C 1.02.0.0 rejects this saying
1071f7cc78ecSespie     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
1072f7cc78ecSespie  struct s { int j; const int *ap[3]; };
1073f7cc78ecSespie  struct s *b; b->j = 5;
1074f7cc78ecSespie}
1075f7cc78ecSespie{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
1076f7cc78ecSespie  const int foo = 10;
1077f7cc78ecSespie}
1078f7cc78ecSespie
1079f7cc78ecSespie; return 0; }
1080f7cc78ecSespieEOF
1081f7cc78ecSespieif { (eval echo configure:1082: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1082f7cc78ecSespie  rm -rf conftest*
1083f7cc78ecSespie  ac_cv_c_const=yes
1084f7cc78ecSespieelse
1085f7cc78ecSespie  echo "configure: failed program was:" >&5
1086f7cc78ecSespie  cat conftest.$ac_ext >&5
1087f7cc78ecSespie  rm -rf conftest*
1088f7cc78ecSespie  ac_cv_c_const=no
1089f7cc78ecSespiefi
1090f7cc78ecSespierm -f conftest*
1091f7cc78ecSespiefi
1092f7cc78ecSespie
1093f7cc78ecSespieecho "$ac_t""$ac_cv_c_const" 1>&6
1094f7cc78ecSespieif test $ac_cv_c_const = no; then
1095f7cc78ecSespie  cat >> confdefs.h <<\EOF
1096f7cc78ecSespie#define const
1097f7cc78ecSespieEOF
1098f7cc78ecSespie
1099f7cc78ecSespiefi
1100f7cc78ecSespie
1101f7cc78ecSespieecho $ac_n "checking for inline""... $ac_c" 1>&6
1102f7cc78ecSespieecho "configure:1103: checking for inline" >&5
1103f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
1104f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1105f7cc78ecSespieelse
1106f7cc78ecSespie  ac_cv_c_inline=no
1107f7cc78ecSespiefor ac_kw in inline __inline__ __inline; do
1108f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1109f7cc78ecSespie#line 1110 "configure"
1110f7cc78ecSespie#include "confdefs.h"
1111f7cc78ecSespie
1112f7cc78ecSespieint main() {
1113f7cc78ecSespie} $ac_kw foo() {
1114f7cc78ecSespie; return 0; }
1115f7cc78ecSespieEOF
1116f7cc78ecSespieif { (eval echo configure:1117: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1117f7cc78ecSespie  rm -rf conftest*
1118f7cc78ecSespie  ac_cv_c_inline=$ac_kw; break
1119f7cc78ecSespieelse
1120f7cc78ecSespie  echo "configure: failed program was:" >&5
1121f7cc78ecSespie  cat conftest.$ac_ext >&5
1122f7cc78ecSespiefi
1123f7cc78ecSespierm -f conftest*
1124f7cc78ecSespiedone
1125f7cc78ecSespie
1126f7cc78ecSespiefi
1127f7cc78ecSespie
1128f7cc78ecSespieecho "$ac_t""$ac_cv_c_inline" 1>&6
1129f7cc78ecSespiecase "$ac_cv_c_inline" in
1130f7cc78ecSespie  inline | yes) ;;
1131f7cc78ecSespie  no) cat >> confdefs.h <<\EOF
1132f7cc78ecSespie#define inline
1133f7cc78ecSespieEOF
1134f7cc78ecSespie ;;
1135f7cc78ecSespie  *)  cat >> confdefs.h <<EOF
1136f7cc78ecSespie#define inline $ac_cv_c_inline
1137f7cc78ecSespieEOF
1138f7cc78ecSespie ;;
1139f7cc78ecSespieesac
1140f7cc78ecSespie
1141f7cc78ecSespieecho $ac_n "checking for off_t""... $ac_c" 1>&6
1142f7cc78ecSespieecho "configure:1143: checking for off_t" >&5
1143f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
1144f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1145f7cc78ecSespieelse
1146f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1147f7cc78ecSespie#line 1148 "configure"
1148f7cc78ecSespie#include "confdefs.h"
1149f7cc78ecSespie#include <sys/types.h>
1150f7cc78ecSespie#if STDC_HEADERS
1151f7cc78ecSespie#include <stdlib.h>
1152f7cc78ecSespie#include <stddef.h>
1153f7cc78ecSespie#endif
1154f7cc78ecSespieEOF
1155f7cc78ecSespieif (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1156f7cc78ecSespie  egrep "off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1157f7cc78ecSespie  rm -rf conftest*
1158f7cc78ecSespie  ac_cv_type_off_t=yes
1159f7cc78ecSespieelse
1160f7cc78ecSespie  rm -rf conftest*
1161f7cc78ecSespie  ac_cv_type_off_t=no
1162f7cc78ecSespiefi
1163f7cc78ecSespierm -f conftest*
1164f7cc78ecSespie
1165f7cc78ecSespiefi
1166f7cc78ecSespieecho "$ac_t""$ac_cv_type_off_t" 1>&6
1167f7cc78ecSespieif test $ac_cv_type_off_t = no; then
1168f7cc78ecSespie  cat >> confdefs.h <<\EOF
1169f7cc78ecSespie#define off_t long
1170f7cc78ecSespieEOF
1171f7cc78ecSespie
1172f7cc78ecSespiefi
1173f7cc78ecSespie
1174f7cc78ecSespieecho $ac_n "checking for size_t""... $ac_c" 1>&6
1175f7cc78ecSespieecho "configure:1176: checking for size_t" >&5
1176f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
1177f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1178f7cc78ecSespieelse
1179f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1180f7cc78ecSespie#line 1181 "configure"
1181f7cc78ecSespie#include "confdefs.h"
1182f7cc78ecSespie#include <sys/types.h>
1183f7cc78ecSespie#if STDC_HEADERS
1184f7cc78ecSespie#include <stdlib.h>
1185f7cc78ecSespie#include <stddef.h>
1186f7cc78ecSespie#endif
1187f7cc78ecSespieEOF
1188f7cc78ecSespieif (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1189f7cc78ecSespie  egrep "size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
1190f7cc78ecSespie  rm -rf conftest*
1191f7cc78ecSespie  ac_cv_type_size_t=yes
1192f7cc78ecSespieelse
1193f7cc78ecSespie  rm -rf conftest*
1194f7cc78ecSespie  ac_cv_type_size_t=no
1195f7cc78ecSespiefi
1196f7cc78ecSespierm -f conftest*
1197f7cc78ecSespie
1198f7cc78ecSespiefi
1199f7cc78ecSespieecho "$ac_t""$ac_cv_type_size_t" 1>&6
1200f7cc78ecSespieif test $ac_cv_type_size_t = no; then
1201f7cc78ecSespie  cat >> confdefs.h <<\EOF
1202f7cc78ecSespie#define size_t unsigned
1203f7cc78ecSespieEOF
1204f7cc78ecSespie
1205f7cc78ecSespiefi
1206f7cc78ecSespie
1207f7cc78ecSespie# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
1208f7cc78ecSespie# for constant arguments.  Useless!
1209f7cc78ecSespieecho $ac_n "checking for working alloca.h""... $ac_c" 1>&6
1210f7cc78ecSespieecho "configure:1211: checking for working alloca.h" >&5
1211f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
1212f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1213f7cc78ecSespieelse
1214f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1215f7cc78ecSespie#line 1216 "configure"
1216f7cc78ecSespie#include "confdefs.h"
1217f7cc78ecSespie#include <alloca.h>
1218f7cc78ecSespieint main() {
1219f7cc78ecSespiechar *p = alloca(2 * sizeof(int));
1220f7cc78ecSespie; return 0; }
1221f7cc78ecSespieEOF
1222f7cc78ecSespieif { (eval echo configure:1223: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1223f7cc78ecSespie  rm -rf conftest*
1224f7cc78ecSespie  ac_cv_header_alloca_h=yes
1225f7cc78ecSespieelse
1226f7cc78ecSespie  echo "configure: failed program was:" >&5
1227f7cc78ecSespie  cat conftest.$ac_ext >&5
1228f7cc78ecSespie  rm -rf conftest*
1229f7cc78ecSespie  ac_cv_header_alloca_h=no
1230f7cc78ecSespiefi
1231f7cc78ecSespierm -f conftest*
1232f7cc78ecSespiefi
1233f7cc78ecSespie
1234f7cc78ecSespieecho "$ac_t""$ac_cv_header_alloca_h" 1>&6
1235f7cc78ecSespieif test $ac_cv_header_alloca_h = yes; then
1236f7cc78ecSespie  cat >> confdefs.h <<\EOF
1237f7cc78ecSespie#define HAVE_ALLOCA_H 1
1238f7cc78ecSespieEOF
1239f7cc78ecSespie
1240f7cc78ecSespiefi
1241f7cc78ecSespie
1242f7cc78ecSespieecho $ac_n "checking for alloca""... $ac_c" 1>&6
1243f7cc78ecSespieecho "configure:1244: checking for alloca" >&5
1244f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
1245f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1246f7cc78ecSespieelse
1247f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1248f7cc78ecSespie#line 1249 "configure"
1249f7cc78ecSespie#include "confdefs.h"
1250f7cc78ecSespie
1251f7cc78ecSespie#ifdef __GNUC__
1252f7cc78ecSespie# define alloca __builtin_alloca
1253f7cc78ecSespie#else
1254f7cc78ecSespie# if HAVE_ALLOCA_H
1255f7cc78ecSespie#  include <alloca.h>
1256f7cc78ecSespie# else
1257f7cc78ecSespie#  ifdef _AIX
1258f7cc78ecSespie #pragma alloca
1259f7cc78ecSespie#  else
1260f7cc78ecSespie#   ifndef alloca /* predefined by HP cc +Olibcalls */
1261f7cc78ecSespiechar *alloca ();
1262f7cc78ecSespie#   endif
1263f7cc78ecSespie#  endif
1264f7cc78ecSespie# endif
1265f7cc78ecSespie#endif
1266f7cc78ecSespie
1267f7cc78ecSespieint main() {
1268f7cc78ecSespiechar *p = (char *) alloca(1);
1269f7cc78ecSespie; return 0; }
1270f7cc78ecSespieEOF
1271f7cc78ecSespieif { (eval echo configure:1272: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1272f7cc78ecSespie  rm -rf conftest*
1273f7cc78ecSespie  ac_cv_func_alloca_works=yes
1274f7cc78ecSespieelse
1275f7cc78ecSespie  echo "configure: failed program was:" >&5
1276f7cc78ecSespie  cat conftest.$ac_ext >&5
1277f7cc78ecSespie  rm -rf conftest*
1278f7cc78ecSespie  ac_cv_func_alloca_works=no
1279f7cc78ecSespiefi
1280f7cc78ecSespierm -f conftest*
1281f7cc78ecSespiefi
1282f7cc78ecSespie
1283f7cc78ecSespieecho "$ac_t""$ac_cv_func_alloca_works" 1>&6
1284f7cc78ecSespieif test $ac_cv_func_alloca_works = yes; then
1285f7cc78ecSespie  cat >> confdefs.h <<\EOF
1286f7cc78ecSespie#define HAVE_ALLOCA 1
1287f7cc78ecSespieEOF
1288f7cc78ecSespie
1289f7cc78ecSespiefi
1290f7cc78ecSespie
1291f7cc78ecSespieif test $ac_cv_func_alloca_works = no; then
1292f7cc78ecSespie  # The SVR3 libPW and SVR4 libucb both contain incompatible functions
1293f7cc78ecSespie  # that cause trouble.  Some versions do not even contain alloca or
1294f7cc78ecSespie  # contain a buggy version.  If you still want to use their alloca,
1295f7cc78ecSespie  # use ar to extract alloca.o from them instead of compiling alloca.c.
1296f7cc78ecSespie  ALLOCA=alloca.o
1297f7cc78ecSespie  cat >> confdefs.h <<\EOF
1298f7cc78ecSespie#define C_ALLOCA 1
1299f7cc78ecSespieEOF
1300f7cc78ecSespie
1301f7cc78ecSespie
1302f7cc78ecSespieecho $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
1303f7cc78ecSespieecho "configure:1304: checking whether alloca needs Cray hooks" >&5
1304f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
1305f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1306f7cc78ecSespieelse
1307f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1308f7cc78ecSespie#line 1309 "configure"
1309f7cc78ecSespie#include "confdefs.h"
1310f7cc78ecSespie#if defined(CRAY) && ! defined(CRAY2)
1311f7cc78ecSespiewebecray
1312f7cc78ecSespie#else
1313f7cc78ecSespiewenotbecray
1314f7cc78ecSespie#endif
1315f7cc78ecSespie
1316f7cc78ecSespieEOF
1317f7cc78ecSespieif (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1318f7cc78ecSespie  egrep "webecray" >/dev/null 2>&1; then
1319f7cc78ecSespie  rm -rf conftest*
1320f7cc78ecSespie  ac_cv_os_cray=yes
1321f7cc78ecSespieelse
1322f7cc78ecSespie  rm -rf conftest*
1323f7cc78ecSespie  ac_cv_os_cray=no
1324f7cc78ecSespiefi
1325f7cc78ecSespierm -f conftest*
1326f7cc78ecSespie
1327f7cc78ecSespiefi
1328f7cc78ecSespie
1329f7cc78ecSespieecho "$ac_t""$ac_cv_os_cray" 1>&6
1330f7cc78ecSespieif test $ac_cv_os_cray = yes; then
1331f7cc78ecSespiefor ac_func in _getb67 GETB67 getb67; do
1332f7cc78ecSespie  echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
1333f7cc78ecSespieecho "configure:1334: checking for $ac_func" >&5
1334f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1335f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1336f7cc78ecSespieelse
1337f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1338f7cc78ecSespie#line 1339 "configure"
1339f7cc78ecSespie#include "confdefs.h"
1340f7cc78ecSespie/* System header to define __stub macros and hopefully few prototypes,
1341f7cc78ecSespie    which can conflict with char $ac_func(); below.  */
1342f7cc78ecSespie#include <assert.h>
1343f7cc78ecSespie/* Override any gcc2 internal prototype to avoid an error.  */
1344f7cc78ecSespie/* We use char because int might match the return type of a gcc2
1345f7cc78ecSespie    builtin and then its argument prototype would still apply.  */
1346f7cc78ecSespiechar $ac_func();
1347f7cc78ecSespie
1348f7cc78ecSespieint main() {
1349f7cc78ecSespie
1350f7cc78ecSespie/* The GNU C library defines this for functions which it implements
1351f7cc78ecSespie    to always fail with ENOSYS.  Some functions are actually named
1352f7cc78ecSespie    something starting with __ and the normal name is an alias.  */
1353f7cc78ecSespie#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1354f7cc78ecSespiechoke me
1355f7cc78ecSespie#else
1356f7cc78ecSespie$ac_func();
1357f7cc78ecSespie#endif
1358f7cc78ecSespie
1359f7cc78ecSespie; return 0; }
1360f7cc78ecSespieEOF
1361f7cc78ecSespieif { (eval echo configure:1362: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1362f7cc78ecSespie  rm -rf conftest*
1363f7cc78ecSespie  eval "ac_cv_func_$ac_func=yes"
1364f7cc78ecSespieelse
1365f7cc78ecSespie  echo "configure: failed program was:" >&5
1366f7cc78ecSespie  cat conftest.$ac_ext >&5
1367f7cc78ecSespie  rm -rf conftest*
1368f7cc78ecSespie  eval "ac_cv_func_$ac_func=no"
1369f7cc78ecSespiefi
1370f7cc78ecSespierm -f conftest*
1371f7cc78ecSespiefi
1372f7cc78ecSespie
1373f7cc78ecSespieif eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1374f7cc78ecSespie  echo "$ac_t""yes" 1>&6
1375f7cc78ecSespie  cat >> confdefs.h <<EOF
1376f7cc78ecSespie#define CRAY_STACKSEG_END $ac_func
1377f7cc78ecSespieEOF
1378f7cc78ecSespie
1379f7cc78ecSespie  break
1380f7cc78ecSespieelse
1381f7cc78ecSespie  echo "$ac_t""no" 1>&6
1382f7cc78ecSespiefi
1383f7cc78ecSespie
1384f7cc78ecSespiedone
1385f7cc78ecSespiefi
1386f7cc78ecSespie
1387f7cc78ecSespieecho $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
1388f7cc78ecSespieecho "configure:1389: checking stack direction for C alloca" >&5
1389f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
1390f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1391f7cc78ecSespieelse
1392f7cc78ecSespie  if test "$cross_compiling" = yes; then
1393f7cc78ecSespie  ac_cv_c_stack_direction=0
1394f7cc78ecSespieelse
1395f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1396f7cc78ecSespie#line 1397 "configure"
1397f7cc78ecSespie#include "confdefs.h"
1398f7cc78ecSespiefind_stack_direction ()
1399f7cc78ecSespie{
1400f7cc78ecSespie  static char *addr = 0;
1401f7cc78ecSespie  auto char dummy;
1402f7cc78ecSespie  if (addr == 0)
1403f7cc78ecSespie    {
1404f7cc78ecSespie      addr = &dummy;
1405f7cc78ecSespie      return find_stack_direction ();
1406f7cc78ecSespie    }
1407f7cc78ecSespie  else
1408f7cc78ecSespie    return (&dummy > addr) ? 1 : -1;
1409f7cc78ecSespie}
1410f7cc78ecSespiemain ()
1411f7cc78ecSespie{
1412f7cc78ecSespie  exit (find_stack_direction() < 0);
1413f7cc78ecSespie}
1414f7cc78ecSespieEOF
1415f7cc78ecSespieif { (eval echo configure:1416: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
1416f7cc78ecSespiethen
1417f7cc78ecSespie  ac_cv_c_stack_direction=1
1418f7cc78ecSespieelse
1419f7cc78ecSespie  echo "configure: failed program was:" >&5
1420f7cc78ecSespie  cat conftest.$ac_ext >&5
1421f7cc78ecSespie  rm -fr conftest*
1422f7cc78ecSespie  ac_cv_c_stack_direction=-1
1423f7cc78ecSespiefi
1424f7cc78ecSespierm -fr conftest*
1425f7cc78ecSespiefi
1426f7cc78ecSespie
1427f7cc78ecSespiefi
1428f7cc78ecSespie
1429f7cc78ecSespieecho "$ac_t""$ac_cv_c_stack_direction" 1>&6
1430f7cc78ecSespiecat >> confdefs.h <<EOF
1431f7cc78ecSespie#define STACK_DIRECTION $ac_cv_c_stack_direction
1432f7cc78ecSespieEOF
1433f7cc78ecSespie
1434f7cc78ecSespiefi
1435f7cc78ecSespie
1436f7cc78ecSespiefor ac_hdr in unistd.h
1437f7cc78ecSespiedo
1438f7cc78ecSespieac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1439f7cc78ecSespieecho $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1440f7cc78ecSespieecho "configure:1441: checking for $ac_hdr" >&5
1441f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1442f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1443f7cc78ecSespieelse
1444f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1445f7cc78ecSespie#line 1446 "configure"
1446f7cc78ecSespie#include "confdefs.h"
1447f7cc78ecSespie#include <$ac_hdr>
1448f7cc78ecSespieEOF
1449f7cc78ecSespieac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1450f7cc78ecSespie{ (eval echo configure:1451: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1451f7cc78ecSespieac_err=`grep -v '^ *+' conftest.out`
1452f7cc78ecSespieif test -z "$ac_err"; then
1453f7cc78ecSespie  rm -rf conftest*
1454f7cc78ecSespie  eval "ac_cv_header_$ac_safe=yes"
1455f7cc78ecSespieelse
1456f7cc78ecSespie  echo "$ac_err" >&5
1457f7cc78ecSespie  echo "configure: failed program was:" >&5
1458f7cc78ecSespie  cat conftest.$ac_ext >&5
1459f7cc78ecSespie  rm -rf conftest*
1460f7cc78ecSespie  eval "ac_cv_header_$ac_safe=no"
1461f7cc78ecSespiefi
1462f7cc78ecSespierm -f conftest*
1463f7cc78ecSespiefi
1464f7cc78ecSespieif eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1465f7cc78ecSespie  echo "$ac_t""yes" 1>&6
1466f7cc78ecSespie    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1467f7cc78ecSespie  cat >> confdefs.h <<EOF
1468f7cc78ecSespie#define $ac_tr_hdr 1
1469f7cc78ecSespieEOF
1470f7cc78ecSespie
1471f7cc78ecSespieelse
1472f7cc78ecSespie  echo "$ac_t""no" 1>&6
1473f7cc78ecSespiefi
1474f7cc78ecSespiedone
1475f7cc78ecSespie
1476f7cc78ecSespiefor ac_func in getpagesize
1477f7cc78ecSespiedo
1478f7cc78ecSespieecho $ac_n "checking for $ac_func""... $ac_c" 1>&6
1479f7cc78ecSespieecho "configure:1480: checking for $ac_func" >&5
1480f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1481f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1482f7cc78ecSespieelse
1483f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1484f7cc78ecSespie#line 1485 "configure"
1485f7cc78ecSespie#include "confdefs.h"
1486f7cc78ecSespie/* System header to define __stub macros and hopefully few prototypes,
1487f7cc78ecSespie    which can conflict with char $ac_func(); below.  */
1488f7cc78ecSespie#include <assert.h>
1489f7cc78ecSespie/* Override any gcc2 internal prototype to avoid an error.  */
1490f7cc78ecSespie/* We use char because int might match the return type of a gcc2
1491f7cc78ecSespie    builtin and then its argument prototype would still apply.  */
1492f7cc78ecSespiechar $ac_func();
1493f7cc78ecSespie
1494f7cc78ecSespieint main() {
1495f7cc78ecSespie
1496f7cc78ecSespie/* The GNU C library defines this for functions which it implements
1497f7cc78ecSespie    to always fail with ENOSYS.  Some functions are actually named
1498f7cc78ecSespie    something starting with __ and the normal name is an alias.  */
1499f7cc78ecSespie#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1500f7cc78ecSespiechoke me
1501f7cc78ecSespie#else
1502f7cc78ecSespie$ac_func();
1503f7cc78ecSespie#endif
1504f7cc78ecSespie
1505f7cc78ecSespie; return 0; }
1506f7cc78ecSespieEOF
1507f7cc78ecSespieif { (eval echo configure:1508: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1508f7cc78ecSespie  rm -rf conftest*
1509f7cc78ecSespie  eval "ac_cv_func_$ac_func=yes"
1510f7cc78ecSespieelse
1511f7cc78ecSespie  echo "configure: failed program was:" >&5
1512f7cc78ecSespie  cat conftest.$ac_ext >&5
1513f7cc78ecSespie  rm -rf conftest*
1514f7cc78ecSespie  eval "ac_cv_func_$ac_func=no"
1515f7cc78ecSespiefi
1516f7cc78ecSespierm -f conftest*
1517f7cc78ecSespiefi
1518f7cc78ecSespie
1519f7cc78ecSespieif eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1520f7cc78ecSespie  echo "$ac_t""yes" 1>&6
1521f7cc78ecSespie    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1522f7cc78ecSespie  cat >> confdefs.h <<EOF
1523f7cc78ecSespie#define $ac_tr_func 1
1524f7cc78ecSespieEOF
1525f7cc78ecSespie
1526f7cc78ecSespieelse
1527f7cc78ecSespie  echo "$ac_t""no" 1>&6
1528f7cc78ecSespiefi
1529f7cc78ecSespiedone
1530f7cc78ecSespie
1531f7cc78ecSespieecho $ac_n "checking for working mmap""... $ac_c" 1>&6
1532f7cc78ecSespieecho "configure:1533: checking for working mmap" >&5
1533f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
1534f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1535f7cc78ecSespieelse
1536f7cc78ecSespie  if test "$cross_compiling" = yes; then
1537f7cc78ecSespie  ac_cv_func_mmap_fixed_mapped=no
1538f7cc78ecSespieelse
1539f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1540f7cc78ecSespie#line 1541 "configure"
1541f7cc78ecSespie#include "confdefs.h"
1542f7cc78ecSespie
1543f7cc78ecSespie/* Thanks to Mike Haertel and Jim Avera for this test.
1544f7cc78ecSespie   Here is a matrix of mmap possibilities:
1545f7cc78ecSespie	mmap private not fixed
1546f7cc78ecSespie	mmap private fixed at somewhere currently unmapped
1547f7cc78ecSespie	mmap private fixed at somewhere already mapped
1548f7cc78ecSespie	mmap shared not fixed
1549f7cc78ecSespie	mmap shared fixed at somewhere currently unmapped
1550f7cc78ecSespie	mmap shared fixed at somewhere already mapped
1551f7cc78ecSespie   For private mappings, we should verify that changes cannot be read()
1552f7cc78ecSespie   back from the file, nor mmap's back from the file at a different
1553f7cc78ecSespie   address.  (There have been systems where private was not correctly
1554f7cc78ecSespie   implemented like the infamous i386 svr4.0, and systems where the
1555f7cc78ecSespie   VM page cache was not coherent with the filesystem buffer cache
1556f7cc78ecSespie   like early versions of FreeBSD and possibly contemporary NetBSD.)
1557f7cc78ecSespie   For shared mappings, we should conversely verify that changes get
1558f7cc78ecSespie   propogated back to all the places they're supposed to be.
1559f7cc78ecSespie
1560f7cc78ecSespie   Grep wants private fixed already mapped.
1561f7cc78ecSespie   The main things grep needs to know about mmap are:
1562f7cc78ecSespie   * does it exist and is it safe to write into the mmap'd area
1563f7cc78ecSespie   * how to use it (BSD variants)  */
1564f7cc78ecSespie#include <sys/types.h>
1565f7cc78ecSespie#include <fcntl.h>
1566f7cc78ecSespie#include <sys/mman.h>
1567f7cc78ecSespie
1568f7cc78ecSespie/* This mess was copied from the GNU getpagesize.h.  */
1569f7cc78ecSespie#ifndef HAVE_GETPAGESIZE
1570f7cc78ecSespie# ifdef HAVE_UNISTD_H
1571f7cc78ecSespie#  include <unistd.h>
1572f7cc78ecSespie# endif
1573f7cc78ecSespie
1574f7cc78ecSespie/* Assume that all systems that can run configure have sys/param.h.  */
1575f7cc78ecSespie# ifndef HAVE_SYS_PARAM_H
1576f7cc78ecSespie#  define HAVE_SYS_PARAM_H 1
1577f7cc78ecSespie# endif
1578f7cc78ecSespie
1579f7cc78ecSespie# ifdef _SC_PAGESIZE
1580f7cc78ecSespie#  define getpagesize() sysconf(_SC_PAGESIZE)
1581f7cc78ecSespie# else /* no _SC_PAGESIZE */
1582f7cc78ecSespie#  ifdef HAVE_SYS_PARAM_H
1583f7cc78ecSespie#   include <sys/param.h>
1584f7cc78ecSespie#   ifdef EXEC_PAGESIZE
1585f7cc78ecSespie#    define getpagesize() EXEC_PAGESIZE
1586f7cc78ecSespie#   else /* no EXEC_PAGESIZE */
1587f7cc78ecSespie#    ifdef NBPG
1588f7cc78ecSespie#     define getpagesize() NBPG * CLSIZE
1589f7cc78ecSespie#     ifndef CLSIZE
1590f7cc78ecSespie#      define CLSIZE 1
1591f7cc78ecSespie#     endif /* no CLSIZE */
1592f7cc78ecSespie#    else /* no NBPG */
1593f7cc78ecSespie#     ifdef NBPC
1594f7cc78ecSespie#      define getpagesize() NBPC
1595f7cc78ecSespie#     else /* no NBPC */
1596f7cc78ecSespie#      ifdef PAGESIZE
1597f7cc78ecSespie#       define getpagesize() PAGESIZE
1598f7cc78ecSespie#      endif /* PAGESIZE */
1599f7cc78ecSespie#     endif /* no NBPC */
1600f7cc78ecSespie#    endif /* no NBPG */
1601f7cc78ecSespie#   endif /* no EXEC_PAGESIZE */
1602f7cc78ecSespie#  else /* no HAVE_SYS_PARAM_H */
1603f7cc78ecSespie#   define getpagesize() 8192	/* punt totally */
1604f7cc78ecSespie#  endif /* no HAVE_SYS_PARAM_H */
1605f7cc78ecSespie# endif /* no _SC_PAGESIZE */
1606f7cc78ecSespie
1607f7cc78ecSespie#endif /* no HAVE_GETPAGESIZE */
1608f7cc78ecSespie
1609f7cc78ecSespie#ifdef __cplusplus
1610f7cc78ecSespieextern "C" { void *malloc(unsigned); }
1611f7cc78ecSespie#else
1612f7cc78ecSespiechar *malloc();
1613f7cc78ecSespie#endif
1614f7cc78ecSespie
1615f7cc78ecSespieint
1616f7cc78ecSespiemain()
1617f7cc78ecSespie{
1618f7cc78ecSespie	char *data, *data2, *data3;
1619f7cc78ecSespie	int i, pagesize;
1620f7cc78ecSespie	int fd;
1621f7cc78ecSespie
1622f7cc78ecSespie	pagesize = getpagesize();
1623f7cc78ecSespie
1624f7cc78ecSespie	/*
1625f7cc78ecSespie	 * First, make a file with some known garbage in it.
1626f7cc78ecSespie	 */
1627f7cc78ecSespie	data = malloc(pagesize);
1628f7cc78ecSespie	if (!data)
1629f7cc78ecSespie		exit(1);
1630f7cc78ecSespie	for (i = 0; i < pagesize; ++i)
1631f7cc78ecSespie		*(data + i) = rand();
1632f7cc78ecSespie	umask(0);
1633f7cc78ecSespie	fd = creat("conftestmmap", 0600);
1634f7cc78ecSespie	if (fd < 0)
1635f7cc78ecSespie		exit(1);
1636f7cc78ecSespie	if (write(fd, data, pagesize) != pagesize)
1637f7cc78ecSespie		exit(1);
1638f7cc78ecSespie	close(fd);
1639f7cc78ecSespie
1640f7cc78ecSespie	/*
1641f7cc78ecSespie	 * Next, try to mmap the file at a fixed address which
1642f7cc78ecSespie	 * already has something else allocated at it.  If we can,
1643f7cc78ecSespie	 * also make sure that we see the same garbage.
1644f7cc78ecSespie	 */
1645f7cc78ecSespie	fd = open("conftestmmap", O_RDWR);
1646f7cc78ecSespie	if (fd < 0)
1647f7cc78ecSespie		exit(1);
1648f7cc78ecSespie	data2 = malloc(2 * pagesize);
1649f7cc78ecSespie	if (!data2)
1650f7cc78ecSespie		exit(1);
1651f7cc78ecSespie	data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
1652f7cc78ecSespie	if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
1653f7cc78ecSespie	    MAP_PRIVATE | MAP_FIXED, fd, 0L))
1654f7cc78ecSespie		exit(1);
1655f7cc78ecSespie	for (i = 0; i < pagesize; ++i)
1656f7cc78ecSespie		if (*(data + i) != *(data2 + i))
1657f7cc78ecSespie			exit(1);
1658f7cc78ecSespie
1659f7cc78ecSespie	/*
1660f7cc78ecSespie	 * Finally, make sure that changes to the mapped area
1661f7cc78ecSespie	 * do not percolate back to the file as seen by read().
1662f7cc78ecSespie	 * (This is a bug on some variants of i386 svr4.0.)
1663f7cc78ecSespie	 */
1664f7cc78ecSespie	for (i = 0; i < pagesize; ++i)
1665f7cc78ecSespie		*(data2 + i) = *(data2 + i) + 1;
1666f7cc78ecSespie	data3 = malloc(pagesize);
1667f7cc78ecSespie	if (!data3)
1668f7cc78ecSespie		exit(1);
1669f7cc78ecSespie	if (read(fd, data3, pagesize) != pagesize)
1670f7cc78ecSespie		exit(1);
1671f7cc78ecSespie	for (i = 0; i < pagesize; ++i)
1672f7cc78ecSespie		if (*(data + i) != *(data3 + i))
1673f7cc78ecSespie			exit(1);
1674f7cc78ecSespie	close(fd);
1675f7cc78ecSespie	unlink("conftestmmap");
1676f7cc78ecSespie	exit(0);
1677f7cc78ecSespie}
1678f7cc78ecSespie
1679f7cc78ecSespieEOF
1680f7cc78ecSespieif { (eval echo configure:1681: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
1681f7cc78ecSespiethen
1682f7cc78ecSespie  ac_cv_func_mmap_fixed_mapped=yes
1683f7cc78ecSespieelse
1684f7cc78ecSespie  echo "configure: failed program was:" >&5
1685f7cc78ecSespie  cat conftest.$ac_ext >&5
1686f7cc78ecSespie  rm -fr conftest*
1687f7cc78ecSespie  ac_cv_func_mmap_fixed_mapped=no
1688f7cc78ecSespiefi
1689f7cc78ecSespierm -fr conftest*
1690f7cc78ecSespiefi
1691f7cc78ecSespie
1692f7cc78ecSespiefi
1693f7cc78ecSespie
1694f7cc78ecSespieecho "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
1695f7cc78ecSespieif test $ac_cv_func_mmap_fixed_mapped = yes; then
1696f7cc78ecSespie  cat >> confdefs.h <<\EOF
1697f7cc78ecSespie#define HAVE_MMAP 1
1698f7cc78ecSespieEOF
1699f7cc78ecSespie
1700f7cc78ecSespiefi
1701f7cc78ecSespie
1702f7cc78ecSespie
1703f7cc78ecSespie   for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \
1704f7cc78ecSespieunistd.h values.h sys/param.h
1705f7cc78ecSespiedo
1706f7cc78ecSespieac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1707f7cc78ecSespieecho $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1708f7cc78ecSespieecho "configure:1709: checking for $ac_hdr" >&5
1709f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1710f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1711f7cc78ecSespieelse
1712f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1713f7cc78ecSespie#line 1714 "configure"
1714f7cc78ecSespie#include "confdefs.h"
1715f7cc78ecSespie#include <$ac_hdr>
1716f7cc78ecSespieEOF
1717f7cc78ecSespieac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1718f7cc78ecSespie{ (eval echo configure:1719: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1719f7cc78ecSespieac_err=`grep -v '^ *+' conftest.out`
1720f7cc78ecSespieif test -z "$ac_err"; then
1721f7cc78ecSespie  rm -rf conftest*
1722f7cc78ecSespie  eval "ac_cv_header_$ac_safe=yes"
1723f7cc78ecSespieelse
1724f7cc78ecSespie  echo "$ac_err" >&5
1725f7cc78ecSespie  echo "configure: failed program was:" >&5
1726f7cc78ecSespie  cat conftest.$ac_ext >&5
1727f7cc78ecSespie  rm -rf conftest*
1728f7cc78ecSespie  eval "ac_cv_header_$ac_safe=no"
1729f7cc78ecSespiefi
1730f7cc78ecSespierm -f conftest*
1731f7cc78ecSespiefi
1732f7cc78ecSespieif eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1733f7cc78ecSespie  echo "$ac_t""yes" 1>&6
1734f7cc78ecSespie    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1735f7cc78ecSespie  cat >> confdefs.h <<EOF
1736f7cc78ecSespie#define $ac_tr_hdr 1
1737f7cc78ecSespieEOF
1738f7cc78ecSespie
1739f7cc78ecSespieelse
1740f7cc78ecSespie  echo "$ac_t""no" 1>&6
1741f7cc78ecSespiefi
1742f7cc78ecSespiedone
1743f7cc78ecSespie
1744f7cc78ecSespie   for ac_func in getcwd munmap putenv setenv setlocale strchr strcasecmp \
1745f7cc78ecSespie__argz_count __argz_stringify __argz_next
1746f7cc78ecSespiedo
1747f7cc78ecSespieecho $ac_n "checking for $ac_func""... $ac_c" 1>&6
1748f7cc78ecSespieecho "configure:1749: checking for $ac_func" >&5
1749f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1750f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1751f7cc78ecSespieelse
1752f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1753f7cc78ecSespie#line 1754 "configure"
1754f7cc78ecSespie#include "confdefs.h"
1755f7cc78ecSespie/* System header to define __stub macros and hopefully few prototypes,
1756f7cc78ecSespie    which can conflict with char $ac_func(); below.  */
1757f7cc78ecSespie#include <assert.h>
1758f7cc78ecSespie/* Override any gcc2 internal prototype to avoid an error.  */
1759f7cc78ecSespie/* We use char because int might match the return type of a gcc2
1760f7cc78ecSespie    builtin and then its argument prototype would still apply.  */
1761f7cc78ecSespiechar $ac_func();
1762f7cc78ecSespie
1763f7cc78ecSespieint main() {
1764f7cc78ecSespie
1765f7cc78ecSespie/* The GNU C library defines this for functions which it implements
1766f7cc78ecSespie    to always fail with ENOSYS.  Some functions are actually named
1767f7cc78ecSespie    something starting with __ and the normal name is an alias.  */
1768f7cc78ecSespie#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1769f7cc78ecSespiechoke me
1770f7cc78ecSespie#else
1771f7cc78ecSespie$ac_func();
1772f7cc78ecSespie#endif
1773f7cc78ecSespie
1774f7cc78ecSespie; return 0; }
1775f7cc78ecSespieEOF
1776f7cc78ecSespieif { (eval echo configure:1777: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1777f7cc78ecSespie  rm -rf conftest*
1778f7cc78ecSespie  eval "ac_cv_func_$ac_func=yes"
1779f7cc78ecSespieelse
1780f7cc78ecSespie  echo "configure: failed program was:" >&5
1781f7cc78ecSespie  cat conftest.$ac_ext >&5
1782f7cc78ecSespie  rm -rf conftest*
1783f7cc78ecSespie  eval "ac_cv_func_$ac_func=no"
1784f7cc78ecSespiefi
1785f7cc78ecSespierm -f conftest*
1786f7cc78ecSespiefi
1787f7cc78ecSespie
1788f7cc78ecSespieif eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1789f7cc78ecSespie  echo "$ac_t""yes" 1>&6
1790f7cc78ecSespie    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1791f7cc78ecSespie  cat >> confdefs.h <<EOF
1792f7cc78ecSespie#define $ac_tr_func 1
1793f7cc78ecSespieEOF
1794f7cc78ecSespie
1795f7cc78ecSespieelse
1796f7cc78ecSespie  echo "$ac_t""no" 1>&6
1797f7cc78ecSespiefi
1798f7cc78ecSespiedone
1799f7cc78ecSespie
1800f7cc78ecSespie
1801f7cc78ecSespie   if test "${ac_cv_func_stpcpy+set}" != "set"; then
1802f7cc78ecSespie     for ac_func in stpcpy
1803f7cc78ecSespiedo
1804f7cc78ecSespieecho $ac_n "checking for $ac_func""... $ac_c" 1>&6
1805f7cc78ecSespieecho "configure:1806: checking for $ac_func" >&5
1806f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
1807f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1808f7cc78ecSespieelse
1809f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1810f7cc78ecSespie#line 1811 "configure"
1811f7cc78ecSespie#include "confdefs.h"
1812f7cc78ecSespie/* System header to define __stub macros and hopefully few prototypes,
1813f7cc78ecSespie    which can conflict with char $ac_func(); below.  */
1814f7cc78ecSespie#include <assert.h>
1815f7cc78ecSespie/* Override any gcc2 internal prototype to avoid an error.  */
1816f7cc78ecSespie/* We use char because int might match the return type of a gcc2
1817f7cc78ecSespie    builtin and then its argument prototype would still apply.  */
1818f7cc78ecSespiechar $ac_func();
1819f7cc78ecSespie
1820f7cc78ecSespieint main() {
1821f7cc78ecSespie
1822f7cc78ecSespie/* The GNU C library defines this for functions which it implements
1823f7cc78ecSespie    to always fail with ENOSYS.  Some functions are actually named
1824f7cc78ecSespie    something starting with __ and the normal name is an alias.  */
1825f7cc78ecSespie#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
1826f7cc78ecSespiechoke me
1827f7cc78ecSespie#else
1828f7cc78ecSespie$ac_func();
1829f7cc78ecSespie#endif
1830f7cc78ecSespie
1831f7cc78ecSespie; return 0; }
1832f7cc78ecSespieEOF
1833f7cc78ecSespieif { (eval echo configure:1834: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1834f7cc78ecSespie  rm -rf conftest*
1835f7cc78ecSespie  eval "ac_cv_func_$ac_func=yes"
1836f7cc78ecSespieelse
1837f7cc78ecSespie  echo "configure: failed program was:" >&5
1838f7cc78ecSespie  cat conftest.$ac_ext >&5
1839f7cc78ecSespie  rm -rf conftest*
1840f7cc78ecSespie  eval "ac_cv_func_$ac_func=no"
1841f7cc78ecSespiefi
1842f7cc78ecSespierm -f conftest*
1843f7cc78ecSespiefi
1844f7cc78ecSespie
1845f7cc78ecSespieif eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
1846f7cc78ecSespie  echo "$ac_t""yes" 1>&6
1847f7cc78ecSespie    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
1848f7cc78ecSespie  cat >> confdefs.h <<EOF
1849f7cc78ecSespie#define $ac_tr_func 1
1850f7cc78ecSespieEOF
1851f7cc78ecSespie
1852f7cc78ecSespieelse
1853f7cc78ecSespie  echo "$ac_t""no" 1>&6
1854f7cc78ecSespiefi
1855f7cc78ecSespiedone
1856f7cc78ecSespie
1857f7cc78ecSespie   fi
1858f7cc78ecSespie   if test "${ac_cv_func_stpcpy}" = "yes"; then
1859f7cc78ecSespie     cat >> confdefs.h <<\EOF
1860f7cc78ecSespie#define HAVE_STPCPY 1
1861f7cc78ecSespieEOF
1862f7cc78ecSespie
1863f7cc78ecSespie   fi
1864f7cc78ecSespie
1865f7cc78ecSespie   if test $ac_cv_header_locale_h = yes; then
1866f7cc78ecSespie    echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
1867f7cc78ecSespieecho "configure:1868: checking for LC_MESSAGES" >&5
1868f7cc78ecSespieif eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
1869f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1870f7cc78ecSespieelse
1871f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1872f7cc78ecSespie#line 1873 "configure"
1873f7cc78ecSespie#include "confdefs.h"
1874f7cc78ecSespie#include <locale.h>
1875f7cc78ecSespieint main() {
1876f7cc78ecSespiereturn LC_MESSAGES
1877f7cc78ecSespie; return 0; }
1878f7cc78ecSespieEOF
1879f7cc78ecSespieif { (eval echo configure:1880: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1880f7cc78ecSespie  rm -rf conftest*
1881f7cc78ecSespie  am_cv_val_LC_MESSAGES=yes
1882f7cc78ecSespieelse
1883f7cc78ecSespie  echo "configure: failed program was:" >&5
1884f7cc78ecSespie  cat conftest.$ac_ext >&5
1885f7cc78ecSespie  rm -rf conftest*
1886f7cc78ecSespie  am_cv_val_LC_MESSAGES=no
1887f7cc78ecSespiefi
1888f7cc78ecSespierm -f conftest*
1889f7cc78ecSespiefi
1890f7cc78ecSespie
1891f7cc78ecSespieecho "$ac_t""$am_cv_val_LC_MESSAGES" 1>&6
1892f7cc78ecSespie    if test $am_cv_val_LC_MESSAGES = yes; then
1893f7cc78ecSespie      cat >> confdefs.h <<\EOF
1894f7cc78ecSespie#define HAVE_LC_MESSAGES 1
1895f7cc78ecSespieEOF
1896f7cc78ecSespie
1897f7cc78ecSespie    fi
1898f7cc78ecSespie  fi
1899f7cc78ecSespie   echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
1900f7cc78ecSespieecho "configure:1901: checking whether NLS is requested" >&5
1901f7cc78ecSespie        # Check whether --enable-nls or --disable-nls was given.
1902f7cc78ecSespieif test "${enable_nls+set}" = set; then
1903f7cc78ecSespie  enableval="$enable_nls"
1904f7cc78ecSespie  USE_NLS=$enableval
1905f7cc78ecSespieelse
1906f7cc78ecSespie  USE_NLS=yes
1907f7cc78ecSespiefi
1908f7cc78ecSespie
1909f7cc78ecSespie    echo "$ac_t""$USE_NLS" 1>&6
1910f7cc78ecSespie
1911f7cc78ecSespie
1912f7cc78ecSespie    USE_INCLUDED_LIBINTL=no
1913f7cc78ecSespie
1914f7cc78ecSespie        if test "$USE_NLS" = "yes"; then
1915f7cc78ecSespie      cat >> confdefs.h <<\EOF
1916f7cc78ecSespie#define ENABLE_NLS 1
1917f7cc78ecSespieEOF
1918f7cc78ecSespie
1919f7cc78ecSespie      echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
1920f7cc78ecSespieecho "configure:1921: checking whether included gettext is requested" >&5
1921f7cc78ecSespie      # Check whether --with-included-gettext or --without-included-gettext was given.
1922f7cc78ecSespieif test "${with_included_gettext+set}" = set; then
1923f7cc78ecSespie  withval="$with_included_gettext"
1924f7cc78ecSespie  nls_cv_force_use_gnu_gettext=$withval
1925f7cc78ecSespieelse
1926f7cc78ecSespie  nls_cv_force_use_gnu_gettext=no
1927f7cc78ecSespiefi
1928f7cc78ecSespie
1929f7cc78ecSespie      echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
1930f7cc78ecSespie
1931f7cc78ecSespie      nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
1932f7cc78ecSespie      if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
1933f7cc78ecSespie                        		nls_cv_header_intl=
1934f7cc78ecSespie	nls_cv_header_libgt=
1935f7cc78ecSespie	CATOBJEXT=NONE
1936f7cc78ecSespie
1937f7cc78ecSespie	ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
1938f7cc78ecSespieecho $ac_n "checking for libintl.h""... $ac_c" 1>&6
1939f7cc78ecSespieecho "configure:1940: checking for libintl.h" >&5
1940f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1941f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1942f7cc78ecSespieelse
1943f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1944f7cc78ecSespie#line 1945 "configure"
1945f7cc78ecSespie#include "confdefs.h"
1946f7cc78ecSespie#include <libintl.h>
1947f7cc78ecSespieEOF
1948f7cc78ecSespieac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1949f7cc78ecSespie{ (eval echo configure:1950: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1950f7cc78ecSespieac_err=`grep -v '^ *+' conftest.out`
1951f7cc78ecSespieif test -z "$ac_err"; then
1952f7cc78ecSespie  rm -rf conftest*
1953f7cc78ecSespie  eval "ac_cv_header_$ac_safe=yes"
1954f7cc78ecSespieelse
1955f7cc78ecSespie  echo "$ac_err" >&5
1956f7cc78ecSespie  echo "configure: failed program was:" >&5
1957f7cc78ecSespie  cat conftest.$ac_ext >&5
1958f7cc78ecSespie  rm -rf conftest*
1959f7cc78ecSespie  eval "ac_cv_header_$ac_safe=no"
1960f7cc78ecSespiefi
1961f7cc78ecSespierm -f conftest*
1962f7cc78ecSespiefi
1963f7cc78ecSespieif eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1964f7cc78ecSespie  echo "$ac_t""yes" 1>&6
1965f7cc78ecSespie  echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
1966f7cc78ecSespieecho "configure:1967: checking for gettext in libc" >&5
1967f7cc78ecSespieif eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
1968f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1969f7cc78ecSespieelse
1970f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
1971f7cc78ecSespie#line 1972 "configure"
1972f7cc78ecSespie#include "confdefs.h"
1973f7cc78ecSespie#include <libintl.h>
1974f7cc78ecSespieint main() {
1975f7cc78ecSespiereturn (int) gettext ("")
1976f7cc78ecSespie; return 0; }
1977f7cc78ecSespieEOF
1978f7cc78ecSespieif { (eval echo configure:1979: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
1979f7cc78ecSespie  rm -rf conftest*
1980f7cc78ecSespie  gt_cv_func_gettext_libc=yes
1981f7cc78ecSespieelse
1982f7cc78ecSespie  echo "configure: failed program was:" >&5
1983f7cc78ecSespie  cat conftest.$ac_ext >&5
1984f7cc78ecSespie  rm -rf conftest*
1985f7cc78ecSespie  gt_cv_func_gettext_libc=no
1986f7cc78ecSespiefi
1987f7cc78ecSespierm -f conftest*
1988f7cc78ecSespiefi
1989f7cc78ecSespie
1990f7cc78ecSespieecho "$ac_t""$gt_cv_func_gettext_libc" 1>&6
1991f7cc78ecSespie
1992f7cc78ecSespie	   if test "$gt_cv_func_gettext_libc" != "yes"; then
1993f7cc78ecSespie	     echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
1994f7cc78ecSespieecho "configure:1995: checking for bindtextdomain in -lintl" >&5
1995f7cc78ecSespieac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
1996f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1997f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
1998f7cc78ecSespieelse
1999f7cc78ecSespie  ac_save_LIBS="$LIBS"
2000f7cc78ecSespieLIBS="-lintl  $LIBS"
2001f7cc78ecSespiecat > conftest.$ac_ext <<EOF
2002f7cc78ecSespie#line 2003 "configure"
2003f7cc78ecSespie#include "confdefs.h"
2004f7cc78ecSespie/* Override any gcc2 internal prototype to avoid an error.  */
2005f7cc78ecSespie/* We use char because int might match the return type of a gcc2
2006f7cc78ecSespie    builtin and then its argument prototype would still apply.  */
2007f7cc78ecSespiechar bindtextdomain();
2008f7cc78ecSespie
2009f7cc78ecSespieint main() {
2010f7cc78ecSespiebindtextdomain()
2011f7cc78ecSespie; return 0; }
2012f7cc78ecSespieEOF
2013f7cc78ecSespieif { (eval echo configure:2014: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2014f7cc78ecSespie  rm -rf conftest*
2015f7cc78ecSespie  eval "ac_cv_lib_$ac_lib_var=yes"
2016f7cc78ecSespieelse
2017f7cc78ecSespie  echo "configure: failed program was:" >&5
2018f7cc78ecSespie  cat conftest.$ac_ext >&5
2019f7cc78ecSespie  rm -rf conftest*
2020f7cc78ecSespie  eval "ac_cv_lib_$ac_lib_var=no"
2021f7cc78ecSespiefi
2022f7cc78ecSespierm -f conftest*
2023f7cc78ecSespieLIBS="$ac_save_LIBS"
2024f7cc78ecSespie
2025f7cc78ecSespiefi
2026f7cc78ecSespieif eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2027f7cc78ecSespie  echo "$ac_t""yes" 1>&6
2028f7cc78ecSespie  echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
2029f7cc78ecSespieecho "configure:2030: checking for gettext in libintl" >&5
2030f7cc78ecSespieif eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
2031f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
2032f7cc78ecSespieelse
2033f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
2034f7cc78ecSespie#line 2035 "configure"
2035f7cc78ecSespie#include "confdefs.h"
2036f7cc78ecSespie
2037f7cc78ecSespieint main() {
2038f7cc78ecSespiereturn (int) gettext ("")
2039f7cc78ecSespie; return 0; }
2040f7cc78ecSespieEOF
2041f7cc78ecSespieif { (eval echo configure:2042: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2042f7cc78ecSespie  rm -rf conftest*
2043f7cc78ecSespie  gt_cv_func_gettext_libintl=yes
2044f7cc78ecSespieelse
2045f7cc78ecSespie  echo "configure: failed program was:" >&5
2046f7cc78ecSespie  cat conftest.$ac_ext >&5
2047f7cc78ecSespie  rm -rf conftest*
2048f7cc78ecSespie  gt_cv_func_gettext_libintl=no
2049f7cc78ecSespiefi
2050f7cc78ecSespierm -f conftest*
2051f7cc78ecSespiefi
2052f7cc78ecSespie
2053f7cc78ecSespieecho "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
2054f7cc78ecSespieelse
2055f7cc78ecSespie  echo "$ac_t""no" 1>&6
2056f7cc78ecSespiefi
2057f7cc78ecSespie
2058f7cc78ecSespie	   fi
2059f7cc78ecSespie
2060f7cc78ecSespie	   if test "$gt_cv_func_gettext_libc" = "yes" \
2061f7cc78ecSespie	      || test "$gt_cv_func_gettext_libintl" = "yes"; then
2062f7cc78ecSespie	      cat >> confdefs.h <<\EOF
2063f7cc78ecSespie#define HAVE_GETTEXT 1
2064f7cc78ecSespieEOF
2065f7cc78ecSespie
2066f7cc78ecSespie	      # Extract the first word of "msgfmt", so it can be a program name with args.
2067f7cc78ecSespieset dummy msgfmt; ac_word=$2
2068f7cc78ecSespieecho $ac_n "checking for $ac_word""... $ac_c" 1>&6
2069f7cc78ecSespieecho "configure:2070: checking for $ac_word" >&5
2070f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
2071f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
2072f7cc78ecSespieelse
2073f7cc78ecSespie  case "$MSGFMT" in
2074f7cc78ecSespie  /*)
2075f7cc78ecSespie  ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
2076f7cc78ecSespie  ;;
2077f7cc78ecSespie  *)
2078f7cc78ecSespie  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2079f7cc78ecSespie  for ac_dir in $PATH; do
2080f7cc78ecSespie    test -z "$ac_dir" && ac_dir=.
2081f7cc78ecSespie    if test -f $ac_dir/$ac_word; then
2082f7cc78ecSespie      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
2083f7cc78ecSespie	ac_cv_path_MSGFMT="$ac_dir/$ac_word"
2084f7cc78ecSespie	break
2085f7cc78ecSespie      fi
2086f7cc78ecSespie    fi
2087f7cc78ecSespie  done
2088f7cc78ecSespie  IFS="$ac_save_ifs"
2089f7cc78ecSespie  test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="no"
2090f7cc78ecSespie  ;;
2091f7cc78ecSespieesac
2092f7cc78ecSespiefi
2093f7cc78ecSespieMSGFMT="$ac_cv_path_MSGFMT"
2094f7cc78ecSespieif test -n "$MSGFMT"; then
2095f7cc78ecSespie  echo "$ac_t""$MSGFMT" 1>&6
2096f7cc78ecSespieelse
2097f7cc78ecSespie  echo "$ac_t""no" 1>&6
2098f7cc78ecSespiefi
2099f7cc78ecSespie	      if test "$MSGFMT" != "no"; then
2100f7cc78ecSespie		for ac_func in dcgettext
2101f7cc78ecSespiedo
2102f7cc78ecSespieecho $ac_n "checking for $ac_func""... $ac_c" 1>&6
2103f7cc78ecSespieecho "configure:2104: checking for $ac_func" >&5
2104f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2105f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
2106f7cc78ecSespieelse
2107f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
2108f7cc78ecSespie#line 2109 "configure"
2109f7cc78ecSespie#include "confdefs.h"
2110f7cc78ecSespie/* System header to define __stub macros and hopefully few prototypes,
2111f7cc78ecSespie    which can conflict with char $ac_func(); below.  */
2112f7cc78ecSespie#include <assert.h>
2113f7cc78ecSespie/* Override any gcc2 internal prototype to avoid an error.  */
2114f7cc78ecSespie/* We use char because int might match the return type of a gcc2
2115f7cc78ecSespie    builtin and then its argument prototype would still apply.  */
2116f7cc78ecSespiechar $ac_func();
2117f7cc78ecSespie
2118f7cc78ecSespieint main() {
2119f7cc78ecSespie
2120f7cc78ecSespie/* The GNU C library defines this for functions which it implements
2121f7cc78ecSespie    to always fail with ENOSYS.  Some functions are actually named
2122f7cc78ecSespie    something starting with __ and the normal name is an alias.  */
2123f7cc78ecSespie#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2124f7cc78ecSespiechoke me
2125f7cc78ecSespie#else
2126f7cc78ecSespie$ac_func();
2127f7cc78ecSespie#endif
2128f7cc78ecSespie
2129f7cc78ecSespie; return 0; }
2130f7cc78ecSespieEOF
2131f7cc78ecSespieif { (eval echo configure:2132: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2132f7cc78ecSespie  rm -rf conftest*
2133f7cc78ecSespie  eval "ac_cv_func_$ac_func=yes"
2134f7cc78ecSespieelse
2135f7cc78ecSespie  echo "configure: failed program was:" >&5
2136f7cc78ecSespie  cat conftest.$ac_ext >&5
2137f7cc78ecSespie  rm -rf conftest*
2138f7cc78ecSespie  eval "ac_cv_func_$ac_func=no"
2139f7cc78ecSespiefi
2140f7cc78ecSespierm -f conftest*
2141f7cc78ecSespiefi
2142f7cc78ecSespie
2143f7cc78ecSespieif eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2144f7cc78ecSespie  echo "$ac_t""yes" 1>&6
2145f7cc78ecSespie    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2146f7cc78ecSespie  cat >> confdefs.h <<EOF
2147f7cc78ecSespie#define $ac_tr_func 1
2148f7cc78ecSespieEOF
2149f7cc78ecSespie
2150f7cc78ecSespieelse
2151f7cc78ecSespie  echo "$ac_t""no" 1>&6
2152f7cc78ecSespiefi
2153f7cc78ecSespiedone
2154f7cc78ecSespie
2155f7cc78ecSespie		# Extract the first word of "gmsgfmt", so it can be a program name with args.
2156f7cc78ecSespieset dummy gmsgfmt; ac_word=$2
2157f7cc78ecSespieecho $ac_n "checking for $ac_word""... $ac_c" 1>&6
2158f7cc78ecSespieecho "configure:2159: checking for $ac_word" >&5
2159f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
2160f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
2161f7cc78ecSespieelse
2162f7cc78ecSespie  case "$GMSGFMT" in
2163f7cc78ecSespie  /*)
2164f7cc78ecSespie  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
2165f7cc78ecSespie  ;;
2166f7cc78ecSespie  ?:/*)
2167f7cc78ecSespie  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
2168f7cc78ecSespie  ;;
2169f7cc78ecSespie  *)
2170f7cc78ecSespie  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2171f7cc78ecSespie  for ac_dir in $PATH; do
2172f7cc78ecSespie    test -z "$ac_dir" && ac_dir=.
2173f7cc78ecSespie    if test -f $ac_dir/$ac_word; then
2174f7cc78ecSespie      ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
2175f7cc78ecSespie      break
2176f7cc78ecSespie    fi
2177f7cc78ecSespie  done
2178f7cc78ecSespie  IFS="$ac_save_ifs"
2179f7cc78ecSespie  test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
2180f7cc78ecSespie  ;;
2181f7cc78ecSespieesac
2182f7cc78ecSespiefi
2183f7cc78ecSespieGMSGFMT="$ac_cv_path_GMSGFMT"
2184f7cc78ecSespieif test -n "$GMSGFMT"; then
2185f7cc78ecSespie  echo "$ac_t""$GMSGFMT" 1>&6
2186f7cc78ecSespieelse
2187f7cc78ecSespie  echo "$ac_t""no" 1>&6
2188f7cc78ecSespiefi
2189f7cc78ecSespie
2190f7cc78ecSespie		# Extract the first word of "xgettext", so it can be a program name with args.
2191f7cc78ecSespieset dummy xgettext; ac_word=$2
2192f7cc78ecSespieecho $ac_n "checking for $ac_word""... $ac_c" 1>&6
2193f7cc78ecSespieecho "configure:2194: checking for $ac_word" >&5
2194f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
2195f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
2196f7cc78ecSespieelse
2197f7cc78ecSespie  case "$XGETTEXT" in
2198f7cc78ecSespie  /*)
2199f7cc78ecSespie  ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
2200f7cc78ecSespie  ;;
2201f7cc78ecSespie  *)
2202f7cc78ecSespie  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2203f7cc78ecSespie  for ac_dir in $PATH; do
2204f7cc78ecSespie    test -z "$ac_dir" && ac_dir=.
2205f7cc78ecSespie    if test -f $ac_dir/$ac_word; then
2206f7cc78ecSespie      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
2207f7cc78ecSespie	ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
2208f7cc78ecSespie	break
2209f7cc78ecSespie      fi
2210f7cc78ecSespie    fi
2211f7cc78ecSespie  done
2212f7cc78ecSespie  IFS="$ac_save_ifs"
2213f7cc78ecSespie  test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
2214f7cc78ecSespie  ;;
2215f7cc78ecSespieesac
2216f7cc78ecSespiefi
2217f7cc78ecSespieXGETTEXT="$ac_cv_path_XGETTEXT"
2218f7cc78ecSespieif test -n "$XGETTEXT"; then
2219f7cc78ecSespie  echo "$ac_t""$XGETTEXT" 1>&6
2220f7cc78ecSespieelse
2221f7cc78ecSespie  echo "$ac_t""no" 1>&6
2222f7cc78ecSespiefi
2223f7cc78ecSespie
2224f7cc78ecSespie		cat > conftest.$ac_ext <<EOF
2225f7cc78ecSespie#line 2226 "configure"
2226f7cc78ecSespie#include "confdefs.h"
2227f7cc78ecSespie
2228f7cc78ecSespieint main() {
2229f7cc78ecSespieextern int _nl_msg_cat_cntr;
2230f7cc78ecSespie			       return _nl_msg_cat_cntr
2231f7cc78ecSespie; return 0; }
2232f7cc78ecSespieEOF
2233f7cc78ecSespieif { (eval echo configure:2234: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
2234f7cc78ecSespie  rm -rf conftest*
2235f7cc78ecSespie  CATOBJEXT=.gmo
2236f7cc78ecSespie		   DATADIRNAME=share
2237f7cc78ecSespieelse
2238f7cc78ecSespie  echo "configure: failed program was:" >&5
2239f7cc78ecSespie  cat conftest.$ac_ext >&5
2240f7cc78ecSespie  rm -rf conftest*
2241f7cc78ecSespie  CATOBJEXT=.mo
2242f7cc78ecSespie		   DATADIRNAME=lib
2243f7cc78ecSespiefi
2244f7cc78ecSespierm -f conftest*
2245f7cc78ecSespie		INSTOBJEXT=.mo
2246f7cc78ecSespie	      fi
2247f7cc78ecSespie	    fi
2248f7cc78ecSespie
2249f7cc78ecSespieelse
2250f7cc78ecSespie  echo "$ac_t""no" 1>&6
2251f7cc78ecSespiefi
2252f7cc78ecSespie
2253f7cc78ecSespie
2254f7cc78ecSespie
2255f7cc78ecSespie        if test "$CATOBJEXT" = "NONE"; then
2256f7cc78ecSespie	  	  	  nls_cv_use_gnu_gettext=yes
2257f7cc78ecSespie        fi
2258f7cc78ecSespie      fi
2259f7cc78ecSespie
2260f7cc78ecSespie      if test "$nls_cv_use_gnu_gettext" = "yes"; then
2261f7cc78ecSespie                INTLOBJS="\$(GETTOBJS)"
2262f7cc78ecSespie        # Extract the first word of "msgfmt", so it can be a program name with args.
2263f7cc78ecSespieset dummy msgfmt; ac_word=$2
2264f7cc78ecSespieecho $ac_n "checking for $ac_word""... $ac_c" 1>&6
2265f7cc78ecSespieecho "configure:2266: checking for $ac_word" >&5
2266f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
2267f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
2268f7cc78ecSespieelse
2269f7cc78ecSespie  case "$MSGFMT" in
2270f7cc78ecSespie  /*)
2271f7cc78ecSespie  ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
2272f7cc78ecSespie  ;;
2273f7cc78ecSespie  *)
2274f7cc78ecSespie  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2275f7cc78ecSespie  for ac_dir in $PATH; do
2276f7cc78ecSespie    test -z "$ac_dir" && ac_dir=.
2277f7cc78ecSespie    if test -f $ac_dir/$ac_word; then
2278f7cc78ecSespie      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep 'dv '`"; then
2279f7cc78ecSespie	ac_cv_path_MSGFMT="$ac_dir/$ac_word"
2280f7cc78ecSespie	break
2281f7cc78ecSespie      fi
2282f7cc78ecSespie    fi
2283f7cc78ecSespie  done
2284f7cc78ecSespie  IFS="$ac_save_ifs"
2285f7cc78ecSespie  test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT="msgfmt"
2286f7cc78ecSespie  ;;
2287f7cc78ecSespieesac
2288f7cc78ecSespiefi
2289f7cc78ecSespieMSGFMT="$ac_cv_path_MSGFMT"
2290f7cc78ecSespieif test -n "$MSGFMT"; then
2291f7cc78ecSespie  echo "$ac_t""$MSGFMT" 1>&6
2292f7cc78ecSespieelse
2293f7cc78ecSespie  echo "$ac_t""no" 1>&6
2294f7cc78ecSespiefi
2295f7cc78ecSespie
2296f7cc78ecSespie        # Extract the first word of "gmsgfmt", so it can be a program name with args.
2297f7cc78ecSespieset dummy gmsgfmt; ac_word=$2
2298f7cc78ecSespieecho $ac_n "checking for $ac_word""... $ac_c" 1>&6
2299f7cc78ecSespieecho "configure:2300: checking for $ac_word" >&5
2300f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
2301f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
2302f7cc78ecSespieelse
2303f7cc78ecSespie  case "$GMSGFMT" in
2304f7cc78ecSespie  /*)
2305f7cc78ecSespie  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
2306f7cc78ecSespie  ;;
2307f7cc78ecSespie  ?:/*)
2308f7cc78ecSespie  ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a dos path.
2309f7cc78ecSespie  ;;
2310f7cc78ecSespie  *)
2311f7cc78ecSespie  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2312f7cc78ecSespie  for ac_dir in $PATH; do
2313f7cc78ecSespie    test -z "$ac_dir" && ac_dir=.
2314f7cc78ecSespie    if test -f $ac_dir/$ac_word; then
2315f7cc78ecSespie      ac_cv_path_GMSGFMT="$ac_dir/$ac_word"
2316f7cc78ecSespie      break
2317f7cc78ecSespie    fi
2318f7cc78ecSespie  done
2319f7cc78ecSespie  IFS="$ac_save_ifs"
2320f7cc78ecSespie  test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
2321f7cc78ecSespie  ;;
2322f7cc78ecSespieesac
2323f7cc78ecSespiefi
2324f7cc78ecSespieGMSGFMT="$ac_cv_path_GMSGFMT"
2325f7cc78ecSespieif test -n "$GMSGFMT"; then
2326f7cc78ecSespie  echo "$ac_t""$GMSGFMT" 1>&6
2327f7cc78ecSespieelse
2328f7cc78ecSespie  echo "$ac_t""no" 1>&6
2329f7cc78ecSespiefi
2330f7cc78ecSespie
2331f7cc78ecSespie        # Extract the first word of "xgettext", so it can be a program name with args.
2332f7cc78ecSespieset dummy xgettext; ac_word=$2
2333f7cc78ecSespieecho $ac_n "checking for $ac_word""... $ac_c" 1>&6
2334f7cc78ecSespieecho "configure:2335: checking for $ac_word" >&5
2335f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
2336f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
2337f7cc78ecSespieelse
2338f7cc78ecSespie  case "$XGETTEXT" in
2339f7cc78ecSespie  /*)
2340f7cc78ecSespie  ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
2341f7cc78ecSespie  ;;
2342f7cc78ecSespie  *)
2343f7cc78ecSespie  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS="${IFS}:"
2344f7cc78ecSespie  for ac_dir in $PATH; do
2345f7cc78ecSespie    test -z "$ac_dir" && ac_dir=.
2346f7cc78ecSespie    if test -f $ac_dir/$ac_word; then
2347f7cc78ecSespie      if test -z "`$ac_dir/$ac_word -h 2>&1 | grep '(HELP)'`"; then
2348f7cc78ecSespie	ac_cv_path_XGETTEXT="$ac_dir/$ac_word"
2349f7cc78ecSespie	break
2350f7cc78ecSespie      fi
2351f7cc78ecSespie    fi
2352f7cc78ecSespie  done
2353f7cc78ecSespie  IFS="$ac_save_ifs"
2354f7cc78ecSespie  test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
2355f7cc78ecSespie  ;;
2356f7cc78ecSespieesac
2357f7cc78ecSespiefi
2358f7cc78ecSespieXGETTEXT="$ac_cv_path_XGETTEXT"
2359f7cc78ecSespieif test -n "$XGETTEXT"; then
2360f7cc78ecSespie  echo "$ac_t""$XGETTEXT" 1>&6
2361f7cc78ecSespieelse
2362f7cc78ecSespie  echo "$ac_t""no" 1>&6
2363f7cc78ecSespiefi
2364f7cc78ecSespie
2365f7cc78ecSespie
2366f7cc78ecSespie	USE_INCLUDED_LIBINTL=yes
2367f7cc78ecSespie        CATOBJEXT=.gmo
2368f7cc78ecSespie        INSTOBJEXT=.mo
2369f7cc78ecSespie        DATADIRNAME=share
2370f7cc78ecSespie	INTLDEPS='$(top_builddir)/../intl/libintl.a'
2371f7cc78ecSespie	INTLLIBS=$INTLDEPS
2372f7cc78ecSespie	LIBS=`echo $LIBS | sed -e 's/-lintl//'`
2373f7cc78ecSespie        nls_cv_header_intl=libintl.h
2374f7cc78ecSespie        nls_cv_header_libgt=libgettext.h
2375f7cc78ecSespie      fi
2376f7cc78ecSespie
2377f7cc78ecSespie            if test "$XGETTEXT" != ":"; then
2378f7cc78ecSespie			if $XGETTEXT --omit-header /dev/null 2> /dev/null; then
2379f7cc78ecSespie	  : ;
2380f7cc78ecSespie	else
2381f7cc78ecSespie	  echo "$ac_t""found xgettext programs is not GNU xgettext; ignore it" 1>&6
2382f7cc78ecSespie	  XGETTEXT=":"
2383f7cc78ecSespie	fi
2384f7cc78ecSespie      fi
2385f7cc78ecSespie
2386f7cc78ecSespie      # We need to process the po/ directory.
2387f7cc78ecSespie      POSUB=po
2388f7cc78ecSespie    else
2389f7cc78ecSespie      DATADIRNAME=share
2390f7cc78ecSespie      nls_cv_header_intl=libintl.h
2391f7cc78ecSespie      nls_cv_header_libgt=libgettext.h
2392f7cc78ecSespie    fi
2393f7cc78ecSespie
2394f7cc78ecSespie    # If this is used in GNU gettext we have to set USE_NLS to `yes'
2395f7cc78ecSespie    # because some of the sources are only built for this goal.
2396f7cc78ecSespie    if test "$PACKAGE" = gettext; then
2397f7cc78ecSespie      USE_NLS=yes
2398f7cc78ecSespie      USE_INCLUDED_LIBINTL=yes
2399f7cc78ecSespie    fi
2400f7cc78ecSespie
2401f7cc78ecSespie                for lang in $ALL_LINGUAS; do
2402f7cc78ecSespie      GMOFILES="$GMOFILES $lang.gmo"
2403f7cc78ecSespie      POFILES="$POFILES $lang.po"
2404f7cc78ecSespie    done
2405f7cc78ecSespie
2406f7cc78ecSespie
2407f7cc78ecSespie
2408f7cc78ecSespie
2409f7cc78ecSespie
2410f7cc78ecSespie
2411f7cc78ecSespie
2412f7cc78ecSespie
2413f7cc78ecSespie
2414f7cc78ecSespie
2415f7cc78ecSespie
2416f7cc78ecSespie
2417f7cc78ecSespie
2418f7cc78ecSespie
2419f7cc78ecSespie   if test "x$CATOBJEXT" != "x"; then
2420f7cc78ecSespie     if test "x$ALL_LINGUAS" = "x"; then
2421f7cc78ecSespie       LINGUAS=
2422f7cc78ecSespie     else
2423f7cc78ecSespie       echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
2424f7cc78ecSespieecho "configure:2425: checking for catalogs to be installed" >&5
2425f7cc78ecSespie       NEW_LINGUAS=
2426f7cc78ecSespie       for lang in ${LINGUAS=$ALL_LINGUAS}; do
2427f7cc78ecSespie         case "$ALL_LINGUAS" in
2428f7cc78ecSespie          *$lang*) NEW_LINGUAS="$NEW_LINGUAS $lang" ;;
2429f7cc78ecSespie         esac
2430f7cc78ecSespie       done
2431f7cc78ecSespie       LINGUAS=$NEW_LINGUAS
2432f7cc78ecSespie       echo "$ac_t""$LINGUAS" 1>&6
2433f7cc78ecSespie     fi
2434f7cc78ecSespie
2435f7cc78ecSespie          if test -n "$LINGUAS"; then
2436f7cc78ecSespie       for lang in $LINGUAS; do CATALOGS="$CATALOGS $lang$CATOBJEXT"; done
2437f7cc78ecSespie     fi
2438f7cc78ecSespie   fi
2439f7cc78ecSespie
2440f7cc78ecSespie            if test $ac_cv_header_locale_h = yes; then
2441f7cc78ecSespie     INCLUDE_LOCALE_H="#include <locale.h>"
2442f7cc78ecSespie   else
2443f7cc78ecSespie     INCLUDE_LOCALE_H="\
2444f7cc78ecSespie/* The system does not provide the header <locale.h>.  Take care yourself.  */"
2445f7cc78ecSespie   fi
2446f7cc78ecSespie
2447f7cc78ecSespie
2448f7cc78ecSespie            if test -f $srcdir/po2tbl.sed.in; then
2449f7cc78ecSespie      if test "$CATOBJEXT" = ".cat"; then
2450f7cc78ecSespie	 ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
2451f7cc78ecSespieecho $ac_n "checking for linux/version.h""... $ac_c" 1>&6
2452f7cc78ecSespieecho "configure:2453: checking for linux/version.h" >&5
2453f7cc78ecSespieif eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2454f7cc78ecSespie  echo $ac_n "(cached) $ac_c" 1>&6
2455f7cc78ecSespieelse
2456f7cc78ecSespie  cat > conftest.$ac_ext <<EOF
2457f7cc78ecSespie#line 2458 "configure"
2458f7cc78ecSespie#include "confdefs.h"
2459f7cc78ecSespie#include <linux/version.h>
2460f7cc78ecSespieEOF
2461f7cc78ecSespieac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2462f7cc78ecSespie{ (eval echo configure:2463: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2463f7cc78ecSespieac_err=`grep -v '^ *+' conftest.out`
2464f7cc78ecSespieif test -z "$ac_err"; then
2465f7cc78ecSespie  rm -rf conftest*
2466f7cc78ecSespie  eval "ac_cv_header_$ac_safe=yes"
2467f7cc78ecSespieelse
2468f7cc78ecSespie  echo "$ac_err" >&5
2469f7cc78ecSespie  echo "configure: failed program was:" >&5
2470f7cc78ecSespie  cat conftest.$ac_ext >&5
2471f7cc78ecSespie  rm -rf conftest*
2472f7cc78ecSespie  eval "ac_cv_header_$ac_safe=no"
2473f7cc78ecSespiefi
2474f7cc78ecSespierm -f conftest*
2475f7cc78ecSespiefi
2476f7cc78ecSespieif eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2477f7cc78ecSespie  echo "$ac_t""yes" 1>&6
2478f7cc78ecSespie  msgformat=linux
2479f7cc78ecSespieelse
2480f7cc78ecSespie  echo "$ac_t""no" 1>&6
2481f7cc78ecSespiemsgformat=xopen
2482f7cc78ecSespiefi
2483f7cc78ecSespie
2484f7cc78ecSespie
2485f7cc78ecSespie	          	 sed -e '/^#/d' $srcdir/$msgformat-msg.sed > po2msg.sed
2486f7cc78ecSespie      fi
2487f7cc78ecSespie            sed -e '/^#.*[^\\]$/d' -e '/^#$/d' \
2488f7cc78ecSespie	 $srcdir/po2tbl.sed.in > po2tbl.sed
2489f7cc78ecSespie   fi
2490f7cc78ecSespie
2491f7cc78ecSespie            if test "$PACKAGE" = "gettext"; then
2492f7cc78ecSespie     GT_NO="#NO#"
2493f7cc78ecSespie     GT_YES=
2494f7cc78ecSespie   else
2495f7cc78ecSespie     GT_NO=
2496f7cc78ecSespie     GT_YES="#YES#"
2497f7cc78ecSespie   fi
2498f7cc78ecSespie
2499f7cc78ecSespie
2500f7cc78ecSespie
2501f7cc78ecSespie   MKINSTALLDIRS="\$(srcdir)/../../mkinstalldirs"
2502f7cc78ecSespie
2503f7cc78ecSespie
2504f7cc78ecSespie      l=
2505f7cc78ecSespie
2506f7cc78ecSespie
2507f7cc78ecSespie            if test -d $srcdir/po; then
2508f7cc78ecSespie      test -d po || mkdir po
2509f7cc78ecSespie      if test "x$srcdir" != "x."; then
2510f7cc78ecSespie	 if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
2511f7cc78ecSespie	    posrcprefix="$srcdir/"
2512f7cc78ecSespie	 else
2513f7cc78ecSespie	    posrcprefix="../$srcdir/"
2514f7cc78ecSespie	 fi
2515f7cc78ecSespie      else
2516f7cc78ecSespie	 posrcprefix="../"
2517f7cc78ecSespie      fi
2518f7cc78ecSespie      rm -f po/POTFILES
2519f7cc78ecSespie      sed -e "/^#/d" -e "/^\$/d" -e "s,.*,	$posrcprefix& \\\\," -e "\$s/\(.*\) \\\\/\1/" \
2520f7cc78ecSespie	 < $srcdir/po/POTFILES.in > po/POTFILES
2521f7cc78ecSespie   fi
2522f7cc78ecSespie
2523f7cc78ecSespie
2524f7cc78ecSespie
2525f7cc78ecSespietrap '' 1 2 15
2526f7cc78ecSespiecat > confcache <<\EOF
2527f7cc78ecSespie# This file is a shell script that caches the results of configure
2528f7cc78ecSespie# tests run on this system so they can be shared between configure
2529f7cc78ecSespie# scripts and configure runs.  It is not useful on other systems.
2530f7cc78ecSespie# If it contains results you don't want to keep, you may remove or edit it.
2531f7cc78ecSespie#
2532f7cc78ecSespie# By default, configure uses ./config.cache as the cache file,
2533f7cc78ecSespie# creating it if it does not exist already.  You can give configure
2534f7cc78ecSespie# the --cache-file=FILE option to use a different cache file; that is
2535f7cc78ecSespie# what configure does when it calls configure scripts in
2536f7cc78ecSespie# subdirectories, so they share the cache.
2537f7cc78ecSespie# Giving --cache-file=/dev/null disables caching, for debugging configure.
2538f7cc78ecSespie# config.status only pays attention to the cache file if you give it the
2539f7cc78ecSespie# --recheck option to rerun configure.
2540f7cc78ecSespie#
2541f7cc78ecSespieEOF
2542f7cc78ecSespie# The following way of writing the cache mishandles newlines in values,
2543f7cc78ecSespie# but we know of no workaround that is simple, portable, and efficient.
2544f7cc78ecSespie# So, don't put newlines in cache variables' values.
2545f7cc78ecSespie# Ultrix sh set writes to stderr and can't be redirected directly,
2546f7cc78ecSespie# and sets the high bit in the cache file unless we assign to the vars.
2547f7cc78ecSespie(set) 2>&1 |
2548f7cc78ecSespie  case `(ac_space=' '; set) 2>&1 | grep ac_space` in
2549f7cc78ecSespie  *ac_space=\ *)
2550f7cc78ecSespie    # `set' does not quote correctly, so add quotes (double-quote substitution
2551f7cc78ecSespie    # turns \\\\ into \\, and sed turns \\ into \).
2552f7cc78ecSespie    sed -n \
2553f7cc78ecSespie      -e "s/'/'\\\\''/g" \
2554f7cc78ecSespie      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
2555f7cc78ecSespie    ;;
2556f7cc78ecSespie  *)
2557f7cc78ecSespie    # `set' quotes correctly as required by POSIX, so do not add quotes.
2558f7cc78ecSespie    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
2559f7cc78ecSespie    ;;
2560f7cc78ecSespie  esac >> confcache
2561f7cc78ecSespieif cmp -s $cache_file confcache; then
2562f7cc78ecSespie  :
2563f7cc78ecSespieelse
2564f7cc78ecSespie  if test -w $cache_file; then
2565f7cc78ecSespie    echo "updating cache $cache_file"
2566f7cc78ecSespie    cat confcache > $cache_file
2567f7cc78ecSespie  else
2568f7cc78ecSespie    echo "not updating unwritable cache $cache_file"
2569f7cc78ecSespie  fi
2570f7cc78ecSespiefi
2571f7cc78ecSespierm -f confcache
2572f7cc78ecSespie
2573f7cc78ecSespietrap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
2574f7cc78ecSespie
2575f7cc78ecSespietest "x$prefix" = xNONE && prefix=$ac_default_prefix
2576f7cc78ecSespie# Let make expand exec_prefix.
2577f7cc78ecSespietest "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
2578f7cc78ecSespie
2579f7cc78ecSespie# Any assignment to VPATH causes Sun make to only execute
2580f7cc78ecSespie# the first set of double-colon rules, so remove it if not needed.
2581f7cc78ecSespie# If there is a colon in the path, we need to keep it.
2582f7cc78ecSespieif test "x$srcdir" = x.; then
2583f7cc78ecSespie  ac_vpsub='/^[ 	]*VPATH[ 	]*=[^:]*$/d'
2584f7cc78ecSespiefi
2585f7cc78ecSespie
2586f7cc78ecSespietrap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
2587f7cc78ecSespie
2588f7cc78ecSespieDEFS=-DHAVE_CONFIG_H
2589f7cc78ecSespie
2590f7cc78ecSespie# Without the "./", some shells look in PATH for config.status.
2591f7cc78ecSespie: ${CONFIG_STATUS=./config.status}
2592f7cc78ecSespie
2593f7cc78ecSespieecho creating $CONFIG_STATUS
2594f7cc78ecSespierm -f $CONFIG_STATUS
2595f7cc78ecSespiecat > $CONFIG_STATUS <<EOF
2596f7cc78ecSespie#! /bin/sh
2597f7cc78ecSespie# Generated automatically by configure.
2598f7cc78ecSespie# Run this file to recreate the current configuration.
2599f7cc78ecSespie# This directory was configured as follows,
2600f7cc78ecSespie# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
2601f7cc78ecSespie#
2602f7cc78ecSespie# $0 $ac_configure_args
2603f7cc78ecSespie#
2604f7cc78ecSespie# Compiler output produced by configure, useful for debugging
2605f7cc78ecSespie# configure, is in ./config.log if it exists.
2606f7cc78ecSespie
2607f7cc78ecSespieac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
2608f7cc78ecSespiefor ac_option
2609f7cc78ecSespiedo
2610f7cc78ecSespie  case "\$ac_option" in
2611f7cc78ecSespie  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
2612f7cc78ecSespie    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
2613f7cc78ecSespie    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
2614f7cc78ecSespie  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
2615f7cc78ecSespie    echo "$CONFIG_STATUS generated by autoconf version 2.12.1"
2616f7cc78ecSespie    exit 0 ;;
2617f7cc78ecSespie  -help | --help | --hel | --he | --h)
2618f7cc78ecSespie    echo "\$ac_cs_usage"; exit 0 ;;
2619f7cc78ecSespie  *) echo "\$ac_cs_usage"; exit 1 ;;
2620f7cc78ecSespie  esac
2621f7cc78ecSespiedone
2622f7cc78ecSespie
2623f7cc78ecSespieac_given_srcdir=$srcdir
2624f7cc78ecSespieac_given_INSTALL="$INSTALL"
2625f7cc78ecSespie
2626f7cc78ecSespietrap 'rm -fr `echo "Makefile config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
2627f7cc78ecSespieEOF
2628f7cc78ecSespiecat >> $CONFIG_STATUS <<EOF
2629f7cc78ecSespie
2630f7cc78ecSespie# Protect against being on the right side of a sed subst in config.status.
2631f7cc78ecSespiesed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
2632f7cc78ecSespie s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
2633f7cc78ecSespie$ac_vpsub
2634f7cc78ecSespie$extrasub
2635f7cc78ecSespies%@SHELL@%$SHELL%g
2636f7cc78ecSespies%@CFLAGS@%$CFLAGS%g
2637f7cc78ecSespies%@CPPFLAGS@%$CPPFLAGS%g
2638f7cc78ecSespies%@CXXFLAGS@%$CXXFLAGS%g
2639f7cc78ecSespies%@DEFS@%$DEFS%g
2640f7cc78ecSespies%@LDFLAGS@%$LDFLAGS%g
2641f7cc78ecSespies%@LIBS@%$LIBS%g
2642f7cc78ecSespies%@exec_prefix@%$exec_prefix%g
2643f7cc78ecSespies%@prefix@%$prefix%g
2644f7cc78ecSespies%@program_transform_name@%$program_transform_name%g
2645f7cc78ecSespies%@bindir@%$bindir%g
2646f7cc78ecSespies%@sbindir@%$sbindir%g
2647f7cc78ecSespies%@libexecdir@%$libexecdir%g
2648f7cc78ecSespies%@datadir@%$datadir%g
2649f7cc78ecSespies%@sysconfdir@%$sysconfdir%g
2650f7cc78ecSespies%@sharedstatedir@%$sharedstatedir%g
2651f7cc78ecSespies%@localstatedir@%$localstatedir%g
2652f7cc78ecSespies%@libdir@%$libdir%g
2653f7cc78ecSespies%@includedir@%$includedir%g
2654f7cc78ecSespies%@oldincludedir@%$oldincludedir%g
2655f7cc78ecSespies%@infodir@%$infodir%g
2656f7cc78ecSespies%@mandir@%$mandir%g
2657f7cc78ecSespies%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
2658f7cc78ecSespies%@INSTALL_DATA@%$INSTALL_DATA%g
2659f7cc78ecSespies%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
2660f7cc78ecSespies%@SET_MAKE@%$SET_MAKE%g
2661f7cc78ecSespies%@CC@%$CC%g
2662f7cc78ecSespies%@RANLIB@%$RANLIB%g
2663f7cc78ecSespies%@CPP@%$CPP%g
2664f7cc78ecSespies%@ALLOCA@%$ALLOCA%g
2665f7cc78ecSespies%@USE_NLS@%$USE_NLS%g
2666f7cc78ecSespies%@MSGFMT@%$MSGFMT%g
2667f7cc78ecSespies%@GMSGFMT@%$GMSGFMT%g
2668f7cc78ecSespies%@XGETTEXT@%$XGETTEXT%g
2669f7cc78ecSespies%@USE_INCLUDED_LIBINTL@%$USE_INCLUDED_LIBINTL%g
2670f7cc78ecSespies%@CATALOGS@%$CATALOGS%g
2671f7cc78ecSespies%@CATOBJEXT@%$CATOBJEXT%g
2672f7cc78ecSespies%@DATADIRNAME@%$DATADIRNAME%g
2673f7cc78ecSespies%@GMOFILES@%$GMOFILES%g
2674f7cc78ecSespies%@INSTOBJEXT@%$INSTOBJEXT%g
2675f7cc78ecSespies%@INTLDEPS@%$INTLDEPS%g
2676f7cc78ecSespies%@INTLLIBS@%$INTLLIBS%g
2677f7cc78ecSespies%@INTLOBJS@%$INTLOBJS%g
2678f7cc78ecSespies%@POFILES@%$POFILES%g
2679f7cc78ecSespies%@POSUB@%$POSUB%g
2680f7cc78ecSespies%@INCLUDE_LOCALE_H@%$INCLUDE_LOCALE_H%g
2681f7cc78ecSespies%@GT_NO@%$GT_NO%g
2682f7cc78ecSespies%@GT_YES@%$GT_YES%g
2683f7cc78ecSespies%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
2684f7cc78ecSespies%@l@%$l%g
2685f7cc78ecSespie
2686f7cc78ecSespieCEOF
2687f7cc78ecSespieEOF
2688f7cc78ecSespie
2689f7cc78ecSespiecat >> $CONFIG_STATUS <<\EOF
2690f7cc78ecSespie
2691f7cc78ecSespie# Split the substitutions into bite-sized pieces for seds with
2692f7cc78ecSespie# small command number limits, like on Digital OSF/1 and HP-UX.
2693f7cc78ecSespieac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
2694f7cc78ecSespieac_file=1 # Number of current file.
2695f7cc78ecSespieac_beg=1 # First line for current file.
2696f7cc78ecSespieac_end=$ac_max_sed_cmds # Line after last line for current file.
2697f7cc78ecSespieac_more_lines=:
2698f7cc78ecSespieac_sed_cmds=""
2699f7cc78ecSespiewhile $ac_more_lines; do
2700f7cc78ecSespie  if test $ac_beg -gt 1; then
2701f7cc78ecSespie    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
2702f7cc78ecSespie  else
2703f7cc78ecSespie    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
2704f7cc78ecSespie  fi
2705f7cc78ecSespie  if test ! -s conftest.s$ac_file; then
2706f7cc78ecSespie    ac_more_lines=false
2707f7cc78ecSespie    rm -f conftest.s$ac_file
2708f7cc78ecSespie  else
2709f7cc78ecSespie    if test -z "$ac_sed_cmds"; then
2710f7cc78ecSespie      ac_sed_cmds="sed -f conftest.s$ac_file"
2711f7cc78ecSespie    else
2712f7cc78ecSespie      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
2713f7cc78ecSespie    fi
2714f7cc78ecSespie    ac_file=`expr $ac_file + 1`
2715f7cc78ecSespie    ac_beg=$ac_end
2716f7cc78ecSespie    ac_end=`expr $ac_end + $ac_max_sed_cmds`
2717f7cc78ecSespie  fi
2718f7cc78ecSespiedone
2719f7cc78ecSespieif test -z "$ac_sed_cmds"; then
2720f7cc78ecSespie  ac_sed_cmds=cat
2721f7cc78ecSespiefi
2722f7cc78ecSespieEOF
2723f7cc78ecSespie
2724f7cc78ecSespiecat >> $CONFIG_STATUS <<EOF
2725f7cc78ecSespie
2726f7cc78ecSespieCONFIG_FILES=\${CONFIG_FILES-"Makefile"}
2727f7cc78ecSespieEOF
2728f7cc78ecSespiecat >> $CONFIG_STATUS <<\EOF
2729f7cc78ecSespiefor ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
2730f7cc78ecSespie  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2731f7cc78ecSespie  case "$ac_file" in
2732f7cc78ecSespie  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2733f7cc78ecSespie       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2734f7cc78ecSespie  *) ac_file_in="${ac_file}.in" ;;
2735f7cc78ecSespie  esac
2736f7cc78ecSespie
2737f7cc78ecSespie  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
2738f7cc78ecSespie
2739f7cc78ecSespie  # Remove last slash and all that follows it.  Not all systems have dirname.
2740f7cc78ecSespie  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2741f7cc78ecSespie  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2742f7cc78ecSespie    # The file is in a subdirectory.
2743f7cc78ecSespie    test ! -d "$ac_dir" && mkdir "$ac_dir"
2744f7cc78ecSespie    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
2745f7cc78ecSespie    # A "../" for each directory in $ac_dir_suffix.
2746f7cc78ecSespie    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
2747f7cc78ecSespie  else
2748f7cc78ecSespie    ac_dir_suffix= ac_dots=
2749f7cc78ecSespie  fi
2750f7cc78ecSespie
2751f7cc78ecSespie  case "$ac_given_srcdir" in
2752f7cc78ecSespie  .)  srcdir=.
2753f7cc78ecSespie      if test -z "$ac_dots"; then top_srcdir=.
2754f7cc78ecSespie      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
2755f7cc78ecSespie  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
2756f7cc78ecSespie  *) # Relative path.
2757f7cc78ecSespie    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
2758f7cc78ecSespie    top_srcdir="$ac_dots$ac_given_srcdir" ;;
2759f7cc78ecSespie  esac
2760f7cc78ecSespie
2761f7cc78ecSespie  case "$ac_given_INSTALL" in
2762f7cc78ecSespie  [/$]*) INSTALL="$ac_given_INSTALL" ;;
2763f7cc78ecSespie  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
2764f7cc78ecSespie  esac
2765f7cc78ecSespie
2766f7cc78ecSespie  echo creating "$ac_file"
2767f7cc78ecSespie  rm -f "$ac_file"
2768f7cc78ecSespie  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
2769f7cc78ecSespie  case "$ac_file" in
2770f7cc78ecSespie  *Makefile*) ac_comsub="1i\\
2771f7cc78ecSespie# $configure_input" ;;
2772f7cc78ecSespie  *) ac_comsub= ;;
2773f7cc78ecSespie  esac
2774f7cc78ecSespie
2775f7cc78ecSespie  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2776f7cc78ecSespie  sed -e "$ac_comsub
2777f7cc78ecSespies%@configure_input@%$configure_input%g
2778f7cc78ecSespies%@srcdir@%$srcdir%g
2779f7cc78ecSespies%@top_srcdir@%$top_srcdir%g
2780f7cc78ecSespies%@INSTALL@%$INSTALL%g
2781f7cc78ecSespie" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
2782f7cc78ecSespiefi; done
2783f7cc78ecSespierm -f conftest.s*
2784f7cc78ecSespie
2785f7cc78ecSespie# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
2786f7cc78ecSespie# NAME is the cpp macro being defined and VALUE is the value it is being given.
2787f7cc78ecSespie#
2788f7cc78ecSespie# ac_d sets the value in "#define NAME VALUE" lines.
2789f7cc78ecSespieac_dA='s%^\([ 	]*\)#\([ 	]*define[ 	][ 	]*\)'
2790f7cc78ecSespieac_dB='\([ 	][ 	]*\)[^ 	]*%\1#\2'
2791f7cc78ecSespieac_dC='\3'
2792f7cc78ecSespieac_dD='%g'
2793f7cc78ecSespie# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
2794f7cc78ecSespieac_uA='s%^\([ 	]*\)#\([ 	]*\)undef\([ 	][ 	]*\)'
2795f7cc78ecSespieac_uB='\([ 	]\)%\1#\2define\3'
2796f7cc78ecSespieac_uC=' '
2797f7cc78ecSespieac_uD='\4%g'
2798f7cc78ecSespie# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
2799f7cc78ecSespieac_eA='s%^\([ 	]*\)#\([ 	]*\)undef\([ 	][ 	]*\)'
2800f7cc78ecSespieac_eB='$%\1#\2define\3'
2801f7cc78ecSespieac_eC=' '
2802f7cc78ecSespieac_eD='%g'
2803f7cc78ecSespie
2804f7cc78ecSespieif test "${CONFIG_HEADERS+set}" != set; then
2805f7cc78ecSespieEOF
2806f7cc78ecSespiecat >> $CONFIG_STATUS <<EOF
2807f7cc78ecSespie  CONFIG_HEADERS="config.h:config.in"
2808f7cc78ecSespieEOF
2809f7cc78ecSespiecat >> $CONFIG_STATUS <<\EOF
2810f7cc78ecSespiefi
2811f7cc78ecSespiefor ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
2812f7cc78ecSespie  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
2813f7cc78ecSespie  case "$ac_file" in
2814f7cc78ecSespie  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
2815f7cc78ecSespie       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
2816f7cc78ecSespie  *) ac_file_in="${ac_file}.in" ;;
2817f7cc78ecSespie  esac
2818f7cc78ecSespie
2819f7cc78ecSespie  echo creating $ac_file
2820f7cc78ecSespie
2821f7cc78ecSespie  rm -f conftest.frag conftest.in conftest.out
2822f7cc78ecSespie  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
2823f7cc78ecSespie  cat $ac_file_inputs > conftest.in
2824f7cc78ecSespie
2825f7cc78ecSespieEOF
2826f7cc78ecSespie
2827f7cc78ecSespie# Transform confdefs.h into a sed script conftest.vals that substitutes
2828f7cc78ecSespie# the proper values into config.h.in to produce config.h.  And first:
2829f7cc78ecSespie# Protect against being on the right side of a sed subst in config.status.
2830f7cc78ecSespie# Protect against being in an unquoted here document in config.status.
2831f7cc78ecSespierm -f conftest.vals
2832f7cc78ecSespiecat > conftest.hdr <<\EOF
2833f7cc78ecSespies/[\\&%]/\\&/g
2834f7cc78ecSespies%[\\$`]%\\&%g
2835f7cc78ecSespies%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
2836f7cc78ecSespies%ac_d%ac_u%gp
2837f7cc78ecSespies%ac_u%ac_e%gp
2838f7cc78ecSespieEOF
2839f7cc78ecSespiesed -n -f conftest.hdr confdefs.h > conftest.vals
2840f7cc78ecSespierm -f conftest.hdr
2841f7cc78ecSespie
2842f7cc78ecSespie# This sed command replaces #undef with comments.  This is necessary, for
2843f7cc78ecSespie# example, in the case of _POSIX_SOURCE, which is predefined and required
2844f7cc78ecSespie# on some systems where configure will not decide to define it.
2845f7cc78ecSespiecat >> conftest.vals <<\EOF
2846f7cc78ecSespies%^[ 	]*#[ 	]*undef[ 	][ 	]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
2847f7cc78ecSespieEOF
2848f7cc78ecSespie
2849f7cc78ecSespie# Break up conftest.vals because some shells have a limit on
2850f7cc78ecSespie# the size of here documents, and old seds have small limits too.
2851f7cc78ecSespie
2852f7cc78ecSespierm -f conftest.tail
2853f7cc78ecSespiewhile :
2854f7cc78ecSespiedo
2855f7cc78ecSespie  ac_lines=`grep -c . conftest.vals`
2856f7cc78ecSespie  # grep -c gives empty output for an empty file on some AIX systems.
2857f7cc78ecSespie  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
2858f7cc78ecSespie  # Write a limited-size here document to conftest.frag.
2859f7cc78ecSespie  echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
2860f7cc78ecSespie  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
2861f7cc78ecSespie  echo 'CEOF
2862f7cc78ecSespie  sed -f conftest.frag conftest.in > conftest.out
2863f7cc78ecSespie  rm -f conftest.in
2864f7cc78ecSespie  mv conftest.out conftest.in
2865f7cc78ecSespie' >> $CONFIG_STATUS
2866f7cc78ecSespie  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
2867f7cc78ecSespie  rm -f conftest.vals
2868f7cc78ecSespie  mv conftest.tail conftest.vals
2869f7cc78ecSespiedone
2870f7cc78ecSespierm -f conftest.vals
2871f7cc78ecSespie
2872f7cc78ecSespiecat >> $CONFIG_STATUS <<\EOF
2873f7cc78ecSespie  rm -f conftest.frag conftest.h
2874f7cc78ecSespie  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
2875f7cc78ecSespie  cat conftest.in >> conftest.h
2876f7cc78ecSespie  rm -f conftest.in
2877f7cc78ecSespie  if cmp -s $ac_file conftest.h 2>/dev/null; then
2878f7cc78ecSespie    echo "$ac_file is unchanged"
2879f7cc78ecSespie    rm -f conftest.h
2880f7cc78ecSespie  else
2881f7cc78ecSespie    # Remove last slash and all that follows it.  Not all systems have dirname.
2882f7cc78ecSespie      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
2883f7cc78ecSespie      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
2884f7cc78ecSespie      # The file is in a subdirectory.
2885f7cc78ecSespie      test ! -d "$ac_dir" && mkdir "$ac_dir"
2886f7cc78ecSespie    fi
2887f7cc78ecSespie    rm -f $ac_file
2888f7cc78ecSespie    mv conftest.h $ac_file
2889f7cc78ecSespie  fi
2890f7cc78ecSespiefi; done
2891f7cc78ecSespie
2892f7cc78ecSespieEOF
2893f7cc78ecSespie
2894f7cc78ecSespiecat >> $CONFIG_STATUS <<EOF
2895f7cc78ecSespieac_sources="$nls_cv_header_libgt"
2896f7cc78ecSespieac_dests="$nls_cv_header_intl"
2897f7cc78ecSespieEOF
2898f7cc78ecSespie
2899f7cc78ecSespiecat >> $CONFIG_STATUS <<\EOF
2900f7cc78ecSespiesrcdir=$ac_given_srcdir
2901f7cc78ecSespiewhile test -n "$ac_sources"; do
2902f7cc78ecSespie  set $ac_dests; ac_dest=$1; shift; ac_dests=$*
2903f7cc78ecSespie  set $ac_sources; ac_source=$1; shift; ac_sources=$*
2904f7cc78ecSespie
2905f7cc78ecSespie  echo "linking $srcdir/$ac_source to $ac_dest"
2906f7cc78ecSespie
2907f7cc78ecSespie  if test ! -r $srcdir/$ac_source; then
2908f7cc78ecSespie    { echo "configure: error: $srcdir/$ac_source: File not found" 1>&2; exit 1; }
2909f7cc78ecSespie  fi
2910f7cc78ecSespie  rm -f $ac_dest
2911f7cc78ecSespie
2912f7cc78ecSespie  # Make relative symlinks.
2913f7cc78ecSespie  # Remove last slash and all that follows it.  Not all systems have dirname.
2914f7cc78ecSespie  ac_dest_dir=`echo $ac_dest|sed 's%/[^/][^/]*$%%'`
2915f7cc78ecSespie  if test "$ac_dest_dir" != "$ac_dest" && test "$ac_dest_dir" != .; then
2916f7cc78ecSespie    # The dest file is in a subdirectory.
2917f7cc78ecSespie    test ! -d "$ac_dest_dir" && mkdir "$ac_dest_dir"
2918f7cc78ecSespie    ac_dest_dir_suffix="/`echo $ac_dest_dir|sed 's%^\./%%'`"
2919f7cc78ecSespie    # A "../" for each directory in $ac_dest_dir_suffix.
2920f7cc78ecSespie    ac_dots=`echo $ac_dest_dir_suffix|sed 's%/[^/]*%../%g'`
2921f7cc78ecSespie  else
2922f7cc78ecSespie    ac_dest_dir_suffix= ac_dots=
2923f7cc78ecSespie  fi
2924f7cc78ecSespie
2925f7cc78ecSespie  case "$srcdir" in
2926f7cc78ecSespie  [/$]*) ac_rel_source="$srcdir/$ac_source" ;;
2927f7cc78ecSespie  *) ac_rel_source="$ac_dots$srcdir/$ac_source" ;;
2928f7cc78ecSespie  esac
2929f7cc78ecSespie
2930f7cc78ecSespie  # Make a symlink if possible; otherwise try a hard link.
2931f7cc78ecSespie  if ln -s $ac_rel_source $ac_dest 2>/dev/null ||
2932f7cc78ecSespie    ln $srcdir/$ac_source $ac_dest; then :
2933f7cc78ecSespie  else
2934f7cc78ecSespie    { echo "configure: error: can not link $ac_dest to $srcdir/$ac_source" 1>&2; exit 1; }
2935f7cc78ecSespie  fi
2936f7cc78ecSespiedone
2937f7cc78ecSespieEOF
2938f7cc78ecSespiecat >> $CONFIG_STATUS <<EOF
2939f7cc78ecSespie
2940f7cc78ecSespie
2941f7cc78ecSespieEOF
2942f7cc78ecSespiecat >> $CONFIG_STATUS <<\EOF
2943f7cc78ecSespietest -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
2944f7cc78ecSespie
2945f7cc78ecSespieexit 0
2946f7cc78ecSespieEOF
2947f7cc78ecSespiechmod +x $CONFIG_STATUS
2948f7cc78ecSespierm -fr confdefs* $ac_clean_files
2949f7cc78ecSespietest "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
2950f7cc78ecSespie
2951