Patches from lvaro Lopes <alvieboy@alvie.com> to fix usage
[zpugcc.git] / toolchain / gcc / configure
blob8aa309f2410604059cbc8622ef30cb63dd029bf6
1 #! /bin/sh
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated automatically using autoconf version 2.13
5 # Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
10 # Defaults:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_help="$ac_help
15 --enable-serial-[{host,target,build}-]configure
16 Force sequential configuration of
17 sub-packages for the host, target or build
18 machine, or all sub-packages"
19 ac_help="$ac_help
20 --enable-maintainer-mode enable make rules and dependencies not useful
21 (and sometimes confusing) to the casual installer"
23 # Initialize some variables set by options.
24 # The variables have the same names as the options, with
25 # dashes changed to underlines.
26 build=NONE
27 cache_file=./config.cache
28 exec_prefix=NONE
29 host=NONE
30 no_create=
31 nonopt=NONE
32 no_recursion=
33 prefix=NONE
34 program_prefix=NONE
35 program_suffix=NONE
36 program_transform_name=s,x,x,
37 silent=
38 site=
39 srcdir=
40 target=NONE
41 verbose=
42 x_includes=NONE
43 x_libraries=NONE
44 bindir='${exec_prefix}/bin'
45 sbindir='${exec_prefix}/sbin'
46 libexecdir='${exec_prefix}/libexec'
47 datadir='${prefix}/share'
48 sysconfdir='${prefix}/etc'
49 sharedstatedir='${prefix}/com'
50 localstatedir='${prefix}/var'
51 libdir='${exec_prefix}/lib'
52 includedir='${prefix}/include'
53 oldincludedir='/usr/include'
54 infodir='${prefix}/info'
55 mandir='${prefix}/man'
57 # Initialize some other variables.
58 subdirs=
59 MFLAGS= MAKEFLAGS=
60 SHELL=${CONFIG_SHELL-/bin/sh}
61 # Maximum number of lines to put in a shell here document.
62 ac_max_here_lines=12
64 ac_prev=
65 for ac_option
68 # If the previous option needs an argument, assign it.
69 if test -n "$ac_prev"; then
70 eval "$ac_prev=\$ac_option"
71 ac_prev=
72 continue
75 case "$ac_option" in
76 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
77 *) ac_optarg= ;;
78 esac
80 # Accept the important Cygnus configure options, so we can diagnose typos.
82 case "$ac_option" in
84 -bindir | --bindir | --bindi | --bind | --bin | --bi)
85 ac_prev=bindir ;;
86 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
87 bindir="$ac_optarg" ;;
89 -build | --build | --buil | --bui | --bu)
90 ac_prev=build ;;
91 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
92 build="$ac_optarg" ;;
94 -cache-file | --cache-file | --cache-fil | --cache-fi \
95 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
96 ac_prev=cache_file ;;
97 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
98 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
99 cache_file="$ac_optarg" ;;
101 -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
102 ac_prev=datadir ;;
103 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
104 | --da=*)
105 datadir="$ac_optarg" ;;
107 -disable-* | --disable-*)
108 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
109 # Reject names that are not valid shell variable names.
110 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
111 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
113 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
114 eval "enable_${ac_feature}=no" ;;
116 -enable-* | --enable-*)
117 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
118 # Reject names that are not valid shell variable names.
119 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
120 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
122 ac_feature=`echo $ac_feature| sed 's/-/_/g'`
123 case "$ac_option" in
124 *=*) ;;
125 *) ac_optarg=yes ;;
126 esac
127 eval "enable_${ac_feature}='$ac_optarg'" ;;
129 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
130 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
131 | --exec | --exe | --ex)
132 ac_prev=exec_prefix ;;
133 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
134 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
135 | --exec=* | --exe=* | --ex=*)
136 exec_prefix="$ac_optarg" ;;
138 -gas | --gas | --ga | --g)
139 # Obsolete; use --with-gas.
140 with_gas=yes ;;
142 -help | --help | --hel | --he)
143 # Omit some internal or obsolete options to make the list less imposing.
144 # This message is too long to be a string in the A/UX 3.1 sh.
145 cat << EOF
146 Usage: configure [options] [host]
147 Options: [defaults in brackets after descriptions]
148 Configuration:
149 --cache-file=FILE cache test results in FILE
150 --help print this message
151 --no-create do not create output files
152 --quiet, --silent do not print \`checking...' messages
153 --version print the version of autoconf that created configure
154 Directory and file names:
155 --prefix=PREFIX install architecture-independent files in PREFIX
156 [$ac_default_prefix]
157 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
158 [same as prefix]
159 --bindir=DIR user executables in DIR [EPREFIX/bin]
160 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
161 --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
162 --datadir=DIR read-only architecture-independent data in DIR
163 [PREFIX/share]
164 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
165 --sharedstatedir=DIR modifiable architecture-independent data in DIR
166 [PREFIX/com]
167 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
168 --libdir=DIR object code libraries in DIR [EPREFIX/lib]
169 --includedir=DIR C header files in DIR [PREFIX/include]
170 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
171 --infodir=DIR info documentation in DIR [PREFIX/info]
172 --mandir=DIR man documentation in DIR [PREFIX/man]
173 --srcdir=DIR find the sources in DIR [configure dir or ..]
174 --program-prefix=PREFIX prepend PREFIX to installed program names
175 --program-suffix=SUFFIX append SUFFIX to installed program names
176 --program-transform-name=PROGRAM
177 run sed PROGRAM on installed program names
179 cat << EOF
180 Host type:
181 --build=BUILD configure for building on BUILD [BUILD=HOST]
182 --host=HOST configure for HOST [guessed]
183 --target=TARGET configure for TARGET [TARGET=HOST]
184 Features and packages:
185 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
186 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
187 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
188 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
189 --x-includes=DIR X include files are in DIR
190 --x-libraries=DIR X library files are in DIR
192 if test -n "$ac_help"; then
193 echo "--enable and --with options recognized:$ac_help"
195 exit 0 ;;
197 -host | --host | --hos | --ho)
198 ac_prev=host ;;
199 -host=* | --host=* | --hos=* | --ho=*)
200 host="$ac_optarg" ;;
202 -includedir | --includedir | --includedi | --included | --include \
203 | --includ | --inclu | --incl | --inc)
204 ac_prev=includedir ;;
205 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
206 | --includ=* | --inclu=* | --incl=* | --inc=*)
207 includedir="$ac_optarg" ;;
209 -infodir | --infodir | --infodi | --infod | --info | --inf)
210 ac_prev=infodir ;;
211 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
212 infodir="$ac_optarg" ;;
214 -libdir | --libdir | --libdi | --libd)
215 ac_prev=libdir ;;
216 -libdir=* | --libdir=* | --libdi=* | --libd=*)
217 libdir="$ac_optarg" ;;
219 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
220 | --libexe | --libex | --libe)
221 ac_prev=libexecdir ;;
222 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
223 | --libexe=* | --libex=* | --libe=*)
224 libexecdir="$ac_optarg" ;;
226 -localstatedir | --localstatedir | --localstatedi | --localstated \
227 | --localstate | --localstat | --localsta | --localst \
228 | --locals | --local | --loca | --loc | --lo)
229 ac_prev=localstatedir ;;
230 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
231 | --localstate=* | --localstat=* | --localsta=* | --localst=* \
232 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
233 localstatedir="$ac_optarg" ;;
235 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
236 ac_prev=mandir ;;
237 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
238 mandir="$ac_optarg" ;;
240 -nfp | --nfp | --nf)
241 # Obsolete; use --without-fp.
242 with_fp=no ;;
244 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
245 | --no-cr | --no-c)
246 no_create=yes ;;
248 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
249 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
250 no_recursion=yes ;;
252 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
253 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
254 | --oldin | --oldi | --old | --ol | --o)
255 ac_prev=oldincludedir ;;
256 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
257 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
258 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
259 oldincludedir="$ac_optarg" ;;
261 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
262 ac_prev=prefix ;;
263 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
264 prefix="$ac_optarg" ;;
266 -program-prefix | --program-prefix | --program-prefi | --program-pref \
267 | --program-pre | --program-pr | --program-p)
268 ac_prev=program_prefix ;;
269 -program-prefix=* | --program-prefix=* | --program-prefi=* \
270 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
271 program_prefix="$ac_optarg" ;;
273 -program-suffix | --program-suffix | --program-suffi | --program-suff \
274 | --program-suf | --program-su | --program-s)
275 ac_prev=program_suffix ;;
276 -program-suffix=* | --program-suffix=* | --program-suffi=* \
277 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
278 program_suffix="$ac_optarg" ;;
280 -program-transform-name | --program-transform-name \
281 | --program-transform-nam | --program-transform-na \
282 | --program-transform-n | --program-transform- \
283 | --program-transform | --program-transfor \
284 | --program-transfo | --program-transf \
285 | --program-trans | --program-tran \
286 | --progr-tra | --program-tr | --program-t)
287 ac_prev=program_transform_name ;;
288 -program-transform-name=* | --program-transform-name=* \
289 | --program-transform-nam=* | --program-transform-na=* \
290 | --program-transform-n=* | --program-transform-=* \
291 | --program-transform=* | --program-transfor=* \
292 | --program-transfo=* | --program-transf=* \
293 | --program-trans=* | --program-tran=* \
294 | --progr-tra=* | --program-tr=* | --program-t=*)
295 program_transform_name="$ac_optarg" ;;
297 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
298 | -silent | --silent | --silen | --sile | --sil)
299 silent=yes ;;
301 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
302 ac_prev=sbindir ;;
303 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
304 | --sbi=* | --sb=*)
305 sbindir="$ac_optarg" ;;
307 -sharedstatedir | --sharedstatedir | --sharedstatedi \
308 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
309 | --sharedst | --shareds | --shared | --share | --shar \
310 | --sha | --sh)
311 ac_prev=sharedstatedir ;;
312 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
313 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
314 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
315 | --sha=* | --sh=*)
316 sharedstatedir="$ac_optarg" ;;
318 -site | --site | --sit)
319 ac_prev=site ;;
320 -site=* | --site=* | --sit=*)
321 site="$ac_optarg" ;;
323 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
324 ac_prev=srcdir ;;
325 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
326 srcdir="$ac_optarg" ;;
328 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
329 | --syscon | --sysco | --sysc | --sys | --sy)
330 ac_prev=sysconfdir ;;
331 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
332 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
333 sysconfdir="$ac_optarg" ;;
335 -target | --target | --targe | --targ | --tar | --ta | --t)
336 ac_prev=target ;;
337 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
338 target="$ac_optarg" ;;
340 -v | -verbose | --verbose | --verbos | --verbo | --verb)
341 verbose=yes ;;
343 -version | --version | --versio | --versi | --vers)
344 echo "configure generated by autoconf version 2.13"
345 exit 0 ;;
347 -with-* | --with-*)
348 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
349 # Reject names that are not valid shell variable names.
350 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
351 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
353 ac_package=`echo $ac_package| sed 's/-/_/g'`
354 case "$ac_option" in
355 *=*) ;;
356 *) ac_optarg=yes ;;
357 esac
358 eval "with_${ac_package}='$ac_optarg'" ;;
360 -without-* | --without-*)
361 ac_package=`echo $ac_option|sed -e 's/-*without-//'`
362 # Reject names that are not valid shell variable names.
363 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
364 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
366 ac_package=`echo $ac_package| sed 's/-/_/g'`
367 eval "with_${ac_package}=no" ;;
369 --x)
370 # Obsolete; use --with-x.
371 with_x=yes ;;
373 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
374 | --x-incl | --x-inc | --x-in | --x-i)
375 ac_prev=x_includes ;;
376 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
377 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
378 x_includes="$ac_optarg" ;;
380 -x-libraries | --x-libraries | --x-librarie | --x-librari \
381 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
382 ac_prev=x_libraries ;;
383 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
384 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
385 x_libraries="$ac_optarg" ;;
387 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
391 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
392 echo "configure: warning: $ac_option: invalid host type" 1>&2
394 if test "x$nonopt" != xNONE; then
395 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
397 nonopt="$ac_option"
400 esac
401 done
403 if test -n "$ac_prev"; then
404 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
407 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
409 # File descriptor usage:
410 # 0 standard input
411 # 1 file creation
412 # 2 errors and warnings
413 # 3 some systems may open it to /dev/tty
414 # 4 used on the Kubota Titan
415 # 6 checking for... messages and results
416 # 5 compiler messages saved in config.log
417 if test "$silent" = yes; then
418 exec 6>/dev/null
419 else
420 exec 6>&1
422 exec 5>./config.log
424 echo "\
425 This file contains any messages produced by compilers while
426 running configure, to aid debugging if configure makes a mistake.
427 " 1>&5
429 # Strip out --no-create and --no-recursion so they do not pile up.
430 # Also quote any args containing shell metacharacters.
431 ac_configure_args=
432 for ac_arg
434 case "$ac_arg" in
435 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
436 | --no-cr | --no-c) ;;
437 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
438 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
439 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
440 ac_configure_args="$ac_configure_args '$ac_arg'" ;;
441 *) ac_configure_args="$ac_configure_args $ac_arg" ;;
442 esac
443 done
445 # NLS nuisances.
446 # Only set these to C if already set. These must not be set unconditionally
447 # because not all systems understand e.g. LANG=C (notably SCO).
448 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
449 # Non-C LC_CTYPE values break the ctype check.
450 if test "${LANG+set}" = set; then LANG=C; export LANG; fi
451 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
452 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
453 if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
455 # confdefs.h avoids OS command line length limits that DEFS can exceed.
456 rm -rf conftest* confdefs.h
457 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
458 echo > confdefs.h
460 # A filename unique to this package, relative to the directory that
461 # configure is in, which we can look for to find out if srcdir is correct.
462 ac_unique_file=move-if-change
464 # Find the source files, if location was not specified.
465 if test -z "$srcdir"; then
466 ac_srcdir_defaulted=yes
467 # Try the directory containing this script, then its parent.
468 ac_prog=$0
469 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
470 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
471 srcdir=$ac_confdir
472 if test ! -r $srcdir/$ac_unique_file; then
473 srcdir=..
475 else
476 ac_srcdir_defaulted=no
478 if test ! -r $srcdir/$ac_unique_file; then
479 if test "$ac_srcdir_defaulted" = yes; then
480 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
481 else
482 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
485 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
487 # Prefer explicitly selected file to automatically selected ones.
488 if test -z "$CONFIG_SITE"; then
489 if test "x$prefix" != xNONE; then
490 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
491 else
492 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
495 for ac_site_file in $CONFIG_SITE; do
496 if test -r "$ac_site_file"; then
497 echo "loading site script $ac_site_file"
498 . "$ac_site_file"
500 done
502 if test -r "$cache_file"; then
503 echo "loading cache $cache_file"
504 . $cache_file
505 else
506 echo "creating cache $cache_file"
507 > $cache_file
510 ac_ext=c
511 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
512 ac_cpp='$CPP $CPPFLAGS'
513 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
514 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
515 cross_compiling=$ac_cv_prog_cc_cross
517 ac_exeext=
518 ac_objext=o
519 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
520 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
521 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
522 ac_n= ac_c='
523 ' ac_t=' '
524 else
525 ac_n=-n ac_c= ac_t=
527 else
528 ac_n= ac_c='\c' ac_t=
533 ac_aux_dir=
534 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
535 if test -f $ac_dir/install-sh; then
536 ac_aux_dir=$ac_dir
537 ac_install_sh="$ac_aux_dir/install-sh -c"
538 break
539 elif test -f $ac_dir/install.sh; then
540 ac_aux_dir=$ac_dir
541 ac_install_sh="$ac_aux_dir/install.sh -c"
542 break
544 done
545 if test -z "$ac_aux_dir"; then
546 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
548 ac_config_guess=$ac_aux_dir/config.guess
549 ac_config_sub=$ac_aux_dir/config.sub
550 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
553 # Do some error checking and defaulting for the host and target type.
554 # The inputs are:
555 # configure --host=HOST --target=TARGET --build=BUILD NONOPT
557 # The rules are:
558 # 1. You are not allowed to specify --host, --target, and nonopt at the
559 # same time.
560 # 2. Host defaults to nonopt.
561 # 3. If nonopt is not specified, then host defaults to the current host,
562 # as determined by config.guess.
563 # 4. Target and build default to nonopt.
564 # 5. If nonopt is not specified, then target and build default to host.
566 # The aliases save the names the user supplied, while $host etc.
567 # will get canonicalized.
568 case $host---$target---$nonopt in
569 NONE---*---* | *---NONE---* | *---*---NONE) ;;
570 *) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
571 esac
574 # Make sure we can run config.sub.
575 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
576 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
579 echo $ac_n "checking host system type""... $ac_c" 1>&6
580 echo "configure:581: checking host system type" >&5
582 host_alias=$host
583 case "$host_alias" in
584 NONE)
585 case $nonopt in
586 NONE)
587 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
588 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
589 fi ;;
590 *) host_alias=$nonopt ;;
591 esac ;;
592 esac
594 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
595 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
596 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
597 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
598 echo "$ac_t""$host" 1>&6
600 echo $ac_n "checking target system type""... $ac_c" 1>&6
601 echo "configure:602: checking target system type" >&5
603 target_alias=$target
604 case "$target_alias" in
605 NONE)
606 case $nonopt in
607 NONE) target_alias=$host_alias ;;
608 *) target_alias=$nonopt ;;
609 esac ;;
610 esac
612 target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
613 target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
614 target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
615 target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
616 echo "$ac_t""$target" 1>&6
618 echo $ac_n "checking build system type""... $ac_c" 1>&6
619 echo "configure:620: checking build system type" >&5
621 build_alias=$build
622 case "$build_alias" in
623 NONE)
624 case $nonopt in
625 NONE) build_alias=$host_alias ;;
626 *) build_alias=$nonopt ;;
627 esac ;;
628 esac
630 build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
631 build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
632 build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
633 build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
634 echo "$ac_t""$build" 1>&6
636 test "$host_alias" != "$target_alias" &&
637 test "$program_prefix$program_suffix$program_transform_name" = \
638 NONENONEs,x,x, &&
639 program_prefix=${target_alias}-
641 if test "$program_transform_name" = s,x,x,; then
642 program_transform_name=
643 else
644 # Double any \ or $. echo might interpret backslashes.
645 cat <<\EOF_SED > conftestsed
646 s,\\,\\\\,g; s,\$,$$,g
647 EOF_SED
648 program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
649 rm -f conftestsed
651 test "$program_prefix" != NONE &&
652 program_transform_name="s,^,${program_prefix},; $program_transform_name"
653 # Use a double $ so make ignores it.
654 test "$program_suffix" != NONE &&
655 program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
657 # sed with no file args requires a program.
658 test "$program_transform_name" = "" && program_transform_name="s,x,x,"
661 # Get 'install' or 'install-sh' and its variants.
662 # Find a good install program. We prefer a C program (faster),
663 # so one script is as good as another. But avoid the broken or
664 # incompatible versions:
665 # SysV /etc/install, /usr/sbin/install
666 # SunOS /usr/etc/install
667 # IRIX /sbin/install
668 # AIX /bin/install
669 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
670 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
671 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
672 # ./install, which can be erroneously created by make from ./install.sh.
673 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
674 echo "configure:675: checking for a BSD compatible install" >&5
675 if test -z "$INSTALL"; then
676 if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
677 echo $ac_n "(cached) $ac_c" 1>&6
678 else
679 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
680 for ac_dir in $PATH; do
681 # Account for people who put trailing slashes in PATH elements.
682 case "$ac_dir/" in
683 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
685 # OSF1 and SCO ODT 3.0 have their own names for install.
686 # Don't use installbsd from OSF since it installs stuff as root
687 # by default.
688 for ac_prog in ginstall scoinst install; do
689 if test -f $ac_dir/$ac_prog; then
690 if test $ac_prog = install &&
691 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
692 # AIX install. It has an incompatible calling convention.
694 else
695 ac_cv_path_install="$ac_dir/$ac_prog -c"
696 break 2
699 done
701 esac
702 done
703 IFS="$ac_save_IFS"
706 if test "${ac_cv_path_install+set}" = set; then
707 INSTALL="$ac_cv_path_install"
708 else
709 # As a last resort, use the slow shell script. We don't cache a
710 # path for INSTALL within a source directory, because that will
711 # break other packages using the cache if that directory is
712 # removed, or if the path is relative.
713 INSTALL="$ac_install_sh"
716 echo "$ac_t""$INSTALL" 1>&6
718 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
719 # It thinks the first close brace ends the variable substitution.
720 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
722 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
724 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
727 # Autoconf M4 include file defining utility macros for complex Canadian
728 # cross builds.
735 ####
736 # _NCN_TOOL_PREFIXES: Some stuff that oughtta be done in AC_CANONICAL_SYSTEM
737 # or AC_INIT.
738 # These demand that AC_CANONICAL_SYSTEM be called beforehand.
740 ####
741 # NCN_CHECK_TARGET_TOOL(variable, prog-to-check-for,[value-if-not-found],[path])
742 # Like AC_CHECK_TOOL, but tries a prefix of the target, not the host.
743 # Code is pretty much lifted from autoconf2.53.
747 ####
748 # NCN_STRICT_CHECK_TOOL(variable, prog-to-check-for,[value-if-not-found],[path])
749 # Like AC_CHECK_TOOL, but requires the prefix if build!=host.
753 ####
754 # NCN_STRICT_CHECK_TARGET_TOOL(variable, prog-to-check-for,[value-if-not-found],[path])
755 # Like NCN_CHECK_TARGET_TOOL, but requires the prefix if build!=target.
759 # AC_PROG_CPP_WERROR
760 # Used for autoconf 2.5x to force AC_PREPROC_IFELSE to reject code which
761 # triggers warnings from the preprocessor. Will be in autoconf 2.58.
762 # For now, using this also overrides header checks to use only the
763 # preprocessor (matches 2.13 behavior; matching 2.58's behavior is a
764 # bit harder from here).
765 # Eventually autoconf will default to checking headers with the compiler
766 # instead, and we'll have to do this differently.
768 # AC_PROG_CPP_WERROR
771 ### we might need to use some other shell than /bin/sh for running subshells
772 ### If we are on Windows, search for the shell. This will permit people
773 ### to not have /bin/sh, but to be able to see /SOME/PATH/sh configure
774 ### without also having to set CONFIG_SHELL. This code will work when
775 ### using bash, which sets OSTYPE.
776 case "${OSTYPE}" in
777 *win32*)
778 if test x${CONFIG_SHELL} = x ; then
779 if test ! -f /bin/sh ; then
780 if test x${SHELL} != x && test -f ${SHELL} ; then
781 CONFIG_SHELL=${SHELL}
782 export CONFIG_SHELL
783 else
784 for prog in sh sh.exe bash bash.exe; do
785 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
786 for dir in $PATH; do
787 test -z "$dir" && dir=.
788 if test -f $dir/$prog; then
789 CONFIG_SHELL=$dir/$prog
790 export CONFIG_SHELL
791 break
793 done
794 IFS="$save_ifs"
795 test -n "${CONFIG_SHELL}" && break
796 done
801 esac
803 config_shell=${CONFIG_SHELL-/bin/sh}
805 progname=$0
806 # if PWD already has a value, it is probably wrong.
807 if test -n "$PWD" ; then PWD=`${PWDCMD-pwd}`; fi
809 # Export original configure arguments for use by sub-configures. These
810 # will be expanded by make, so quote '$'.
811 tmp="$progname $@"
812 sed -e 's,\$,$$,g' <<EOF_SED > conftestsed.out
813 $tmp
814 EOF_SED
815 TOPLEVEL_CONFIGURE_ARGUMENTS=`cat conftestsed.out`
816 rm -f conftestsed.out
819 moveifchange=${srcdir}/move-if-change
821 # Set srcdir to "." if that's what it is.
822 # This is important for multilib support.
823 pwd=`${PWDCMD-pwd}`
824 srcpwd=`cd ${srcdir} ; ${PWDCMD-pwd}`
825 if test "${pwd}" = "${srcpwd}" ; then
826 srcdir=.
829 topsrcdir=$srcpwd
831 extra_host_args=
832 # Define the trigger file to make sure configure will re-run whenever
833 # the gcc version number changes.
834 if test "${with_gcc_version_trigger+set}" = set ; then
835 gcc_version_trigger="$with_gcc_version_trigger"
836 gcc_version=`grep version_string ${with_gcc_version_trigger} | sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/'`
837 else
838 # If gcc's sources are available, define the trigger file.
839 if test -f ${topsrcdir}/gcc/version.c ; then
840 gcc_version_trigger=${topsrcdir}/gcc/version.c
841 gcc_version=`grep version_string ${gcc_version_trigger} | sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/'`
842 case "$ac_configure_args" in
843 *--with-gcc-version-trigger=$gcc_version_trigger* )
846 # Add to all subconfigure arguments: build, host, and target.
847 ac_configure_args="$ac_configure_args --with-gcc-version-trigger=$gcc_version_trigger"
849 esac
853 ### To add a new directory to the tree, first choose whether it is a target
854 ### or a host dependent tool. Then put it into the appropriate list
855 ### (library or tools, host or target), doing a dependency sort.
857 # Subdirs will be configured in the order listed in build_configdirs,
858 # configdirs, or target_configdirs; see the serialization section below.
860 # Dependency sorting is only needed when *configuration* must be done in
861 # a particular order. In all cases a dependency should be specified in
862 # the Makefile, whether or not it's implicitly specified here.
864 # Double entries in build_configdirs, configdirs, or target_configdirs may
865 # cause circular dependencies and break everything horribly.
867 # these libraries are used by various programs built for the host environment
869 host_libs="intl mmalloc libiberty opcodes bfd readline tcl tk itcl tix libgui zlib"
871 # these tools are built for the host environment
872 # Note, the powerpc-eabi build depends on sim occurring before gdb in order to
873 # know that we are building the simulator.
874 # binutils, gas and ld appear in that order because it makes sense to run
875 # "make check" in that particular order.
876 host_tools="texinfo byacc flex bison binutils gas ld gcc sid sim gdb make patch prms send-pr gprof etc expect dejagnu ash bash bzip2 m4 autoconf automake libtool diff rcs fileutils shellutils time textutils wdiff find uudecode hello tar gzip indent recode release sed utils guile perl gawk findutils gettext zip fastjar"
878 # libgcj represents the runtime libraries only used by gcj.
879 libgcj="target-libffi \
880 target-boehm-gc \
881 target-zlib \
882 target-qthreads \
883 target-libjava"
885 # these libraries are built for the target environment, and are built after
886 # the host libraries and the host tools (which may be a cross compiler)
888 target_libraries="target-libiberty \
889 target-libgloss \
890 target-newlib \
891 target-libstdc++-v3 \
892 target-libf2c \
893 ${libgcj} \
894 target-libobjc"
896 # these tools are built using the target libraries, and are intended to
897 # run only in the target environment
899 # note: any program that *uses* libraries that are in the "target_libraries"
900 # list belongs in this list. those programs are also very likely
901 # candidates for the "native_only" list which follows
903 target_tools="target-examples target-groff target-gperf target-rda"
905 ################################################################################
907 ## All tools belong in one of the four categories, and are assigned above
908 ## We assign ${configdirs} this way to remove all embedded newlines. This
909 ## is important because configure will choke if they ever get through.
910 ## ${configdirs} is directories we build using the host tools.
911 ## ${target_configdirs} is directories we build using the target tools.
913 configdirs=`echo ${host_libs} ${host_tools}`
914 target_configdirs=`echo ${target_libraries} ${target_tools}`
916 # Only make build modules if build != host.
917 # This should be done more generally, but at the moment it doesn't matter.
918 if test ${host_alias} != ${build_alias} ; then
919 # This is the only build module.
920 build_modules=libiberty
921 else
922 build_modules=
926 ################################################################################
928 srcname="gnu development package"
930 # This gets set non-empty for some net releases of packages.
931 appdirs=""
933 # Define is_cross_compiler to save on calls to 'test'.
934 is_cross_compiler=
935 if test x"${host}" = x"${target}" ; then
936 is_cross_compiler=no
937 else
938 is_cross_compiler=yes
941 # Find the build and target subdir names.
942 case ${build_alias} in
943 "") build_noncanonical=${build} ;;
944 *) build_noncanonical=${build_alias} ;;
945 esac
947 case ${host_alias} in
948 "") host_noncanonical=${build_noncanonical} ;;
949 *) host_noncanonical=${host_alias} ;;
950 esac
952 case ${target_alias} in
953 "") target_noncanonical=${host_noncanonical} ;;
954 *) target_noncanonical=${target_alias} ;;
955 esac
957 # Prefix 'build-' so this never conflicts with target_subdir.
958 build_subdir="build-${build_noncanonical}"
959 # Not really a subdirectory, but here for completeness.
960 host_subdir=.
961 # No prefix.
962 target_subdir=${target_noncanonical}
965 # Skipdirs are removed silently.
966 skipdirs=
967 # Noconfigdirs are removed loudly.
968 noconfigdirs=""
970 use_gnu_ld=
971 # Make sure we don't let GNU ld be added if we didn't want it.
972 if test x$with_gnu_ld = xno ; then
973 use_gnu_ld=no
974 noconfigdirs="$noconfigdirs ld"
977 use_gnu_as=
978 # Make sure we don't let GNU as be added if we didn't want it.
979 if test x$with_gnu_as = xno ; then
980 use_gnu_as=no
981 noconfigdirs="$noconfigdirs gas"
984 # some tools are so dependent upon X11 that if we're not building with X,
985 # it's not even worth trying to configure, much less build, that tool.
987 case ${with_x} in
988 yes | "") ;; # the default value for this tree is that X11 is available
990 skipdirs="${skipdirs} tk tix itcl libgui"
991 # We won't be able to build gdbtk without X.
992 enable_gdbtk=no
994 *) echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2 ;;
995 esac
997 # Some tools are only suitable for building in a "native" situation.
998 # Remove these if host!=target.
999 native_only="autoconf automake libtool fileutils find gawk gettext gzip hello indent m4 rcs recode sed shellutils tar textutils uudecode wdiff gprof target-groff guile perl time ash bash bzip2 prms gnuserv target-gperf"
1001 # Similarly, some are only suitable for cross toolchains.
1002 # Remove these if host=target.
1003 cross_only="target-libgloss target-newlib target-opcodes"
1005 case $is_cross_compiler in
1006 no) skipdirs="${skipdirs} ${cross_only}" ;;
1007 yes) skipdirs="${skipdirs} ${native_only}" ;;
1008 esac
1010 # If both --with-headers and --with-libs are specified, default to
1011 # --without-newlib.
1012 if test x"${with_headers}" != x && test x"${with_headers} != xno \
1013 && test x"${with_libs}" != x && test x"${with_libs} != xno ; then
1014 if test x"${with_newlib}" = x ; then
1015 with_newlib=no
1019 # Recognize --with-newlib/--without-newlib.
1020 case ${with_newlib} in
1021 no) skipdirs="${skipdirs} target-newlib" ;;
1022 yes) skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'` ;;
1023 esac
1025 # Configure extra directories which are host specific
1027 case "${host}" in
1028 *-cygwin*)
1029 configdirs="$configdirs libtermcap" ;;
1030 esac
1032 # Remove more programs from consideration, based on the host or
1033 # target this usually means that a port of the program doesn't
1034 # exist yet.
1036 case "${host}" in
1037 hppa*64*-*-*)
1038 noconfigdirs="$noconfigdirs byacc"
1040 i[3456789]86-*-vsta)
1041 noconfigdirs="tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl itcl tix gnuserv gettext"
1043 i[3456789]86-*-go32* | i[3456789]86-*-msdosdjgpp*)
1044 noconfigdirs="tcl tk expect dejagnu send-pr uudecode guile itcl tix gnuserv libffi"
1046 i[3456789]86-*-mingw32*)
1047 # noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl itcl tix gnuserv"
1048 noconfigdirs="expect dejagnu autoconf automake send-pr rcs guile perl texinfo libtool"
1050 i[3456789]86-*-beos*)
1051 noconfigdirs="$noconfigdirs tk itcl tix libgui gdb"
1053 *-*-cygwin*)
1054 noconfigdirs="autoconf automake send-pr rcs guile perl"
1056 *-*-netbsd*)
1057 noconfigdirs="rcs"
1059 ppc*-*-pe)
1060 noconfigdirs="patch diff make tk tcl expect dejagnu autoconf automake texinfo bison send-pr gprof rcs guile perl itcl tix gnuserv"
1062 powerpc-*-beos*)
1063 noconfigdirs="$noconfigdirs tk itcl tix libgui gdb dejagnu readline"
1065 *-*-darwin*)
1066 noconfigdirs="$noconfigdirs tk itcl tix libgui"
1068 esac
1070 # Save it here so that, even in case of --enable-libgcj, if the Java
1071 # front-end isn't enabled, we still get libgcj disabled.
1072 libgcj_saved=$libgcj
1073 case $enable_libgcj in
1074 yes)
1075 # If we reset it here, it won't get added to noconfigdirs in the
1076 # target-specific build rules, so it will be forcibly enabled
1077 # (unless the Java language itself isn't enabled).
1078 libgcj=
1081 # Make sure we get it printed in the list of not supported target libs.
1082 noconfigdirs="$noconfigdirs ${libgcj}"
1084 esac
1086 case "${target}" in
1087 *-*-chorusos)
1088 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
1090 powerpc-*-darwin*)
1091 noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes gdb gprof"
1092 noconfigdirs="$noconfigdirs target-libobjc"
1094 *-*-darwin*)
1095 noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes gdb gprof"
1096 noconfigdirs="$noconfigdirs target-libobjc ${libgcj}"
1098 *-*-freebsd[12] | *-*-freebsd[12].* | *-*-freebsd*aout*)
1099 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
1101 *-*-kaos*)
1102 # Remove unsupported stuff on all kaOS configurations.
1103 skipdirs="target-libiberty ${libgcj} target-libstdc++-v3 target-libf2c target-librx"
1104 skipdirs="$skipdirs target-libobjc target-examples target-groff target-gperf"
1105 skipdirs="$skipdirs zlib fastjar target-libjava target-boehm-gc target-zlib"
1106 noconfigdirs="$noconfigdirs target-libgloss"
1108 *-*-netbsd*)
1109 # Skip some stuff on all NetBSD configurations.
1110 noconfigdirs="$noconfigdirs target-newlib target-libiberty target-libgloss"
1112 # Skip some stuff that's unsupported on some NetBSD configurations.
1113 case "${target}" in
1114 i*86-*-netbsdelf*) ;;
1115 arm*-*-netbsdelf*) ;;
1117 noconfigdirs="$noconfigdirs ${libgcj}"
1119 esac
1121 *-*-netware)
1122 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-newlib target-libiberty target-libgloss ${libgcj}"
1124 *-*-rtems*)
1125 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1126 case ${target} in
1127 h8300*-*-* | h8500-*-*)
1128 noconfigdirs="$noconfigdirs target-libf2c"
1130 *) ;;
1131 esac
1133 *-*-uclinux*)
1134 noconfigdirs="$noconfigdirs target-newlib target-libgloss target-rda ${libgcj}"
1136 *-*-vxworks*)
1137 noconfigdirs="$noconfigdirs target-newlib target-libgloss target-libiberty ${libgcj}"
1139 alpha*-dec-osf*)
1140 # ld works, but does not support shared libraries.
1141 # newlib is not 64 bit ready. I'm not sure about fileutils.
1142 # gas doesn't generate exception information.
1143 noconfigdirs="$noconfigdirs gas ld fileutils target-newlib target-libgloss"
1145 alpha*-*-*vms*)
1146 noconfigdirs="$noconfigdirs gdb ld target-newlib target-libgloss ${libgcj}"
1148 alpha*-*-linux*)
1149 # newlib is not 64 bit ready
1150 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1152 alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu)
1153 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1155 alpha*-*-*)
1156 # newlib is not 64 bit ready
1157 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
1159 am33_2.0-*-linux*)
1160 noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
1162 sh-*-linux*)
1163 noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
1165 sh*-*-pe|mips*-*-pe|*arm-wince-pe)
1166 noconfigdirs="$noconfigdirs ${libgcj}"
1167 noconfigdirs="$noconfigdirs target-examples"
1168 noconfigdirs="$noconfigdirs target-libiberty texinfo send-pr"
1169 noconfigdirs="$noconfigdirs tcl tix tk itcl libgui sim"
1170 noconfigdirs="$noconfigdirs expect dejagnu"
1171 # the C++ libraries don't build on top of CE's C libraries
1172 noconfigdirs="$noconfigdirs target-libstdc++-v3"
1173 noconfigdirs="$noconfigdirs target-newlib"
1174 case "${host}" in
1175 *-*-cygwin*) ;; # keep gdb and readline
1176 *) noconfigdirs="$noconfigdirs gdb readline"
1178 esac
1180 arc-*-*)
1181 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1183 arm-*-coff | strongarm-*-coff | xscale-*-coff)
1184 noconfigdirs="$noconfigdirs ${libgcj}"
1186 arm-*-elf* | strongarm-*-elf* | xscale-*-elf*)
1187 noconfigdirs="$noconfigdirs target-libffi target-qthreads"
1189 arm-*-pe*)
1190 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1192 arm-*-oabi*)
1193 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1195 thumb-*-coff)
1196 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1198 thumb-*-elf)
1199 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1201 thumb-*-oabi)
1202 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1204 thumb-*-pe)
1205 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1207 arm-*-riscix*)
1208 noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
1210 avr-*-*)
1211 noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
1213 c4x-*-* | tic4x-*-*)
1214 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
1216 c54x*-*-* | tic54x-*-*)
1217 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj} gcc gdb newlib"
1219 cris-*-*)
1220 noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
1222 d10v-*-*)
1223 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
1225 d30v-*-*)
1226 noconfigdirs="$noconfigdirs ${libgcj} gdb"
1228 fr30-*-elf*)
1229 noconfigdirs="$noconfigdirs ${libgcj} gdb"
1231 frv-*-*)
1232 noconfigdirs="$noconfigdirs ${libgcj}"
1234 h8300*-*-*)
1235 noconfigdirs="$noconfigdirs target-libgloss ${libgcj} target-libf2c"
1237 h8500-*-*)
1238 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj} target-libf2c"
1240 hppa*64*-*-linux* | parisc*64*-*-linux*)
1241 # In this case, it's because the hppa64-linux target is for
1242 # the kernel only at this point and has no libc, and thus no
1243 # headers, crt*.o, etc., all of which are needed by these.
1244 noconfigdirs="$noconfigdirs target-zlib"
1246 hppa*-*-*elf* | \
1247 parisc*-*-linux* | hppa*-*-linux* | \
1248 hppa*-*-lites* | \
1249 hppa*-*-openbsd* | \
1250 hppa*64*-*-*)
1251 noconfigdirs="$noconfigdirs ${libgcj}"
1252 # Do configure ld/binutils/gas for this case.
1254 hppa*-*-*)
1255 # According to Alexandre Oliva <aoliva@redhat.com>, libjava won't
1256 # build on HP-UX 10.20.
1257 noconfigdirs="$noconfigdirs ld shellutils ${libgcj}"
1259 i960-*-*)
1260 noconfigdirs="$noconfigdirs ${libgcj} gdb"
1262 ia64*-*-elf*)
1263 # No gdb support yet.
1264 noconfigdirs="$noconfigdirs tix readline mmalloc libgui itcl gdb"
1266 ia64*-**-hpux*)
1267 # No gdb or ld support yet.
1268 noconfigdirs="$noconfigdirs ${libgcj} tix readline mmalloc libgui itcl gdb ld"
1270 i[3456789]86-*-coff | i[3456789]86-*-elf)
1271 noconfigdirs="$noconfigdirs ${libgcj}"
1273 i[3456789]86-*-freebsd* | i[3456789]86-*-kfreebsd*-gnu)
1274 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1276 i[3456789]86-*-linux*)
1277 # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's
1278 # not build java stuff by default.
1279 case "${target}" in
1280 *-*-*libc1*)
1281 noconfigdirs="$noconfigdirs ${libgcj}";;
1282 esac
1284 # This section makes it possible to build newlib natively on linux.
1285 # If we are using a cross compiler then don't configure newlib.
1286 if test x${is_cross_compiler} != xno ; then
1287 noconfigdirs="$noconfigdirs target-newlib"
1289 noconfigdirs="$noconfigdirs target-libgloss"
1290 # If we are not using a cross compiler, do configure newlib.
1291 # Note however, that newlib will only be configured in this situation
1292 # if the --with-newlib option has been given, because otherwise
1293 # 'target-newlib' will appear in skipdirs.
1295 i[3456789]86-*-mingw32*)
1296 target_configdirs="$target_configdirs target-mingw"
1297 noconfigdirs="$noconfigdirs expect target-libgloss ${libgcj}"
1299 # Can't build gdb for mingw32 if not native.
1300 case "${host}" in
1301 i[3456789]86-*-mingw32) ;; # keep gdb tcl tk expect etc.
1302 *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix gnuserv"
1304 esac
1306 *-*-cygwin*)
1307 target_configdirs="$target_configdirs target-libtermcap target-winsup"
1308 noconfigdirs="$noconfigdirs target-gperf target-libgloss ${libgcj}"
1309 # always build newlib.
1310 skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
1312 # Can't build gdb for Cygwin if not native.
1313 case "${host}" in
1314 *-*-cygwin*) ;; # keep gdb tcl tk expect etc.
1315 *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix libgui gnuserv"
1317 esac
1319 i[3456789]86-*-pe)
1320 noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
1322 i[3456789]86-*-sco3.2v5*)
1323 # The linker does not yet know about weak symbols in COFF,
1324 # and is not configured to handle mixed ELF and COFF.
1325 noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
1327 i[3456789]86-*-sco*)
1328 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
1330 i[3456789]86-*-solaris2*)
1331 noconfigdirs="$noconfigdirs target-libgloss"
1333 i[3456789]86-*-sysv4*)
1334 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1336 i[3456789]86-*-beos*)
1337 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
1339 m32r-*-*)
1340 noconfigdirs="$noconfigdirs ${libgcj}"
1342 zpu-*-*)
1343 noconfigdirs="$noconfigdirs target-libiberty ${libgcj}"
1345 m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
1346 noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
1348 m68k-*-elf*)
1349 noconfigdirs="$noconfigdirs ${libgcj}"
1351 m68k-*-coff*)
1352 noconfigdirs="$noconfigdirs ${libgcj}"
1354 mcore-*-pe*)
1355 # The EPOC C++ environment does not support exceptions or rtti,
1356 # and so building libstdc++-v3 tends not to always work.
1357 noconfigdirs="$noconfigdirs target-libstdc++-v3"
1359 mmix-*-*)
1360 noconfigdirs="$noconfigdirs ${libgcj} gdb libgloss"
1362 mn10200-*-*)
1363 noconfigdirs="$noconfigdirs ${libgcj}"
1365 mn10300-*-*)
1366 noconfigdirs="$noconfigdirs ${libgcj}"
1368 powerpc-*-aix*)
1369 # copied from rs6000-*-* entry
1370 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
1372 powerpc*-*-winnt* | powerpc*-*-pe* | ppc*-*-pe)
1373 target_configdirs="$target_configdirs target-winsup"
1374 noconfigdirs="$noconfigdirs gdb tcl tk make expect target-libgloss itcl tix gnuserv ${libgcj}"
1375 # always build newlib.
1376 skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
1378 # This is temporary until we can link against shared libraries
1379 powerpcle-*-solaris*)
1380 noconfigdirs="$noconfigdirs gdb sim make tcl tk expect itcl tix gnuserv ${libgcj}"
1382 powerpc-*-beos*)
1383 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
1385 powerpc-*-eabi)
1386 noconfigdirs="$noconfigdirs ${libgcj}"
1388 rs6000-*-lynxos*)
1389 noconfigdirs="$noconfigdirs target-newlib gprof ${libgcj}"
1391 rs6000-*-aix*)
1392 noconfigdirs="$noconfigdirs gprof ${libgcj}"
1394 rs6000-*-*)
1395 noconfigdirs="$noconfigdirs gprof ${libgcj}"
1397 m68k-apollo-*)
1398 noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss ${libgcj}"
1400 mips*-*-irix5*)
1401 # The GNU linker does not support shared libraries.
1402 noconfigdirs="$noconfigdirs ld gprof target-libgloss ${libgcj}"
1404 mips*-*-irix6*)
1405 # Linking libjava exceeds command-line length limits on at least
1406 # IRIX 6.2, but not on IRIX 6.5.
1407 # Also, boehm-gc won't build on IRIX 6.5, according to Jeffrey Oldham
1408 # <oldham@codesourcery.com>
1409 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
1411 mips*-dec-bsd*)
1412 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
1414 mips*-*-bsd*)
1415 noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
1417 mipstx39-*-*)
1418 noconfigdirs="$noconfigdirs gprof ${libgcj}" # same as generic mips
1420 mips64*-*-linux*)
1421 noconfigdirs="$noconfigdirs target-newlib ${libgcj}"
1423 mips*-*-linux*)
1424 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1426 mips*-*-*)
1427 noconfigdirs="$noconfigdirs gprof ${libgcj}"
1429 romp-*-*)
1430 noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes target-libgloss ${libgcj}"
1432 sh-*-*)
1433 case "${host}" in
1434 i[3456789]86-*-vsta) ;; # don't add gprof back in
1435 i[3456789]86-*-go32*) ;; # don't add gprof back in
1436 i[3456789]86-*-msdosdjgpp*) ;; # don't add gprof back in
1437 *) skipdirs=`echo " ${skipdirs} " | sed -e 's/ gprof / /'` ;;
1438 esac
1439 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1441 sh64-*-*)
1442 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1444 sparc-*-elf*)
1445 noconfigdirs="$noconfigdirs ${libgcj}"
1447 sparc64-*-elf*)
1448 noconfigdirs="$noconfigdirs ${libgcj}"
1450 sparclite-*-*)
1451 noconfigdirs="$noconfigdirs ${libgcj}"
1453 sparc-*-sunos4*)
1454 noconfigdirs="$noconfigdirs ${libgcj}"
1455 if test x${is_cross_compiler} != xno ; then
1456 noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
1457 else
1458 use_gnu_ld=no
1461 sparc-*-solaris* | sparc64-*-solaris* | sparcv9-*-solaris*)
1463 v810-*-*)
1464 noconfigdirs="$noconfigdirs bfd binutils gas gcc gdb ld target-libstdc++-v3 opcodes target-libgloss ${libgcj}"
1466 v850-*-*)
1467 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1469 v850e-*-*)
1470 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1472 v850ea-*-*)
1473 noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
1475 vax-*-vms)
1476 noconfigdirs="$noconfigdirs bfd binutils gdb ld target-newlib opcodes target-libgloss ${libgcj}"
1478 vax-*-*)
1479 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
1481 xtensa-*-*)
1482 noconfigdirs="$noconfigdirs ${libgcj}"
1484 ip2k-*-*)
1485 noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
1487 *-*-linux*)
1488 noconfigdirs="$noconfigdirs target-newlib target-libgloss"
1490 *-*-lynxos*)
1491 noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
1493 *-*-*)
1494 noconfigdirs="$noconfigdirs ${libgcj}"
1496 esac
1498 # If we aren't building newlib, then don't build libgloss, since libgloss
1499 # depends upon some newlib header files.
1500 case "${noconfigdirs}" in
1501 *target-libgloss*) ;;
1502 *target-newlib*) noconfigdirs="$noconfigdirs target-libgloss" ;;
1503 esac
1505 # Figure out what language subdirectories are present.
1506 # Look if the user specified --enable-languages="..."; if not, use
1507 # the environment variable $LANGUAGES if defined. $LANGUAGES might
1508 # go away some day.
1509 # NB: embedded tabs in this IF block -- do not untabify
1510 if test x"${enable_languages+set}" != xset; then
1511 if test x"${LANGUAGES+set}" = xset; then
1512 enable_languages="${LANGUAGES}"
1513 echo configure.in: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
1514 else
1515 enable_languages=all
1517 else
1518 if test x"${enable_languages}" = x ||
1519 test x"${enable_languages}" = xyes;
1520 then
1521 echo configure.in: --enable-languages needs at least one language argument 1>&2
1522 exit 1
1525 enable_languages=`echo "${enable_languages}" | sed -e 's/[ ,][ ,]*/,/g' -e 's/,$//'`
1527 # First scan to see if an enabled language requires some other language.
1528 # We assume that a given config-lang.in will list all the language
1529 # front ends it requires, even if some are required indirectly.
1530 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
1531 case ${lang_frag} in
1532 ..) ;;
1533 # The odd quoting in the next line works around
1534 # an apparent bug in bash 1.12 on linux.
1535 ${srcdir}/gcc/[*]/config-lang.in) ;;
1537 # From the config-lang.in, get $language, $lang_requires
1538 language=
1539 lang_requires=
1540 . ${lang_frag}
1541 for other in ${lang_requires} ; do
1542 case ,${enable_languages}, in
1543 *,$other,*) ;;
1544 *,all,*) ;;
1545 *,$language,*)
1546 echo " \`$other' language required by \`$language'; enabling" 1>&2
1547 enable_languages="${enable_languages},${other}"
1549 esac
1550 done
1552 esac
1553 done
1555 for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
1556 case ${lang_frag} in
1557 ..) ;;
1558 # The odd quoting in the next line works around
1559 # an apparent bug in bash 1.12 on linux.
1560 ${srcdir}/gcc/[*]/config-lang.in) ;;
1562 # From the config-lang.in, get $language, $target_libs,
1563 # $lang_dirs, and $build_by_default
1564 language=
1565 target_libs=
1566 lang_dirs=
1567 build_by_default=
1568 . ${lang_frag}
1569 if test "x$language" = x ; then
1570 echo "${lang_frag} doesn't set \$language." 1>&2
1571 exit 1
1573 case ,${enable_languages}, in
1574 *,${language},*)
1575 # Language was explicitly selected; include it.
1576 add_this_lang=yes
1578 *,all,*)
1579 # 'all' was selected; include 'default' languages.
1580 case ${build_by_default} in
1581 no) add_this_lang=no ;;
1582 *) add_this_lang=yes ;;
1583 esac
1585 *) add_this_lang=no ;;
1586 esac
1587 case ${add_this_lang} in
1589 # Remove language-dependent dirs.
1590 eval noconfigdirs='"$noconfigdirs "'\"$target_libs $lang_dirs\"
1592 esac
1594 esac
1595 done
1597 # Remove the entries in $skipdirs and $noconfigdirs from $configdirs and
1598 # $target_configdirs.
1599 # If we have the source for $noconfigdirs entries, add them to $notsupp.
1601 notsupp=""
1602 for dir in . $skipdirs $noconfigdirs ; do
1603 dirname=`echo $dir | sed -e s/target-//g`
1604 if test $dir != . && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
1605 configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
1606 if test -r $srcdir/$dirname/configure ; then
1607 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
1608 true
1609 else
1610 notsupp="$notsupp $dir"
1614 if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
1615 target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
1616 if test -r $srcdir/$dirname/configure ; then
1617 if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
1618 true
1619 else
1620 notsupp="$notsupp $dir"
1624 done
1626 # Sometimes the tools are distributed with libiberty but with no other
1627 # libraries. In that case, we don't want to build target-libiberty.
1628 if test -n "${target_configdirs}" ; then
1629 others=
1630 for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
1631 if test "$i" != "libiberty" ; then
1632 if test -r $srcdir/$i/configure ; then
1633 others=yes;
1634 break;
1637 done
1638 if test -z "${others}" ; then
1639 target_configdirs=
1643 # Quietly strip out all directories which aren't configurable in this tree.
1644 # This relies on all configurable subdirectories being autoconfiscated, which
1645 # is now the case.
1646 configdirs_all="$configdirs"
1647 configdirs=
1648 for i in ${configdirs_all} ; do
1649 if test -f ${srcdir}/$i/configure ; then
1650 configdirs="${configdirs} $i"
1652 done
1653 target_configdirs_all="$target_configdirs"
1654 target_configdirs=
1655 for i in ${target_configdirs_all} ; do
1656 j=`echo $i | sed -e s/target-//g`
1657 if test -f ${srcdir}/$j/configure ; then
1658 target_configdirs="${target_configdirs} $i"
1660 done
1662 # Produce a warning message for the subdirs we can't configure.
1663 # This isn't especially interesting in the Cygnus tree, but in the individual
1664 # FSF releases, it's important to let people know when their machine isn't
1665 # supported by the one or two programs in a package.
1667 if test -n "${notsupp}" && test -z "${norecursion}" ; then
1668 # If $appdirs is non-empty, at least one of those directories must still
1669 # be configured, or we error out. (E.g., if the gas release supports a
1670 # specified target in some subdirs but not the gas subdir, we shouldn't
1671 # pretend that all is well.)
1672 if test -n "$appdirs" ; then
1673 for dir in $appdirs ; do
1674 if test -r $dir/Makefile.in ; then
1675 if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
1676 appdirs=""
1677 break
1679 if echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
1680 appdirs=""
1681 break
1684 done
1685 if test -n "$appdirs" ; then
1686 echo "*** This configuration is not supported by this package." 1>&2
1687 exit 1
1690 # Okay, some application will build, or we don't care to check. Still
1691 # notify of subdirs not getting built.
1692 echo "*** This configuration is not supported in the following subdirectories:" 1>&2
1693 echo " ${notsupp}" 1>&2
1694 echo " (Any other directories should still work fine.)" 1>&2
1697 case "$host" in
1698 *msdosdjgpp*)
1699 enable_gdbtk=no ;;
1700 esac
1702 copy_dirs=
1704 # Handle --with-headers=XXX. If the value is not "yes", the contents of
1705 # the named directory are copied to $(tooldir)/sys-include.
1706 if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
1707 if test x${is_cross_compiler} = xno ; then
1708 echo 1>&2 '***' --with-headers is only supported when cross compiling
1709 exit 1
1711 if test x"${with_headers}" != xyes ; then
1712 case "${exec_prefixoption}" in
1713 "") x=${prefix} ;;
1714 *) x=${exec_prefix} ;;
1715 esac
1716 copy_dirs="${copy_dirs} ${with_headers} $x/${target_alias}/sys-include"
1720 # Handle --with-libs=XXX. If the value is not "yes", the contents of
1721 # the name directories are copied to $(tooldir)/lib. Multiple directories
1722 # are permitted.
1723 if test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
1724 if test x${is_cross_compiler} = xno ; then
1725 echo 1>&2 '***' --with-libs is only supported when cross compiling
1726 exit 1
1728 if test x"${with_libs}" != xyes ; then
1729 # Copy the libraries in reverse order, so that files in the first named
1730 # library override files in subsequent libraries.
1731 case "${exec_prefixoption}" in
1732 "") x=${prefix} ;;
1733 *) x=${exec_prefix} ;;
1734 esac
1735 for l in ${with_libs}; do
1736 copy_dirs="$l $x/${target_alias}/lib ${copy_dirs}"
1737 done
1741 # Handle ${copy_dirs}
1742 set fnord ${copy_dirs}
1743 shift
1744 while test $# != 0 ; do
1745 if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
1747 else
1748 echo Copying $1 to $2
1750 # Use the install script to create the directory and all required
1751 # parent directories.
1752 if test -d $2 ; then
1754 else
1755 echo >config.temp
1756 ${srcdir}/install-sh -c -m 644 config.temp $2/COPIED
1759 # Copy the directory, assuming we have tar.
1760 # FIXME: Should we use B in the second tar? Not all systems support it.
1761 (cd $1; tar -cf - .) | (cd $2; tar -xpf -)
1763 # It is the responsibility of the user to correctly adjust all
1764 # symlinks. If somebody can figure out how to handle them correctly
1765 # here, feel free to add the code.
1767 echo $1 > $2/COPIED
1769 shift; shift
1770 done
1772 # Work in distributions that contain no compiler tools, like Autoconf.
1773 tentative_cc=""
1774 host_makefile_frag=/dev/null
1775 if test -d ${srcdir}/config ; then
1776 case "${host}" in
1777 m68k-hp-hpux*)
1778 # Avoid "too much defining" errors from HPUX compiler.
1779 tentative_cc="cc -Wp,-H256000"
1780 # If "ar" in $PATH is GNU ar, the symbol table may need rebuilding.
1781 # If it's HP/UX ar, this should be harmless.
1782 RANLIB="ar ts"
1784 m68k-apollo-sysv*)
1785 tentative_cc="cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DUSG"
1787 m68k-apollo-bsd*)
1788 #None of the Apollo compilers can compile gas or binutils. The preprocessor
1789 # chokes on bfd, the compiler won't let you assign integers to enums, and
1790 # other problems. Defining CC to gcc is a questionable way to say "don't use
1791 # the apollo compiler" (the preferred version of GCC could be called cc,
1792 # or whatever), but I'm not sure leaving CC as cc is any better...
1793 #CC=cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DNO_STDARG
1794 # Used to have BISON=yacc.
1795 tentative_cc=gcc
1797 m88k-dg-dgux*)
1798 tentative_cc="gcc -Wall -ansi -D__using_DGUX"
1800 m88k-harris-cxux*)
1801 # Under CX/UX, we want to tell the compiler to use ANSI mode.
1802 tentative_cc="cc -Xa"
1803 host_makefile_frag="config/mh-cxux"
1805 m88k-motorola-sysv*)
1807 mips*-dec-ultrix*)
1808 tentative_cc="cc -Wf,-XNg1000"
1809 host_makefile_frag="config/mh-decstation"
1811 mips*-nec-sysv4*)
1812 # The C compiler on NEC MIPS SVR4 needs bigger tables.
1813 tentative_cc="cc -ZXNd=5000 -ZXNg=1000"
1814 host_makefile_frag="config/mh-necv4"
1816 mips*-sgi-irix4*)
1817 # Tell compiler to use K&R C. We can't compile under the SGI Ansi
1818 # environment. Also bump switch table size so that cp-parse will
1819 # compile. Bump string length limit so linker builds.
1820 tentative_cc="cc -cckr -Wf,-XNg1500 -Wf,-XNk1000 -Wf,-XNh2000 -Wf,-XNl8192"
1822 mips*-*-sysv4*)
1823 host_makefile_frag="config/mh-sysv4"
1825 mips*-*-sysv*)
1826 # This is for a MIPS running RISC/os 4.52C.
1828 # This is needed for GDB, but needs to be in the top-level make because
1829 # if a library is compiled with the bsd headers and gets linked with the
1830 # sysv system libraries all hell can break loose (e.g. a jmp_buf might be
1831 # a different size).
1832 # ptrace(2) apparently has problems in the BSD environment. No workaround is
1833 # known except to select the sysv environment. Could we use /proc instead?
1834 # These "sysv environments" and "bsd environments" often end up being a pain.
1836 # This is not part of CFLAGS because perhaps not all C compilers have this
1837 # option.
1838 tentative_cc="cc -systype sysv"
1840 i370-ibm-opened*)
1841 tentative_cc="c89"
1843 i[3456789]86-*-sysv5*)
1844 host_makefile_frag="config/mh-sysv5"
1846 i[3456789]86-*-dgux*)
1847 tentative_cc="gcc -Wall -ansi -D__using_DGUX"
1848 host_makefile_frag="config/mh-dgux386"
1850 i[3456789]86-ncr-sysv4.3*)
1851 # The MetaWare compiler will generate a copyright message unless you
1852 # turn it off by adding the -Hnocopyr flag.
1853 tentative_cc="cc -Hnocopyr"
1855 i[3456789]86-ncr-sysv4*)
1856 # for an NCR 3000 (i486/SVR4) system.
1857 # The NCR 3000 ships with a MetaWare compiler installed as /bin/cc.
1858 # This compiler not only emits obnoxious copyright messages every time
1859 # you run it, but it chokes and dies on a whole bunch of GNU source
1860 # files. Default to using the AT&T compiler installed in /usr/ccs/ATT/cc.
1861 tentative_cc="/usr/ccs/ATT/cc"
1862 host_makefile_frag="config/mh-ncr3000"
1864 i[3456789]86-*-sco3.2v5*)
1866 i[3456789]86-*-sco*)
1867 # The native C compiler botches some simple uses of const. Unfortunately,
1868 # it doesn't defined anything like "__sco__" for us to test for in ansidecl.h.
1869 tentative_cc="cc -Dconst="
1870 host_makefile_frag="config/mh-sco"
1872 i[3456789]86-*-udk*)
1873 host_makefile_frag="config/mh-sysv5"
1875 i[3456789]86-*-solaris2*)
1876 host_makefile_frag="config/mh-sysv4"
1878 i[3456789]86-*-msdosdjgpp*)
1879 host_makefile_frag="config/mh-djgpp"
1881 *-cygwin*)
1882 host_makefile_frag="config/mh-cygwin"
1884 *-mingw32*)
1885 host_makefile_frag="config/mh-mingw32"
1887 *-interix*)
1888 host_makefile_frag="config/mh-interix"
1890 vax-*-ultrix2*)
1891 # The old BSD pcc isn't up to compiling parts of gdb so use gcc
1892 tentative_cc=gcc
1894 *-*-solaris2*)
1895 host_makefile_frag="config/mh-solaris"
1897 m68k-sun-sunos*)
1898 # Sun's C compiler needs the -J flag to be able to compile cp-parse.c
1899 # without overflowing the jump tables (-J says to use a 32 bit table)
1900 tentative_cc="cc -J"
1902 *-hp-hpux*)
1903 tentative_cc="cc -Wp,-H256000"
1905 *-*-hiux*)
1906 tentative_cc="cc -Wp,-H256000"
1908 rs6000-*-lynxos*)
1909 # /bin/cc is less than useful for our purposes. Always use GCC
1910 tentative_cc="/usr/cygnus/progressive/bin/gcc"
1911 host_makefile_frag="config/mh-lynxrs6k"
1913 *-*-lynxos*)
1914 # /bin/cc is less than useful for our purposes. Always use GCC
1915 tentative_cc="/bin/gcc"
1917 *-*-sysv4*)
1918 host_makefile_frag="config/mh-sysv4"
1920 esac
1923 extra_arflags_for_target=
1924 extra_nmflags_for_target=
1925 extra_ranlibflags_for_target=
1926 target_makefile_frag=/dev/null
1927 case "${target}" in
1928 i[3456789]86-*-netware*)
1929 target_makefile_frag="config/mt-netware"
1931 powerpc-*-netware*)
1932 target_makefile_frag="config/mt-netware"
1934 *-*-linux*)
1935 target_makefile_frag="config/mt-linux"
1937 *-*-aix4.[3456789]* | *-*-aix[56789].*)
1938 # nm and ar from AIX 4.3 and above require -X32_64 flag to all ar and nm
1939 # commands to handle both 32-bit and 64-bit objects. These flags are
1940 # harmless if we're using GNU nm or ar.
1941 extra_arflags_for_target=" -X32_64"
1942 extra_nmflags_for_target=" -B -X32_64"
1944 *-*-darwin*)
1945 # ranlib from Darwin requires the -c flag to look at common symbols.
1946 extra_ranlibflags_for_target=" -c"
1948 mips*-*-pe | sh*-*-pe | *arm-wince-pe)
1949 target_makefile_frag="config/mt-wince"
1951 esac
1953 alphaieee_frag=/dev/null
1954 case $target in
1955 alpha*-*-*)
1956 # This just makes sure to use the -mieee option to build target libs.
1957 # This should probably be set individually by each library.
1958 alphaieee_frag="config/mt-alphaieee"
1960 esac
1962 # If --enable-target-optspace always use -Os instead of -O2 to build
1963 # the target libraries, similarly if it is not specified, use -Os
1964 # on selected platforms.
1965 ospace_frag=/dev/null
1966 case "${enable_target_optspace}:${target}" in
1967 yes:*)
1968 ospace_frag="config/mt-ospace"
1970 :d30v-*)
1971 ospace_frag="config/mt-d30v"
1973 :m32r-* | :d10v-* | :fr30-*)
1974 ospace_frag="config/mt-ospace"
1976 no:* | :*)
1979 echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
1981 esac
1983 # Set with_gnu_as and with_gnu_ld as appropriate.
1985 # This is done by determining whether or not the appropriate directory
1986 # is available, and by checking whether or not specific configurations
1987 # have requested that this magic not happen.
1989 # The command line options always override the explicit settings in
1990 # configure.in, and the settings in configure.in override this magic.
1992 # If the default for a toolchain is to use GNU as and ld, and you don't
1993 # want to do that, then you should use the --without-gnu-as and
1994 # --without-gnu-ld options for the configure script.
1996 if test x${use_gnu_as} = x &&
1997 echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 ; then
1998 with_gnu_as=yes
1999 extra_host_args="$extra_host_args --with-gnu-as"
2002 if test x${use_gnu_ld} = x &&
2003 echo " ${configdirs} " | grep " ld " > /dev/null 2>&1 ; then
2004 with_gnu_ld=yes
2005 extra_host_args="$extra_host_args --with-gnu-ld"
2008 # If using newlib, add --with-newlib to the extra_host_args so that gcc/configure
2009 # can detect this case.
2011 if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 ; then
2012 with_newlib=yes
2013 extra_host_args="$extra_host_args --with-newlib"
2017 # Default to using --with-stabs for certain targets.
2018 if test x${with_stabs} = x ; then
2019 case "${target}" in
2020 mips*-*-irix[56]*)
2022 mips*-*-* | alpha*-*-osf*)
2023 with_stabs=yes;
2024 extra_host_args="${extra_host_args} --with-stabs"
2026 esac
2029 # hpux11 in 64bit mode has libraries in a weird place. Arrange to find
2030 # them automatically.
2031 case "${host}" in
2032 hppa*64*-*-hpux11*)
2033 extra_host_args="$extra_host_args -x-libraries=/usr/lib/pa20_64 -x-includes=/usr/X11R6/include"
2035 esac
2037 # If we aren't going to be using gcc, see if we can extract a definition
2038 # of CC from the fragment.
2039 # Actually, use the 'pre-extracted' version above.
2040 if test -z "${CC}" && test "${build}" = "${host}" ; then
2041 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
2042 found=
2043 for dir in $PATH; do
2044 test -z "$dir" && dir=.
2045 if test -f $dir/gcc; then
2046 found=yes
2047 break
2049 done
2050 IFS="$save_ifs"
2051 if test -z "${found}" && test -n "${tentative_cc}" ; then
2052 CC=$tentative_cc
2056 # Some systems (e.g., one of the i386-aix systems the gas testers are
2057 # using) don't handle "\$" correctly, so don't use it here.
2058 tooldir='${exec_prefix}'/${target_alias}
2059 build_tooldir=${tooldir}
2061 # Generate a default definition for YACC. This is used if the makefile can't
2062 # locate bison or byacc in objdir.
2064 for prog in 'bison -y' byacc yacc
2066 set dummy $prog; tmp=$2
2067 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
2068 for dir in $PATH; do
2069 test -z "$dir" && dir=.
2070 if test -f $dir/$tmp; then
2071 DEFAULT_YACC="$prog"
2072 break
2074 done
2075 IFS="$save_ifs"
2077 test -n "$DEFAULT_YACC" && break
2078 done
2080 # Generate a default definition for M4. This is used if the makefile can't
2081 # locate m4 in objdir.
2083 for prog in gm4 gnum4 m4
2085 set dummy $prog; tmp=$2
2086 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
2087 for dir in $PATH; do
2088 test -z "$dir" && dir=.
2089 if test -f $dir/$tmp; then
2090 DEFAULT_M4="$prog"
2091 break
2093 done
2094 IFS="$save_ifs"
2096 test -n "$DEFAULT_M4" && break
2097 done
2099 # Generate a default definition for LEX. This is used if the makefile can't
2100 # locate flex in objdir.
2102 for prog in flex lex
2104 set dummy $prog; tmp=$2
2105 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
2106 for dir in $PATH; do
2107 test -z "$dir" && dir=.
2108 if test -f $dir/$tmp; then
2109 DEFAULT_LEX="$prog"
2110 break
2112 done
2113 IFS="$save_ifs"
2115 test -n "$DEFAULT_LEX" && break
2116 done
2118 if test "${build}" != "${host}" ; then
2119 # If we are doing a Canadian Cross, in which the host and build systems
2120 # are not the same, we set reasonable default values for the tools.
2122 BISON=${BISON-bison}
2123 CC=${CC-${host_alias}-gcc}
2124 CFLAGS=${CFLAGS-"-g -O2"}
2125 CXX=${CXX-${host_alias}-c++}
2126 CXXFLAGS=${CXXFLAGS-"-g -O2"}
2127 CC_FOR_BUILD=${CC_FOR_BUILD-gcc}
2128 CC_FOR_TARGET=${CC_FOR_TARGET-${target_alias}-gcc}
2129 CXX_FOR_TARGET=${CXX_FOR_TARGET-${target_alias}-c++}
2130 GCJ_FOR_TARGET=${GCJ_FOR_TARGET-${target_alias}-gcj}
2131 GCC_FOR_TARGET=${GCC_FOR_TARGET-${CC_FOR_TARGET-${target_alias}-gcc}}
2132 BUILD_PREFIX=${build_alias}-
2133 BUILD_PREFIX_1=${build_alias}-
2134 MAKEINFO=${MAKEINFO-makeinfo}
2136 if test -z "${YACC}" ; then
2137 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
2138 for dir in $PATH; do
2139 test -z "$dir" && dir=.
2140 if test -f $dir/bison; then
2141 YACC="bison -y"
2142 break
2144 if test -f $dir/byacc; then
2145 YACC=byacc
2146 break
2148 if test -f $dir/yacc; then
2149 YACC=yacc
2150 break
2152 done
2153 IFS="$save_ifs"
2154 if test -z "${YACC}" ; then
2155 YACC="bison -y"
2159 if test -z "${LEX}" ; then
2160 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
2161 for dir in $PATH; do
2162 test -z "$dir" && dir=.
2163 if test -f $dir/flex; then
2164 LEX=flex
2165 break
2167 if test -f $dir/lex; then
2168 LEX=lex
2169 break
2171 done
2172 IFS="$save_ifs"
2173 LEX=${LEX-flex}
2176 else
2177 # Set reasonable default values for some tools even if not Canadian.
2178 # Of course, these are different reasonable default values, originally
2179 # specified directly in the Makefile.
2180 # We don't export, so that autoconf can do its job.
2181 # Note that all these settings are above the fragment inclusion point
2182 # in Makefile.in, so can still be overridden by fragments.
2183 # This is all going to change when we autoconfiscate...
2185 BISON="\$(USUAL_BISON)"
2186 CC_FOR_BUILD="\$(CC)"
2187 GCC_FOR_TARGET="\$(USUAL_GCC_FOR_TARGET)"
2188 BUILD_PREFIX=
2189 BUILD_PREFIX_1=loser-
2190 MAKEINFO="\$(USUAL_MAKEINFO)"
2191 LEX="\$(USUAL_LEX)"
2192 YACC="\$(USUAL_YACC)"
2194 # If CC is still not set, try to get gcc.
2195 cc_prog_is_gcc=
2196 if test -z "${CC}" ; then
2197 IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
2198 for dir in $PATH; do
2199 test -z "$dir" && dir=.
2200 if test -f $dir/gcc; then
2201 CC="gcc"
2202 cc_prog_is_gcc=yes
2203 echo 'void f(){}' > conftest.c
2204 if test -z "`${CC} -g -c conftest.c 2>&1`"; then
2205 CFLAGS=${CFLAGS-"-g -O2"}
2206 CXXFLAGS=${CXXFLAGS-"-g -O2"}
2207 else
2208 CFLAGS=${CFLAGS-"-O2"}
2209 CXXFLAGS=${CXXFLAGS-"-O2"}
2211 rm -f conftest*
2212 break
2214 done
2215 IFS="$save_ifs"
2216 CC=${CC-cc}
2217 else
2218 # Determine if we are using gcc.
2219 cat > conftest.c <<EOF
2220 #ifdef __GNUC__
2221 yes;
2222 #endif
2224 if ${CC} -E conftest.c | grep yes >/dev/null 2>&1; then
2225 cc_prog_is_gcc=yes
2227 rm -f conftest.c
2228 if test -z "${CFLAGS}"; then
2229 # Here CC is set but CFLAGS is not. Use a quick hack to use -O2 if CC
2230 # is set to a version of gcc.
2231 if test "$cc_prog_is_gcc" = yes; then
2232 echo 'void f(){}' > conftest.c
2233 if test -z "`${CC} -g -c conftest.c 2>&1`"; then
2234 CFLAGS=${CFLAGS-"-g -O2"}
2235 CXXFLAGS=${CXXFLAGS-"-g -O2"}
2236 else
2237 CFLAGS=${CFLAGS-"-O2"}
2238 CXXFLAGS=${CXXFLAGS-"-O2"}
2240 rm -f conftest*
2245 # We must set the default linker to the linker used by gcc for the correct
2246 # operation of libtool. If LD is not defined and we are using gcc, try to
2247 # set the LD default to the ld used by gcc.
2248 if test -z "$LD"; then
2249 if test "$cc_prog_is_gcc" = yes; then
2250 case $build in
2251 *-*-mingw*)
2252 gcc_prog_ld=`$CC -print-prog-name=ld 2>&1 | tr -d '\015'` ;;
2254 gcc_prog_ld=`$CC -print-prog-name=ld 2>&1` ;;
2255 esac
2256 case $gcc_prog_ld in
2257 # Accept absolute paths.
2258 [\\/]* | [A-Za-z]:[\\/]*)
2259 LD="$gcc_prog_ld" ;;
2260 esac
2264 CXX=${CXX-"c++"}
2265 CFLAGS=${CFLAGS-"-g"}
2266 CXXFLAGS=${CXXFLAGS-"-g -O2"}
2269 # FIXME Should this be done recursively ??? (Useful for e.g. gdbtest)
2270 # Set up the list of links to be made.
2271 # ${links} is the list of link names, and ${files} is the list of names to link to.
2273 # Make the links.
2274 configlinks="${links}"
2275 if test -r ./config.status ; then
2276 mv -f ./config.status ./config.back
2278 while test -n "${files}" ; do
2279 # set file to car of files, files to cdr of files
2280 set ${files}; file=$1; shift; files=$*
2281 set ${links}; link=$1; shift; links=$*
2283 if test ! -r ${srcdir}/${file} ; then
2284 if test ! -r ${file} ; then
2285 echo '***' "${progname}: cannot create a link \"${link}\"," 1>&2
2286 echo '***' "since the file \"${srcdir}/${file}\" does not exist." 1>&2
2287 exit 1
2288 else
2289 srcfile=${file}
2291 else
2292 srcfile=${srcdir}/${file}
2295 ${remove} -f ${link}
2296 # Make a symlink if possible, otherwise try a hard link
2297 if ${symbolic_link} ${srcfile} ${link} >/dev/null 2>&1 ; then
2298 true
2299 else
2300 # We need to re-remove the file because Lynx leaves a
2301 # very strange directory there when it fails an NFS symlink.
2302 ${remove} -r -f ${link}
2303 ${hard_link} ${srcfile} ${link}
2305 if test ! -r ${link} ; then
2306 echo '***' "${progname}: unable to link \"${link}\" to \"${srcfile}\"." 1>&2
2307 exit 1
2310 echo "Linked \"${link}\" to \"${srcfile}\"."
2311 done
2313 # Create a .gdbinit file which runs the one in srcdir
2314 # and tells GDB to look there for source files.
2316 if test -r ${srcdir}/.gdbinit ; then
2317 case ${srcdir} in
2318 .) ;;
2319 *) cat > ./.gdbinit <<EOF
2320 # ${NO_EDIT}
2321 dir ${srcdir}
2322 dir .
2323 source ${srcdir}/.gdbinit
2326 esac
2329 # Make sure that the compiler is able to generate an executable. If it
2330 # can't, we are probably in trouble. We don't care whether we can run the
2331 # executable--we might be using a cross compiler--we only care whether it
2332 # can be created. At this point the main configure script has set CC.
2333 we_are_ok=no
2334 echo "int main () { return 0; }" > conftest.c
2335 ${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
2336 if test $? = 0 ; then
2337 if test -s conftest || test -s conftest.exe ; then
2338 we_are_ok=yes
2341 case $we_are_ok in
2343 echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
2344 echo 1>&2 "*** You must set the environment variable CC to a working compiler."
2345 rm -f conftest*
2346 exit 1
2348 esac
2349 rm -f conftest*
2351 # The Solaris /usr/ucb/cc compiler does not appear to work.
2352 case "${host}" in
2353 sparc-sun-solaris2*)
2354 CCBASE="`echo ${CC-cc} | sed 's/ .*$//'`"
2355 if test "`type $CCBASE | sed 's/^[^/]*//'`" = "/usr/ucb/cc" ; then
2356 could_use=
2357 test -d /opt/SUNWspro/bin && could_use="/opt/SUNWspro/bin"
2358 if test -d /opt/cygnus/bin ; then
2359 if test "$could_use" = "" ; then
2360 could_use="/opt/cygnus/bin"
2361 else
2362 could_use="$could_use or /opt/cygnus/bin"
2365 if test "$could_use" = "" ; then
2366 echo "Warning: compilation may fail because you're using"
2367 echo "/usr/ucb/cc. You should change your PATH or CC "
2368 echo "variable and rerun configure."
2369 else
2370 echo "Warning: compilation may fail because you're using"
2371 echo "/usr/ucb/cc, when you should use the C compiler from"
2372 echo "$could_use. You should change your"
2373 echo "PATH or CC variable and rerun configure."
2377 esac
2379 # If --enable-shared was set, we must set LD_LIBRARY_PATH so that the
2380 # binutils tools will find libbfd.so.
2381 case "${enable_shared}" in
2382 no | "") SET_LIB_PATH= ;;
2383 *) SET_LIB_PATH="\$(REALLY_SET_LIB_PATH)" ;;
2384 esac
2386 case "${host}" in
2387 *-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
2388 *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
2389 esac
2391 # Record target_configdirs and the configure arguments for target and
2392 # build configuration in Makefile.
2393 target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
2395 # This is the final value for target_configdirs. configdirs already
2396 # has its final value, as does build_modules. It's time to create some
2397 # lists of valid targets.
2399 all_build_modules=
2400 configure_build_modules=
2401 for module in ${build_modules} ; do
2402 all_build_modules=all-build-${module}
2403 configure_build_modules=configure-build-${module}
2404 done
2406 # Determine whether gdb needs tk/tcl or not.
2407 # Use 'maybe' since enable_gdbtk might be true even if tk isn't available
2408 # and in that case we want gdb to be built without tk. Ugh!
2409 # In fact I believe gdb is the *only* package directly dependent on tk,
2410 # so we should be able to put the 'maybe's in unconditionally and
2411 # leave out the maybe dependencies when enable_gdbtk is false. I'm not
2412 # 100% sure that that's safe though.
2414 gdb_tk="maybe-all-tcl maybe-all-tk maybe-all-itcl maybe-all-tix maybe-all-libgui"
2415 case "$enable_gdbtk" in
2417 GDB_TK="" ;;
2418 yes)
2419 GDB_TK="${gdb_tk}" ;;
2421 # Only add the dependency on gdbtk when GDBtk is part of the gdb
2422 # distro. Eventually someone will fix this and move Insight, nee
2423 # gdbtk to a separate directory.
2424 if test -d ${srcdir}/gdb/gdbtk ; then
2425 GDB_TK="${gdb_tk}"
2426 else
2427 GDB_TK=""
2430 esac
2432 # Create the 'maybe dependencies'. This uses a temporary file.
2434 # While at that, we remove Makefiles if we were started for recursive
2435 # configuration, so that the top-level Makefile reconfigures them,
2436 # like we used to do when configure itself was recursive.
2437 rm -f maybedep.tmp
2438 echo '# maybedep.tmp' > maybedep.tmp
2440 # Make-targets which may need maybe dependencies.
2441 mts="configure all install check clean distclean dvi info install-info"
2442 mts="${mts} installcheck mostlyclean maintainer-clean TAGS"
2444 # Loop over modules and make-targets.
2445 for module in ${build_modules} ; do
2446 if test -z "${no_recursion}" \
2447 && test -f ${build_subdir}/${module}/Makefile; then
2448 echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
2449 rm -f ${build_subdir}/${module}/Makefile
2451 for mt in ${mts} ; do
2452 case ${mt} in
2453 install) ;; # No installing build modules.
2454 *) echo "maybe-${mt}-build-${module}: ${mt}-build-${module}" >> maybedep.tmp ;;
2455 esac
2456 done
2457 done
2458 for module in ${configdirs} ; do
2459 if test -z "${no_recursion}" \
2460 && test -f ${module}/Makefile; then
2461 echo 1>&2 "*** removing ${module}/Makefile to force reconfigure"
2462 rm -f ${module}/Makefile
2464 for mt in ${mts} ; do
2465 echo "maybe-${mt}-${module}: ${mt}-${module}" >> maybedep.tmp
2466 done
2467 done
2468 for module in ${target_configdirs} ; do
2469 if test -z "${no_recursion}" \
2470 && test -f ${target_subdir}/${module}/Makefile; then
2471 echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
2472 rm -f ${target_subdir}/${module}/Makefile
2474 for mt in ${mts} ; do
2475 echo "maybe-${mt}-target-${module}: ${mt}-target-${module}" >> maybedep.tmp
2476 done
2477 done
2478 maybe_dependencies=maybedep.tmp
2481 # Create the serialization dependencies. This uses a temporary file.
2483 # Check whether --enable-serial-configure or --disable-serial-configure was given.
2484 if test "${enable_serial_configure+set}" = set; then
2485 enableval="$enable_serial_configure"
2490 case ${enable_serial_configure} in
2491 yes)
2492 enable_serial_build_configure=yes
2493 enable_serial_host_configure=yes
2494 enable_serial_target_configure=yes
2496 esac
2498 # These force 'configure's to be done one at a time, to avoid problems
2499 # with contention over a shared config.cache.
2500 rm -f serdep.tmp
2501 echo '# serdep.tmp' > serdep.tmp
2502 olditem=
2503 test "x${enable_serial_build_configure}" = xyes &&
2504 for item in ${build_configdirs} ; do
2505 case ${olditem} in
2506 "") ;;
2507 *) echo "configure-build-${item}: configure-build-${olditem}" >> serdep.tmp ;;
2508 esac
2509 olditem=${item}
2510 done
2511 olditem=
2512 test "x${enable_serial_host_configure}" = xyes &&
2513 for item in ${configdirs} ; do
2514 case ${olditem} in
2515 "") ;;
2516 *) echo "configure-${item}: configure-${olditem}" >> serdep.tmp ;;
2517 esac
2518 olditem=${item}
2519 done
2520 olditem=
2521 test "x${enable_serial_target_configure}" = xyes &&
2522 for item in ${target_configdirs} ; do
2523 case ${olditem} in
2524 "") ;;
2525 *) echo "configure-target-${item}: configure-target-${olditem}" >> serdep.tmp ;;
2526 esac
2527 olditem=${item}
2528 done
2529 serialization_dependencies=serdep.tmp
2532 # Base args. Strip norecursion, cache-file, srcdir, host, build,
2533 # target and nonopt. These are the ones we might not want to pass
2534 # down to subconfigures. Also strip program-prefix, program-suffix,
2535 # and program-transform-name, so that we can pass down a consistent
2536 # program-transform-name. If autoconf has put single quotes around
2537 # any of these arguments (because they contain shell metacharacters)
2538 # then this will fail; in practice this only happens for
2539 # --program-transform-name, so be sure to override --program-transform-name
2540 # at the end of the argument list.
2541 # These will be expanded by make, so quote '$'.
2542 cat <<\EOF_SED > conftestsed
2543 s/ --no[^ ]*/ /g
2544 s/ --c[a-z-]*[= ][^ ]*//g
2545 s/ --sr[a-z-]*[= ][^ ]*//g
2546 s/ --ho[a-z-]*[= ][^ ]*//g
2547 s/ --bu[a-z-]*[= ][^ ]*//g
2548 s/ --t[a-z-]*[= ][^ ]*//g
2549 s/ --program-[pst][a-z-]*[= ][^ ]*//g
2550 s/ -cache-file[= ][^ ]*//g
2551 s/ -srcdir[= ][^ ]*//g
2552 s/ -host[= ][^ ]*//g
2553 s/ -build[= ][^ ]*//g
2554 s/ -target[= ][^ ]*//g
2555 s/ -program-prefix[= ][^ ]*//g
2556 s/ -program-suffix[= ][^ ]*//g
2557 s/ -program-transform-name[= ][^ ]*//g
2558 s/ [^' -][^ ]* / /
2559 s/^ *//;s/ *$//
2560 s,\$,$$,g
2561 EOF_SED
2562 sed -f conftestsed <<EOF_SED > conftestsed.out
2563 ${ac_configure_args}
2564 EOF_SED
2565 baseargs=`cat conftestsed.out`
2566 rm -f conftestsed conftestsed.out
2568 # Add in --program-transform-name, after --program-prefix and
2569 # --program-suffix have been applied to it. Autoconf has already
2570 # doubled dollar signs and backslashes in program_transform_name; we want
2571 # the backslashes un-doubled, and then the entire thing wrapped in single
2572 # quotes, because this will be expanded first by make and then by the shell.
2573 # Also, because we want to override the logic in subdir configure scripts to
2574 # choose program_transform_name, replace any s,x,x, with s,y,y,.
2575 sed -e "s,\\\\\\\\,\\\\,g; s,','\\\\'',g; s/s,x,x,/s,y,y,/" <<EOF_SED > conftestsed.out
2576 ${program_transform_name}
2577 EOF_SED
2578 gcc_transform_name=`cat conftestsed.out`
2579 rm -f conftestsed.out
2580 baseargs="$baseargs --program-transform-name='${gcc_transform_name}'"
2582 # For the build-side libraries, we just need to pretend we're native,
2583 # and not use the same cache file. Multilibs are neither needed nor
2584 # desired.
2585 build_configargs="--cache-file=../config.cache --build=${build_alias} --host=${build_alias} ${baseargs}"
2587 # For host modules, accept cache file option, or specification as blank.
2588 case "${cache_file}" in
2589 "") # empty
2590 cache_file_option="" ;;
2591 /* | [A-Za-z]:[\\/]* ) # absolute path
2592 cache_file_option="--cache-file=${cache_file}" ;;
2593 *) # relative path
2594 cache_file_option="--cache-file=../${cache_file}" ;;
2595 esac
2597 # Host dirs don't like to share a cache file either, horribly enough.
2598 # This seems to be due to autoconf 2.5x stupidity.
2599 host_configargs="--cache-file=./config.cache --build=${build_alias} --host=${host_alias} --target=${target_alias} ${extra_host_args} ${baseargs}"
2601 target_configargs=${baseargs}
2603 # Passing a --with-cross-host argument lets the target libraries know
2604 # whether they are being built with a cross-compiler or being built
2605 # native. However, it would be better to use other mechanisms to make the
2606 # sorts of decisions they want to make on this basis. Please consider
2607 # this option to be deprecated. FIXME.
2608 if test x${is_cross_compiler} = xyes ; then
2609 target_configargs="--with-cross-host=${host_alias} ${target_configargs}"
2612 # Default to --enable-multilib.
2613 if test x${enable_multilib} = x ; then
2614 target_configargs="--enable-multilib ${target_configargs}"
2617 # Pass --with-newlib if appropriate. Note that target_configdirs has
2618 # changed from the earlier setting of with_newlib.
2619 if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
2620 target_configargs="--with-newlib ${target_configargs}"
2623 # Different target subdirs use different values of certain variables
2624 # (notably CXX). Worse, multilibs use *lots* of different values.
2625 # Worse yet, autoconf 2.5x makes some of these 'precious', meaning that
2626 # it doesn't automatically accept command-line overrides of them.
2627 # This means it's not safe for target subdirs to share a cache file,
2628 # which is disgusting, but there you have it. Hopefully this can be
2629 # fixed in future. It's still worthwhile to use a cache file for each
2630 # directory. I think.
2632 # Pass the appropriate --host, --build, and --cache-file arguments.
2633 target_configargs="--cache-file=./config.cache --host=${target_alias} --build=${build_alias} ${target_configargs}"
2635 # provide a proper gxx_include_dir.
2636 # Note, if you change the default, make sure to fix both here and in
2637 # the gcc and libstdc++-v3 subdirectories.
2638 # Check whether --with-gxx-include-dir or --without-gxx-include-dir was given.
2639 case "${with_gxx_include_dir}" in
2640 yes)
2641 { echo "configure: error: --with-gxx-include-dir=[dir] requires a directory" 1>&2; exit 1; }
2643 no | "")
2644 case "${enable_version_specific_runtime_libs}" in
2645 yes) gxx_include_dir='${libsubdir}/include/c++' ;;
2647 . ${srcdir}/config.if
2648 gxx_include_dir='${prefix}/include/'${libstdcxx_incdir} ;;
2649 esac ;;
2650 *) gxx_include_dir=${with_gxx_include_dir} ;;
2651 esac
2653 FLAGS_FOR_TARGET=
2654 case " $target_configdirs " in
2655 *" newlib "*)
2656 case " $target_configargs " in
2657 *" --with-newlib "*)
2658 case "$target" in
2659 *-cygwin*)
2660 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/include -isystem $$s/winsup/cygwin/include -isystem $$s/winsup/w32api/include' ;;
2661 esac
2663 # If we're not building GCC, don't discard standard headers.
2664 if test -d ${srcdir}/gcc; then
2665 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -nostdinc'
2667 if test "${build}" != "${host}"; then
2668 # On Canadian crosses, CC_FOR_TARGET will have already been set
2669 # by `configure', so we won't have an opportunity to add -Bgcc/
2670 # to it. This is right: we don't want to search that directory
2671 # for binaries, but we want the header files in there, so add
2672 # them explicitly.
2673 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -isystem $$r/gcc/include'
2675 # Someone might think of using the pre-installed headers on
2676 # Canadian crosses, in case the installed compiler is not fully
2677 # compatible with the compiler being built. In this case, it
2678 # would be better to flag an error than risking having
2679 # incompatible object files being constructed. We can't
2680 # guarantee that an error will be flagged, but let's hope the
2681 # compiler will do it, when presented with incompatible header
2682 # files.
2686 case "${target}-${is_cross_compiler}" in
2687 i[3456789]86-*-linux*-no)
2688 # Here host == target, so we don't need to build gcc,
2689 # so we don't want to discard standard headers.
2690 FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
2693 # If we're building newlib, use its generic headers last, but search
2694 # for any libc-related directories first (so make it the last -B
2695 # switch).
2696 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/newlib/ -isystem $$r/$(TARGET_SUBDIR)/newlib/targ-include -isystem $$s/newlib/libc/include'
2698 esac
2700 esac
2702 esac
2704 # Allow the user to override the flags for
2705 # our build compiler if desired.
2706 CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD-${CFLAGS}}
2708 # On Canadian crosses, we'll be searching the right directories for
2709 # the previously-installed cross compiler, so don't bother to add
2710 # flags for directories within the install tree of the compiler
2711 # being built; programs in there won't even run.
2712 if test "${build}" = "${host}" && test -d ${srcdir}/gcc; then
2713 # Search for pre-installed headers if nothing else fits.
2714 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$(build_tooldir)/bin/ -B$(build_tooldir)/lib/ -isystem $(build_tooldir)/include -isystem $(build_tooldir)/sys-include'
2717 if test "x${use_gnu_ld}" = x &&
2718 echo " ${configdirs} " | grep " ld " > /dev/null ; then
2719 # Arrange for us to find uninstalled linker scripts.
2720 FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/ld'
2723 if test "x${CC_FOR_TARGET+set}" = xset; then
2725 elif test -d ${srcdir}/gcc; then
2726 CC_FOR_TARGET='$$r/gcc/xgcc -B$$r/gcc/'
2727 elif test "$host" = "$target"; then
2728 CC_FOR_TARGET='$(CC)'
2729 else
2730 CC_FOR_TARGET=`echo gcc | sed "${program_transform_name}"`
2732 CC_FOR_TARGET=$CC_FOR_TARGET' $(FLAGS_FOR_TARGET)'
2734 if test "x${GCJ_FOR_TARGET+set}" = xset; then
2736 elif test -d ${srcdir}/gcc; then
2737 GCJ_FOR_TARGET='$$r/gcc/gcj -B$$r/gcc/'
2738 elif test "$host" = "$target"; then
2739 GCJ_FOR_TARGET='gcj'
2740 else
2741 GCJ_FOR_TARGET=`echo gcj | sed "${program_transform_name}"`
2743 GCJ_FOR_TARGET=$GCJ_FOR_TARGET' $(FLAGS_FOR_TARGET)'
2745 # Don't use libstdc++-v3's flags to configure/build itself.
2746 libstdcxx_flags='`test ! -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags || $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
2747 raw_libstdcxx_flags='-L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
2749 if test "x${CXX_FOR_TARGET+set}" = xset; then
2750 if test "x${RAW_CXX_FOR_TARGET+set}" != xset; then
2751 RAW_CXX_FOR_TARGET=${CXX_FOR_TARGET}
2753 elif test -d ${srcdir}/gcc; then
2754 # We add -shared-libgcc to CXX_FOR_TARGET whenever we use xgcc instead
2755 # of g++ for linking C++ or Java, because g++ has -shared-libgcc by
2756 # default whereas gcc does not.
2757 # RAW_CXX_FOR_TARGET is for linking C++ or java; CXX_FOR_TARGET is for
2758 # all other cases.
2759 CXX_FOR_TARGET='$$r/gcc/g++ -B$$r/gcc/ -nostdinc++ '$libstdcxx_flags
2760 RAW_CXX_FOR_TARGET='$$r/gcc/xgcc -shared-libgcc -B$$r/gcc/ -nostdinc++ '$raw_libstdcxx_flags
2761 elif test "$host" = "$target"; then
2762 CXX_FOR_TARGET='$(CXX)'
2763 RAW_CXX_FOR_TARGET=${CXX_FOR_TARGET}
2764 else
2765 CXX_FOR_TARGET=`echo c++ | sed "${program_transform_name}"`
2766 RAW_CXX_FOR_TARGET=${CXX_FOR_TARGET}
2768 CXX_FOR_TARGET=$CXX_FOR_TARGET' $(FLAGS_FOR_TARGET)'
2769 RAW_CXX_FOR_TARGET=$RAW_CXX_FOR_TARGET' $(FLAGS_FOR_TARGET)'
2771 qCXX_FOR_TARGET=`echo "$CXX_FOR_TARGET" | sed 's,[&%],\\\&,g'`
2772 qRAW_CXX_FOR_TARGET=`echo "$RAW_CXX_FOR_TARGET" | sed 's,[&%],\\\&,g'`
2774 # We want to defer the evaluation of `cmd`s and shell variables in
2775 # CXX_FOR_TARGET when recursing in the top-level Makefile, such as for
2776 # bootstrap. We'll enclose CXX_FOR_TARGET_FOR_RECURSIVE_MAKE in single
2777 # quotes, but we still have to duplicate `$'s so that shell variables
2778 # can be expanded by the nested make as shell variables, not as make
2779 # macros.
2780 qqCXX_FOR_TARGET=`echo "$qCXX_FOR_TARGET" | sed -e 's,[$][$],$$$$,g'`
2781 qqRAW_CXX_FOR_TARGET=`echo "$qRAW_CXX_FOR_TARGET" | sed -e 's,[$][$],$$$$,g'`
2783 # Wrap CC_FOR_TARGET and friends, for certain types of builds.
2784 CC_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${CC_FOR_TARGET}"
2785 GCJ_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${GCJ_FOR_TARGET}"
2786 CXX_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${qCXX_FOR_TARGET}"
2787 RAW_CXX_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${qRAW_CXX_FOR_TARGET}"
2788 CXX_FOR_TARGET_FOR_RECURSIVE_MAKE="\$(STAGE_CC_WRAPPER) ${qqCXX_FOR_TARGET}"
2789 RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE="\$(STAGE_CC_WRAPPER) ${qqRAW_CXX_FOR_TARGET}"
2791 # Makefile fragments.
2792 host_makefile_frag=${srcdir}/${host_makefile_frag}
2793 target_makefile_frag=${srcdir}/${target_makefile_frag}
2794 alphaieee_frag=${srcdir}/${alphaieee_frag}
2795 ospace_frag=${srcdir}/${ospace_frag}
2801 # Miscellanea: directories, flags, etc.
2815 # Build module lists & subconfigure args.
2820 # Host module lists & subconfigure args.
2824 # Target module lists & subconfigure args.
2828 # Build tools.
2836 # Host tools.
2837 ncn_tool_prefix=
2838 test -n "$host_alias" && ncn_tool_prefix=$host_alias-
2839 ncn_target_tool_prefix=
2840 test -n "$target_alias" && ncn_target_tool_prefix=$target_alias-
2842 if test -n "$ncn_tool_prefix"; then
2843 # Extract the first word of "${ncn_tool_prefix}ar", so it can be a program name with args.
2844 set dummy ${ncn_tool_prefix}ar; ac_word=$2
2845 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2846 echo "configure:2847: checking for $ac_word" >&5
2847 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
2848 echo $ac_n "(cached) $ac_c" 1>&6
2849 else
2850 if test -n "$AR"; then
2851 ac_cv_prog_AR="$AR" # Let the user override the test.
2852 else
2853 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2854 ac_dummy="$PATH"
2855 for ac_dir in $ac_dummy; do
2856 test -z "$ac_dir" && ac_dir=.
2857 if test -f $ac_dir/$ac_word; then
2858 ac_cv_prog_AR="${ncn_tool_prefix}ar"
2859 break
2861 done
2862 IFS="$ac_save_ifs"
2865 AR="$ac_cv_prog_AR"
2866 if test -n "$AR"; then
2867 echo "$ac_t""$AR" 1>&6
2868 else
2869 echo "$ac_t""no" 1>&6
2873 if test -z "$ac_cv_prog_AR" ; then
2874 if test $build = $host ; then
2875 ncn_cv_AR=$AR
2876 # Extract the first word of "ar", so it can be a program name with args.
2877 set dummy ar; ac_word=$2
2878 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2879 echo "configure:2880: checking for $ac_word" >&5
2880 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AR'+set}'`\" = set"; then
2881 echo $ac_n "(cached) $ac_c" 1>&6
2882 else
2883 if test -n "$ncn_cv_AR"; then
2884 ac_cv_prog_ncn_cv_AR="$ncn_cv_AR" # Let the user override the test.
2885 else
2886 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2887 ac_dummy="$PATH"
2888 for ac_dir in $ac_dummy; do
2889 test -z "$ac_dir" && ac_dir=.
2890 if test -f $ac_dir/$ac_word; then
2891 ac_cv_prog_ncn_cv_AR="ar"
2892 break
2894 done
2895 IFS="$ac_save_ifs"
2896 test -z "$ac_cv_prog_ncn_cv_AR" && ac_cv_prog_ncn_cv_AR="ar"
2899 ncn_cv_AR="$ac_cv_prog_ncn_cv_AR"
2900 if test -n "$ncn_cv_AR"; then
2901 echo "$ac_t""$ncn_cv_AR" 1>&6
2902 else
2903 echo "$ac_t""no" 1>&6
2906 AR=$ncn_cv_AR
2907 else
2908 AR="${ncn_tool_prefix}ar"
2910 else
2911 AR="$ac_cv_prog_AR"
2914 if test -n "$ncn_tool_prefix"; then
2915 # Extract the first word of "${ncn_tool_prefix}as", so it can be a program name with args.
2916 set dummy ${ncn_tool_prefix}as; ac_word=$2
2917 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2918 echo "configure:2919: checking for $ac_word" >&5
2919 if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
2920 echo $ac_n "(cached) $ac_c" 1>&6
2921 else
2922 if test -n "$AS"; then
2923 ac_cv_prog_AS="$AS" # Let the user override the test.
2924 else
2925 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2926 ac_dummy="$PATH"
2927 for ac_dir in $ac_dummy; do
2928 test -z "$ac_dir" && ac_dir=.
2929 if test -f $ac_dir/$ac_word; then
2930 ac_cv_prog_AS="${ncn_tool_prefix}as"
2931 break
2933 done
2934 IFS="$ac_save_ifs"
2937 AS="$ac_cv_prog_AS"
2938 if test -n "$AS"; then
2939 echo "$ac_t""$AS" 1>&6
2940 else
2941 echo "$ac_t""no" 1>&6
2945 if test -z "$ac_cv_prog_AS" ; then
2946 if test $build = $host ; then
2947 ncn_cv_AS=$AS
2948 # Extract the first word of "as", so it can be a program name with args.
2949 set dummy as; ac_word=$2
2950 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2951 echo "configure:2952: checking for $ac_word" >&5
2952 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AS'+set}'`\" = set"; then
2953 echo $ac_n "(cached) $ac_c" 1>&6
2954 else
2955 if test -n "$ncn_cv_AS"; then
2956 ac_cv_prog_ncn_cv_AS="$ncn_cv_AS" # Let the user override the test.
2957 else
2958 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2959 ac_dummy="$PATH"
2960 for ac_dir in $ac_dummy; do
2961 test -z "$ac_dir" && ac_dir=.
2962 if test -f $ac_dir/$ac_word; then
2963 ac_cv_prog_ncn_cv_AS="as"
2964 break
2966 done
2967 IFS="$ac_save_ifs"
2968 test -z "$ac_cv_prog_ncn_cv_AS" && ac_cv_prog_ncn_cv_AS="as"
2971 ncn_cv_AS="$ac_cv_prog_ncn_cv_AS"
2972 if test -n "$ncn_cv_AS"; then
2973 echo "$ac_t""$ncn_cv_AS" 1>&6
2974 else
2975 echo "$ac_t""no" 1>&6
2978 AS=$ncn_cv_AS
2979 else
2980 AS="${ncn_tool_prefix}as"
2982 else
2983 AS="$ac_cv_prog_AS"
2986 if test -n "$ncn_tool_prefix"; then
2987 # Extract the first word of "${ncn_tool_prefix}dlltool", so it can be a program name with args.
2988 set dummy ${ncn_tool_prefix}dlltool; ac_word=$2
2989 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
2990 echo "configure:2991: checking for $ac_word" >&5
2991 if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
2992 echo $ac_n "(cached) $ac_c" 1>&6
2993 else
2994 if test -n "$DLLTOOL"; then
2995 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
2996 else
2997 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
2998 ac_dummy="$PATH"
2999 for ac_dir in $ac_dummy; do
3000 test -z "$ac_dir" && ac_dir=.
3001 if test -f $ac_dir/$ac_word; then
3002 ac_cv_prog_DLLTOOL="${ncn_tool_prefix}dlltool"
3003 break
3005 done
3006 IFS="$ac_save_ifs"
3009 DLLTOOL="$ac_cv_prog_DLLTOOL"
3010 if test -n "$DLLTOOL"; then
3011 echo "$ac_t""$DLLTOOL" 1>&6
3012 else
3013 echo "$ac_t""no" 1>&6
3017 if test -z "$ac_cv_prog_DLLTOOL" ; then
3018 if test $build = $host ; then
3019 ncn_cv_DLLTOOL=$DLLTOOL
3020 # Extract the first word of "dlltool", so it can be a program name with args.
3021 set dummy dlltool; ac_word=$2
3022 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3023 echo "configure:3024: checking for $ac_word" >&5
3024 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_DLLTOOL'+set}'`\" = set"; then
3025 echo $ac_n "(cached) $ac_c" 1>&6
3026 else
3027 if test -n "$ncn_cv_DLLTOOL"; then
3028 ac_cv_prog_ncn_cv_DLLTOOL="$ncn_cv_DLLTOOL" # Let the user override the test.
3029 else
3030 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3031 ac_dummy="$PATH"
3032 for ac_dir in $ac_dummy; do
3033 test -z "$ac_dir" && ac_dir=.
3034 if test -f $ac_dir/$ac_word; then
3035 ac_cv_prog_ncn_cv_DLLTOOL="dlltool"
3036 break
3038 done
3039 IFS="$ac_save_ifs"
3040 test -z "$ac_cv_prog_ncn_cv_DLLTOOL" && ac_cv_prog_ncn_cv_DLLTOOL="dlltool"
3043 ncn_cv_DLLTOOL="$ac_cv_prog_ncn_cv_DLLTOOL"
3044 if test -n "$ncn_cv_DLLTOOL"; then
3045 echo "$ac_t""$ncn_cv_DLLTOOL" 1>&6
3046 else
3047 echo "$ac_t""no" 1>&6
3050 DLLTOOL=$ncn_cv_DLLTOOL
3051 else
3052 DLLTOOL="${ncn_tool_prefix}dlltool"
3054 else
3055 DLLTOOL="$ac_cv_prog_DLLTOOL"
3058 if test -n "$ncn_tool_prefix"; then
3059 # Extract the first word of "${ncn_tool_prefix}ld", so it can be a program name with args.
3060 set dummy ${ncn_tool_prefix}ld; ac_word=$2
3061 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3062 echo "configure:3063: checking for $ac_word" >&5
3063 if eval "test \"`echo '$''{'ac_cv_prog_LD'+set}'`\" = set"; then
3064 echo $ac_n "(cached) $ac_c" 1>&6
3065 else
3066 if test -n "$LD"; then
3067 ac_cv_prog_LD="$LD" # Let the user override the test.
3068 else
3069 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3070 ac_dummy="$PATH"
3071 for ac_dir in $ac_dummy; do
3072 test -z "$ac_dir" && ac_dir=.
3073 if test -f $ac_dir/$ac_word; then
3074 ac_cv_prog_LD="${ncn_tool_prefix}ld"
3075 break
3077 done
3078 IFS="$ac_save_ifs"
3081 LD="$ac_cv_prog_LD"
3082 if test -n "$LD"; then
3083 echo "$ac_t""$LD" 1>&6
3084 else
3085 echo "$ac_t""no" 1>&6
3089 if test -z "$ac_cv_prog_LD" ; then
3090 if test $build = $host ; then
3091 ncn_cv_LD=$LD
3092 # Extract the first word of "ld", so it can be a program name with args.
3093 set dummy ld; ac_word=$2
3094 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3095 echo "configure:3096: checking for $ac_word" >&5
3096 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_LD'+set}'`\" = set"; then
3097 echo $ac_n "(cached) $ac_c" 1>&6
3098 else
3099 if test -n "$ncn_cv_LD"; then
3100 ac_cv_prog_ncn_cv_LD="$ncn_cv_LD" # Let the user override the test.
3101 else
3102 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3103 ac_dummy="$PATH"
3104 for ac_dir in $ac_dummy; do
3105 test -z "$ac_dir" && ac_dir=.
3106 if test -f $ac_dir/$ac_word; then
3107 ac_cv_prog_ncn_cv_LD="ld"
3108 break
3110 done
3111 IFS="$ac_save_ifs"
3112 test -z "$ac_cv_prog_ncn_cv_LD" && ac_cv_prog_ncn_cv_LD="ld"
3115 ncn_cv_LD="$ac_cv_prog_ncn_cv_LD"
3116 if test -n "$ncn_cv_LD"; then
3117 echo "$ac_t""$ncn_cv_LD" 1>&6
3118 else
3119 echo "$ac_t""no" 1>&6
3122 LD=$ncn_cv_LD
3123 else
3124 LD="${ncn_tool_prefix}ld"
3126 else
3127 LD="$ac_cv_prog_LD"
3130 if test -n "$ncn_tool_prefix"; then
3131 # Extract the first word of "${ncn_tool_prefix}nm", so it can be a program name with args.
3132 set dummy ${ncn_tool_prefix}nm; ac_word=$2
3133 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3134 echo "configure:3135: checking for $ac_word" >&5
3135 if eval "test \"`echo '$''{'ac_cv_prog_NM'+set}'`\" = set"; then
3136 echo $ac_n "(cached) $ac_c" 1>&6
3137 else
3138 if test -n "$NM"; then
3139 ac_cv_prog_NM="$NM" # Let the user override the test.
3140 else
3141 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3142 ac_dummy="$PATH"
3143 for ac_dir in $ac_dummy; do
3144 test -z "$ac_dir" && ac_dir=.
3145 if test -f $ac_dir/$ac_word; then
3146 ac_cv_prog_NM="${ncn_tool_prefix}nm"
3147 break
3149 done
3150 IFS="$ac_save_ifs"
3153 NM="$ac_cv_prog_NM"
3154 if test -n "$NM"; then
3155 echo "$ac_t""$NM" 1>&6
3156 else
3157 echo "$ac_t""no" 1>&6
3161 if test -z "$ac_cv_prog_NM" ; then
3162 if test $build = $host ; then
3163 ncn_cv_NM=$NM
3164 # Extract the first word of "nm", so it can be a program name with args.
3165 set dummy nm; ac_word=$2
3166 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3167 echo "configure:3168: checking for $ac_word" >&5
3168 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_NM'+set}'`\" = set"; then
3169 echo $ac_n "(cached) $ac_c" 1>&6
3170 else
3171 if test -n "$ncn_cv_NM"; then
3172 ac_cv_prog_ncn_cv_NM="$ncn_cv_NM" # Let the user override the test.
3173 else
3174 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3175 ac_dummy="$PATH"
3176 for ac_dir in $ac_dummy; do
3177 test -z "$ac_dir" && ac_dir=.
3178 if test -f $ac_dir/$ac_word; then
3179 ac_cv_prog_ncn_cv_NM="nm"
3180 break
3182 done
3183 IFS="$ac_save_ifs"
3184 test -z "$ac_cv_prog_ncn_cv_NM" && ac_cv_prog_ncn_cv_NM="nm"
3187 ncn_cv_NM="$ac_cv_prog_ncn_cv_NM"
3188 if test -n "$ncn_cv_NM"; then
3189 echo "$ac_t""$ncn_cv_NM" 1>&6
3190 else
3191 echo "$ac_t""no" 1>&6
3194 NM=$ncn_cv_NM
3195 else
3196 NM="${ncn_tool_prefix}nm"
3198 else
3199 NM="$ac_cv_prog_NM"
3202 if test -n "$ncn_tool_prefix"; then
3203 # Extract the first word of "${ncn_tool_prefix}ranlib", so it can be a program name with args.
3204 set dummy ${ncn_tool_prefix}ranlib; ac_word=$2
3205 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3206 echo "configure:3207: checking for $ac_word" >&5
3207 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
3208 echo $ac_n "(cached) $ac_c" 1>&6
3209 else
3210 if test -n "$RANLIB"; then
3211 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3212 else
3213 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3214 ac_dummy="$PATH"
3215 for ac_dir in $ac_dummy; do
3216 test -z "$ac_dir" && ac_dir=.
3217 if test -f $ac_dir/$ac_word; then
3218 ac_cv_prog_RANLIB="${ncn_tool_prefix}ranlib"
3219 break
3221 done
3222 IFS="$ac_save_ifs"
3225 RANLIB="$ac_cv_prog_RANLIB"
3226 if test -n "$RANLIB"; then
3227 echo "$ac_t""$RANLIB" 1>&6
3228 else
3229 echo "$ac_t""no" 1>&6
3233 if test -z "$ac_cv_prog_RANLIB" ; then
3234 if test $build = $host ; then
3235 ncn_cv_RANLIB=$RANLIB
3236 # Extract the first word of "ranlib", so it can be a program name with args.
3237 set dummy ranlib; ac_word=$2
3238 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3239 echo "configure:3240: checking for $ac_word" >&5
3240 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_RANLIB'+set}'`\" = set"; then
3241 echo $ac_n "(cached) $ac_c" 1>&6
3242 else
3243 if test -n "$ncn_cv_RANLIB"; then
3244 ac_cv_prog_ncn_cv_RANLIB="$ncn_cv_RANLIB" # Let the user override the test.
3245 else
3246 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3247 ac_dummy="$PATH"
3248 for ac_dir in $ac_dummy; do
3249 test -z "$ac_dir" && ac_dir=.
3250 if test -f $ac_dir/$ac_word; then
3251 ac_cv_prog_ncn_cv_RANLIB="ranlib"
3252 break
3254 done
3255 IFS="$ac_save_ifs"
3256 test -z "$ac_cv_prog_ncn_cv_RANLIB" && ac_cv_prog_ncn_cv_RANLIB=":"
3259 ncn_cv_RANLIB="$ac_cv_prog_ncn_cv_RANLIB"
3260 if test -n "$ncn_cv_RANLIB"; then
3261 echo "$ac_t""$ncn_cv_RANLIB" 1>&6
3262 else
3263 echo "$ac_t""no" 1>&6
3266 RANLIB=$ncn_cv_RANLIB
3267 else
3268 RANLIB=":"
3270 else
3271 RANLIB="$ac_cv_prog_RANLIB"
3274 if test -n "$ncn_tool_prefix"; then
3275 # Extract the first word of "${ncn_tool_prefix}windres", so it can be a program name with args.
3276 set dummy ${ncn_tool_prefix}windres; ac_word=$2
3277 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3278 echo "configure:3279: checking for $ac_word" >&5
3279 if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
3280 echo $ac_n "(cached) $ac_c" 1>&6
3281 else
3282 if test -n "$WINDRES"; then
3283 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
3284 else
3285 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3286 ac_dummy="$PATH"
3287 for ac_dir in $ac_dummy; do
3288 test -z "$ac_dir" && ac_dir=.
3289 if test -f $ac_dir/$ac_word; then
3290 ac_cv_prog_WINDRES="${ncn_tool_prefix}windres"
3291 break
3293 done
3294 IFS="$ac_save_ifs"
3297 WINDRES="$ac_cv_prog_WINDRES"
3298 if test -n "$WINDRES"; then
3299 echo "$ac_t""$WINDRES" 1>&6
3300 else
3301 echo "$ac_t""no" 1>&6
3305 if test -z "$ac_cv_prog_WINDRES" ; then
3306 if test $build = $host ; then
3307 ncn_cv_WINDRES=$WINDRES
3308 # Extract the first word of "windres", so it can be a program name with args.
3309 set dummy windres; ac_word=$2
3310 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3311 echo "configure:3312: checking for $ac_word" >&5
3312 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_WINDRES'+set}'`\" = set"; then
3313 echo $ac_n "(cached) $ac_c" 1>&6
3314 else
3315 if test -n "$ncn_cv_WINDRES"; then
3316 ac_cv_prog_ncn_cv_WINDRES="$ncn_cv_WINDRES" # Let the user override the test.
3317 else
3318 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3319 ac_dummy="$PATH"
3320 for ac_dir in $ac_dummy; do
3321 test -z "$ac_dir" && ac_dir=.
3322 if test -f $ac_dir/$ac_word; then
3323 ac_cv_prog_ncn_cv_WINDRES="windres"
3324 break
3326 done
3327 IFS="$ac_save_ifs"
3328 test -z "$ac_cv_prog_ncn_cv_WINDRES" && ac_cv_prog_ncn_cv_WINDRES="windres"
3331 ncn_cv_WINDRES="$ac_cv_prog_ncn_cv_WINDRES"
3332 if test -n "$ncn_cv_WINDRES"; then
3333 echo "$ac_t""$ncn_cv_WINDRES" 1>&6
3334 else
3335 echo "$ac_t""no" 1>&6
3338 WINDRES=$ncn_cv_WINDRES
3339 else
3340 WINDRES="${ncn_tool_prefix}windres"
3342 else
3343 WINDRES="$ac_cv_prog_WINDRES"
3346 if test -n "$ncn_tool_prefix"; then
3347 # Extract the first word of "${ncn_tool_prefix}objcopy", so it can be a program name with args.
3348 set dummy ${ncn_tool_prefix}objcopy; ac_word=$2
3349 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3350 echo "configure:3351: checking for $ac_word" >&5
3351 if eval "test \"`echo '$''{'ac_cv_prog_OBJCOPY'+set}'`\" = set"; then
3352 echo $ac_n "(cached) $ac_c" 1>&6
3353 else
3354 if test -n "$OBJCOPY"; then
3355 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
3356 else
3357 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3358 ac_dummy="$PATH"
3359 for ac_dir in $ac_dummy; do
3360 test -z "$ac_dir" && ac_dir=.
3361 if test -f $ac_dir/$ac_word; then
3362 ac_cv_prog_OBJCOPY="${ncn_tool_prefix}objcopy"
3363 break
3365 done
3366 IFS="$ac_save_ifs"
3369 OBJCOPY="$ac_cv_prog_OBJCOPY"
3370 if test -n "$OBJCOPY"; then
3371 echo "$ac_t""$OBJCOPY" 1>&6
3372 else
3373 echo "$ac_t""no" 1>&6
3377 if test -z "$ac_cv_prog_OBJCOPY" ; then
3378 if test $build = $host ; then
3379 ncn_cv_OBJCOPY=$OBJCOPY
3380 # Extract the first word of "objcopy", so it can be a program name with args.
3381 set dummy objcopy; ac_word=$2
3382 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3383 echo "configure:3384: checking for $ac_word" >&5
3384 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_OBJCOPY'+set}'`\" = set"; then
3385 echo $ac_n "(cached) $ac_c" 1>&6
3386 else
3387 if test -n "$ncn_cv_OBJCOPY"; then
3388 ac_cv_prog_ncn_cv_OBJCOPY="$ncn_cv_OBJCOPY" # Let the user override the test.
3389 else
3390 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3391 ac_dummy="$PATH"
3392 for ac_dir in $ac_dummy; do
3393 test -z "$ac_dir" && ac_dir=.
3394 if test -f $ac_dir/$ac_word; then
3395 ac_cv_prog_ncn_cv_OBJCOPY="objcopy"
3396 break
3398 done
3399 IFS="$ac_save_ifs"
3400 test -z "$ac_cv_prog_ncn_cv_OBJCOPY" && ac_cv_prog_ncn_cv_OBJCOPY="objcopy"
3403 ncn_cv_OBJCOPY="$ac_cv_prog_ncn_cv_OBJCOPY"
3404 if test -n "$ncn_cv_OBJCOPY"; then
3405 echo "$ac_t""$ncn_cv_OBJCOPY" 1>&6
3406 else
3407 echo "$ac_t""no" 1>&6
3410 OBJCOPY=$ncn_cv_OBJCOPY
3411 else
3412 OBJCOPY="${ncn_tool_prefix}objcopy"
3414 else
3415 OBJCOPY="$ac_cv_prog_OBJCOPY"
3418 if test -n "$ncn_tool_prefix"; then
3419 # Extract the first word of "${ncn_tool_prefix}objdump", so it can be a program name with args.
3420 set dummy ${ncn_tool_prefix}objdump; ac_word=$2
3421 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3422 echo "configure:3423: checking for $ac_word" >&5
3423 if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP'+set}'`\" = set"; then
3424 echo $ac_n "(cached) $ac_c" 1>&6
3425 else
3426 if test -n "$OBJDUMP"; then
3427 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
3428 else
3429 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3430 ac_dummy="$PATH"
3431 for ac_dir in $ac_dummy; do
3432 test -z "$ac_dir" && ac_dir=.
3433 if test -f $ac_dir/$ac_word; then
3434 ac_cv_prog_OBJDUMP="${ncn_tool_prefix}objdump"
3435 break
3437 done
3438 IFS="$ac_save_ifs"
3441 OBJDUMP="$ac_cv_prog_OBJDUMP"
3442 if test -n "$OBJDUMP"; then
3443 echo "$ac_t""$OBJDUMP" 1>&6
3444 else
3445 echo "$ac_t""no" 1>&6
3449 if test -z "$ac_cv_prog_OBJDUMP" ; then
3450 if test $build = $host ; then
3451 ncn_cv_OBJDUMP=$OBJDUMP
3452 # Extract the first word of "objdump", so it can be a program name with args.
3453 set dummy objdump; ac_word=$2
3454 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3455 echo "configure:3456: checking for $ac_word" >&5
3456 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_OBJDUMP'+set}'`\" = set"; then
3457 echo $ac_n "(cached) $ac_c" 1>&6
3458 else
3459 if test -n "$ncn_cv_OBJDUMP"; then
3460 ac_cv_prog_ncn_cv_OBJDUMP="$ncn_cv_OBJDUMP" # Let the user override the test.
3461 else
3462 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3463 ac_dummy="$PATH"
3464 for ac_dir in $ac_dummy; do
3465 test -z "$ac_dir" && ac_dir=.
3466 if test -f $ac_dir/$ac_word; then
3467 ac_cv_prog_ncn_cv_OBJDUMP="objdump"
3468 break
3470 done
3471 IFS="$ac_save_ifs"
3472 test -z "$ac_cv_prog_ncn_cv_OBJDUMP" && ac_cv_prog_ncn_cv_OBJDUMP="objdump"
3475 ncn_cv_OBJDUMP="$ac_cv_prog_ncn_cv_OBJDUMP"
3476 if test -n "$ncn_cv_OBJDUMP"; then
3477 echo "$ac_t""$ncn_cv_OBJDUMP" 1>&6
3478 else
3479 echo "$ac_t""no" 1>&6
3482 OBJDUMP=$ncn_cv_OBJDUMP
3483 else
3484 OBJDUMP="${ncn_tool_prefix}objdump"
3486 else
3487 OBJDUMP="$ac_cv_prog_OBJDUMP"
3499 # Target tools.
3500 if test -n "$ncn_target_tool_prefix"; then
3501 # Extract the first word of "${ncn_target_tool_prefix}ar", so it can be a program name with args.
3502 set dummy ${ncn_target_tool_prefix}ar; ac_word=$2
3503 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3504 echo "configure:3505: checking for $ac_word" >&5
3505 if eval "test \"`echo '$''{'ac_cv_prog_AR_FOR_TARGET'+set}'`\" = set"; then
3506 echo $ac_n "(cached) $ac_c" 1>&6
3507 else
3508 if test -n "$AR_FOR_TARGET"; then
3509 ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
3510 else
3511 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3512 ac_dummy="$PATH"
3513 for ac_dir in $ac_dummy; do
3514 test -z "$ac_dir" && ac_dir=.
3515 if test -f $ac_dir/$ac_word; then
3516 ac_cv_prog_AR_FOR_TARGET="${ncn_target_tool_prefix}ar"
3517 break
3519 done
3520 IFS="$ac_save_ifs"
3523 AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
3524 if test -n "$AR_FOR_TARGET"; then
3525 echo "$ac_t""$AR_FOR_TARGET" 1>&6
3526 else
3527 echo "$ac_t""no" 1>&6
3531 if test -z "$ac_cv_prog_AR_FOR_TARGET" ; then
3532 if test $build = $target ; then
3533 ncn_cv_AR_FOR_TARGET=$AR_FOR_TARGET
3534 # Extract the first word of "ar", so it can be a program name with args.
3535 set dummy ar; ac_word=$2
3536 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3537 echo "configure:3538: checking for $ac_word" >&5
3538 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AR_FOR_TARGET'+set}'`\" = set"; then
3539 echo $ac_n "(cached) $ac_c" 1>&6
3540 else
3541 if test -n "$ncn_cv_AR_FOR_TARGET"; then
3542 ac_cv_prog_ncn_cv_AR_FOR_TARGET="$ncn_cv_AR_FOR_TARGET" # Let the user override the test.
3543 else
3544 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3545 ac_dummy="$PATH"
3546 for ac_dir in $ac_dummy; do
3547 test -z "$ac_dir" && ac_dir=.
3548 if test -f $ac_dir/$ac_word; then
3549 ac_cv_prog_ncn_cv_AR_FOR_TARGET="ar"
3550 break
3552 done
3553 IFS="$ac_save_ifs"
3554 test -z "$ac_cv_prog_ncn_cv_AR_FOR_TARGET" && ac_cv_prog_ncn_cv_AR_FOR_TARGET="ar"
3557 ncn_cv_AR_FOR_TARGET="$ac_cv_prog_ncn_cv_AR_FOR_TARGET"
3558 if test -n "$ncn_cv_AR_FOR_TARGET"; then
3559 echo "$ac_t""$ncn_cv_AR_FOR_TARGET" 1>&6
3560 else
3561 echo "$ac_t""no" 1>&6
3564 AR_FOR_TARGET=$ncn_cv_AR_FOR_TARGET
3565 else
3566 AR_FOR_TARGET="${ncn_target_tool_prefix}ar"
3568 else
3569 AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
3572 if test -n "$ncn_target_tool_prefix"; then
3573 # Extract the first word of "${ncn_target_tool_prefix}as", so it can be a program name with args.
3574 set dummy ${ncn_target_tool_prefix}as; ac_word=$2
3575 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3576 echo "configure:3577: checking for $ac_word" >&5
3577 if eval "test \"`echo '$''{'ac_cv_prog_AS_FOR_TARGET'+set}'`\" = set"; then
3578 echo $ac_n "(cached) $ac_c" 1>&6
3579 else
3580 if test -n "$AS_FOR_TARGET"; then
3581 ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
3582 else
3583 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3584 ac_dummy="$PATH"
3585 for ac_dir in $ac_dummy; do
3586 test -z "$ac_dir" && ac_dir=.
3587 if test -f $ac_dir/$ac_word; then
3588 ac_cv_prog_AS_FOR_TARGET="${ncn_target_tool_prefix}as"
3589 break
3591 done
3592 IFS="$ac_save_ifs"
3595 AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
3596 if test -n "$AS_FOR_TARGET"; then
3597 echo "$ac_t""$AS_FOR_TARGET" 1>&6
3598 else
3599 echo "$ac_t""no" 1>&6
3603 if test -z "$ac_cv_prog_AS_FOR_TARGET" ; then
3604 if test $build = $target ; then
3605 ncn_cv_AS_FOR_TARGET=$AS_FOR_TARGET
3606 # Extract the first word of "as", so it can be a program name with args.
3607 set dummy as; ac_word=$2
3608 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3609 echo "configure:3610: checking for $ac_word" >&5
3610 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AS_FOR_TARGET'+set}'`\" = set"; then
3611 echo $ac_n "(cached) $ac_c" 1>&6
3612 else
3613 if test -n "$ncn_cv_AS_FOR_TARGET"; then
3614 ac_cv_prog_ncn_cv_AS_FOR_TARGET="$ncn_cv_AS_FOR_TARGET" # Let the user override the test.
3615 else
3616 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3617 ac_dummy="$PATH"
3618 for ac_dir in $ac_dummy; do
3619 test -z "$ac_dir" && ac_dir=.
3620 if test -f $ac_dir/$ac_word; then
3621 ac_cv_prog_ncn_cv_AS_FOR_TARGET="as"
3622 break
3624 done
3625 IFS="$ac_save_ifs"
3626 test -z "$ac_cv_prog_ncn_cv_AS_FOR_TARGET" && ac_cv_prog_ncn_cv_AS_FOR_TARGET="as"
3629 ncn_cv_AS_FOR_TARGET="$ac_cv_prog_ncn_cv_AS_FOR_TARGET"
3630 if test -n "$ncn_cv_AS_FOR_TARGET"; then
3631 echo "$ac_t""$ncn_cv_AS_FOR_TARGET" 1>&6
3632 else
3633 echo "$ac_t""no" 1>&6
3636 AS_FOR_TARGET=$ncn_cv_AS_FOR_TARGET
3637 else
3638 AS_FOR_TARGET="${ncn_target_tool_prefix}as"
3640 else
3641 AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
3644 if test -n "$ncn_target_tool_prefix"; then
3645 # Extract the first word of "${ncn_target_tool_prefix}dlltool", so it can be a program name with args.
3646 set dummy ${ncn_target_tool_prefix}dlltool; ac_word=$2
3647 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3648 echo "configure:3649: checking for $ac_word" >&5
3649 if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
3650 echo $ac_n "(cached) $ac_c" 1>&6
3651 else
3652 if test -n "$DLLTOOL_FOR_TARGET"; then
3653 ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
3654 else
3655 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3656 ac_dummy="$PATH"
3657 for ac_dir in $ac_dummy; do
3658 test -z "$ac_dir" && ac_dir=.
3659 if test -f $ac_dir/$ac_word; then
3660 ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}dlltool"
3661 break
3663 done
3664 IFS="$ac_save_ifs"
3667 DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
3668 if test -n "$DLLTOOL_FOR_TARGET"; then
3669 echo "$ac_t""$DLLTOOL_FOR_TARGET" 1>&6
3670 else
3671 echo "$ac_t""no" 1>&6
3675 if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" ; then
3676 if test $build = $target ; then
3677 ncn_cv_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
3678 # Extract the first word of "dlltool", so it can be a program name with args.
3679 set dummy dlltool; ac_word=$2
3680 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3681 echo "configure:3682: checking for $ac_word" >&5
3682 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
3683 echo $ac_n "(cached) $ac_c" 1>&6
3684 else
3685 if test -n "$ncn_cv_DLLTOOL_FOR_TARGET"; then
3686 ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET="$ncn_cv_DLLTOOL_FOR_TARGET" # Let the user override the test.
3687 else
3688 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3689 ac_dummy="$PATH"
3690 for ac_dir in $ac_dummy; do
3691 test -z "$ac_dir" && ac_dir=.
3692 if test -f $ac_dir/$ac_word; then
3693 ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET="dlltool"
3694 break
3696 done
3697 IFS="$ac_save_ifs"
3698 test -z "$ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET" && ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET="dlltool"
3701 ncn_cv_DLLTOOL_FOR_TARGET="$ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET"
3702 if test -n "$ncn_cv_DLLTOOL_FOR_TARGET"; then
3703 echo "$ac_t""$ncn_cv_DLLTOOL_FOR_TARGET" 1>&6
3704 else
3705 echo "$ac_t""no" 1>&6
3708 DLLTOOL_FOR_TARGET=$ncn_cv_DLLTOOL_FOR_TARGET
3709 else
3710 DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}dlltool"
3712 else
3713 DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
3716 if test -n "$ncn_target_tool_prefix"; then
3717 # Extract the first word of "${ncn_target_tool_prefix}ld", so it can be a program name with args.
3718 set dummy ${ncn_target_tool_prefix}ld; ac_word=$2
3719 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3720 echo "configure:3721: checking for $ac_word" >&5
3721 if eval "test \"`echo '$''{'ac_cv_prog_LD_FOR_TARGET'+set}'`\" = set"; then
3722 echo $ac_n "(cached) $ac_c" 1>&6
3723 else
3724 if test -n "$LD_FOR_TARGET"; then
3725 ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
3726 else
3727 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3728 ac_dummy="$PATH"
3729 for ac_dir in $ac_dummy; do
3730 test -z "$ac_dir" && ac_dir=.
3731 if test -f $ac_dir/$ac_word; then
3732 ac_cv_prog_LD_FOR_TARGET="${ncn_target_tool_prefix}ld"
3733 break
3735 done
3736 IFS="$ac_save_ifs"
3739 LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
3740 if test -n "$LD_FOR_TARGET"; then
3741 echo "$ac_t""$LD_FOR_TARGET" 1>&6
3742 else
3743 echo "$ac_t""no" 1>&6
3747 if test -z "$ac_cv_prog_LD_FOR_TARGET" ; then
3748 if test $build = $target ; then
3749 ncn_cv_LD_FOR_TARGET=$LD_FOR_TARGET
3750 # Extract the first word of "ld", so it can be a program name with args.
3751 set dummy ld; ac_word=$2
3752 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3753 echo "configure:3754: checking for $ac_word" >&5
3754 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_LD_FOR_TARGET'+set}'`\" = set"; then
3755 echo $ac_n "(cached) $ac_c" 1>&6
3756 else
3757 if test -n "$ncn_cv_LD_FOR_TARGET"; then
3758 ac_cv_prog_ncn_cv_LD_FOR_TARGET="$ncn_cv_LD_FOR_TARGET" # Let the user override the test.
3759 else
3760 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3761 ac_dummy="$PATH"
3762 for ac_dir in $ac_dummy; do
3763 test -z "$ac_dir" && ac_dir=.
3764 if test -f $ac_dir/$ac_word; then
3765 ac_cv_prog_ncn_cv_LD_FOR_TARGET="ld"
3766 break
3768 done
3769 IFS="$ac_save_ifs"
3770 test -z "$ac_cv_prog_ncn_cv_LD_FOR_TARGET" && ac_cv_prog_ncn_cv_LD_FOR_TARGET="ld"
3773 ncn_cv_LD_FOR_TARGET="$ac_cv_prog_ncn_cv_LD_FOR_TARGET"
3774 if test -n "$ncn_cv_LD_FOR_TARGET"; then
3775 echo "$ac_t""$ncn_cv_LD_FOR_TARGET" 1>&6
3776 else
3777 echo "$ac_t""no" 1>&6
3780 LD_FOR_TARGET=$ncn_cv_LD_FOR_TARGET
3781 else
3782 LD_FOR_TARGET="${ncn_target_tool_prefix}ld"
3784 else
3785 LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
3788 if test -n "$ncn_target_tool_prefix"; then
3789 # Extract the first word of "${ncn_target_tool_prefix}nm", so it can be a program name with args.
3790 set dummy ${ncn_target_tool_prefix}nm; ac_word=$2
3791 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3792 echo "configure:3793: checking for $ac_word" >&5
3793 if eval "test \"`echo '$''{'ac_cv_prog_NM_FOR_TARGET'+set}'`\" = set"; then
3794 echo $ac_n "(cached) $ac_c" 1>&6
3795 else
3796 if test -n "$NM_FOR_TARGET"; then
3797 ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
3798 else
3799 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3800 ac_dummy="$PATH"
3801 for ac_dir in $ac_dummy; do
3802 test -z "$ac_dir" && ac_dir=.
3803 if test -f $ac_dir/$ac_word; then
3804 ac_cv_prog_NM_FOR_TARGET="${ncn_target_tool_prefix}nm"
3805 break
3807 done
3808 IFS="$ac_save_ifs"
3811 NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
3812 if test -n "$NM_FOR_TARGET"; then
3813 echo "$ac_t""$NM_FOR_TARGET" 1>&6
3814 else
3815 echo "$ac_t""no" 1>&6
3819 if test -z "$ac_cv_prog_NM_FOR_TARGET" ; then
3820 if test $build = $target ; then
3821 ncn_cv_NM_FOR_TARGET=$NM_FOR_TARGET
3822 # Extract the first word of "nm", so it can be a program name with args.
3823 set dummy nm; ac_word=$2
3824 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3825 echo "configure:3826: checking for $ac_word" >&5
3826 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_NM_FOR_TARGET'+set}'`\" = set"; then
3827 echo $ac_n "(cached) $ac_c" 1>&6
3828 else
3829 if test -n "$ncn_cv_NM_FOR_TARGET"; then
3830 ac_cv_prog_ncn_cv_NM_FOR_TARGET="$ncn_cv_NM_FOR_TARGET" # Let the user override the test.
3831 else
3832 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3833 ac_dummy="$PATH"
3834 for ac_dir in $ac_dummy; do
3835 test -z "$ac_dir" && ac_dir=.
3836 if test -f $ac_dir/$ac_word; then
3837 ac_cv_prog_ncn_cv_NM_FOR_TARGET="nm"
3838 break
3840 done
3841 IFS="$ac_save_ifs"
3842 test -z "$ac_cv_prog_ncn_cv_NM_FOR_TARGET" && ac_cv_prog_ncn_cv_NM_FOR_TARGET="nm"
3845 ncn_cv_NM_FOR_TARGET="$ac_cv_prog_ncn_cv_NM_FOR_TARGET"
3846 if test -n "$ncn_cv_NM_FOR_TARGET"; then
3847 echo "$ac_t""$ncn_cv_NM_FOR_TARGET" 1>&6
3848 else
3849 echo "$ac_t""no" 1>&6
3852 NM_FOR_TARGET=$ncn_cv_NM_FOR_TARGET
3853 else
3854 NM_FOR_TARGET="${ncn_target_tool_prefix}nm"
3856 else
3857 NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
3860 if test -n "$ncn_target_tool_prefix"; then
3861 # Extract the first word of "${ncn_target_tool_prefix}ranlib", so it can be a program name with args.
3862 set dummy ${ncn_target_tool_prefix}ranlib; ac_word=$2
3863 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3864 echo "configure:3865: checking for $ac_word" >&5
3865 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB_FOR_TARGET'+set}'`\" = set"; then
3866 echo $ac_n "(cached) $ac_c" 1>&6
3867 else
3868 if test -n "$RANLIB_FOR_TARGET"; then
3869 ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
3870 else
3871 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3872 ac_dummy="$PATH"
3873 for ac_dir in $ac_dummy; do
3874 test -z "$ac_dir" && ac_dir=.
3875 if test -f $ac_dir/$ac_word; then
3876 ac_cv_prog_RANLIB_FOR_TARGET="${ncn_target_tool_prefix}ranlib"
3877 break
3879 done
3880 IFS="$ac_save_ifs"
3883 RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
3884 if test -n "$RANLIB_FOR_TARGET"; then
3885 echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
3886 else
3887 echo "$ac_t""no" 1>&6
3891 if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" ; then
3892 if test $build = $target ; then
3893 ncn_cv_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
3894 # Extract the first word of "ranlib", so it can be a program name with args.
3895 set dummy ranlib; ac_word=$2
3896 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3897 echo "configure:3898: checking for $ac_word" >&5
3898 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET'+set}'`\" = set"; then
3899 echo $ac_n "(cached) $ac_c" 1>&6
3900 else
3901 if test -n "$ncn_cv_RANLIB_FOR_TARGET"; then
3902 ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET="$ncn_cv_RANLIB_FOR_TARGET" # Let the user override the test.
3903 else
3904 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3905 ac_dummy="$PATH"
3906 for ac_dir in $ac_dummy; do
3907 test -z "$ac_dir" && ac_dir=.
3908 if test -f $ac_dir/$ac_word; then
3909 ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET="ranlib"
3910 break
3912 done
3913 IFS="$ac_save_ifs"
3914 test -z "$ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET" && ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET=":"
3917 ncn_cv_RANLIB_FOR_TARGET="$ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET"
3918 if test -n "$ncn_cv_RANLIB_FOR_TARGET"; then
3919 echo "$ac_t""$ncn_cv_RANLIB_FOR_TARGET" 1>&6
3920 else
3921 echo "$ac_t""no" 1>&6
3924 RANLIB_FOR_TARGET=$ncn_cv_RANLIB_FOR_TARGET
3925 else
3926 RANLIB_FOR_TARGET=":"
3928 else
3929 RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
3932 if test -n "$ncn_target_tool_prefix"; then
3933 # Extract the first word of "${ncn_target_tool_prefix}windres", so it can be a program name with args.
3934 set dummy ${ncn_target_tool_prefix}windres; ac_word=$2
3935 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3936 echo "configure:3937: checking for $ac_word" >&5
3937 if eval "test \"`echo '$''{'ac_cv_prog_WINDRES_FOR_TARGET'+set}'`\" = set"; then
3938 echo $ac_n "(cached) $ac_c" 1>&6
3939 else
3940 if test -n "$WINDRES_FOR_TARGET"; then
3941 ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
3942 else
3943 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3944 ac_dummy="$PATH"
3945 for ac_dir in $ac_dummy; do
3946 test -z "$ac_dir" && ac_dir=.
3947 if test -f $ac_dir/$ac_word; then
3948 ac_cv_prog_WINDRES_FOR_TARGET="${ncn_target_tool_prefix}windres"
3949 break
3951 done
3952 IFS="$ac_save_ifs"
3955 WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
3956 if test -n "$WINDRES_FOR_TARGET"; then
3957 echo "$ac_t""$WINDRES_FOR_TARGET" 1>&6
3958 else
3959 echo "$ac_t""no" 1>&6
3963 if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" ; then
3964 if test $build = $target ; then
3965 ncn_cv_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
3966 # Extract the first word of "windres", so it can be a program name with args.
3967 set dummy windres; ac_word=$2
3968 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
3969 echo "configure:3970: checking for $ac_word" >&5
3970 if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET'+set}'`\" = set"; then
3971 echo $ac_n "(cached) $ac_c" 1>&6
3972 else
3973 if test -n "$ncn_cv_WINDRES_FOR_TARGET"; then
3974 ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET="$ncn_cv_WINDRES_FOR_TARGET" # Let the user override the test.
3975 else
3976 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
3977 ac_dummy="$PATH"
3978 for ac_dir in $ac_dummy; do
3979 test -z "$ac_dir" && ac_dir=.
3980 if test -f $ac_dir/$ac_word; then
3981 ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET="windres"
3982 break
3984 done
3985 IFS="$ac_save_ifs"
3986 test -z "$ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET" && ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET="windres"
3989 ncn_cv_WINDRES_FOR_TARGET="$ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET"
3990 if test -n "$ncn_cv_WINDRES_FOR_TARGET"; then
3991 echo "$ac_t""$ncn_cv_WINDRES_FOR_TARGET" 1>&6
3992 else
3993 echo "$ac_t""no" 1>&6
3996 WINDRES_FOR_TARGET=$ncn_cv_WINDRES_FOR_TARGET
3997 else
3998 WINDRES_FOR_TARGET="${ncn_target_tool_prefix}windres"
4000 else
4001 WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
4014 # Fix up target tools.
4015 if test "x${build}" = "x${host}" ; then
4016 # In this case, the newly built tools can and should be used,
4017 # so we override the results of the autoconf tests.
4018 # This should really only happen when the tools are actually being built,
4019 # but that's a further refinement. The new build scheme, where
4020 # tools are built into a structure paralleling where they're installed,
4021 # should also eliminate all of this cleanly.
4022 AR_FOR_TARGET="\$(USUAL_AR_FOR_TARGET)"
4023 AS_FOR_TARGET="\$(USUAL_AS_FOR_TARGET)"
4024 DLLTOOL_FOR_TARGET="\$(USUAL_DLLTOOL_FOR_TARGET)"
4025 LD_FOR_TARGET="\$(USUAL_LD_FOR_TARGET)"
4026 NM_FOR_TARGET="\$(USUAL_NM_FOR_TARGET)"
4027 RANLIB_FOR_TARGET="\$(USUAL_RANLIB_FOR_TARGET)"
4028 WINDRES_FOR_TARGET="\$(USUAL_WINDRES_FOR_TARGET)"
4030 # Certain tools may need extra flags.
4031 AR_FOR_TARGET=${AR_FOR_TARGET}${extra_arflags_for_target}
4032 RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET}${extra_ranlibflags_for_target}
4033 NM_FOR_TARGET=${NM_FOR_TARGET}${extra_nmflags_for_target}
4035 echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
4036 echo "configure:4037: checking whether to enable maintainer-specific portions of Makefiles" >&5
4037 # Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
4038 if test "${enable_maintainer_mode+set}" = set; then
4039 enableval="$enable_maintainer_mode"
4040 USE_MAINTAINER_MODE=$enableval
4041 else
4042 USE_MAINTAINER_MODE=no
4045 echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
4048 if test "$USE_MAINTAINER_MODE" = yes; then
4049 MAINTAINER_MODE_TRUE=
4050 MAINTAINER_MODE_FALSE='#'
4051 else
4052 MAINTAINER_MODE_TRUE='#'
4053 MAINTAINER_MODE_FALSE=
4055 MAINT=$MAINTAINER_MODE_TRUE
4057 trap '' 1 2 15
4058 cat > confcache <<\EOF
4059 # This file is a shell script that caches the results of configure
4060 # tests run on this system so they can be shared between configure
4061 # scripts and configure runs. It is not useful on other systems.
4062 # If it contains results you don't want to keep, you may remove or edit it.
4064 # By default, configure uses ./config.cache as the cache file,
4065 # creating it if it does not exist already. You can give configure
4066 # the --cache-file=FILE option to use a different cache file; that is
4067 # what configure does when it calls configure scripts in
4068 # subdirectories, so they share the cache.
4069 # Giving --cache-file=/dev/null disables caching, for debugging configure.
4070 # config.status only pays attention to the cache file if you give it the
4071 # --recheck option to rerun configure.
4074 # The following way of writing the cache mishandles newlines in values,
4075 # but we know of no workaround that is simple, portable, and efficient.
4076 # So, don't put newlines in cache variables' values.
4077 # Ultrix sh set writes to stderr and can't be redirected directly,
4078 # and sets the high bit in the cache file unless we assign to the vars.
4079 (set) 2>&1 |
4080 case `(ac_space=' '; set | grep ac_space) 2>&1` in
4081 *ac_space=\ *)
4082 # `set' does not quote correctly, so add quotes (double-quote substitution
4083 # turns \\\\ into \\, and sed turns \\ into \).
4084 sed -n \
4085 -e "s/'/'\\\\''/g" \
4086 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
4089 # `set' quotes correctly as required by POSIX, so do not add quotes.
4090 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
4092 esac >> confcache
4093 if cmp -s $cache_file confcache; then
4095 else
4096 if test -w $cache_file; then
4097 echo "updating cache $cache_file"
4098 cat confcache > $cache_file
4099 else
4100 echo "not updating unwritable cache $cache_file"
4103 rm -f confcache
4105 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
4107 test "x$prefix" = xNONE && prefix=$ac_default_prefix
4108 # Let make expand exec_prefix.
4109 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
4111 # Any assignment to VPATH causes Sun make to only execute
4112 # the first set of double-colon rules, so remove it if not needed.
4113 # If there is a colon in the path, we need to keep it.
4114 if test "x$srcdir" = x.; then
4115 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
4118 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
4120 # Transform confdefs.h into DEFS.
4121 # Protect against shell expansion while executing Makefile rules.
4122 # Protect against Makefile macro expansion.
4123 cat > conftest.defs <<\EOF
4124 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
4125 s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
4126 s%\[%\\&%g
4127 s%\]%\\&%g
4128 s%\$%$$%g
4130 DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
4131 rm -f conftest.defs
4134 # Without the "./", some shells look in PATH for config.status.
4135 : ${CONFIG_STATUS=./config.status}
4137 echo creating $CONFIG_STATUS
4138 rm -f $CONFIG_STATUS
4139 cat > $CONFIG_STATUS <<EOF
4140 #! /bin/sh
4141 # Generated automatically by configure.
4142 # Run this file to recreate the current configuration.
4143 # This directory was configured as follows,
4144 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
4146 # $0 $ac_configure_args
4148 # Compiler output produced by configure, useful for debugging
4149 # configure, is in ./config.log if it exists.
4151 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
4152 for ac_option
4154 case "\$ac_option" in
4155 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
4156 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
4157 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
4158 -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
4159 echo "$CONFIG_STATUS generated by autoconf version 2.13"
4160 exit 0 ;;
4161 -help | --help | --hel | --he | --h)
4162 echo "\$ac_cs_usage"; exit 0 ;;
4163 *) echo "\$ac_cs_usage"; exit 1 ;;
4164 esac
4165 done
4167 ac_given_srcdir=$srcdir
4168 ac_given_INSTALL="$INSTALL"
4170 trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
4172 cat >> $CONFIG_STATUS <<EOF
4174 # Protect against being on the right side of a sed subst in config.status.
4175 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
4176 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
4177 $ac_vpsub
4178 $extrasub
4179 s%@SHELL@%$SHELL%g
4180 s%@CFLAGS@%$CFLAGS%g
4181 s%@CPPFLAGS@%$CPPFLAGS%g
4182 s%@CXXFLAGS@%$CXXFLAGS%g
4183 s%@FFLAGS@%$FFLAGS%g
4184 s%@DEFS@%$DEFS%g
4185 s%@LDFLAGS@%$LDFLAGS%g
4186 s%@LIBS@%$LIBS%g
4187 s%@exec_prefix@%$exec_prefix%g
4188 s%@prefix@%$prefix%g
4189 s%@program_transform_name@%$program_transform_name%g
4190 s%@bindir@%$bindir%g
4191 s%@sbindir@%$sbindir%g
4192 s%@libexecdir@%$libexecdir%g
4193 s%@datadir@%$datadir%g
4194 s%@sysconfdir@%$sysconfdir%g
4195 s%@sharedstatedir@%$sharedstatedir%g
4196 s%@localstatedir@%$localstatedir%g
4197 s%@libdir@%$libdir%g
4198 s%@includedir@%$includedir%g
4199 s%@oldincludedir@%$oldincludedir%g
4200 s%@infodir@%$infodir%g
4201 s%@mandir@%$mandir%g
4202 s%@host@%$host%g
4203 s%@host_alias@%$host_alias%g
4204 s%@host_cpu@%$host_cpu%g
4205 s%@host_vendor@%$host_vendor%g
4206 s%@host_os@%$host_os%g
4207 s%@target@%$target%g
4208 s%@target_alias@%$target_alias%g
4209 s%@target_cpu@%$target_cpu%g
4210 s%@target_vendor@%$target_vendor%g
4211 s%@target_os@%$target_os%g
4212 s%@build@%$build%g
4213 s%@build_alias@%$build_alias%g
4214 s%@build_cpu@%$build_cpu%g
4215 s%@build_vendor@%$build_vendor%g
4216 s%@build_os@%$build_os%g
4217 s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
4218 s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
4219 s%@INSTALL_DATA@%$INSTALL_DATA%g
4220 s%@TOPLEVEL_CONFIGURE_ARGUMENTS@%$TOPLEVEL_CONFIGURE_ARGUMENTS%g
4221 s%@build_subdir@%$build_subdir%g
4222 s%@host_subdir@%$host_subdir%g
4223 s%@target_subdir@%$target_subdir%g
4224 /@maybe_dependencies@/r $maybe_dependencies
4225 s%@maybe_dependencies@%%g
4226 /@serialization_dependencies@/r $serialization_dependencies
4227 s%@serialization_dependencies@%%g
4228 /@host_makefile_frag@/r $host_makefile_frag
4229 s%@host_makefile_frag@%%g
4230 /@target_makefile_frag@/r $target_makefile_frag
4231 s%@target_makefile_frag@%%g
4232 /@alphaieee_frag@/r $alphaieee_frag
4233 s%@alphaieee_frag@%%g
4234 /@ospace_frag@/r $ospace_frag
4235 s%@ospace_frag@%%g
4236 s%@SET_LIB_PATH@%$SET_LIB_PATH%g
4237 s%@RPATH_ENVVAR@%$RPATH_ENVVAR%g
4238 s%@BUILD_PREFIX@%$BUILD_PREFIX%g
4239 s%@BUILD_PREFIX_1@%$BUILD_PREFIX_1%g
4240 s%@configlinks@%$configlinks%g
4241 s%@gcc_version_trigger@%$gcc_version_trigger%g
4242 s%@gcc_version@%$gcc_version%g
4243 s%@tooldir@%$tooldir%g
4244 s%@build_tooldir@%$build_tooldir%g
4245 s%@GDB_TK@%$GDB_TK%g
4246 s%@gxx_include_dir@%$gxx_include_dir%g
4247 s%@libstdcxx_incdir@%$libstdcxx_incdir%g
4248 s%@build_configargs@%$build_configargs%g
4249 s%@configure_build_modules@%$configure_build_modules%g
4250 s%@all_build_modules@%$all_build_modules%g
4251 s%@host_configargs@%$host_configargs%g
4252 s%@configdirs@%$configdirs%g
4253 s%@target_configargs@%$target_configargs%g
4254 s%@target_configdirs@%$target_configdirs%g
4255 s%@BISON@%$BISON%g
4256 s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
4257 s%@LEX@%$LEX%g
4258 s%@MAKEINFO@%$MAKEINFO%g
4259 s%@YACC@%$YACC%g
4260 s%@config_shell@%$config_shell%g
4261 s%@AR@%$AR%g
4262 s%@ncn_cv_AR@%$ncn_cv_AR%g
4263 s%@AS@%$AS%g
4264 s%@ncn_cv_AS@%$ncn_cv_AS%g
4265 s%@DLLTOOL@%$DLLTOOL%g
4266 s%@ncn_cv_DLLTOOL@%$ncn_cv_DLLTOOL%g
4267 s%@LD@%$LD%g
4268 s%@ncn_cv_LD@%$ncn_cv_LD%g
4269 s%@NM@%$NM%g
4270 s%@ncn_cv_NM@%$ncn_cv_NM%g
4271 s%@RANLIB@%$RANLIB%g
4272 s%@ncn_cv_RANLIB@%$ncn_cv_RANLIB%g
4273 s%@WINDRES@%$WINDRES%g
4274 s%@ncn_cv_WINDRES@%$ncn_cv_WINDRES%g
4275 s%@OBJCOPY@%$OBJCOPY%g
4276 s%@ncn_cv_OBJCOPY@%$ncn_cv_OBJCOPY%g
4277 s%@OBJDUMP@%$OBJDUMP%g
4278 s%@ncn_cv_OBJDUMP@%$ncn_cv_OBJDUMP%g
4279 s%@CC@%$CC%g
4280 s%@CXX@%$CXX%g
4281 s%@CFLAGS_FOR_BUILD@%$CFLAGS_FOR_BUILD%g
4282 s%@DEFAULT_YACC@%$DEFAULT_YACC%g
4283 s%@DEFAULT_LEX@%$DEFAULT_LEX%g
4284 s%@DEFAULT_M4@%$DEFAULT_M4%g
4285 s%@AR_FOR_TARGET@%$AR_FOR_TARGET%g
4286 s%@ncn_cv_AR_FOR_TARGET@%$ncn_cv_AR_FOR_TARGET%g
4287 s%@AS_FOR_TARGET@%$AS_FOR_TARGET%g
4288 s%@ncn_cv_AS_FOR_TARGET@%$ncn_cv_AS_FOR_TARGET%g
4289 s%@DLLTOOL_FOR_TARGET@%$DLLTOOL_FOR_TARGET%g
4290 s%@ncn_cv_DLLTOOL_FOR_TARGET@%$ncn_cv_DLLTOOL_FOR_TARGET%g
4291 s%@LD_FOR_TARGET@%$LD_FOR_TARGET%g
4292 s%@ncn_cv_LD_FOR_TARGET@%$ncn_cv_LD_FOR_TARGET%g
4293 s%@NM_FOR_TARGET@%$NM_FOR_TARGET%g
4294 s%@ncn_cv_NM_FOR_TARGET@%$ncn_cv_NM_FOR_TARGET%g
4295 s%@RANLIB_FOR_TARGET@%$RANLIB_FOR_TARGET%g
4296 s%@ncn_cv_RANLIB_FOR_TARGET@%$ncn_cv_RANLIB_FOR_TARGET%g
4297 s%@WINDRES_FOR_TARGET@%$WINDRES_FOR_TARGET%g
4298 s%@ncn_cv_WINDRES_FOR_TARGET@%$ncn_cv_WINDRES_FOR_TARGET%g
4299 s%@GCC_FOR_TARGET@%$GCC_FOR_TARGET%g
4300 s%@FLAGS_FOR_TARGET@%$FLAGS_FOR_TARGET%g
4301 s%@CC_FOR_TARGET@%$CC_FOR_TARGET%g
4302 s%@GCJ_FOR_TARGET@%$GCJ_FOR_TARGET%g
4303 s%@CXX_FOR_TARGET@%$CXX_FOR_TARGET%g
4304 s%@RAW_CXX_FOR_TARGET@%$RAW_CXX_FOR_TARGET%g
4305 s%@CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@%$CXX_FOR_TARGET_FOR_RECURSIVE_MAKE%g
4306 s%@RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@%$RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE%g
4307 s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
4308 s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
4309 s%@MAINT@%$MAINT%g
4311 CEOF
4314 cat >> $CONFIG_STATUS <<\EOF
4316 # Split the substitutions into bite-sized pieces for seds with
4317 # small command number limits, like on Digital OSF/1 and HP-UX.
4318 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
4319 ac_file=1 # Number of current file.
4320 ac_beg=1 # First line for current file.
4321 ac_end=$ac_max_sed_cmds # Line after last line for current file.
4322 ac_more_lines=:
4323 ac_sed_cmds=""
4324 while $ac_more_lines; do
4325 if test $ac_beg -gt 1; then
4326 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
4327 else
4328 sed "${ac_end}q" conftest.subs > conftest.s$ac_file
4330 if test ! -s conftest.s$ac_file; then
4331 ac_more_lines=false
4332 rm -f conftest.s$ac_file
4333 else
4334 if test -z "$ac_sed_cmds"; then
4335 ac_sed_cmds="sed -f conftest.s$ac_file"
4336 else
4337 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
4339 ac_file=`expr $ac_file + 1`
4340 ac_beg=$ac_end
4341 ac_end=`expr $ac_end + $ac_max_sed_cmds`
4343 done
4344 if test -z "$ac_sed_cmds"; then
4345 ac_sed_cmds=cat
4349 cat >> $CONFIG_STATUS <<EOF
4351 CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
4353 cat >> $CONFIG_STATUS <<\EOF
4354 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
4355 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
4356 case "$ac_file" in
4357 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
4358 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
4359 *) ac_file_in="${ac_file}.in" ;;
4360 esac
4362 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
4364 # Remove last slash and all that follows it. Not all systems have dirname.
4365 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4366 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4367 # The file is in a subdirectory.
4368 test ! -d "$ac_dir" && mkdir "$ac_dir"
4369 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
4370 # A "../" for each directory in $ac_dir_suffix.
4371 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
4372 else
4373 ac_dir_suffix= ac_dots=
4376 case "$ac_given_srcdir" in
4377 .) srcdir=.
4378 if test -z "$ac_dots"; then top_srcdir=.
4379 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
4380 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
4381 *) # Relative path.
4382 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
4383 top_srcdir="$ac_dots$ac_given_srcdir" ;;
4384 esac
4386 case "$ac_given_INSTALL" in
4387 [/$]*) INSTALL="$ac_given_INSTALL" ;;
4388 *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
4389 esac
4391 echo creating "$ac_file"
4392 rm -f "$ac_file"
4393 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
4394 case "$ac_file" in
4395 *Makefile*) ac_comsub="1i\\
4396 # $configure_input" ;;
4397 *) ac_comsub= ;;
4398 esac
4400 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4401 sed -e "$ac_comsub
4402 s%@configure_input@%$configure_input%g
4403 s%@srcdir@%$srcdir%g
4404 s%@top_srcdir@%$top_srcdir%g
4405 s%@INSTALL@%$INSTALL%g
4406 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
4407 fi; done
4408 rm -f conftest.s*
4411 cat >> $CONFIG_STATUS <<EOF
4414 cat >> $CONFIG_STATUS <<\EOF
4416 exit 0
4418 chmod +x $CONFIG_STATUS
4419 rm -fr confdefs* $ac_clean_files
4420 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1