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