Merge branch 'vendor/MDOCML'
[dragonfly.git] / contrib / gmp / configure
1 #! /bin/sh
2 # From configure.in Revision.
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by GNU Autoconf 2.61 for GNU MP 4.3.2.
5 #
6 # Report bugs to <gmp-bugs@gmplib.org>.
7 #
8 #
9 #
10 # Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
11 # 2007 Free Software Foundation, Inc.
12 #
13 # This file is part of the GNU MP Library.
14 #
15 # The GNU MP Library is free software; you can redistribute it and/or modify
16 # it under the terms of the GNU Lesser General Public License as published
17 # by the Free Software Foundation; either version 3 of the License, or (at
18 # your option) any later version.
19 #
20 # The GNU MP Library is distributed in the hope that it will be useful, but
21 # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
22 # or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public
23 # License for more details.
24 #
25 # You should have received a copy of the GNU Lesser General Public License
26 # along with the GNU MP Library.  If not, see http://www.gnu.org/licenses/.
27 #
28 #
29 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
30 # 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
31 # This configure script is free software; the Free Software Foundation
32 # gives unlimited permission to copy, distribute and modify it.
33 ## --------------------- ##
34 ## M4sh Initialization.  ##
35 ## --------------------- ##
36
37 # Be more Bourne compatible
38 DUALCASE=1; export DUALCASE # for MKS sh
39 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
40   emulate sh
41   NULLCMD=:
42   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
43   # is contrary to our usage.  Disable this feature.
44   alias -g '${1+"$@"}'='"$@"'
45   setopt NO_GLOB_SUBST
46 else
47   case `(set -o) 2>/dev/null` in
48   *posix*) set -o posix ;;
49 esac
50
51 fi
52
53
54
55
56 # PATH needs CR
57 # Avoid depending upon Character Ranges.
58 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
59 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
60 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
61 as_cr_digits='0123456789'
62 as_cr_alnum=$as_cr_Letters$as_cr_digits
63
64 # The user is always right.
65 if test "${PATH_SEPARATOR+set}" != set; then
66   echo "#! /bin/sh" >conf$$.sh
67   echo  "exit 0"   >>conf$$.sh
68   chmod +x conf$$.sh
69   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
70     PATH_SEPARATOR=';'
71   else
72     PATH_SEPARATOR=:
73   fi
74   rm -f conf$$.sh
75 fi
76
77 # Support unset when possible.
78 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
79   as_unset=unset
80 else
81   as_unset=false
82 fi
83
84
85 # IFS
86 # We need space, tab and new line, in precisely that order.  Quoting is
87 # there to prevent editors from complaining about space-tab.
88 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
89 # splitting by setting IFS to empty value.)
90 as_nl='
91 '
92 IFS=" ""        $as_nl"
93
94 # Find who we are.  Look in the path if we contain no directory separator.
95 case $0 in
96   *[\\/]* ) as_myself=$0 ;;
97   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
98 for as_dir in $PATH
99 do
100   IFS=$as_save_IFS
101   test -z "$as_dir" && as_dir=.
102   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
103 done
104 IFS=$as_save_IFS
105
106      ;;
107 esac
108 # We did not find ourselves, most probably we were run as `sh COMMAND'
109 # in which case we are not to be found in the path.
110 if test "x$as_myself" = x; then
111   as_myself=$0
112 fi
113 if test ! -f "$as_myself"; then
114   echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
115   { (exit 1); exit 1; }
116 fi
117
118 # Work around bugs in pre-3.0 UWIN ksh.
119 for as_var in ENV MAIL MAILPATH
120 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
121 done
122 PS1='$ '
123 PS2='> '
124 PS4='+ '
125
126 # NLS nuisances.
127 for as_var in \
128   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
129   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
130   LC_TELEPHONE LC_TIME
131 do
132   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
133     eval $as_var=C; export $as_var
134   else
135     ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
136   fi
137 done
138
139 # Required to use basename.
140 if expr a : '\(a\)' >/dev/null 2>&1 &&
141    test "X`expr 00001 : '.*\(...\)'`" = X001; then
142   as_expr=expr
143 else
144   as_expr=false
145 fi
146
147 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
148   as_basename=basename
149 else
150   as_basename=false
151 fi
152
153
154 # Name of the executable.
155 as_me=`$as_basename -- "$0" ||
156 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
157          X"$0" : 'X\(//\)$' \| \
158          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
159 echo X/"$0" |
160     sed '/^.*\/\([^/][^/]*\)\/*$/{
161             s//\1/
162             q
163           }
164           /^X\/\(\/\/\)$/{
165             s//\1/
166             q
167           }
168           /^X\/\(\/\).*/{
169             s//\1/
170             q
171           }
172           s/.*/./; q'`
173
174 # CDPATH.
175 $as_unset CDPATH
176
177
178 if test "x$CONFIG_SHELL" = x; then
179   if (eval ":") 2>/dev/null; then
180   as_have_required=yes
181 else
182   as_have_required=no
183 fi
184
185   if test $as_have_required = yes &&     (eval ":
186 (as_func_return () {
187   (exit \$1)
188 }
189 as_func_success () {
190   as_func_return 0
191 }
192 as_func_failure () {
193   as_func_return 1
194 }
195 as_func_ret_success () {
196   return 0
197 }
198 as_func_ret_failure () {
199   return 1
200 }
201
202 exitcode=0
203 if as_func_success; then
204   :
205 else
206   exitcode=1
207   echo as_func_success failed.
208 fi
209
210 if as_func_failure; then
211   exitcode=1
212   echo as_func_failure succeeded.
213 fi
214
215 if as_func_ret_success; then
216   :
217 else
218   exitcode=1
219   echo as_func_ret_success failed.
220 fi
221
222 if as_func_ret_failure; then
223   exitcode=1
224   echo as_func_ret_failure succeeded.
225 fi
226
227 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
228   :
229 else
230   exitcode=1
231   echo positional parameters were not saved.
232 fi
233
234 test \$exitcode = 0) || { (exit 1); exit 1; }
235
236 (
237   as_lineno_1=\$LINENO
238   as_lineno_2=\$LINENO
239   test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
240   test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
241 ") 2> /dev/null; then
242   :
243 else
244   as_candidate_shells=
245     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
246 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
247 do
248   IFS=$as_save_IFS
249   test -z "$as_dir" && as_dir=.
250   case $as_dir in
251          /*)
252            for as_base in sh bash ksh sh5; do
253              as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
254            done;;
255        esac
256 done
257 IFS=$as_save_IFS
258
259
260       for as_shell in $as_candidate_shells $SHELL; do
261          # Try only shells that exist, to save several forks.
262          if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
263                 { ("$as_shell") 2> /dev/null <<\_ASEOF
264 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
265   emulate sh
266   NULLCMD=:
267   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
268   # is contrary to our usage.  Disable this feature.
269   alias -g '${1+"$@"}'='"$@"'
270   setopt NO_GLOB_SUBST
271 else
272   case `(set -o) 2>/dev/null` in
273   *posix*) set -o posix ;;
274 esac
275
276 fi
277
278
279 :
280 _ASEOF
281 }; then
282   CONFIG_SHELL=$as_shell
283                as_have_required=yes
284                if { "$as_shell" 2> /dev/null <<\_ASEOF
285 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
286   emulate sh
287   NULLCMD=:
288   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
289   # is contrary to our usage.  Disable this feature.
290   alias -g '${1+"$@"}'='"$@"'
291   setopt NO_GLOB_SUBST
292 else
293   case `(set -o) 2>/dev/null` in
294   *posix*) set -o posix ;;
295 esac
296
297 fi
298
299
300 :
301 (as_func_return () {
302   (exit $1)
303 }
304 as_func_success () {
305   as_func_return 0
306 }
307 as_func_failure () {
308   as_func_return 1
309 }
310 as_func_ret_success () {
311   return 0
312 }
313 as_func_ret_failure () {
314   return 1
315 }
316
317 exitcode=0
318 if as_func_success; then
319   :
320 else
321   exitcode=1
322   echo as_func_success failed.
323 fi
324
325 if as_func_failure; then
326   exitcode=1
327   echo as_func_failure succeeded.
328 fi
329
330 if as_func_ret_success; then
331   :
332 else
333   exitcode=1
334   echo as_func_ret_success failed.
335 fi
336
337 if as_func_ret_failure; then
338   exitcode=1
339   echo as_func_ret_failure succeeded.
340 fi
341
342 if ( set x; as_func_ret_success y && test x = "$1" ); then
343   :
344 else
345   exitcode=1
346   echo positional parameters were not saved.
347 fi
348
349 test $exitcode = 0) || { (exit 1); exit 1; }
350
351 (
352   as_lineno_1=$LINENO
353   as_lineno_2=$LINENO
354   test "x$as_lineno_1" != "x$as_lineno_2" &&
355   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
356
357 _ASEOF
358 }; then
359   break
360 fi
361
362 fi
363
364       done
365
366       if test "x$CONFIG_SHELL" != x; then
367   for as_var in BASH_ENV ENV
368         do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
369         done
370         export CONFIG_SHELL
371         exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
372 fi
373
374
375     if test $as_have_required = no; then
376   echo This script requires a shell more modern than all the
377       echo shells that I found on your system.  Please install a
378       echo modern shell, or manually run the script under such a
379       echo shell if you do have one.
380       { (exit 1); exit 1; }
381 fi
382
383
384 fi
385
386 fi
387
388
389
390 (eval "as_func_return () {
391   (exit \$1)
392 }
393 as_func_success () {
394   as_func_return 0
395 }
396 as_func_failure () {
397   as_func_return 1
398 }
399 as_func_ret_success () {
400   return 0
401 }
402 as_func_ret_failure () {
403   return 1
404 }
405
406 exitcode=0
407 if as_func_success; then
408   :
409 else
410   exitcode=1
411   echo as_func_success failed.
412 fi
413
414 if as_func_failure; then
415   exitcode=1
416   echo as_func_failure succeeded.
417 fi
418
419 if as_func_ret_success; then
420   :
421 else
422   exitcode=1
423   echo as_func_ret_success failed.
424 fi
425
426 if as_func_ret_failure; then
427   exitcode=1
428   echo as_func_ret_failure succeeded.
429 fi
430
431 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
432   :
433 else
434   exitcode=1
435   echo positional parameters were not saved.
436 fi
437
438 test \$exitcode = 0") || {
439   echo No shell found that supports shell functions.
440   echo Please tell autoconf@gnu.org about your system,
441   echo including any error possibly output before this
442   echo message
443 }
444
445
446
447   as_lineno_1=$LINENO
448   as_lineno_2=$LINENO
449   test "x$as_lineno_1" != "x$as_lineno_2" &&
450   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
451
452   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
453   # uniformly replaced by the line number.  The first 'sed' inserts a
454   # line-number line after each line using $LINENO; the second 'sed'
455   # does the real work.  The second script uses 'N' to pair each
456   # line-number line with the line containing $LINENO, and appends
457   # trailing '-' during substitution so that $LINENO is not a special
458   # case at line end.
459   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
460   # scripts with optimization help from Paolo Bonzini.  Blame Lee
461   # E. McMahon (1931-1989) for sed's syntax.  :-)
462   sed -n '
463     p
464     /[$]LINENO/=
465   ' <$as_myself |
466     sed '
467       s/[$]LINENO.*/&-/
468       t lineno
469       b
470       :lineno
471       N
472       :loop
473       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
474       t loop
475       s/-\n.*//
476     ' >$as_me.lineno &&
477   chmod +x "$as_me.lineno" ||
478     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
479    { (exit 1); exit 1; }; }
480
481   # Don't try to exec as it changes $[0], causing all sort of problems
482   # (the dirname of $[0] is not the place where we might find the
483   # original and so on.  Autoconf is especially sensitive to this).
484   . "./$as_me.lineno"
485   # Exit status is that of the last command.
486   exit
487 }
488
489
490 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
491   as_dirname=dirname
492 else
493   as_dirname=false
494 fi
495
496 ECHO_C= ECHO_N= ECHO_T=
497 case `echo -n x` in
498 -n*)
499   case `echo 'x\c'` in
500   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
501   *)   ECHO_C='\c';;
502   esac;;
503 *)
504   ECHO_N='-n';;
505 esac
506
507 if expr a : '\(a\)' >/dev/null 2>&1 &&
508    test "X`expr 00001 : '.*\(...\)'`" = X001; then
509   as_expr=expr
510 else
511   as_expr=false
512 fi
513
514 rm -f conf$$ conf$$.exe conf$$.file
515 if test -d conf$$.dir; then
516   rm -f conf$$.dir/conf$$.file
517 else
518   rm -f conf$$.dir
519   mkdir conf$$.dir
520 fi
521 echo >conf$$.file
522 if ln -s conf$$.file conf$$ 2>/dev/null; then
523   as_ln_s='ln -s'
524   # ... but there are two gotchas:
525   # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
526   # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
527   # In both cases, we have to default to `cp -p'.
528   ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
529     as_ln_s='cp -p'
530 elif ln conf$$.file conf$$ 2>/dev/null; then
531   as_ln_s=ln
532 else
533   as_ln_s='cp -p'
534 fi
535 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
536 rmdir conf$$.dir 2>/dev/null
537
538 if mkdir -p . 2>/dev/null; then
539   as_mkdir_p=:
540 else
541   test -d ./-p && rmdir ./-p
542   as_mkdir_p=false
543 fi
544
545 if test -x / >/dev/null 2>&1; then
546   as_test_x='test -x'
547 else
548   if ls -dL / >/dev/null 2>&1; then
549     as_ls_L_option=L
550   else
551     as_ls_L_option=
552   fi
553   as_test_x='
554     eval sh -c '\''
555       if test -d "$1"; then
556         test -d "$1/.";
557       else
558         case $1 in
559         -*)set "./$1";;
560         esac;
561         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
562         ???[sx]*):;;*)false;;esac;fi
563     '\'' sh
564   '
565 fi
566 as_executable_p=$as_test_x
567
568 # Sed expression to map a string onto a valid CPP name.
569 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
570
571 # Sed expression to map a string onto a valid variable name.
572 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
573
574
575
576
577 # Check that we are running under the correct shell.
578 SHELL=${CONFIG_SHELL-/bin/sh}
579
580 case X$ECHO in
581 X*--fallback-echo)
582   # Remove one level of quotation (which was required for Make).
583   ECHO=`echo "$ECHO" | sed 's,\\\\\$\\$0,'$0','`
584   ;;
585 esac
586
587 echo=${ECHO-echo}
588 if test "X$1" = X--no-reexec; then
589   # Discard the --no-reexec flag, and continue.
590   shift
591 elif test "X$1" = X--fallback-echo; then
592   # Avoid inline document here, it may be left over
593   :
594 elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then
595   # Yippee, $echo works!
596   :
597 else
598   # Restart under the correct shell.
599   exec $SHELL "$0" --no-reexec ${1+"$@"}
600 fi
601
602 if test "X$1" = X--fallback-echo; then
603   # used as fallback echo
604   shift
605   cat <<EOF
606 $*
607 EOF
608   exit 0
609 fi
610
611 # The HP-UX ksh and POSIX shell print the target directory to stdout
612 # if CDPATH is set.
613 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
614
615 if test -z "$ECHO"; then
616 if test "X${echo_test_string+set}" != Xset; then
617 # find a string as large as possible, as long as the shell can cope with it
618   for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do
619     # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
620     if (echo_test_string=`eval $cmd`) 2>/dev/null &&
621        echo_test_string=`eval $cmd` &&
622        (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null
623     then
624       break
625     fi
626   done
627 fi
628
629 if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
630    echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
631    test "X$echo_testing_string" = "X$echo_test_string"; then
632   :
633 else
634   # The Solaris, AIX, and Digital Unix default echo programs unquote
635   # backslashes.  This makes it impossible to quote backslashes using
636   #   echo "$something" | sed 's/\\/\\\\/g'
637   #
638   # So, first we look for a working echo in the user's PATH.
639
640   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
641   for dir in $PATH /usr/ucb; do
642     IFS="$lt_save_ifs"
643     if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
644        test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
645        echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
646        test "X$echo_testing_string" = "X$echo_test_string"; then
647       echo="$dir/echo"
648       break
649     fi
650   done
651   IFS="$lt_save_ifs"
652
653   if test "X$echo" = Xecho; then
654     # We didn't find a better echo, so look for alternatives.
655     if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' &&
656        echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` &&
657        test "X$echo_testing_string" = "X$echo_test_string"; then
658       # This shell has a builtin print -r that does the trick.
659       echo='print -r'
660     elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) &&
661          test "X$CONFIG_SHELL" != X/bin/ksh; then
662       # If we have ksh, try running configure again with it.
663       ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
664       export ORIGINAL_CONFIG_SHELL
665       CONFIG_SHELL=/bin/ksh
666       export CONFIG_SHELL
667       exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"}
668     else
669       # Try using printf.
670       echo='printf %s\n'
671       if test "X`($echo '\t') 2>/dev/null`" = 'X\t' &&
672          echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` &&
673          test "X$echo_testing_string" = "X$echo_test_string"; then
674         # Cool, printf works
675         :
676       elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
677            test "X$echo_testing_string" = 'X\t' &&
678            echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
679            test "X$echo_testing_string" = "X$echo_test_string"; then
680         CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
681         export CONFIG_SHELL
682         SHELL="$CONFIG_SHELL"
683         export SHELL
684         echo="$CONFIG_SHELL $0 --fallback-echo"
685       elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
686            test "X$echo_testing_string" = 'X\t' &&
687            echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
688            test "X$echo_testing_string" = "X$echo_test_string"; then
689         echo="$CONFIG_SHELL $0 --fallback-echo"
690       else
691         # maybe with a smaller string...
692         prev=:
693
694         for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do
695           if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null
696           then
697             break
698           fi
699           prev="$cmd"
700         done
701
702         if test "$prev" != 'sed 50q "$0"'; then
703           echo_test_string=`eval $prev`
704           export echo_test_string
705           exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"}
706         else
707           # Oops.  We lost completely, so just stick with echo.
708           echo=echo
709         fi
710       fi
711     fi
712   fi
713 fi
714 fi
715
716 # Copy echo and quote the copy suitably for passing to libtool from
717 # the Makefile, instead of quoting the original, which is used later.
718 ECHO=$echo
719 if test "X$ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then
720    ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo"
721 fi
722
723
724
725
726 tagnames=${tagnames+${tagnames},}CXX
727
728 tagnames=${tagnames+${tagnames},}F77
729
730 exec 7<&0 </dev/null 6>&1
731
732 # Name of the host.
733 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
734 # so uname gets run too.
735 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
736
737 #
738 # Initializations.
739 #
740 ac_default_prefix=/usr/local
741 ac_clean_files=
742 ac_config_libobj_dir=.
743 LIBOBJS=
744 cross_compiling=no
745 subdirs=
746 MFLAGS=
747 MAKEFLAGS=
748 SHELL=${CONFIG_SHELL-/bin/sh}
749
750 # Identity of this package.
751 PACKAGE_NAME='GNU MP'
752 PACKAGE_TARNAME='gmp'
753 PACKAGE_VERSION='4.3.2'
754 PACKAGE_STRING='GNU MP 4.3.2'
755 PACKAGE_BUGREPORT='gmp-bugs@gmplib.org'
756
757 ac_unique_file="gmp-impl.h"
758 # Factoring default headers for most tests.
759 ac_includes_default="\
760 #include <stdio.h>
761 #ifdef HAVE_SYS_TYPES_H
762 # include <sys/types.h>
763 #endif
764 #ifdef HAVE_SYS_STAT_H
765 # include <sys/stat.h>
766 #endif
767 #ifdef STDC_HEADERS
768 # include <stdlib.h>
769 # include <stddef.h>
770 #else
771 # ifdef HAVE_STDLIB_H
772 #  include <stdlib.h>
773 # endif
774 #endif
775 #ifdef HAVE_STRING_H
776 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
777 #  include <memory.h>
778 # endif
779 # include <string.h>
780 #endif
781 #ifdef HAVE_STRINGS_H
782 # include <strings.h>
783 #endif
784 #ifdef HAVE_INTTYPES_H
785 # include <inttypes.h>
786 #endif
787 #ifdef HAVE_STDINT_H
788 # include <stdint.h>
789 #endif
790 #ifdef HAVE_UNISTD_H
791 # include <unistd.h>
792 #endif"
793
794 ac_subst_vars='SHELL
795 PATH_SEPARATOR
796 PACKAGE_NAME
797 PACKAGE_TARNAME
798 PACKAGE_VERSION
799 PACKAGE_STRING
800 PACKAGE_BUGREPORT
801 exec_prefix
802 prefix
803 program_transform_name
804 bindir
805 sbindir
806 libexecdir
807 datarootdir
808 datadir
809 sysconfdir
810 sharedstatedir
811 localstatedir
812 includedir
813 oldincludedir
814 docdir
815 infodir
816 htmldir
817 dvidir
818 pdfdir
819 psdir
820 libdir
821 localedir
822 mandir
823 DEFS
824 ECHO_C
825 ECHO_N
826 ECHO_T
827 LIBS
828 build_alias
829 host_alias
830 target_alias
831 build
832 build_cpu
833 build_vendor
834 build_os
835 host
836 host_cpu
837 host_vendor
838 host_os
839 INSTALL_PROGRAM
840 INSTALL_SCRIPT
841 INSTALL_DATA
842 CYGPATH_W
843 PACKAGE
844 VERSION
845 ACLOCAL
846 AUTOCONF
847 AUTOMAKE
848 AUTOHEADER
849 MAKEINFO
850 AMTAR
851 install_sh
852 STRIP
853 INSTALL_STRIP_PROGRAM
854 mkdir_p
855 AWK
856 SET_MAKE
857 am__leading_dot
858 MAINTAINER_MODE_TRUE
859 MAINTAINER_MODE_FALSE
860 MAINT
861 WANT_MPBSD_TRUE
862 WANT_MPBSD_FALSE
863 GMP_NAIL_BITS
864 ABI
865 HAVE_HOST_CPU_FAMILY_power
866 HAVE_HOST_CPU_FAMILY_powerpc
867 GMP_LDFLAGS
868 LIBGMP_LDFLAGS
869 LIBGMPXX_LDFLAGS
870 SPEED_CYCLECOUNTER_OBJ
871 CALLING_CONVENTIONS_OBJS
872 DEFN_LONG_LONG_LIMB
873 CC
874 CFLAGS
875 LDFLAGS
876 CPPFLAGS
877 ac_ct_CC
878 EXEEXT
879 OBJEXT
880 CPP
881 CC_FOR_BUILD
882 CPP_FOR_BUILD
883 EXEEXT_FOR_BUILD
884 U_FOR_BUILD
885 LIBM_FOR_BUILD
886 CCAS
887 CXX
888 CXXFLAGS
889 ac_ct_CXX
890 WANT_CXX_TRUE
891 WANT_CXX_FALSE
892 CXXCPP
893 GREP
894 EGREP
895 U
896 ANSI2KNR
897 ASMFLAGS
898 AR
899 LIBGMP_DLL
900 SED
901 LN_S
902 ECHO
903 RANLIB
904 DLLTOOL
905 AS
906 OBJDUMP
907 LIBTOOL
908 ENABLE_STATIC_TRUE
909 ENABLE_STATIC_FALSE
910 LIBM
911 TAL_OBJECT
912 M4
913 BITS_PER_MP_LIMB
914 mpn_objs_in_libmp
915 mpn_objects
916 mpn_objs_in_libgmp
917 gmp_srclinks
918 TUNE_SQR_OBJ
919 HAVE_CLOCK_01
920 HAVE_CPUTIME_01
921 HAVE_GETRUSAGE_01
922 HAVE_GETTIMEOFDAY_01
923 HAVE_SIGACTION_01
924 HAVE_SIGALTSTACK_01
925 HAVE_SIGSTACK_01
926 HAVE_SYS_RESOURCE_H_01
927 HAVE_STACK_T_01
928 LIBCURSES
929 WITH_READLINE_01
930 LIBREADLINE
931 YACC
932 YFLAGS
933 LEX
934 LEX_OUTPUT_ROOT
935 LEXLIB
936 LIBOBJS
937 LTLIBOBJS'
938 ac_subst_files=''
939       ac_precious_vars='build_alias
940 host_alias
941 target_alias
942 ABI
943 CC
944 CFLAGS
945 LDFLAGS
946 LIBS
947 CPPFLAGS
948 CPP
949 CC_FOR_BUILD
950 CPP_FOR_BUILD
951 CXX
952 CXXFLAGS
953 CCC
954 CXXCPP
955 M4
956 YACC
957 YFLAGS'
958
959
960 # Initialize some variables set by options.
961 ac_init_help=
962 ac_init_version=false
963 # The variables have the same names as the options, with
964 # dashes changed to underlines.
965 cache_file=/dev/null
966 exec_prefix=NONE
967 no_create=
968 no_recursion=
969 prefix=NONE
970 program_prefix=NONE
971 program_suffix=NONE
972 program_transform_name=s,x,x,
973 silent=
974 site=
975 srcdir=
976 verbose=
977 x_includes=NONE
978 x_libraries=NONE
979
980 # Installation directory options.
981 # These are left unexpanded so users can "make install exec_prefix=/foo"
982 # and all the variables that are supposed to be based on exec_prefix
983 # by default will actually change.
984 # Use braces instead of parens because sh, perl, etc. also accept them.
985 # (The list follows the same order as the GNU Coding Standards.)
986 bindir='${exec_prefix}/bin'
987 sbindir='${exec_prefix}/sbin'
988 libexecdir='${exec_prefix}/libexec'
989 datarootdir='${prefix}/share'
990 datadir='${datarootdir}'
991 sysconfdir='${prefix}/etc'
992 sharedstatedir='${prefix}/com'
993 localstatedir='${prefix}/var'
994 includedir='${prefix}/include'
995 oldincludedir='/usr/include'
996 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
997 infodir='${datarootdir}/info'
998 htmldir='${docdir}'
999 dvidir='${docdir}'
1000 pdfdir='${docdir}'
1001 psdir='${docdir}'
1002 libdir='${exec_prefix}/lib'
1003 localedir='${datarootdir}/locale'
1004 mandir='${datarootdir}/man'
1005
1006 ac_prev=
1007 ac_dashdash=
1008 for ac_option
1009 do
1010   # If the previous option needs an argument, assign it.
1011   if test -n "$ac_prev"; then
1012     eval $ac_prev=\$ac_option
1013     ac_prev=
1014     continue
1015   fi
1016
1017   case $ac_option in
1018   *=*)  ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1019   *)    ac_optarg=yes ;;
1020   esac
1021
1022   # Accept the important Cygnus configure options, so we can diagnose typos.
1023
1024   case $ac_dashdash$ac_option in
1025   --)
1026     ac_dashdash=yes ;;
1027
1028   -bindir | --bindir | --bindi | --bind | --bin | --bi)
1029     ac_prev=bindir ;;
1030   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1031     bindir=$ac_optarg ;;
1032
1033   -build | --build | --buil | --bui | --bu)
1034     ac_prev=build_alias ;;
1035   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1036     build_alias=$ac_optarg ;;
1037
1038   -cache-file | --cache-file | --cache-fil | --cache-fi \
1039   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1040     ac_prev=cache_file ;;
1041   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1042   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1043     cache_file=$ac_optarg ;;
1044
1045   --config-cache | -C)
1046     cache_file=config.cache ;;
1047
1048   -datadir | --datadir | --datadi | --datad)
1049     ac_prev=datadir ;;
1050   -datadir=* | --datadir=* | --datadi=* | --datad=*)
1051     datadir=$ac_optarg ;;
1052
1053   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1054   | --dataroo | --dataro | --datar)
1055     ac_prev=datarootdir ;;
1056   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1057   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1058     datarootdir=$ac_optarg ;;
1059
1060   -disable-* | --disable-*)
1061     ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1062     # Reject names that are not valid shell variable names.
1063     expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1064       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
1065    { (exit 1); exit 1; }; }
1066     ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
1067     eval enable_$ac_feature=no ;;
1068
1069   -docdir | --docdir | --docdi | --doc | --do)
1070     ac_prev=docdir ;;
1071   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1072     docdir=$ac_optarg ;;
1073
1074   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1075     ac_prev=dvidir ;;
1076   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1077     dvidir=$ac_optarg ;;
1078
1079   -enable-* | --enable-*)
1080     ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1081     # Reject names that are not valid shell variable names.
1082     expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1083       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
1084    { (exit 1); exit 1; }; }
1085     ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
1086     eval enable_$ac_feature=\$ac_optarg ;;
1087
1088   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1089   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1090   | --exec | --exe | --ex)
1091     ac_prev=exec_prefix ;;
1092   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1093   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1094   | --exec=* | --exe=* | --ex=*)
1095     exec_prefix=$ac_optarg ;;
1096
1097   -gas | --gas | --ga | --g)
1098     # Obsolete; use --with-gas.
1099     with_gas=yes ;;
1100
1101   -help | --help | --hel | --he | -h)
1102     ac_init_help=long ;;
1103   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1104     ac_init_help=recursive ;;
1105   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1106     ac_init_help=short ;;
1107
1108   -host | --host | --hos | --ho)
1109     ac_prev=host_alias ;;
1110   -host=* | --host=* | --hos=* | --ho=*)
1111     host_alias=$ac_optarg ;;
1112
1113   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1114     ac_prev=htmldir ;;
1115   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1116   | --ht=*)
1117     htmldir=$ac_optarg ;;
1118
1119   -includedir | --includedir | --includedi | --included | --include \
1120   | --includ | --inclu | --incl | --inc)
1121     ac_prev=includedir ;;
1122   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1123   | --includ=* | --inclu=* | --incl=* | --inc=*)
1124     includedir=$ac_optarg ;;
1125
1126   -infodir | --infodir | --infodi | --infod | --info | --inf)
1127     ac_prev=infodir ;;
1128   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1129     infodir=$ac_optarg ;;
1130
1131   -libdir | --libdir | --libdi | --libd)
1132     ac_prev=libdir ;;
1133   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1134     libdir=$ac_optarg ;;
1135
1136   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1137   | --libexe | --libex | --libe)
1138     ac_prev=libexecdir ;;
1139   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1140   | --libexe=* | --libex=* | --libe=*)
1141     libexecdir=$ac_optarg ;;
1142
1143   -localedir | --localedir | --localedi | --localed | --locale)
1144     ac_prev=localedir ;;
1145   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1146     localedir=$ac_optarg ;;
1147
1148   -localstatedir | --localstatedir | --localstatedi | --localstated \
1149   | --localstate | --localstat | --localsta | --localst | --locals)
1150     ac_prev=localstatedir ;;
1151   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1152   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1153     localstatedir=$ac_optarg ;;
1154
1155   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1156     ac_prev=mandir ;;
1157   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1158     mandir=$ac_optarg ;;
1159
1160   -nfp | --nfp | --nf)
1161     # Obsolete; use --without-fp.
1162     with_fp=no ;;
1163
1164   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1165   | --no-cr | --no-c | -n)
1166     no_create=yes ;;
1167
1168   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1169   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1170     no_recursion=yes ;;
1171
1172   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1173   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1174   | --oldin | --oldi | --old | --ol | --o)
1175     ac_prev=oldincludedir ;;
1176   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1177   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1178   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1179     oldincludedir=$ac_optarg ;;
1180
1181   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1182     ac_prev=prefix ;;
1183   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1184     prefix=$ac_optarg ;;
1185
1186   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1187   | --program-pre | --program-pr | --program-p)
1188     ac_prev=program_prefix ;;
1189   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1190   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1191     program_prefix=$ac_optarg ;;
1192
1193   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1194   | --program-suf | --program-su | --program-s)
1195     ac_prev=program_suffix ;;
1196   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1197   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1198     program_suffix=$ac_optarg ;;
1199
1200   -program-transform-name | --program-transform-name \
1201   | --program-transform-nam | --program-transform-na \
1202   | --program-transform-n | --program-transform- \
1203   | --program-transform | --program-transfor \
1204   | --program-transfo | --program-transf \
1205   | --program-trans | --program-tran \
1206   | --progr-tra | --program-tr | --program-t)
1207     ac_prev=program_transform_name ;;
1208   -program-transform-name=* | --program-transform-name=* \
1209   | --program-transform-nam=* | --program-transform-na=* \
1210   | --program-transform-n=* | --program-transform-=* \
1211   | --program-transform=* | --program-transfor=* \
1212   | --program-transfo=* | --program-transf=* \
1213   | --program-trans=* | --program-tran=* \
1214   | --progr-tra=* | --program-tr=* | --program-t=*)
1215     program_transform_name=$ac_optarg ;;
1216
1217   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1218     ac_prev=pdfdir ;;
1219   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1220     pdfdir=$ac_optarg ;;
1221
1222   -psdir | --psdir | --psdi | --psd | --ps)
1223     ac_prev=psdir ;;
1224   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1225     psdir=$ac_optarg ;;
1226
1227   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1228   | -silent | --silent | --silen | --sile | --sil)
1229     silent=yes ;;
1230
1231   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1232     ac_prev=sbindir ;;
1233   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1234   | --sbi=* | --sb=*)
1235     sbindir=$ac_optarg ;;
1236
1237   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1238   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1239   | --sharedst | --shareds | --shared | --share | --shar \
1240   | --sha | --sh)
1241     ac_prev=sharedstatedir ;;
1242   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1243   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1244   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1245   | --sha=* | --sh=*)
1246     sharedstatedir=$ac_optarg ;;
1247
1248   -site | --site | --sit)
1249     ac_prev=site ;;
1250   -site=* | --site=* | --sit=*)
1251     site=$ac_optarg ;;
1252
1253   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1254     ac_prev=srcdir ;;
1255   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1256     srcdir=$ac_optarg ;;
1257
1258   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1259   | --syscon | --sysco | --sysc | --sys | --sy)
1260     ac_prev=sysconfdir ;;
1261   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1262   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1263     sysconfdir=$ac_optarg ;;
1264
1265   -target | --target | --targe | --targ | --tar | --ta | --t)
1266     ac_prev=target_alias ;;
1267   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1268     target_alias=$ac_optarg ;;
1269
1270   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1271     verbose=yes ;;
1272
1273   -version | --version | --versio | --versi | --vers | -V)
1274     ac_init_version=: ;;
1275
1276   -with-* | --with-*)
1277     ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1278     # Reject names that are not valid shell variable names.
1279     expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1280       { echo "$as_me: error: invalid package name: $ac_package" >&2
1281    { (exit 1); exit 1; }; }
1282     ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
1283     eval with_$ac_package=\$ac_optarg ;;
1284
1285   -without-* | --without-*)
1286     ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1287     # Reject names that are not valid shell variable names.
1288     expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1289       { echo "$as_me: error: invalid package name: $ac_package" >&2
1290    { (exit 1); exit 1; }; }
1291     ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
1292     eval with_$ac_package=no ;;
1293
1294   --x)
1295     # Obsolete; use --with-x.
1296     with_x=yes ;;
1297
1298   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1299   | --x-incl | --x-inc | --x-in | --x-i)
1300     ac_prev=x_includes ;;
1301   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1302   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1303     x_includes=$ac_optarg ;;
1304
1305   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1306   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1307     ac_prev=x_libraries ;;
1308   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1309   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1310     x_libraries=$ac_optarg ;;
1311
1312   -*) { echo "$as_me: error: unrecognized option: $ac_option
1313 Try \`$0 --help' for more information." >&2
1314    { (exit 1); exit 1; }; }
1315     ;;
1316
1317   *=*)
1318     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1319     # Reject names that are not valid shell variable names.
1320     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1321       { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1322    { (exit 1); exit 1; }; }
1323     eval $ac_envvar=\$ac_optarg
1324     export $ac_envvar ;;
1325
1326   *)
1327     # FIXME: should be removed in autoconf 3.0.
1328     echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1329     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1330       echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1331     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1332     ;;
1333
1334   esac
1335 done
1336
1337 if test -n "$ac_prev"; then
1338   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1339   { echo "$as_me: error: missing argument to $ac_option" >&2
1340    { (exit 1); exit 1; }; }
1341 fi
1342
1343 # Be sure to have absolute directory names.
1344 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1345                 datadir sysconfdir sharedstatedir localstatedir includedir \
1346                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1347                 libdir localedir mandir
1348 do
1349   eval ac_val=\$$ac_var
1350   case $ac_val in
1351     [\\/$]* | ?:[\\/]* )  continue;;
1352     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1353   esac
1354   { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1355    { (exit 1); exit 1; }; }
1356 done
1357
1358 # There might be people who depend on the old broken behavior: `$host'
1359 # used to hold the argument of --host etc.
1360 # FIXME: To remove some day.
1361 build=$build_alias
1362 host=$host_alias
1363 target=$target_alias
1364
1365 # FIXME: To remove some day.
1366 if test "x$host_alias" != x; then
1367   if test "x$build_alias" = x; then
1368     cross_compiling=maybe
1369     echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1370     If a cross compiler is detected then cross compile mode will be used." >&2
1371   elif test "x$build_alias" != "x$host_alias"; then
1372     cross_compiling=yes
1373   fi
1374 fi
1375
1376 ac_tool_prefix=
1377 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1378
1379 test "$silent" = yes && exec 6>/dev/null
1380
1381
1382 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1383 ac_ls_di=`ls -di .` &&
1384 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1385   { echo "$as_me: error: Working directory cannot be determined" >&2
1386    { (exit 1); exit 1; }; }
1387 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1388   { echo "$as_me: error: pwd does not report name of working directory" >&2
1389    { (exit 1); exit 1; }; }
1390
1391
1392 # Find the source files, if location was not specified.
1393 if test -z "$srcdir"; then
1394   ac_srcdir_defaulted=yes
1395   # Try the directory containing this script, then the parent directory.
1396   ac_confdir=`$as_dirname -- "$0" ||
1397 $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1398          X"$0" : 'X\(//\)[^/]' \| \
1399          X"$0" : 'X\(//\)$' \| \
1400          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
1401 echo X"$0" |
1402     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1403             s//\1/
1404             q
1405           }
1406           /^X\(\/\/\)[^/].*/{
1407             s//\1/
1408             q
1409           }
1410           /^X\(\/\/\)$/{
1411             s//\1/
1412             q
1413           }
1414           /^X\(\/\).*/{
1415             s//\1/
1416             q
1417           }
1418           s/.*/./; q'`
1419   srcdir=$ac_confdir
1420   if test ! -r "$srcdir/$ac_unique_file"; then
1421     srcdir=..
1422   fi
1423 else
1424   ac_srcdir_defaulted=no
1425 fi
1426 if test ! -r "$srcdir/$ac_unique_file"; then
1427   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1428   { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1429    { (exit 1); exit 1; }; }
1430 fi
1431 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1432 ac_abs_confdir=`(
1433         cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2
1434    { (exit 1); exit 1; }; }
1435         pwd)`
1436 # When building in place, set srcdir=.
1437 if test "$ac_abs_confdir" = "$ac_pwd"; then
1438   srcdir=.
1439 fi
1440 # Remove unnecessary trailing slashes from srcdir.
1441 # Double slashes in file names in object file debugging info
1442 # mess up M-x gdb in Emacs.
1443 case $srcdir in
1444 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1445 esac
1446 for ac_var in $ac_precious_vars; do
1447   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1448   eval ac_env_${ac_var}_value=\$${ac_var}
1449   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1450   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1451 done
1452
1453 #
1454 # Report the --help message.
1455 #
1456 if test "$ac_init_help" = "long"; then
1457   # Omit some internal or obsolete options to make the list less imposing.
1458   # This message is too long to be a string in the A/UX 3.1 sh.
1459   cat <<_ACEOF
1460 \`configure' configures GNU MP 4.3.2 to adapt to many kinds of systems.
1461
1462 Usage: $0 [OPTION]... [VAR=VALUE]...
1463
1464 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1465 VAR=VALUE.  See below for descriptions of some of the useful variables.
1466
1467 Defaults for the options are specified in brackets.
1468
1469 Configuration:
1470   -h, --help              display this help and exit
1471       --help=short        display options specific to this package
1472       --help=recursive    display the short help of all the included packages
1473   -V, --version           display version information and exit
1474   -q, --quiet, --silent   do not print \`checking...' messages
1475       --cache-file=FILE   cache test results in FILE [disabled]
1476   -C, --config-cache      alias for \`--cache-file=config.cache'
1477   -n, --no-create         do not create output files
1478       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1479
1480 Installation directories:
1481   --prefix=PREFIX         install architecture-independent files in PREFIX
1482                           [$ac_default_prefix]
1483   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1484                           [PREFIX]
1485
1486 By default, \`make install' will install all the files in
1487 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1488 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1489 for instance \`--prefix=\$HOME'.
1490
1491 For better control, use the options below.
1492
1493 Fine tuning of the installation directories:
1494   --bindir=DIR           user executables [EPREFIX/bin]
1495   --sbindir=DIR          system admin executables [EPREFIX/sbin]
1496   --libexecdir=DIR       program executables [EPREFIX/libexec]
1497   --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
1498   --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
1499   --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
1500   --libdir=DIR           object code libraries [EPREFIX/lib]
1501   --includedir=DIR       C header files [PREFIX/include]
1502   --oldincludedir=DIR    C header files for non-gcc [/usr/include]
1503   --datarootdir=DIR      read-only arch.-independent data root [PREFIX/share]
1504   --datadir=DIR          read-only architecture-independent data [DATAROOTDIR]
1505   --infodir=DIR          info documentation [DATAROOTDIR/info]
1506   --localedir=DIR        locale-dependent data [DATAROOTDIR/locale]
1507   --mandir=DIR           man documentation [DATAROOTDIR/man]
1508   --docdir=DIR           documentation root [DATAROOTDIR/doc/gmp]
1509   --htmldir=DIR          html documentation [DOCDIR]
1510   --dvidir=DIR           dvi documentation [DOCDIR]
1511   --pdfdir=DIR           pdf documentation [DOCDIR]
1512   --psdir=DIR            ps documentation [DOCDIR]
1513 _ACEOF
1514
1515   cat <<\_ACEOF
1516
1517 Program names:
1518   --program-prefix=PREFIX            prepend PREFIX to installed program names
1519   --program-suffix=SUFFIX            append SUFFIX to installed program names
1520   --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
1521
1522 System types:
1523   --build=BUILD     configure for building on BUILD [guessed]
1524   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1525 _ACEOF
1526 fi
1527
1528 if test -n "$ac_init_help"; then
1529   case $ac_init_help in
1530      short | recursive ) echo "Configuration of GNU MP 4.3.2:";;
1531    esac
1532   cat <<\_ACEOF
1533
1534 Optional Features:
1535   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1536   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1537   --enable-maintainer-mode  enable make rules and dependencies not useful
1538                           (and sometimes confusing) to the casual installer
1539   --enable-assert         enable ASSERT checking [default=no]
1540   --enable-alloca         how to get temp memory [default=reentrant]
1541   --enable-cxx            enable C++ support [default=no]
1542   --enable-fft            enable FFTs for multiplication [default=yes]
1543   --enable-mpbsd          build Berkeley MP compatibility library
1544                           [default=no]
1545   --enable-nails          use nails on limbs [default=no]
1546   --enable-profiling      build with profiler support [default=no]
1547   --enable-fat            build a fat binary on systems that support it
1548                           [default=no]
1549   --enable-minithres      choose minimal thresholds for testing [default=no]
1550   --enable-shared[=PKGS]  build shared libraries [default=yes]
1551   --enable-static[=PKGS]  build static libraries [default=yes]
1552   --enable-fast-install[=PKGS]
1553                           optimize for fast installation [default=yes]
1554   --disable-libtool-lock  avoid locking (might break parallel builds)
1555
1556 Optional Packages:
1557   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1558   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1559   --with-readline         readline support in calc demo program
1560                           [default=detect]
1561   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1562   --with-pic              try to use only PIC/non-PIC objects [default=use
1563                           both]
1564   --with-tags[=TAGS]      include additional configurations [automatic]
1565
1566 Some influential environment variables:
1567   ABI         desired ABI (for processors supporting more than one ABI)
1568   CC          C compiler command
1569   CFLAGS      C compiler flags
1570   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1571               nonstandard directory <lib dir>
1572   LIBS        libraries to pass to the linker, e.g. -l<library>
1573   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1574               you have headers in a nonstandard directory <include dir>
1575   CPP         C preprocessor
1576   CC_FOR_BUILD
1577               build system C compiler
1578   CPP_FOR_BUILD
1579               build system C preprocessor
1580   CXX         C++ compiler command
1581   CXXFLAGS    C++ compiler flags
1582   CXXCPP      C++ preprocessor
1583   M4          m4 macro processor
1584   YACC        The `Yet Another C Compiler' implementation to use. Defaults to
1585               the first program found out of: `bison -y', `byacc', `yacc'.
1586   YFLAGS      The list of arguments that will be passed by default to $YACC.
1587               This script will default YFLAGS to the empty string to avoid a
1588               default value of `-d' given by some make applications.
1589
1590 Use these variables to override the choices made by `configure' or to help
1591 it to find libraries and programs with nonstandard names/locations.
1592
1593 Report bugs to <gmp-bugs@gmplib.org>.
1594 _ACEOF
1595 ac_status=$?
1596 fi
1597
1598 if test "$ac_init_help" = "recursive"; then
1599   # If there are subdirs, report their specific --help.
1600   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1601     test -d "$ac_dir" || continue
1602     ac_builddir=.
1603
1604 case "$ac_dir" in
1605 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1606 *)
1607   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
1608   # A ".." for each directory in $ac_dir_suffix.
1609   ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
1610   case $ac_top_builddir_sub in
1611   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1612   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1613   esac ;;
1614 esac
1615 ac_abs_top_builddir=$ac_pwd
1616 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1617 # for backward compatibility:
1618 ac_top_builddir=$ac_top_build_prefix
1619
1620 case $srcdir in
1621   .)  # We are building in place.
1622     ac_srcdir=.
1623     ac_top_srcdir=$ac_top_builddir_sub
1624     ac_abs_top_srcdir=$ac_pwd ;;
1625   [\\/]* | ?:[\\/]* )  # Absolute name.
1626     ac_srcdir=$srcdir$ac_dir_suffix;
1627     ac_top_srcdir=$srcdir
1628     ac_abs_top_srcdir=$srcdir ;;
1629   *) # Relative name.
1630     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1631     ac_top_srcdir=$ac_top_build_prefix$srcdir
1632     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1633 esac
1634 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1635
1636     cd "$ac_dir" || { ac_status=$?; continue; }
1637     # Check for guested configure.
1638     if test -f "$ac_srcdir/configure.gnu"; then
1639       echo &&
1640       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1641     elif test -f "$ac_srcdir/configure"; then
1642       echo &&
1643       $SHELL "$ac_srcdir/configure" --help=recursive
1644     else
1645       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1646     fi || ac_status=$?
1647     cd "$ac_pwd" || { ac_status=$?; break; }
1648   done
1649 fi
1650
1651 test -n "$ac_init_help" && exit $ac_status
1652 if $ac_init_version; then
1653   cat <<\_ACEOF
1654 GNU MP configure 4.3.2
1655 generated by GNU Autoconf 2.61
1656
1657 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1658 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
1659 This configure script is free software; the Free Software Foundation
1660 gives unlimited permission to copy, distribute and modify it.
1661
1662
1663
1664 Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
1665 2007 Free Software Foundation, Inc.
1666
1667 This file is part of the GNU MP Library.
1668
1669 The GNU MP Library is free software; you can redistribute it and/or modify
1670 it under the terms of the GNU Lesser General Public License as published
1671 by the Free Software Foundation; either version 3 of the License, or (at
1672 your option) any later version.
1673
1674 The GNU MP Library is distributed in the hope that it will be useful, but
1675 WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
1676 or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public
1677 License for more details.
1678
1679 You should have received a copy of the GNU Lesser General Public License
1680 along with the GNU MP Library.  If not, see http://www.gnu.org/licenses/.
1681
1682 _ACEOF
1683   exit
1684 fi
1685 cat >config.log <<_ACEOF
1686 This file contains any messages produced by compilers while
1687 running configure, to aid debugging if configure makes a mistake.
1688
1689 It was created by GNU MP $as_me 4.3.2, which was
1690 generated by GNU Autoconf 2.61.  Invocation command line was
1691
1692   $ $0 $@
1693
1694 _ACEOF
1695 exec 5>>config.log
1696 {
1697 cat <<_ASUNAME
1698 ## --------- ##
1699 ## Platform. ##
1700 ## --------- ##
1701
1702 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1703 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1704 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1705 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1706 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1707
1708 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1709 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1710
1711 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1712 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1713 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1714 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1715 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1716 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1717 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1718
1719 _ASUNAME
1720
1721 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1722 for as_dir in $PATH
1723 do
1724   IFS=$as_save_IFS
1725   test -z "$as_dir" && as_dir=.
1726   echo "PATH: $as_dir"
1727 done
1728 IFS=$as_save_IFS
1729
1730 } >&5
1731
1732 cat >&5 <<_ACEOF
1733
1734
1735 ## ----------- ##
1736 ## Core tests. ##
1737 ## ----------- ##
1738
1739 _ACEOF
1740
1741
1742 # Keep a trace of the command line.
1743 # Strip out --no-create and --no-recursion so they do not pile up.
1744 # Strip out --silent because we don't want to record it for future runs.
1745 # Also quote any args containing shell meta-characters.
1746 # Make two passes to allow for proper duplicate-argument suppression.
1747 ac_configure_args=
1748 ac_configure_args0=
1749 ac_configure_args1=
1750 ac_must_keep_next=false
1751 for ac_pass in 1 2
1752 do
1753   for ac_arg
1754   do
1755     case $ac_arg in
1756     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1757     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1758     | -silent | --silent | --silen | --sile | --sil)
1759       continue ;;
1760     *\'*)
1761       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1762     esac
1763     case $ac_pass in
1764     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1765     2)
1766       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1767       if test $ac_must_keep_next = true; then
1768         ac_must_keep_next=false # Got value, back to normal.
1769       else
1770         case $ac_arg in
1771           *=* | --config-cache | -C | -disable-* | --disable-* \
1772           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1773           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1774           | -with-* | --with-* | -without-* | --without-* | --x)
1775             case "$ac_configure_args0 " in
1776               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1777             esac
1778             ;;
1779           -* ) ac_must_keep_next=true ;;
1780         esac
1781       fi
1782       ac_configure_args="$ac_configure_args '$ac_arg'"
1783       ;;
1784     esac
1785   done
1786 done
1787 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1788 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1789
1790 # When interrupted or exit'd, cleanup temporary files, and complete
1791 # config.log.  We remove comments because anyway the quotes in there
1792 # would cause problems or look ugly.
1793 # WARNING: Use '\'' to represent an apostrophe within the trap.
1794 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1795 trap 'exit_status=$?
1796   # Save into config.log some information that might help in debugging.
1797   {
1798     echo
1799
1800     cat <<\_ASBOX
1801 ## ---------------- ##
1802 ## Cache variables. ##
1803 ## ---------------- ##
1804 _ASBOX
1805     echo
1806     # The following way of writing the cache mishandles newlines in values,
1807 (
1808   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1809     eval ac_val=\$$ac_var
1810     case $ac_val in #(
1811     *${as_nl}*)
1812       case $ac_var in #(
1813       *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
1814 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
1815       esac
1816       case $ac_var in #(
1817       _ | IFS | as_nl) ;; #(
1818       *) $as_unset $ac_var ;;
1819       esac ;;
1820     esac
1821   done
1822   (set) 2>&1 |
1823     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1824     *${as_nl}ac_space=\ *)
1825       sed -n \
1826         "s/'\''/'\''\\\\'\'''\''/g;
1827           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1828       ;; #(
1829     *)
1830       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1831       ;;
1832     esac |
1833     sort
1834 )
1835     echo
1836
1837     cat <<\_ASBOX
1838 ## ----------------- ##
1839 ## Output variables. ##
1840 ## ----------------- ##
1841 _ASBOX
1842     echo
1843     for ac_var in $ac_subst_vars
1844     do
1845       eval ac_val=\$$ac_var
1846       case $ac_val in
1847       *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1848       esac
1849       echo "$ac_var='\''$ac_val'\''"
1850     done | sort
1851     echo
1852
1853     if test -n "$ac_subst_files"; then
1854       cat <<\_ASBOX
1855 ## ------------------- ##
1856 ## File substitutions. ##
1857 ## ------------------- ##
1858 _ASBOX
1859       echo
1860       for ac_var in $ac_subst_files
1861       do
1862         eval ac_val=\$$ac_var
1863         case $ac_val in
1864         *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1865         esac
1866         echo "$ac_var='\''$ac_val'\''"
1867       done | sort
1868       echo
1869     fi
1870
1871     if test -s confdefs.h; then
1872       cat <<\_ASBOX
1873 ## ----------- ##
1874 ## confdefs.h. ##
1875 ## ----------- ##
1876 _ASBOX
1877       echo
1878       cat confdefs.h
1879       echo
1880     fi
1881     test "$ac_signal" != 0 &&
1882       echo "$as_me: caught signal $ac_signal"
1883     echo "$as_me: exit $exit_status"
1884   } >&5
1885   rm -f core *.core core.conftest.* &&
1886     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1887     exit $exit_status
1888 ' 0
1889 for ac_signal in 1 2 13 15; do
1890   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1891 done
1892 ac_signal=0
1893
1894 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1895 rm -f -r conftest* confdefs.h
1896
1897 # Predefined preprocessor variables.
1898
1899 cat >>confdefs.h <<_ACEOF
1900 #define PACKAGE_NAME "$PACKAGE_NAME"
1901 _ACEOF
1902
1903
1904 cat >>confdefs.h <<_ACEOF
1905 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1906 _ACEOF
1907
1908
1909 cat >>confdefs.h <<_ACEOF
1910 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1911 _ACEOF
1912
1913
1914 cat >>confdefs.h <<_ACEOF
1915 #define PACKAGE_STRING "$PACKAGE_STRING"
1916 _ACEOF
1917
1918
1919 cat >>confdefs.h <<_ACEOF
1920 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1921 _ACEOF
1922
1923
1924 # Let the site file select an alternate cache file if it wants to.
1925 # Prefer explicitly selected file to automatically selected ones.
1926 if test -n "$CONFIG_SITE"; then
1927   set x "$CONFIG_SITE"
1928 elif test "x$prefix" != xNONE; then
1929   set x "$prefix/share/config.site" "$prefix/etc/config.site"
1930 else
1931   set x "$ac_default_prefix/share/config.site" \
1932         "$ac_default_prefix/etc/config.site"
1933 fi
1934 shift
1935 for ac_site_file
1936 do
1937   if test -r "$ac_site_file"; then
1938     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1939 echo "$as_me: loading site script $ac_site_file" >&6;}
1940     sed 's/^/| /' "$ac_site_file" >&5
1941     . "$ac_site_file"
1942   fi
1943 done
1944
1945 if test -r "$cache_file"; then
1946   # Some versions of bash will fail to source /dev/null (special
1947   # files actually), so we avoid doing that.
1948   if test -f "$cache_file"; then
1949     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1950 echo "$as_me: loading cache $cache_file" >&6;}
1951     case $cache_file in
1952       [\\/]* | ?:[\\/]* ) . "$cache_file";;
1953       *)                      . "./$cache_file";;
1954     esac
1955   fi
1956 else
1957   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1958 echo "$as_me: creating cache $cache_file" >&6;}
1959   >$cache_file
1960 fi
1961
1962 # Check that the precious variables saved in the cache have kept the same
1963 # value.
1964 ac_cache_corrupted=false
1965 for ac_var in $ac_precious_vars; do
1966   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1967   eval ac_new_set=\$ac_env_${ac_var}_set
1968   eval ac_old_val=\$ac_cv_env_${ac_var}_value
1969   eval ac_new_val=\$ac_env_${ac_var}_value
1970   case $ac_old_set,$ac_new_set in
1971     set,)
1972       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1973 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1974       ac_cache_corrupted=: ;;
1975     ,set)
1976       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1977 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1978       ac_cache_corrupted=: ;;
1979     ,);;
1980     *)
1981       if test "x$ac_old_val" != "x$ac_new_val"; then
1982         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1983 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1984         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1985 echo "$as_me:   former value:  $ac_old_val" >&2;}
1986         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1987 echo "$as_me:   current value: $ac_new_val" >&2;}
1988         ac_cache_corrupted=:
1989       fi;;
1990   esac
1991   # Pass precious variables to config.status.
1992   if test "$ac_new_set" = set; then
1993     case $ac_new_val in
1994     *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1995     *) ac_arg=$ac_var=$ac_new_val ;;
1996     esac
1997     case " $ac_configure_args " in
1998       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1999       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
2000     esac
2001   fi
2002 done
2003 if $ac_cache_corrupted; then
2004   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
2005 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2006   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
2007 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
2008    { (exit 1); exit 1; }; }
2009 fi
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035 ac_ext=c
2036 ac_cpp='$CPP $CPPFLAGS'
2037 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2038 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2039 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050 # If --target is not used then $target_alias is empty, but if say
2051 # "./configure athlon-pc-freebsd3.5" is used, then all three of
2052 # $build_alias, $host_alias and $target_alias are set to
2053 # "athlon-pc-freebsd3.5".
2054 #
2055 if test -n "$target_alias" && test "$target_alias" != "$host_alias"; then
2056   { { echo "$as_me:$LINENO: error: --target is not appropriate for GMP
2057 Use --build=CPU-VENDOR-OS if you need to specify your CPU and/or system
2058 explicitly.  Use --host if cross-compiling (see \"Installing GMP\" in the
2059 manual for more on this)." >&5
2060 echo "$as_me: error: --target is not appropriate for GMP
2061 Use --build=CPU-VENDOR-OS if you need to specify your CPU and/or system
2062 explicitly.  Use --host if cross-compiling (see \"Installing GMP\" in the
2063 manual for more on this)." >&2;}
2064    { (exit 1); exit 1; }; }
2065 fi
2066
2067 gmp_configm4="config.m4"
2068 gmp_tmpconfigm4=cnfm4.tmp
2069 gmp_tmpconfigm4i=cnfm4i.tmp
2070 gmp_tmpconfigm4p=cnfm4p.tmp
2071 rm -f $gmp_tmpconfigm4 $gmp_tmpconfigm4i $gmp_tmpconfigm4p
2072
2073 # CONFIG_TOP_SRCDIR is a path from the mpn builddir to the top srcdir.
2074 # The pattern here tests for an absolute path the same way as
2075 # _AC_OUTPUT_FILES in autoconf acgeneral.m4.
2076 case $srcdir in
2077 [\\/]* | ?:[\\/]* )  tmp="$srcdir"    ;;
2078 *)                       tmp="../$srcdir" ;;
2079 esac
2080 echo "define(<CONFIG_TOP_SRCDIR>,<\`$tmp'>)" >>$gmp_tmpconfigm4
2081
2082 # All CPUs use asm-defs.m4
2083 echo "include(CONFIG_TOP_SRCDIR\`/mpn/asm-defs.m4')" >>$gmp_tmpconfigm4i
2084
2085
2086 ac_aux_dir=
2087 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
2088   if test -f "$ac_dir/install-sh"; then
2089     ac_aux_dir=$ac_dir
2090     ac_install_sh="$ac_aux_dir/install-sh -c"
2091     break
2092   elif test -f "$ac_dir/install.sh"; then
2093     ac_aux_dir=$ac_dir
2094     ac_install_sh="$ac_aux_dir/install.sh -c"
2095     break
2096   elif test -f "$ac_dir/shtool"; then
2097     ac_aux_dir=$ac_dir
2098     ac_install_sh="$ac_aux_dir/shtool install -c"
2099     break
2100   fi
2101 done
2102 if test -z "$ac_aux_dir"; then
2103   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&5
2104 echo "$as_me: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&2;}
2105    { (exit 1); exit 1; }; }
2106 fi
2107
2108 # These three variables are undocumented and unsupported,
2109 # and are intended to be withdrawn in a future Autoconf release.
2110 # They can cause serious problems if a builder's source tree is in a directory
2111 # whose full name contains unusual characters.
2112 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2113 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2114 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2115
2116
2117 # Make sure we can run config.sub.
2118 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2119   { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
2120 echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
2121    { (exit 1); exit 1; }; }
2122
2123 { echo "$as_me:$LINENO: checking build system type" >&5
2124 echo $ECHO_N "checking build system type... $ECHO_C" >&6; }
2125 if test "${ac_cv_build+set}" = set; then
2126   echo $ECHO_N "(cached) $ECHO_C" >&6
2127 else
2128   ac_build_alias=$build_alias
2129 test "x$ac_build_alias" = x &&
2130   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2131 test "x$ac_build_alias" = x &&
2132   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
2133 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2134    { (exit 1); exit 1; }; }
2135 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2136   { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
2137 echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
2138    { (exit 1); exit 1; }; }
2139
2140 fi
2141 { echo "$as_me:$LINENO: result: $ac_cv_build" >&5
2142 echo "${ECHO_T}$ac_cv_build" >&6; }
2143 case $ac_cv_build in
2144 *-*-*) ;;
2145 *) { { echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
2146 echo "$as_me: error: invalid value of canonical build" >&2;}
2147    { (exit 1); exit 1; }; };;
2148 esac
2149 build=$ac_cv_build
2150 ac_save_IFS=$IFS; IFS='-'
2151 set x $ac_cv_build
2152 shift
2153 build_cpu=$1
2154 build_vendor=$2
2155 shift; shift
2156 # Remember, the first character of IFS is used to create $*,
2157 # except with old shells:
2158 build_os=$*
2159 IFS=$ac_save_IFS
2160 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2161
2162
2163 { echo "$as_me:$LINENO: checking host system type" >&5
2164 echo $ECHO_N "checking host system type... $ECHO_C" >&6; }
2165 if test "${ac_cv_host+set}" = set; then
2166   echo $ECHO_N "(cached) $ECHO_C" >&6
2167 else
2168   if test "x$host_alias" = x; then
2169   ac_cv_host=$ac_cv_build
2170 else
2171   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2172     { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
2173 echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
2174    { (exit 1); exit 1; }; }
2175 fi
2176
2177 fi
2178 { echo "$as_me:$LINENO: result: $ac_cv_host" >&5
2179 echo "${ECHO_T}$ac_cv_host" >&6; }
2180 case $ac_cv_host in
2181 *-*-*) ;;
2182 *) { { echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
2183 echo "$as_me: error: invalid value of canonical host" >&2;}
2184    { (exit 1); exit 1; }; };;
2185 esac
2186 host=$ac_cv_host
2187 ac_save_IFS=$IFS; IFS='-'
2188 set x $ac_cv_host
2189 shift
2190 host_cpu=$1
2191 host_vendor=$2
2192 shift; shift
2193 # Remember, the first character of IFS is used to create $*,
2194 # except with old shells:
2195 host_os=$*
2196 IFS=$ac_save_IFS
2197 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2198
2199
2200
2201 am__api_version="1.8"
2202 # Find a good install program.  We prefer a C program (faster),
2203 # so one script is as good as another.  But avoid the broken or
2204 # incompatible versions:
2205 # SysV /etc/install, /usr/sbin/install
2206 # SunOS /usr/etc/install
2207 # IRIX /sbin/install
2208 # AIX /bin/install
2209 # AmigaOS /C/install, which installs bootblocks on floppy discs
2210 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2211 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2212 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2213 # OS/2's system install, which has a completely different semantic
2214 # ./install, which can be erroneously created by make from ./install.sh.
2215 { echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
2216 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; }
2217 if test -z "$INSTALL"; then
2218 if test "${ac_cv_path_install+set}" = set; then
2219   echo $ECHO_N "(cached) $ECHO_C" >&6
2220 else
2221   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2222 for as_dir in $PATH
2223 do
2224   IFS=$as_save_IFS
2225   test -z "$as_dir" && as_dir=.
2226   # Account for people who put trailing slashes in PATH elements.
2227 case $as_dir/ in
2228   ./ | .// | /cC/* | \
2229   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
2230   ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
2231   /usr/ucb/* ) ;;
2232   *)
2233     # OSF1 and SCO ODT 3.0 have their own names for install.
2234     # Don't use installbsd from OSF since it installs stuff as root
2235     # by default.
2236     for ac_prog in ginstall scoinst install; do
2237       for ac_exec_ext in '' $ac_executable_extensions; do
2238         if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
2239           if test $ac_prog = install &&
2240             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2241             # AIX install.  It has an incompatible calling convention.
2242             :
2243           elif test $ac_prog = install &&
2244             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2245             # program-specific install script used by HP pwplus--don't use.
2246             :
2247           else
2248             ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
2249             break 3
2250           fi
2251         fi
2252       done
2253     done
2254     ;;
2255 esac
2256 done
2257 IFS=$as_save_IFS
2258
2259
2260 fi
2261   if test "${ac_cv_path_install+set}" = set; then
2262     INSTALL=$ac_cv_path_install
2263   else
2264     # As a last resort, use the slow shell script.  Don't cache a
2265     # value for INSTALL within a source directory, because that will
2266     # break other packages using the cache if that directory is
2267     # removed, or if the value is a relative name.
2268     INSTALL=$ac_install_sh
2269   fi
2270 fi
2271 { echo "$as_me:$LINENO: result: $INSTALL" >&5
2272 echo "${ECHO_T}$INSTALL" >&6; }
2273
2274 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2275 # It thinks the first close brace ends the variable substitution.
2276 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2277
2278 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2279
2280 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2281
2282 { echo "$as_me:$LINENO: checking whether build environment is sane" >&5
2283 echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6; }
2284 # Just in case
2285 sleep 1
2286 echo timestamp > conftest.file
2287 # Do `set' in a subshell so we don't clobber the current shell's
2288 # arguments.  Must try -L first in case configure is actually a
2289 # symlink; some systems play weird games with the mod time of symlinks
2290 # (eg FreeBSD returns the mod time of the symlink's containing
2291 # directory).
2292 if (
2293    set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
2294    if test "$*" = "X"; then
2295       # -L didn't work.
2296       set X `ls -t $srcdir/configure conftest.file`
2297    fi
2298    rm -f conftest.file
2299    if test "$*" != "X $srcdir/configure conftest.file" \
2300       && test "$*" != "X conftest.file $srcdir/configure"; then
2301
2302       # If neither matched, then we have a broken ls.  This can happen
2303       # if, for instance, CONFIG_SHELL is bash and it inherits a
2304       # broken ls alias from the environment.  This has actually
2305       # happened.  Such a system could not be considered "sane".
2306       { { echo "$as_me:$LINENO: error: ls -t appears to fail.  Make sure there is not a broken
2307 alias in your environment" >&5
2308 echo "$as_me: error: ls -t appears to fail.  Make sure there is not a broken
2309 alias in your environment" >&2;}
2310    { (exit 1); exit 1; }; }
2311    fi
2312
2313    test "$2" = conftest.file
2314    )
2315 then
2316    # Ok.
2317    :
2318 else
2319    { { echo "$as_me:$LINENO: error: newly created file is older than distributed files!
2320 Check your system clock" >&5
2321 echo "$as_me: error: newly created file is older than distributed files!
2322 Check your system clock" >&2;}
2323    { (exit 1); exit 1; }; }
2324 fi
2325 { echo "$as_me:$LINENO: result: yes" >&5
2326 echo "${ECHO_T}yes" >&6; }
2327 test "$program_prefix" != NONE &&
2328   program_transform_name="s&^&$program_prefix&;$program_transform_name"
2329 # Use a double $ so make ignores it.
2330 test "$program_suffix" != NONE &&
2331   program_transform_name="s&\$&$program_suffix&;$program_transform_name"
2332 # Double any \ or $.  echo might interpret backslashes.
2333 # By default was `s,x,x', remove it if useless.
2334 cat <<\_ACEOF >conftest.sed
2335 s/[\\$]/&&/g;s/;s,x,x,$//
2336 _ACEOF
2337 program_transform_name=`echo $program_transform_name | sed -f conftest.sed`
2338 rm -f conftest.sed
2339
2340 # expand $ac_aux_dir to an absolute path
2341 am_aux_dir=`cd $ac_aux_dir && pwd`
2342
2343 test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
2344 # Use eval to expand $SHELL
2345 if eval "$MISSING --run true"; then
2346   am_missing_run="$MISSING --run "
2347 else
2348   am_missing_run=
2349   { echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5
2350 echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
2351 fi
2352
2353 if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then
2354   # Keeping the `.' argument allows $(mkdir_p) to be used without
2355   # argument.  Indeed, we sometimes output rules like
2356   #   $(mkdir_p) $(somedir)
2357   # where $(somedir) is conditionally defined.
2358   # (`test -n '$(somedir)' && $(mkdir_p) $(somedir)' is a more
2359   # expensive solution, as it forces Make to start a sub-shell.)
2360   mkdir_p='mkdir -p -- .'
2361 else
2362   # On NextStep and OpenStep, the `mkdir' command does not
2363   # recognize any option.  It will interpret all options as
2364   # directories to create, and then abort because `.' already
2365   # exists.
2366   for d in ./-p ./--version;
2367   do
2368     test -d $d && rmdir $d
2369   done
2370   # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists.
2371   if test -f "$ac_aux_dir/mkinstalldirs"; then
2372     mkdir_p='$(mkinstalldirs)'
2373   else
2374     mkdir_p='$(install_sh) -d'
2375   fi
2376 fi
2377
2378 for ac_prog in gawk mawk nawk awk
2379 do
2380   # Extract the first word of "$ac_prog", so it can be a program name with args.
2381 set dummy $ac_prog; ac_word=$2
2382 { echo "$as_me:$LINENO: checking for $ac_word" >&5
2383 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
2384 if test "${ac_cv_prog_AWK+set}" = set; then
2385   echo $ECHO_N "(cached) $ECHO_C" >&6
2386 else
2387   if test -n "$AWK"; then
2388   ac_cv_prog_AWK="$AWK" # Let the user override the test.
2389 else
2390 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2391 for as_dir in $PATH
2392 do
2393   IFS=$as_save_IFS
2394   test -z "$as_dir" && as_dir=.
2395   for ac_exec_ext in '' $ac_executable_extensions; do
2396   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2397     ac_cv_prog_AWK="$ac_prog"
2398     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2399     break 2
2400   fi
2401 done
2402 done
2403 IFS=$as_save_IFS
2404
2405 fi
2406 fi
2407 AWK=$ac_cv_prog_AWK
2408 if test -n "$AWK"; then
2409   { echo "$as_me:$LINENO: result: $AWK" >&5
2410 echo "${ECHO_T}$AWK" >&6; }
2411 else
2412   { echo "$as_me:$LINENO: result: no" >&5
2413 echo "${ECHO_T}no" >&6; }
2414 fi
2415
2416
2417   test -n "$AWK" && break
2418 done
2419
2420 { echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
2421 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6; }
2422 set x ${MAKE-make}; ac_make=`echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
2423 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then
2424   echo $ECHO_N "(cached) $ECHO_C" >&6
2425 else
2426   cat >conftest.make <<\_ACEOF
2427 SHELL = /bin/sh
2428 all:
2429         @echo '@@@%%%=$(MAKE)=@@@%%%'
2430 _ACEOF
2431 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
2432 case `${MAKE-make} -f conftest.make 2>/dev/null` in
2433   *@@@%%%=?*=@@@%%%*)
2434     eval ac_cv_prog_make_${ac_make}_set=yes;;
2435   *)
2436     eval ac_cv_prog_make_${ac_make}_set=no;;
2437 esac
2438 rm -f conftest.make
2439 fi
2440 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
2441   { echo "$as_me:$LINENO: result: yes" >&5
2442 echo "${ECHO_T}yes" >&6; }
2443   SET_MAKE=
2444 else
2445   { echo "$as_me:$LINENO: result: no" >&5
2446 echo "${ECHO_T}no" >&6; }
2447   SET_MAKE="MAKE=${MAKE-make}"
2448 fi
2449
2450 rm -rf .tst 2>/dev/null
2451 mkdir .tst 2>/dev/null
2452 if test -d .tst; then
2453   am__leading_dot=.
2454 else
2455   am__leading_dot=_
2456 fi
2457 rmdir .tst 2>/dev/null
2458
2459 # test to see if srcdir already configured
2460 if test "`cd $srcdir && pwd`" != "`pwd`" &&
2461    test -f $srcdir/config.status; then
2462   { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
2463 echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
2464    { (exit 1); exit 1; }; }
2465 fi
2466
2467 # test whether we have cygpath
2468 if test -z "$CYGPATH_W"; then
2469   if (cygpath --version) >/dev/null 2>/dev/null; then
2470     CYGPATH_W='cygpath -w'
2471   else
2472     CYGPATH_W=echo
2473   fi
2474 fi
2475
2476
2477 # Define the identity of the package.
2478  PACKAGE='gmp'
2479  VERSION='4.3.2'
2480
2481
2482 cat >>confdefs.h <<_ACEOF
2483 #define PACKAGE "$PACKAGE"
2484 _ACEOF
2485
2486
2487 cat >>confdefs.h <<_ACEOF
2488 #define VERSION "$VERSION"
2489 _ACEOF
2490
2491 # Some tools Automake needs.
2492
2493 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
2494
2495
2496 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
2497
2498
2499 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
2500
2501
2502 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
2503
2504
2505 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
2506
2507
2508 AMTAR=${AMTAR-"${am_missing_run}tar"}
2509
2510 install_sh=${install_sh-"$am_aux_dir/install-sh"}
2511
2512 # Installed binaries are usually stripped using `strip' when the user
2513 # run `make install-strip'.  However `strip' might not be the right
2514 # tool to use in cross-compilation environments, therefore Automake
2515 # will honor the `STRIP' environment variable to overrule this program.
2516 if test "$cross_compiling" != no; then
2517   if test -n "$ac_tool_prefix"; then
2518   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
2519 set dummy ${ac_tool_prefix}strip; ac_word=$2
2520 { echo "$as_me:$LINENO: checking for $ac_word" >&5
2521 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
2522 if test "${ac_cv_prog_STRIP+set}" = set; then
2523   echo $ECHO_N "(cached) $ECHO_C" >&6
2524 else
2525   if test -n "$STRIP"; then
2526   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
2527 else
2528 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2529 for as_dir in $PATH
2530 do
2531   IFS=$as_save_IFS
2532   test -z "$as_dir" && as_dir=.
2533   for ac_exec_ext in '' $ac_executable_extensions; do
2534   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2535     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
2536     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2537     break 2
2538   fi
2539 done
2540 done
2541 IFS=$as_save_IFS
2542
2543 fi
2544 fi
2545 STRIP=$ac_cv_prog_STRIP
2546 if test -n "$STRIP"; then
2547   { echo "$as_me:$LINENO: result: $STRIP" >&5
2548 echo "${ECHO_T}$STRIP" >&6; }
2549 else
2550   { echo "$as_me:$LINENO: result: no" >&5
2551 echo "${ECHO_T}no" >&6; }
2552 fi
2553
2554
2555 fi
2556 if test -z "$ac_cv_prog_STRIP"; then
2557   ac_ct_STRIP=$STRIP
2558   # Extract the first word of "strip", so it can be a program name with args.
2559 set dummy strip; ac_word=$2
2560 { echo "$as_me:$LINENO: checking for $ac_word" >&5
2561 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
2562 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
2563   echo $ECHO_N "(cached) $ECHO_C" >&6
2564 else
2565   if test -n "$ac_ct_STRIP"; then
2566   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
2567 else
2568 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2569 for as_dir in $PATH
2570 do
2571   IFS=$as_save_IFS
2572   test -z "$as_dir" && as_dir=.
2573   for ac_exec_ext in '' $ac_executable_extensions; do
2574   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2575     ac_cv_prog_ac_ct_STRIP="strip"
2576     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2577     break 2
2578   fi
2579 done
2580 done
2581 IFS=$as_save_IFS
2582
2583 fi
2584 fi
2585 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
2586 if test -n "$ac_ct_STRIP"; then
2587   { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
2588 echo "${ECHO_T}$ac_ct_STRIP" >&6; }
2589 else
2590   { echo "$as_me:$LINENO: result: no" >&5
2591 echo "${ECHO_T}no" >&6; }
2592 fi
2593
2594   if test "x$ac_ct_STRIP" = x; then
2595     STRIP=":"
2596   else
2597     case $cross_compiling:$ac_tool_warned in
2598 yes:)
2599 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
2600 whose name does not start with the host triplet.  If you think this
2601 configuration is useful to you, please write to autoconf@gnu.org." >&5
2602 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
2603 whose name does not start with the host triplet.  If you think this
2604 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
2605 ac_tool_warned=yes ;;
2606 esac
2607     STRIP=$ac_ct_STRIP
2608   fi
2609 else
2610   STRIP="$ac_cv_prog_STRIP"
2611 fi
2612
2613 fi
2614 INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
2615
2616 # We need awk for the "check" target.  The system "awk" is bad on
2617 # some platforms.
2618
2619
2620
2621 ac_config_headers="$ac_config_headers config.h:config.in"
2622
2623 { echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5
2624 echo $ECHO_N "checking whether to enable maintainer-specific portions of Makefiles... $ECHO_C" >&6; }
2625     # Check whether --enable-maintainer-mode was given.
2626 if test "${enable_maintainer_mode+set}" = set; then
2627   enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2628 else
2629   USE_MAINTAINER_MODE=no
2630 fi
2631
2632   { echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5
2633 echo "${ECHO_T}$USE_MAINTAINER_MODE" >&6; }
2634
2635
2636 if test $USE_MAINTAINER_MODE = yes; then
2637   MAINTAINER_MODE_TRUE=
2638   MAINTAINER_MODE_FALSE='#'
2639 else
2640   MAINTAINER_MODE_TRUE='#'
2641   MAINTAINER_MODE_FALSE=
2642 fi
2643
2644   MAINT=$MAINTAINER_MODE_TRUE
2645
2646
2647
2648
2649 # Check whether --enable-assert was given.
2650 if test "${enable_assert+set}" = set; then
2651   enableval=$enable_assert; case $enableval in
2652 yes|no) ;;
2653 *) { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-assert, need yes or no" >&5
2654 echo "$as_me: error: bad value $enableval for --enable-assert, need yes or no" >&2;}
2655    { (exit 1); exit 1; }; } ;;
2656 esac
2657 else
2658   enable_assert=no
2659 fi
2660
2661
2662 if test "$enable_assert" = "yes"; then
2663
2664 cat >>confdefs.h <<\_ACEOF
2665 #define WANT_ASSERT 1
2666 _ACEOF
2667
2668   want_assert_01=1
2669 else
2670   want_assert_01=0
2671 fi
2672
2673 echo "define(<WANT_ASSERT>,$want_assert_01)" >> $gmp_tmpconfigm4
2674
2675
2676
2677 # Check whether --enable-alloca was given.
2678 if test "${enable_alloca+set}" = set; then
2679   enableval=$enable_alloca; case $enableval in
2680 alloca|malloc-reentrant|malloc-notreentrant) ;;
2681 yes|no|reentrant|notreentrant) ;;
2682 debug) ;;
2683 *)
2684   { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-alloca, need one of:
2685 yes no reentrant notreentrant alloca malloc-reentrant malloc-notreentrant debug" >&5
2686 echo "$as_me: error: bad value $enableval for --enable-alloca, need one of:
2687 yes no reentrant notreentrant alloca malloc-reentrant malloc-notreentrant debug" >&2;}
2688    { (exit 1); exit 1; }; } ;;
2689 esac
2690 else
2691   enable_alloca=reentrant
2692 fi
2693
2694
2695
2696 # IMPROVE ME: The default for C++ is disabled.  The tests currently
2697 # performed below for a working C++ compiler are not particularly strong,
2698 # and in general can't be expected to get the right setup on their own.  The
2699 # most significant problem is getting the ABI the same.  Defaulting CXXFLAGS
2700 # to CFLAGS takes only a small step towards this.  It's also probably worth
2701 # worrying whether the C and C++ runtimes from say gcc and a vendor C++ can
2702 # work together.  Some rather broken C++ installations were encountered
2703 # during testing, and though such things clearly aren't GMP's problem, if
2704 # --enable-cxx=detect were to be the default then some careful checks of
2705 # which, if any, C++ compiler on the system is up to scratch would be
2706 # wanted.
2707 #
2708 # Check whether --enable-cxx was given.
2709 if test "${enable_cxx+set}" = set; then
2710   enableval=$enable_cxx; case $enableval in
2711 yes|no|detect) ;;
2712 *) { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-cxx, need yes/no/detect" >&5
2713 echo "$as_me: error: bad value $enableval for --enable-cxx, need yes/no/detect" >&2;}
2714    { (exit 1); exit 1; }; } ;;
2715 esac
2716 else
2717   enable_cxx=no
2718 fi
2719
2720
2721
2722 # Check whether --enable-fft was given.
2723 if test "${enable_fft+set}" = set; then
2724   enableval=$enable_fft; case $enableval in
2725 yes|no) ;;
2726 *) { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-fft, need yes or no" >&5
2727 echo "$as_me: error: bad value $enableval for --enable-fft, need yes or no" >&2;}
2728    { (exit 1); exit 1; }; } ;;
2729 esac
2730 else
2731   enable_fft=yes
2732 fi
2733
2734
2735 if test "$enable_fft" = "yes"; then
2736
2737 cat >>confdefs.h <<\_ACEOF
2738 #define WANT_FFT 1
2739 _ACEOF
2740
2741 fi
2742
2743
2744 # Check whether --enable-mpbsd was given.
2745 if test "${enable_mpbsd+set}" = set; then
2746   enableval=$enable_mpbsd; case $enableval in
2747 yes|no) ;;
2748 *) { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-mpbsd, need yes or no" >&5
2749 echo "$as_me: error: bad value $enableval for --enable-mpbsd, need yes or no" >&2;}
2750    { (exit 1); exit 1; }; } ;;
2751 esac
2752 else
2753   enable_mpbsd=no
2754 fi
2755
2756
2757
2758 if test "$enable_mpbsd" = "yes"; then
2759   WANT_MPBSD_TRUE=
2760   WANT_MPBSD_FALSE='#'
2761 else
2762   WANT_MPBSD_TRUE='#'
2763   WANT_MPBSD_FALSE=
2764 fi
2765
2766
2767
2768 # Check whether --enable-nails was given.
2769 if test "${enable_nails+set}" = set; then
2770   enableval=$enable_nails; case $enableval in
2771 yes|no|[02468]|[0-9][02468]) ;;
2772 *[13579])
2773   { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-nails, only even nail sizes supported" >&5
2774 echo "$as_me: error: bad value $enableval for --enable-nails, only even nail sizes supported" >&2;}
2775    { (exit 1); exit 1; }; } ;;
2776 *)
2777   { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-nails, need yes/no/number" >&5
2778 echo "$as_me: error: bad value $enableval for --enable-nails, need yes/no/number" >&2;}
2779    { (exit 1); exit 1; }; } ;;
2780 esac
2781 else
2782   enable_nails=no
2783 fi
2784
2785
2786 case $enable_nails in
2787 yes) GMP_NAIL_BITS=2 ;;
2788 no)  GMP_NAIL_BITS=0 ;;
2789 *)   GMP_NAIL_BITS=$enable_nails ;;
2790 esac
2791
2792
2793
2794 # Check whether --enable-profiling was given.
2795 if test "${enable_profiling+set}" = set; then
2796   enableval=$enable_profiling; case $enableval in
2797 no|prof|gprof|instrument) ;;
2798 *) { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-profiling, need no/prof/gprof/instrument" >&5
2799 echo "$as_me: error: bad value $enableval for --enable-profiling, need no/prof/gprof/instrument" >&2;}
2800    { (exit 1); exit 1; }; } ;;
2801 esac
2802 else
2803   enable_profiling=no
2804 fi
2805
2806
2807 case $enable_profiling in
2808   prof)
2809
2810 cat >>confdefs.h <<\_ACEOF
2811 #define WANT_PROFILING_PROF 1
2812 _ACEOF
2813
2814     ;;
2815   gprof)
2816
2817 cat >>confdefs.h <<\_ACEOF
2818 #define WANT_PROFILING_GPROF 1
2819 _ACEOF
2820
2821     ;;
2822   instrument)
2823
2824 cat >>confdefs.h <<\_ACEOF
2825 #define WANT_PROFILING_INSTRUMENT 1
2826 _ACEOF
2827
2828     ;;
2829 esac
2830
2831
2832 echo "define(<WANT_PROFILING>,<\`$enable_profiling'>)" >> $gmp_tmpconfigm4
2833
2834
2835 # -fomit-frame-pointer is incompatible with -pg on some chips
2836 if test "$enable_profiling" = gprof; then
2837   fomit_frame_pointer=
2838 else
2839   fomit_frame_pointer="-fomit-frame-pointer"
2840 fi
2841
2842
2843
2844 # Check whether --with-readline was given.
2845 if test "${with_readline+set}" = set; then
2846   withval=$with_readline; case $withval in
2847 yes|no|detect) ;;
2848 *) { { echo "$as_me:$LINENO: error: bad value $withval for --with-readline, need yes/no/detect" >&5
2849 echo "$as_me: error: bad value $withval for --with-readline, need yes/no/detect" >&2;}
2850    { (exit 1); exit 1; }; } ;;
2851 esac
2852 else
2853   with_readline=detect
2854 fi
2855
2856
2857
2858 # Check whether --enable-fat was given.
2859 if test "${enable_fat+set}" = set; then
2860   enableval=$enable_fat; case $enableval in
2861 yes|no) ;;
2862 *) { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-fat, need yes or no" >&5
2863 echo "$as_me: error: bad value $enableval for --enable-fat, need yes or no" >&2;}
2864    { (exit 1); exit 1; }; } ;;
2865 esac
2866 else
2867   enable_fat=no
2868 fi
2869
2870
2871
2872 # Check whether --enable-minithres was given.
2873 if test "${enable_minithres+set}" = set; then
2874   enableval=$enable_minithres; case $enableval in
2875 yes|no) ;;
2876 *) { { echo "$as_me:$LINENO: error: bad value $enableval for --enable-minithres, need yes or no" >&5
2877 echo "$as_me: error: bad value $enableval for --enable-minithres, need yes or no" >&2;}
2878    { (exit 1); exit 1; }; } ;;
2879 esac
2880 else
2881   enable_minithres=no
2882 fi
2883
2884
2885
2886
2887 tmp_host=`echo $host_cpu | sed 's/\./_/'`
2888 cat >>confdefs.h <<_ACEOF
2889 #define HAVE_HOST_CPU_$tmp_host 1
2890 _ACEOF
2891
2892
2893 echo "define_not_for_expansion(\`HAVE_HOST_CPU_$tmp_host')" >> $gmp_tmpconfigm4p
2894
2895
2896
2897
2898
2899
2900
2901 # Table of compilers, options, and mpn paths.  This code has various related
2902 # purposes
2903 #
2904 #   - better default CC/CFLAGS selections than autoconf otherwise gives
2905 #   - default CC/CFLAGS selections for extra CPU types specific to GMP
2906 #   - a few tests for known bad compilers
2907 #   - choice of ABIs on suitable systems
2908 #   - selection of corresponding mpn search path
2909 #
2910 # After GMP specific searches and tests, the standard autoconf AC_PROG_CC is
2911 # called.  User selections of CC etc are respected.
2912 #
2913 # Care is taken not to use macros like AC_TRY_COMPILE during the GMP
2914 # pre-testing, since they of course depend on AC_PROG_CC, and also some of
2915 # them cache their results, which is not wanted.
2916 #
2917 # The ABI selection mechanism is unique to GMP.  All that reaches autoconf
2918 # is a different selection of CC/CFLAGS according to the best ABI the system
2919 # supports, and/or what the user selects.  Naturally the mpn assembler code
2920 # selected is very dependent on the ABI.
2921 #
2922 # The closest the standard tools come to a notion of ABI is something like
2923 # "sparc64" which encodes a CPU and an ABI together.  This doesn't seem to
2924 # scale well for GMP, where exact CPU types like "ultrasparc2" are wanted,
2925 # separate from the ABI used on them.
2926 #
2927 #
2928 # The variables set here are
2929 #
2930 #   cclist              the compiler choices
2931 #   xx_cflags           flags for compiler xx
2932 #   xx_cflags_maybe     flags for compiler xx, if they work
2933 #   xx_cppflags         cpp flags for compiler xx
2934 #   xx_cflags_optlist   list of sets of optional flags
2935 #   xx_cflags_yyy       set yyy of optional flags for compiler xx
2936 #   xx_ldflags          -Wc,-foo flags for libtool linking with compiler xx
2937 #   ar_flags            extra flags for $AR
2938 #   nm_flags            extra flags for $NM
2939 #   limb                limb size, can be "longlong"
2940 #   path                mpn search path
2941 #   extra_functions     extra mpn functions
2942 #   fat_path            fat binary mpn search path [if fat binary desired]
2943 #   fat_functions       fat functions
2944 #   fat_thresholds      fat thresholds
2945 #
2946 # Suppose xx_cflags_optlist="arch", then flags from $xx_cflags_arch are
2947 # tried, and the first flag that works will be used.  An optlist like "arch
2948 # cpu optimize" can be used to get multiple independent sets of flags tried.
2949 # The first that works from each will be used.  If no flag in a set works
2950 # then nothing from that set is added.
2951 #
2952 # For multiple ABIs, the scheme extends as follows.
2953 #
2954 #   abilist               set of ABI choices
2955 #   cclist_aa             compiler choices in ABI aa
2956 #   xx_aa_cflags          flags for xx in ABI aa
2957 #   xx_aa_cflags_maybe    flags for xx in ABI aa, if they work
2958 #   xx_aa_cppflags        cpp flags for xx in ABI aa
2959 #   xx_aa_cflags_optlist  list of sets of optional flags in ABI aa
2960 #   xx_aa_cflags_yyy      set yyy of optional flags for compiler xx in ABI aa
2961 #   xx_aa_ldflags         -Wc,-foo flags for libtool linking
2962 #   ar_aa_flags           extra flags for $AR in ABI aa
2963 #   nm_aa_flags           extra flags for $NM in ABI aa
2964 #   limb_aa               limb size in ABI aa, can be "longlong"
2965 #   path_aa               mpn search path in ABI aa
2966 #   extra_functions_aa    extra mpn functions in ABI aa
2967 #
2968 # As a convenience, the unadorned xx_cflags (etc) are used for the last ABI
2969 # in ablist, if an xx_aa_cflags for that ABI isn't given.  For example if
2970 # abilist="64 32" then $cc_64_cflags will be used for the 64-bit ABI, but
2971 # for the 32-bit either $cc_32_cflags or $cc_cflags is used, whichever is
2972 # defined.  This makes it easy to add some 64-bit compilers and flags to an
2973 # unadorned 32-bit set.
2974 #
2975 # limb=longlong (or limb_aa=longlong) applies to all compilers within that
2976 # ABI.  It won't work to have some needing long long and some not, since a
2977 # single instantiated gmp.h will be used by both.
2978 #
2979 # SPEED_CYCLECOUNTER, cyclecounter_size and CALLING_CONVENTIONS_OBJS are
2980 # also set here, with an ABI suffix.
2981 #
2982 #
2983 #
2984 # A table-driven approach like this to mapping cpu type to good compiler
2985 # options is a bit of a maintenance burden, but there's not much uniformity
2986 # between options specifications on different compilers.  Some sort of
2987 # separately updatable tool might be cute.
2988 #
2989 # The use of lots of variables like this, direct and indirect, tends to
2990 # obscure when and how various things are done, but unfortunately it's
2991 # pretty much the only way.  If shell subroutines were portable then actual
2992 # code like "if this .. do that" could be written, but attempting the same
2993 # with full copies of GMP_PROG_CC_WORKS etc expanded at every point would
2994 # hugely bloat the output.
2995
2996
2997
2998
2999 # abilist needs to be non-empty, "standard" is just a generic name here
3000 abilist="standard"
3001
3002 # FIXME: We'd like to prefer an ANSI compiler, perhaps by preferring
3003 # c89 over cc here.  But note that on HP-UX c89 provides a castrated
3004 # environment, and would want to be excluded somehow.  Maybe
3005 # AC_PROG_CC_STDC already does enough to stick cc into ANSI mode and
3006 # we don't need to worry.
3007 #
3008 cclist="gcc cc"
3009
3010 gcc_cflags="-O2 -pedantic"
3011 gcc_64_cflags="-O2 -pedantic"
3012 cc_cflags="-O"
3013 cc_64_cflags="-O"
3014
3015 SPEED_CYCLECOUNTER_OBJ=
3016 cyclecounter_size=2
3017
3018 HAVE_HOST_CPU_FAMILY_power=0
3019
3020 HAVE_HOST_CPU_FAMILY_powerpc=0
3021
3022
3023 case $host in
3024
3025   a29k*-*-*)
3026     path="a29k"
3027     ;;
3028
3029
3030   alpha*-*-*)
3031     cat >>confdefs.h <<\_ACEOF
3032 #define HAVE_HOST_CPU_FAMILY_alpha 1
3033 _ACEOF
3034
3035     case $host_cpu in
3036       alphaev5* | alphapca5*) path="alpha/ev5 alpha" ;;
3037       alphaev67 | alphaev68 | alphaev7*)
3038         path="alpha/ev67 alpha/ev6 alpha/ev5 alpha" ;;
3039       alphaev6* | alphaev7*)  path="alpha/ev6 alpha/ev5 alpha" ;;
3040       *)                      path="alpha" ;;
3041     esac
3042     extra_functions="cntlz"
3043     gcc_cflags_optlist="asm cpu oldas" # need asm ahead of cpu, see below
3044     gcc_cflags_oldas="-Wa,-oldas"     # see GMP_GCC_WA_OLDAS.
3045
3046     # gcc 2.7.2.3 doesn't know any -mcpu= for alpha, apparently.
3047     # gcc 2.95 knows -mcpu= ev4, ev5, ev56, pca56, ev6.
3048     # gcc 3.0 adds nothing.
3049     # gcc 3.1 adds ev45, ev67 (but ev45 is the same as ev4).
3050     # gcc 3.2 adds nothing.
3051     #
3052     # gcc version "2.9-gnupro-99r1" under "-O2 -mcpu=ev6" strikes internal
3053     # compiler errors too easily and is rejected by GMP_PROG_CC_WORKS.  Each
3054     # -mcpu=ev6 below has a fallback to -mcpu=ev56 for this reason.
3055     #
3056     case $host_cpu in
3057       alpha)        gcc_cflags_cpu="-mcpu=ev4" ;;
3058       alphaev5)     gcc_cflags_cpu="-mcpu=ev5" ;;
3059       alphaev56)    gcc_cflags_cpu="-mcpu=ev56" ;;
3060       alphapca56 | alphapca57)
3061                     gcc_cflags_cpu="-mcpu=pca56" ;;
3062       alphaev6)     gcc_cflags_cpu="-mcpu=ev6 -mcpu=ev56" ;;
3063       alphaev67 | alphaev68 | alphaev7*)
3064                     gcc_cflags_cpu="-mcpu=ev67 -mcpu=ev6 -mcpu=ev56" ;;
3065     esac
3066
3067     # gcc version "2.9-gnupro-99r1" on alphaev68-dec-osf5.1 has been seen
3068     # accepting -mcpu=ev6, but not putting the assembler in the right mode
3069     # for what it produces.  We need to do this for it, and need to do it
3070     # before testing the -mcpu options.
3071     #
3072     # On old versions of gcc, which don't know -mcpu=, we believe an
3073     # explicit -Wa,-mev5 etc will be necessary to put the assembler in
3074     # the right mode for our .asm files and longlong.h asm blocks.
3075     #
3076     # On newer versions of gcc, when -mcpu= is known, we must give a -Wa
3077     # which is at least as high as the code gcc will generate.  gcc
3078     # establishes what it needs with a ".arch" directive, our command line
3079     # option seems to override that.
3080     #
3081     # gas prior to 2.14 doesn't accept -mev67, but -mev6 seems enough for
3082     # ctlz and cttz (in 2.10.0 at least).
3083     #
3084     # OSF `as' accepts ev68 but stupidly treats it as ev4.  -arch only seems
3085     # to affect insns like ldbu which are expanded as macros when necessary.
3086     # Insns like ctlz which were never available as macros are always
3087     # accepted and always generate their plain code.
3088     #
3089     case $host_cpu in
3090       alpha)        gcc_cflags_asm="-Wa,-arch,ev4 -Wa,-mev4" ;;
3091       alphaev5)     gcc_cflags_asm="-Wa,-arch,ev5 -Wa,-mev5" ;;
3092       alphaev56)    gcc_cflags_asm="-Wa,-arch,ev56 -Wa,-mev56" ;;
3093       alphapca56 | alphapca57)
3094                     gcc_cflags_asm="-Wa,-arch,pca56 -Wa,-mpca56" ;;
3095       alphaev6)     gcc_cflags_asm="-Wa,-arch,ev6 -Wa,-mev6" ;;
3096       alphaev67 | alphaev68 | alphaev7*)
3097                     gcc_cflags_asm="-Wa,-arch,ev67 -Wa,-mev67 -Wa,-arch,ev6 -Wa,-mev6" ;;
3098     esac
3099
3100     # It might be better to ask "cc" whether it's Cray C or DEC C,
3101     # instead of relying on the OS part of $host.  But it's hard to
3102     # imagine either of those compilers anywhere except their native
3103     # systems.
3104     #
3105
3106 echo "include_mpn(\`alpha/alpha-defs.m4')" >> $gmp_tmpconfigm4i
3107
3108     case $host in
3109       *-cray-unicos*)
3110         cc_cflags="-O"          # no -g, it silently disables all optimizations
3111
3112 echo "include_mpn(\`alpha/unicos.m4')" >> $gmp_tmpconfigm4i
3113
3114         # Don't perform any assembly syntax tests on this beast.
3115         gmp_asm_syntax_testing=no
3116         ;;
3117       *-*-osf*)
3118
3119 echo "include_mpn(\`alpha/default.m4')" >> $gmp_tmpconfigm4i
3120
3121         cc_cflags=""
3122         cc_cflags_optlist="opt cpu"
3123
3124         # not sure if -fast works on old versions, so make it optional
3125         cc_cflags_opt="-fast -O2"
3126
3127         # DEC C V5.9-005 knows ev4, ev5, ev56, pca56, ev6.
3128         # Compaq C V6.3-029 adds ev67.
3129         #
3130         case $host_cpu in
3131           alpha)       cc_cflags_cpu="-arch~ev4~-tune~ev4" ;;
3132           alphaev5)    cc_cflags_cpu="-arch~ev5~-tune~ev5" ;;
3133           alphaev56)   cc_cflags_cpu="-arch~ev56~-tune~ev56" ;;
3134           alphapca56 | alphapca57)
3135             cc_cflags_cpu="-arch~pca56~-tune~pca56" ;;
3136           alphaev6)    cc_cflags_cpu="-arch~ev6~-tune~ev6" ;;
3137           alphaev67 | alphaev68 | alphaev7*)
3138             cc_cflags_cpu="-arch~ev67~-tune~ev67 -arch~ev6~-tune~ev6" ;;
3139         esac
3140         ;;
3141       *)
3142
3143 echo "include_mpn(\`alpha/default.m4')" >> $gmp_tmpconfigm4i
3144
3145         ;;
3146     esac
3147
3148     case $host in
3149       *-*-unicos*)
3150         # tune/alpha.asm assumes int==4bytes but unicos uses int==8bytes
3151         ;;
3152       *)
3153         SPEED_CYCLECOUNTER_OBJ=alpha.lo
3154         cyclecounter_size=1 ;;
3155     esac
3156     ;;
3157
3158
3159   # Cray vector machines.
3160   # This must come after alpha* so that we can recognize present and future
3161   # vector processors with a wildcard.
3162   *-cray-unicos*)
3163     gmp_asm_syntax_testing=no
3164     cclist="cc"
3165     # We used to have -hscalar0 here as a workaround for miscompilation of
3166     # mpz/import.c, but let's hope Cray fixes their bugs instead, since
3167     # -hscalar0 causes disastrously poor code to be generated.
3168     cc_cflags="-O3 -hnofastmd -htask0 -Wa,-B"
3169     path="cray"
3170     ;;
3171
3172
3173   arm*-*-*)
3174     path="arm"
3175     gcc_cflags="$gcc_cflags $fomit_frame_pointer"
3176     gcc_testlist="gcc-arm-umodsi"
3177
3178 echo "include_mpn(\`arm/arm-defs.m4')" >> $gmp_tmpconfigm4i
3179
3180     ;;
3181
3182
3183   clipper*-*-*)
3184     path="clipper"
3185     ;;
3186
3187
3188   # Fujitsu
3189   f30[01]-fujitsu-sysv*)
3190     cclist="gcc vcc"
3191     # FIXME: flags for vcc?
3192     vcc_cflags="-g"
3193     path="fujitsu"
3194     ;;
3195
3196
3197   hppa*-*-*)
3198     # HP cc (the one sold separately) is K&R by default, but AM_C_PROTOTYPES
3199     # will add "-Ae", or "-Aa -D_HPUX_SOURCE", to put it into ansi mode, if
3200     # possible.
3201     #
3202     # gcc for hppa 2.0 can be built either for 2.0n (32-bit) or 2.0w
3203     # (64-bit), but not both, so there's no option to choose the desired
3204     # mode, we must instead detect which of the two it is.  This is done by
3205     # checking sizeof(long), either 4 or 8 bytes respectively.  Do this in
3206     # ABI=1.0 too, in case someone tries to build that with a 2.0w gcc.
3207     #
3208     gcc_cflags="-O2"
3209     gcc_cflags_optlist="arch"
3210     gcc_testlist="sizeof-long-4"
3211     SPEED_CYCLECOUNTER_OBJ=hppa.lo
3212     cyclecounter_size=1
3213
3214     # FIXME: For hppa2.0*, path should be "pa32/hppa2_0 pa32/hppa1_1 pa32".
3215     # (Can't remember why this isn't done already, have to check what .asm
3216     # files are available in each and how they run on a typical 2.0 cpu.)
3217     #
3218     case $host_cpu in
3219       hppa1.0*)    path="pa32" ;;
3220       hppa7000*)   path="pa32/hppa1_1 pa32" ;;
3221       hppa2.0* | hppa64)
3222                    path="pa32/hppa2_0 pa32/hppa1_1/pa7100 pa32/hppa1_1 pa32" ;;
3223       *)           # default to 7100
3224                    path="pa32/hppa1_1/pa7100 pa32/hppa1_1 pa32" ;;
3225     esac
3226
3227     # gcc 2.7.2.3 knows -mpa-risc-1-0 and -mpa-risc-1-1
3228     # gcc 2.95 adds -mpa-risc-2-0, plus synonyms -march=1.0, 1.1 and 2.0
3229     #
3230     # We don't use -mpa-risc-2-0 in ABI=1.0 because 64-bit registers may not
3231     # be saved by the kernel on an old system.  Actually gcc (as of 3.2)
3232     # only adds a few float instructions with -mpa-risc-2-0, so it would
3233     # probably be safe, but let's not take the chance.  In any case, a
3234     # configuration like --host=hppa2.0 ABI=1.0 is far from optimal.
3235     #
3236     case $host_cpu in
3237       hppa1.0*)           gcc_cflags_arch="-mpa-risc-1-0" ;;
3238       *)                  # default to 7100
3239                           gcc_cflags_arch="-mpa-risc-1-1" ;;
3240     esac
3241
3242     case $host_cpu in
3243       hppa1.0*)    cc_cflags="+O2" ;;
3244       *)           # default to 7100
3245                    cc_cflags="+DA1.1 +O2" ;;
3246     esac
3247
3248     case $host in
3249       hppa2.0*-*-* | hppa64-*-*)
3250         cclist_20n="gcc cc"
3251         abilist="2.0n 1.0"
3252         path_20n="pa64"
3253         limb_20n=longlong
3254         any_20n_testlist="sizeof-long-4"
3255         SPEED_CYCLECOUNTER_OBJ_20n=hppa2.lo
3256         cyclecounter_size_20n=2
3257
3258         # -mpa-risc-2-0 is only an optional flag, in case an old gcc is
3259         # used.  Assembler support for 2.0 is essential though, for our asm
3260         # files.
3261         gcc_20n_cflags="-O2"
3262         gcc_20n_cflags_optlist="arch"
3263         gcc_20n_cflags_arch="-mpa-risc-2-0 -mpa-risc-1-1"
3264         gcc_20n_testlist="sizeof-long-4 hppa-level-2.0"
3265
3266         cc_20n_cflags="+DA2.0 +e +O2 -Wl,+vnocompatwarnings"
3267         cc_20n_testlist="hpc-hppa-2-0"
3268
3269         # ABI=2.0w is available for hppa2.0w and hppa2.0, but not for
3270         # hppa2.0n, on the assumption that that the latter indicates a
3271         # desire for ABI=2.0n.
3272         case $host in
3273         hppa2.0n-*-*) ;;
3274         *)
3275           # HPUX 10 and earlier cannot run 2.0w.  Not sure about other
3276           # systems (GNU/Linux for instance), but lets assume they're ok.
3277           case $host in
3278             *-*-hpux[1-9] | *-*-hpux[1-9].* | *-*-hpux10 | *-*-hpux10.*) ;;
3279             *)    abilist="2.0w $abilist" ;;
3280           esac
3281
3282           cclist_20w="gcc cc"
3283           gcc_20w_cflags="-O2 -mpa-risc-2-0"
3284           cc_20w_cflags="+DD64 +O2"
3285           cc_20w_testlist="hpc-hppa-2-0"
3286           path_20w="pa64"
3287           any_20w_testlist="sizeof-long-8"
3288           SPEED_CYCLECOUNTER_OBJ_20w=hppa2w.lo
3289           cyclecounter_size_20w=2
3290           ;;
3291         esac
3292         ;;
3293     esac
3294     ;;
3295
3296
3297   i960*-*-*)
3298     path="i960"
3299     ;;
3300
3301
3302   ia64*-*-* | itanium-*-* | itanium2-*-*)
3303     abilist="64"
3304
3305 echo "include_mpn(\`ia64/ia64-defs.m4')" >> $gmp_tmpconfigm4i
3306
3307     SPEED_CYCLECOUNTER_OBJ=ia64.lo
3308
3309     case $host_cpu in
3310       itanium)   path="ia64/itanium  ia64" ;;
3311       itanium2)  path="ia64/itanium2 ia64" ;;
3312       *)         path="ia64" ;;
3313     esac
3314
3315     gcc_64_cflags_optlist="tune"
3316     gcc_32_cflags_optlist=$gcc_64_cflags_optlist
3317
3318     # gcc pre-release 3.4 adds -mtune itanium and itanium2
3319     case $host_cpu in
3320       itanium)   gcc_cflags_tune="-mtune=itanium" ;;
3321       itanium2)  gcc_cflags_tune="-mtune=itanium2" ;;
3322     esac
3323
3324     case $host in
3325       *-*-linux*)
3326         cclist="gcc icc"
3327         icc_cflags="-no-gcc"
3328         icc_cflags_optlist="opt"
3329         # Don't use -O3, it is for "large data sets" and also miscompiles GMP.
3330         # But icc miscompiles GMP at any optimization level, at higher levels
3331         # it miscompiles more files...
3332         icc_cflags_opt="-O2 -O1"
3333         ;;
3334
3335       *-*-hpux*)
3336         # HP cc sometimes gets internal errors if the optimization level is
3337         # too high.  GMP_PROG_CC_WORKS detects this, the "_opt" fallbacks
3338         # let us use whatever seems to work.
3339         #
3340         abilist="32 64"
3341
3342         cclist_32="gcc cc"
3343         path_32="ia64"
3344         cc_32_cflags=""
3345         cc_32_cflags_optlist="opt"
3346         cc_32_cflags_opt="+O3 +O2 +O1"
3347         gcc_32_cflags="-milp32 -O2"
3348         limb_32=longlong
3349         SPEED_CYCLECOUNTER_OBJ_32=ia64.lo
3350         cyclecounter_size_32=2
3351
3352         # Must have +DD64 in CPPFLAGS to get the right __LP64__ for headers,
3353         # but also need it in CFLAGS for linking programs, since automake
3354         # only uses CFLAGS when linking, not CPPFLAGS.
3355         # FIXME: Maybe should use cc_64_ldflags for this, but that would
3356         # need GMP_LDFLAGS used consistently by all the programs.
3357         #
3358         cc_64_cflags="+DD64"
3359         cc_64_cppflags="+DD64"
3360         cc_64_cflags_optlist="opt"
3361         cc_64_cflags_opt="+O3 +O2 +O1"
3362         gcc_64_cflags="$gcc_64_cflags -mlp64"
3363         ;;
3364     esac
3365     ;;
3366
3367
3368   # Motorola 68k
3369   #
3370   m68k-*-* | m68[0-9][0-9][0-9]-*-*)
3371     cat >>confdefs.h <<\_ACEOF
3372 #define HAVE_HOST_CPU_FAMILY_m68k 1
3373 _ACEOF
3374
3375
3376 echo "include_mpn(\`m68k/m68k-defs.m4')" >> $gmp_tmpconfigm4i
3377
3378     gcc_cflags="$gcc_cflags $fomit_frame_pointer"
3379     gcc_cflags_optlist="arch"
3380
3381     # gcc 2.7.2 knows -m68000, -m68020, -m68030, -m68040.
3382     # gcc 2.95 adds -mcpu32, -m68060.
3383     # FIXME: Maybe "-m68020 -mnobitfield" would suit cpu32 on 2.7.2.
3384     #
3385     case $host_cpu in
3386     m68020)  gcc_cflags_arch="-m68020" ;;
3387     m68030)  gcc_cflags_arch="-m68030" ;;
3388     m68040)  gcc_cflags_arch="-m68040" ;;
3389     m68060)  gcc_cflags_arch="-m68060 -m68000" ;;
3390     m68360)  gcc_cflags_arch="-mcpu32 -m68000" ;;
3391     *)       gcc_cflags_arch="-m68000" ;;
3392     esac
3393
3394     # FIXME: m68k/mc68020 looks like it's ok for cpu32, but this wants to be
3395     # tested.  Will need to introduce an m68k/cpu32 if m68k/mc68020 ever uses
3396     # the bitfield instructions.
3397     case $host_cpu in
3398     m680[234]0 | m68360)  path="m68k/mc68020 m68k" ;;
3399     *)                      path="m68k" ;;
3400     esac
3401     ;;
3402
3403
3404   # Motorola 88k
3405   m88k*-*-*)
3406     path="m88k"
3407     ;;
3408   m88110*-*-*)
3409     gcc_cflags="$gcc_cflags -m88110"
3410     path="m88k/mc88110 m88k"
3411     ;;
3412
3413
3414   # National Semiconductor 32k
3415   ns32k*-*-*)
3416     path="ns32k"
3417     ;;
3418
3419
3420   # IRIX 5 and earlier can only run 32-bit o32.
3421   #
3422   # IRIX 6 and up always has a 64-bit mips CPU can run n32 or 64.  n32 is
3423   # preferred over 64, but only because that's been the default in past
3424   # versions of GMP.  The two are equally efficient.
3425   #
3426   # Linux kernel 2.2.13 arch/mips/kernel/irixelf.c has a comment about not
3427   # supporting n32 or 64.
3428   #
3429   # For reference, libtool (eg. 1.5.6) recognises the n32 ABI and knows the
3430   # right options to use when linking (both cc and gcc), so no need for
3431   # anything special from us.
3432   #
3433   mips*-*-*)
3434     abilist="o32"
3435     gcc_cflags_optlist="abi"
3436     gcc_cflags_abi="-mabi=32"
3437     gcc_testlist="gcc-mips-o32"
3438     path="mips32"
3439     cc_cflags="-O2 -o32"   # no -g, it disables all optimizations
3440     # this suits both mips32 and mips64
3441
3442 echo "include_mpn(\`mips32/mips-defs.m4')" >> $gmp_tmpconfigm4i
3443
3444
3445     case $host in
3446       mips64*-*-* | mips*-*-irix[6789]*)
3447         abilist="n32 64 o32"
3448
3449         cclist_n32="gcc cc"
3450         gcc_n32_cflags="-O2 -mabi=n32"
3451         cc_n32_cflags="-O2 -n32"        # no -g, it disables all optimizations
3452         limb_n32=longlong
3453         path_n32="mips64"
3454
3455         cclist_64="gcc cc"
3456         gcc_64_cflags="$gcc_64_cflags -mabi=64"
3457         gcc_64_ldflags="-Wc,-mabi=64"
3458         cc_64_cflags="-O2 -64"          # no -g, it disables all optimizations
3459         cc_64_ldflags="-Wc,-64"
3460         path_64="mips64"
3461         ;;
3462     esac
3463     ;;
3464
3465
3466   # Darwin (powerpc-apple-darwin1.3) has it's hacked gcc installed as cc.
3467   # Our usual "gcc in disguise" detection means gcc_cflags etc here gets
3468   # used.
3469   #
3470   # The darwin pre-compiling preprocessor is disabled with -no-cpp-precomp
3471   # since it doesn't like "__attribute__ ((mode (SI)))" etc in gmp-impl.h,
3472   # and so always ends up running the plain preprocessor anyway.  This could
3473   # be done in CPPFLAGS rather than CFLAGS, but there's not many places
3474   # preprocessing is done separately, and this is only a speedup, the normal
3475   # preprocessor gets run if there's any problems.
3476   #
3477   # We used to use -Wa,-mppc with gcc, but can't remember exactly why.
3478   # Presumably it was for old versions of gcc where -mpowerpc doesn't put
3479   # the assembler in the right mode.  In any case -Wa,-mppc is not good, for
3480   # instance -mcpu=604 makes recent gcc use -m604 to get access to the
3481   # "fsel" instruction, but a -Wa,-mppc overrides that, making code that
3482   # comes out with fsel fail.
3483   #
3484   # (Note also that the darwin assembler doesn't accept "-mppc", so any
3485   # -Wa,-mppc was used only if it worked.  The right flag on darwin would be
3486   # "-arch ppc" or some such, but that's already the default.)
3487   #
3488   powerpc*-*-* | power[3-9]-*-*)
3489     cat >>confdefs.h <<\_ACEOF
3490 #define HAVE_HOST_CPU_FAMILY_powerpc 1
3491 _ACEOF
3492
3493     HAVE_HOST_CPU_FAMILY_powerpc=1
3494     abilist="32"
3495     cclist="gcc cc"
3496     cc_cflags="-O2"
3497     gcc_cflags="$gcc_cflags -mpowerpc"
3498     gcc_cflags_optlist="precomp subtype asm cpu"
3499     gcc_cflags_precomp="-no-cpp-precomp"
3500     gcc_cflags_subtype="-force_cpusubtype_ALL"  # for vmx on darwin
3501     gcc_cflags_asm=""
3502     gcc_cflags_cpu=""
3503
3504     # grab this object, though it's not a true cycle counter routine
3505     SPEED_CYCLECOUNTER_OBJ=powerpc.lo
3506     cyclecounter_size=0
3507
3508     case $host_cpu in
3509       powerpc740 | powerpc750)
3510         path="powerpc32/750 powerpc32" ;;
3511       powerpc7400 | powerpc7410)
3512         path="powerpc32/vmx powerpc32/750 powerpc32" ;;
3513       powerpc74[45]?)
3514         path="powerpc32/vmx powerpc32" ;;
3515       *)
3516         path="powerpc32" ;;
3517     esac
3518
3519     # gcc 2.7.2 knows -mcpu=403, 601, 603, 604.
3520     # gcc 2.95 adds 401, 505, 602, 603e, ec603e, 604e, 620, 740, 750,
3521     #   801, 821, 823, 860.
3522     # gcc 3.0 adds 630, rs64a.
3523     # gcc 3.1 adds 405, 7400, 7450.
3524     # gcc 3.2 adds nothing.
3525     # gcc 3.3 adds power3, power4, 8540.  power3 seems to be a synonym for 630.
3526     # gcc pre-release 3.4 adds 405fp, 440, 440fp, 970.
3527     #
3528     # FIXME: The way 603e falls back to 603 for gcc 2.7.2 should be
3529     # done for all the others too.  But what would be the correct
3530     # arrangements?
3531     #
3532     case $host_cpu in
3533       powerpc401)   gcc_cflags_cpu="-mcpu=401" ;;
3534       powerpc403)   gcc_cflags_cpu="-mcpu=403" ;;
3535       powerpc405)   gcc_cflags_cpu="-mcpu=405" ;;
3536       powerpc505)   gcc_cflags_cpu="-mcpu=505" ;;
3537       powerpc601)   gcc_cflags_cpu="-mcpu=601" ;;
3538       powerpc602)   gcc_cflags_cpu="-mcpu=602" ;;
3539       powerpc603)   gcc_cflags_cpu="-mcpu=603" ;;
3540       powerpc603e)  gcc_cflags_cpu="-mcpu=603e -mcpu=603" ;;
3541       powerpc604)   gcc_cflags_cpu="-mcpu=604" ;;
3542       powerpc604e)  gcc_cflags_cpu="-mcpu=604e -mcpu=604" ;;
3543       powerpc620)   gcc_cflags_cpu="-mcpu=620" ;;
3544       powerpc630)   gcc_cflags_cpu="-mcpu=630" ;;
3545       powerpc740)   gcc_cflags_cpu="-mcpu=740" ;;
3546       powerpc7400 | powerpc7410)
3547                     gcc_cflags_asm="-Wa,-maltivec"
3548                     gcc_cflags_cpu="-mcpu=7400 -mcpu=750" ;;
3549       powerpc74[45]?)
3550                     gcc_cflags_asm="-Wa,-maltivec"
3551                     gcc_cflags_cpu="-mcpu=7450" ;;
3552       powerpc750)   gcc_cflags_cpu="-mcpu=750" ;;
3553       powerpc801)   gcc_cflags_cpu="-mcpu=801" ;;
3554       powerpc821)   gcc_cflags_cpu="-mcpu=821" ;;
3555       powerpc823)   gcc_cflags_cpu="-mcpu=823" ;;
3556       powerpc860)   gcc_cflags_cpu="-mcpu=860" ;;
3557       powerpc970)   gcc_cflags_cpu="-mcpu=970" ;;
3558     esac
3559
3560     case $host in
3561       *-*-aix*)
3562         cclist="gcc xlc cc"
3563         xlc_cflags="-O2 -qmaxmem=20000"
3564         xlc_cflags_optlist="arch"
3565
3566         # xlc (what version?) knows -qarch=ppc, ppcgr, 601, 602, 603, 604,
3567         # 403, rs64a
3568         # -qarch=ppc is needed, so ensure everything falls back to that.
3569         # FIXME: Perhaps newer versions know more flavours.
3570         #
3571         case $host_cpu in
3572           powerpc403)   xlc_cflags_arch="-qarch=403 -qarch=ppc" ;;
3573           powerpc601)   xlc_cflags_arch="-qarch=601 -qarch=ppc" ;;
3574           powerpc602)   xlc_cflags_arch="-qarch=602 -qarch=ppc" ;;
3575           powerpc603)   xlc_cflags_arch="-qarch=603 -qarch=ppc" ;;
3576           powerpc603e)  xlc_cflags_arch="-qarch=603 -qarch=ppc" ;;
3577           powerpc604)   xlc_cflags_arch="-qarch=604 -qarch=ppc" ;;
3578           powerpc604e)  xlc_cflags_arch="-qarch=604 -qarch=ppc" ;;
3579           *)            xlc_cflags_arch="-qarch=ppc" ;;
3580         esac
3581         ;;
3582     esac
3583
3584     case $host in
3585       powerpc64-*-* | powerpc64le-*-* | powerpc620-*-* | powerpc630-*-* | powerpc970-*-* | power[3-9]-*-*)
3586         case $host_cpu in
3587           powerpc970)           vmx_path="powerpc64/vmx" ;;
3588           *)                    vmx_path="" ;;
3589         esac
3590         case $host in
3591           *-*-aix*)
3592             # On AIX a true 64-bit ABI is available.
3593             # Need -Wc to pass object type flags through to the linker.
3594             abilist="aix64 $abilist"
3595             cclist_aix64="gcc xlc"
3596             gcc_aix64_cflags="-O2 -maix64 -mpowerpc64"
3597             gcc_aix64_cflags_optlist="cpu"
3598             gcc_aix64_ldflags="-Wc,-maix64"
3599             xlc_aix64_cflags="-O2 -q64 -qtune=pwr3 -qmaxmem=20000"
3600             xlc_aix64_ldflags="-Wc,-q64"
3601             # Must indicate object type to ar and nm
3602             ar_aix64_flags="-X64"
3603             nm_aix64_flags="-X64"
3604             path_aix64="powerpc64/mode64 $vmx_path powerpc64"
3605             # grab this object, though it's not a true cycle counter routine
3606             SPEED_CYCLECOUNTER_OBJ_aix64=powerpc64.lo
3607             cyclecounter_size_aix64=0
3608             ;;
3609           *-*-darwin*)
3610             # On Darwin we can use 64-bit instructions with a longlong limb,
3611             # but the chip still in 32-bit mode.
3612             # In theory this can be used on any OS which knows how to save
3613             # 64-bit registers in a context switch.
3614             #
3615             # Note that we must use -mpowerpc64 with gcc, since the
3616             # longlong.h macros expect limb operands in a single 64-bit
3617             # register, not two 32-bit registers as would be given for a
3618             # long long without -mpowerpc64.  In theory we could detect and
3619             # accomodate both styles, but the proper 64-bit registers will
3620             # be fastest and are what we really want to use.
3621             #
3622             # One would think -mpowerpc64 would set the assembler in the right
3623             # mode to handle 64-bit instructions.  But for that, also
3624             # -force_cpusubtype_ALL is needed.
3625             #
3626             # Do not use -fast for Darwin, it actually adds options
3627             # incompatible with a shared library.
3628             #
3629             abilist="mode64 mode32 $abilist"
3630             gcc_cflags_opt="-O3 -O2 -O1"        # will this become used?
3631             cclist_mode32="gcc"
3632             gcc_mode32_cflags="-mpowerpc64"
3633             gcc_mode32_cflags_optlist="subtype cpu opt"
3634             gcc_mode32_cflags_subtype="-force_cpusubtype_ALL"
3635             gcc_mode32_cflags_opt="-O3 -O2 -O1"
3636             path_mode32="powerpc64/mode32 $vmx_path powerpc64"
3637             limb_mode32=longlong
3638             cclist_mode64="gcc"
3639             gcc_mode64_cflags="-m64"
3640             gcc_mode64_cflags_optlist="cpu opt"
3641             gcc_mode64_cflags_opt="-O3 -O2 -O1"
3642             path_mode64="powerpc64/mode64 $vmx_path powerpc64"
3643             SPEED_CYCLECOUNTER_OBJ_mode64=powerpc64.lo
3644             cyclecounter_size_mode64=0
3645             any_mode64_testlist="sizeof-long-8"
3646             ;;
3647           *-*-linux* | *-*-*bsd*)
3648             # On GNU/Linux, assume the processor is in 64-bit mode.  Some
3649             # environments have a gcc that is always in 64-bit mode, while
3650             # others require -m64, hence the use of cflags_maybe.  The
3651             # sizeof-long-8 test checks the mode is right (for the no option
3652             # case).
3653             #
3654             # -mpowerpc64 is not used, since it should be the default in
3655             # 64-bit mode.  (We need its effect for the various longlong.h
3656             # asm macros to be right of course.)
3657             #
3658             # gcc64 was an early port of gcc to 64-bit mode, but should be
3659             # obsolete before too long.  We prefer plain gcc when it knows
3660             # 64-bits.
3661             #
3662             abilist="mode64 mode32 $abilist"
3663             cclist_mode32="gcc"
3664             gcc_mode32_cflags="-mpowerpc64"
3665             gcc_mode32_cflags_optlist="cpu opt"
3666             gcc_mode32_cflags_opt="-O3 -O2 -O1"
3667             path_mode32="powerpc64/mode32 $vmx_path powerpc64"
3668             limb_mode32=longlong
3669             cclist_mode64="gcc gcc64"
3670             gcc_mode64_cflags_maybe="-m64"
3671             gcc_mode64_cflags_optlist="cpu opt"
3672             gcc_mode64_cflags_opt="-O3 -O2 -O1"
3673             path_mode64="powerpc64/mode64 $vmx_path powerpc64"
3674             SPEED_CYCLECOUNTER_OBJ_mode64=powerpc64.lo
3675             cyclecounter_size_mode64=0
3676             any_mode64_testlist="sizeof-long-8"
3677             ;;
3678         esac
3679         ;;
3680     esac
3681     ;;
3682
3683
3684   # POWER
3685   power-*-* | power[12]-*-* | power2sc-*-*)
3686     cat >>confdefs.h <<\_ACEOF
3687 #define HAVE_HOST_CPU_FAMILY_power 1
3688 _ACEOF
3689
3690     HAVE_HOST_CPU_FAMILY_power=1
3691     cclist="gcc"
3692     extra_functions="udiv_w_sdiv"
3693     path="power"
3694
3695     # gcc 2.7.2 knows rios1, rios2, rsc
3696     #
3697     # -mcpu=rios2 can tickle an AIX assembler bug (see GMP_PROG_CC_WORKS) so
3698     # there needs to be a fallback to just -mpower.
3699     #
3700     gcc_cflags_optlist="cpu"
3701     case $host in
3702       power-*-*)    gcc_cflags_cpu="-mcpu=power -mpower" ;;
3703       power1-*-*)   gcc_cflags_cpu="-mcpu=rios1 -mpower" ;;
3704       power2-*-*)   gcc_cflags_cpu="-mcpu=rios2 -mpower" ;;
3705       power2sc-*-*) gcc_cflags_cpu="-mcpu=rsc   -mpower" ;;
3706     esac
3707     case $host in
3708     *-*-aix*)
3709       cclist="gcc xlc"
3710       xlc_cflags="-O2 -qarch=pwr -qmaxmem=20000"
3711       ;;
3712     esac
3713     ;;
3714
3715
3716   pyramid-*-*)
3717     path="pyr"
3718     ;;
3719
3720
3721   # IBM s/370 and similar
3722   s3[6-9]0*-*-*)
3723     gcc_cflags="$gcc_cflags $fomit_frame_pointer"
3724     path="s390"
3725     extra_functions="udiv_w_sdiv"
3726     ;;
3727
3728
3729   sh-*-*)   path="sh" ;;
3730   sh2-*-*)  path="sh/sh2 sh" ;;
3731
3732
3733   *sparc*-*-*)
3734     # sizeof(long)==4 or 8 is tested, to ensure we get the right ABI.  We've
3735     # had various bug reports where users have set CFLAGS for their desired
3736     # mode, but not set our ABI.  For some reason it's sparc where this
3737     # keeps coming up, presumably users there are accustomed to driving the
3738     # compiler mode that way.  The effect of our testlist setting is to
3739     # reject ABI=64 in favour of ABI=32 if the user has forced the flags to
3740     # 32-bit mode.
3741     #
3742     abilist="32"
3743     cclist="gcc acc cc"
3744     any_testlist="sizeof-long-4"
3745
3746 echo "include_mpn(\`sparc32/sparc-defs.m4')" >> $gmp_tmpconfigm4i
3747
3748
3749     case $host_cpu in
3750       sparcv8 | microsparc | turbosparc)
3751         path="sparc32/v8 sparc32" ;;
3752       supersparc)
3753         path="sparc32/v8/supersparc sparc32/v8 sparc32" ;;
3754       sparc64 | sparcv9* | ultrasparc*)
3755         path="sparc32/v9 sparc32/v8 sparc32" ;;
3756       *)
3757         path="sparc32" ;;
3758     esac
3759
3760     # gcc 2.7.2 doesn't know about v9 and doesn't pass -xarch=v8plus to the
3761     # assembler.  Add it explicitly since the solaris assembler won't accept
3762     # our sparc32/v9 asm code without it.  gas accepts -xarch=v8plus too, so
3763     # it can be in the cflags unconditionally (though gas doesn't need it).
3764     #
3765     # gcc -m32 is needed to force 32-bit mode on a dual-ABI system, but past
3766     # gcc doesn't know that flag, hence cflags_maybe.  Note that -m32 cannot
3767     # be done through the optlist since the plain cflags would be run first
3768     # and we don't want to require the default mode (whatever it is) works.
3769     #
3770     # Note it's gcc_32_cflags_maybe and not gcc_cflags_maybe because the
3771     # latter would be used in the 64-bit ABI on systems like "*bsd" where
3772     # abilist="64" only.
3773     #
3774     case $host_cpu in
3775       sparc64 | sparcv9* | ultrasparc*)
3776         gcc_cflags="$gcc_cflags -Wa,-xarch=v8plus" ;;
3777       *)
3778         gcc_cflags="$gcc_cflags" ;;
3779     esac
3780     gcc_32_cflags_maybe="-m32"
3781     gcc_cflags_optlist="cpu"
3782
3783     # gcc 2.7.2 knows -mcypress, -msupersparc, -mv8, -msparclite.
3784     # gcc 2.95 knows -mcpu= v7, hypersparc, sparclite86x, f930, f934,
3785     #   sparclet, tsc701, v9, ultrasparc.  A warning is given that the
3786     #   plain -m forms will disappear.
3787     # gcc 3.0 adds nothing.
3788     # gcc 3.1 adds nothing.
3789     # gcc 3.2 adds nothing.
3790     # gcc 3.3 adds ultrasparc3.
3791     #
3792     case $host_cpu in
3793       supersparc)           gcc_cflags_cpu="-mcpu=supersparc -msupersparc" ;;
3794       sparcv8 | microsparc | turbosparc)
3795                             gcc_cflags_cpu="-mcpu=v8 -mv8" ;;
3796       sparc64 | sparcv9*)   gcc_cflags_cpu="-mcpu=v9 -mv8" ;;
3797       ultrasparc3)          gcc_cflags_cpu="-mcpu=ultrasparc3 -mcpu=ultrasparc -mv8" ;;
3798       ultrasparc*)          gcc_cflags_cpu="-mcpu=ultrasparc -mv8" ;;
3799       *)                    gcc_cflags_cpu="-mcpu=v7 -mcypress" ;;
3800     esac
3801
3802     # SunPRO cc and acc, and SunOS bundled cc
3803     case $host in
3804       *-*-solaris* | *-*-sunos*)
3805         # Note no -g, it disables all optimizations.
3806         cc_cflags=
3807         cc_cflags_optlist="opt arch cpu"
3808
3809         # SunOS cc doesn't know -xO4, fallback to -O2.
3810         cc_cflags_opt="-xO4 -O2"
3811
3812         # SunOS cc doesn't know -xarch, apparently always generating v7
3813         # code, so make this optional
3814         case $host_cpu in
3815           sparcv8 | microsparc | supersparc | turbosparc)
3816                                               cc_cflags_arch="-xarch=v8" ;;
3817           sparc64 | sparcv9* | ultrasparc*)   cc_cflags_arch="-xarch=v8plus" ;;
3818           *)                                  cc_cflags_arch="-xarch=v7" ;;
3819         esac
3820
3821         # SunOS cc doesn't know -xchip and doesn't seem to have an equivalent.
3822         # SunPRO cc 5 recognises -xchip=generic, old, super, super2, micro,
3823         #   micro2, hyper, hyper2, powerup, ultra, ultra2, ultra2i.
3824         # SunPRO cc 6 adds -xchip=ultra2e, ultra3cu.
3825         #
3826         # FIXME: Which of ultra, ultra2 or ultra2i is the best fallback for
3827         # ultrasparc3?
3828         #
3829         case $host_cpu in
3830           supersparc)   cc_cflags_cpu="-xchip=super" ;;
3831           microsparc)   cc_cflags_cpu="-xchip=micro" ;;
3832           turbosparc)   cc_cflags_cpu="-xchip=micro2" ;;
3833           ultrasparc)   cc_cflags_cpu="-xchip=ultra" ;;
3834           ultrasparc2)  cc_cflags_cpu="-xchip=ultra2" ;;
3835           ultrasparc2i) cc_cflags_cpu="-xchip=ultra2i" ;;
3836           ultrasparc3)  cc_cflags_cpu="-xchip=ultra3 -xchip=ultra" ;;
3837           *)            cc_cflags_cpu="-xchip=generic" ;;
3838         esac
3839     esac
3840
3841     case $host_cpu in
3842       sparc64 | sparcv9* | ultrasparc*)
3843         case $host in
3844           # Solaris 6 and earlier cannot run ABI=64 since it doesn't save
3845           # registers properly, so ABI=32 is left as the only choice.
3846           #
3847           *-*-solaris2.[0-6] | *-*-solaris2.[0-6].*) ;;
3848
3849           # BSD sparc64 ports are 64-bit-only systems, so ABI=64 is the only
3850           # choice.  In fact they need no special compiler flags, gcc -m64
3851           # is the default, but it doesn't hurt to add it.  v9 CPUs always
3852           # use the sparc64 port, since the plain 32-bit sparc ports don't
3853           # run on a v9.
3854           #
3855           *-*-*bsd*) abilist="64" ;;
3856
3857           # For all other systems, we try both 64 and 32.
3858           #
3859           # GNU/Linux sparc64 has only recently gained a 64-bit user mode.
3860           # In the past sparc64 meant a v9 cpu, but there were no 64-bit
3861           # operations in user mode.  We assume that if "gcc -m64" works
3862           # then the system is suitable.  Hopefully even if someone attempts
3863           # to put a new gcc and/or glibc on an old system it won't run.
3864           #
3865           *) abilist="64 32" ;;
3866         esac
3867
3868         path_64="sparc64"
3869         cclist_64="gcc"
3870         any_64_testlist="sizeof-long-8"
3871
3872         # gcc -mptr64 is probably implied by -m64, but we're not sure if
3873         # this was always so.  On Solaris in the past we always used both
3874         # "-m64 -mptr64".
3875         #
3876         # gcc -Wa,-xarch=v9 is thought to be necessary in some cases on
3877         # solaris, but it would seem likely that if gcc is going to generate
3878         # 64-bit code it will have to add that option itself where needed.
3879         # An extra copy of this option should be harmless though, but leave
3880         # it until we're sure.  (Might want -xarch=v9a or -xarch=v9b for the
3881         # higher cpu types instead.)
3882         #
3883         gcc_64_cflags="$gcc_64_cflags -m64 -mptr64"
3884         gcc_64_ldflags="-Wc,-m64"
3885         gcc_64_cflags_optlist="cpu"
3886
3887         case $host in
3888           *-*-solaris*)
3889             # Sun cc.
3890             #
3891             # We used to have -fast and some fixup options here, but it
3892             # recurrently caused problems with miscompilation.  Of course,
3893             # -fast is documented as miscompiling things for the sake of speed.
3894             #
3895             cclist_64="$cclist_64 cc"
3896             cc_64_cflags="-xO3 -xarch=v9"
3897             cc_64_cflags_optlist="cpu"
3898             ;;
3899         esac
3900
3901         # using the v9 %tick register
3902         SPEED_CYCLECOUNTER_OBJ_32=sparcv9.lo
3903         SPEED_CYCLECOUNTER_OBJ_64=sparcv9.lo
3904         cyclecounter_size_32=2
3905         cyclecounter_size_64=2
3906         ;;
3907     esac
3908     ;;
3909
3910
3911   # VAX
3912   vax*-*-*)
3913     # Currently gcc (version 3.0) on vax always uses a frame pointer
3914     # (config/vax/vax.h FRAME_POINTER_REQUIRED=1), so -fomit-frame-pointer
3915     # will be ignored.
3916     #
3917     gcc_cflags="$gcc_cflags $fomit_frame_pointer"
3918     path="vax"
3919     extra_functions="udiv_w_sdiv"
3920     ;;
3921
3922
3923   # AMD and Intel x86 configurations, including AMD64
3924   #
3925   # Rumour has it gcc -O2 used to give worse register allocation than just
3926   # -O, but lets assume that's no longer true.
3927   #
3928   # -m32 forces 32-bit mode on a bi-arch 32/64 amd64 build of gcc.  -m64 is
3929   # the default in such a build (we think), so -m32 is essential for ABI=32.
3930   # This is, of course, done for any $host_cpu, not just x86_64, so we can
3931   # get such a gcc into the right mode to cross-compile to say i486-*-*.
3932   #
3933   # -m32 is not available in gcc 2.95 and earlier, hence cflags_maybe to use
3934   # it when it works.  We check sizeof(long)==4 to ensure we get the right
3935   # mode, in case -m32 has failed not because it's an old gcc, but because
3936   # it's a dual 32/64-bit gcc without a 32-bit libc, or whatever.
3937   #
3938   i?86*-*-* | k[5-8]*-*-* | pentium*-*-* | athlon-*-* | viac3*-*-* | geode*-*-* | athlon64-*-* | atom-*-* | core2-*-* | x86_64-*-*)
3939     abilist="32"
3940     cclist="gcc icc cc"
3941     gcc_cflags="$gcc_cflags $fomit_frame_pointer"
3942     gcc_32_cflags_maybe="-m32"
3943     icc_cflags="-no-gcc"
3944     icc_cflags_optlist="opt"
3945     icc_cflags_opt="-O3 -O2 -O1"
3946     any_32_testlist="sizeof-long-4"
3947     CALLING_CONVENTIONS_OBJS='x86call.lo x86check$U.lo'
3948
3949     # Availability of rdtsc is checked at run-time.
3950     SPEED_CYCLECOUNTER_OBJ=pentium.lo
3951
3952     # gcc 2.7.2 only knows i386 and i486, using -m386 or -m486.  These
3953     #     represent -mcpu= since -m486 doesn't generate 486 specific insns.
3954     # gcc 2.95 adds k6, pentium and pentiumpro, and takes -march= and -mcpu=.
3955     # gcc 3.0 adds athlon.
3956     # gcc 3.1 adds k6-2, k6-3, pentium-mmx, pentium2, pentium3, pentium4,
3957     #     athlon-tbird, athlon-4, athlon-xp, athlon-mp.
3958     # gcc 3.2 adds winchip2.
3959     # gcc 3.3 adds winchip-c6.
3960     # gcc 3.3.1 from mandrake adds k8 and knows -mtune.
3961     # gcc 3.4 adds c3, c3-2, k8, and deprecates -mcpu in favour of -mtune.
3962     #
3963     # In gcc 2.95.[0123], -march=pentiumpro provoked a stack slot bug in an
3964     # old version of mpz/powm.c.  Seems to be fine with the current code, so
3965     # no need for any restrictions on that option.
3966     #
3967     # -march=pentiumpro can fail if the assembler doesn't know "cmov"
3968     # (eg. solaris 2.8 native "as"), so always have -march=pentium after
3969     # that as a fallback.
3970     #
3971     # -march=pentium4 and -march=k8 enable SSE2 instructions, which may or
3972     # may not be supported by the assembler and/or the OS, and is bad in gcc
3973     # prior to 3.3.  The tests will reject these if no good, so fallbacks
3974     # like "-march=pentium4 -mno-sse2" are given to try also without SSE2.
3975     # Note the relevant -march types are listed in the optflags handling
3976     # below, be sure to update there if adding new types emitting SSE2.
3977     #
3978     # -mtune is used at the start of each cpu option list to give something
3979     # gcc 3.4 will use, thereby avoiding warnings from -mcpu.  -mcpu forms
3980     # are retained for use by prior gcc.  For example pentium has
3981     # "-mtune=pentium -mcpu=pentium ...", the -mtune is for 3.4 and the
3982     # -mcpu for prior.  If there's a brand new choice in 3.4 for a chip,
3983     # like k8 for x86_64, then it can be the -mtune at the start, no need to
3984     # duplicate anything.
3985     #
3986     gcc_cflags_optlist="cpu arch"
3987     case $host_cpu in
3988       i386*)
3989         gcc_cflags_cpu="-mtune=i386 -mcpu=i386 -m386"
3990         gcc_cflags_arch="-march=i386"
3991         ;;
3992       i486*)
3993         gcc_cflags_cpu="-mtune=i486 -mcpu=i486 -m486"
3994         gcc_cflags_arch="-march=i486"
3995         ;;
3996       i586 | pentium)
3997         gcc_cflags_cpu="-mtune=pentium -mcpu=pentium -m486"
3998         gcc_cflags_arch="-march=pentium"
3999         ;;
4000       pentiummmx)
4001         gcc_cflags_cpu="-mtune=pentium-mmx -mcpu=pentium-mmx -mcpu=pentium -m486"
4002         gcc_cflags_arch="-march=pentium-mmx -march=pentium"
4003         ;;
4004       i686 | pentiumpro)
4005         gcc_cflags_cpu="-mtune=pentiumpro -mcpu=pentiumpro -mcpu=i486 -m486"
4006         gcc_cflags_arch="-march=pentiumpro -march=pentium"
4007         ;;
4008       pentium2)
4009         gcc_cflags_cpu="-mtune=pentium2 -mcpu=pentium2 -mcpu=pentiumpro -mcpu=i486 -m486"
4010         gcc_cflags_arch="-march=pentium2 -march=pentiumpro -march=pentium"
4011         ;;
4012       pentium3 | pentiumm)
4013         gcc_cflags_cpu="-mtune=pentium3 -mcpu=pentium3 -mcpu=pentiumpro -mcpu=i486 -m486"
4014         gcc_cflags_arch="-march=pentium3 -march=pentiumpro -march=pentium"
4015         ;;
4016       k6)
4017         gcc_cflags_cpu="-mtune=k6 -mcpu=k6 -mcpu=i486 -m486"
4018         gcc_cflags_arch="-march=k6"
4019         ;;
4020       k62)
4021         gcc_cflags_cpu="-mtune=k6-2 -mcpu=k6-2 -mcpu=k6 -mcpu=i486 -m486"
4022         gcc_cflags_arch="-march=k6-2 -march=k6"
4023         ;;
4024       k63)
4025         gcc_cflags_cpu="-mtune=k6-3 -mcpu=k6-3 -mcpu=k6 -mcpu=i486 -m486"
4026         gcc_cflags_arch="-march=k6-3 -march=k6"
4027         ;;
4028       geode)
4029         gcc_cflags_cpu="-mtune=k6-3 -mcpu=k6-3 -mcpu=k6 -mcpu=i486 -m486"
4030         gcc_cflags_arch="-march=k6-3 -march=k6"
4031         ;;
4032       athlon)
4033         # Athlon instruction costs are close to P6 (3 cycle load latency,
4034         # 4-6 cycle mul, 40 cycle div, pairable adc, etc) so if gcc doesn't
4035         # know athlon (eg. 2.95.2 doesn't) then fall back on pentiumpro.
4036         gcc_cflags_cpu="-mtune=athlon -mcpu=athlon -mcpu=pentiumpro -mcpu=i486 -m486"
4037         gcc_cflags_arch="-march=athlon -march=pentiumpro -march=pentium"
4038         ;;
4039       i786 | pentium4)
4040         # pentiumpro is the primary fallback when gcc doesn't know pentium4.
4041         # This gets us cmov to eliminate branches.  Maybe "athlon" would be
4042         # a possibility on gcc 3.0.
4043         #
4044         gcc_cflags_cpu="-mtune=pentium4 -mcpu=pentium4 -mcpu=pentiumpro -mcpu=i486 -m486"
4045         gcc_cflags_arch="-march=pentium4 -march=pentium4~-mno-sse2 -march=pentiumpro -march=pentium"
4046         ;;
4047       viac32)
4048         # Not sure of the best fallbacks here for -mcpu.
4049         # c3-2 has sse and mmx, so pentium3 is good for -march.
4050         gcc_cflags_cpu="-mtune=c3-2 -mcpu=c3-2 -mcpu=i486 -m486"
4051         gcc_cflags_arch="-march=c3-2 -march=pentium3 -march=pentiumpro -march=pentium"
4052         ;;
4053       viac3*)
4054         # Not sure of the best fallbacks here.
4055         gcc_cflags_cpu="-mtune=c3 -mcpu=c3 -mcpu=i486 -m486"
4056         gcc_cflags_arch="-march=c3 -march=pentium-mmx -march=pentium"
4057         ;;
4058       athlon64 | x86_64)
4059         gcc_cflags_cpu="-mtune=k8 -mcpu=athlon -mcpu=pentiumpro -mcpu=i486 -m486"
4060         gcc_cflags_arch="-march=k8 -march=k8~-mno-sse2 -march=athlon -march=pentiumpro -march=pentium"
4061         ;;
4062       core2)
4063         gcc_cflags_cpu="-mtune=core2 -mtune=k8"
4064         gcc_cflags_arch="-march=core2 -march=core2~-mno-sse2 -march=k8 -march=k8~-mno-sse2"
4065         ;;
4066       *)
4067         gcc_cflags_cpu="-mtune=i486 -mcpu=i486 -m486"
4068         gcc_cflags_arch="-march=i486"
4069         ;;
4070     esac
4071
4072     case $host_cpu in
4073       i386*)                path="x86" ;;
4074       i486*)                path="x86/i486 x86" ;;
4075       i586 | pentium)       path="x86/pentium x86" ;;
4076       pentiummmx)           path="x86/pentium/mmx x86/pentium x86" ;;
4077       i686 | pentiumpro)    path="x86/p6 x86" ;;
4078       pentium2)             path="x86/p6/mmx x86/p6 x86" ;;
4079       pentium3)             path="x86/p6/p3mmx x86/p6/mmx x86/p6 x86";;
4080       pentiumm | core2)     path="x86/p6/sse2 x86/p6/p3mmx x86/p6/mmx x86/p6 x86";;
4081       k6[23])             path="x86/k6/k62mmx x86/k6/mmx x86/k6 x86" ;;
4082       k6)                   path="x86/k6/mmx x86/k6 x86" ;;
4083       geode)                path="x86/k6/k62mmx x86/k6/mmx x86/k6 x86" ;;
4084       # we don't have any specific 32-bit code for athlon64/opteron, the
4085       # athlon code should be reasonable
4086       athlon | athlon64)    path="x86/k7/mmx x86/k7 x86" ;;
4087       i786 | pentium4)      path="x86/pentium4/sse2 x86/pentium4/mmx x86/pentium4 x86" ;;
4088       # VIA/Centaur processors, sold as CyrixIII and C3.
4089       viac32)               path="x86/p6/p3mmx x86/p6/mmx x86/p6 x86";;
4090       viac3*)               path="x86/pentium/mmx x86/pentium x86";;
4091       *)                    path="x86" ;;
4092     esac
4093
4094     # If the user asked for a fat build, override the path and flags set above
4095     if test $enable_fat = yes; then
4096       gcc_cflags_cpu=""
4097       gcc_cflags_arch=""
4098       extra_functions="$extra_functions fat fat_entry"
4099       path="x86/fat x86"
4100       fat_path="x86 x86/fat x86/i486
4101                 x86/k6 x86/k6/mmx x86/k6/k62mmx
4102                 x86/k7 x86/k7/mmx
4103                 x86/pentium x86/pentium/mmx
4104                 x86/p6 x86/p6/mmx x86/p6/p3mmx x86/p6/sse2
4105                 x86/pentium4 x86/pentium4/mmx x86/pentium4/sse2"
4106       fat_functions="add_n addmul_1 copyd copyi
4107                      dive_1 diveby3 divrem_1 gcd_1 lshift
4108                      mod_1 mod_34lsub1 mode1o mul_1 mul_basecase
4109                      pre_divrem_1 pre_mod_1 rshift
4110                      sqr_basecase sub_n submul_1"
4111       fat_thresholds="MUL_KARATSUBA_THRESHOLD MUL_TOOM3_THRESHOLD
4112                       SQR_KARATSUBA_THRESHOLD SQR_TOOM3_THRESHOLD"
4113     fi
4114
4115     case $host_cpu in
4116       athlon64 | atom | core2 | pentium4 | x86_64)
4117         cclist_64="gcc"
4118         gcc_64_cflags="$gcc_64_cflags -m64"
4119         gcc_64_cflags_optlist="cpu"
4120         CALLING_CONVENTIONS_OBJS_64='amd64call.lo amd64check$U.lo'
4121         SPEED_CYCLECOUNTER_OBJ_64=x86_64.lo
4122         cyclecounter_size_64=2
4123
4124         case $host in
4125           *-*-solaris*)
4126             # Sun cc.
4127             cclist_64="$cclist_64 cc"
4128             cc_64_cflags="-xO3 -m64"
4129             ;;
4130         esac
4131
4132         case $host_cpu in
4133           athlon64 | x86_64)
4134             abilist="64 32"
4135             path_64="x86_64"
4136             ;;
4137           pentium4)
4138             abilist="64 32"
4139             path_64="x86_64/pentium4 x86_64"
4140             ;;
4141           core2)
4142             abilist="64 32"
4143             path_64="x86_64/core2 x86_64"
4144             ;;
4145           atom)
4146             # The AMD K8/K9/K10 code seems best for Intel Atom
4147             abilist="64 32"
4148             path_64="x86_64/atom x86_64"
4149             ;;
4150         esac
4151         ;;
4152     esac
4153     ;;
4154
4155
4156   # FIXME: z8kx won't get through config.sub.  Could make 16 versus 32 bit
4157   # limb an ABI option perhaps.
4158   z8kx*-*-*)
4159     path="z8000x"
4160     extra_functions="udiv_w_sdiv"
4161     ;;
4162   z8k*-*-*)
4163     path="z8000"
4164     extra_functions="udiv_w_sdiv"
4165     ;;
4166
4167
4168   # Special CPU "none" selects generic C.  -DNO_ASM is used to disable gcc
4169   # asm blocks in longlong.h (since they're driven by cpp pre-defined
4170   # symbols like __alpha rather than the configured $host_cpu).
4171   #
4172   none-*-*)
4173     abilist="long longlong"
4174     cclist_long=$cclist
4175     gcc_long_cflags=$gcc_cflags
4176     gcc_long_cppflags="-DNO_ASM"
4177     cc_long_cflags=$cc_cflags
4178     cclist_longlong=$cclist
4179     gcc_longlong_cflags=$gcc_cflags
4180     gcc_longlong_cppflags="-DNO_ASM"
4181     cc_longlong_cflags=$cc_cflags
4182     limb_longlong=longlong
4183     ;;
4184
4185 esac
4186
4187 # mingw can be built by the cygwin gcc if -mno-cygwin is added.  For
4188 # convenience add this automatically if it works.  Actual mingw gcc accepts
4189 # -mno-cygwin too, but of course is the default.  mingw only runs on the
4190 # x86s, but allow any CPU here so as to catch "none" too.
4191 #
4192 case $host in
4193   *-*-mingw*)
4194     gcc_cflags_optlist="$gcc_cflags_optlist nocygwin"
4195     gcc_cflags_nocygwin="-mno-cygwin"
4196     ;;
4197 esac
4198
4199
4200 CFLAGS_or_unset=${CFLAGS-'(unset)'}
4201 CPPFLAGS_or_unset=${CPPFLAGS-'(unset)'}
4202
4203 cat >&5 <<EOF
4204 User:
4205 ABI=$ABI
4206 CC=$CC
4207 CFLAGS=$CFLAGS_or_unset
4208 CPPFLAGS=$CPPFLAGS_or_unset
4209 MPN_PATH=$MPN_PATH
4210 GMP:
4211 abilist=$abilist
4212 cclist=$cclist
4213 EOF
4214
4215
4216 test_CFLAGS=${CFLAGS+set}
4217 test_CPPFLAGS=${CPPFLAGS+set}
4218
4219 for abi in $abilist; do
4220   abi_last="$abi"
4221 done
4222
4223 # If the user specifies an ABI then it must be in $abilist, after that
4224 # $abilist is restricted to just that choice.
4225 #
4226 if test -n "$ABI"; then
4227   found=no
4228   for abi in $abilist; do
4229     if test $abi = "$ABI"; then found=yes; break; fi
4230   done
4231   if test $found = no; then
4232     { { echo "$as_me:$LINENO: error: ABI=$ABI is not among the following valid choices: $abilist" >&5
4233 echo "$as_me: error: ABI=$ABI is not among the following valid choices: $abilist" >&2;}
4234    { (exit 1); exit 1; }; }
4235   fi
4236   abilist="$ABI"
4237 fi
4238
4239 found_compiler=no
4240
4241 for abi in $abilist; do
4242
4243   echo "checking ABI=$abi"
4244
4245   # Suppose abilist="64 32", then for abi=64, will have abi1="_64" and
4246   # abi2="_64".  For abi=32, will have abi1="_32" and abi2="".  This is how
4247   # $gcc_cflags becomes a fallback for $gcc_32_cflags (the last in the
4248   # abilist), but there's no fallback for $gcc_64_cflags.
4249   #
4250   abi1=`echo _$abi | sed 's/[.]//g'`
4251   if test $abi = $abi_last; then abi2=; else abi2="$abi1"; fi
4252
4253   # Compiler choices under this ABI
4254                               eval cclist_chosen=\"\$cclist$abi1\"
4255   test -n "$cclist_chosen" || eval cclist_chosen=\"\$cclist$abi2\"
4256
4257   # If there's a user specified $CC then don't use a list for
4258   # $cclist_chosen, just a single value for $ccbase.
4259   #
4260   if test -n "$CC"; then
4261
4262     # The first word of $CC, stripped of any directory.  For instance
4263     # CC="/usr/local/bin/gcc -pipe" will give "gcc".
4264     #
4265     for ccbase in $CC; do break; done
4266     ccbase=`echo $ccbase | sed 's:.*/::'`
4267
4268     # If this $ccbase is in $cclist_chosen then it's a compiler we know and
4269     # we can do flags defaulting with it.  If not, then $cclist_chosen is
4270     # set to "unrecognised" so no default flags are used.
4271     #
4272     # "unrecognised" is used to avoid bad effects with eval if $ccbase has
4273     # non-symbol characters.  For instance ccbase=my+cc would end up with
4274     # something like cflags="$my+cc_cflags" which would give
4275     # cflags="+cc_cflags" rather than the intended empty string for an
4276     # unknown compiler.
4277     #
4278     found=unrecognised
4279     for i in $cclist_chosen; do
4280       if test "$ccbase" = $i; then
4281         found=$ccbase
4282         break
4283       fi
4284     done
4285     cclist_chosen=$found
4286   fi
4287
4288   for ccbase in $cclist_chosen; do
4289
4290     # When cross compiling, look for a compiler with the $host_alias as a
4291     # prefix, the same way that AC_CHECK_TOOL does.  But don't do this to a
4292     # user-selected $CC.
4293     #
4294     # $cross_compiling will be yes/no/maybe at this point.  Do the host
4295     # prefixing for "maybe" as well as "yes".
4296     #
4297     if test "$cross_compiling" != no && test -z "$CC"; then
4298       cross_compiling_prefix="${host_alias}-"
4299     fi
4300
4301     for ccprefix in $cross_compiling_prefix ""; do
4302
4303       cc="$CC"
4304       test -n "$cc" || cc="$ccprefix$ccbase"
4305
4306       # If the compiler is gcc but installed under another name, then change
4307       # $ccbase so as to use the flags we know for gcc.  This helps for
4308       # instance when specifying CC=gcc272 on Debian GNU/Linux, or the
4309       # native cc which is really gcc on NeXT or MacOS-X.
4310       #
4311       # FIXME: There's a slight misfeature here.  If cc is actually gcc but
4312       # gcc is not a known compiler under this $abi then we'll end up
4313       # testing it with no flags and it'll work, but chances are it won't be
4314       # in the right mode for the ABI we desire.  Let's quietly hope this
4315       # doesn't happen.
4316       #
4317       if test $ccbase != gcc; then
4318         cat >conftest.c <<EOF
4319 #if ! defined (__GNUC__) || defined (__INTEL_COMPILER)
4320   choke me
4321 #endif
4322 EOF
4323 gmp_compile="$cc -c conftest.c >&5"
4324 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
4325   (eval $gmp_compile) 2>&5
4326   ac_status=$?
4327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4328   (exit $ac_status); }; then
4329   rm -f conftest*
4330   { echo "$as_me:$LINENO: checking whether $cc is gcc" >&5
4331 echo $ECHO_N "checking whether $cc is gcc... $ECHO_C" >&6; }
4332   { echo "$as_me:$LINENO: result: yes" >&5
4333 echo "${ECHO_T}yes" >&6; }
4334   ccbase=gcc
4335 else
4336   rm -f conftest*
4337   :
4338 fi
4339
4340       fi
4341
4342       # Similarly if the compiler is IBM xlc but invoked as cc or whatever
4343       # then change $ccbase and make the default xlc flags available.
4344       if test $ccbase != xlc; then
4345         gmp_command="$cc 2>&1 | grep xlc >/dev/null"
4346 if { (eval echo "$as_me:$LINENO: \"$gmp_command\"") >&5
4347   (eval $gmp_command) 2>&5
4348   ac_status=$?
4349   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4350   (exit $ac_status); }; then
4351   { echo "$as_me:$LINENO: checking whether $cc is xlc" >&5
4352 echo $ECHO_N "checking whether $cc is xlc... $ECHO_C" >&6; }
4353   { echo "$as_me:$LINENO: result: yes" >&5
4354 echo "${ECHO_T}yes" >&6; }
4355   ccbase=xlc
4356 else
4357   :
4358 fi
4359
4360       fi
4361
4362       # acc was Sun's first unbundled compiler back in the SunOS days, or
4363       # something like that, but today its man page says it's not meant to
4364       # be used directly (instead via /usr/ucb/cc).  The options are pretty
4365       # much the same as the main SunPRO cc, so share those configs.
4366       #
4367       case $host in
4368         *sparc*-*-solaris* | *sparc*-*-sunos*)
4369           if test "$ccbase" = acc; then ccbase=cc; fi ;;
4370       esac
4371
4372       for tmp_cflags_maybe in yes no; do
4373                              eval cflags=\"\$${ccbase}${abi1}_cflags\"
4374         test -n "$cflags" || eval cflags=\"\$${ccbase}${abi2}_cflags\"
4375
4376         if test "$tmp_cflags_maybe" = yes; then
4377           # don't try cflags_maybe when the user set CFLAGS
4378           if test "$test_CFLAGS" = set; then continue; fi
4379                                      eval cflags_maybe=\"\$${ccbase}${abi1}_cflags_maybe\"
4380           test -n "$cflags_maybe" || eval cflags_maybe=\"\$${ccbase}${abi2}_cflags_maybe\"
4381           # don't try cflags_maybe if there's nothing set
4382           if test -z "$cflags_maybe"; then continue; fi
4383           cflags="$cflags_maybe $cflags"
4384         fi
4385
4386         # Any user CFLAGS, even an empty string, takes precendence
4387         if test "$test_CFLAGS" = set; then cflags=$CFLAGS; fi
4388
4389         # Any user CPPFLAGS, even an empty string, takes precendence
4390                                eval cppflags=\"\$${ccbase}${abi1}_cppflags\"
4391         test -n "$cppflags" || eval cppflags=\"\$${ccbase}${abi2}_cppflags\"
4392         if test "$test_CPPFLAGS" = set; then cppflags=$CPPFLAGS; fi
4393
4394         # --enable-profiling adds -p/-pg even to user-specified CFLAGS.
4395         # This is convenient, but it's perhaps a bit naughty to modify user
4396         # CFLAGS.
4397         case "$enable_profiling" in
4398           prof)       cflags="$cflags -p" ;;
4399           gprof)      cflags="$cflags -pg" ;;
4400           instrument) cflags="$cflags -finstrument-functions" ;;
4401         esac
4402
4403         { echo "$as_me:$LINENO: checking compiler $cc $cflags $cppflags" >&5
4404 echo $ECHO_N "checking compiler $cc $cflags $cppflags... $ECHO_C" >&6; }
4405 gmp_prog_cc_works=yes
4406
4407 # first see a simple "main()" works, then go on to other checks
4408 if test "$gmp_prog_cc_works" = yes; then
4409   # remove anything that might look like compiler output to our "||" expression
4410   rm -f conftest* a.out b.out a.exe a_out.exe
4411   cat >conftest.c <<EOF
4412
4413 int main () { return 0; }
4414 EOF
4415   echo "Test compile: " >&5
4416   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
4417   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
4418   (eval $gmp_compile) 2>&5
4419   ac_status=$?
4420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4421   (exit $ac_status); }; then
4422     cc_works_part=yes
4423     if test "$cross_compiling" = no; then
4424       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
4425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4426   (eval $ac_try) 2>&5
4427   ac_status=$?
4428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4429   (exit $ac_status); }; }; then :;
4430       else
4431         cc_works_part=norun
4432       fi
4433     fi
4434   else
4435     cc_works_part=no
4436   fi
4437   if test "$cc_works_part" != yes; then
4438     echo "failed program was:" >&5
4439     cat conftest.c >&5
4440   fi
4441   rm -f conftest* a.out b.out a.exe a_out.exe
4442   case $cc_works_part in
4443     yes)
4444
4445       ;;
4446     no)
4447       gmp_prog_cc_works="no"
4448       ;;
4449     norun)
4450       gmp_prog_cc_works="no, program does not run"
4451       ;;
4452   esac
4453 fi
4454
4455
4456
4457
4458 if test "$gmp_prog_cc_works" = yes; then
4459   # remove anything that might look like compiler output to our "||" expression
4460   rm -f conftest* a.out b.out a.exe a_out.exe
4461   cat >conftest.c <<EOF
4462 /* The following provokes an internal error from gcc 2.95.2 -mpowerpc64
4463    (without -maix64), hence detecting an unusable compiler */
4464 void *g() { return (void *) 0; }
4465 void *f() { return g(); }
4466
4467 int main () { return 0; }
4468 EOF
4469   echo "Test compile: function pointer return" >&5
4470   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
4471   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
4472   (eval $gmp_compile) 2>&5
4473   ac_status=$?
4474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4475   (exit $ac_status); }; then
4476     cc_works_part=yes
4477     if test "$cross_compiling" = no; then
4478       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
4479   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4480   (eval $ac_try) 2>&5
4481   ac_status=$?
4482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4483   (exit $ac_status); }; }; then :;
4484       else
4485         cc_works_part=norun
4486       fi
4487     fi
4488   else
4489     cc_works_part=no
4490   fi
4491   if test "$cc_works_part" != yes; then
4492     echo "failed program was:" >&5
4493     cat conftest.c >&5
4494   fi
4495   rm -f conftest* a.out b.out a.exe a_out.exe
4496   case $cc_works_part in
4497     yes)
4498
4499       ;;
4500     no)
4501       gmp_prog_cc_works="no, function pointer return"
4502       ;;
4503     norun)
4504       gmp_prog_cc_works="no, function pointer return, program does not run"
4505       ;;
4506   esac
4507 fi
4508
4509
4510
4511
4512 if test "$gmp_prog_cc_works" = yes; then
4513   # remove anything that might look like compiler output to our "||" expression
4514   rm -f conftest* a.out b.out a.exe a_out.exe
4515   cat >conftest.c <<EOF
4516 /* The following provokes an invalid instruction syntax from i386 gcc
4517    -march=pentiumpro on Solaris 2.8.  The native sun assembler
4518    requires a non-standard syntax for cmov which gcc (as of 2.95.2 at
4519    least) doesn't know.  */
4520 int n;
4521 int cmov () { return (n >= 0 ? n : 0); }
4522
4523 int main () { return 0; }
4524 EOF
4525   echo "Test compile: cmov instruction" >&5
4526   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
4527   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
4528   (eval $gmp_compile) 2>&5
4529   ac_status=$?
4530   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4531   (exit $ac_status); }; then
4532     cc_works_part=yes
4533     if test "$cross_compiling" = no; then
4534       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
4535   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4536   (eval $ac_try) 2>&5
4537   ac_status=$?
4538   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4539   (exit $ac_status); }; }; then :;
4540       else
4541         cc_works_part=norun
4542       fi
4543     fi
4544   else
4545     cc_works_part=no
4546   fi
4547   if test "$cc_works_part" != yes; then
4548     echo "failed program was:" >&5
4549     cat conftest.c >&5
4550   fi
4551   rm -f conftest* a.out b.out a.exe a_out.exe
4552   case $cc_works_part in
4553     yes)
4554
4555       ;;
4556     no)
4557       gmp_prog_cc_works="no, cmov instruction"
4558       ;;
4559     norun)
4560       gmp_prog_cc_works="no, cmov instruction, program does not run"
4561       ;;
4562   esac
4563 fi
4564
4565
4566
4567
4568 if test "$gmp_prog_cc_works" = yes; then
4569   # remove anything that might look like compiler output to our "||" expression
4570   rm -f conftest* a.out b.out a.exe a_out.exe
4571   cat >conftest.c <<EOF
4572 /* The following provokes a linker invocation problem with gcc 3.0.3
4573    on AIX 4.3 under "-maix64 -mpowerpc64 -mcpu=630".  The -mcpu=630
4574    option causes gcc to incorrectly select the 32-bit libgcc.a, not
4575    the 64-bit one, and consequently it misses out on the __fixunsdfdi
4576    helper (double -> uint64 conversion).  */
4577 double d;
4578 unsigned long gcc303 () { return (unsigned long) d; }
4579
4580 int main () { return 0; }
4581 EOF
4582   echo "Test compile: double -> ulong conversion" >&5
4583   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
4584   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
4585   (eval $gmp_compile) 2>&5
4586   ac_status=$?
4587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4588   (exit $ac_status); }; then
4589     cc_works_part=yes
4590     if test "$cross_compiling" = no; then
4591       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
4592   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4593   (eval $ac_try) 2>&5
4594   ac_status=$?
4595   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4596   (exit $ac_status); }; }; then :;
4597       else
4598         cc_works_part=norun
4599       fi
4600     fi
4601   else
4602     cc_works_part=no
4603   fi
4604   if test "$cc_works_part" != yes; then
4605     echo "failed program was:" >&5
4606     cat conftest.c >&5
4607   fi
4608   rm -f conftest* a.out b.out a.exe a_out.exe
4609   case $cc_works_part in
4610     yes)
4611
4612       ;;
4613     no)
4614       gmp_prog_cc_works="no, double -> ulong conversion"
4615       ;;
4616     norun)
4617       gmp_prog_cc_works="no, double -> ulong conversion, program does not run"
4618       ;;
4619   esac
4620 fi
4621
4622
4623
4624
4625 if test "$gmp_prog_cc_works" = yes; then
4626   # remove anything that might look like compiler output to our "||" expression
4627   rm -f conftest* a.out b.out a.exe a_out.exe
4628   cat >conftest.c <<EOF
4629 /* The following provokes an error from hppa gcc 2.95 under -mpa-risc-2-0 if
4630    the assembler doesn't know hppa 2.0 instructions.  fneg is a 2.0
4631    instruction, and a negation like this comes out using it.  */
4632 double fneg_data;
4633 unsigned long fneg () { return -fneg_data; }
4634
4635 int main () { return 0; }
4636 EOF
4637   echo "Test compile: double negation" >&5
4638   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
4639   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
4640   (eval $gmp_compile) 2>&5
4641   ac_status=$?
4642   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4643   (exit $ac_status); }; then
4644     cc_works_part=yes
4645     if test "$cross_compiling" = no; then
4646       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
4647   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4648   (eval $ac_try) 2>&5
4649   ac_status=$?
4650   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4651   (exit $ac_status); }; }; then :;
4652       else
4653         cc_works_part=norun
4654       fi
4655     fi
4656   else
4657     cc_works_part=no
4658   fi
4659   if test "$cc_works_part" != yes; then
4660     echo "failed program was:" >&5
4661     cat conftest.c >&5
4662   fi
4663   rm -f conftest* a.out b.out a.exe a_out.exe
4664   case $cc_works_part in
4665     yes)
4666
4667       ;;
4668     no)
4669       gmp_prog_cc_works="no, double negation"
4670       ;;
4671     norun)
4672       gmp_prog_cc_works="no, double negation, program does not run"
4673       ;;
4674   esac
4675 fi
4676
4677
4678
4679
4680 if test "$gmp_prog_cc_works" = yes; then
4681   # remove anything that might look like compiler output to our "||" expression
4682   rm -f conftest* a.out b.out a.exe a_out.exe
4683   cat >conftest.c <<EOF
4684 /* The following makes gcc 3.3 -march=pentium4 generate an SSE2 xmm insn
4685    (cvtsd2ss) which will provoke an error if the assembler doesn't recognise
4686    those instructions.  Not sure how much of the gmp code will come out
4687    wanting sse2, but it's easiest to reject an option we know is bad.  */
4688 double ftod_data;
4689 float ftod () { return (float) ftod_data; }
4690
4691 int main () { return 0; }
4692 EOF
4693   echo "Test compile: double -> float conversion" >&5
4694   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
4695   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
4696   (eval $gmp_compile) 2>&5
4697   ac_status=$?
4698   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4699   (exit $ac_status); }; then
4700     cc_works_part=yes
4701     if test "$cross_compiling" = no; then
4702       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
4703   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4704   (eval $ac_try) 2>&5
4705   ac_status=$?
4706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4707   (exit $ac_status); }; }; then :;
4708       else
4709         cc_works_part=norun
4710       fi
4711     fi
4712   else
4713     cc_works_part=no
4714   fi
4715   if test "$cc_works_part" != yes; then
4716     echo "failed program was:" >&5
4717     cat conftest.c >&5
4718   fi
4719   rm -f conftest* a.out b.out a.exe a_out.exe
4720   case $cc_works_part in
4721     yes)
4722
4723       ;;
4724     no)
4725       gmp_prog_cc_works="no, double -> float conversion"
4726       ;;
4727     norun)
4728       gmp_prog_cc_works="no, double -> float conversion, program does not run"
4729       ;;
4730   esac
4731 fi
4732
4733
4734
4735
4736 if test "$gmp_prog_cc_works" = yes; then
4737   # remove anything that might look like compiler output to our "||" expression
4738   rm -f conftest* a.out b.out a.exe a_out.exe
4739   cat >conftest.c <<EOF
4740 /* The following provokes an internal compiler error from gcc version
4741    "2.9-gnupro-99r1" under "-O2 -mcpu=ev6", apparently relating to char
4742    values being spilled into floating point registers.  The problem doesn't
4743    show up all the time, but has occurred enough in GMP for us to reject
4744    this compiler+flags.  */
4745 #include <string.h>  /* for memcpy */
4746 struct try_t
4747 {
4748  char dst[2];
4749  char size;
4750  long d0, d1, d2, d3, d4, d5, d6;
4751  char overlap;
4752 };
4753 struct try_t param[6];
4754 int
4755 param_init ()
4756 {
4757  struct try_t *p;
4758  memcpy (p, &param[ 2 ], sizeof (*p));
4759  memcpy (p, &param[ 2 ], sizeof (*p));
4760  p->size = 2;
4761  memcpy (p, &param[ 1 ], sizeof (*p));
4762  p->dst[0] = 1;
4763  p->overlap = 2;
4764  memcpy (p, &param[ 3 ], sizeof (*p));
4765  p->dst[0] = 1;
4766  p->overlap = 8;
4767  memcpy (p, &param[ 4 ], sizeof (*p));
4768  memcpy (p, &param[ 4 ], sizeof (*p));
4769  p->overlap = 8;
4770  memcpy (p, &param[ 5 ], sizeof (*p));
4771  memcpy (p, &param[ 5 ], sizeof (*p));
4772  memcpy (p, &param[ 5 ], sizeof (*p));
4773  return 0;
4774 }
4775
4776 int main () { return 0; }
4777 EOF
4778   echo "Test compile: gnupro alpha ev6 char spilling" >&5
4779   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
4780   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
4781   (eval $gmp_compile) 2>&5
4782   ac_status=$?
4783   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4784   (exit $ac_status); }; then
4785     cc_works_part=yes
4786     if test "$cross_compiling" = no; then
4787       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
4788   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4789   (eval $ac_try) 2>&5
4790   ac_status=$?
4791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4792   (exit $ac_status); }; }; then :;
4793       else
4794         cc_works_part=norun
4795       fi
4796     fi
4797   else
4798     cc_works_part=no
4799   fi
4800   if test "$cc_works_part" != yes; then
4801     echo "failed program was:" >&5
4802     cat conftest.c >&5
4803   fi
4804   rm -f conftest* a.out b.out a.exe a_out.exe
4805   case $cc_works_part in
4806     yes)
4807
4808       ;;
4809     no)
4810       gmp_prog_cc_works="no, gnupro alpha ev6 char spilling"
4811       ;;
4812     norun)
4813       gmp_prog_cc_works="no, gnupro alpha ev6 char spilling, program does not run"
4814       ;;
4815   esac
4816 fi
4817
4818
4819
4820
4821 # __builtin_alloca is not available everywhere, check it exists before
4822 # seeing that it works
4823 if test "$gmp_prog_cc_works" = yes; then
4824   # remove anything that might look like compiler output to our "||" expression
4825   rm -f conftest* a.out b.out a.exe a_out.exe
4826   cat >conftest.c <<EOF
4827 int k; int foo () { __builtin_alloca (k); }
4828 EOF
4829   echo "Test compile: __builtin_alloca availability" >&5
4830   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
4831   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
4832   (eval $gmp_compile) 2>&5
4833   ac_status=$?
4834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4835   (exit $ac_status); }; then
4836     cc_works_part=yes
4837     if test "$cross_compiling" = no; then
4838       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
4839   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4840   (eval $ac_try) 2>&5
4841   ac_status=$?
4842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4843   (exit $ac_status); }; }; then :;
4844       else
4845         cc_works_part=norun
4846       fi
4847     fi
4848   else
4849     cc_works_part=no
4850   fi
4851   if test "$cc_works_part" != yes; then
4852     echo "failed program was:" >&5
4853     cat conftest.c >&5
4854   fi
4855   rm -f conftest* a.out b.out a.exe a_out.exe
4856   case $cc_works_part in
4857     yes)
4858       if test "$gmp_prog_cc_works" = yes; then
4859   # remove anything that might look like compiler output to our "||" expression
4860   rm -f conftest* a.out b.out a.exe a_out.exe
4861   cat >conftest.c <<EOF
4862 /* The following provokes an internal compiler error from Itanium HP-UX cc
4863     under +O2 or higher.  We use this sort of code in mpn/generic/mul_fft.c. */
4864 int k;
4865 int foo ()
4866 {
4867   int i, **a;
4868   a = __builtin_alloca (k);
4869   for (i = 0; i <= k; i++)
4870     a[i] = __builtin_alloca (1 << i);
4871 }
4872
4873 int main () { return 0; }
4874 EOF
4875   echo "Test compile: alloca array" >&5
4876   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
4877   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
4878   (eval $gmp_compile) 2>&5
4879   ac_status=$?
4880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4881   (exit $ac_status); }; then
4882     cc_works_part=yes
4883     if test "$cross_compiling" = no; then
4884       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
4885   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4886   (eval $ac_try) 2>&5
4887   ac_status=$?
4888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4889   (exit $ac_status); }; }; then :;
4890       else
4891         cc_works_part=norun
4892       fi
4893     fi
4894   else
4895     cc_works_part=no
4896   fi
4897   if test "$cc_works_part" != yes; then
4898     echo "failed program was:" >&5
4899     cat conftest.c >&5
4900   fi
4901   rm -f conftest* a.out b.out a.exe a_out.exe
4902   case $cc_works_part in
4903     yes)
4904
4905       ;;
4906     no)
4907       gmp_prog_cc_works="no, alloca array"
4908       ;;
4909     norun)
4910       gmp_prog_cc_works="no, alloca array, program does not run"
4911       ;;
4912   esac
4913 fi
4914
4915
4916
4917       ;;
4918     no)
4919
4920       ;;
4921     norun)
4922
4923       ;;
4924   esac
4925 fi
4926
4927
4928 if test "$gmp_prog_cc_works" = yes; then
4929   # remove anything that might look like compiler output to our "||" expression
4930   rm -f conftest* a.out b.out a.exe a_out.exe
4931   cat >conftest.c <<EOF
4932 /* The following provokes an internal error from the assembler on
4933    power2-ibm-aix4.3.1.0.  gcc -mrios2 compiles to nabs+fcirz, and this
4934    results in "Internal error related to the source program domain".
4935
4936    For reference it seems to be the combination of nabs+fcirz which is bad,
4937    not either alone.  This sort of thing occurs in mpz/get_str.c with the
4938    way double chars_per_bit_exactly is applied in MPN_SIZEINBASE.  Perhaps
4939    if that code changes to a scaled-integer style then we won't need this
4940    test.  */
4941
4942 double fp[1];
4943 int x;
4944 int f ()
4945 {
4946   int a;
4947   a = (x >= 0 ? x : -x);
4948   return a * fp[0];
4949 }
4950
4951 int main () { return 0; }
4952 EOF
4953   echo "Test compile: abs int -> double conversion" >&5
4954   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
4955   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
4956   (eval $gmp_compile) 2>&5
4957   ac_status=$?
4958   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4959   (exit $ac_status); }; then
4960     cc_works_part=yes
4961     if test "$cross_compiling" = no; then
4962       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
4963   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4964   (eval $ac_try) 2>&5
4965   ac_status=$?
4966   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4967   (exit $ac_status); }; }; then :;
4968       else
4969         cc_works_part=norun
4970       fi
4971     fi
4972   else
4973     cc_works_part=no
4974   fi
4975   if test "$cc_works_part" != yes; then
4976     echo "failed program was:" >&5
4977     cat conftest.c >&5
4978   fi
4979   rm -f conftest* a.out b.out a.exe a_out.exe
4980   case $cc_works_part in
4981     yes)
4982
4983       ;;
4984     no)
4985       gmp_prog_cc_works="no, abs int -> double conversion"
4986       ;;
4987     norun)
4988       gmp_prog_cc_works="no, abs int -> double conversion, program does not run"
4989       ;;
4990   esac
4991 fi
4992
4993
4994
4995
4996 if test "$gmp_prog_cc_works" = yes; then
4997   # remove anything that might look like compiler output to our "||" expression
4998   rm -f conftest* a.out b.out a.exe a_out.exe
4999   cat >conftest.c <<EOF
5000 /* The following provokes a segfault in the compiler on powerpc-apple-darwin.
5001    Extracted from tests/mpn/t-iord_u.c.  Causes Apple's gcc 3.3 build 1640 and
5002    1666 to segfault with e.g., -O2 -mpowerpc64.  */
5003
5004 #if defined (__GNUC__) && ! defined (__cplusplus)
5005 typedef unsigned long long t1;typedef t1*t2;
5006 static __inline__ t1 e(t2 rp,t2 up,int n,t1 v0)
5007 {t1 c,x,r;int i;if(v0){c=1;for(i=1;i<n;i++){x=up[i];r=x+1;rp[i]=r;}}return c;}
5008 f(){static const struct{t1 n;t1 src[9];t1 want[9];}d[]={{1,{0},{1}},};t1 got[9];int i;
5009 for(i=0;i<1;i++){if(e(got,got,9,d[i].n)==0)h();g(i,d[i].src,d[i].n,got,d[i].want,9);if(d[i].n)h();}}
5010 h(){}g(){}
5011 #else
5012 int dummy;
5013 #endif
5014
5015 int main () { return 0; }
5016 EOF
5017   echo "Test compile: long long reliability test 1" >&5
5018   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
5019   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5020   (eval $gmp_compile) 2>&5
5021   ac_status=$?
5022   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5023   (exit $ac_status); }; then
5024     cc_works_part=yes
5025     if test "$cross_compiling" = no; then
5026       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
5027   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5028   (eval $ac_try) 2>&5
5029   ac_status=$?
5030   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5031   (exit $ac_status); }; }; then :;
5032       else
5033         cc_works_part=norun
5034       fi
5035     fi
5036   else
5037     cc_works_part=no
5038   fi
5039   if test "$cc_works_part" != yes; then
5040     echo "failed program was:" >&5
5041     cat conftest.c >&5
5042   fi
5043   rm -f conftest* a.out b.out a.exe a_out.exe
5044   case $cc_works_part in
5045     yes)
5046
5047       ;;
5048     no)
5049       gmp_prog_cc_works="no, long long reliability test 1"
5050       ;;
5051     norun)
5052       gmp_prog_cc_works="no, long long reliability test 1, program does not run"
5053       ;;
5054   esac
5055 fi
5056
5057
5058
5059
5060 if test "$gmp_prog_cc_works" = yes; then
5061   # remove anything that might look like compiler output to our "||" expression
5062   rm -f conftest* a.out b.out a.exe a_out.exe
5063   cat >conftest.c <<EOF
5064 /* The following provokes an internal compiler error on powerpc-apple-darwin.
5065    Extracted from mpz/cfdiv_q_2exp.c.  Causes Apple's gcc 3.3 build 1640 and
5066    1666 to get an ICE with -O1 -mpowerpc64.  */
5067
5068 #if defined (__GNUC__) && ! defined (__cplusplus)
5069 f(int u){int i;long long x;x=u?~0:0;if(x)for(i=0;i<9;i++);x&=g();if(x)g();}
5070 g(){}
5071 #else
5072 int dummy;
5073 #endif
5074
5075 int main () { return 0; }
5076 EOF
5077   echo "Test compile: long long reliability test 2" >&5
5078   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
5079   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5080   (eval $gmp_compile) 2>&5
5081   ac_status=$?
5082   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5083   (exit $ac_status); }; then
5084     cc_works_part=yes
5085     if test "$cross_compiling" = no; then
5086       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
5087   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5088   (eval $ac_try) 2>&5
5089   ac_status=$?
5090   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5091   (exit $ac_status); }; }; then :;
5092       else
5093         cc_works_part=norun
5094       fi
5095     fi
5096   else
5097     cc_works_part=no
5098   fi
5099   if test "$cc_works_part" != yes; then
5100     echo "failed program was:" >&5
5101     cat conftest.c >&5
5102   fi
5103   rm -f conftest* a.out b.out a.exe a_out.exe
5104   case $cc_works_part in
5105     yes)
5106
5107       ;;
5108     no)
5109       gmp_prog_cc_works="no, long long reliability test 2"
5110       ;;
5111     norun)
5112       gmp_prog_cc_works="no, long long reliability test 2, program does not run"
5113       ;;
5114   esac
5115 fi
5116
5117
5118
5119
5120 if test "$gmp_prog_cc_works" = yes; then
5121   # remove anything that might look like compiler output to our "||" expression
5122   rm -f conftest* a.out b.out a.exe a_out.exe
5123   cat >conftest.c <<EOF
5124 /* The following is mis-compiled by HP ia-64 cc version
5125         cc: HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]
5126    under "cc +O3", both in +DD32 and +DD64 modes.  The mpn_lshift_com gets
5127    inlined and its return value somehow botched to be 0 instead of 1.  This
5128    arises in the real mpn_lshift_com in mul_fft.c.  A lower optimization
5129    level, like +O2 seems ok.  This code needs to be run to show the problem,
5130    but that's fine, the offending cc is a native-only compiler so we don't
5131    have to worry about cross compiling.  */
5132
5133 #if ! defined (__cplusplus)
5134 unsigned long
5135 lshift_com (rp, up, n, cnt)
5136   unsigned long *rp;
5137   unsigned long *up;
5138   long n;
5139   unsigned cnt;
5140 {
5141   unsigned long retval, high_limb, low_limb;
5142   unsigned tnc;
5143   long i;
5144   tnc = 8 * sizeof (unsigned long) - cnt;
5145   low_limb = *up++;
5146   retval = low_limb >> tnc;
5147   high_limb = low_limb << cnt;
5148   for (i = n - 1; i != 0; i--)
5149     {
5150       low_limb = *up++;
5151       *rp++ = ~(high_limb | (low_limb >> tnc));
5152       high_limb = low_limb << cnt;
5153     }
5154   return retval;
5155 }
5156 int
5157 main ()
5158 {
5159   unsigned long cy, rp[2], up[2];
5160   up[0] = ~ 0L;
5161   up[1] = 0;
5162   cy = lshift_com (rp, up, 2L, 1);
5163   if (cy != 1L)
5164     return 1;
5165   return 0;
5166 }
5167 #else
5168 int
5169 main ()
5170 {
5171   return 0;
5172 }
5173 #endif
5174
5175 EOF
5176   echo "Test compile: mpn_lshift_com optimization" >&5
5177   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
5178   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5179   (eval $gmp_compile) 2>&5
5180   ac_status=$?
5181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5182   (exit $ac_status); }; then
5183     cc_works_part=yes
5184     if test "$cross_compiling" = no; then
5185       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
5186   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5187   (eval $ac_try) 2>&5
5188   ac_status=$?
5189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5190   (exit $ac_status); }; }; then :;
5191       else
5192         cc_works_part=norun
5193       fi
5194     fi
5195   else
5196     cc_works_part=no
5197   fi
5198   if test "$cc_works_part" != yes; then
5199     echo "failed program was:" >&5
5200     cat conftest.c >&5
5201   fi
5202   rm -f conftest* a.out b.out a.exe a_out.exe
5203   case $cc_works_part in
5204     yes)
5205
5206       ;;
5207     no)
5208       gmp_prog_cc_works="no, mpn_lshift_com optimization"
5209       ;;
5210     norun)
5211       gmp_prog_cc_works="no, mpn_lshift_com optimization, program does not run"
5212       ;;
5213   esac
5214 fi
5215
5216
5217
5218 if test "$gmp_prog_cc_works" = yes; then
5219   # remove anything that might look like compiler output to our "||" expression
5220   rm -f conftest* a.out b.out a.exe a_out.exe
5221   cat >conftest.c <<EOF
5222 /* The following is mis-compiled by Intel ia-64 icc version 1.8 under
5223     "icc -O3",  After several calls, the function writes parial garbage to
5224     the result vector.  Perhaps relates to the chk.a.nc insn.  This code needs
5225     to be run to show the problem, but that's fine, the offending cc is a
5226     native-only compiler so we don't have to worry about cross compiling.  */
5227
5228 #if ! defined (__cplusplus)
5229 #include <stdlib.h>
5230 void
5231 lshift_com (rp, up, n, cnt)
5232   unsigned long *rp;
5233   unsigned long *up;
5234   long n;
5235   unsigned cnt;
5236 {
5237   unsigned long high_limb, low_limb;
5238   unsigned tnc;
5239   long i;
5240   up += n;
5241   rp += n;
5242   tnc = 8 * sizeof (unsigned long) - cnt;
5243   low_limb = *--up;
5244   high_limb = low_limb << cnt;
5245   for (i = n - 1; i != 0; i--)
5246     {
5247       low_limb = *--up;
5248       *--rp = ~(high_limb | (low_limb >> tnc));
5249       high_limb = low_limb << cnt;
5250     }
5251   *--rp = ~high_limb;
5252 }
5253 int
5254 main ()
5255 {
5256   unsigned long *r, *r2;
5257   unsigned long a[88 + 1];
5258   long i;
5259   for (i = 0; i < 88 + 1; i++)
5260     a[i] = ~0L;
5261   r = malloc (10000 * sizeof (unsigned long));
5262   r2 = r;
5263   for (i = 0; i < 528; i += 22)
5264     {
5265       lshift_com (r2, a,
5266                   i / (8 * sizeof (unsigned long)) + 1,
5267                   i % (8 * sizeof (unsigned long)));
5268       r2 += 88 + 1;
5269     }
5270   if (r[2048] != 0 || r[2049] != 0 || r[2050] != 0 || r[2051] != 0 ||
5271       r[2052] != 0 || r[2053] != 0 || r[2054] != 0)
5272     abort ();
5273   return 0;
5274 }
5275 #else
5276 int
5277 main ()
5278 {
5279   return 0;
5280 }
5281 #endif
5282
5283 EOF
5284   echo "Test compile: mpn_lshift_com optimization 2" >&5
5285   gmp_compile="$cc $cflags $cppflags conftest.c >&5"
5286   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5287   (eval $gmp_compile) 2>&5
5288   ac_status=$?
5289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5290   (exit $ac_status); }; then
5291     cc_works_part=yes
5292     if test "$cross_compiling" = no; then
5293       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
5294   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5295   (eval $ac_try) 2>&5
5296   ac_status=$?
5297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5298   (exit $ac_status); }; }; then :;
5299       else
5300         cc_works_part=norun
5301       fi
5302     fi
5303   else
5304     cc_works_part=no
5305   fi
5306   if test "$cc_works_part" != yes; then
5307     echo "failed program was:" >&5
5308     cat conftest.c >&5
5309   fi
5310   rm -f conftest* a.out b.out a.exe a_out.exe
5311   case $cc_works_part in
5312     yes)
5313
5314       ;;
5315     no)
5316       gmp_prog_cc_works="no, mpn_lshift_com optimization 2"
5317       ;;
5318     norun)
5319       gmp_prog_cc_works="no, mpn_lshift_com optimization 2, program does not run"
5320       ;;
5321   esac
5322 fi
5323
5324
5325
5326
5327 # A certain _GLOBAL_OFFSET_TABLE_ problem in past versions of gas, tickled
5328 # by recent versions of gcc.
5329 #
5330 if test "$gmp_prog_cc_works" = yes; then
5331   case $host in
5332     i?86*-*-* | k[5-8]*-*-* | pentium*-*-* | athlon-*-* | viac3*-*-* | geode*-*-*)
5333       # this problem only arises in PIC code, so don't need to test when
5334       # --disable-shared.  We don't necessarily have $enable_shared set to
5335       # yes at this point, it will still be unset for the default (which is
5336       # yes); hence the use of "!= no".
5337       if test "$enable_shared" != no; then
5338         echo "Testing gcc GOT with eax emitted" >&5
5339 cat >conftest.c <<\EOF
5340 int foo;
5341 int bar () { return foo; }
5342 EOF
5343 tmp_got_emitted=no
5344 gmp_compile="$cc $cflags $cppflags -fPIC -S conftest.c >&5 2>&1"
5345 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5346   (eval $gmp_compile) 2>&5
5347   ac_status=$?
5348   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5349   (exit $ac_status); }; then
5350   if grep "addl.*_GLOBAL_OFFSET_TABLE_.*eax" conftest.s >/dev/null; then
5351     tmp_got_emitted=yes
5352   fi
5353 fi
5354 rm -f conftest.*
5355 echo "Result: $tmp_got_emitted" >&5
5356 if test "$tmp_got_emitted" = yes; then
5357   echo "Testing gas GOT with eax good" >&5
5358 cat >conftest.awk <<\EOF
5359 BEGIN {
5360   want[0]  = "001"
5361   want[1]  = "043"
5362   want[2]  = "105"
5363   want[3]  = "147"
5364   want[4]  = "211"
5365   want[5]  = "253"
5366   want[6]  = "315"
5367   want[7]  = "357"
5368
5369   want[8]  = "005"
5370   want[9]  = "002"
5371   want[10] = "000"
5372   want[11] = "000"
5373   want[12] = "000"
5374
5375   want[13] = "376"
5376   want[14] = "334"
5377   want[15] = "272"
5378   want[16] = "230"
5379   want[17] = "166"
5380   want[18] = "124"
5381   want[19] = "062"
5382   want[20] = "020"
5383
5384   result = "yes"
5385 }
5386 {
5387   for (f = 2; f <= NF; f++)
5388     {
5389       for (i = 0; i < 20; i++)
5390         got[i] = got[i+1];
5391       got[20] = $f;
5392
5393       found = 1
5394       for (i = 0; i < 21; i++)
5395         if (got[i] != want[i])
5396           {
5397             found = 0
5398             break
5399           }
5400       if (found)
5401         {
5402           result = "no"
5403           exit
5404         }
5405     }
5406 }
5407 END {
5408   print result
5409 }
5410 EOF
5411 cat >conftest.s <<\EOF
5412         .text
5413         .byte   1, 35, 69, 103, 137, 171, 205, 239
5414         addl    $_GLOBAL_OFFSET_TABLE_, %eax
5415         .byte   254, 220, 186, 152, 118, 84, 50, 16
5416 EOF
5417 tmp_got_good=yes
5418 gmp_compile="$cc $cflags $cppflags -fPIC -o conftest.o -c conftest.s >&5 2>&1"
5419 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5420   (eval $gmp_compile) 2>&5
5421   ac_status=$?
5422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5423   (exit $ac_status); }; then
5424   tmp_got_good=`od -b conftest.o | $AWK -f conftest.awk`
5425 fi
5426 rm -f conftest.*
5427 echo "Result: $tmp_got_good" >&5
5428 if test "$tmp_got_good" = no; then
5429   gmp_prog_cc_works="no, bad gas GOT with eax"
5430 else
5431   :
5432 fi
5433
5434 else
5435   :
5436 fi
5437
5438       fi
5439       ;;
5440   esac
5441 fi
5442
5443 { echo "$as_me:$LINENO: result: $gmp_prog_cc_works" >&5
5444 echo "${ECHO_T}$gmp_prog_cc_works" >&6; }
5445 case $gmp_prog_cc_works in
5446   yes)
5447
5448     ;;
5449   *)
5450     continue
5451     ;;
5452 esac
5453
5454
5455         # If we're supposed to be using a "long long" for a limb, check that
5456         # it works.
5457                                   eval limb_chosen=\"\$limb$abi1\"
5458         test -n "$limb_chosen" || eval limb_chosen=\"\$limb$abi2\"
5459         if test "$limb_chosen" = longlong; then
5460           { echo "$as_me:$LINENO: checking compiler $cc $cflags $cppflags has long long" >&5
5461 echo $ECHO_N "checking compiler $cc $cflags $cppflags has long long... $ECHO_C" >&6; }
5462 cat >conftest.c <<EOF
5463 long long  foo;
5464 long long  bar () { return foo; }
5465 int main () { return 0; }
5466 EOF
5467 gmp_prog_cc_works=no
5468 gmp_compile="$cc $cflags $cppflags -c conftest.c >&5"
5469 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5470   (eval $gmp_compile) 2>&5
5471   ac_status=$?
5472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5473   (exit $ac_status); }; then
5474   gmp_prog_cc_works=yes
5475 else
5476   echo "failed program was:" >&5
5477   cat conftest.c >&5
5478 fi
5479 rm -f conftest* a.out b.out a.exe a_out.exe
5480 { echo "$as_me:$LINENO: result: $gmp_prog_cc_works" >&5
5481 echo "${ECHO_T}$gmp_prog_cc_works" >&6; }
5482 if test $gmp_prog_cc_works = yes; then
5483   :
5484 else
5485   continue
5486 fi
5487
5488         fi
5489
5490         # The tests to perform on this $cc, if any
5491                                eval testlist=\"\$${ccbase}${abi1}_testlist\"
5492         test -n "$testlist" || eval testlist=\"\$${ccbase}${abi2}_testlist\"
5493         test -n "$testlist" || eval testlist=\"\$any${abi1}_testlist\"
5494         test -n "$testlist" || eval testlist=\"\$any${abi2}_testlist\"
5495
5496         testlist_pass=yes
5497         for tst in $testlist; do
5498           case $tst in
5499           hpc-hppa-2-0)   { echo "$as_me:$LINENO: checking whether HP compiler $cc is good for 64-bits" >&5
5500 echo $ECHO_N "checking whether HP compiler $cc is good for 64-bits... $ECHO_C" >&6; }
5501 # Bad compiler output:
5502 #   ccom: HP92453-01 G.10.32.05 HP C Compiler
5503 # Good compiler output:
5504 #   ccom: HP92453-01 A.10.32.30 HP C Compiler
5505 # Let A.10.32.30 or higher be ok.
5506 echo >conftest.c
5507 gmp_tmp_vs=`$cc  -V -c -o conftest.$OBJEXT conftest.c 2>&1 | grep "^ccom:"`
5508 echo "Version string: $gmp_tmp_vs" >&5
5509 rm conftest*
5510 gmp_tmp_v1=`echo $gmp_tmp_vs | sed 's/.* .\.\([0-9]*\).*/\1/'`
5511 gmp_tmp_v2=`echo $gmp_tmp_vs | sed 's/.* .\..*\.\(.*\)\..* HP C.*/\1/'`
5512 gmp_tmp_v3=`echo $gmp_tmp_vs | sed 's/.* .\..*\..*\.\(.*\) HP C.*/\1/'`
5513 echo "Version number: $gmp_tmp_v1.$gmp_tmp_v2.$gmp_tmp_v3" >&5
5514 if test -z "$gmp_tmp_v1"; then
5515   gmp_hpc_64bit=not-applicable
5516 else
5517   gmp_compare_ge=no
5518 if test -n "$gmp_tmp_v1"; then
5519   if test "$gmp_tmp_v1" -gt 10; then
5520     gmp_compare_ge=yes
5521   else
5522     if test "$gmp_tmp_v1" -eq 10; then
5523       if test -n "$gmp_tmp_v2"; then
5524   if test "$gmp_tmp_v2" -gt 32; then
5525     gmp_compare_ge=yes
5526   else
5527     if test "$gmp_tmp_v2" -eq 32; then
5528       if test -n "$gmp_tmp_v3" && test "$gmp_tmp_v3" -ge 30; then
5529   gmp_compare_ge=yes
5530 fi
5531
5532     fi
5533   fi
5534 fi
5535
5536     fi
5537   fi
5538 fi
5539
5540
5541   gmp_hpc_64bit=$gmp_compare_ge
5542 fi
5543 { echo "$as_me:$LINENO: result: $gmp_hpc_64bit" >&5
5544 echo "${ECHO_T}$gmp_hpc_64bit" >&6; }
5545 if test $gmp_hpc_64bit = yes; then
5546   :
5547 else
5548   testlist_pass=no
5549 fi
5550  ;;
5551           gcc-arm-umodsi) { echo "$as_me:$LINENO: checking whether ARM gcc unsigned division works" >&5
5552 echo $ECHO_N "checking whether ARM gcc unsigned division works... $ECHO_C" >&6; }
5553 tmp_version=`$cc --version`
5554 echo "$tmp_version" >&5
5555 case $tmp_version in
5556   2.95 | 2.95.[123])
5557     testlist_pass=no
5558     gmp_gcc_arm_umodsi_result="no, gcc 2.95.[0123]" ;;
5559   *)
5560     :
5561     gmp_gcc_arm_umodsi_result=yes ;;
5562 esac
5563 { echo "$as_me:$LINENO: result: $gmp_gcc_arm_umodsi_result" >&5
5564 echo "${ECHO_T}$gmp_gcc_arm_umodsi_result" >&6; }
5565  ;;
5566           gcc-mips-o32)   { echo "$as_me:$LINENO: checking whether gcc supports o32" >&5
5567 echo $ECHO_N "checking whether gcc supports o32... $ECHO_C" >&6; }
5568 echo 'int x;' >conftest.c
5569 echo "$cc -mabi=32 -c conftest.c" >&5
5570 if $cc -mabi=32 -c conftest.c >conftest.out 2>&1; then
5571   result=yes
5572 else
5573   cat conftest.out >&5
5574   if grep "cc1: Invalid option \`abi=32'" conftest.out >/dev/null; then
5575     result=yes
5576   else
5577     result=no
5578   fi
5579 fi
5580 rm -f conftest.*
5581 { echo "$as_me:$LINENO: result: $result" >&5
5582 echo "${ECHO_T}$result" >&6; }
5583 if test $result = yes; then
5584   :
5585 else
5586   testlist_pass=no
5587 fi
5588  ;;
5589           hppa-level-2.0) { echo "$as_me:$LINENO: checking $cc $cflags assembler knows hppa 2.0" >&5
5590 echo $ECHO_N "checking $cc $cflags assembler knows hppa 2.0... $ECHO_C" >&6; }
5591 result=no
5592 cat >conftest.s <<EOF
5593         .level 2.0
5594 EOF
5595 gmp_compile="$cc $cflags -c conftest.s >&5 2>&1"
5596 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5597   (eval $gmp_compile) 2>&5
5598   ac_status=$?
5599   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5600   (exit $ac_status); }; then
5601   result=yes
5602 else
5603   echo "failed program was" >&5
5604   cat conftest.s >&5
5605 fi
5606 rm -f conftest*
5607 { echo "$as_me:$LINENO: result: $result" >&5
5608 echo "${ECHO_T}$result" >&6; }
5609 if test "$result" = yes; then
5610   :
5611 else
5612   testlist_pass=no
5613 fi
5614  ;;
5615           sizeof*)       echo "configure: testlist $tst" >&5
5616 gmp_sizeof_type=`echo "$tst" | sed 's/sizeof-\([a-z]*\).*/\1/'`
5617 gmp_sizeof_want=`echo "$tst" | sed 's/sizeof-[a-z]*-\([0-9]*\).*/\1/'`
5618 { echo "$as_me:$LINENO: checking compiler $cc $cflags has sizeof($gmp_sizeof_type)==$gmp_sizeof_want" >&5
5619 echo $ECHO_N "checking compiler $cc $cflags has sizeof($gmp_sizeof_type)==$gmp_sizeof_want... $ECHO_C" >&6; }
5620 cat >conftest.c <<EOF
5621 int
5622 main ()
5623 {
5624   static int test_array [1 - 2 * (long) (sizeof ($gmp_sizeof_type) != $gmp_sizeof_want)];
5625   test_array[0] = 0;
5626   return 0;
5627 }
5628 EOF
5629 gmp_c_testlist_sizeof=no
5630 gmp_compile="$cc $cflags -c conftest.c >&5"
5631 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5632   (eval $gmp_compile) 2>&5
5633   ac_status=$?
5634   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5635   (exit $ac_status); }; then
5636   gmp_c_testlist_sizeof=yes
5637 fi
5638 rm -f conftest*
5639 { echo "$as_me:$LINENO: result: $gmp_c_testlist_sizeof" >&5
5640 echo "${ECHO_T}$gmp_c_testlist_sizeof" >&6; }
5641 if test $gmp_c_testlist_sizeof = yes; then
5642   :
5643 else
5644   testlist_pass=no
5645 fi
5646  ;;
5647           esac
5648           if test $testlist_pass = no; then break; fi
5649         done
5650
5651         if test $testlist_pass = yes; then
5652           found_compiler=yes
5653           break
5654         fi
5655       done
5656
5657       if test $found_compiler = yes; then break; fi
5658     done
5659
5660     if test $found_compiler = yes; then break; fi
5661   done
5662
5663   if test $found_compiler = yes; then break; fi
5664 done
5665
5666
5667 # If we recognised the CPU, as indicated by $path being set, then insist
5668 # that we have a working compiler, either from our $cclist choices or from
5669 # $CC.  We can't let AC_PROG_CC look around for a compiler because it might
5670 # find one that we've rejected (for not supporting the modes our asm code
5671 # demands, etc).
5672 #
5673 # If we didn't recognise the CPU (and this includes host_cpu=none), then
5674 # fall through and let AC_PROG_CC look around for a compiler too.  This is
5675 # mostly in the interests of following a standard autoconf setup, after all
5676 # we've already tested cc and gcc adequately (hopefully).  As of autoconf
5677 # 2.50 the only thing AC_PROG_CC really adds is a check for "cl" (Microsoft
5678 # C on MS-DOS systems).
5679 #
5680 if test $found_compiler = no && test -n "$path"; then
5681   { { echo "$as_me:$LINENO: error: could not find a working compiler, see config.log for details" >&5
5682 echo "$as_me: error: could not find a working compiler, see config.log for details" >&2;}
5683    { (exit 1); exit 1; }; }
5684 fi
5685
5686
5687 if test $found_compiler = yes; then
5688
5689   # If we're creating CFLAGS, then look for optional additions.  If the user
5690   # set CFLAGS then leave it alone.
5691   #
5692   if test "$test_CFLAGS" != set; then
5693                           eval optlist=\"\$${ccbase}${abi1}_cflags_optlist\"
5694     test -n "$optlist" || eval optlist=\"\$${ccbase}${abi2}_cflags_optlist\"
5695
5696     for opt in $optlist; do
5697                              eval optflags=\"\$${ccbase}${abi1}_cflags_${opt}\"
5698       test -n "$optflags" || eval optflags=\"\$${ccbase}${abi2}_cflags_${opt}\"
5699       test -n "$optflags" || eval optflags=\"\$${ccbase}_cflags_${opt}\"
5700
5701       for flag in $optflags; do
5702
5703         # ~ represents a space in an option spec
5704         flag=`echo "$flag" | tr '~' ' '`
5705
5706         case $flag in
5707           -march=pentium4 | -march=k8)
5708             # For -march settings which enable SSE2 we exclude certain bad
5709             # gcc versions and we need an OS knowing how to save xmm regs.
5710             #
5711             # This is only for ABI=32, any 64-bit gcc is good and any OS
5712             # knowing x86_64 will know xmm.
5713             #
5714             # -march=k8 was only introduced in gcc 3.3, so we shouldn't need
5715             # the GMP_GCC_PENTIUM4_SSE2 check (for gcc 3.2 and prior).  But
5716             # it doesn't hurt to run it anyway, sharing code with the
5717             # pentium4 case.
5718             #
5719             if test "$abi" = 32; then
5720               { echo "$as_me:$LINENO: checking whether gcc is good for sse2" >&5
5721 echo $ECHO_N "checking whether gcc is good for sse2... $ECHO_C" >&6; }
5722 case `$cc $cflags $cppflags -dumpversion` in
5723   3.[012] | 3.[012].*) result=no ;;
5724   *)                     result=yes ;;
5725 esac
5726 { echo "$as_me:$LINENO: result: $result" >&5
5727 echo "${ECHO_T}$result" >&6; }
5728 if test "$result" = yes; then
5729   :
5730 else
5731   continue
5732 fi
5733
5734               { echo "$as_me:$LINENO: checking whether the operating system supports XMM registers" >&5
5735 echo $ECHO_N "checking whether the operating system supports XMM registers... $ECHO_C" >&6; }
5736 if test "${gmp_cv_os_x86_xmm+set}" = set; then
5737   echo $ECHO_N "(cached) $ECHO_C" >&6
5738 else
5739   if test "$build" = "$host"; then
5740   # remove anything that might look like compiler output to our "||" expression
5741   rm -f conftest* a.out b.out a.exe a_out.exe
5742   cat >conftest.s <<EOF
5743         .text
5744 main:
5745 _main:
5746         .globl  main
5747         .globl  _main
5748         .byte   0x0f, 0x57, 0xc0
5749         xorl    %eax, %eax
5750         ret
5751 EOF
5752   gmp_compile="$cc $cflags $cppflags conftest.s -o conftest >&5"
5753   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5754   (eval $gmp_compile) 2>&5
5755   ac_status=$?
5756   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5757   (exit $ac_status); }; then
5758     if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
5759   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5760   (eval $ac_try) 2>&5
5761   ac_status=$?
5762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5763   (exit $ac_status); }; }; then
5764       gmp_cv_os_x86_xmm=yes
5765     else
5766       gmp_cv_os_x86_xmm=no
5767     fi
5768   else
5769     { echo "$as_me:$LINENO: WARNING: Oops, cannot compile test program" >&5
5770 echo "$as_me: WARNING: Oops, cannot compile test program" >&2;}
5771   fi
5772   rm -f conftest*
5773 fi
5774
5775 if test -z "$gmp_cv_os_x86_xmm"; then
5776   case $host_os in
5777     freebsd[123] | freebsd[123].*)
5778       gmp_cv_os_x86_xmm=no ;;
5779     freebsd*)
5780       gmp_cv_os_x86_xmm=yes ;;
5781     *)
5782       gmp_cv_os_x86_xmm=probably ;;
5783   esac
5784 fi
5785
5786 fi
5787 { echo "$as_me:$LINENO: result: $gmp_cv_os_x86_xmm" >&5
5788 echo "${ECHO_T}$gmp_cv_os_x86_xmm" >&6; }
5789
5790 if test "$gmp_cv_os_x86_xmm" = probably; then
5791   { echo "$as_me:$LINENO: WARNING: Not certain of OS support for xmm when cross compiling." >&5
5792 echo "$as_me: WARNING: Not certain of OS support for xmm when cross compiling." >&2;}
5793   { echo "$as_me:$LINENO: WARNING: Will assume it's ok, expect a SIGILL if this is wrong." >&5
5794 echo "$as_me: WARNING: Will assume it's ok, expect a SIGILL if this is wrong." >&2;}
5795 fi
5796
5797 case $gmp_cv_os_x86_xmm in
5798 no)
5799   continue
5800   ;;
5801 *)
5802
5803   ;;
5804 esac
5805
5806             fi
5807             ;;
5808           -no-cpp-precomp)
5809             # special check, avoiding a warning
5810             if test "$ccbase" = gcc; then
5811   { echo "$as_me:$LINENO: checking compiler $cc $cflags -no-cpp-precomp" >&5
5812 echo $ECHO_N "checking compiler $cc $cflags -no-cpp-precomp... $ECHO_C" >&6; }
5813   result=no
5814   cat >conftest.c <<EOF
5815 int main () { return 0; }
5816 EOF
5817   gmp_compile="$cc $cflags -no-cpp-precomp conftest.c >conftest.out 2>&1"
5818   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5819   (eval $gmp_compile) 2>&5
5820   ac_status=$?
5821   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5822   (exit $ac_status); }; then
5823     if grep "unrecognized option.*-no-cpp-precomp" conftest.out >/dev/null; then : ;
5824     else
5825       result=yes
5826     fi
5827   fi
5828   cat conftest.out >&5
5829   rm -f conftest* a.out b.out a.exe a_out.exe
5830   { echo "$as_me:$LINENO: result: $result" >&5
5831 echo "${ECHO_T}$result" >&6; }
5832   if test "$result" = yes; then
5833       cflags="$cflags $flag"
5834                                    break
5835   else
5836       continue
5837   fi
5838 fi
5839
5840             ;;
5841           -Wa,-m*)
5842             case $host in
5843               alpha*-*-*)
5844                 { echo "$as_me:$LINENO: checking assembler $cc $cflags $flag" >&5
5845 echo $ECHO_N "checking assembler $cc $cflags $flag... $ECHO_C" >&6; }
5846 result=no
5847 cat >conftest.c <<EOF
5848 int main () {}
5849 EOF
5850 gmp_compile="$cc $cflags $flag -c conftest.c >conftest.out 2>&1"
5851 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5852   (eval $gmp_compile) 2>&5
5853   ac_status=$?
5854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5855   (exit $ac_status); }; then
5856   if grep "Unknown CPU identifier" conftest.out >/dev/null; then : ;
5857   else
5858     result=yes
5859   fi
5860 fi
5861 cat conftest.out >&5
5862 rm -f conftest*
5863 { echo "$as_me:$LINENO: result: $result" >&5
5864 echo "${ECHO_T}$result" >&6; }
5865 if test "$result" = yes; then
5866   :
5867 else
5868   continue
5869 fi
5870
5871               ;;
5872             esac
5873             ;;
5874           -Wa,-oldas)
5875             { echo "$as_me:$LINENO: checking for $cc $cflags $cppflags -Wa,-oldas" >&5
5876 echo $ECHO_N "checking for $cc $cflags $cppflags -Wa,-oldas... $ECHO_C" >&6; }
5877 result=no
5878 cat >conftest.c <<EOF
5879 EOF
5880 echo "with empty conftest.c" >&5
5881 gmp_compile="$cc $cflags $cppflags -c conftest.c >&5 2>&1"
5882 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5883   (eval $gmp_compile) 2>&5
5884   ac_status=$?
5885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5886   (exit $ac_status); }; then : ;
5887 else
5888   # empty fails
5889   gmp_compile="$cc $cflags $cppflags -Wa,-oldas -c conftest.c >&5 2>&1"
5890   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5891   (eval $gmp_compile) 2>&5
5892   ac_status=$?
5893   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5894   (exit $ac_status); }; then
5895     # but with -Wa,-oldas it works
5896     result=yes
5897   fi
5898 fi
5899 rm -f conftest*
5900 { echo "$as_me:$LINENO: result: $result" >&5
5901 echo "${ECHO_T}$result" >&6; }
5902 if test "$result" = yes; then
5903   cflags="$cflags $flag"
5904                              break
5905 else
5906   continue
5907 fi
5908
5909             ;;
5910         esac
5911
5912         { echo "$as_me:$LINENO: checking compiler $cc $cflags $cppflags $flag" >&5
5913 echo $ECHO_N "checking compiler $cc $cflags $cppflags $flag... $ECHO_C" >&6; }
5914 gmp_prog_cc_works=yes
5915
5916 # first see a simple "main()" works, then go on to other checks
5917 if test "$gmp_prog_cc_works" = yes; then
5918   # remove anything that might look like compiler output to our "||" expression
5919   rm -f conftest* a.out b.out a.exe a_out.exe
5920   cat >conftest.c <<EOF
5921
5922 int main () { return 0; }
5923 EOF
5924   echo "Test compile: " >&5
5925   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
5926   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5927   (eval $gmp_compile) 2>&5
5928   ac_status=$?
5929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5930   (exit $ac_status); }; then
5931     cc_works_part=yes
5932     if test "$cross_compiling" = no; then
5933       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
5934   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5935   (eval $ac_try) 2>&5
5936   ac_status=$?
5937   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5938   (exit $ac_status); }; }; then :;
5939       else
5940         cc_works_part=norun
5941       fi
5942     fi
5943   else
5944     cc_works_part=no
5945   fi
5946   if test "$cc_works_part" != yes; then
5947     echo "failed program was:" >&5
5948     cat conftest.c >&5
5949   fi
5950   rm -f conftest* a.out b.out a.exe a_out.exe
5951   case $cc_works_part in
5952     yes)
5953
5954       ;;
5955     no)
5956       gmp_prog_cc_works="no"
5957       ;;
5958     norun)
5959       gmp_prog_cc_works="no, program does not run"
5960       ;;
5961   esac
5962 fi
5963
5964
5965
5966
5967 if test "$gmp_prog_cc_works" = yes; then
5968   # remove anything that might look like compiler output to our "||" expression
5969   rm -f conftest* a.out b.out a.exe a_out.exe
5970   cat >conftest.c <<EOF
5971 /* The following provokes an internal error from gcc 2.95.2 -mpowerpc64
5972    (without -maix64), hence detecting an unusable compiler */
5973 void *g() { return (void *) 0; }
5974 void *f() { return g(); }
5975
5976 int main () { return 0; }
5977 EOF
5978   echo "Test compile: function pointer return" >&5
5979   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
5980   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
5981   (eval $gmp_compile) 2>&5
5982   ac_status=$?
5983   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5984   (exit $ac_status); }; then
5985     cc_works_part=yes
5986     if test "$cross_compiling" = no; then
5987       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
5988   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5989   (eval $ac_try) 2>&5
5990   ac_status=$?
5991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5992   (exit $ac_status); }; }; then :;
5993       else
5994         cc_works_part=norun
5995       fi
5996     fi
5997   else
5998     cc_works_part=no
5999   fi
6000   if test "$cc_works_part" != yes; then
6001     echo "failed program was:" >&5
6002     cat conftest.c >&5
6003   fi
6004   rm -f conftest* a.out b.out a.exe a_out.exe
6005   case $cc_works_part in
6006     yes)
6007
6008       ;;
6009     no)
6010       gmp_prog_cc_works="no, function pointer return"
6011       ;;
6012     norun)
6013       gmp_prog_cc_works="no, function pointer return, program does not run"
6014       ;;
6015   esac
6016 fi
6017
6018
6019
6020
6021 if test "$gmp_prog_cc_works" = yes; then
6022   # remove anything that might look like compiler output to our "||" expression
6023   rm -f conftest* a.out b.out a.exe a_out.exe
6024   cat >conftest.c <<EOF
6025 /* The following provokes an invalid instruction syntax from i386 gcc
6026    -march=pentiumpro on Solaris 2.8.  The native sun assembler
6027    requires a non-standard syntax for cmov which gcc (as of 2.95.2 at
6028    least) doesn't know.  */
6029 int n;
6030 int cmov () { return (n >= 0 ? n : 0); }
6031
6032 int main () { return 0; }
6033 EOF
6034   echo "Test compile: cmov instruction" >&5
6035   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6036   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6037   (eval $gmp_compile) 2>&5
6038   ac_status=$?
6039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6040   (exit $ac_status); }; then
6041     cc_works_part=yes
6042     if test "$cross_compiling" = no; then
6043       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6044   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6045   (eval $ac_try) 2>&5
6046   ac_status=$?
6047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6048   (exit $ac_status); }; }; then :;
6049       else
6050         cc_works_part=norun
6051       fi
6052     fi
6053   else
6054     cc_works_part=no
6055   fi
6056   if test "$cc_works_part" != yes; then
6057     echo "failed program was:" >&5
6058     cat conftest.c >&5
6059   fi
6060   rm -f conftest* a.out b.out a.exe a_out.exe
6061   case $cc_works_part in
6062     yes)
6063
6064       ;;
6065     no)
6066       gmp_prog_cc_works="no, cmov instruction"
6067       ;;
6068     norun)
6069       gmp_prog_cc_works="no, cmov instruction, program does not run"
6070       ;;
6071   esac
6072 fi
6073
6074
6075
6076
6077 if test "$gmp_prog_cc_works" = yes; then
6078   # remove anything that might look like compiler output to our "||" expression
6079   rm -f conftest* a.out b.out a.exe a_out.exe
6080   cat >conftest.c <<EOF
6081 /* The following provokes a linker invocation problem with gcc 3.0.3
6082    on AIX 4.3 under "-maix64 -mpowerpc64 -mcpu=630".  The -mcpu=630
6083    option causes gcc to incorrectly select the 32-bit libgcc.a, not
6084    the 64-bit one, and consequently it misses out on the __fixunsdfdi
6085    helper (double -> uint64 conversion).  */
6086 double d;
6087 unsigned long gcc303 () { return (unsigned long) d; }
6088
6089 int main () { return 0; }
6090 EOF
6091   echo "Test compile: double -> ulong conversion" >&5
6092   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6093   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6094   (eval $gmp_compile) 2>&5
6095   ac_status=$?
6096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6097   (exit $ac_status); }; then
6098     cc_works_part=yes
6099     if test "$cross_compiling" = no; then
6100       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6101   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6102   (eval $ac_try) 2>&5
6103   ac_status=$?
6104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6105   (exit $ac_status); }; }; then :;
6106       else
6107         cc_works_part=norun
6108       fi
6109     fi
6110   else
6111     cc_works_part=no
6112   fi
6113   if test "$cc_works_part" != yes; then
6114     echo "failed program was:" >&5
6115     cat conftest.c >&5
6116   fi
6117   rm -f conftest* a.out b.out a.exe a_out.exe
6118   case $cc_works_part in
6119     yes)
6120
6121       ;;
6122     no)
6123       gmp_prog_cc_works="no, double -> ulong conversion"
6124       ;;
6125     norun)
6126       gmp_prog_cc_works="no, double -> ulong conversion, program does not run"
6127       ;;
6128   esac
6129 fi
6130
6131
6132
6133
6134 if test "$gmp_prog_cc_works" = yes; then
6135   # remove anything that might look like compiler output to our "||" expression
6136   rm -f conftest* a.out b.out a.exe a_out.exe
6137   cat >conftest.c <<EOF
6138 /* The following provokes an error from hppa gcc 2.95 under -mpa-risc-2-0 if
6139    the assembler doesn't know hppa 2.0 instructions.  fneg is a 2.0
6140    instruction, and a negation like this comes out using it.  */
6141 double fneg_data;
6142 unsigned long fneg () { return -fneg_data; }
6143
6144 int main () { return 0; }
6145 EOF
6146   echo "Test compile: double negation" >&5
6147   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6148   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6149   (eval $gmp_compile) 2>&5
6150   ac_status=$?
6151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6152   (exit $ac_status); }; then
6153     cc_works_part=yes
6154     if test "$cross_compiling" = no; then
6155       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6156   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6157   (eval $ac_try) 2>&5
6158   ac_status=$?
6159   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6160   (exit $ac_status); }; }; then :;
6161       else
6162         cc_works_part=norun
6163       fi
6164     fi
6165   else
6166     cc_works_part=no
6167   fi
6168   if test "$cc_works_part" != yes; then
6169     echo "failed program was:" >&5
6170     cat conftest.c >&5
6171   fi
6172   rm -f conftest* a.out b.out a.exe a_out.exe
6173   case $cc_works_part in
6174     yes)
6175
6176       ;;
6177     no)
6178       gmp_prog_cc_works="no, double negation"
6179       ;;
6180     norun)
6181       gmp_prog_cc_works="no, double negation, program does not run"
6182       ;;
6183   esac
6184 fi
6185
6186
6187
6188
6189 if test "$gmp_prog_cc_works" = yes; then
6190   # remove anything that might look like compiler output to our "||" expression
6191   rm -f conftest* a.out b.out a.exe a_out.exe
6192   cat >conftest.c <<EOF
6193 /* The following makes gcc 3.3 -march=pentium4 generate an SSE2 xmm insn
6194    (cvtsd2ss) which will provoke an error if the assembler doesn't recognise
6195    those instructions.  Not sure how much of the gmp code will come out
6196    wanting sse2, but it's easiest to reject an option we know is bad.  */
6197 double ftod_data;
6198 float ftod () { return (float) ftod_data; }
6199
6200 int main () { return 0; }
6201 EOF
6202   echo "Test compile: double -> float conversion" >&5
6203   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6204   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6205   (eval $gmp_compile) 2>&5
6206   ac_status=$?
6207   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6208   (exit $ac_status); }; then
6209     cc_works_part=yes
6210     if test "$cross_compiling" = no; then
6211       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6212   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6213   (eval $ac_try) 2>&5
6214   ac_status=$?
6215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6216   (exit $ac_status); }; }; then :;
6217       else
6218         cc_works_part=norun
6219       fi
6220     fi
6221   else
6222     cc_works_part=no
6223   fi
6224   if test "$cc_works_part" != yes; then
6225     echo "failed program was:" >&5
6226     cat conftest.c >&5
6227   fi
6228   rm -f conftest* a.out b.out a.exe a_out.exe
6229   case $cc_works_part in
6230     yes)
6231
6232       ;;
6233     no)
6234       gmp_prog_cc_works="no, double -> float conversion"
6235       ;;
6236     norun)
6237       gmp_prog_cc_works="no, double -> float conversion, program does not run"
6238       ;;
6239   esac
6240 fi
6241
6242
6243
6244
6245 if test "$gmp_prog_cc_works" = yes; then
6246   # remove anything that might look like compiler output to our "||" expression
6247   rm -f conftest* a.out b.out a.exe a_out.exe
6248   cat >conftest.c <<EOF
6249 /* The following provokes an internal compiler error from gcc version
6250    "2.9-gnupro-99r1" under "-O2 -mcpu=ev6", apparently relating to char
6251    values being spilled into floating point registers.  The problem doesn't
6252    show up all the time, but has occurred enough in GMP for us to reject
6253    this compiler+flags.  */
6254 #include <string.h>  /* for memcpy */
6255 struct try_t
6256 {
6257  char dst[2];
6258  char size;
6259  long d0, d1, d2, d3, d4, d5, d6;
6260  char overlap;
6261 };
6262 struct try_t param[6];
6263 int
6264 param_init ()
6265 {
6266  struct try_t *p;
6267  memcpy (p, &param[ 2 ], sizeof (*p));
6268  memcpy (p, &param[ 2 ], sizeof (*p));
6269  p->size = 2;
6270  memcpy (p, &param[ 1 ], sizeof (*p));
6271  p->dst[0] = 1;
6272  p->overlap = 2;
6273  memcpy (p, &param[ 3 ], sizeof (*p));
6274  p->dst[0] = 1;
6275  p->overlap = 8;
6276  memcpy (p, &param[ 4 ], sizeof (*p));
6277  memcpy (p, &param[ 4 ], sizeof (*p));
6278  p->overlap = 8;
6279  memcpy (p, &param[ 5 ], sizeof (*p));
6280  memcpy (p, &param[ 5 ], sizeof (*p));
6281  memcpy (p, &param[ 5 ], sizeof (*p));
6282  return 0;
6283 }
6284
6285 int main () { return 0; }
6286 EOF
6287   echo "Test compile: gnupro alpha ev6 char spilling" >&5
6288   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6289   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6290   (eval $gmp_compile) 2>&5
6291   ac_status=$?
6292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6293   (exit $ac_status); }; then
6294     cc_works_part=yes
6295     if test "$cross_compiling" = no; then
6296       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6297   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6298   (eval $ac_try) 2>&5
6299   ac_status=$?
6300   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6301   (exit $ac_status); }; }; then :;
6302       else
6303         cc_works_part=norun
6304       fi
6305     fi
6306   else
6307     cc_works_part=no
6308   fi
6309   if test "$cc_works_part" != yes; then
6310     echo "failed program was:" >&5
6311     cat conftest.c >&5
6312   fi
6313   rm -f conftest* a.out b.out a.exe a_out.exe
6314   case $cc_works_part in
6315     yes)
6316
6317       ;;
6318     no)
6319       gmp_prog_cc_works="no, gnupro alpha ev6 char spilling"
6320       ;;
6321     norun)
6322       gmp_prog_cc_works="no, gnupro alpha ev6 char spilling, program does not run"
6323       ;;
6324   esac
6325 fi
6326
6327
6328
6329
6330 # __builtin_alloca is not available everywhere, check it exists before
6331 # seeing that it works
6332 if test "$gmp_prog_cc_works" = yes; then
6333   # remove anything that might look like compiler output to our "||" expression
6334   rm -f conftest* a.out b.out a.exe a_out.exe
6335   cat >conftest.c <<EOF
6336 int k; int foo () { __builtin_alloca (k); }
6337 EOF
6338   echo "Test compile: __builtin_alloca availability" >&5
6339   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6340   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6341   (eval $gmp_compile) 2>&5
6342   ac_status=$?
6343   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6344   (exit $ac_status); }; then
6345     cc_works_part=yes
6346     if test "$cross_compiling" = no; then
6347       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6348   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6349   (eval $ac_try) 2>&5
6350   ac_status=$?
6351   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6352   (exit $ac_status); }; }; then :;
6353       else
6354         cc_works_part=norun
6355       fi
6356     fi
6357   else
6358     cc_works_part=no
6359   fi
6360   if test "$cc_works_part" != yes; then
6361     echo "failed program was:" >&5
6362     cat conftest.c >&5
6363   fi
6364   rm -f conftest* a.out b.out a.exe a_out.exe
6365   case $cc_works_part in
6366     yes)
6367       if test "$gmp_prog_cc_works" = yes; then
6368   # remove anything that might look like compiler output to our "||" expression
6369   rm -f conftest* a.out b.out a.exe a_out.exe
6370   cat >conftest.c <<EOF
6371 /* The following provokes an internal compiler error from Itanium HP-UX cc
6372     under +O2 or higher.  We use this sort of code in mpn/generic/mul_fft.c. */
6373 int k;
6374 int foo ()
6375 {
6376   int i, **a;
6377   a = __builtin_alloca (k);
6378   for (i = 0; i <= k; i++)
6379     a[i] = __builtin_alloca (1 << i);
6380 }
6381
6382 int main () { return 0; }
6383 EOF
6384   echo "Test compile: alloca array" >&5
6385   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6386   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6387   (eval $gmp_compile) 2>&5
6388   ac_status=$?
6389   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6390   (exit $ac_status); }; then
6391     cc_works_part=yes
6392     if test "$cross_compiling" = no; then
6393       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6394   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6395   (eval $ac_try) 2>&5
6396   ac_status=$?
6397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6398   (exit $ac_status); }; }; then :;
6399       else
6400         cc_works_part=norun
6401       fi
6402     fi
6403   else
6404     cc_works_part=no
6405   fi
6406   if test "$cc_works_part" != yes; then
6407     echo "failed program was:" >&5
6408     cat conftest.c >&5
6409   fi
6410   rm -f conftest* a.out b.out a.exe a_out.exe
6411   case $cc_works_part in
6412     yes)
6413
6414       ;;
6415     no)
6416       gmp_prog_cc_works="no, alloca array"
6417       ;;
6418     norun)
6419       gmp_prog_cc_works="no, alloca array, program does not run"
6420       ;;
6421   esac
6422 fi
6423
6424
6425
6426       ;;
6427     no)
6428
6429       ;;
6430     norun)
6431
6432       ;;
6433   esac
6434 fi
6435
6436
6437 if test "$gmp_prog_cc_works" = yes; then
6438   # remove anything that might look like compiler output to our "||" expression
6439   rm -f conftest* a.out b.out a.exe a_out.exe
6440   cat >conftest.c <<EOF
6441 /* The following provokes an internal error from the assembler on
6442    power2-ibm-aix4.3.1.0.  gcc -mrios2 compiles to nabs+fcirz, and this
6443    results in "Internal error related to the source program domain".
6444
6445    For reference it seems to be the combination of nabs+fcirz which is bad,
6446    not either alone.  This sort of thing occurs in mpz/get_str.c with the
6447    way double chars_per_bit_exactly is applied in MPN_SIZEINBASE.  Perhaps
6448    if that code changes to a scaled-integer style then we won't need this
6449    test.  */
6450
6451 double fp[1];
6452 int x;
6453 int f ()
6454 {
6455   int a;
6456   a = (x >= 0 ? x : -x);
6457   return a * fp[0];
6458 }
6459
6460 int main () { return 0; }
6461 EOF
6462   echo "Test compile: abs int -> double conversion" >&5
6463   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6464   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6465   (eval $gmp_compile) 2>&5
6466   ac_status=$?
6467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6468   (exit $ac_status); }; then
6469     cc_works_part=yes
6470     if test "$cross_compiling" = no; then
6471       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6472   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6473   (eval $ac_try) 2>&5
6474   ac_status=$?
6475   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6476   (exit $ac_status); }; }; then :;
6477       else
6478         cc_works_part=norun
6479       fi
6480     fi
6481   else
6482     cc_works_part=no
6483   fi
6484   if test "$cc_works_part" != yes; then
6485     echo "failed program was:" >&5
6486     cat conftest.c >&5
6487   fi
6488   rm -f conftest* a.out b.out a.exe a_out.exe
6489   case $cc_works_part in
6490     yes)
6491
6492       ;;
6493     no)
6494       gmp_prog_cc_works="no, abs int -> double conversion"
6495       ;;
6496     norun)
6497       gmp_prog_cc_works="no, abs int -> double conversion, program does not run"
6498       ;;
6499   esac
6500 fi
6501
6502
6503
6504
6505 if test "$gmp_prog_cc_works" = yes; then
6506   # remove anything that might look like compiler output to our "||" expression
6507   rm -f conftest* a.out b.out a.exe a_out.exe
6508   cat >conftest.c <<EOF
6509 /* The following provokes a segfault in the compiler on powerpc-apple-darwin.
6510    Extracted from tests/mpn/t-iord_u.c.  Causes Apple's gcc 3.3 build 1640 and
6511    1666 to segfault with e.g., -O2 -mpowerpc64.  */
6512
6513 #if defined (__GNUC__) && ! defined (__cplusplus)
6514 typedef unsigned long long t1;typedef t1*t2;
6515 static __inline__ t1 e(t2 rp,t2 up,int n,t1 v0)
6516 {t1 c,x,r;int i;if(v0){c=1;for(i=1;i<n;i++){x=up[i];r=x+1;rp[i]=r;}}return c;}
6517 f(){static const struct{t1 n;t1 src[9];t1 want[9];}d[]={{1,{0},{1}},};t1 got[9];int i;
6518 for(i=0;i<1;i++){if(e(got,got,9,d[i].n)==0)h();g(i,d[i].src,d[i].n,got,d[i].want,9);if(d[i].n)h();}}
6519 h(){}g(){}
6520 #else
6521 int dummy;
6522 #endif
6523
6524 int main () { return 0; }
6525 EOF
6526   echo "Test compile: long long reliability test 1" >&5
6527   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6528   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6529   (eval $gmp_compile) 2>&5
6530   ac_status=$?
6531   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6532   (exit $ac_status); }; then
6533     cc_works_part=yes
6534     if test "$cross_compiling" = no; then
6535       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6536   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6537   (eval $ac_try) 2>&5
6538   ac_status=$?
6539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6540   (exit $ac_status); }; }; then :;
6541       else
6542         cc_works_part=norun
6543       fi
6544     fi
6545   else
6546     cc_works_part=no
6547   fi
6548   if test "$cc_works_part" != yes; then
6549     echo "failed program was:" >&5
6550     cat conftest.c >&5
6551   fi
6552   rm -f conftest* a.out b.out a.exe a_out.exe
6553   case $cc_works_part in
6554     yes)
6555
6556       ;;
6557     no)
6558       gmp_prog_cc_works="no, long long reliability test 1"
6559       ;;
6560     norun)
6561       gmp_prog_cc_works="no, long long reliability test 1, program does not run"
6562       ;;
6563   esac
6564 fi
6565
6566
6567
6568
6569 if test "$gmp_prog_cc_works" = yes; then
6570   # remove anything that might look like compiler output to our "||" expression
6571   rm -f conftest* a.out b.out a.exe a_out.exe
6572   cat >conftest.c <<EOF
6573 /* The following provokes an internal compiler error on powerpc-apple-darwin.
6574    Extracted from mpz/cfdiv_q_2exp.c.  Causes Apple's gcc 3.3 build 1640 and
6575    1666 to get an ICE with -O1 -mpowerpc64.  */
6576
6577 #if defined (__GNUC__) && ! defined (__cplusplus)
6578 f(int u){int i;long long x;x=u?~0:0;if(x)for(i=0;i<9;i++);x&=g();if(x)g();}
6579 g(){}
6580 #else
6581 int dummy;
6582 #endif
6583
6584 int main () { return 0; }
6585 EOF
6586   echo "Test compile: long long reliability test 2" >&5
6587   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6588   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6589   (eval $gmp_compile) 2>&5
6590   ac_status=$?
6591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6592   (exit $ac_status); }; then
6593     cc_works_part=yes
6594     if test "$cross_compiling" = no; then
6595       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6596   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6597   (eval $ac_try) 2>&5
6598   ac_status=$?
6599   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6600   (exit $ac_status); }; }; then :;
6601       else
6602         cc_works_part=norun
6603       fi
6604     fi
6605   else
6606     cc_works_part=no
6607   fi
6608   if test "$cc_works_part" != yes; then
6609     echo "failed program was:" >&5
6610     cat conftest.c >&5
6611   fi
6612   rm -f conftest* a.out b.out a.exe a_out.exe
6613   case $cc_works_part in
6614     yes)
6615
6616       ;;
6617     no)
6618       gmp_prog_cc_works="no, long long reliability test 2"
6619       ;;
6620     norun)
6621       gmp_prog_cc_works="no, long long reliability test 2, program does not run"
6622       ;;
6623   esac
6624 fi
6625
6626
6627
6628
6629 if test "$gmp_prog_cc_works" = yes; then
6630   # remove anything that might look like compiler output to our "||" expression
6631   rm -f conftest* a.out b.out a.exe a_out.exe
6632   cat >conftest.c <<EOF
6633 /* The following is mis-compiled by HP ia-64 cc version
6634         cc: HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]
6635    under "cc +O3", both in +DD32 and +DD64 modes.  The mpn_lshift_com gets
6636    inlined and its return value somehow botched to be 0 instead of 1.  This
6637    arises in the real mpn_lshift_com in mul_fft.c.  A lower optimization
6638    level, like +O2 seems ok.  This code needs to be run to show the problem,
6639    but that's fine, the offending cc is a native-only compiler so we don't
6640    have to worry about cross compiling.  */
6641
6642 #if ! defined (__cplusplus)
6643 unsigned long
6644 lshift_com (rp, up, n, cnt)
6645   unsigned long *rp;
6646   unsigned long *up;
6647   long n;
6648   unsigned cnt;
6649 {
6650   unsigned long retval, high_limb, low_limb;
6651   unsigned tnc;
6652   long i;
6653   tnc = 8 * sizeof (unsigned long) - cnt;
6654   low_limb = *up++;
6655   retval = low_limb >> tnc;
6656   high_limb = low_limb << cnt;
6657   for (i = n - 1; i != 0; i--)
6658     {
6659       low_limb = *up++;
6660       *rp++ = ~(high_limb | (low_limb >> tnc));
6661       high_limb = low_limb << cnt;
6662     }
6663   return retval;
6664 }
6665 int
6666 main ()
6667 {
6668   unsigned long cy, rp[2], up[2];
6669   up[0] = ~ 0L;
6670   up[1] = 0;
6671   cy = lshift_com (rp, up, 2L, 1);
6672   if (cy != 1L)
6673     return 1;
6674   return 0;
6675 }
6676 #else
6677 int
6678 main ()
6679 {
6680   return 0;
6681 }
6682 #endif
6683
6684 EOF
6685   echo "Test compile: mpn_lshift_com optimization" >&5
6686   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6687   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6688   (eval $gmp_compile) 2>&5
6689   ac_status=$?
6690   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6691   (exit $ac_status); }; then
6692     cc_works_part=yes
6693     if test "$cross_compiling" = no; then
6694       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6695   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6696   (eval $ac_try) 2>&5
6697   ac_status=$?
6698   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6699   (exit $ac_status); }; }; then :;
6700       else
6701         cc_works_part=norun
6702       fi
6703     fi
6704   else
6705     cc_works_part=no
6706   fi
6707   if test "$cc_works_part" != yes; then
6708     echo "failed program was:" >&5
6709     cat conftest.c >&5
6710   fi
6711   rm -f conftest* a.out b.out a.exe a_out.exe
6712   case $cc_works_part in
6713     yes)
6714
6715       ;;
6716     no)
6717       gmp_prog_cc_works="no, mpn_lshift_com optimization"
6718       ;;
6719     norun)
6720       gmp_prog_cc_works="no, mpn_lshift_com optimization, program does not run"
6721       ;;
6722   esac
6723 fi
6724
6725
6726
6727 if test "$gmp_prog_cc_works" = yes; then
6728   # remove anything that might look like compiler output to our "||" expression
6729   rm -f conftest* a.out b.out a.exe a_out.exe
6730   cat >conftest.c <<EOF
6731 /* The following is mis-compiled by Intel ia-64 icc version 1.8 under
6732     "icc -O3",  After several calls, the function writes parial garbage to
6733     the result vector.  Perhaps relates to the chk.a.nc insn.  This code needs
6734     to be run to show the problem, but that's fine, the offending cc is a
6735     native-only compiler so we don't have to worry about cross compiling.  */
6736
6737 #if ! defined (__cplusplus)
6738 #include <stdlib.h>
6739 void
6740 lshift_com (rp, up, n, cnt)
6741   unsigned long *rp;
6742   unsigned long *up;
6743   long n;
6744   unsigned cnt;
6745 {
6746   unsigned long high_limb, low_limb;
6747   unsigned tnc;
6748   long i;
6749   up += n;
6750   rp += n;
6751   tnc = 8 * sizeof (unsigned long) - cnt;
6752   low_limb = *--up;
6753   high_limb = low_limb << cnt;
6754   for (i = n - 1; i != 0; i--)
6755     {
6756       low_limb = *--up;
6757       *--rp = ~(high_limb | (low_limb >> tnc));
6758       high_limb = low_limb << cnt;
6759     }
6760   *--rp = ~high_limb;
6761 }
6762 int
6763 main ()
6764 {
6765   unsigned long *r, *r2;
6766   unsigned long a[88 + 1];
6767   long i;
6768   for (i = 0; i < 88 + 1; i++)
6769     a[i] = ~0L;
6770   r = malloc (10000 * sizeof (unsigned long));
6771   r2 = r;
6772   for (i = 0; i < 528; i += 22)
6773     {
6774       lshift_com (r2, a,
6775                   i / (8 * sizeof (unsigned long)) + 1,
6776                   i % (8 * sizeof (unsigned long)));
6777       r2 += 88 + 1;
6778     }
6779   if (r[2048] != 0 || r[2049] != 0 || r[2050] != 0 || r[2051] != 0 ||
6780       r[2052] != 0 || r[2053] != 0 || r[2054] != 0)
6781     abort ();
6782   return 0;
6783 }
6784 #else
6785 int
6786 main ()
6787 {
6788   return 0;
6789 }
6790 #endif
6791
6792 EOF
6793   echo "Test compile: mpn_lshift_com optimization 2" >&5
6794   gmp_compile="$cc $cflags $cppflags $flag conftest.c >&5"
6795   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6796   (eval $gmp_compile) 2>&5
6797   ac_status=$?
6798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6799   (exit $ac_status); }; then
6800     cc_works_part=yes
6801     if test "$cross_compiling" = no; then
6802       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
6803   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6804   (eval $ac_try) 2>&5
6805   ac_status=$?
6806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6807   (exit $ac_status); }; }; then :;
6808       else
6809         cc_works_part=norun
6810       fi
6811     fi
6812   else
6813     cc_works_part=no
6814   fi
6815   if test "$cc_works_part" != yes; then
6816     echo "failed program was:" >&5
6817     cat conftest.c >&5
6818   fi
6819   rm -f conftest* a.out b.out a.exe a_out.exe
6820   case $cc_works_part in
6821     yes)
6822
6823       ;;
6824     no)
6825       gmp_prog_cc_works="no, mpn_lshift_com optimization 2"
6826       ;;
6827     norun)
6828       gmp_prog_cc_works="no, mpn_lshift_com optimization 2, program does not run"
6829       ;;
6830   esac
6831 fi
6832
6833
6834
6835
6836 # A certain _GLOBAL_OFFSET_TABLE_ problem in past versions of gas, tickled
6837 # by recent versions of gcc.
6838 #
6839 if test "$gmp_prog_cc_works" = yes; then
6840   case $host in
6841     i?86*-*-* | k[5-8]*-*-* | pentium*-*-* | athlon-*-* | viac3*-*-* | geode*-*-*)
6842       # this problem only arises in PIC code, so don't need to test when
6843       # --disable-shared.  We don't necessarily have $enable_shared set to
6844       # yes at this point, it will still be unset for the default (which is
6845       # yes); hence the use of "!= no".
6846       if test "$enable_shared" != no; then
6847         echo "Testing gcc GOT with eax emitted" >&5
6848 cat >conftest.c <<\EOF
6849 int foo;
6850 int bar () { return foo; }
6851 EOF
6852 tmp_got_emitted=no
6853 gmp_compile="$cc $cflags $cppflags $flag -fPIC -S conftest.c >&5 2>&1"
6854 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6855   (eval $gmp_compile) 2>&5
6856   ac_status=$?
6857   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6858   (exit $ac_status); }; then
6859   if grep "addl.*_GLOBAL_OFFSET_TABLE_.*eax" conftest.s >/dev/null; then
6860     tmp_got_emitted=yes
6861   fi
6862 fi
6863 rm -f conftest.*
6864 echo "Result: $tmp_got_emitted" >&5
6865 if test "$tmp_got_emitted" = yes; then
6866   echo "Testing gas GOT with eax good" >&5
6867 cat >conftest.awk <<\EOF
6868 BEGIN {
6869   want[0]  = "001"
6870   want[1]  = "043"
6871   want[2]  = "105"
6872   want[3]  = "147"
6873   want[4]  = "211"
6874   want[5]  = "253"
6875   want[6]  = "315"
6876   want[7]  = "357"
6877
6878   want[8]  = "005"
6879   want[9]  = "002"
6880   want[10] = "000"
6881   want[11] = "000"
6882   want[12] = "000"
6883
6884   want[13] = "376"
6885   want[14] = "334"
6886   want[15] = "272"
6887   want[16] = "230"
6888   want[17] = "166"
6889   want[18] = "124"
6890   want[19] = "062"
6891   want[20] = "020"
6892
6893   result = "yes"
6894 }
6895 {
6896   for (f = 2; f <= NF; f++)
6897     {
6898       for (i = 0; i < 20; i++)
6899         got[i] = got[i+1];
6900       got[20] = $f;
6901
6902       found = 1
6903       for (i = 0; i < 21; i++)
6904         if (got[i] != want[i])
6905           {
6906             found = 0
6907             break
6908           }
6909       if (found)
6910         {
6911           result = "no"
6912           exit
6913         }
6914     }
6915 }
6916 END {
6917   print result
6918 }
6919 EOF
6920 cat >conftest.s <<\EOF
6921         .text
6922         .byte   1, 35, 69, 103, 137, 171, 205, 239
6923         addl    $_GLOBAL_OFFSET_TABLE_, %eax
6924         .byte   254, 220, 186, 152, 118, 84, 50, 16
6925 EOF
6926 tmp_got_good=yes
6927 gmp_compile="$cc $cflags $cppflags $flag -fPIC -o conftest.o -c conftest.s >&5 2>&1"
6928 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
6929   (eval $gmp_compile) 2>&5
6930   ac_status=$?
6931   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6932   (exit $ac_status); }; then
6933   tmp_got_good=`od -b conftest.o | $AWK -f conftest.awk`
6934 fi
6935 rm -f conftest.*
6936 echo "Result: $tmp_got_good" >&5
6937 if test "$tmp_got_good" = no; then
6938   gmp_prog_cc_works="no, bad gas GOT with eax"
6939 else
6940   :
6941 fi
6942
6943 else
6944   :
6945 fi
6946
6947       fi
6948       ;;
6949   esac
6950 fi
6951
6952 { echo "$as_me:$LINENO: result: $gmp_prog_cc_works" >&5
6953 echo "${ECHO_T}$gmp_prog_cc_works" >&6; }
6954 case $gmp_prog_cc_works in
6955   yes)
6956     cflags="$cflags $flag"
6957           break
6958     ;;
6959   *)
6960
6961     ;;
6962 esac
6963
6964       done
6965     done
6966   fi
6967
6968   ABI="$abi"
6969   CC="$cc"
6970   CFLAGS="$cflags"
6971   CPPFLAGS="$cppflags"
6972
6973
6974   # Could easily have this in config.h too, if desired.
6975   ABI_nodots=`echo $ABI | sed 's/\./_/'`
6976
6977 echo "define_not_for_expansion(\`HAVE_ABI_$ABI_nodots')" >> $gmp_tmpconfigm4p
6978
6979
6980
6981   # GMP_LDFLAGS substitution, selected according to ABI.
6982   # These are needed on libgmp.la and libmp.la, but currently not on
6983   # convenience libraries like tune/libspeed.la or mpz/libmpz.la.
6984   #
6985                             eval GMP_LDFLAGS=\"\$${ccbase}${abi1}_ldflags\"
6986   test -n "$GMP_LDFLAGS" || eval GMP_LDFLAGS=\"\$${ccbase}${abi1}_ldflags\"
6987
6988
6989
6990
6991   # extra_functions, selected according to ABI
6992                     eval tmp=\"\$extra_functions$abi1\"
6993   test -n "$tmp" || eval tmp=\"\$extra_functions$abi2\"
6994   extra_functions="$tmp"
6995
6996
6997   # Cycle counter, selected according to ABI.
6998   #
6999                     eval tmp=\"\$SPEED_CYCLECOUNTER_OBJ$abi1\"
7000   test -n "$tmp" || eval tmp=\"\$SPEED_CYCLECOUNTER_OBJ$abi2\"
7001   SPEED_CYCLECOUNTER_OBJ="$tmp"
7002                     eval tmp=\"\$cyclecounter_size$abi1\"
7003   test -n "$tmp" || eval tmp=\"\$cyclecounter_size$abi2\"
7004   cyclecounter_size="$tmp"
7005
7006   if test -n "$SPEED_CYCLECOUNTER_OBJ"; then
7007
7008 cat >>confdefs.h <<_ACEOF
7009 #define HAVE_SPEED_CYCLECOUNTER $cyclecounter_size
7010 _ACEOF
7011
7012   fi
7013
7014
7015
7016   # Calling conventions checking, selected according to ABI.
7017   #
7018                     eval tmp=\"\$CALLING_CONVENTIONS_OBJS$abi1\"
7019   test -n "$tmp" || eval tmp=\"\$CALLING_CONVENTIONS_OBJS$abi2\"
7020   CALLING_CONVENTIONS_OBJS="$tmp"
7021
7022   if test -n "$CALLING_CONVENTIONS_OBJS"; then
7023
7024 cat >>confdefs.h <<\_ACEOF
7025 #define HAVE_CALLING_CONVENTIONS 1
7026 _ACEOF
7027
7028   fi
7029
7030
7031 fi
7032
7033
7034 # If the user gave an MPN_PATH, use that verbatim, otherwise choose
7035 # according to the ABI and add "generic".
7036 #
7037 if test -n "$MPN_PATH"; then
7038   path="$MPN_PATH"
7039 else
7040                     eval tmp=\"\$path$abi1\"
7041   test -n "$tmp" || eval tmp=\"\$path$abi2\"
7042   path="$tmp generic"
7043 fi
7044
7045
7046 # Long long limb setup for gmp.h.
7047 case $limb_chosen in
7048 longlong) DEFN_LONG_LONG_LIMB="#define _LONG_LONG_LIMB 1"    ;;
7049 *)        DEFN_LONG_LONG_LIMB="/* #undef _LONG_LONG_LIMB */" ;;
7050 esac
7051
7052
7053
7054 # The C compiler and preprocessor, put into ANSI mode if possible.
7055 ac_ext=c
7056 ac_cpp='$CPP $CPPFLAGS'
7057 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7058 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7059 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7060 if test -n "$ac_tool_prefix"; then
7061   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
7062 set dummy ${ac_tool_prefix}gcc; ac_word=$2
7063 { echo "$as_me:$LINENO: checking for $ac_word" >&5
7064 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
7065 if test "${ac_cv_prog_CC+set}" = set; then
7066   echo $ECHO_N "(cached) $ECHO_C" >&6
7067 else
7068   if test -n "$CC"; then
7069   ac_cv_prog_CC="$CC" # Let the user override the test.
7070 else
7071 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7072 for as_dir in $PATH
7073 do
7074   IFS=$as_save_IFS
7075   test -z "$as_dir" && as_dir=.
7076   for ac_exec_ext in '' $ac_executable_extensions; do
7077   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7078     ac_cv_prog_CC="${ac_tool_prefix}gcc"
7079     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7080     break 2
7081   fi
7082 done
7083 done
7084 IFS=$as_save_IFS
7085
7086 fi
7087 fi
7088 CC=$ac_cv_prog_CC
7089 if test -n "$CC"; then
7090   { echo "$as_me:$LINENO: result: $CC" >&5
7091 echo "${ECHO_T}$CC" >&6; }
7092 else
7093   { echo "$as_me:$LINENO: result: no" >&5
7094 echo "${ECHO_T}no" >&6; }
7095 fi
7096
7097
7098 fi
7099 if test -z "$ac_cv_prog_CC"; then
7100   ac_ct_CC=$CC
7101   # Extract the first word of "gcc", so it can be a program name with args.
7102 set dummy gcc; ac_word=$2
7103 { echo "$as_me:$LINENO: checking for $ac_word" >&5
7104 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
7105 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
7106   echo $ECHO_N "(cached) $ECHO_C" >&6
7107 else
7108   if test -n "$ac_ct_CC"; then
7109   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
7110 else
7111 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7112 for as_dir in $PATH
7113 do
7114   IFS=$as_save_IFS
7115   test -z "$as_dir" && as_dir=.
7116   for ac_exec_ext in '' $ac_executable_extensions; do
7117   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7118     ac_cv_prog_ac_ct_CC="gcc"
7119     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7120     break 2
7121   fi
7122 done
7123 done
7124 IFS=$as_save_IFS
7125
7126 fi
7127 fi
7128 ac_ct_CC=$ac_cv_prog_ac_ct_CC
7129 if test -n "$ac_ct_CC"; then
7130   { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
7131 echo "${ECHO_T}$ac_ct_CC" >&6; }
7132 else
7133   { echo "$as_me:$LINENO: result: no" >&5
7134 echo "${ECHO_T}no" >&6; }
7135 fi
7136
7137   if test "x$ac_ct_CC" = x; then
7138     CC=""
7139   else
7140     case $cross_compiling:$ac_tool_warned in
7141 yes:)
7142 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
7143 whose name does not start with the host triplet.  If you think this
7144 configuration is useful to you, please write to autoconf@gnu.org." >&5
7145 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
7146 whose name does not start with the host triplet.  If you think this
7147 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
7148 ac_tool_warned=yes ;;
7149 esac
7150     CC=$ac_ct_CC
7151   fi
7152 else
7153   CC="$ac_cv_prog_CC"
7154 fi
7155
7156 if test -z "$CC"; then
7157           if test -n "$ac_tool_prefix"; then
7158     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
7159 set dummy ${ac_tool_prefix}cc; ac_word=$2
7160 { echo "$as_me:$LINENO: checking for $ac_word" >&5
7161 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
7162 if test "${ac_cv_prog_CC+set}" = set; then
7163   echo $ECHO_N "(cached) $ECHO_C" >&6
7164 else
7165   if test -n "$CC"; then
7166   ac_cv_prog_CC="$CC" # Let the user override the test.
7167 else
7168 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7169 for as_dir in $PATH
7170 do
7171   IFS=$as_save_IFS
7172   test -z "$as_dir" && as_dir=.
7173   for ac_exec_ext in '' $ac_executable_extensions; do
7174   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7175     ac_cv_prog_CC="${ac_tool_prefix}cc"
7176     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7177     break 2
7178   fi
7179 done
7180 done
7181 IFS=$as_save_IFS
7182
7183 fi
7184 fi
7185 CC=$ac_cv_prog_CC
7186 if test -n "$CC"; then
7187   { echo "$as_me:$LINENO: result: $CC" >&5
7188 echo "${ECHO_T}$CC" >&6; }
7189 else
7190   { echo "$as_me:$LINENO: result: no" >&5
7191 echo "${ECHO_T}no" >&6; }
7192 fi
7193
7194
7195   fi
7196 fi
7197 if test -z "$CC"; then
7198   # Extract the first word of "cc", so it can be a program name with args.
7199 set dummy cc; ac_word=$2
7200 { echo "$as_me:$LINENO: checking for $ac_word" >&5
7201 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
7202 if test "${ac_cv_prog_CC+set}" = set; then
7203   echo $ECHO_N "(cached) $ECHO_C" >&6
7204 else
7205   if test -n "$CC"; then
7206   ac_cv_prog_CC="$CC" # Let the user override the test.
7207 else
7208   ac_prog_rejected=no
7209 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7210 for as_dir in $PATH
7211 do
7212   IFS=$as_save_IFS
7213   test -z "$as_dir" && as_dir=.
7214   for ac_exec_ext in '' $ac_executable_extensions; do
7215   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7216     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
7217        ac_prog_rejected=yes
7218        continue
7219      fi
7220     ac_cv_prog_CC="cc"
7221     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7222     break 2
7223   fi
7224 done
7225 done
7226 IFS=$as_save_IFS
7227
7228 if test $ac_prog_rejected = yes; then
7229   # We found a bogon in the path, so make sure we never use it.
7230   set dummy $ac_cv_prog_CC
7231   shift
7232   if test $# != 0; then
7233     # We chose a different compiler from the bogus one.
7234     # However, it has the same basename, so the bogon will be chosen
7235     # first if we set CC to just the basename; use the full file name.
7236     shift
7237     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
7238   fi
7239 fi
7240 fi
7241 fi
7242 CC=$ac_cv_prog_CC
7243 if test -n "$CC"; then
7244   { echo "$as_me:$LINENO: result: $CC" >&5
7245 echo "${ECHO_T}$CC" >&6; }
7246 else
7247   { echo "$as_me:$LINENO: result: no" >&5
7248 echo "${ECHO_T}no" >&6; }
7249 fi
7250
7251
7252 fi
7253 if test -z "$CC"; then
7254   if test -n "$ac_tool_prefix"; then
7255   for ac_prog in cl.exe
7256   do
7257     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7258 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7259 { echo "$as_me:$LINENO: checking for $ac_word" >&5
7260 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
7261 if test "${ac_cv_prog_CC+set}" = set; then
7262   echo $ECHO_N "(cached) $ECHO_C" >&6
7263 else
7264   if test -n "$CC"; then
7265   ac_cv_prog_CC="$CC" # Let the user override the test.
7266 else
7267 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7268 for as_dir in $PATH
7269 do
7270   IFS=$as_save_IFS
7271   test -z "$as_dir" && as_dir=.
7272   for ac_exec_ext in '' $ac_executable_extensions; do
7273   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7274     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
7275     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7276     break 2
7277   fi
7278 done
7279 done
7280 IFS=$as_save_IFS
7281
7282 fi
7283 fi
7284 CC=$ac_cv_prog_CC
7285 if test -n "$CC"; then
7286   { echo "$as_me:$LINENO: result: $CC" >&5
7287 echo "${ECHO_T}$CC" >&6; }
7288 else
7289   { echo "$as_me:$LINENO: result: no" >&5
7290 echo "${ECHO_T}no" >&6; }
7291 fi
7292
7293
7294     test -n "$CC" && break
7295   done
7296 fi
7297 if test -z "$CC"; then
7298   ac_ct_CC=$CC
7299   for ac_prog in cl.exe
7300 do
7301   # Extract the first word of "$ac_prog", so it can be a program name with args.
7302 set dummy $ac_prog; ac_word=$2
7303 { echo "$as_me:$LINENO: checking for $ac_word" >&5
7304 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
7305 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
7306   echo $ECHO_N "(cached) $ECHO_C" >&6
7307 else
7308   if test -n "$ac_ct_CC"; then
7309   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
7310 else
7311 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7312 for as_dir in $PATH
7313 do
7314   IFS=$as_save_IFS
7315   test -z "$as_dir" && as_dir=.
7316   for ac_exec_ext in '' $ac_executable_extensions; do
7317   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7318     ac_cv_prog_ac_ct_CC="$ac_prog"
7319     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7320     break 2
7321   fi
7322 done
7323 done
7324 IFS=$as_save_IFS
7325
7326 fi
7327 fi
7328 ac_ct_CC=$ac_cv_prog_ac_ct_CC
7329 if test -n "$ac_ct_CC"; then
7330   { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
7331 echo "${ECHO_T}$ac_ct_CC" >&6; }
7332 else
7333   { echo "$as_me:$LINENO: result: no" >&5
7334 echo "${ECHO_T}no" >&6; }
7335 fi
7336
7337
7338   test -n "$ac_ct_CC" && break
7339 done
7340
7341   if test "x$ac_ct_CC" = x; then
7342     CC=""
7343   else
7344     case $cross_compiling:$ac_tool_warned in
7345 yes:)
7346 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
7347 whose name does not start with the host triplet.  If you think this
7348 configuration is useful to you, please write to autoconf@gnu.org." >&5
7349 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
7350 whose name does not start with the host triplet.  If you think this
7351 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
7352 ac_tool_warned=yes ;;
7353 esac
7354     CC=$ac_ct_CC
7355   fi
7356 fi
7357
7358 fi
7359
7360
7361 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
7362 See \`config.log' for more details." >&5
7363 echo "$as_me: error: no acceptable C compiler found in \$PATH
7364 See \`config.log' for more details." >&2;}
7365    { (exit 1); exit 1; }; }
7366
7367 # Provide some information about the compiler.
7368 echo "$as_me:$LINENO: checking for C compiler version" >&5
7369 ac_compiler=`set X $ac_compile; echo $2`
7370 { (ac_try="$ac_compiler --version >&5"
7371 case "(($ac_try" in
7372   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7373   *) ac_try_echo=$ac_try;;
7374 esac
7375 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7376   (eval "$ac_compiler --version >&5") 2>&5
7377   ac_status=$?
7378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7379   (exit $ac_status); }
7380 { (ac_try="$ac_compiler -v >&5"
7381 case "(($ac_try" in
7382   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7383   *) ac_try_echo=$ac_try;;
7384 esac
7385 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7386   (eval "$ac_compiler -v >&5") 2>&5
7387   ac_status=$?
7388   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7389   (exit $ac_status); }
7390 { (ac_try="$ac_compiler -V >&5"
7391 case "(($ac_try" in
7392   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7393   *) ac_try_echo=$ac_try;;
7394 esac
7395 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7396   (eval "$ac_compiler -V >&5") 2>&5
7397   ac_status=$?
7398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7399   (exit $ac_status); }
7400
7401 cat >conftest.$ac_ext <<_ACEOF
7402 /* confdefs.h.  */
7403 _ACEOF
7404 cat confdefs.h >>conftest.$ac_ext
7405 cat >>conftest.$ac_ext <<_ACEOF
7406 /* end confdefs.h.  */
7407
7408 int
7409 main ()
7410 {
7411
7412   ;
7413   return 0;
7414 }
7415 _ACEOF
7416 ac_clean_files_save=$ac_clean_files
7417 ac_clean_files="$ac_clean_files a.out a.exe b.out"
7418 # Try to create an executable without -o first, disregard a.out.
7419 # It will help us diagnose broken compilers, and finding out an intuition
7420 # of exeext.
7421 { echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
7422 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; }
7423 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
7424 #
7425 # List of possible output files, starting from the most likely.
7426 # The algorithm is not robust to junk in `.', hence go to wildcards (a.*)
7427 # only as a last resort.  b.out is created by i960 compilers.
7428 ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out'
7429 #
7430 # The IRIX 6 linker writes into existing files which may not be
7431 # executable, retaining their permissions.  Remove them first so a
7432 # subsequent execution test works.
7433 ac_rmfiles=
7434 for ac_file in $ac_files
7435 do
7436   case $ac_file in
7437     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
7438     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
7439   esac
7440 done
7441 rm -f $ac_rmfiles
7442
7443 if { (ac_try="$ac_link_default"
7444 case "(($ac_try" in
7445   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7446   *) ac_try_echo=$ac_try;;
7447 esac
7448 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7449   (eval "$ac_link_default") 2>&5
7450   ac_status=$?
7451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7452   (exit $ac_status); }; then
7453   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
7454 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
7455 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
7456 # so that the user can short-circuit this test for compilers unknown to
7457 # Autoconf.
7458 for ac_file in $ac_files ''
7459 do
7460   test -f "$ac_file" || continue
7461   case $ac_file in
7462     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj )
7463         ;;
7464     [ab].out )
7465         # We found the default executable, but exeext='' is most
7466         # certainly right.
7467         break;;
7468     *.* )
7469         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
7470         then :; else
7471            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
7472         fi
7473         # We set ac_cv_exeext here because the later test for it is not
7474         # safe: cross compilers may not add the suffix if given an `-o'
7475         # argument, so we may need to know it at that point already.
7476         # Even if this section looks crufty: it has the advantage of
7477         # actually working.
7478         break;;
7479     * )
7480         break;;
7481   esac
7482 done
7483 test "$ac_cv_exeext" = no && ac_cv_exeext=
7484
7485 else
7486   ac_file=''
7487 fi
7488
7489 { echo "$as_me:$LINENO: result: $ac_file" >&5
7490 echo "${ECHO_T}$ac_file" >&6; }
7491 if test -z "$ac_file"; then
7492   echo "$as_me: failed program was:" >&5
7493 sed 's/^/| /' conftest.$ac_ext >&5
7494
7495 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
7496 See \`config.log' for more details." >&5
7497 echo "$as_me: error: C compiler cannot create executables
7498 See \`config.log' for more details." >&2;}
7499    { (exit 77); exit 77; }; }
7500 fi
7501
7502 ac_exeext=$ac_cv_exeext
7503
7504 # Check that the compiler produces executables we can run.  If not, either
7505 # the compiler is broken, or we cross compile.
7506 { echo "$as_me:$LINENO: checking whether the C compiler works" >&5
7507 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; }
7508 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
7509 # If not cross compiling, check that we can run a simple program.
7510 if test "$cross_compiling" != yes; then
7511   if { ac_try='./$ac_file'
7512   { (case "(($ac_try" in
7513   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7514   *) ac_try_echo=$ac_try;;
7515 esac
7516 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7517   (eval "$ac_try") 2>&5
7518   ac_status=$?
7519   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7520   (exit $ac_status); }; }; then
7521     cross_compiling=no
7522   else
7523     if test "$cross_compiling" = maybe; then
7524         cross_compiling=yes
7525     else
7526         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
7527 If you meant to cross compile, use \`--host'.
7528 See \`config.log' for more details." >&5
7529 echo "$as_me: error: cannot run C compiled programs.
7530 If you meant to cross compile, use \`--host'.
7531 See \`config.log' for more details." >&2;}
7532    { (exit 1); exit 1; }; }
7533     fi
7534   fi
7535 fi
7536 { echo "$as_me:$LINENO: result: yes" >&5
7537 echo "${ECHO_T}yes" >&6; }
7538
7539 rm -f a.out a.exe conftest$ac_cv_exeext b.out
7540 ac_clean_files=$ac_clean_files_save
7541 # Check that the compiler produces executables we can run.  If not, either
7542 # the compiler is broken, or we cross compile.
7543 { echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
7544 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; }
7545 { echo "$as_me:$LINENO: result: $cross_compiling" >&5
7546 echo "${ECHO_T}$cross_compiling" >&6; }
7547
7548 { echo "$as_me:$LINENO: checking for suffix of executables" >&5
7549 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; }
7550 if { (ac_try="$ac_link"
7551 case "(($ac_try" in
7552   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7553   *) ac_try_echo=$ac_try;;
7554 esac
7555 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7556   (eval "$ac_link") 2>&5
7557   ac_status=$?
7558   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7559   (exit $ac_status); }; then
7560   # If both `conftest.exe' and `conftest' are `present' (well, observable)
7561 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
7562 # work properly (i.e., refer to `conftest.exe'), while it won't with
7563 # `rm'.
7564 for ac_file in conftest.exe conftest conftest.*; do
7565   test -f "$ac_file" || continue
7566   case $ac_file in
7567     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
7568     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
7569           break;;
7570     * ) break;;
7571   esac
7572 done
7573 else
7574   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
7575 See \`config.log' for more details." >&5
7576 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
7577 See \`config.log' for more details." >&2;}
7578    { (exit 1); exit 1; }; }
7579 fi
7580
7581 rm -f conftest$ac_cv_exeext
7582 { echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
7583 echo "${ECHO_T}$ac_cv_exeext" >&6; }
7584
7585 rm -f conftest.$ac_ext
7586 EXEEXT=$ac_cv_exeext
7587 ac_exeext=$EXEEXT
7588 { echo "$as_me:$LINENO: checking for suffix of object files" >&5
7589 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; }
7590 if test "${ac_cv_objext+set}" = set; then
7591   echo $ECHO_N "(cached) $ECHO_C" >&6
7592 else
7593   cat >conftest.$ac_ext <<_ACEOF
7594 /* confdefs.h.  */
7595 _ACEOF
7596 cat confdefs.h >>conftest.$ac_ext
7597 cat >>conftest.$ac_ext <<_ACEOF
7598 /* end confdefs.h.  */
7599
7600 int
7601 main ()
7602 {
7603
7604   ;
7605   return 0;
7606 }
7607 _ACEOF
7608 rm -f conftest.o conftest.obj
7609 if { (ac_try="$ac_compile"
7610 case "(($ac_try" in
7611   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7612   *) ac_try_echo=$ac_try;;
7613 esac
7614 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7615   (eval "$ac_compile") 2>&5
7616   ac_status=$?
7617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7618   (exit $ac_status); }; then
7619   for ac_file in conftest.o conftest.obj conftest.*; do
7620   test -f "$ac_file" || continue;
7621   case $ac_file in
7622     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;;
7623     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
7624        break;;
7625   esac
7626 done
7627 else
7628   echo "$as_me: failed program was:" >&5
7629 sed 's/^/| /' conftest.$ac_ext >&5
7630
7631 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
7632 See \`config.log' for more details." >&5
7633 echo "$as_me: error: cannot compute suffix of object files: cannot compile
7634 See \`config.log' for more details." >&2;}
7635    { (exit 1); exit 1; }; }
7636 fi
7637
7638 rm -f conftest.$ac_cv_objext conftest.$ac_ext
7639 fi
7640 { echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
7641 echo "${ECHO_T}$ac_cv_objext" >&6; }
7642 OBJEXT=$ac_cv_objext
7643 ac_objext=$OBJEXT
7644 { echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
7645 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; }
7646 if test "${ac_cv_c_compiler_gnu+set}" = set; then
7647   echo $ECHO_N "(cached) $ECHO_C" >&6
7648 else
7649   cat >conftest.$ac_ext <<_ACEOF
7650 /* confdefs.h.  */
7651 _ACEOF
7652 cat confdefs.h >>conftest.$ac_ext
7653 cat >>conftest.$ac_ext <<_ACEOF
7654 /* end confdefs.h.  */
7655
7656 int
7657 main ()
7658 {
7659 #ifndef __GNUC__
7660        choke me
7661 #endif
7662
7663   ;
7664   return 0;
7665 }
7666 _ACEOF
7667 rm -f conftest.$ac_objext
7668 if { (ac_try="$ac_compile"
7669 case "(($ac_try" in
7670   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7671   *) ac_try_echo=$ac_try;;
7672 esac
7673 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7674   (eval "$ac_compile") 2>conftest.er1
7675   ac_status=$?
7676   grep -v '^ *+' conftest.er1 >conftest.err
7677   rm -f conftest.er1
7678   cat conftest.err >&5
7679   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7680   (exit $ac_status); } && {
7681          test -z "$ac_c_werror_flag" ||
7682          test ! -s conftest.err
7683        } && test -s conftest.$ac_objext; then
7684   ac_compiler_gnu=yes
7685 else
7686   echo "$as_me: failed program was:" >&5
7687 sed 's/^/| /' conftest.$ac_ext >&5
7688
7689         ac_compiler_gnu=no
7690 fi
7691
7692 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7693 ac_cv_c_compiler_gnu=$ac_compiler_gnu
7694
7695 fi
7696 { echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
7697 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; }
7698 GCC=`test $ac_compiler_gnu = yes && echo yes`
7699 ac_test_CFLAGS=${CFLAGS+set}
7700 ac_save_CFLAGS=$CFLAGS
7701 { echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
7702 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; }
7703 if test "${ac_cv_prog_cc_g+set}" = set; then
7704   echo $ECHO_N "(cached) $ECHO_C" >&6
7705 else
7706   ac_save_c_werror_flag=$ac_c_werror_flag
7707    ac_c_werror_flag=yes
7708    ac_cv_prog_cc_g=no
7709    CFLAGS="-g"
7710    cat >conftest.$ac_ext <<_ACEOF
7711 /* confdefs.h.  */
7712 _ACEOF
7713 cat confdefs.h >>conftest.$ac_ext
7714 cat >>conftest.$ac_ext <<_ACEOF
7715 /* end confdefs.h.  */
7716
7717 int
7718 main ()
7719 {
7720
7721   ;
7722   return 0;
7723 }
7724 _ACEOF
7725 rm -f conftest.$ac_objext
7726 if { (ac_try="$ac_compile"
7727 case "(($ac_try" in
7728   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7729   *) ac_try_echo=$ac_try;;
7730 esac
7731 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7732   (eval "$ac_compile") 2>conftest.er1
7733   ac_status=$?
7734   grep -v '^ *+' conftest.er1 >conftest.err
7735   rm -f conftest.er1
7736   cat conftest.err >&5
7737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7738   (exit $ac_status); } && {
7739          test -z "$ac_c_werror_flag" ||
7740          test ! -s conftest.err
7741        } && test -s conftest.$ac_objext; then
7742   ac_cv_prog_cc_g=yes
7743 else
7744   echo "$as_me: failed program was:" >&5
7745 sed 's/^/| /' conftest.$ac_ext >&5
7746
7747         CFLAGS=""
7748       cat >conftest.$ac_ext <<_ACEOF
7749 /* confdefs.h.  */
7750 _ACEOF
7751 cat confdefs.h >>conftest.$ac_ext
7752 cat >>conftest.$ac_ext <<_ACEOF
7753 /* end confdefs.h.  */
7754
7755 int
7756 main ()
7757 {
7758
7759   ;
7760   return 0;
7761 }
7762 _ACEOF
7763 rm -f conftest.$ac_objext
7764 if { (ac_try="$ac_compile"
7765 case "(($ac_try" in
7766   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7767   *) ac_try_echo=$ac_try;;
7768 esac
7769 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7770   (eval "$ac_compile") 2>conftest.er1
7771   ac_status=$?
7772   grep -v '^ *+' conftest.er1 >conftest.err
7773   rm -f conftest.er1
7774   cat conftest.err >&5
7775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7776   (exit $ac_status); } && {
7777          test -z "$ac_c_werror_flag" ||
7778          test ! -s conftest.err
7779        } && test -s conftest.$ac_objext; then
7780   :
7781 else
7782   echo "$as_me: failed program was:" >&5
7783 sed 's/^/| /' conftest.$ac_ext >&5
7784
7785         ac_c_werror_flag=$ac_save_c_werror_flag
7786          CFLAGS="-g"
7787          cat >conftest.$ac_ext <<_ACEOF
7788 /* confdefs.h.  */
7789 _ACEOF
7790 cat confdefs.h >>conftest.$ac_ext
7791 cat >>conftest.$ac_ext <<_ACEOF
7792 /* end confdefs.h.  */
7793
7794 int
7795 main ()
7796 {
7797
7798   ;
7799   return 0;
7800 }
7801 _ACEOF
7802 rm -f conftest.$ac_objext
7803 if { (ac_try="$ac_compile"
7804 case "(($ac_try" in
7805   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7806   *) ac_try_echo=$ac_try;;
7807 esac
7808 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7809   (eval "$ac_compile") 2>conftest.er1
7810   ac_status=$?
7811   grep -v '^ *+' conftest.er1 >conftest.err
7812   rm -f conftest.er1
7813   cat conftest.err >&5
7814   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7815   (exit $ac_status); } && {
7816          test -z "$ac_c_werror_flag" ||
7817          test ! -s conftest.err
7818        } && test -s conftest.$ac_objext; then
7819   ac_cv_prog_cc_g=yes
7820 else
7821   echo "$as_me: failed program was:" >&5
7822 sed 's/^/| /' conftest.$ac_ext >&5
7823
7824
7825 fi
7826
7827 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7828 fi
7829
7830 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7831 fi
7832
7833 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7834    ac_c_werror_flag=$ac_save_c_werror_flag
7835 fi
7836 { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
7837 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; }
7838 if test "$ac_test_CFLAGS" = set; then
7839   CFLAGS=$ac_save_CFLAGS
7840 elif test $ac_cv_prog_cc_g = yes; then
7841   if test "$GCC" = yes; then
7842     CFLAGS="-g -O2"
7843   else
7844     CFLAGS="-g"
7845   fi
7846 else
7847   if test "$GCC" = yes; then
7848     CFLAGS="-O2"
7849   else
7850     CFLAGS=
7851   fi
7852 fi
7853 { echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
7854 echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
7855 if test "${ac_cv_prog_cc_c89+set}" = set; then
7856   echo $ECHO_N "(cached) $ECHO_C" >&6
7857 else
7858   ac_cv_prog_cc_c89=no
7859 ac_save_CC=$CC
7860 cat >conftest.$ac_ext <<_ACEOF
7861 /* confdefs.h.  */
7862 _ACEOF
7863 cat confdefs.h >>conftest.$ac_ext
7864 cat >>conftest.$ac_ext <<_ACEOF
7865 /* end confdefs.h.  */
7866 #include <stdarg.h>
7867 #include <stdio.h>
7868 #include <sys/types.h>
7869 #include <sys/stat.h>
7870 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
7871 struct buf { int x; };
7872 FILE * (*rcsopen) (struct buf *, struct stat *, int);
7873 static char *e (p, i)
7874      char **p;
7875      int i;
7876 {
7877   return p[i];
7878 }
7879 static char *f (char * (*g) (char **, int), char **p, ...)
7880 {
7881   char *s;
7882   va_list v;
7883   va_start (v,p);
7884   s = g (p, va_arg (v,int));
7885   va_end (v);
7886   return s;
7887 }
7888
7889 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
7890    function prototypes and stuff, but not '\xHH' hex character constants.
7891    These don't provoke an error unfortunately, instead are silently treated
7892    as 'x'.  The following induces an error, until -std is added to get
7893    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
7894    array size at least.  It's necessary to write '\x00'==0 to get something
7895    that's true only with -std.  */
7896 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
7897
7898 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
7899    inside strings and character constants.  */
7900 #define FOO(x) 'x'
7901 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
7902
7903 int test (int i, double x);
7904 struct s1 {int (*f) (int a);};
7905 struct s2 {int (*f) (double a);};
7906 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
7907 int argc;
7908 char **argv;
7909 int
7910 main ()
7911 {
7912 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
7913   ;
7914   return 0;
7915 }
7916 _ACEOF
7917 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
7918         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
7919 do
7920   CC="$ac_save_CC $ac_arg"
7921   rm -f conftest.$ac_objext
7922 if { (ac_try="$ac_compile"
7923 case "(($ac_try" in
7924   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7925   *) ac_try_echo=$ac_try;;
7926 esac
7927 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7928   (eval "$ac_compile") 2>conftest.er1
7929   ac_status=$?
7930   grep -v '^ *+' conftest.er1 >conftest.err
7931   rm -f conftest.er1
7932   cat conftest.err >&5
7933   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7934   (exit $ac_status); } && {
7935          test -z "$ac_c_werror_flag" ||
7936          test ! -s conftest.err
7937        } && test -s conftest.$ac_objext; then
7938   ac_cv_prog_cc_c89=$ac_arg
7939 else
7940   echo "$as_me: failed program was:" >&5
7941 sed 's/^/| /' conftest.$ac_ext >&5
7942
7943
7944 fi
7945
7946 rm -f core conftest.err conftest.$ac_objext
7947   test "x$ac_cv_prog_cc_c89" != "xno" && break
7948 done
7949 rm -f conftest.$ac_ext
7950 CC=$ac_save_CC
7951
7952 fi
7953 # AC_CACHE_VAL
7954 case "x$ac_cv_prog_cc_c89" in
7955   x)
7956     { echo "$as_me:$LINENO: result: none needed" >&5
7957 echo "${ECHO_T}none needed" >&6; } ;;
7958   xno)
7959     { echo "$as_me:$LINENO: result: unsupported" >&5
7960 echo "${ECHO_T}unsupported" >&6; } ;;
7961   *)
7962     CC="$CC $ac_cv_prog_cc_c89"
7963     { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
7964 echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
7965 esac
7966
7967
7968 ac_ext=c
7969 ac_cpp='$CPP $CPPFLAGS'
7970 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7971 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7972 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7973
7974    case $ac_cv_prog_cc_stdc in
7975   no) ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;;
7976   *) { echo "$as_me:$LINENO: checking for $CC option to accept ISO C99" >&5
7977 echo $ECHO_N "checking for $CC option to accept ISO C99... $ECHO_C" >&6; }
7978 if test "${ac_cv_prog_cc_c99+set}" = set; then
7979   echo $ECHO_N "(cached) $ECHO_C" >&6
7980 else
7981   ac_cv_prog_cc_c99=no
7982 ac_save_CC=$CC
7983 cat >conftest.$ac_ext <<_ACEOF
7984 /* confdefs.h.  */
7985 _ACEOF
7986 cat confdefs.h >>conftest.$ac_ext
7987 cat >>conftest.$ac_ext <<_ACEOF
7988 /* end confdefs.h.  */
7989 #include <stdarg.h>
7990 #include <stdbool.h>
7991 #include <stdlib.h>
7992 #include <wchar.h>
7993 #include <stdio.h>
7994
7995 // Check varargs macros.  These examples are taken from C99 6.10.3.5.
7996 #define debug(...) fprintf (stderr, __VA_ARGS__)
7997 #define showlist(...) puts (#__VA_ARGS__)
7998 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
7999 static void
8000 test_varargs_macros (void)
8001 {
8002   int x = 1234;
8003   int y = 5678;
8004   debug ("Flag");
8005   debug ("X = %d\n", x);
8006   showlist (The first, second, and third items.);
8007   report (x>y, "x is %d but y is %d", x, y);
8008 }
8009
8010 // Check long long types.
8011 #define BIG64 18446744073709551615ull
8012 #define BIG32 4294967295ul
8013 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
8014 #if !BIG_OK
8015   your preprocessor is broken;
8016 #endif
8017 #if BIG_OK
8018 #else
8019   your preprocessor is broken;
8020 #endif
8021 static long long int bignum = -9223372036854775807LL;
8022 static unsigned long long int ubignum = BIG64;
8023
8024 struct incomplete_array
8025 {
8026   int datasize;
8027   double data[];
8028 };
8029
8030 struct named_init {
8031   int number;
8032   const wchar_t *name;
8033   double average;
8034 };
8035
8036 typedef const char *ccp;
8037
8038 static inline int
8039 test_restrict (ccp restrict text)
8040 {
8041   // See if C++-style comments work.
8042   // Iterate through items via the restricted pointer.
8043   // Also check for declarations in for loops.
8044   for (unsigned int i = 0; *(text+i) != '\0'; ++i)
8045     continue;
8046   return 0;
8047 }
8048
8049 // Check varargs and va_copy.
8050 static void
8051 test_varargs (const char *format, ...)
8052 {
8053   va_list args;
8054   va_start (args, format);
8055   va_list args_copy;
8056   va_copy (args_copy, args);
8057
8058   const char *str;
8059   int number;
8060   float fnumber;
8061
8062   while (*format)
8063     {
8064       switch (*format++)
8065         {
8066         case 's': // string
8067           str = va_arg (args_copy, const char *);
8068           break;
8069         case 'd': // int
8070           number = va_arg (args_copy, int);
8071           break;
8072         case 'f': // float
8073           fnumber = va_arg (args_copy, double);
8074           break;
8075         default:
8076           break;
8077         }
8078     }
8079   va_end (args_copy);
8080   va_end (args);
8081 }
8082
8083 int
8084 main ()
8085 {
8086
8087   // Check bool.
8088   _Bool success = false;
8089
8090   // Check restrict.
8091   if (test_restrict ("String literal") == 0)
8092     success = true;
8093   char *restrict newvar = "Another string";
8094
8095   // Check varargs.
8096   test_varargs ("s, d' f .", "string", 65, 34.234);
8097   test_varargs_macros ();
8098
8099   // Check flexible array members.
8100   struct incomplete_array *ia =
8101     malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
8102   ia->datasize = 10;
8103   for (int i = 0; i < ia->datasize; ++i)
8104     ia->data[i] = i * 1.234;
8105
8106   // Check named initializers.
8107   struct named_init ni = {
8108     .number = 34,
8109     .name = L"Test wide string",
8110     .average = 543.34343,
8111   };
8112
8113   ni.number = 58;
8114
8115   int dynamic_array[ni.number];
8116   dynamic_array[ni.number - 1] = 543;
8117
8118   // work around unused variable warnings
8119   return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
8120           || dynamic_array[ni.number - 1] != 543);
8121
8122   ;
8123   return 0;
8124 }
8125 _ACEOF
8126 for ac_arg in '' -std=gnu99 -c99 -qlanglvl=extc99
8127 do
8128   CC="$ac_save_CC $ac_arg"
8129   rm -f conftest.$ac_objext
8130 if { (ac_try="$ac_compile"
8131 case "(($ac_try" in
8132   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8133   *) ac_try_echo=$ac_try;;
8134 esac
8135 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8136   (eval "$ac_compile") 2>conftest.er1
8137   ac_status=$?
8138   grep -v '^ *+' conftest.er1 >conftest.err
8139   rm -f conftest.er1
8140   cat conftest.err >&5
8141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8142   (exit $ac_status); } && {
8143          test -z "$ac_c_werror_flag" ||
8144          test ! -s conftest.err
8145        } && test -s conftest.$ac_objext; then
8146   ac_cv_prog_cc_c99=$ac_arg
8147 else
8148   echo "$as_me: failed program was:" >&5
8149 sed 's/^/| /' conftest.$ac_ext >&5
8150
8151
8152 fi
8153
8154 rm -f core conftest.err conftest.$ac_objext
8155   test "x$ac_cv_prog_cc_c99" != "xno" && break
8156 done
8157 rm -f conftest.$ac_ext
8158 CC=$ac_save_CC
8159
8160 fi
8161 # AC_CACHE_VAL
8162 case "x$ac_cv_prog_cc_c99" in
8163   x)
8164     { echo "$as_me:$LINENO: result: none needed" >&5
8165 echo "${ECHO_T}none needed" >&6; } ;;
8166   xno)
8167     { echo "$as_me:$LINENO: result: unsupported" >&5
8168 echo "${ECHO_T}unsupported" >&6; } ;;
8169   *)
8170     CC="$CC $ac_cv_prog_cc_c99"
8171     { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c99" >&5
8172 echo "${ECHO_T}$ac_cv_prog_cc_c99" >&6; } ;;
8173 esac
8174 if test "x$ac_cv_prog_cc_c99" != xno; then
8175   ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
8176 else
8177   { echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
8178 echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
8179 if test "${ac_cv_prog_cc_c89+set}" = set; then
8180   echo $ECHO_N "(cached) $ECHO_C" >&6
8181 else
8182   ac_cv_prog_cc_c89=no
8183 ac_save_CC=$CC
8184 cat >conftest.$ac_ext <<_ACEOF
8185 /* confdefs.h.  */
8186 _ACEOF
8187 cat confdefs.h >>conftest.$ac_ext
8188 cat >>conftest.$ac_ext <<_ACEOF
8189 /* end confdefs.h.  */
8190 #include <stdarg.h>
8191 #include <stdio.h>
8192 #include <sys/types.h>
8193 #include <sys/stat.h>
8194 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
8195 struct buf { int x; };
8196 FILE * (*rcsopen) (struct buf *, struct stat *, int);
8197 static char *e (p, i)
8198      char **p;
8199      int i;
8200 {
8201   return p[i];
8202 }
8203 static char *f (char * (*g) (char **, int), char **p, ...)
8204 {
8205   char *s;
8206   va_list v;
8207   va_start (v,p);
8208   s = g (p, va_arg (v,int));
8209   va_end (v);
8210   return s;
8211 }
8212
8213 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
8214    function prototypes and stuff, but not '\xHH' hex character constants.
8215    These don't provoke an error unfortunately, instead are silently treated
8216    as 'x'.  The following induces an error, until -std is added to get
8217    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
8218    array size at least.  It's necessary to write '\x00'==0 to get something
8219    that's true only with -std.  */
8220 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
8221
8222 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
8223    inside strings and character constants.  */
8224 #define FOO(x) 'x'
8225 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
8226
8227 int test (int i, double x);
8228 struct s1 {int (*f) (int a);};
8229 struct s2 {int (*f) (double a);};
8230 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
8231 int argc;
8232 char **argv;
8233 int
8234 main ()
8235 {
8236 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
8237   ;
8238   return 0;
8239 }
8240 _ACEOF
8241 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
8242         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
8243 do
8244   CC="$ac_save_CC $ac_arg"
8245   rm -f conftest.$ac_objext
8246 if { (ac_try="$ac_compile"
8247 case "(($ac_try" in
8248   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8249   *) ac_try_echo=$ac_try;;
8250 esac
8251 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8252   (eval "$ac_compile") 2>conftest.er1
8253   ac_status=$?
8254   grep -v '^ *+' conftest.er1 >conftest.err
8255   rm -f conftest.er1
8256   cat conftest.err >&5
8257   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8258   (exit $ac_status); } && {
8259          test -z "$ac_c_werror_flag" ||
8260          test ! -s conftest.err
8261        } && test -s conftest.$ac_objext; then
8262   ac_cv_prog_cc_c89=$ac_arg
8263 else
8264   echo "$as_me: failed program was:" >&5
8265 sed 's/^/| /' conftest.$ac_ext >&5
8266
8267
8268 fi
8269
8270 rm -f core conftest.err conftest.$ac_objext
8271   test "x$ac_cv_prog_cc_c89" != "xno" && break
8272 done
8273 rm -f conftest.$ac_ext
8274 CC=$ac_save_CC
8275
8276 fi
8277 # AC_CACHE_VAL
8278 case "x$ac_cv_prog_cc_c89" in
8279   x)
8280     { echo "$as_me:$LINENO: result: none needed" >&5
8281 echo "${ECHO_T}none needed" >&6; } ;;
8282   xno)
8283     { echo "$as_me:$LINENO: result: unsupported" >&5
8284 echo "${ECHO_T}unsupported" >&6; } ;;
8285   *)
8286     CC="$CC $ac_cv_prog_cc_c89"
8287     { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
8288 echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
8289 esac
8290 if test "x$ac_cv_prog_cc_c89" != xno; then
8291   ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
8292 else
8293   ac_cv_prog_cc_stdc=no
8294 fi
8295
8296
8297 fi
8298
8299  ;;
8300 esac
8301   { echo "$as_me:$LINENO: checking for $CC option to accept ISO Standard C" >&5
8302 echo $ECHO_N "checking for $CC option to accept ISO Standard C... $ECHO_C" >&6; }
8303   if test "${ac_cv_prog_cc_stdc+set}" = set; then
8304   echo $ECHO_N "(cached) $ECHO_C" >&6
8305 fi
8306
8307   case $ac_cv_prog_cc_stdc in
8308   no) { echo "$as_me:$LINENO: result: unsupported" >&5
8309 echo "${ECHO_T}unsupported" >&6; } ;;
8310   '') { echo "$as_me:$LINENO: result: none needed" >&5
8311 echo "${ECHO_T}none needed" >&6; } ;;
8312   *) { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
8313 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6; } ;;
8314 esac
8315
8316
8317 ac_ext=c
8318 ac_cpp='$CPP $CPPFLAGS'
8319 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8320 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8321 ac_compiler_gnu=$ac_cv_c_compiler_gnu
8322 { echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
8323 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
8324 # On Suns, sometimes $CPP names a directory.
8325 if test -n "$CPP" && test -d "$CPP"; then
8326   CPP=
8327 fi
8328 if test -z "$CPP"; then
8329   if test "${ac_cv_prog_CPP+set}" = set; then
8330   echo $ECHO_N "(cached) $ECHO_C" >&6
8331 else
8332       # Double quotes because CPP needs to be expanded
8333     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
8334     do
8335       ac_preproc_ok=false
8336 for ac_c_preproc_warn_flag in '' yes
8337 do
8338   # Use a header file that comes with gcc, so configuring glibc
8339   # with a fresh cross-compiler works.
8340   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8341   # <limits.h> exists even on freestanding compilers.
8342   # On the NeXT, cc -E runs the code through the compiler's parser,
8343   # not just through cpp. "Syntax error" is here to catch this case.
8344   cat >conftest.$ac_ext <<_ACEOF
8345 /* confdefs.h.  */
8346 _ACEOF
8347 cat confdefs.h >>conftest.$ac_ext
8348 cat >>conftest.$ac_ext <<_ACEOF
8349 /* end confdefs.h.  */
8350 #ifdef __STDC__
8351 # include <limits.h>
8352 #else
8353 # include <assert.h>
8354 #endif
8355                      Syntax error
8356 _ACEOF
8357 if { (ac_try="$ac_cpp conftest.$ac_ext"
8358 case "(($ac_try" in
8359   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8360   *) ac_try_echo=$ac_try;;
8361 esac
8362 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8363   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
8364   ac_status=$?
8365   grep -v '^ *+' conftest.er1 >conftest.err
8366   rm -f conftest.er1
8367   cat conftest.err >&5
8368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8369   (exit $ac_status); } >/dev/null && {
8370          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
8371          test ! -s conftest.err
8372        }; then
8373   :
8374 else
8375   echo "$as_me: failed program was:" >&5
8376 sed 's/^/| /' conftest.$ac_ext >&5
8377
8378   # Broken: fails on valid input.
8379 continue
8380 fi
8381
8382 rm -f conftest.err conftest.$ac_ext
8383
8384   # OK, works on sane cases.  Now check whether nonexistent headers
8385   # can be detected and how.
8386   cat >conftest.$ac_ext <<_ACEOF
8387 /* confdefs.h.  */
8388 _ACEOF
8389 cat confdefs.h >>conftest.$ac_ext
8390 cat >>conftest.$ac_ext <<_ACEOF
8391 /* end confdefs.h.  */
8392 #include <ac_nonexistent.h>
8393 _ACEOF
8394 if { (ac_try="$ac_cpp conftest.$ac_ext"
8395 case "(($ac_try" in
8396   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8397   *) ac_try_echo=$ac_try;;
8398 esac
8399 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8400   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
8401   ac_status=$?
8402   grep -v '^ *+' conftest.er1 >conftest.err
8403   rm -f conftest.er1
8404   cat conftest.err >&5
8405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8406   (exit $ac_status); } >/dev/null && {
8407          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
8408          test ! -s conftest.err
8409        }; then
8410   # Broken: success on invalid input.
8411 continue
8412 else
8413   echo "$as_me: failed program was:" >&5
8414 sed 's/^/| /' conftest.$ac_ext >&5
8415
8416   # Passes both tests.
8417 ac_preproc_ok=:
8418 break
8419 fi
8420
8421 rm -f conftest.err conftest.$ac_ext
8422
8423 done
8424 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
8425 rm -f conftest.err conftest.$ac_ext
8426 if $ac_preproc_ok; then
8427   break
8428 fi
8429
8430     done
8431     ac_cv_prog_CPP=$CPP
8432
8433 fi
8434   CPP=$ac_cv_prog_CPP
8435 else
8436   ac_cv_prog_CPP=$CPP
8437 fi
8438 { echo "$as_me:$LINENO: result: $CPP" >&5
8439 echo "${ECHO_T}$CPP" >&6; }
8440 ac_preproc_ok=false
8441 for ac_c_preproc_warn_flag in '' yes
8442 do
8443   # Use a header file that comes with gcc, so configuring glibc
8444   # with a fresh cross-compiler works.
8445   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8446   # <limits.h> exists even on freestanding compilers.
8447   # On the NeXT, cc -E runs the code through the compiler's parser,
8448   # not just through cpp. "Syntax error" is here to catch this case.
8449   cat >conftest.$ac_ext <<_ACEOF
8450 /* confdefs.h.  */
8451 _ACEOF
8452 cat confdefs.h >>conftest.$ac_ext
8453 cat >>conftest.$ac_ext <<_ACEOF
8454 /* end confdefs.h.  */
8455 #ifdef __STDC__
8456 # include <limits.h>
8457 #else
8458 # include <assert.h>
8459 #endif
8460                      Syntax error
8461 _ACEOF
8462 if { (ac_try="$ac_cpp conftest.$ac_ext"
8463 case "(($ac_try" in
8464   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8465   *) ac_try_echo=$ac_try;;
8466 esac
8467 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8468   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
8469   ac_status=$?
8470   grep -v '^ *+' conftest.er1 >conftest.err
8471   rm -f conftest.er1
8472   cat conftest.err >&5
8473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8474   (exit $ac_status); } >/dev/null && {
8475          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
8476          test ! -s conftest.err
8477        }; then
8478   :
8479 else
8480   echo "$as_me: failed program was:" >&5
8481 sed 's/^/| /' conftest.$ac_ext >&5
8482
8483   # Broken: fails on valid input.
8484 continue
8485 fi
8486
8487 rm -f conftest.err conftest.$ac_ext
8488
8489   # OK, works on sane cases.  Now check whether nonexistent headers
8490   # can be detected and how.
8491   cat >conftest.$ac_ext <<_ACEOF
8492 /* confdefs.h.  */
8493 _ACEOF
8494 cat confdefs.h >>conftest.$ac_ext
8495 cat >>conftest.$ac_ext <<_ACEOF
8496 /* end confdefs.h.  */
8497 #include <ac_nonexistent.h>
8498 _ACEOF
8499 if { (ac_try="$ac_cpp conftest.$ac_ext"
8500 case "(($ac_try" in
8501   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8502   *) ac_try_echo=$ac_try;;
8503 esac
8504 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8505   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
8506   ac_status=$?
8507   grep -v '^ *+' conftest.er1 >conftest.err
8508   rm -f conftest.er1
8509   cat conftest.err >&5
8510   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8511   (exit $ac_status); } >/dev/null && {
8512          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
8513          test ! -s conftest.err
8514        }; then
8515   # Broken: success on invalid input.
8516 continue
8517 else
8518   echo "$as_me: failed program was:" >&5
8519 sed 's/^/| /' conftest.$ac_ext >&5
8520
8521   # Passes both tests.
8522 ac_preproc_ok=:
8523 break
8524 fi
8525
8526 rm -f conftest.err conftest.$ac_ext
8527
8528 done
8529 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
8530 rm -f conftest.err conftest.$ac_ext
8531 if $ac_preproc_ok; then
8532   :
8533 else
8534   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
8535 See \`config.log' for more details." >&5
8536 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
8537 See \`config.log' for more details." >&2;}
8538    { (exit 1); exit 1; }; }
8539 fi
8540
8541 ac_ext=c
8542 ac_cpp='$CPP $CPPFLAGS'
8543 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8544 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8545 ac_compiler_gnu=$ac_cv_c_compiler_gnu
8546
8547
8548
8549 case $ac_cv_prog_cc_stdc in
8550   no)
8551     ;;
8552   *)
8553     cat >conftest.$ac_ext <<_ACEOF
8554 /* confdefs.h.  */
8555 _ACEOF
8556 cat confdefs.h >>conftest.$ac_ext
8557 cat >>conftest.$ac_ext <<_ACEOF
8558 /* end confdefs.h.  */
8559 #define __GMP_WITHIN_CONFIGURE 1   /* ignore template stuff */
8560 #define GMP_NAIL_BITS $GMP_NAIL_BITS
8561 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
8562 #define GMP_LIMB_BITS 123
8563 $DEFN_LONG_LONG_LIMB
8564 #include "$srcdir/gmp-h.in"
8565
8566 #if ! __GMP_HAVE_PROTOTYPES
8567 die die die
8568 #endif
8569
8570 int
8571 main ()
8572 {
8573
8574   ;
8575   return 0;
8576 }
8577 _ACEOF
8578 rm -f conftest.$ac_objext
8579 if { (ac_try="$ac_compile"
8580 case "(($ac_try" in
8581   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8582   *) ac_try_echo=$ac_try;;
8583 esac
8584 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8585   (eval "$ac_compile") 2>conftest.er1
8586   ac_status=$?
8587   grep -v '^ *+' conftest.er1 >conftest.err
8588   rm -f conftest.er1
8589   cat conftest.err >&5
8590   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8591   (exit $ac_status); } && {
8592          test -z "$ac_c_werror_flag" ||
8593          test ! -s conftest.err
8594        } && test -s conftest.$ac_objext; then
8595   :
8596 else
8597   echo "$as_me: failed program was:" >&5
8598 sed 's/^/| /' conftest.$ac_ext >&5
8599
8600         { echo "$as_me:$LINENO: WARNING: gmp.h doesnt recognise compiler as ANSI, prototypes and \"const\" will be unavailable" >&5
8601 echo "$as_me: WARNING: gmp.h doesnt recognise compiler as ANSI, prototypes and \"const\" will be unavailable" >&2;}
8602 fi
8603
8604 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8605     ;;
8606 esac
8607
8608
8609
8610 # The C compiler on the build system, and associated tests.
8611
8612 if test -n "$CC_FOR_BUILD"; then
8613   { echo "$as_me:$LINENO: checking build system compiler $CC_FOR_BUILD" >&5
8614 echo $ECHO_N "checking build system compiler $CC_FOR_BUILD... $ECHO_C" >&6; }
8615 # remove anything that might look like compiler output to our "||" expression
8616 rm -f conftest* a.out b.out a.exe a_out.exe
8617 cat >conftest.c <<EOF
8618 int
8619 main ()
8620 {
8621   exit(0);
8622 }
8623 EOF
8624 gmp_compile="$CC_FOR_BUILD conftest.c"
8625 cc_for_build_works=no
8626 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
8627   (eval $gmp_compile) 2>&5
8628   ac_status=$?
8629   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8630   (exit $ac_status); }; then
8631   if (./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest) >&5 2>&1; then
8632     cc_for_build_works=yes
8633   fi
8634 fi
8635 rm -f conftest* a.out b.out a.exe a_out.exe
8636 { echo "$as_me:$LINENO: result: $cc_for_build_works" >&5
8637 echo "${ECHO_T}$cc_for_build_works" >&6; }
8638 if test "$cc_for_build_works" = yes; then
8639   :
8640 else
8641   { { echo "$as_me:$LINENO: error: Specified CC_FOR_BUILD doesn't seem to work" >&5
8642 echo "$as_me: error: Specified CC_FOR_BUILD doesn't seem to work" >&2;}
8643    { (exit 1); exit 1; }; }
8644 fi
8645
8646 elif test -n "$HOST_CC"; then
8647   { echo "$as_me:$LINENO: checking build system compiler $HOST_CC" >&5
8648 echo $ECHO_N "checking build system compiler $HOST_CC... $ECHO_C" >&6; }
8649 # remove anything that might look like compiler output to our "||" expression
8650 rm -f conftest* a.out b.out a.exe a_out.exe
8651 cat >conftest.c <<EOF
8652 int
8653 main ()
8654 {
8655   exit(0);
8656 }
8657 EOF
8658 gmp_compile="$HOST_CC conftest.c"
8659 cc_for_build_works=no
8660 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
8661   (eval $gmp_compile) 2>&5
8662   ac_status=$?
8663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8664   (exit $ac_status); }; then
8665   if (./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest) >&5 2>&1; then
8666     cc_for_build_works=yes
8667   fi
8668 fi
8669 rm -f conftest* a.out b.out a.exe a_out.exe
8670 { echo "$as_me:$LINENO: result: $cc_for_build_works" >&5
8671 echo "${ECHO_T}$cc_for_build_works" >&6; }
8672 if test "$cc_for_build_works" = yes; then
8673   CC_FOR_BUILD=$HOST_CC
8674 else
8675   { { echo "$as_me:$LINENO: error: Specified HOST_CC doesn't seem to work" >&5
8676 echo "$as_me: error: Specified HOST_CC doesn't seem to work" >&2;}
8677    { (exit 1); exit 1; }; }
8678 fi
8679
8680 else
8681   for i in "$CC" "$CC $CFLAGS $CPPFLAGS" cc gcc c89 c99; do
8682     { echo "$as_me:$LINENO: checking build system compiler $i" >&5
8683 echo $ECHO_N "checking build system compiler $i... $ECHO_C" >&6; }
8684 # remove anything that might look like compiler output to our "||" expression
8685 rm -f conftest* a.out b.out a.exe a_out.exe
8686 cat >conftest.c <<EOF
8687 int
8688 main ()
8689 {
8690   exit(0);
8691 }
8692 EOF
8693 gmp_compile="$i conftest.c"
8694 cc_for_build_works=no
8695 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
8696   (eval $gmp_compile) 2>&5
8697   ac_status=$?
8698   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8699   (exit $ac_status); }; then
8700   if (./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest) >&5 2>&1; then
8701     cc_for_build_works=yes
8702   fi
8703 fi
8704 rm -f conftest* a.out b.out a.exe a_out.exe
8705 { echo "$as_me:$LINENO: result: $cc_for_build_works" >&5
8706 echo "${ECHO_T}$cc_for_build_works" >&6; }
8707 if test "$cc_for_build_works" = yes; then
8708   CC_FOR_BUILD=$i
8709        break
8710 else
8711   :
8712 fi
8713
8714   done
8715   if test -z "$CC_FOR_BUILD"; then
8716     { { echo "$as_me:$LINENO: error: Cannot find a build system compiler" >&5
8717 echo "$as_me: error: Cannot find a build system compiler" >&2;}
8718    { (exit 1); exit 1; }; }
8719   fi
8720 fi
8721
8722
8723
8724
8725
8726 { echo "$as_me:$LINENO: checking for build system preprocessor" >&5
8727 echo $ECHO_N "checking for build system preprocessor... $ECHO_C" >&6; }
8728 if test -z "$CPP_FOR_BUILD"; then
8729   if test "${gmp_cv_prog_cpp_for_build+set}" = set; then
8730   echo $ECHO_N "(cached) $ECHO_C" >&6
8731 else
8732   cat >conftest.c <<EOF
8733 #define FOO BAR
8734 EOF
8735   for i in "$CC_FOR_BUILD -E" "$CC_FOR_BUILD -E -traditional-cpp" "/lib/cpp"; do
8736     gmp_compile="$i conftest.c"
8737     if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
8738   (eval $gmp_compile) 2>&5
8739   ac_status=$?
8740   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8741   (exit $ac_status); } >&5 2>&1; then
8742       gmp_cv_prog_cpp_for_build=$i
8743       break
8744     fi
8745   done
8746   rm -f conftest* a.out b.out a.exe a_out.exe
8747   if test -z "$gmp_cv_prog_cpp_for_build"; then
8748     { { echo "$as_me:$LINENO: error: Cannot find build system C preprocessor." >&5
8749 echo "$as_me: error: Cannot find build system C preprocessor." >&2;}
8750    { (exit 1); exit 1; }; }
8751   fi
8752
8753 fi
8754
8755   CPP_FOR_BUILD=$gmp_cv_prog_cpp_for_build
8756 fi
8757 { echo "$as_me:$LINENO: result: $CPP_FOR_BUILD" >&5
8758 echo "${ECHO_T}$CPP_FOR_BUILD" >&6; }
8759
8760
8761
8762
8763
8764 { echo "$as_me:$LINENO: checking for build system executable suffix" >&5
8765 echo $ECHO_N "checking for build system executable suffix... $ECHO_C" >&6; }
8766 if test "${gmp_cv_prog_exeext_for_build+set}" = set; then
8767   echo $ECHO_N "(cached) $ECHO_C" >&6
8768 else
8769   cat >conftest.c <<EOF
8770 int
8771 main ()
8772 {
8773   exit (0);
8774 }
8775 EOF
8776 for i in .exe ,ff8 ""; do
8777   gmp_compile="$CC_FOR_BUILD conftest.c -o conftest$i"
8778   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
8779   (eval $gmp_compile) 2>&5
8780   ac_status=$?
8781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8782   (exit $ac_status); }; then
8783     if (./conftest) 2>&5; then
8784       gmp_cv_prog_exeext_for_build=$i
8785       break
8786     fi
8787   fi
8788 done
8789 rm -f conftest*
8790 if test "${gmp_cv_prog_exeext_for_build+set}" != set; then
8791   { { echo "$as_me:$LINENO: error: Cannot determine executable suffix" >&5
8792 echo "$as_me: error: Cannot determine executable suffix" >&2;}
8793    { (exit 1); exit 1; }; }
8794 fi
8795
8796 fi
8797 { echo "$as_me:$LINENO: result: $gmp_cv_prog_exeext_for_build" >&5
8798 echo "${ECHO_T}$gmp_cv_prog_exeext_for_build" >&6; }
8799 EXEEXT_FOR_BUILD=$gmp_cv_prog_exeext_for_build
8800
8801
8802
8803 { echo "$as_me:$LINENO: checking whether build system compiler is ANSI" >&5
8804 echo $ECHO_N "checking whether build system compiler is ANSI... $ECHO_C" >&6; }
8805 if test "${gmp_cv_c_for_build_ansi+set}" = set; then
8806   echo $ECHO_N "(cached) $ECHO_C" >&6
8807 else
8808   cat >conftest.c <<EOF
8809 int
8810 main (int argc, char **argv)
8811 {
8812   exit(0);
8813 }
8814 EOF
8815 gmp_compile="$CC_FOR_BUILD conftest.c"
8816 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
8817   (eval $gmp_compile) 2>&5
8818   ac_status=$?
8819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8820   (exit $ac_status); }; then
8821   gmp_cv_c_for_build_ansi=yes
8822 else
8823   gmp_cv_c_for_build_ansi=no
8824 fi
8825 rm -f conftest* a.out b.out a.exe a_out.exe
8826
8827 fi
8828 { echo "$as_me:$LINENO: result: $gmp_cv_c_for_build_ansi" >&5
8829 echo "${ECHO_T}$gmp_cv_c_for_build_ansi" >&6; }
8830 if test "$gmp_cv_c_for_build_ansi" = yes; then
8831   U_FOR_BUILD=
8832 else
8833   U_FOR_BUILD=_
8834
8835 fi
8836
8837
8838 { echo "$as_me:$LINENO: checking for build system compiler math library" >&5
8839 echo $ECHO_N "checking for build system compiler math library... $ECHO_C" >&6; }
8840 if test "${gmp_cv_check_libm_for_build+set}" = set; then
8841   echo $ECHO_N "(cached) $ECHO_C" >&6
8842 else
8843   cat >conftest.c <<EOF
8844 int
8845 main ()
8846 {
8847   exit(0);
8848 }
8849 double d;
8850 double
8851 foo ()
8852 {
8853   return log (d);
8854 }
8855 EOF
8856 gmp_compile="$CC_FOR_BUILD conftest.c -lm"
8857 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
8858   (eval $gmp_compile) 2>&5
8859   ac_status=$?
8860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8861   (exit $ac_status); }; then
8862   gmp_cv_check_libm_for_build=-lm
8863 else
8864   gmp_cv_check_libm_for_build=no
8865 fi
8866 rm -f conftest* a.out b.out a.exe a_out.exe
8867
8868 fi
8869 { echo "$as_me:$LINENO: result: $gmp_cv_check_libm_for_build" >&5
8870 echo "${ECHO_T}$gmp_cv_check_libm_for_build" >&6; }
8871 case $gmp_cv_check_libm_for_build in
8872   yes) LIBM_FOR_BUILD=-lm
8873  ;;
8874   no)  LIBM_FOR_BUILD= ;;
8875   *)   LIBM_FOR_BUILD=$gmp_cv_check_libm_for_build ;;
8876 esac
8877
8878
8879
8880 # How to assemble, used with CFLAGS etc, see mpn/Makeasm.am.
8881 # Using the compiler is a lot easier than figuring out how to invoke the
8882 # assembler directly.
8883 #
8884 test -n "$CCAS" || CCAS="$CC -c"
8885
8886
8887
8888 # The C++ compiler, if desired.
8889 want_cxx=no
8890 if test $enable_cxx != no; then
8891   test_CXXFLAGS=${CXXFLAGS+set}
8892   ac_ext=cpp
8893 ac_cpp='$CXXCPP $CPPFLAGS'
8894 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8895 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8896 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
8897 if test -z "$CXX"; then
8898   if test -n "$CCC"; then
8899     CXX=$CCC
8900   else
8901     if test -n "$ac_tool_prefix"; then
8902   for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
8903   do
8904     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8905 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8906 { echo "$as_me:$LINENO: checking for $ac_word" >&5
8907 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
8908 if test "${ac_cv_prog_CXX+set}" = set; then
8909   echo $ECHO_N "(cached) $ECHO_C" >&6
8910 else
8911   if test -n "$CXX"; then
8912   ac_cv_prog_CXX="$CXX" # Let the user override the test.
8913 else
8914 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8915 for as_dir in $PATH
8916 do
8917   IFS=$as_save_IFS
8918   test -z "$as_dir" && as_dir=.
8919   for ac_exec_ext in '' $ac_executable_extensions; do
8920   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8921     ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
8922     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8923     break 2
8924   fi
8925 done
8926 done
8927 IFS=$as_save_IFS
8928
8929 fi
8930 fi
8931 CXX=$ac_cv_prog_CXX
8932 if test -n "$CXX"; then
8933   { echo "$as_me:$LINENO: result: $CXX" >&5
8934 echo "${ECHO_T}$CXX" >&6; }
8935 else
8936   { echo "$as_me:$LINENO: result: no" >&5
8937 echo "${ECHO_T}no" >&6; }
8938 fi
8939
8940
8941     test -n "$CXX" && break
8942   done
8943 fi
8944 if test -z "$CXX"; then
8945   ac_ct_CXX=$CXX
8946   for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
8947 do
8948   # Extract the first word of "$ac_prog", so it can be a program name with args.
8949 set dummy $ac_prog; ac_word=$2
8950 { echo "$as_me:$LINENO: checking for $ac_word" >&5
8951 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
8952 if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then
8953   echo $ECHO_N "(cached) $ECHO_C" >&6
8954 else
8955   if test -n "$ac_ct_CXX"; then
8956   ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
8957 else
8958 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8959 for as_dir in $PATH
8960 do
8961   IFS=$as_save_IFS
8962   test -z "$as_dir" && as_dir=.
8963   for ac_exec_ext in '' $ac_executable_extensions; do
8964   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8965     ac_cv_prog_ac_ct_CXX="$ac_prog"
8966     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
8967     break 2
8968   fi
8969 done
8970 done
8971 IFS=$as_save_IFS
8972
8973 fi
8974 fi
8975 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
8976 if test -n "$ac_ct_CXX"; then
8977   { echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5
8978 echo "${ECHO_T}$ac_ct_CXX" >&6; }
8979 else
8980   { echo "$as_me:$LINENO: result: no" >&5
8981 echo "${ECHO_T}no" >&6; }
8982 fi
8983
8984
8985   test -n "$ac_ct_CXX" && break
8986 done
8987
8988   if test "x$ac_ct_CXX" = x; then
8989     CXX="g++"
8990   else
8991     case $cross_compiling:$ac_tool_warned in
8992 yes:)
8993 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
8994 whose name does not start with the host triplet.  If you think this
8995 configuration is useful to you, please write to autoconf@gnu.org." >&5
8996 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
8997 whose name does not start with the host triplet.  If you think this
8998 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
8999 ac_tool_warned=yes ;;
9000 esac
9001     CXX=$ac_ct_CXX
9002   fi
9003 fi
9004
9005   fi
9006 fi
9007 # Provide some information about the compiler.
9008 echo "$as_me:$LINENO: checking for C++ compiler version" >&5
9009 ac_compiler=`set X $ac_compile; echo $2`
9010 { (ac_try="$ac_compiler --version >&5"
9011 case "(($ac_try" in
9012   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9013   *) ac_try_echo=$ac_try;;
9014 esac
9015 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9016   (eval "$ac_compiler --version >&5") 2>&5
9017   ac_status=$?
9018   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9019   (exit $ac_status); }
9020 { (ac_try="$ac_compiler -v >&5"
9021 case "(($ac_try" in
9022   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9023   *) ac_try_echo=$ac_try;;
9024 esac
9025 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9026   (eval "$ac_compiler -v >&5") 2>&5
9027   ac_status=$?
9028   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9029   (exit $ac_status); }
9030 { (ac_try="$ac_compiler -V >&5"
9031 case "(($ac_try" in
9032   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9033   *) ac_try_echo=$ac_try;;
9034 esac
9035 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9036   (eval "$ac_compiler -V >&5") 2>&5
9037   ac_status=$?
9038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9039   (exit $ac_status); }
9040
9041 { echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5
9042 echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6; }
9043 if test "${ac_cv_cxx_compiler_gnu+set}" = set; then
9044   echo $ECHO_N "(cached) $ECHO_C" >&6
9045 else
9046   cat >conftest.$ac_ext <<_ACEOF
9047 /* confdefs.h.  */
9048 _ACEOF
9049 cat confdefs.h >>conftest.$ac_ext
9050 cat >>conftest.$ac_ext <<_ACEOF
9051 /* end confdefs.h.  */
9052
9053 int
9054 main ()
9055 {
9056 #ifndef __GNUC__
9057        choke me
9058 #endif
9059
9060   ;
9061   return 0;
9062 }
9063 _ACEOF
9064 rm -f conftest.$ac_objext
9065 if { (ac_try="$ac_compile"
9066 case "(($ac_try" in
9067   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9068   *) ac_try_echo=$ac_try;;
9069 esac
9070 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9071   (eval "$ac_compile") 2>conftest.er1
9072   ac_status=$?
9073   grep -v '^ *+' conftest.er1 >conftest.err
9074   rm -f conftest.er1
9075   cat conftest.err >&5
9076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9077   (exit $ac_status); } && {
9078          test -z "$ac_cxx_werror_flag" ||
9079          test ! -s conftest.err
9080        } && test -s conftest.$ac_objext; then
9081   ac_compiler_gnu=yes
9082 else
9083   echo "$as_me: failed program was:" >&5
9084 sed 's/^/| /' conftest.$ac_ext >&5
9085
9086         ac_compiler_gnu=no
9087 fi
9088
9089 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9090 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
9091
9092 fi
9093 { echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5
9094 echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6; }
9095 GXX=`test $ac_compiler_gnu = yes && echo yes`
9096 ac_test_CXXFLAGS=${CXXFLAGS+set}
9097 ac_save_CXXFLAGS=$CXXFLAGS
9098 { echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5
9099 echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6; }
9100 if test "${ac_cv_prog_cxx_g+set}" = set; then
9101   echo $ECHO_N "(cached) $ECHO_C" >&6
9102 else
9103   ac_save_cxx_werror_flag=$ac_cxx_werror_flag
9104    ac_cxx_werror_flag=yes
9105    ac_cv_prog_cxx_g=no
9106    CXXFLAGS="-g"
9107    cat >conftest.$ac_ext <<_ACEOF
9108 /* confdefs.h.  */
9109 _ACEOF
9110 cat confdefs.h >>conftest.$ac_ext
9111 cat >>conftest.$ac_ext <<_ACEOF
9112 /* end confdefs.h.  */
9113
9114 int
9115 main ()
9116 {
9117
9118   ;
9119   return 0;
9120 }
9121 _ACEOF
9122 rm -f conftest.$ac_objext
9123 if { (ac_try="$ac_compile"
9124 case "(($ac_try" in
9125   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9126   *) ac_try_echo=$ac_try;;
9127 esac
9128 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9129   (eval "$ac_compile") 2>conftest.er1
9130   ac_status=$?
9131   grep -v '^ *+' conftest.er1 >conftest.err
9132   rm -f conftest.er1
9133   cat conftest.err >&5
9134   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9135   (exit $ac_status); } && {
9136          test -z "$ac_cxx_werror_flag" ||
9137          test ! -s conftest.err
9138        } && test -s conftest.$ac_objext; then
9139   ac_cv_prog_cxx_g=yes
9140 else
9141   echo "$as_me: failed program was:" >&5
9142 sed 's/^/| /' conftest.$ac_ext >&5
9143
9144         CXXFLAGS=""
9145       cat >conftest.$ac_ext <<_ACEOF
9146 /* confdefs.h.  */
9147 _ACEOF
9148 cat confdefs.h >>conftest.$ac_ext
9149 cat >>conftest.$ac_ext <<_ACEOF
9150 /* end confdefs.h.  */
9151
9152 int
9153 main ()
9154 {
9155
9156   ;
9157   return 0;
9158 }
9159 _ACEOF
9160 rm -f conftest.$ac_objext
9161 if { (ac_try="$ac_compile"
9162 case "(($ac_try" in
9163   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9164   *) ac_try_echo=$ac_try;;
9165 esac
9166 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9167   (eval "$ac_compile") 2>conftest.er1
9168   ac_status=$?
9169   grep -v '^ *+' conftest.er1 >conftest.err
9170   rm -f conftest.er1
9171   cat conftest.err >&5
9172   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9173   (exit $ac_status); } && {
9174          test -z "$ac_cxx_werror_flag" ||
9175          test ! -s conftest.err
9176        } && test -s conftest.$ac_objext; then
9177   :
9178 else
9179   echo "$as_me: failed program was:" >&5
9180 sed 's/^/| /' conftest.$ac_ext >&5
9181
9182         ac_cxx_werror_flag=$ac_save_cxx_werror_flag
9183          CXXFLAGS="-g"
9184          cat >conftest.$ac_ext <<_ACEOF
9185 /* confdefs.h.  */
9186 _ACEOF
9187 cat confdefs.h >>conftest.$ac_ext
9188 cat >>conftest.$ac_ext <<_ACEOF
9189 /* end confdefs.h.  */
9190
9191 int
9192 main ()
9193 {
9194
9195   ;
9196   return 0;
9197 }
9198 _ACEOF
9199 rm -f conftest.$ac_objext
9200 if { (ac_try="$ac_compile"
9201 case "(($ac_try" in
9202   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9203   *) ac_try_echo=$ac_try;;
9204 esac
9205 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9206   (eval "$ac_compile") 2>conftest.er1
9207   ac_status=$?
9208   grep -v '^ *+' conftest.er1 >conftest.err
9209   rm -f conftest.er1
9210   cat conftest.err >&5
9211   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9212   (exit $ac_status); } && {
9213          test -z "$ac_cxx_werror_flag" ||
9214          test ! -s conftest.err
9215        } && test -s conftest.$ac_objext; then
9216   ac_cv_prog_cxx_g=yes
9217 else
9218   echo "$as_me: failed program was:" >&5
9219 sed 's/^/| /' conftest.$ac_ext >&5
9220
9221
9222 fi
9223
9224 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9225 fi
9226
9227 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9228 fi
9229
9230 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9231    ac_cxx_werror_flag=$ac_save_cxx_werror_flag
9232 fi
9233 { echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5
9234 echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6; }
9235 if test "$ac_test_CXXFLAGS" = set; then
9236   CXXFLAGS=$ac_save_CXXFLAGS
9237 elif test $ac_cv_prog_cxx_g = yes; then
9238   if test "$GXX" = yes; then
9239     CXXFLAGS="-g -O2"
9240   else
9241     CXXFLAGS="-g"
9242   fi
9243 else
9244   if test "$GXX" = yes; then
9245     CXXFLAGS="-O2"
9246   else
9247     CXXFLAGS=
9248   fi
9249 fi
9250 ac_ext=c
9251 ac_cpp='$CPP $CPPFLAGS'
9252 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9253 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9254 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9255
9256
9257   echo "CXXFLAGS chosen by autoconf: $CXXFLAGS" >&5
9258   cxxflags_ac_prog_cxx=$CXXFLAGS
9259   cxxflags_list=ac_prog_cxx
9260
9261   # If the user didn't specify $CXXFLAGS, then try $CFLAGS, with -g removed
9262   # if AC_PROG_CXX thinks that doesn't work.  $CFLAGS stands a good chance
9263   # of working, eg. on a GNU system where CC=gcc and CXX=g++.
9264   #
9265   if test "$test_CXXFLAGS" != set; then
9266     cxxflags_cflags=$CFLAGS
9267     cxxflags_list="cflags $cxxflags_list"
9268     if test "$ac_prog_cxx_g" = no; then
9269       cxxflags_cflags=`echo "$cxxflags_cflags" | sed -e 's/ -g //' -e 's/^-g //' -e 's/ -g$//'`
9270     fi
9271   fi
9272
9273   # See if the C++ compiler works.  If the user specified CXXFLAGS then all
9274   # we're doing is checking whether AC_PROG_CXX succeeded, since it doesn't
9275   # give a fatal error, just leaves CXX set to a default g++.  If on the
9276   # other hand the user didn't specify CXXFLAGS then we get to try here our
9277   # $cxxflags_list alternatives.
9278   #
9279   # Automake includes $CPPFLAGS in a C++ compile, so we do the same here.
9280   #
9281   for cxxflags_choice in $cxxflags_list; do
9282     eval CXXFLAGS=\"\$cxxflags_$cxxflags_choice\"
9283     { echo "$as_me:$LINENO: checking C++ compiler $CXX $CPPFLAGS $CXXFLAGS" >&5
9284 echo $ECHO_N "checking C++ compiler $CXX $CPPFLAGS $CXXFLAGS... $ECHO_C" >&6; }
9285 gmp_prog_cxx_works=yes
9286
9287 # start with a plain "main()", then go on to further checks
9288 if test "$gmp_prog_cxx_works" = yes; then
9289   # remove anything that might look like compiler output to our "||" expression
9290   rm -f conftest* a.out b.out a.exe a_out.exe
9291   cat >conftest.cc <<EOF
9292
9293 int main (void) { return 0; }
9294 EOF
9295   echo "Test compile: " >&5
9296   gmp_cxxcompile="$CXX $CPPFLAGS $CXXFLAGS conftest.cc >&5"
9297   if { (eval echo "$as_me:$LINENO: \"$gmp_cxxcompile\"") >&5
9298   (eval $gmp_cxxcompile) 2>&5
9299   ac_status=$?
9300   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9301   (exit $ac_status); }; then
9302     if test "$cross_compiling" = no; then
9303       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
9304   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9305   (eval $ac_try) 2>&5
9306   ac_status=$?
9307   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9308   (exit $ac_status); }; }; then :;
9309       else
9310         gmp_prog_cxx_works="no, program does not run"
9311       fi
9312     fi
9313   else
9314     gmp_prog_cxx_works="no"
9315   fi
9316   case $gmp_prog_cxx_works in
9317     no*)
9318       echo "failed program was:" >&5
9319       cat conftest.cc >&5
9320       ;;
9321   esac
9322   rm -f conftest* a.out b.out a.exe a_out.exe
9323 fi
9324
9325
9326 if test "$gmp_prog_cxx_works" = yes; then
9327   # remove anything that might look like compiler output to our "||" expression
9328   rm -f conftest* a.out b.out a.exe a_out.exe
9329   cat >conftest.cc <<EOF
9330 namespace foo { }
9331 using namespace foo;
9332
9333 int main (void) { return 0; }
9334 EOF
9335   echo "Test compile: namespace" >&5
9336   gmp_cxxcompile="$CXX $CPPFLAGS $CXXFLAGS conftest.cc >&5"
9337   if { (eval echo "$as_me:$LINENO: \"$gmp_cxxcompile\"") >&5
9338   (eval $gmp_cxxcompile) 2>&5
9339   ac_status=$?
9340   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9341   (exit $ac_status); }; then
9342     if test "$cross_compiling" = no; then
9343       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
9344   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9345   (eval $ac_try) 2>&5
9346   ac_status=$?
9347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9348   (exit $ac_status); }; }; then :;
9349       else
9350         gmp_prog_cxx_works="no, namespace, program does not run"
9351       fi
9352     fi
9353   else
9354     gmp_prog_cxx_works="no, namespace"
9355   fi
9356   case $gmp_prog_cxx_works in
9357     no*)
9358       echo "failed program was:" >&5
9359       cat conftest.cc >&5
9360       ;;
9361   esac
9362   rm -f conftest* a.out b.out a.exe a_out.exe
9363 fi
9364
9365
9366 # GMP requires the standard C++ iostream classes
9367 if test "$gmp_prog_cxx_works" = yes; then
9368   # remove anything that might look like compiler output to our "||" expression
9369   rm -f conftest* a.out b.out a.exe a_out.exe
9370   cat >conftest.cc <<EOF
9371 /* This test rejects g++ 2.7.2 which doesn't have <iostream>, only a
9372     pre-standard iostream.h. */
9373 #include <iostream>
9374
9375 /* This test rejects OSF 5.1 Compaq C++ in its default pre-standard iostream
9376    mode, since that mode puts cout in the global namespace, not "std".  */
9377 void someoutput (void) { std::cout << 123; }
9378
9379 int main (void) { return 0; }
9380 EOF
9381   echo "Test compile: std iostream" >&5
9382   gmp_cxxcompile="$CXX $CPPFLAGS $CXXFLAGS conftest.cc >&5"
9383   if { (eval echo "$as_me:$LINENO: \"$gmp_cxxcompile\"") >&5
9384   (eval $gmp_cxxcompile) 2>&5
9385   ac_status=$?
9386   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9387   (exit $ac_status); }; then
9388     if test "$cross_compiling" = no; then
9389       if { ac_try='./a.out || ./b.out || ./a.exe || ./a_out.exe || ./conftest'
9390   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9391   (eval $ac_try) 2>&5
9392   ac_status=$?
9393   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9394   (exit $ac_status); }; }; then :;
9395       else
9396         gmp_prog_cxx_works="no, std iostream, program does not run"
9397       fi
9398     fi
9399   else
9400     gmp_prog_cxx_works="no, std iostream"
9401   fi
9402   case $gmp_prog_cxx_works in
9403     no*)
9404       echo "failed program was:" >&5
9405       cat conftest.cc >&5
9406       ;;
9407   esac
9408   rm -f conftest* a.out b.out a.exe a_out.exe
9409 fi
9410
9411
9412 { echo "$as_me:$LINENO: result: $gmp_prog_cxx_works" >&5
9413 echo "${ECHO_T}$gmp_prog_cxx_works" >&6; }
9414 case $gmp_prog_cxx_works in
9415   yes)
9416     want_cxx=yes
9417       break
9418     ;;
9419   *)
9420
9421     ;;
9422 esac
9423
9424   done
9425
9426   # If --enable-cxx=yes but a C++ compiler can't be found, then abort.
9427   if test $want_cxx = no && test $enable_cxx = yes; then
9428     { { echo "$as_me:$LINENO: error: C++ compiler not available, see config.log for details" >&5
9429 echo "$as_me: error: C++ compiler not available, see config.log for details" >&2;}
9430    { (exit 1); exit 1; }; }
9431   fi
9432 fi
9433
9434
9435
9436 if test $want_cxx = yes; then
9437   WANT_CXX_TRUE=
9438   WANT_CXX_FALSE='#'
9439 else
9440   WANT_CXX_TRUE='#'
9441   WANT_CXX_FALSE=
9442 fi
9443
9444
9445 # FIXME: We're not interested in CXXCPP for ourselves, but if we don't do it
9446 # here then AC_PROG_LIBTOOL will AC_REQUIRE it (via _LT_AC_TAGCONFIG) and
9447 # hence execute it unconditionally, and that will fail if there's no C++
9448 # compiler (and no generic /lib/cpp).
9449 #
9450 if test $want_cxx = yes; then
9451   ac_ext=cpp
9452 ac_cpp='$CXXCPP $CPPFLAGS'
9453 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9454 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9455 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
9456 { echo "$as_me:$LINENO: checking how to run the C++ preprocessor" >&5
9457 echo $ECHO_N "checking how to run the C++ preprocessor... $ECHO_C" >&6; }
9458 if test -z "$CXXCPP"; then
9459   if test "${ac_cv_prog_CXXCPP+set}" = set; then
9460   echo $ECHO_N "(cached) $ECHO_C" >&6
9461 else
9462       # Double quotes because CXXCPP needs to be expanded
9463     for CXXCPP in "$CXX -E" "/lib/cpp"
9464     do
9465       ac_preproc_ok=false
9466 for ac_cxx_preproc_warn_flag in '' yes
9467 do
9468   # Use a header file that comes with gcc, so configuring glibc
9469   # with a fresh cross-compiler works.
9470   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9471   # <limits.h> exists even on freestanding compilers.
9472   # On the NeXT, cc -E runs the code through the compiler's parser,
9473   # not just through cpp. "Syntax error" is here to catch this case.
9474   cat >conftest.$ac_ext <<_ACEOF
9475 /* confdefs.h.  */
9476 _ACEOF
9477 cat confdefs.h >>conftest.$ac_ext
9478 cat >>conftest.$ac_ext <<_ACEOF
9479 /* end confdefs.h.  */
9480 #ifdef __STDC__
9481 # include <limits.h>
9482 #else
9483 # include <assert.h>
9484 #endif
9485                      Syntax error
9486 _ACEOF
9487 if { (ac_try="$ac_cpp conftest.$ac_ext"
9488 case "(($ac_try" in
9489   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9490   *) ac_try_echo=$ac_try;;
9491 esac
9492 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9493   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9494   ac_status=$?
9495   grep -v '^ *+' conftest.er1 >conftest.err
9496   rm -f conftest.er1
9497   cat conftest.err >&5
9498   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9499   (exit $ac_status); } >/dev/null && {
9500          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
9501          test ! -s conftest.err
9502        }; then
9503   :
9504 else
9505   echo "$as_me: failed program was:" >&5
9506 sed 's/^/| /' conftest.$ac_ext >&5
9507
9508   # Broken: fails on valid input.
9509 continue
9510 fi
9511
9512 rm -f conftest.err conftest.$ac_ext
9513
9514   # OK, works on sane cases.  Now check whether nonexistent headers
9515   # can be detected and how.
9516   cat >conftest.$ac_ext <<_ACEOF
9517 /* confdefs.h.  */
9518 _ACEOF
9519 cat confdefs.h >>conftest.$ac_ext
9520 cat >>conftest.$ac_ext <<_ACEOF
9521 /* end confdefs.h.  */
9522 #include <ac_nonexistent.h>
9523 _ACEOF
9524 if { (ac_try="$ac_cpp conftest.$ac_ext"
9525 case "(($ac_try" in
9526   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9527   *) ac_try_echo=$ac_try;;
9528 esac
9529 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9530   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9531   ac_status=$?
9532   grep -v '^ *+' conftest.er1 >conftest.err
9533   rm -f conftest.er1
9534   cat conftest.err >&5
9535   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9536   (exit $ac_status); } >/dev/null && {
9537          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
9538          test ! -s conftest.err
9539        }; then
9540   # Broken: success on invalid input.
9541 continue
9542 else
9543   echo "$as_me: failed program was:" >&5
9544 sed 's/^/| /' conftest.$ac_ext >&5
9545
9546   # Passes both tests.
9547 ac_preproc_ok=:
9548 break
9549 fi
9550
9551 rm -f conftest.err conftest.$ac_ext
9552
9553 done
9554 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
9555 rm -f conftest.err conftest.$ac_ext
9556 if $ac_preproc_ok; then
9557   break
9558 fi
9559
9560     done
9561     ac_cv_prog_CXXCPP=$CXXCPP
9562
9563 fi
9564   CXXCPP=$ac_cv_prog_CXXCPP
9565 else
9566   ac_cv_prog_CXXCPP=$CXXCPP
9567 fi
9568 { echo "$as_me:$LINENO: result: $CXXCPP" >&5
9569 echo "${ECHO_T}$CXXCPP" >&6; }
9570 ac_preproc_ok=false
9571 for ac_cxx_preproc_warn_flag in '' yes
9572 do
9573   # Use a header file that comes with gcc, so configuring glibc
9574   # with a fresh cross-compiler works.
9575   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9576   # <limits.h> exists even on freestanding compilers.
9577   # On the NeXT, cc -E runs the code through the compiler's parser,
9578   # not just through cpp. "Syntax error" is here to catch this case.
9579   cat >conftest.$ac_ext <<_ACEOF
9580 /* confdefs.h.  */
9581 _ACEOF
9582 cat confdefs.h >>conftest.$ac_ext
9583 cat >>conftest.$ac_ext <<_ACEOF
9584 /* end confdefs.h.  */
9585 #ifdef __STDC__
9586 # include <limits.h>
9587 #else
9588 # include <assert.h>
9589 #endif
9590                      Syntax error
9591 _ACEOF
9592 if { (ac_try="$ac_cpp conftest.$ac_ext"
9593 case "(($ac_try" in
9594   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9595   *) ac_try_echo=$ac_try;;
9596 esac
9597 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9598   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9599   ac_status=$?
9600   grep -v '^ *+' conftest.er1 >conftest.err
9601   rm -f conftest.er1
9602   cat conftest.err >&5
9603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9604   (exit $ac_status); } >/dev/null && {
9605          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
9606          test ! -s conftest.err
9607        }; then
9608   :
9609 else
9610   echo "$as_me: failed program was:" >&5
9611 sed 's/^/| /' conftest.$ac_ext >&5
9612
9613   # Broken: fails on valid input.
9614 continue
9615 fi
9616
9617 rm -f conftest.err conftest.$ac_ext
9618
9619   # OK, works on sane cases.  Now check whether nonexistent headers
9620   # can be detected and how.
9621   cat >conftest.$ac_ext <<_ACEOF
9622 /* confdefs.h.  */
9623 _ACEOF
9624 cat confdefs.h >>conftest.$ac_ext
9625 cat >>conftest.$ac_ext <<_ACEOF
9626 /* end confdefs.h.  */
9627 #include <ac_nonexistent.h>
9628 _ACEOF
9629 if { (ac_try="$ac_cpp conftest.$ac_ext"
9630 case "(($ac_try" in
9631   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9632   *) ac_try_echo=$ac_try;;
9633 esac
9634 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9635   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9636   ac_status=$?
9637   grep -v '^ *+' conftest.er1 >conftest.err
9638   rm -f conftest.er1
9639   cat conftest.err >&5
9640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9641   (exit $ac_status); } >/dev/null && {
9642          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
9643          test ! -s conftest.err
9644        }; then
9645   # Broken: success on invalid input.
9646 continue
9647 else
9648   echo "$as_me: failed program was:" >&5
9649 sed 's/^/| /' conftest.$ac_ext >&5
9650
9651   # Passes both tests.
9652 ac_preproc_ok=:
9653 break
9654 fi
9655
9656 rm -f conftest.err conftest.$ac_ext
9657
9658 done
9659 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
9660 rm -f conftest.err conftest.$ac_ext
9661 if $ac_preproc_ok; then
9662   :
9663 else
9664   { { echo "$as_me:$LINENO: error: C++ preprocessor \"$CXXCPP\" fails sanity check
9665 See \`config.log' for more details." >&5
9666 echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check
9667 See \`config.log' for more details." >&2;}
9668    { (exit 1); exit 1; }; }
9669 fi
9670
9671 ac_ext=c
9672 ac_cpp='$CPP $CPPFLAGS'
9673 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9674 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9675 ac_compiler_gnu=$ac_cv_c_compiler_gnu
9676
9677 fi
9678
9679
9680 # Path setups for Cray, according to IEEE or CFP.  These must come after
9681 # deciding the compiler.
9682 #
9683
9684 { echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
9685 echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; }
9686 if test "${ac_cv_path_GREP+set}" = set; then
9687   echo $ECHO_N "(cached) $ECHO_C" >&6
9688 else
9689   # Extract the first word of "grep ggrep" to use in msg output
9690 if test -z "$GREP"; then
9691 set dummy grep ggrep; ac_prog_name=$2
9692 if test "${ac_cv_path_GREP+set}" = set; then
9693   echo $ECHO_N "(cached) $ECHO_C" >&6
9694 else
9695   ac_path_GREP_found=false
9696 # Loop through the user's path and test for each of PROGNAME-LIST
9697 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9698 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
9699 do
9700   IFS=$as_save_IFS
9701   test -z "$as_dir" && as_dir=.
9702   for ac_prog in grep ggrep; do
9703   for ac_exec_ext in '' $ac_executable_extensions; do
9704     ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
9705     { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
9706     # Check for GNU ac_path_GREP and select it if it is found.
9707   # Check for GNU $ac_path_GREP
9708 case `"$ac_path_GREP" --version 2>&1` in
9709 *GNU*)
9710   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
9711 *)
9712   ac_count=0
9713   echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
9714   while :
9715   do
9716     cat "conftest.in" "conftest.in" >"conftest.tmp"
9717     mv "conftest.tmp" "conftest.in"
9718     cp "conftest.in" "conftest.nl"
9719     echo 'GREP' >> "conftest.nl"
9720     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
9721     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
9722     ac_count=`expr $ac_count + 1`
9723     if test $ac_count -gt ${ac_path_GREP_max-0}; then
9724       # Best one so far, save it but keep looking for a better one
9725       ac_cv_path_GREP="$ac_path_GREP"
9726       ac_path_GREP_max=$ac_count
9727     fi
9728     # 10*(2^10) chars as input seems more than enough
9729     test $ac_count -gt 10 && break
9730   done
9731   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
9732 esac
9733
9734
9735     $ac_path_GREP_found && break 3
9736   done
9737 done
9738
9739 done
9740 IFS=$as_save_IFS
9741
9742
9743 fi
9744
9745 GREP="$ac_cv_path_GREP"
9746 if test -z "$GREP"; then
9747   { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
9748 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
9749    { (exit 1); exit 1; }; }
9750 fi
9751
9752 else
9753   ac_cv_path_GREP=$GREP
9754 fi
9755
9756
9757 fi
9758 { echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
9759 echo "${ECHO_T}$ac_cv_path_GREP" >&6; }
9760  GREP="$ac_cv_path_GREP"
9761
9762
9763 { echo "$as_me:$LINENO: checking for egrep" >&5
9764 echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
9765 if test "${ac_cv_path_EGREP+set}" = set; then
9766   echo $ECHO_N "(cached) $ECHO_C" >&6
9767 else
9768   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
9769    then ac_cv_path_EGREP="$GREP -E"
9770    else
9771      # Extract the first word of "egrep" to use in msg output
9772 if test -z "$EGREP"; then
9773 set dummy egrep; ac_prog_name=$2
9774 if test "${ac_cv_path_EGREP+set}" = set; then
9775   echo $ECHO_N "(cached) $ECHO_C" >&6
9776 else
9777   ac_path_EGREP_found=false
9778 # Loop through the user's path and test for each of PROGNAME-LIST
9779 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9780 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
9781 do
9782   IFS=$as_save_IFS
9783   test -z "$as_dir" && as_dir=.
9784   for ac_prog in egrep; do
9785   for ac_exec_ext in '' $ac_executable_extensions; do
9786     ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
9787     { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
9788     # Check for GNU ac_path_EGREP and select it if it is found.
9789   # Check for GNU $ac_path_EGREP
9790 case `"$ac_path_EGREP" --version 2>&1` in
9791 *GNU*)
9792   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
9793 *)
9794   ac_count=0
9795   echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
9796   while :
9797   do
9798     cat "conftest.in" "conftest.in" >"conftest.tmp"
9799     mv "conftest.tmp" "conftest.in"
9800     cp "conftest.in" "conftest.nl"
9801     echo 'EGREP' >> "conftest.nl"
9802     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
9803     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
9804     ac_count=`expr $ac_count + 1`
9805     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
9806       # Best one so far, save it but keep looking for a better one
9807       ac_cv_path_EGREP="$ac_path_EGREP"
9808       ac_path_EGREP_max=$ac_count
9809     fi
9810     # 10*(2^10) chars as input seems more than enough
9811     test $ac_count -gt 10 && break
9812   done
9813   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
9814 esac
9815
9816
9817     $ac_path_EGREP_found && break 3
9818   done
9819 done
9820
9821 done
9822 IFS=$as_save_IFS
9823
9824
9825 fi
9826
9827 EGREP="$ac_cv_path_EGREP"
9828 if test -z "$EGREP"; then
9829   { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
9830 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
9831    { (exit 1); exit 1; }; }
9832 fi
9833
9834 else
9835   ac_cv_path_EGREP=$EGREP
9836 fi
9837
9838
9839    fi
9840 fi
9841 { echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
9842 echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
9843  EGREP="$ac_cv_path_EGREP"
9844
9845
9846 case $host_cpu in
9847   c90 | t90)
9848     cat >conftest.$ac_ext <<_ACEOF
9849 /* confdefs.h.  */
9850 _ACEOF
9851 cat confdefs.h >>conftest.$ac_ext
9852 cat >>conftest.$ac_ext <<_ACEOF
9853 /* end confdefs.h.  */
9854 #ifdef _CRAYIEEE
9855 yes
9856 #endif
9857 _ACEOF
9858 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9859   $EGREP "yes" >/dev/null 2>&1; then
9860   add_path="cray/ieee"
9861 else
9862   add_path="cray/cfp"; extra_functions="mulwwc90"
9863 fi
9864 rm -f conftest*
9865
9866     ;;
9867   j90 | sv1)
9868     add_path="cray/cfp"; extra_functions="mulwwj90"
9869     ;;
9870 esac
9871
9872
9873
9874 if test -z "$MPN_PATH"; then
9875   path="$add_path $path"
9876 fi
9877
9878 # For a nail build, also look in "nails" subdirectories.
9879 #
9880 if test $GMP_NAIL_BITS != 0 && test -z "$MPN_PATH"; then
9881   new_path=
9882   for i in $path; do
9883     case $i in
9884     generic) new_path="$new_path $i" ;;
9885     *)       new_path="$new_path $i/nails $i" ;;
9886     esac
9887   done
9888   path=$new_path
9889 fi
9890
9891
9892 # Put all directories into CPUVEC_list so as to get a full set of
9893 # CPUVEC_SETUP_$tmp_suffix defines into config.h, even if some of them are
9894 # empty because mmx and/or sse2 had to be dropped.
9895 #
9896 for i in $fat_path; do
9897   tmp_suffix=`echo $i | sed -e '/\//s:^[^/]*/::' -e 's:[\\/]:_:g'`
9898   CPUVEC_list="$CPUVEC_list CPUVEC_SETUP_$tmp_suffix"
9899 done
9900
9901
9902 # If there's any sse2 or mmx in the path, check whether the assembler
9903 # supports it, and remove if not.
9904 #
9905 # We only need this in ABI=32, for ABI=64 on x86_64 we can assume a new
9906 # enough assembler.
9907 #
9908 case $host in
9909   i?86*-*-* | k[5-8]*-*-* | pentium*-*-* | athlon-*-* | viac3*-*-* | geode*-*-* | athlon64-*-* | atom-*-* | core2-*-* | x86_64-*-*)
9910     if test "$ABI" = 32; then
9911       case "$path $fat_path" in
9912         *mmx*)   { echo "$as_me:$LINENO: checking if the assembler knows about MMX instructions" >&5
9913 echo $ECHO_N "checking if the assembler knows about MMX instructions... $ECHO_C" >&6; }
9914 if test "${gmp_cv_asm_x86_mmx+set}" = set; then
9915   echo $ECHO_N "(cached) $ECHO_C" >&6
9916 else
9917   cat >conftest.s <<EOF
9918         .text
9919         movq    %mm0, %mm1
9920 EOF
9921 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
9922 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
9923   (eval $gmp_assemble) 2>&5
9924   ac_status=$?
9925   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9926   (exit $ac_status); }; then
9927   cat conftest.out >&5
9928   gmp_cv_asm_x86_mmx=yes
9929 case $host in
9930 *-*-solaris*)
9931   if (dis conftest.$OBJEXT >conftest.out) 2>/dev/null; then
9932     if grep "0f 6f c1" conftest.out >/dev/null; then
9933       gmp_cv_asm_x86_mmx=movq-bug
9934     fi
9935   else
9936     { echo "$as_me:$LINENO: WARNING: \"dis\" not available to check for \"as\" movq bug" >&5
9937 echo "$as_me: WARNING: \"dis\" not available to check for \"as\" movq bug" >&2;}
9938   fi
9939 esac
9940 else
9941   cat conftest.out >&5
9942   echo "configure: failed program was:" >&5
9943   cat conftest.s >&5
9944   gmp_cv_asm_x86_mmx=no
9945 fi
9946 rm -f conftest*
9947
9948 fi
9949 { echo "$as_me:$LINENO: result: $gmp_cv_asm_x86_mmx" >&5
9950 echo "${ECHO_T}$gmp_cv_asm_x86_mmx" >&6; }
9951
9952 case $gmp_cv_asm_x86_mmx in
9953 movq-bug)
9954   { echo "$as_me:$LINENO: WARNING: +----------------------------------------------------------" >&5
9955 echo "$as_me: WARNING: +----------------------------------------------------------" >&2;}
9956   { echo "$as_me:$LINENO: WARNING: | WARNING WARNING WARNING" >&5
9957 echo "$as_me: WARNING: | WARNING WARNING WARNING" >&2;}
9958   { echo "$as_me:$LINENO: WARNING: | Host CPU has MMX code, but the assembler" >&5
9959 echo "$as_me: WARNING: | Host CPU has MMX code, but the assembler" >&2;}
9960   { echo "$as_me:$LINENO: WARNING: |     $CCAS $CFLAGS $CPPFLAGS" >&5
9961 echo "$as_me: WARNING: |     $CCAS $CFLAGS $CPPFLAGS" >&2;}
9962   { echo "$as_me:$LINENO: WARNING: | has the Solaris 2.6 and 2.7 bug where register to register" >&5
9963 echo "$as_me: WARNING: | has the Solaris 2.6 and 2.7 bug where register to register" >&2;}
9964   { echo "$as_me:$LINENO: WARNING: | movq operands are reversed." >&5
9965 echo "$as_me: WARNING: | movq operands are reversed." >&2;}
9966   { echo "$as_me:$LINENO: WARNING: | Non-MMX replacements will be used." >&5
9967 echo "$as_me: WARNING: | Non-MMX replacements will be used." >&2;}
9968   { echo "$as_me:$LINENO: WARNING: | This will be an inferior build." >&5
9969 echo "$as_me: WARNING: | This will be an inferior build." >&2;}
9970   { echo "$as_me:$LINENO: WARNING: +----------------------------------------------------------" >&5
9971 echo "$as_me: WARNING: +----------------------------------------------------------" >&2;}
9972   ;;
9973 no)
9974   { echo "$as_me:$LINENO: WARNING: +----------------------------------------------------------" >&5
9975 echo "$as_me: WARNING: +----------------------------------------------------------" >&2;}
9976   { echo "$as_me:$LINENO: WARNING: | WARNING WARNING WARNING" >&5
9977 echo "$as_me: WARNING: | WARNING WARNING WARNING" >&2;}
9978   { echo "$as_me:$LINENO: WARNING: | Host CPU has MMX code, but it can't be assembled by" >&5
9979 echo "$as_me: WARNING: | Host CPU has MMX code, but it can't be assembled by" >&2;}
9980   { echo "$as_me:$LINENO: WARNING: |     $CCAS $CFLAGS $CPPFLAGS" >&5
9981 echo "$as_me: WARNING: |     $CCAS $CFLAGS $CPPFLAGS" >&2;}
9982   { echo "$as_me:$LINENO: WARNING: | Non-MMX replacements will be used." >&5
9983 echo "$as_me: WARNING: | Non-MMX replacements will be used." >&2;}
9984   { echo "$as_me:$LINENO: WARNING: | This will be an inferior build." >&5
9985 echo "$as_me: WARNING: | This will be an inferior build." >&2;}
9986   { echo "$as_me:$LINENO: WARNING: +----------------------------------------------------------" >&5
9987 echo "$as_me: WARNING: +----------------------------------------------------------" >&2;}
9988   ;;
9989 esac
9990 if test "$gmp_cv_asm_x86_mmx" = yes; then
9991   :
9992 else
9993   tmp_path=
9994 for i in $path; do
9995   case $i in
9996     */*mmx*) ;;
9997     *) tmp_path="$tmp_path $i" ;;
9998   esac
9999 done
10000 path="$tmp_path"
10001
10002 tmp_path=
10003 for i in $fat_path; do
10004   case $i in
10005     */*mmx*) ;;
10006     *) tmp_path="$tmp_path $i" ;;
10007   esac
10008 done
10009 fat_path="$tmp_path"
10010
10011
10012 fi
10013  ;;
10014       esac
10015       case "$path $fat_path" in
10016         *sse2*)  { echo "$as_me:$LINENO: checking if the assembler knows about SSE2 instructions" >&5
10017 echo $ECHO_N "checking if the assembler knows about SSE2 instructions... $ECHO_C" >&6; }
10018 if test "${gmp_cv_asm_x86_sse2+set}" = set; then
10019   echo $ECHO_N "(cached) $ECHO_C" >&6
10020 else
10021   cat >conftest.s <<EOF
10022         .text
10023         paddq   %mm0, %mm1
10024 EOF
10025 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
10026 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
10027   (eval $gmp_assemble) 2>&5
10028   ac_status=$?
10029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10030   (exit $ac_status); }; then
10031   cat conftest.out >&5
10032   gmp_cv_asm_x86_sse2=yes
10033 else
10034   cat conftest.out >&5
10035   echo "configure: failed program was:" >&5
10036   cat conftest.s >&5
10037   gmp_cv_asm_x86_sse2=no
10038 fi
10039 rm -f conftest*
10040
10041
10042 fi
10043 { echo "$as_me:$LINENO: result: $gmp_cv_asm_x86_sse2" >&5
10044 echo "${ECHO_T}$gmp_cv_asm_x86_sse2" >&6; }
10045 case $gmp_cv_asm_x86_sse2 in
10046 yes)
10047   :
10048   ;;
10049 *)
10050   { echo "$as_me:$LINENO: WARNING: +----------------------------------------------------------" >&5
10051 echo "$as_me: WARNING: +----------------------------------------------------------" >&2;}
10052   { echo "$as_me:$LINENO: WARNING: | WARNING WARNING WARNING" >&5
10053 echo "$as_me: WARNING: | WARNING WARNING WARNING" >&2;}
10054   { echo "$as_me:$LINENO: WARNING: | Host CPU has SSE2 code, but it can't be assembled by" >&5
10055 echo "$as_me: WARNING: | Host CPU has SSE2 code, but it can't be assembled by" >&2;}
10056   { echo "$as_me:$LINENO: WARNING: |     $CCAS $CFLAGS $CPPFLAGS" >&5
10057 echo "$as_me: WARNING: |     $CCAS $CFLAGS $CPPFLAGS" >&2;}
10058   { echo "$as_me:$LINENO: WARNING: | Non-SSE2 replacements will be used." >&5
10059 echo "$as_me: WARNING: | Non-SSE2 replacements will be used." >&2;}
10060   { echo "$as_me:$LINENO: WARNING: | This will be an inferior build." >&5
10061 echo "$as_me: WARNING: | This will be an inferior build." >&2;}
10062   { echo "$as_me:$LINENO: WARNING: +----------------------------------------------------------" >&5
10063 echo "$as_me: WARNING: +----------------------------------------------------------" >&2;}
10064   tmp_path=
10065 for i in $path; do
10066   case $i in
10067     */sse2) ;;
10068     *) tmp_path="$tmp_path $i" ;;
10069   esac
10070 done
10071 path="$tmp_path"
10072
10073 tmp_path=
10074 for i in $fat_path; do
10075   case $i in
10076     */sse2) ;;
10077     *) tmp_path="$tmp_path $i" ;;
10078   esac
10079 done
10080 fat_path="$tmp_path"
10081
10082
10083   ;;
10084 esac
10085  ;;
10086       esac
10087     fi
10088     ;;
10089 esac
10090
10091
10092 cat >&5 <<EOF
10093 Decided:
10094 ABI=$ABI
10095 CC=$CC
10096 CFLAGS=$CFLAGS
10097 CPPFLAGS=$CPPFLAGS
10098 GMP_LDFLAGS=$GMP_LDFLAGS
10099 CXX=$CXX
10100 CXXFLAGS=$CXXFLAGS
10101 path=$path
10102 EOF
10103 echo "using ABI=\"$ABI\""
10104 echo "      CC=\"$CC\""
10105 echo "      CFLAGS=\"$CFLAGS\""
10106 echo "      CPPFLAGS=\"$CPPFLAGS\""
10107 if test $want_cxx = yes; then
10108   echo "      CXX=\"$CXX\""
10109   echo "      CXXFLAGS=\"$CXXFLAGS\""
10110 fi
10111 echo "      MPN_PATH=\"$path\""
10112
10113
10114 # Automake ansi2knr support.
10115 { echo "$as_me:$LINENO: checking for function prototypes" >&5
10116 echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6; }
10117 if test "$ac_cv_prog_cc_c89" != no; then
10118   { echo "$as_me:$LINENO: result: yes" >&5
10119 echo "${ECHO_T}yes" >&6; }
10120
10121 cat >>confdefs.h <<\_ACEOF
10122 #define PROTOTYPES 1
10123 _ACEOF
10124
10125
10126 cat >>confdefs.h <<\_ACEOF
10127 #define __PROTOTYPES 1
10128 _ACEOF
10129
10130 else
10131   { echo "$as_me:$LINENO: result: no" >&5
10132 echo "${ECHO_T}no" >&6; }
10133 fi
10134
10135 { echo "$as_me:$LINENO: checking for ANSI C header files" >&5
10136 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
10137 if test "${ac_cv_header_stdc+set}" = set; then
10138   echo $ECHO_N "(cached) $ECHO_C" >&6
10139 else
10140   cat >conftest.$ac_ext <<_ACEOF
10141 /* confdefs.h.  */
10142 _ACEOF
10143 cat confdefs.h >>conftest.$ac_ext
10144 cat >>conftest.$ac_ext <<_ACEOF
10145 /* end confdefs.h.  */
10146 #include <stdlib.h>
10147 #include <stdarg.h>
10148 #include <string.h>
10149 #include <float.h>
10150
10151 int
10152 main ()
10153 {
10154
10155   ;
10156   return 0;
10157 }
10158 _ACEOF
10159 rm -f conftest.$ac_objext
10160 if { (ac_try="$ac_compile"
10161 case "(($ac_try" in
10162   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10163   *) ac_try_echo=$ac_try;;
10164 esac
10165 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10166   (eval "$ac_compile") 2>conftest.er1
10167   ac_status=$?
10168   grep -v '^ *+' conftest.er1 >conftest.err
10169   rm -f conftest.er1
10170   cat conftest.err >&5
10171   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10172   (exit $ac_status); } && {
10173          test -z "$ac_c_werror_flag" ||
10174          test ! -s conftest.err
10175        } && test -s conftest.$ac_objext; then
10176   ac_cv_header_stdc=yes
10177 else
10178   echo "$as_me: failed program was:" >&5
10179 sed 's/^/| /' conftest.$ac_ext >&5
10180
10181         ac_cv_header_stdc=no
10182 fi
10183
10184 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10185
10186 if test $ac_cv_header_stdc = yes; then
10187   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
10188   cat >conftest.$ac_ext <<_ACEOF
10189 /* confdefs.h.  */
10190 _ACEOF
10191 cat confdefs.h >>conftest.$ac_ext
10192 cat >>conftest.$ac_ext <<_ACEOF
10193 /* end confdefs.h.  */
10194 #include <string.h>
10195
10196 _ACEOF
10197 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10198   $EGREP "memchr" >/dev/null 2>&1; then
10199   :
10200 else
10201   ac_cv_header_stdc=no
10202 fi
10203 rm -f conftest*
10204
10205 fi
10206
10207 if test $ac_cv_header_stdc = yes; then
10208   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
10209   cat >conftest.$ac_ext <<_ACEOF
10210 /* confdefs.h.  */
10211 _ACEOF
10212 cat confdefs.h >>conftest.$ac_ext
10213 cat >>conftest.$ac_ext <<_ACEOF
10214 /* end confdefs.h.  */
10215 #include <stdlib.h>
10216
10217 _ACEOF
10218 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10219   $EGREP "free" >/dev/null 2>&1; then
10220   :
10221 else
10222   ac_cv_header_stdc=no
10223 fi
10224 rm -f conftest*
10225
10226 fi
10227
10228 if test $ac_cv_header_stdc = yes; then
10229   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
10230   if test "$cross_compiling" = yes; then
10231   :
10232 else
10233   cat >conftest.$ac_ext <<_ACEOF
10234 /* confdefs.h.  */
10235 _ACEOF
10236 cat confdefs.h >>conftest.$ac_ext
10237 cat >>conftest.$ac_ext <<_ACEOF
10238 /* end confdefs.h.  */
10239 #include <ctype.h>
10240 #include <stdlib.h>
10241 #if ((' ' & 0x0FF) == 0x020)
10242 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
10243 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
10244 #else
10245 # define ISLOWER(c) \
10246                    (('a' <= (c) && (c) <= 'i') \
10247                      || ('j' <= (c) && (c) <= 'r') \
10248                      || ('s' <= (c) && (c) <= 'z'))
10249 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
10250 #endif
10251
10252 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
10253 int
10254 main ()
10255 {
10256   int i;
10257   for (i = 0; i < 256; i++)
10258     if (XOR (islower (i), ISLOWER (i))
10259         || toupper (i) != TOUPPER (i))
10260       return 2;
10261   return 0;
10262 }
10263 _ACEOF
10264 rm -f conftest$ac_exeext
10265 if { (ac_try="$ac_link"
10266 case "(($ac_try" in
10267   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10268   *) ac_try_echo=$ac_try;;
10269 esac
10270 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10271   (eval "$ac_link") 2>&5
10272   ac_status=$?
10273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10274   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
10275   { (case "(($ac_try" in
10276   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10277   *) ac_try_echo=$ac_try;;
10278 esac
10279 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10280   (eval "$ac_try") 2>&5
10281   ac_status=$?
10282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10283   (exit $ac_status); }; }; then
10284   :
10285 else
10286   echo "$as_me: program exited with status $ac_status" >&5
10287 echo "$as_me: failed program was:" >&5
10288 sed 's/^/| /' conftest.$ac_ext >&5
10289
10290 ( exit $ac_status )
10291 ac_cv_header_stdc=no
10292 fi
10293 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
10294 fi
10295
10296
10297 fi
10298 fi
10299 { echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
10300 echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
10301 if test $ac_cv_header_stdc = yes; then
10302
10303 cat >>confdefs.h <<\_ACEOF
10304 #define STDC_HEADERS 1
10305 _ACEOF
10306
10307 fi
10308
10309 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
10310
10311
10312
10313
10314
10315
10316
10317
10318
10319 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
10320                   inttypes.h stdint.h unistd.h
10321 do
10322 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10323 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10324 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10325 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10326   echo $ECHO_N "(cached) $ECHO_C" >&6
10327 else
10328   cat >conftest.$ac_ext <<_ACEOF
10329 /* confdefs.h.  */
10330 _ACEOF
10331 cat confdefs.h >>conftest.$ac_ext
10332 cat >>conftest.$ac_ext <<_ACEOF
10333 /* end confdefs.h.  */
10334 $ac_includes_default
10335
10336 #include <$ac_header>
10337 _ACEOF
10338 rm -f conftest.$ac_objext
10339 if { (ac_try="$ac_compile"
10340 case "(($ac_try" in
10341   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10342   *) ac_try_echo=$ac_try;;
10343 esac
10344 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10345   (eval "$ac_compile") 2>conftest.er1
10346   ac_status=$?
10347   grep -v '^ *+' conftest.er1 >conftest.err
10348   rm -f conftest.er1
10349   cat conftest.err >&5
10350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10351   (exit $ac_status); } && {
10352          test -z "$ac_c_werror_flag" ||
10353          test ! -s conftest.err
10354        } && test -s conftest.$ac_objext; then
10355   eval "$as_ac_Header=yes"
10356 else
10357   echo "$as_me: failed program was:" >&5
10358 sed 's/^/| /' conftest.$ac_ext >&5
10359
10360         eval "$as_ac_Header=no"
10361 fi
10362
10363 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10364 fi
10365 ac_res=`eval echo '${'$as_ac_Header'}'`
10366                { echo "$as_me:$LINENO: result: $ac_res" >&5
10367 echo "${ECHO_T}$ac_res" >&6; }
10368 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10369   cat >>confdefs.h <<_ACEOF
10370 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10371 _ACEOF
10372
10373 fi
10374
10375 done
10376
10377
10378
10379 if test "$ac_cv_prog_cc_stdc" != no; then
10380   U= ANSI2KNR=
10381 else
10382   U=_ ANSI2KNR=./ansi2knr
10383 fi
10384 # Ensure some checks needed by ansi2knr itself.
10385
10386
10387 for ac_header in string.h
10388 do
10389 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10390 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10391   { echo "$as_me:$LINENO: checking for $ac_header" >&5
10392 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10393 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10394   echo $ECHO_N "(cached) $ECHO_C" >&6
10395 fi
10396 ac_res=`eval echo '${'$as_ac_Header'}'`
10397                { echo "$as_me:$LINENO: result: $ac_res" >&5
10398 echo "${ECHO_T}$ac_res" >&6; }
10399 else
10400   # Is the header compilable?
10401 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
10402 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
10403 cat >conftest.$ac_ext <<_ACEOF
10404 /* confdefs.h.  */
10405 _ACEOF
10406 cat confdefs.h >>conftest.$ac_ext
10407 cat >>conftest.$ac_ext <<_ACEOF
10408 /* end confdefs.h.  */
10409 $ac_includes_default
10410 #include <$ac_header>
10411 _ACEOF
10412 rm -f conftest.$ac_objext
10413 if { (ac_try="$ac_compile"
10414 case "(($ac_try" in
10415   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10416   *) ac_try_echo=$ac_try;;
10417 esac
10418 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10419   (eval "$ac_compile") 2>conftest.er1
10420   ac_status=$?
10421   grep -v '^ *+' conftest.er1 >conftest.err
10422   rm -f conftest.er1
10423   cat conftest.err >&5
10424   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10425   (exit $ac_status); } && {
10426          test -z "$ac_c_werror_flag" ||
10427          test ! -s conftest.err
10428        } && test -s conftest.$ac_objext; then
10429   ac_header_compiler=yes
10430 else
10431   echo "$as_me: failed program was:" >&5
10432 sed 's/^/| /' conftest.$ac_ext >&5
10433
10434         ac_header_compiler=no
10435 fi
10436
10437 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10438 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10439 echo "${ECHO_T}$ac_header_compiler" >&6; }
10440
10441 # Is the header present?
10442 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
10443 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
10444 cat >conftest.$ac_ext <<_ACEOF
10445 /* confdefs.h.  */
10446 _ACEOF
10447 cat confdefs.h >>conftest.$ac_ext
10448 cat >>conftest.$ac_ext <<_ACEOF
10449 /* end confdefs.h.  */
10450 #include <$ac_header>
10451 _ACEOF
10452 if { (ac_try="$ac_cpp conftest.$ac_ext"
10453 case "(($ac_try" in
10454   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10455   *) ac_try_echo=$ac_try;;
10456 esac
10457 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10458   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10459   ac_status=$?
10460   grep -v '^ *+' conftest.er1 >conftest.err
10461   rm -f conftest.er1
10462   cat conftest.err >&5
10463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10464   (exit $ac_status); } >/dev/null && {
10465          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10466          test ! -s conftest.err
10467        }; then
10468   ac_header_preproc=yes
10469 else
10470   echo "$as_me: failed program was:" >&5
10471 sed 's/^/| /' conftest.$ac_ext >&5
10472
10473   ac_header_preproc=no
10474 fi
10475
10476 rm -f conftest.err conftest.$ac_ext
10477 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10478 echo "${ECHO_T}$ac_header_preproc" >&6; }
10479
10480 # So?  What about this header?
10481 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10482   yes:no: )
10483     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10484 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10485     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10486 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10487     ac_header_preproc=yes
10488     ;;
10489   no:yes:* )
10490     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10491 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10492     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10493 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10494     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10495 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10496     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10497 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10498     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10499 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10500     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10501 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10502     ( cat <<\_ASBOX
10503 ## ---------------------------------- ##
10504 ## Report this to gmp-bugs@gmplib.org ##
10505 ## ---------------------------------- ##
10506 _ASBOX
10507      ) | sed "s/^/$as_me: WARNING:     /" >&2
10508     ;;
10509 esac
10510 { echo "$as_me:$LINENO: checking for $ac_header" >&5
10511 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10512 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10513   echo $ECHO_N "(cached) $ECHO_C" >&6
10514 else
10515   eval "$as_ac_Header=\$ac_header_preproc"
10516 fi
10517 ac_res=`eval echo '${'$as_ac_Header'}'`
10518                { echo "$as_me:$LINENO: result: $ac_res" >&5
10519 echo "${ECHO_T}$ac_res" >&6; }
10520
10521 fi
10522 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10523   cat >>confdefs.h <<_ACEOF
10524 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10525 _ACEOF
10526
10527 fi
10528
10529 done
10530
10531
10532
10533
10534 { echo "$as_me:$LINENO: checking whether assembler supports --noexecstack option" >&5
10535 echo $ECHO_N "checking whether assembler supports --noexecstack option... $ECHO_C" >&6; }
10536 if test "${cl_cv_as_noexecstack+set}" = set; then
10537   echo $ECHO_N "(cached) $ECHO_C" >&6
10538 else
10539     cat > conftest.c <<EOF
10540 void foo() {}
10541 EOF
10542   if { ac_try='${CC} $CFLAGS $CPPFLAGS
10543                      -S -o conftest.s conftest.c >/dev/null'
10544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10545   (eval $ac_try) 2>&5
10546   ac_status=$?
10547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10548   (exit $ac_status); }; } \
10549      && grep .note.GNU-stack conftest.s >/dev/null \
10550      && { ac_try='${CC} $CFLAGS $CPPFLAGS -Wa,--noexecstack
10551                        -c -o conftest.o conftest.s >/dev/null'
10552   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10553   (eval $ac_try) 2>&5
10554   ac_status=$?
10555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10556   (exit $ac_status); }; }
10557   then
10558     cl_cv_as_noexecstack=yes
10559   else
10560     cl_cv_as_noexecstack=no
10561   fi
10562   rm -f conftest*
10563 fi
10564 { echo "$as_me:$LINENO: result: $cl_cv_as_noexecstack" >&5
10565 echo "${ECHO_T}$cl_cv_as_noexecstack" >&6; }
10566   if test "$cl_cv_as_noexecstack" = yes; then
10567     ASMFLAGS="$ASMFLAGS -Wa,--noexecstack"
10568   fi
10569
10570
10571
10572
10573 gmp_user_AR=$AR
10574 if test -n "$ac_tool_prefix"; then
10575   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
10576 set dummy ${ac_tool_prefix}ar; ac_word=$2
10577 { echo "$as_me:$LINENO: checking for $ac_word" >&5
10578 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
10579 if test "${ac_cv_prog_AR+set}" = set; then
10580   echo $ECHO_N "(cached) $ECHO_C" >&6
10581 else
10582   if test -n "$AR"; then
10583   ac_cv_prog_AR="$AR" # Let the user override the test.
10584 else
10585 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10586 for as_dir in $PATH
10587 do
10588   IFS=$as_save_IFS
10589   test -z "$as_dir" && as_dir=.
10590   for ac_exec_ext in '' $ac_executable_extensions; do
10591   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10592     ac_cv_prog_AR="${ac_tool_prefix}ar"
10593     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
10594     break 2
10595   fi
10596 done
10597 done
10598 IFS=$as_save_IFS
10599
10600 fi
10601 fi
10602 AR=$ac_cv_prog_AR
10603 if test -n "$AR"; then
10604   { echo "$as_me:$LINENO: result: $AR" >&5
10605 echo "${ECHO_T}$AR" >&6; }
10606 else
10607   { echo "$as_me:$LINENO: result: no" >&5
10608 echo "${ECHO_T}no" >&6; }
10609 fi
10610
10611
10612 fi
10613 if test -z "$ac_cv_prog_AR"; then
10614   ac_ct_AR=$AR
10615   # Extract the first word of "ar", so it can be a program name with args.
10616 set dummy ar; ac_word=$2
10617 { echo "$as_me:$LINENO: checking for $ac_word" >&5
10618 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
10619 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
10620   echo $ECHO_N "(cached) $ECHO_C" >&6
10621 else
10622   if test -n "$ac_ct_AR"; then
10623   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
10624 else
10625 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10626 for as_dir in $PATH
10627 do
10628   IFS=$as_save_IFS
10629   test -z "$as_dir" && as_dir=.
10630   for ac_exec_ext in '' $ac_executable_extensions; do
10631   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10632     ac_cv_prog_ac_ct_AR="ar"
10633     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
10634     break 2
10635   fi
10636 done
10637 done
10638 IFS=$as_save_IFS
10639
10640 fi
10641 fi
10642 ac_ct_AR=$ac_cv_prog_ac_ct_AR
10643 if test -n "$ac_ct_AR"; then
10644   { echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
10645 echo "${ECHO_T}$ac_ct_AR" >&6; }
10646 else
10647   { echo "$as_me:$LINENO: result: no" >&5
10648 echo "${ECHO_T}no" >&6; }
10649 fi
10650
10651   if test "x$ac_ct_AR" = x; then
10652     AR="ar"
10653   else
10654     case $cross_compiling:$ac_tool_warned in
10655 yes:)
10656 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
10657 whose name does not start with the host triplet.  If you think this
10658 configuration is useful to you, please write to autoconf@gnu.org." >&5
10659 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
10660 whose name does not start with the host triplet.  If you think this
10661 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
10662 ac_tool_warned=yes ;;
10663 esac
10664     AR=$ac_ct_AR
10665   fi
10666 else
10667   AR="$ac_cv_prog_AR"
10668 fi
10669
10670 if test -z "$gmp_user_AR"; then
10671                         eval arflags=\"\$ar${abi1}_flags\"
10672   test -n "$arflags" || eval arflags=\"\$ar${abi2}_flags\"
10673   if test -n "$arflags"; then
10674     { echo "$as_me:$LINENO: checking for extra ar flags" >&5
10675 echo $ECHO_N "checking for extra ar flags... $ECHO_C" >&6; }
10676     AR="$AR $arflags"
10677     ac_cv_prog_AR="$AR $arflags"
10678     ac_cv_prog_ac_ct_AR="$AR $arflags"
10679     { echo "$as_me:$LINENO: result: $arflags" >&5
10680 echo "${ECHO_T}$arflags" >&6; }
10681   fi
10682 fi
10683 if test -z "$AR_FLAGS"; then
10684   AR_FLAGS=cq
10685 fi
10686
10687
10688 gmp_user_NM=$NM
10689 { echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
10690 echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6; }
10691 if test "${lt_cv_path_NM+set}" = set; then
10692   echo $ECHO_N "(cached) $ECHO_C" >&6
10693 else
10694   if test -n "$NM"; then
10695   # Let the user override the test.
10696   lt_cv_path_NM="$NM"
10697 else
10698   lt_nm_to_check="${ac_tool_prefix}nm"
10699   if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
10700     lt_nm_to_check="$lt_nm_to_check nm"
10701   fi
10702   for lt_tmp_nm in $lt_nm_to_check; do
10703     lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
10704     for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
10705       IFS="$lt_save_ifs"
10706       test -z "$ac_dir" && ac_dir=.
10707       tmp_nm="$ac_dir/$lt_tmp_nm"
10708       if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
10709         # Check to see if the nm accepts a BSD-compat flag.
10710         # Adding the `sed 1q' prevents false positives on HP-UX, which says:
10711         #   nm: unknown option "B" ignored
10712         # Tru64's nm complains that /dev/null is an invalid object file
10713         case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
10714         */dev/null* | *'Invalid file or object type'*)
10715           lt_cv_path_NM="$tmp_nm -B"
10716           break
10717           ;;
10718         *)
10719           case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
10720           */dev/null*)
10721             lt_cv_path_NM="$tmp_nm -p"
10722             break
10723             ;;
10724           *)
10725             lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
10726             continue # so that we can try to find one that supports BSD flags
10727             ;;
10728           esac
10729           ;;
10730         esac
10731       fi
10732     done
10733     IFS="$lt_save_ifs"
10734   done
10735   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
10736 fi
10737 fi
10738 { echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
10739 echo "${ECHO_T}$lt_cv_path_NM" >&6; }
10740 NM="$lt_cv_path_NM"
10741
10742
10743 # FIXME: When cross compiling (ie. $ac_tool_prefix not empty), libtool
10744 # defaults to plain "nm" if a "${ac_tool_prefix}nm" is not found.  In this
10745 # case run it again to try the native "nm", firstly so that likely locations
10746 # are searched, secondly so that -B or -p are added if necessary for BSD
10747 # format.  This is necessary for instance on OSF with "./configure
10748 # --build=alphaev5-dec-osf --host=alphaev6-dec-osf".
10749 #
10750 if test -z "$gmp_user_NM" && test -n "$ac_tool_prefix" && test "$NM" = nm; then
10751   $as_unset lt_cv_path_NM
10752   gmp_save_ac_tool_prefix=$ac_tool_prefix
10753   ac_tool_prefix=
10754   NM=
10755   { echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5
10756 echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6; }
10757 if test "${lt_cv_path_NM+set}" = set; then
10758   echo $ECHO_N "(cached) $ECHO_C" >&6
10759 else
10760   if test -n "$NM"; then
10761   # Let the user override the test.
10762   lt_cv_path_NM="$NM"
10763 else
10764   lt_nm_to_check="${ac_tool_prefix}nm"
10765   if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
10766     lt_nm_to_check="$lt_nm_to_check nm"
10767   fi
10768   for lt_tmp_nm in $lt_nm_to_check; do
10769     lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
10770     for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
10771       IFS="$lt_save_ifs"
10772       test -z "$ac_dir" && ac_dir=.
10773       tmp_nm="$ac_dir/$lt_tmp_nm"
10774       if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
10775         # Check to see if the nm accepts a BSD-compat flag.
10776         # Adding the `sed 1q' prevents false positives on HP-UX, which says:
10777         #   nm: unknown option "B" ignored
10778         # Tru64's nm complains that /dev/null is an invalid object file
10779         case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
10780         */dev/null* | *'Invalid file or object type'*)
10781           lt_cv_path_NM="$tmp_nm -B"
10782           break
10783           ;;
10784         *)
10785           case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
10786           */dev/null*)
10787             lt_cv_path_NM="$tmp_nm -p"
10788             break
10789             ;;
10790           *)
10791             lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
10792             continue # so that we can try to find one that supports BSD flags
10793             ;;
10794           esac
10795           ;;
10796         esac
10797       fi
10798     done
10799     IFS="$lt_save_ifs"
10800   done
10801   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
10802 fi
10803 fi
10804 { echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
10805 echo "${ECHO_T}$lt_cv_path_NM" >&6; }
10806 NM="$lt_cv_path_NM"
10807
10808   ac_tool_prefix=$gmp_save_ac_tool_prefix
10809 fi
10810
10811 if test -z "$gmp_user_NM"; then
10812                         eval nmflags=\"\$nm${abi1}_flags\"
10813   test -n "$nmflags" || eval nmflags=\"\$nm${abi2}_flags\"
10814   if test -n "$nmflags"; then
10815     { echo "$as_me:$LINENO: checking for extra nm flags" >&5
10816 echo $ECHO_N "checking for extra nm flags... $ECHO_C" >&6; }
10817     NM="$NM $nmflags"
10818     { echo "$as_me:$LINENO: result: $nmflags" >&5
10819 echo "${ECHO_T}$nmflags" >&6; }
10820   fi
10821 fi
10822
10823
10824 case $host in
10825   # FIXME: On AIX 3 and 4, $libname.a is included in libtool
10826   # $library_names_spec, so libgmp.a becomes a symlink to libgmp.so, making
10827   # it impossible to build shared and static libraries simultaneously.
10828   # Disable shared libraries by default, but let the user override with
10829   # --enable-shared --disable-static.
10830   #
10831   # FIXME: This $libname.a problem looks like it might apply to *-*-amigaos*
10832   # and *-*-os2* too, but wait for someone to test this before worrying
10833   # about it.  If there is a problem then of course libtool is the right
10834   # place to fix it.
10835   #
10836   *-*-aix[34]*)
10837     if test -z "$enable_shared"; then enable_shared=no; fi ;;
10838 esac
10839
10840
10841 # Configs for Windows DLLs.
10842
10843
10844
10845
10846 LIBGMP_DLL=0
10847
10848 case $host in
10849   *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
10850     # By default, build only static.
10851     if test -z "$enable_shared"; then
10852       enable_shared=no
10853     fi
10854     # Don't allow both static and DLL.
10855     if test "$enable_shared" != no && test "$enable_static" != no; then
10856       { { echo "$as_me:$LINENO: error: cannot build both static and DLL, since gmp.h is different for each.
10857 Use \"--disable-static --enable-shared\" to build just a DLL." >&5
10858 echo "$as_me: error: cannot build both static and DLL, since gmp.h is different for each.
10859 Use \"--disable-static --enable-shared\" to build just a DLL." >&2;}
10860    { (exit 1); exit 1; }; }
10861     fi
10862
10863     # "-no-undefined" is required when building a DLL, see documentation on
10864     # AC_LIBTOOL_WIN32_DLL.
10865     #
10866     # "-Wl,--export-all-symbols" is a bit of a hack, it gets all libgmp and
10867     # libgmpxx functions and variables exported.  This is what libtool did
10868     # in the past, and it's convenient for us in the test programs.
10869     #
10870     # Maybe it'd be prudent to check for --export-all-symbols before using
10871     # it, but it seems to have been in ld since at least 2000, and there's
10872     # not really any alternative we want to take up at the moment.
10873     #
10874     # "-Wl,output-def" is used to get a .def file for use by MS lib to make
10875     # a .lib import library, described in the manual.  libgmp-3.dll.def
10876     # corresponds to the libmp-3.dll.def generated by libtool (as a result
10877     # of -export-symbols on that library).
10878     #
10879     # Incidentally, libtool does generate an import library libgmp.dll.a,
10880     # but it's "ar" format and cannot be used by the MS linker.  There
10881     # doesn't seem to be any GNU tool for generating or converting to .lib.
10882     #
10883     # FIXME: The .def files produced by -Wl,output-def include isascii,
10884     # iscsym, iscsymf and toascii, apparently because mingw ctype.h doesn't
10885     # inline isascii (used in gmp).  It gives an extern inline for
10886     # __isascii, but for some reason not the plain isascii.
10887     #
10888     if test "$enable_shared" = yes; then
10889       GMP_LDFLAGS="$GMP_LDFLAGS -no-undefined -Wl,--export-all-symbols"
10890       LIBGMP_LDFLAGS="$LIBGMP_LDFLAGS -Wl,--output-def,.libs/libgmp-3.dll.def"
10891       LIBGMPXX_LDFLAGS="$LIBGMP_LDFLAGS -Wl,--output-def,.libs/libgmpxx-3.dll.def"
10892       LIBGMP_DLL=1
10893     fi
10894     ;;
10895 esac
10896
10897
10898 # Ensure that $CONFIG_SHELL is available for AC_LIBTOOL_SYS_MAX_CMD_LEN.
10899 # It's often set already by _LT_AC_PROG_ECHO_BACKSLASH or
10900 # _AS_LINENO_PREPARE, but not always.
10901 #
10902 # The symptom of CONFIG_SHELL unset is some "expr" errors during the test,
10903 # and an empty result.  This only happens when invoked as "sh configure",
10904 # ie. no path, and can be seen for instance on ia64-*-hpux*.
10905 #
10906 # FIXME: Newer libtool should have it's own fix for this.
10907 #
10908 if test -z "$CONFIG_SHELL"; then
10909   CONFIG_SHELL=$SHELL
10910 fi
10911
10912 # Enable CXX in libtool only if we want it, and never enable GCJ, nor RC on
10913 # mingw and cygwin.  Under --disable-cxx this avoids some error messages
10914 # from libtool arising from the fact we didn't actually run AC_PROG_CXX.
10915 # Notice that any user-supplied --with-tags setting takes precedence.
10916 #
10917 # FIXME: Is this the right way to get this effect?  Very possibly not, but
10918 # the current _LT_AC_TAGCONFIG doesn't really suggest an alternative.
10919 #
10920 if test "${with_tags+set}" != set; then
10921   if test $want_cxx = yes; then
10922     with_tags=CXX
10923   else
10924     with_tags=
10925   fi
10926 fi
10927
10928 # The dead hand of AC_REQUIRE makes AC_PROG_LIBTOOL expand and execute
10929 # AC_PROG_F77, even when F77 is not in the selected with_tags.  This is
10930 # probably harmless, but it's unsightly and bloats our configure, so pretend
10931 # AC_PROG_F77 has been expanded already.
10932 #
10933 # FIXME: Rumour has it libtool will one day provide a way for a configure.in
10934 # to say what it wants from among supported languages etc.
10935 #
10936
10937
10938 # Check whether --enable-shared was given.
10939 if test "${enable_shared+set}" = set; then
10940   enableval=$enable_shared; p=${PACKAGE-default}
10941     case $enableval in
10942     yes) enable_shared=yes ;;
10943     no) enable_shared=no ;;
10944     *)
10945       enable_shared=no
10946       # Look at the argument we got.  We use all the common list separators.
10947       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10948       for pkg in $enableval; do
10949         IFS="$lt_save_ifs"
10950         if test "X$pkg" = "X$p"; then
10951           enable_shared=yes
10952         fi
10953       done
10954       IFS="$lt_save_ifs"
10955       ;;
10956     esac
10957 else
10958   enable_shared=yes
10959 fi
10960
10961
10962 # Check whether --enable-static was given.
10963 if test "${enable_static+set}" = set; then
10964   enableval=$enable_static; p=${PACKAGE-default}
10965     case $enableval in
10966     yes) enable_static=yes ;;
10967     no) enable_static=no ;;
10968     *)
10969      enable_static=no
10970       # Look at the argument we got.  We use all the common list separators.
10971       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10972       for pkg in $enableval; do
10973         IFS="$lt_save_ifs"
10974         if test "X$pkg" = "X$p"; then
10975           enable_static=yes
10976         fi
10977       done
10978       IFS="$lt_save_ifs"
10979       ;;
10980     esac
10981 else
10982   enable_static=yes
10983 fi
10984
10985
10986 # Check whether --enable-fast-install was given.
10987 if test "${enable_fast_install+set}" = set; then
10988   enableval=$enable_fast_install; p=${PACKAGE-default}
10989     case $enableval in
10990     yes) enable_fast_install=yes ;;
10991     no) enable_fast_install=no ;;
10992     *)
10993       enable_fast_install=no
10994       # Look at the argument we got.  We use all the common list separators.
10995       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
10996       for pkg in $enableval; do
10997         IFS="$lt_save_ifs"
10998         if test "X$pkg" = "X$p"; then
10999           enable_fast_install=yes
11000         fi
11001       done
11002       IFS="$lt_save_ifs"
11003       ;;
11004     esac
11005 else
11006   enable_fast_install=yes
11007 fi
11008
11009
11010 { echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
11011 echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6; }
11012 if test "${lt_cv_path_SED+set}" = set; then
11013   echo $ECHO_N "(cached) $ECHO_C" >&6
11014 else
11015   # Loop through the user's path and test for sed and gsed.
11016 # Then use that list of sed's as ones to test for truncation.
11017 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11018 for as_dir in $PATH
11019 do
11020   IFS=$as_save_IFS
11021   test -z "$as_dir" && as_dir=.
11022   for lt_ac_prog in sed gsed; do
11023     for ac_exec_ext in '' $ac_executable_extensions; do
11024       if { test -f "$as_dir/$lt_ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$lt_ac_prog$ac_exec_ext"; }; then
11025         lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext"
11026       fi
11027     done
11028   done
11029 done
11030 IFS=$as_save_IFS
11031 lt_ac_max=0
11032 lt_ac_count=0
11033 # Add /usr/xpg4/bin/sed as it is typically found on Solaris
11034 # along with /bin/sed that truncates output.
11035 for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do
11036   test ! -f $lt_ac_sed && continue
11037   cat /dev/null > conftest.in
11038   lt_ac_count=0
11039   echo $ECHO_N "0123456789$ECHO_C" >conftest.in
11040   # Check for GNU sed and select it if it is found.
11041   if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then
11042     lt_cv_path_SED=$lt_ac_sed
11043     break
11044   fi
11045   while true; do
11046     cat conftest.in conftest.in >conftest.tmp
11047     mv conftest.tmp conftest.in
11048     cp conftest.in conftest.nl
11049     echo >>conftest.nl
11050     $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break
11051     cmp -s conftest.out conftest.nl || break
11052     # 10000 chars as input seems more than enough
11053     test $lt_ac_count -gt 10 && break
11054     lt_ac_count=`expr $lt_ac_count + 1`
11055     if test $lt_ac_count -gt $lt_ac_max; then
11056       lt_ac_max=$lt_ac_count
11057       lt_cv_path_SED=$lt_ac_sed
11058     fi
11059   done
11060 done
11061
11062 fi
11063
11064 SED=$lt_cv_path_SED
11065
11066 { echo "$as_me:$LINENO: result: $SED" >&5
11067 echo "${ECHO_T}$SED" >&6; }
11068
11069
11070 # Check whether --with-gnu-ld was given.
11071 if test "${with_gnu_ld+set}" = set; then
11072   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
11073 else
11074   with_gnu_ld=no
11075 fi
11076
11077 ac_prog=ld
11078 if test "$GCC" = yes; then
11079   # Check if gcc -print-prog-name=ld gives a path.
11080   { echo "$as_me:$LINENO: checking for ld used by $CC" >&5
11081 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6; }
11082   case $host in
11083   *-*-mingw*)
11084     # gcc leaves a trailing carriage return which upsets mingw
11085     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
11086   *)
11087     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
11088   esac
11089   case $ac_prog in
11090     # Accept absolute paths.
11091     [\\/]* | ?:[\\/]*)
11092       re_direlt='/[^/][^/]*/\.\./'
11093       # Canonicalize the pathname of ld
11094       ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
11095       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
11096         ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
11097       done
11098       test -z "$LD" && LD="$ac_prog"
11099       ;;
11100   "")
11101     # If it fails, then pretend we aren't using GCC.
11102     ac_prog=ld
11103     ;;
11104   *)
11105     # If it is relative, then search for the first ld in PATH.
11106     with_gnu_ld=unknown
11107     ;;
11108   esac
11109 elif test "$with_gnu_ld" = yes; then
11110   { echo "$as_me:$LINENO: checking for GNU ld" >&5
11111 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6; }
11112 else
11113   { echo "$as_me:$LINENO: checking for non-GNU ld" >&5
11114 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6; }
11115 fi
11116 if test "${lt_cv_path_LD+set}" = set; then
11117   echo $ECHO_N "(cached) $ECHO_C" >&6
11118 else
11119   if test -z "$LD"; then
11120   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
11121   for ac_dir in $PATH; do
11122     IFS="$lt_save_ifs"
11123     test -z "$ac_dir" && ac_dir=.
11124     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
11125       lt_cv_path_LD="$ac_dir/$ac_prog"
11126       # Check to see if the program is GNU ld.  I'd rather use --version,
11127       # but apparently some variants of GNU ld only accept -v.
11128       # Break only if it was the GNU/non-GNU ld that we prefer.
11129       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
11130       *GNU* | *'with BFD'*)
11131         test "$with_gnu_ld" != no && break
11132         ;;
11133       *)
11134         test "$with_gnu_ld" != yes && break
11135         ;;
11136       esac
11137     fi
11138   done
11139   IFS="$lt_save_ifs"
11140 else
11141   lt_cv_path_LD="$LD" # Let the user override the test with a path.
11142 fi
11143 fi
11144
11145 LD="$lt_cv_path_LD"
11146 if test -n "$LD"; then
11147   { echo "$as_me:$LINENO: result: $LD" >&5
11148 echo "${ECHO_T}$LD" >&6; }
11149 else
11150   { echo "$as_me:$LINENO: result: no" >&5
11151 echo "${ECHO_T}no" >&6; }
11152 fi
11153 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
11154 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
11155    { (exit 1); exit 1; }; }
11156 { echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
11157 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6; }
11158 if test "${lt_cv_prog_gnu_ld+set}" = set; then
11159   echo $ECHO_N "(cached) $ECHO_C" >&6
11160 else
11161   # I'd rather use --version here, but apparently some GNU lds only accept -v.
11162 case `$LD -v 2>&1 </dev/null` in
11163 *GNU* | *'with BFD'*)
11164   lt_cv_prog_gnu_ld=yes
11165   ;;
11166 *)
11167   lt_cv_prog_gnu_ld=no
11168   ;;
11169 esac
11170 fi
11171 { echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
11172 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6; }
11173 with_gnu_ld=$lt_cv_prog_gnu_ld
11174
11175
11176 { echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
11177 echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6; }
11178 if test "${lt_cv_ld_reload_flag+set}" = set; then
11179   echo $ECHO_N "(cached) $ECHO_C" >&6
11180 else
11181   lt_cv_ld_reload_flag='-r'
11182 fi
11183 { echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
11184 echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6; }
11185 reload_flag=$lt_cv_ld_reload_flag
11186 case $reload_flag in
11187 "" | " "*) ;;
11188 *) reload_flag=" $reload_flag" ;;
11189 esac
11190 reload_cmds='$LD$reload_flag -o $output$reload_objs'
11191 case $host_os in
11192   darwin*)
11193     if test "$GCC" = yes; then
11194       reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
11195     else
11196       reload_cmds='$LD$reload_flag -o $output$reload_objs'
11197     fi
11198     ;;
11199 esac
11200
11201 { echo "$as_me:$LINENO: checking whether ln -s works" >&5
11202 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6; }
11203 LN_S=$as_ln_s
11204 if test "$LN_S" = "ln -s"; then
11205   { echo "$as_me:$LINENO: result: yes" >&5
11206 echo "${ECHO_T}yes" >&6; }
11207 else
11208   { echo "$as_me:$LINENO: result: no, using $LN_S" >&5
11209 echo "${ECHO_T}no, using $LN_S" >&6; }
11210 fi
11211
11212 { echo "$as_me:$LINENO: checking how to recognize dependent libraries" >&5
11213 echo $ECHO_N "checking how to recognize dependent libraries... $ECHO_C" >&6; }
11214 if test "${lt_cv_deplibs_check_method+set}" = set; then
11215   echo $ECHO_N "(cached) $ECHO_C" >&6
11216 else
11217   lt_cv_file_magic_cmd='$MAGIC_CMD'
11218 lt_cv_file_magic_test_file=
11219 lt_cv_deplibs_check_method='unknown'
11220 # Need to set the preceding variable on all platforms that support
11221 # interlibrary dependencies.
11222 # 'none' -- dependencies not supported.
11223 # `unknown' -- same as none, but documents that we really don't know.
11224 # 'pass_all' -- all dependencies passed with no checks.
11225 # 'test_compile' -- check by making test program.
11226 # 'file_magic [[regex]]' -- check by looking for files in library path
11227 # which responds to the $file_magic_cmd with a given extended regex.
11228 # If you have `file' or equivalent on your system and you're not sure
11229 # whether `pass_all' will *always* work, you probably want this one.
11230
11231 case $host_os in
11232 aix4* | aix5*)
11233   lt_cv_deplibs_check_method=pass_all
11234   ;;
11235
11236 beos*)
11237   lt_cv_deplibs_check_method=pass_all
11238   ;;
11239
11240 bsdi[45]*)
11241   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
11242   lt_cv_file_magic_cmd='/usr/bin/file -L'
11243   lt_cv_file_magic_test_file=/shlib/libc.so
11244   ;;
11245
11246 cygwin*)
11247   # func_win32_libid is a shell function defined in ltmain.sh
11248   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
11249   lt_cv_file_magic_cmd='func_win32_libid'
11250   ;;
11251
11252 mingw* | pw32*)
11253   # Base MSYS/MinGW do not provide the 'file' command needed by
11254   # func_win32_libid shell function, so use a weaker test based on 'objdump',
11255   # unless we find 'file', for example because we are cross-compiling.
11256   if ( file / ) >/dev/null 2>&1; then
11257     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
11258     lt_cv_file_magic_cmd='func_win32_libid'
11259   else
11260     lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
11261     lt_cv_file_magic_cmd='$OBJDUMP -f'
11262   fi
11263   ;;
11264
11265 darwin* | rhapsody*)
11266   lt_cv_deplibs_check_method=pass_all
11267   ;;
11268
11269 freebsd* | dragonfly*)
11270   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
11271     case $host_cpu in
11272     i*86 )
11273       # Not sure whether the presence of OpenBSD here was a mistake.
11274       # Let's accept both of them until this is cleared up.
11275       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
11276       lt_cv_file_magic_cmd=/usr/bin/file
11277       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
11278       ;;
11279     esac
11280   else
11281     lt_cv_deplibs_check_method=pass_all
11282   fi
11283   ;;
11284
11285 gnu*)
11286   lt_cv_deplibs_check_method=pass_all
11287   ;;
11288
11289 hpux10.20* | hpux11*)
11290   lt_cv_file_magic_cmd=/usr/bin/file
11291   case $host_cpu in
11292   ia64*)
11293     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
11294     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
11295     ;;
11296   hppa*64*)
11297     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'
11298     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
11299     ;;
11300   *)
11301     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
11302     lt_cv_file_magic_test_file=/usr/lib/libc.sl
11303     ;;
11304   esac
11305   ;;
11306
11307 interix[3-9]*)
11308   # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
11309   lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
11310   ;;
11311
11312 irix5* | irix6* | nonstopux*)
11313   case $LD in
11314   *-32|*"-32 ") libmagic=32-bit;;
11315   *-n32|*"-n32 ") libmagic=N32;;
11316   *-64|*"-64 ") libmagic=64-bit;;
11317   *) libmagic=never-match;;
11318   esac
11319   lt_cv_deplibs_check_method=pass_all
11320   ;;
11321
11322 # This must be Linux ELF.
11323 linux* | k*bsd*-gnu)
11324   lt_cv_deplibs_check_method=pass_all
11325   ;;
11326
11327 netbsd*)
11328   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
11329     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
11330   else
11331     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
11332   fi
11333   ;;
11334
11335 newos6*)
11336   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
11337   lt_cv_file_magic_cmd=/usr/bin/file
11338   lt_cv_file_magic_test_file=/usr/lib/libnls.so
11339   ;;
11340
11341 nto-qnx*)
11342   lt_cv_deplibs_check_method=unknown
11343   ;;
11344
11345 openbsd*)
11346   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
11347     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
11348   else
11349     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
11350   fi
11351   ;;
11352
11353 osf3* | osf4* | osf5*)
11354   lt_cv_deplibs_check_method=pass_all
11355   ;;
11356
11357 rdos*)
11358   lt_cv_deplibs_check_method=pass_all
11359   ;;
11360
11361 solaris*)
11362   lt_cv_deplibs_check_method=pass_all
11363   ;;
11364
11365 sysv4 | sysv4.3*)
11366   case $host_vendor in
11367   motorola)
11368     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
11369     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
11370     ;;
11371   ncr)
11372     lt_cv_deplibs_check_method=pass_all
11373     ;;
11374   sequent)
11375     lt_cv_file_magic_cmd='/bin/file'
11376     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
11377     ;;
11378   sni)
11379     lt_cv_file_magic_cmd='/bin/file'
11380     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
11381     lt_cv_file_magic_test_file=/lib/libc.so
11382     ;;
11383   siemens)
11384     lt_cv_deplibs_check_method=pass_all
11385     ;;
11386   pc)
11387     lt_cv_deplibs_check_method=pass_all
11388     ;;
11389   esac
11390   ;;
11391
11392 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
11393   lt_cv_deplibs_check_method=pass_all
11394   ;;
11395 esac
11396
11397 fi
11398 { echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
11399 echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6; }
11400 file_magic_cmd=$lt_cv_file_magic_cmd
11401 deplibs_check_method=$lt_cv_deplibs_check_method
11402 test -z "$deplibs_check_method" && deplibs_check_method=unknown
11403
11404
11405
11406
11407 # If no C compiler was specified, use CC.
11408 LTCC=${LTCC-"$CC"}
11409
11410 # If no C compiler flags were specified, use CFLAGS.
11411 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
11412
11413 # Allow CC to be a program name with arguments.
11414 compiler=$CC
11415
11416 # Check whether --enable-libtool-lock was given.
11417 if test "${enable_libtool_lock+set}" = set; then
11418   enableval=$enable_libtool_lock;
11419 fi
11420
11421 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
11422
11423 # Some flags need to be propagated to the compiler or linker for good
11424 # libtool support.
11425 case $host in
11426 ia64-*-hpux*)
11427   # Find out which ABI we are using.
11428   echo 'int i;' > conftest.$ac_ext
11429   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11430   (eval $ac_compile) 2>&5
11431   ac_status=$?
11432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11433   (exit $ac_status); }; then
11434     case `/usr/bin/file conftest.$ac_objext` in
11435     *ELF-32*)
11436       HPUX_IA64_MODE="32"
11437       ;;
11438     *ELF-64*)
11439       HPUX_IA64_MODE="64"
11440       ;;
11441     esac
11442   fi
11443   rm -rf conftest*
11444   ;;
11445 *-*-irix6*)
11446   # Find out which ABI we are using.
11447   echo '#line 11447 "configure"' > conftest.$ac_ext
11448   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11449   (eval $ac_compile) 2>&5
11450   ac_status=$?
11451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11452   (exit $ac_status); }; then
11453    if test "$lt_cv_prog_gnu_ld" = yes; then
11454     case `/usr/bin/file conftest.$ac_objext` in
11455     *32-bit*)
11456       LD="${LD-ld} -melf32bsmip"
11457       ;;
11458     *N32*)
11459       LD="${LD-ld} -melf32bmipn32"
11460       ;;
11461     *64-bit*)
11462       LD="${LD-ld} -melf64bmip"
11463       ;;
11464     esac
11465    else
11466     case `/usr/bin/file conftest.$ac_objext` in
11467     *32-bit*)
11468       LD="${LD-ld} -32"
11469       ;;
11470     *N32*)
11471       LD="${LD-ld} -n32"
11472       ;;
11473     *64-bit*)
11474       LD="${LD-ld} -64"
11475       ;;
11476     esac
11477    fi
11478   fi
11479   rm -rf conftest*
11480   ;;
11481
11482 x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
11483 s390*-*linux*|sparc*-*linux*)
11484   # Find out which ABI we are using.
11485   echo 'int i;' > conftest.$ac_ext
11486   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11487   (eval $ac_compile) 2>&5
11488   ac_status=$?
11489   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11490   (exit $ac_status); }; then
11491     case `/usr/bin/file conftest.o` in
11492     *32-bit*)
11493       case $host in
11494         x86_64-*kfreebsd*-gnu)
11495           LD="${LD-ld} -m elf_i386_fbsd"
11496           ;;
11497         x86_64-*linux*)
11498           LD="${LD-ld} -m elf_i386"
11499           ;;
11500         ppc64-*linux*|powerpc64-*linux*)
11501           LD="${LD-ld} -m elf32ppclinux"
11502           ;;
11503         s390x-*linux*)
11504           LD="${LD-ld} -m elf_s390"
11505           ;;
11506         sparc64-*linux*)
11507           LD="${LD-ld} -m elf32_sparc"
11508           ;;
11509       esac
11510       ;;
11511     *64-bit*)
11512       case $host in
11513         x86_64-*kfreebsd*-gnu)
11514           LD="${LD-ld} -m elf_x86_64_fbsd"
11515           ;;
11516         x86_64-*linux*)
11517           LD="${LD-ld} -m elf_x86_64"
11518           ;;
11519         ppc*-*linux*|powerpc*-*linux*)
11520           LD="${LD-ld} -m elf64ppc"
11521           ;;
11522         s390*-*linux*)
11523           LD="${LD-ld} -m elf64_s390"
11524           ;;
11525         sparc*-*linux*)
11526           LD="${LD-ld} -m elf64_sparc"
11527           ;;
11528       esac
11529       ;;
11530     esac
11531   fi
11532   rm -rf conftest*
11533   ;;
11534
11535 *-*-sco3.2v5*)
11536   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
11537   SAVE_CFLAGS="$CFLAGS"
11538   CFLAGS="$CFLAGS -belf"
11539   { echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
11540 echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6; }
11541 if test "${lt_cv_cc_needs_belf+set}" = set; then
11542   echo $ECHO_N "(cached) $ECHO_C" >&6
11543 else
11544   ac_ext=c
11545 ac_cpp='$CPP $CPPFLAGS'
11546 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11547 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11548 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11549
11550      cat >conftest.$ac_ext <<_ACEOF
11551 /* confdefs.h.  */
11552 _ACEOF
11553 cat confdefs.h >>conftest.$ac_ext
11554 cat >>conftest.$ac_ext <<_ACEOF
11555 /* end confdefs.h.  */
11556
11557 int
11558 main ()
11559 {
11560
11561   ;
11562   return 0;
11563 }
11564 _ACEOF
11565 rm -f conftest.$ac_objext conftest$ac_exeext
11566 if { (ac_try="$ac_link"
11567 case "(($ac_try" in
11568   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11569   *) ac_try_echo=$ac_try;;
11570 esac
11571 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11572   (eval "$ac_link") 2>conftest.er1
11573   ac_status=$?
11574   grep -v '^ *+' conftest.er1 >conftest.err
11575   rm -f conftest.er1
11576   cat conftest.err >&5
11577   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11578   (exit $ac_status); } && {
11579          test -z "$ac_c_werror_flag" ||
11580          test ! -s conftest.err
11581        } && test -s conftest$ac_exeext &&
11582        $as_test_x conftest$ac_exeext; then
11583   lt_cv_cc_needs_belf=yes
11584 else
11585   echo "$as_me: failed program was:" >&5
11586 sed 's/^/| /' conftest.$ac_ext >&5
11587
11588         lt_cv_cc_needs_belf=no
11589 fi
11590
11591 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11592       conftest$ac_exeext conftest.$ac_ext
11593      ac_ext=c
11594 ac_cpp='$CPP $CPPFLAGS'
11595 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11596 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11597 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11598
11599 fi
11600 { echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
11601 echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6; }
11602   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
11603     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
11604     CFLAGS="$SAVE_CFLAGS"
11605   fi
11606   ;;
11607 sparc*-*solaris*)
11608   # Find out which ABI we are using.
11609   echo 'int i;' > conftest.$ac_ext
11610   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11611   (eval $ac_compile) 2>&5
11612   ac_status=$?
11613   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11614   (exit $ac_status); }; then
11615     case `/usr/bin/file conftest.o` in
11616     *64-bit*)
11617       case $lt_cv_prog_gnu_ld in
11618       yes*) LD="${LD-ld} -m elf64_sparc" ;;
11619       *)    LD="${LD-ld} -64" ;;
11620       esac
11621       ;;
11622     esac
11623   fi
11624   rm -rf conftest*
11625   ;;
11626
11627 *-*-cygwin* | *-*-mingw* | *-*-pw32*)
11628   if test -n "$ac_tool_prefix"; then
11629   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
11630 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
11631 { echo "$as_me:$LINENO: checking for $ac_word" >&5
11632 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
11633 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
11634   echo $ECHO_N "(cached) $ECHO_C" >&6
11635 else
11636   if test -n "$DLLTOOL"; then
11637   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
11638 else
11639 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11640 for as_dir in $PATH
11641 do
11642   IFS=$as_save_IFS
11643   test -z "$as_dir" && as_dir=.
11644   for ac_exec_ext in '' $ac_executable_extensions; do
11645   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11646     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
11647     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11648     break 2
11649   fi
11650 done
11651 done
11652 IFS=$as_save_IFS
11653
11654 fi
11655 fi
11656 DLLTOOL=$ac_cv_prog_DLLTOOL
11657 if test -n "$DLLTOOL"; then
11658   { echo "$as_me:$LINENO: result: $DLLTOOL" >&5
11659 echo "${ECHO_T}$DLLTOOL" >&6; }
11660 else
11661   { echo "$as_me:$LINENO: result: no" >&5
11662 echo "${ECHO_T}no" >&6; }
11663 fi
11664
11665
11666 fi
11667 if test -z "$ac_cv_prog_DLLTOOL"; then
11668   ac_ct_DLLTOOL=$DLLTOOL
11669   # Extract the first word of "dlltool", so it can be a program name with args.
11670 set dummy dlltool; ac_word=$2
11671 { echo "$as_me:$LINENO: checking for $ac_word" >&5
11672 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
11673 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
11674   echo $ECHO_N "(cached) $ECHO_C" >&6
11675 else
11676   if test -n "$ac_ct_DLLTOOL"; then
11677   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
11678 else
11679 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11680 for as_dir in $PATH
11681 do
11682   IFS=$as_save_IFS
11683   test -z "$as_dir" && as_dir=.
11684   for ac_exec_ext in '' $ac_executable_extensions; do
11685   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11686     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
11687     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11688     break 2
11689   fi
11690 done
11691 done
11692 IFS=$as_save_IFS
11693
11694 fi
11695 fi
11696 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
11697 if test -n "$ac_ct_DLLTOOL"; then
11698   { echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
11699 echo "${ECHO_T}$ac_ct_DLLTOOL" >&6; }
11700 else
11701   { echo "$as_me:$LINENO: result: no" >&5
11702 echo "${ECHO_T}no" >&6; }
11703 fi
11704
11705   if test "x$ac_ct_DLLTOOL" = x; then
11706     DLLTOOL="false"
11707   else
11708     case $cross_compiling:$ac_tool_warned in
11709 yes:)
11710 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
11711 whose name does not start with the host triplet.  If you think this
11712 configuration is useful to you, please write to autoconf@gnu.org." >&5
11713 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
11714 whose name does not start with the host triplet.  If you think this
11715 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
11716 ac_tool_warned=yes ;;
11717 esac
11718     DLLTOOL=$ac_ct_DLLTOOL
11719   fi
11720 else
11721   DLLTOOL="$ac_cv_prog_DLLTOOL"
11722 fi
11723
11724   if test -n "$ac_tool_prefix"; then
11725   # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
11726 set dummy ${ac_tool_prefix}as; ac_word=$2
11727 { echo "$as_me:$LINENO: checking for $ac_word" >&5
11728 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
11729 if test "${ac_cv_prog_AS+set}" = set; then
11730   echo $ECHO_N "(cached) $ECHO_C" >&6
11731 else
11732   if test -n "$AS"; then
11733   ac_cv_prog_AS="$AS" # Let the user override the test.
11734 else
11735 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11736 for as_dir in $PATH
11737 do
11738   IFS=$as_save_IFS
11739   test -z "$as_dir" && as_dir=.
11740   for ac_exec_ext in '' $ac_executable_extensions; do
11741   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11742     ac_cv_prog_AS="${ac_tool_prefix}as"
11743     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11744     break 2
11745   fi
11746 done
11747 done
11748 IFS=$as_save_IFS
11749
11750 fi
11751 fi
11752 AS=$ac_cv_prog_AS
11753 if test -n "$AS"; then
11754   { echo "$as_me:$LINENO: result: $AS" >&5
11755 echo "${ECHO_T}$AS" >&6; }
11756 else
11757   { echo "$as_me:$LINENO: result: no" >&5
11758 echo "${ECHO_T}no" >&6; }
11759 fi
11760
11761
11762 fi
11763 if test -z "$ac_cv_prog_AS"; then
11764   ac_ct_AS=$AS
11765   # Extract the first word of "as", so it can be a program name with args.
11766 set dummy as; ac_word=$2
11767 { echo "$as_me:$LINENO: checking for $ac_word" >&5
11768 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
11769 if test "${ac_cv_prog_ac_ct_AS+set}" = set; then
11770   echo $ECHO_N "(cached) $ECHO_C" >&6
11771 else
11772   if test -n "$ac_ct_AS"; then
11773   ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test.
11774 else
11775 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11776 for as_dir in $PATH
11777 do
11778   IFS=$as_save_IFS
11779   test -z "$as_dir" && as_dir=.
11780   for ac_exec_ext in '' $ac_executable_extensions; do
11781   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11782     ac_cv_prog_ac_ct_AS="as"
11783     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11784     break 2
11785   fi
11786 done
11787 done
11788 IFS=$as_save_IFS
11789
11790 fi
11791 fi
11792 ac_ct_AS=$ac_cv_prog_ac_ct_AS
11793 if test -n "$ac_ct_AS"; then
11794   { echo "$as_me:$LINENO: result: $ac_ct_AS" >&5
11795 echo "${ECHO_T}$ac_ct_AS" >&6; }
11796 else
11797   { echo "$as_me:$LINENO: result: no" >&5
11798 echo "${ECHO_T}no" >&6; }
11799 fi
11800
11801   if test "x$ac_ct_AS" = x; then
11802     AS="false"
11803   else
11804     case $cross_compiling:$ac_tool_warned in
11805 yes:)
11806 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
11807 whose name does not start with the host triplet.  If you think this
11808 configuration is useful to you, please write to autoconf@gnu.org." >&5
11809 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
11810 whose name does not start with the host triplet.  If you think this
11811 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
11812 ac_tool_warned=yes ;;
11813 esac
11814     AS=$ac_ct_AS
11815   fi
11816 else
11817   AS="$ac_cv_prog_AS"
11818 fi
11819
11820   if test -n "$ac_tool_prefix"; then
11821   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
11822 set dummy ${ac_tool_prefix}objdump; ac_word=$2
11823 { echo "$as_me:$LINENO: checking for $ac_word" >&5
11824 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
11825 if test "${ac_cv_prog_OBJDUMP+set}" = set; then
11826   echo $ECHO_N "(cached) $ECHO_C" >&6
11827 else
11828   if test -n "$OBJDUMP"; then
11829   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
11830 else
11831 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11832 for as_dir in $PATH
11833 do
11834   IFS=$as_save_IFS
11835   test -z "$as_dir" && as_dir=.
11836   for ac_exec_ext in '' $ac_executable_extensions; do
11837   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11838     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
11839     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11840     break 2
11841   fi
11842 done
11843 done
11844 IFS=$as_save_IFS
11845
11846 fi
11847 fi
11848 OBJDUMP=$ac_cv_prog_OBJDUMP
11849 if test -n "$OBJDUMP"; then
11850   { echo "$as_me:$LINENO: result: $OBJDUMP" >&5
11851 echo "${ECHO_T}$OBJDUMP" >&6; }
11852 else
11853   { echo "$as_me:$LINENO: result: no" >&5
11854 echo "${ECHO_T}no" >&6; }
11855 fi
11856
11857
11858 fi
11859 if test -z "$ac_cv_prog_OBJDUMP"; then
11860   ac_ct_OBJDUMP=$OBJDUMP
11861   # Extract the first word of "objdump", so it can be a program name with args.
11862 set dummy objdump; ac_word=$2
11863 { echo "$as_me:$LINENO: checking for $ac_word" >&5
11864 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
11865 if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then
11866   echo $ECHO_N "(cached) $ECHO_C" >&6
11867 else
11868   if test -n "$ac_ct_OBJDUMP"; then
11869   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
11870 else
11871 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11872 for as_dir in $PATH
11873 do
11874   IFS=$as_save_IFS
11875   test -z "$as_dir" && as_dir=.
11876   for ac_exec_ext in '' $ac_executable_extensions; do
11877   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11878     ac_cv_prog_ac_ct_OBJDUMP="objdump"
11879     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
11880     break 2
11881   fi
11882 done
11883 done
11884 IFS=$as_save_IFS
11885
11886 fi
11887 fi
11888 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
11889 if test -n "$ac_ct_OBJDUMP"; then
11890   { echo "$as_me:$LINENO: result: $ac_ct_OBJDUMP" >&5
11891 echo "${ECHO_T}$ac_ct_OBJDUMP" >&6; }
11892 else
11893   { echo "$as_me:$LINENO: result: no" >&5
11894 echo "${ECHO_T}no" >&6; }
11895 fi
11896
11897   if test "x$ac_ct_OBJDUMP" = x; then
11898     OBJDUMP="false"
11899   else
11900     case $cross_compiling:$ac_tool_warned in
11901 yes:)
11902 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
11903 whose name does not start with the host triplet.  If you think this
11904 configuration is useful to you, please write to autoconf@gnu.org." >&5
11905 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
11906 whose name does not start with the host triplet.  If you think this
11907 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
11908 ac_tool_warned=yes ;;
11909 esac
11910     OBJDUMP=$ac_ct_OBJDUMP
11911   fi
11912 else
11913   OBJDUMP="$ac_cv_prog_OBJDUMP"
11914 fi
11915
11916   ;;
11917
11918 esac
11919
11920 need_locks="$enable_libtool_lock"
11921
11922
11923
11924 for ac_header in dlfcn.h
11925 do
11926 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
11927 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11928   { echo "$as_me:$LINENO: checking for $ac_header" >&5
11929 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
11930 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11931   echo $ECHO_N "(cached) $ECHO_C" >&6
11932 fi
11933 ac_res=`eval echo '${'$as_ac_Header'}'`
11934                { echo "$as_me:$LINENO: result: $ac_res" >&5
11935 echo "${ECHO_T}$ac_res" >&6; }
11936 else
11937   # Is the header compilable?
11938 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
11939 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
11940 cat >conftest.$ac_ext <<_ACEOF
11941 /* confdefs.h.  */
11942 _ACEOF
11943 cat confdefs.h >>conftest.$ac_ext
11944 cat >>conftest.$ac_ext <<_ACEOF
11945 /* end confdefs.h.  */
11946 $ac_includes_default
11947 #include <$ac_header>
11948 _ACEOF
11949 rm -f conftest.$ac_objext
11950 if { (ac_try="$ac_compile"
11951 case "(($ac_try" in
11952   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11953   *) ac_try_echo=$ac_try;;
11954 esac
11955 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11956   (eval "$ac_compile") 2>conftest.er1
11957   ac_status=$?
11958   grep -v '^ *+' conftest.er1 >conftest.err
11959   rm -f conftest.er1
11960   cat conftest.err >&5
11961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11962   (exit $ac_status); } && {
11963          test -z "$ac_c_werror_flag" ||
11964          test ! -s conftest.err
11965        } && test -s conftest.$ac_objext; then
11966   ac_header_compiler=yes
11967 else
11968   echo "$as_me: failed program was:" >&5
11969 sed 's/^/| /' conftest.$ac_ext >&5
11970
11971         ac_header_compiler=no
11972 fi
11973
11974 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11975 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11976 echo "${ECHO_T}$ac_header_compiler" >&6; }
11977
11978 # Is the header present?
11979 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
11980 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
11981 cat >conftest.$ac_ext <<_ACEOF
11982 /* confdefs.h.  */
11983 _ACEOF
11984 cat confdefs.h >>conftest.$ac_ext
11985 cat >>conftest.$ac_ext <<_ACEOF
11986 /* end confdefs.h.  */
11987 #include <$ac_header>
11988 _ACEOF
11989 if { (ac_try="$ac_cpp conftest.$ac_ext"
11990 case "(($ac_try" in
11991   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11992   *) ac_try_echo=$ac_try;;
11993 esac
11994 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11995   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11996   ac_status=$?
11997   grep -v '^ *+' conftest.er1 >conftest.err
11998   rm -f conftest.er1
11999   cat conftest.err >&5
12000   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12001   (exit $ac_status); } >/dev/null && {
12002          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12003          test ! -s conftest.err
12004        }; then
12005   ac_header_preproc=yes
12006 else
12007   echo "$as_me: failed program was:" >&5
12008 sed 's/^/| /' conftest.$ac_ext >&5
12009
12010   ac_header_preproc=no
12011 fi
12012
12013 rm -f conftest.err conftest.$ac_ext
12014 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12015 echo "${ECHO_T}$ac_header_preproc" >&6; }
12016
12017 # So?  What about this header?
12018 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12019   yes:no: )
12020     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12021 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12022     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12023 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12024     ac_header_preproc=yes
12025     ;;
12026   no:yes:* )
12027     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12028 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12029     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12030 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12031     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12032 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12033     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12034 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12035     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12036 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12037     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12038 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12039     ( cat <<\_ASBOX
12040 ## ---------------------------------- ##
12041 ## Report this to gmp-bugs@gmplib.org ##
12042 ## ---------------------------------- ##
12043 _ASBOX
12044      ) | sed "s/^/$as_me: WARNING:     /" >&2
12045     ;;
12046 esac
12047 { echo "$as_me:$LINENO: checking for $ac_header" >&5
12048 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12049 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12050   echo $ECHO_N "(cached) $ECHO_C" >&6
12051 else
12052   eval "$as_ac_Header=\$ac_header_preproc"
12053 fi
12054 ac_res=`eval echo '${'$as_ac_Header'}'`
12055                { echo "$as_me:$LINENO: result: $ac_res" >&5
12056 echo "${ECHO_T}$ac_res" >&6; }
12057
12058 fi
12059 if test `eval echo '${'$as_ac_Header'}'` = yes; then
12060   cat >>confdefs.h <<_ACEOF
12061 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12062 _ACEOF
12063
12064 fi
12065
12066 done
12067
12068
12069
12070 if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
12071     ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
12072     (test "X$CXX" != "Xg++"))) ; then
12073   ac_ext=cpp
12074 ac_cpp='$CXXCPP $CPPFLAGS'
12075 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
12076 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
12077 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
12078 { echo "$as_me:$LINENO: checking how to run the C++ preprocessor" >&5
12079 echo $ECHO_N "checking how to run the C++ preprocessor... $ECHO_C" >&6; }
12080 if test -z "$CXXCPP"; then
12081   if test "${ac_cv_prog_CXXCPP+set}" = set; then
12082   echo $ECHO_N "(cached) $ECHO_C" >&6
12083 else
12084       # Double quotes because CXXCPP needs to be expanded
12085     for CXXCPP in "$CXX -E" "/lib/cpp"
12086     do
12087       ac_preproc_ok=false
12088 for ac_cxx_preproc_warn_flag in '' yes
12089 do
12090   # Use a header file that comes with gcc, so configuring glibc
12091   # with a fresh cross-compiler works.
12092   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12093   # <limits.h> exists even on freestanding compilers.
12094   # On the NeXT, cc -E runs the code through the compiler's parser,
12095   # not just through cpp. "Syntax error" is here to catch this case.
12096   cat >conftest.$ac_ext <<_ACEOF
12097 /* confdefs.h.  */
12098 _ACEOF
12099 cat confdefs.h >>conftest.$ac_ext
12100 cat >>conftest.$ac_ext <<_ACEOF
12101 /* end confdefs.h.  */
12102 #ifdef __STDC__
12103 # include <limits.h>
12104 #else
12105 # include <assert.h>
12106 #endif
12107                      Syntax error
12108 _ACEOF
12109 if { (ac_try="$ac_cpp conftest.$ac_ext"
12110 case "(($ac_try" in
12111   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12112   *) ac_try_echo=$ac_try;;
12113 esac
12114 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12115   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12116   ac_status=$?
12117   grep -v '^ *+' conftest.er1 >conftest.err
12118   rm -f conftest.er1
12119   cat conftest.err >&5
12120   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12121   (exit $ac_status); } >/dev/null && {
12122          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
12123          test ! -s conftest.err
12124        }; then
12125   :
12126 else
12127   echo "$as_me: failed program was:" >&5
12128 sed 's/^/| /' conftest.$ac_ext >&5
12129
12130   # Broken: fails on valid input.
12131 continue
12132 fi
12133
12134 rm -f conftest.err conftest.$ac_ext
12135
12136   # OK, works on sane cases.  Now check whether nonexistent headers
12137   # can be detected and how.
12138   cat >conftest.$ac_ext <<_ACEOF
12139 /* confdefs.h.  */
12140 _ACEOF
12141 cat confdefs.h >>conftest.$ac_ext
12142 cat >>conftest.$ac_ext <<_ACEOF
12143 /* end confdefs.h.  */
12144 #include <ac_nonexistent.h>
12145 _ACEOF
12146 if { (ac_try="$ac_cpp conftest.$ac_ext"
12147 case "(($ac_try" in
12148   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12149   *) ac_try_echo=$ac_try;;
12150 esac
12151 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12152   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12153   ac_status=$?
12154   grep -v '^ *+' conftest.er1 >conftest.err
12155   rm -f conftest.er1
12156   cat conftest.err >&5
12157   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12158   (exit $ac_status); } >/dev/null && {
12159          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
12160          test ! -s conftest.err
12161        }; then
12162   # Broken: success on invalid input.
12163 continue
12164 else
12165   echo "$as_me: failed program was:" >&5
12166 sed 's/^/| /' conftest.$ac_ext >&5
12167
12168   # Passes both tests.
12169 ac_preproc_ok=:
12170 break
12171 fi
12172
12173 rm -f conftest.err conftest.$ac_ext
12174
12175 done
12176 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
12177 rm -f conftest.err conftest.$ac_ext
12178 if $ac_preproc_ok; then
12179   break
12180 fi
12181
12182     done
12183     ac_cv_prog_CXXCPP=$CXXCPP
12184
12185 fi
12186   CXXCPP=$ac_cv_prog_CXXCPP
12187 else
12188   ac_cv_prog_CXXCPP=$CXXCPP
12189 fi
12190 { echo "$as_me:$LINENO: result: $CXXCPP" >&5
12191 echo "${ECHO_T}$CXXCPP" >&6; }
12192 ac_preproc_ok=false
12193 for ac_cxx_preproc_warn_flag in '' yes
12194 do
12195   # Use a header file that comes with gcc, so configuring glibc
12196   # with a fresh cross-compiler works.
12197   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12198   # <limits.h> exists even on freestanding compilers.
12199   # On the NeXT, cc -E runs the code through the compiler's parser,
12200   # not just through cpp. "Syntax error" is here to catch this case.
12201   cat >conftest.$ac_ext <<_ACEOF
12202 /* confdefs.h.  */
12203 _ACEOF
12204 cat confdefs.h >>conftest.$ac_ext
12205 cat >>conftest.$ac_ext <<_ACEOF
12206 /* end confdefs.h.  */
12207 #ifdef __STDC__
12208 # include <limits.h>
12209 #else
12210 # include <assert.h>
12211 #endif
12212                      Syntax error
12213 _ACEOF
12214 if { (ac_try="$ac_cpp conftest.$ac_ext"
12215 case "(($ac_try" in
12216   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12217   *) ac_try_echo=$ac_try;;
12218 esac
12219 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12220   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12221   ac_status=$?
12222   grep -v '^ *+' conftest.er1 >conftest.err
12223   rm -f conftest.er1
12224   cat conftest.err >&5
12225   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12226   (exit $ac_status); } >/dev/null && {
12227          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
12228          test ! -s conftest.err
12229        }; then
12230   :
12231 else
12232   echo "$as_me: failed program was:" >&5
12233 sed 's/^/| /' conftest.$ac_ext >&5
12234
12235   # Broken: fails on valid input.
12236 continue
12237 fi
12238
12239 rm -f conftest.err conftest.$ac_ext
12240
12241   # OK, works on sane cases.  Now check whether nonexistent headers
12242   # can be detected and how.
12243   cat >conftest.$ac_ext <<_ACEOF
12244 /* confdefs.h.  */
12245 _ACEOF
12246 cat confdefs.h >>conftest.$ac_ext
12247 cat >>conftest.$ac_ext <<_ACEOF
12248 /* end confdefs.h.  */
12249 #include <ac_nonexistent.h>
12250 _ACEOF
12251 if { (ac_try="$ac_cpp conftest.$ac_ext"
12252 case "(($ac_try" in
12253   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12254   *) ac_try_echo=$ac_try;;
12255 esac
12256 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12257   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12258   ac_status=$?
12259   grep -v '^ *+' conftest.er1 >conftest.err
12260   rm -f conftest.er1
12261   cat conftest.err >&5
12262   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12263   (exit $ac_status); } >/dev/null && {
12264          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
12265          test ! -s conftest.err
12266        }; then
12267   # Broken: success on invalid input.
12268 continue
12269 else
12270   echo "$as_me: failed program was:" >&5
12271 sed 's/^/| /' conftest.$ac_ext >&5
12272
12273   # Passes both tests.
12274 ac_preproc_ok=:
12275 break
12276 fi
12277
12278 rm -f conftest.err conftest.$ac_ext
12279
12280 done
12281 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
12282 rm -f conftest.err conftest.$ac_ext
12283 if $ac_preproc_ok; then
12284   :
12285 else
12286   { { echo "$as_me:$LINENO: error: C++ preprocessor \"$CXXCPP\" fails sanity check
12287 See \`config.log' for more details." >&5
12288 echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check
12289 See \`config.log' for more details." >&2;}
12290    { (exit 1); exit 1; }; }
12291 fi
12292
12293 ac_ext=cpp
12294 ac_cpp='$CXXCPP $CPPFLAGS'
12295 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
12296 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
12297 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
12298
12299 fi
12300
12301
12302
12303
12304 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
12305
12306 # find the maximum length of command line arguments
12307 { echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5
12308 echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6; }
12309 if test "${lt_cv_sys_max_cmd_len+set}" = set; then
12310   echo $ECHO_N "(cached) $ECHO_C" >&6
12311 else
12312     i=0
12313   teststring="ABCD"
12314
12315   case $build_os in
12316   msdosdjgpp*)
12317     # On DJGPP, this test can blow up pretty badly due to problems in libc
12318     # (any single argument exceeding 2000 bytes causes a buffer overrun
12319     # during glob expansion).  Even if it were fixed, the result of this
12320     # check would be larger than it should be.
12321     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
12322     ;;
12323
12324   gnu*)
12325     # Under GNU Hurd, this test is not required because there is
12326     # no limit to the length of command line arguments.
12327     # Libtool will interpret -1 as no limit whatsoever
12328     lt_cv_sys_max_cmd_len=-1;
12329     ;;
12330
12331   cygwin* | mingw*)
12332     # On Win9x/ME, this test blows up -- it succeeds, but takes
12333     # about 5 minutes as the teststring grows exponentially.
12334     # Worse, since 9x/ME are not pre-emptively multitasking,
12335     # you end up with a "frozen" computer, even though with patience
12336     # the test eventually succeeds (with a max line length of 256k).
12337     # Instead, let's just punt: use the minimum linelength reported by
12338     # all of the supported platforms: 8192 (on NT/2K/XP).
12339     lt_cv_sys_max_cmd_len=8192;
12340     ;;
12341
12342   amigaos*)
12343     # On AmigaOS with pdksh, this test takes hours, literally.
12344     # So we just punt and use a minimum line length of 8192.
12345     lt_cv_sys_max_cmd_len=8192;
12346     ;;
12347
12348   netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
12349     # This has been around since 386BSD, at least.  Likely further.
12350     if test -x /sbin/sysctl; then
12351       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
12352     elif test -x /usr/sbin/sysctl; then
12353       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
12354     else
12355       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
12356     fi
12357     # And add a safety zone
12358     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
12359     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
12360     ;;
12361
12362   interix*)
12363     # We know the value 262144 and hardcode it with a safety zone (like BSD)
12364     lt_cv_sys_max_cmd_len=196608
12365     ;;
12366
12367   osf*)
12368     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
12369     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
12370     # nice to cause kernel panics so lets avoid the loop below.
12371     # First set a reasonable default.
12372     lt_cv_sys_max_cmd_len=16384
12373     #
12374     if test -x /sbin/sysconfig; then
12375       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
12376         *1*) lt_cv_sys_max_cmd_len=-1 ;;
12377       esac
12378     fi
12379     ;;
12380   sco3.2v5*)
12381     lt_cv_sys_max_cmd_len=102400
12382     ;;
12383   sysv5* | sco5v6* | sysv4.2uw2*)
12384     kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
12385     if test -n "$kargmax"; then
12386       lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[         ]//'`
12387     else
12388       lt_cv_sys_max_cmd_len=32768
12389     fi
12390     ;;
12391   *)
12392     lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
12393     if test -n "$lt_cv_sys_max_cmd_len"; then
12394       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
12395       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
12396     else
12397       SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
12398       while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \
12399                = "XX$teststring") >/dev/null 2>&1 &&
12400               new_result=`expr "X$teststring" : ".*" 2>&1` &&
12401               lt_cv_sys_max_cmd_len=$new_result &&
12402               test $i != 17 # 1/2 MB should be enough
12403       do
12404         i=`expr $i + 1`
12405         teststring=$teststring$teststring
12406       done
12407       teststring=
12408       # Add a significant safety factor because C++ compilers can tack on massive
12409       # amounts of additional arguments before passing them to the linker.
12410       # It appears as though 1/2 is a usable value.
12411       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
12412     fi
12413     ;;
12414   esac
12415
12416 fi
12417
12418 if test -n $lt_cv_sys_max_cmd_len ; then
12419   { echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5
12420 echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6; }
12421 else
12422   { echo "$as_me:$LINENO: result: none" >&5
12423 echo "${ECHO_T}none" >&6; }
12424 fi
12425
12426
12427
12428
12429
12430 # Check for command to grab the raw symbol name followed by C symbol from nm.
12431 { echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5
12432 echo $ECHO_N "checking command to parse $NM output from $compiler object... $ECHO_C" >&6; }
12433 if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
12434   echo $ECHO_N "(cached) $ECHO_C" >&6
12435 else
12436
12437 # These are sane defaults that work on at least a few old systems.
12438 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
12439
12440 # Character class describing NM global symbol codes.
12441 symcode='[BCDEGRST]'
12442
12443 # Regexp to match symbols that can be accessed directly from C.
12444 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
12445
12446 # Transform an extracted symbol line into a proper C declaration
12447 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'"
12448
12449 # Transform an extracted symbol line into symbol name and symbol address
12450 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
12451
12452 # Define system-specific variables.
12453 case $host_os in
12454 aix*)
12455   symcode='[BCDT]'
12456   ;;
12457 cygwin* | mingw* | pw32*)
12458   symcode='[ABCDGISTW]'
12459   ;;
12460 hpux*) # Its linker distinguishes data from code symbols
12461   if test "$host_cpu" = ia64; then
12462     symcode='[ABCDEGRST]'
12463   fi
12464   lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
12465   lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
12466   ;;
12467 linux* | k*bsd*-gnu)
12468   if test "$host_cpu" = ia64; then
12469     symcode='[ABCDGIRSTW]'
12470     lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
12471     lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
12472   fi
12473   ;;
12474 irix* | nonstopux*)
12475   symcode='[BCDEGRST]'
12476   ;;
12477 osf*)
12478   symcode='[BCDEGQRST]'
12479   ;;
12480 solaris*)
12481   symcode='[BDRT]'
12482   ;;
12483 sco3.2v5*)
12484   symcode='[DT]'
12485   ;;
12486 sysv4.2uw2*)
12487   symcode='[DT]'
12488   ;;
12489 sysv5* | sco5v6* | unixware* | OpenUNIX*)
12490   symcode='[ABDT]'
12491   ;;
12492 sysv4)
12493   symcode='[DFNSTU]'
12494   ;;
12495 esac
12496
12497 # Handle CRLF in mingw tool chain
12498 opt_cr=
12499 case $build_os in
12500 mingw*)
12501   opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp
12502   ;;
12503 esac
12504
12505 # If we're using GNU nm, then use its standard symbol codes.
12506 case `$NM -V 2>&1` in
12507 *GNU* | *'with BFD'*)
12508   symcode='[ABCDGIRSTW]' ;;
12509 esac
12510
12511 # Try without a prefix undercore, then with it.
12512 for ac_symprfx in "" "_"; do
12513
12514   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
12515   symxfrm="\\1 $ac_symprfx\\2 \\2"
12516
12517   # Write the raw and C identifiers.
12518   lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[       ]\($symcode$symcode*\)[         ][      ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
12519
12520   # Check to see that the pipe works correctly.
12521   pipe_works=no
12522
12523   rm -f conftest*
12524   cat > conftest.$ac_ext <<EOF
12525 #ifdef __cplusplus
12526 extern "C" {
12527 #endif
12528 char nm_test_var;
12529 void nm_test_func(){}
12530 #ifdef __cplusplus
12531 }
12532 #endif
12533 int main(){nm_test_var='a';nm_test_func();return(0);}
12534 EOF
12535
12536   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12537   (eval $ac_compile) 2>&5
12538   ac_status=$?
12539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12540   (exit $ac_status); }; then
12541     # Now try to grab the symbols.
12542     nlist=conftest.nm
12543     if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5
12544   (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
12545   ac_status=$?
12546   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12547   (exit $ac_status); } && test -s "$nlist"; then
12548       # Try sorting and uniquifying the output.
12549       if sort "$nlist" | uniq > "$nlist"T; then
12550         mv -f "$nlist"T "$nlist"
12551       else
12552         rm -f "$nlist"T
12553       fi
12554
12555       # Make sure that we snagged all the symbols we need.
12556       if grep ' nm_test_var$' "$nlist" >/dev/null; then
12557         if grep ' nm_test_func$' "$nlist" >/dev/null; then
12558           cat <<EOF > conftest.$ac_ext
12559 #ifdef __cplusplus
12560 extern "C" {
12561 #endif
12562
12563 EOF
12564           # Now generate the symbol file.
12565           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext'
12566
12567           cat <<EOF >> conftest.$ac_ext
12568 #if defined (__STDC__) && __STDC__
12569 # define lt_ptr_t void *
12570 #else
12571 # define lt_ptr_t char *
12572 # define const
12573 #endif
12574
12575 /* The mapping between symbol names and symbols. */
12576 const struct {
12577   const char *name;
12578   lt_ptr_t address;
12579 }
12580 lt_preloaded_symbols[] =
12581 {
12582 EOF
12583           $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext
12584           cat <<\EOF >> conftest.$ac_ext
12585   {0, (lt_ptr_t) 0}
12586 };
12587
12588 #ifdef __cplusplus
12589 }
12590 #endif
12591 EOF
12592           # Now try linking the two files.
12593           mv conftest.$ac_objext conftstm.$ac_objext
12594           lt_save_LIBS="$LIBS"
12595           lt_save_CFLAGS="$CFLAGS"
12596           LIBS="conftstm.$ac_objext"
12597           CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
12598           if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12599   (eval $ac_link) 2>&5
12600   ac_status=$?
12601   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12602   (exit $ac_status); } && test -s conftest${ac_exeext}; then
12603             pipe_works=yes
12604           fi
12605           LIBS="$lt_save_LIBS"
12606           CFLAGS="$lt_save_CFLAGS"
12607         else
12608           echo "cannot find nm_test_func in $nlist" >&5
12609         fi
12610       else
12611         echo "cannot find nm_test_var in $nlist" >&5
12612       fi
12613     else
12614       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
12615     fi
12616   else
12617     echo "$progname: failed program was:" >&5
12618     cat conftest.$ac_ext >&5
12619   fi
12620   rm -f conftest* conftst*
12621
12622   # Do not use the global_symbol_pipe unless it works.
12623   if test "$pipe_works" = yes; then
12624     break
12625   else
12626     lt_cv_sys_global_symbol_pipe=
12627   fi
12628 done
12629
12630 fi
12631
12632 if test -z "$lt_cv_sys_global_symbol_pipe"; then
12633   lt_cv_sys_global_symbol_to_cdecl=
12634 fi
12635 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
12636   { echo "$as_me:$LINENO: result: failed" >&5
12637 echo "${ECHO_T}failed" >&6; }
12638 else
12639   { echo "$as_me:$LINENO: result: ok" >&5
12640 echo "${ECHO_T}ok" >&6; }
12641 fi
12642
12643 { echo "$as_me:$LINENO: checking for objdir" >&5
12644 echo $ECHO_N "checking for objdir... $ECHO_C" >&6; }
12645 if test "${lt_cv_objdir+set}" = set; then
12646   echo $ECHO_N "(cached) $ECHO_C" >&6
12647 else
12648   rm -f .libs 2>/dev/null
12649 mkdir .libs 2>/dev/null
12650 if test -d .libs; then
12651   lt_cv_objdir=.libs
12652 else
12653   # MS-DOS does not allow filenames that begin with a dot.
12654   lt_cv_objdir=_libs
12655 fi
12656 rmdir .libs 2>/dev/null
12657 fi
12658 { echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5
12659 echo "${ECHO_T}$lt_cv_objdir" >&6; }
12660 objdir=$lt_cv_objdir
12661
12662
12663
12664
12665
12666 case $host_os in
12667 aix3*)
12668   # AIX sometimes has problems with the GCC collect2 program.  For some
12669   # reason, if we set the COLLECT_NAMES environment variable, the problems
12670   # vanish in a puff of smoke.
12671   if test "X${COLLECT_NAMES+set}" != Xset; then
12672     COLLECT_NAMES=
12673     export COLLECT_NAMES
12674   fi
12675   ;;
12676 esac
12677
12678 # Sed substitution that helps us do robust quoting.  It backslashifies
12679 # metacharacters that are still active within double-quoted strings.
12680 Xsed='sed -e 1s/^X//'
12681 sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'
12682
12683 # Same as above, but do not quote variable references.
12684 double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'
12685
12686 # Sed substitution to delay expansion of an escaped shell variable in a
12687 # double_quote_subst'ed string.
12688 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
12689
12690 # Sed substitution to avoid accidental globbing in evaled expressions
12691 no_glob_subst='s/\*/\\\*/g'
12692
12693 # Constants:
12694 rm="rm -f"
12695
12696 # Global variables:
12697 default_ofile=libtool
12698 can_build_shared=yes
12699
12700 # All known linkers require a `.a' archive for static linking (except MSVC,
12701 # which needs '.lib').
12702 libext=a
12703 ltmain="$ac_aux_dir/ltmain.sh"
12704 ofile="$default_ofile"
12705 with_gnu_ld="$lt_cv_prog_gnu_ld"
12706
12707 if test -n "$ac_tool_prefix"; then
12708   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
12709 set dummy ${ac_tool_prefix}ar; ac_word=$2
12710 { echo "$as_me:$LINENO: checking for $ac_word" >&5
12711 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
12712 if test "${ac_cv_prog_AR+set}" = set; then
12713   echo $ECHO_N "(cached) $ECHO_C" >&6
12714 else
12715   if test -n "$AR"; then
12716   ac_cv_prog_AR="$AR" # Let the user override the test.
12717 else
12718 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12719 for as_dir in $PATH
12720 do
12721   IFS=$as_save_IFS
12722   test -z "$as_dir" && as_dir=.
12723   for ac_exec_ext in '' $ac_executable_extensions; do
12724   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12725     ac_cv_prog_AR="${ac_tool_prefix}ar"
12726     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12727     break 2
12728   fi
12729 done
12730 done
12731 IFS=$as_save_IFS
12732
12733 fi
12734 fi
12735 AR=$ac_cv_prog_AR
12736 if test -n "$AR"; then
12737   { echo "$as_me:$LINENO: result: $AR" >&5
12738 echo "${ECHO_T}$AR" >&6; }
12739 else
12740   { echo "$as_me:$LINENO: result: no" >&5
12741 echo "${ECHO_T}no" >&6; }
12742 fi
12743
12744
12745 fi
12746 if test -z "$ac_cv_prog_AR"; then
12747   ac_ct_AR=$AR
12748   # Extract the first word of "ar", so it can be a program name with args.
12749 set dummy ar; ac_word=$2
12750 { echo "$as_me:$LINENO: checking for $ac_word" >&5
12751 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
12752 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
12753   echo $ECHO_N "(cached) $ECHO_C" >&6
12754 else
12755   if test -n "$ac_ct_AR"; then
12756   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
12757 else
12758 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12759 for as_dir in $PATH
12760 do
12761   IFS=$as_save_IFS
12762   test -z "$as_dir" && as_dir=.
12763   for ac_exec_ext in '' $ac_executable_extensions; do
12764   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12765     ac_cv_prog_ac_ct_AR="ar"
12766     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12767     break 2
12768   fi
12769 done
12770 done
12771 IFS=$as_save_IFS
12772
12773 fi
12774 fi
12775 ac_ct_AR=$ac_cv_prog_ac_ct_AR
12776 if test -n "$ac_ct_AR"; then
12777   { echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
12778 echo "${ECHO_T}$ac_ct_AR" >&6; }
12779 else
12780   { echo "$as_me:$LINENO: result: no" >&5
12781 echo "${ECHO_T}no" >&6; }
12782 fi
12783
12784   if test "x$ac_ct_AR" = x; then
12785     AR="false"
12786   else
12787     case $cross_compiling:$ac_tool_warned in
12788 yes:)
12789 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
12790 whose name does not start with the host triplet.  If you think this
12791 configuration is useful to you, please write to autoconf@gnu.org." >&5
12792 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
12793 whose name does not start with the host triplet.  If you think this
12794 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
12795 ac_tool_warned=yes ;;
12796 esac
12797     AR=$ac_ct_AR
12798   fi
12799 else
12800   AR="$ac_cv_prog_AR"
12801 fi
12802
12803 if test -n "$ac_tool_prefix"; then
12804   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
12805 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
12806 { echo "$as_me:$LINENO: checking for $ac_word" >&5
12807 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
12808 if test "${ac_cv_prog_RANLIB+set}" = set; then
12809   echo $ECHO_N "(cached) $ECHO_C" >&6
12810 else
12811   if test -n "$RANLIB"; then
12812   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
12813 else
12814 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12815 for as_dir in $PATH
12816 do
12817   IFS=$as_save_IFS
12818   test -z "$as_dir" && as_dir=.
12819   for ac_exec_ext in '' $ac_executable_extensions; do
12820   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12821     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
12822     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12823     break 2
12824   fi
12825 done
12826 done
12827 IFS=$as_save_IFS
12828
12829 fi
12830 fi
12831 RANLIB=$ac_cv_prog_RANLIB
12832 if test -n "$RANLIB"; then
12833   { echo "$as_me:$LINENO: result: $RANLIB" >&5
12834 echo "${ECHO_T}$RANLIB" >&6; }
12835 else
12836   { echo "$as_me:$LINENO: result: no" >&5
12837 echo "${ECHO_T}no" >&6; }
12838 fi
12839
12840
12841 fi
12842 if test -z "$ac_cv_prog_RANLIB"; then
12843   ac_ct_RANLIB=$RANLIB
12844   # Extract the first word of "ranlib", so it can be a program name with args.
12845 set dummy ranlib; ac_word=$2
12846 { echo "$as_me:$LINENO: checking for $ac_word" >&5
12847 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
12848 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
12849   echo $ECHO_N "(cached) $ECHO_C" >&6
12850 else
12851   if test -n "$ac_ct_RANLIB"; then
12852   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
12853 else
12854 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12855 for as_dir in $PATH
12856 do
12857   IFS=$as_save_IFS
12858   test -z "$as_dir" && as_dir=.
12859   for ac_exec_ext in '' $ac_executable_extensions; do
12860   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12861     ac_cv_prog_ac_ct_RANLIB="ranlib"
12862     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12863     break 2
12864   fi
12865 done
12866 done
12867 IFS=$as_save_IFS
12868
12869 fi
12870 fi
12871 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
12872 if test -n "$ac_ct_RANLIB"; then
12873   { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
12874 echo "${ECHO_T}$ac_ct_RANLIB" >&6; }
12875 else
12876   { echo "$as_me:$LINENO: result: no" >&5
12877 echo "${ECHO_T}no" >&6; }
12878 fi
12879
12880   if test "x$ac_ct_RANLIB" = x; then
12881     RANLIB=":"
12882   else
12883     case $cross_compiling:$ac_tool_warned in
12884 yes:)
12885 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
12886 whose name does not start with the host triplet.  If you think this
12887 configuration is useful to you, please write to autoconf@gnu.org." >&5
12888 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
12889 whose name does not start with the host triplet.  If you think this
12890 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
12891 ac_tool_warned=yes ;;
12892 esac
12893     RANLIB=$ac_ct_RANLIB
12894   fi
12895 else
12896   RANLIB="$ac_cv_prog_RANLIB"
12897 fi
12898
12899 if test -n "$ac_tool_prefix"; then
12900   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
12901 set dummy ${ac_tool_prefix}strip; ac_word=$2
12902 { echo "$as_me:$LINENO: checking for $ac_word" >&5
12903 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
12904 if test "${ac_cv_prog_STRIP+set}" = set; then
12905   echo $ECHO_N "(cached) $ECHO_C" >&6
12906 else
12907   if test -n "$STRIP"; then
12908   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
12909 else
12910 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12911 for as_dir in $PATH
12912 do
12913   IFS=$as_save_IFS
12914   test -z "$as_dir" && as_dir=.
12915   for ac_exec_ext in '' $ac_executable_extensions; do
12916   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12917     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
12918     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12919     break 2
12920   fi
12921 done
12922 done
12923 IFS=$as_save_IFS
12924
12925 fi
12926 fi
12927 STRIP=$ac_cv_prog_STRIP
12928 if test -n "$STRIP"; then
12929   { echo "$as_me:$LINENO: result: $STRIP" >&5
12930 echo "${ECHO_T}$STRIP" >&6; }
12931 else
12932   { echo "$as_me:$LINENO: result: no" >&5
12933 echo "${ECHO_T}no" >&6; }
12934 fi
12935
12936
12937 fi
12938 if test -z "$ac_cv_prog_STRIP"; then
12939   ac_ct_STRIP=$STRIP
12940   # Extract the first word of "strip", so it can be a program name with args.
12941 set dummy strip; ac_word=$2
12942 { echo "$as_me:$LINENO: checking for $ac_word" >&5
12943 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
12944 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
12945   echo $ECHO_N "(cached) $ECHO_C" >&6
12946 else
12947   if test -n "$ac_ct_STRIP"; then
12948   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
12949 else
12950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12951 for as_dir in $PATH
12952 do
12953   IFS=$as_save_IFS
12954   test -z "$as_dir" && as_dir=.
12955   for ac_exec_ext in '' $ac_executable_extensions; do
12956   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12957     ac_cv_prog_ac_ct_STRIP="strip"
12958     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
12959     break 2
12960   fi
12961 done
12962 done
12963 IFS=$as_save_IFS
12964
12965 fi
12966 fi
12967 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
12968 if test -n "$ac_ct_STRIP"; then
12969   { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
12970 echo "${ECHO_T}$ac_ct_STRIP" >&6; }
12971 else
12972   { echo "$as_me:$LINENO: result: no" >&5
12973 echo "${ECHO_T}no" >&6; }
12974 fi
12975
12976   if test "x$ac_ct_STRIP" = x; then
12977     STRIP=":"
12978   else
12979     case $cross_compiling:$ac_tool_warned in
12980 yes:)
12981 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
12982 whose name does not start with the host triplet.  If you think this
12983 configuration is useful to you, please write to autoconf@gnu.org." >&5
12984 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
12985 whose name does not start with the host triplet.  If you think this
12986 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
12987 ac_tool_warned=yes ;;
12988 esac
12989     STRIP=$ac_ct_STRIP
12990   fi
12991 else
12992   STRIP="$ac_cv_prog_STRIP"
12993 fi
12994
12995
12996 old_CC="$CC"
12997 old_CFLAGS="$CFLAGS"
12998
12999 # Set sane defaults for various variables
13000 test -z "$AR" && AR=ar
13001 test -z "$AR_FLAGS" && AR_FLAGS=cru
13002 test -z "$AS" && AS=as
13003 test -z "$CC" && CC=cc
13004 test -z "$LTCC" && LTCC=$CC
13005 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
13006 test -z "$DLLTOOL" && DLLTOOL=dlltool
13007 test -z "$LD" && LD=ld
13008 test -z "$LN_S" && LN_S="ln -s"
13009 test -z "$MAGIC_CMD" && MAGIC_CMD=file
13010 test -z "$NM" && NM=nm
13011 test -z "$SED" && SED=sed
13012 test -z "$OBJDUMP" && OBJDUMP=objdump
13013 test -z "$RANLIB" && RANLIB=:
13014 test -z "$STRIP" && STRIP=:
13015 test -z "$ac_objext" && ac_objext=o
13016
13017 # Determine commands to create old-style static archives.
13018 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
13019 old_postinstall_cmds='chmod 644 $oldlib'
13020 old_postuninstall_cmds=
13021
13022 if test -n "$RANLIB"; then
13023   case $host_os in
13024   openbsd*)
13025     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
13026     ;;
13027   *)
13028     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
13029     ;;
13030   esac
13031   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
13032 fi
13033
13034 for cc_temp in $compiler""; do
13035   case $cc_temp in
13036     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
13037     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
13038     \-*) ;;
13039     *) break;;
13040   esac
13041 done
13042 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
13043
13044
13045 # Only perform the check for file, if the check method requires it
13046 case $deplibs_check_method in
13047 file_magic*)
13048   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
13049     { echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
13050 echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6; }
13051 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
13052   echo $ECHO_N "(cached) $ECHO_C" >&6
13053 else
13054   case $MAGIC_CMD in
13055 [\\/*] |  ?:[\\/]*)
13056   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
13057   ;;
13058 *)
13059   lt_save_MAGIC_CMD="$MAGIC_CMD"
13060   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
13061   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
13062   for ac_dir in $ac_dummy; do
13063     IFS="$lt_save_ifs"
13064     test -z "$ac_dir" && ac_dir=.
13065     if test -f $ac_dir/${ac_tool_prefix}file; then
13066       lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
13067       if test -n "$file_magic_test_file"; then
13068         case $deplibs_check_method in
13069         "file_magic "*)
13070           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
13071           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
13072           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
13073             $EGREP "$file_magic_regex" > /dev/null; then
13074             :
13075           else
13076             cat <<EOF 1>&2
13077
13078 *** Warning: the command libtool uses to detect shared libraries,
13079 *** $file_magic_cmd, produces output that libtool cannot recognize.
13080 *** The result is that libtool may fail to recognize shared libraries
13081 *** as such.  This will affect the creation of libtool libraries that
13082 *** depend on shared libraries, but programs linked with such libtool
13083 *** libraries will work regardless of this problem.  Nevertheless, you
13084 *** may want to report the problem to your system manager and/or to
13085 *** bug-libtool@gnu.org
13086
13087 EOF
13088           fi ;;
13089         esac
13090       fi
13091       break
13092     fi
13093   done
13094   IFS="$lt_save_ifs"
13095   MAGIC_CMD="$lt_save_MAGIC_CMD"
13096   ;;
13097 esac
13098 fi
13099
13100 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
13101 if test -n "$MAGIC_CMD"; then
13102   { echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
13103 echo "${ECHO_T}$MAGIC_CMD" >&6; }
13104 else
13105   { echo "$as_me:$LINENO: result: no" >&5
13106 echo "${ECHO_T}no" >&6; }
13107 fi
13108
13109 if test -z "$lt_cv_path_MAGIC_CMD"; then
13110   if test -n "$ac_tool_prefix"; then
13111     { echo "$as_me:$LINENO: checking for file" >&5
13112 echo $ECHO_N "checking for file... $ECHO_C" >&6; }
13113 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
13114   echo $ECHO_N "(cached) $ECHO_C" >&6
13115 else
13116   case $MAGIC_CMD in
13117 [\\/*] |  ?:[\\/]*)
13118   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
13119   ;;
13120 *)
13121   lt_save_MAGIC_CMD="$MAGIC_CMD"
13122   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
13123   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
13124   for ac_dir in $ac_dummy; do
13125     IFS="$lt_save_ifs"
13126     test -z "$ac_dir" && ac_dir=.
13127     if test -f $ac_dir/file; then
13128       lt_cv_path_MAGIC_CMD="$ac_dir/file"
13129       if test -n "$file_magic_test_file"; then
13130         case $deplibs_check_method in
13131         "file_magic "*)
13132           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
13133           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
13134           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
13135             $EGREP "$file_magic_regex" > /dev/null; then
13136             :
13137           else
13138             cat <<EOF 1>&2
13139
13140 *** Warning: the command libtool uses to detect shared libraries,
13141 *** $file_magic_cmd, produces output that libtool cannot recognize.
13142 *** The result is that libtool may fail to recognize shared libraries
13143 *** as such.  This will affect the creation of libtool libraries that
13144 *** depend on shared libraries, but programs linked with such libtool
13145 *** libraries will work regardless of this problem.  Nevertheless, you
13146 *** may want to report the problem to your system manager and/or to
13147 *** bug-libtool@gnu.org
13148
13149 EOF
13150           fi ;;
13151         esac
13152       fi
13153       break
13154     fi
13155   done
13156   IFS="$lt_save_ifs"
13157   MAGIC_CMD="$lt_save_MAGIC_CMD"
13158   ;;
13159 esac
13160 fi
13161
13162 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
13163 if test -n "$MAGIC_CMD"; then
13164   { echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
13165 echo "${ECHO_T}$MAGIC_CMD" >&6; }
13166 else
13167   { echo "$as_me:$LINENO: result: no" >&5
13168 echo "${ECHO_T}no" >&6; }
13169 fi
13170
13171   else
13172     MAGIC_CMD=:
13173   fi
13174 fi
13175
13176   fi
13177   ;;
13178 esac
13179
13180 enable_dlopen=no
13181 enable_win32_dll=yes
13182
13183 # Check whether --enable-libtool-lock was given.
13184 if test "${enable_libtool_lock+set}" = set; then
13185   enableval=$enable_libtool_lock;
13186 fi
13187
13188 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
13189
13190
13191 # Check whether --with-pic was given.
13192 if test "${with_pic+set}" = set; then
13193   withval=$with_pic; pic_mode="$withval"
13194 else
13195   pic_mode=default
13196 fi
13197
13198 test -z "$pic_mode" && pic_mode=default
13199
13200 # Use C for the default configuration in the libtool script
13201 tagname=
13202 lt_save_CC="$CC"
13203 ac_ext=c
13204 ac_cpp='$CPP $CPPFLAGS'
13205 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13206 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13207 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13208
13209
13210 # Source file extension for C test sources.
13211 ac_ext=c
13212
13213 # Object file extension for compiled C test sources.
13214 objext=o
13215 objext=$objext
13216
13217 # Code to be used in simple compile tests
13218 lt_simple_compile_test_code="int some_variable = 0;"
13219
13220 # Code to be used in simple link tests
13221 lt_simple_link_test_code='int main(){return(0);}'
13222
13223
13224 # If no C compiler was specified, use CC.
13225 LTCC=${LTCC-"$CC"}
13226
13227 # If no C compiler flags were specified, use CFLAGS.
13228 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
13229
13230 # Allow CC to be a program name with arguments.
13231 compiler=$CC
13232
13233
13234 # save warnings/boilerplate of simple test code
13235 ac_outfile=conftest.$ac_objext
13236 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
13237 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
13238 _lt_compiler_boilerplate=`cat conftest.err`
13239 $rm conftest*
13240
13241 ac_outfile=conftest.$ac_objext
13242 echo "$lt_simple_link_test_code" >conftest.$ac_ext
13243 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
13244 _lt_linker_boilerplate=`cat conftest.err`
13245 $rm conftest*
13246
13247
13248
13249 lt_prog_compiler_no_builtin_flag=
13250
13251 if test "$GCC" = yes; then
13252   lt_prog_compiler_no_builtin_flag=' -fno-builtin'
13253
13254
13255 { echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
13256 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6; }
13257 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then
13258   echo $ECHO_N "(cached) $ECHO_C" >&6
13259 else
13260   lt_cv_prog_compiler_rtti_exceptions=no
13261   ac_outfile=conftest.$ac_objext
13262    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
13263    lt_compiler_flag="-fno-rtti -fno-exceptions"
13264    # Insert the option either (1) after the last *FLAGS variable, or
13265    # (2) before a word containing "conftest.", or (3) at the end.
13266    # Note that $ac_compile itself does not contain backslashes and begins
13267    # with a dollar sign (not a hyphen), so the echo should work correctly.
13268    # The option is referenced via a variable to avoid confusing sed.
13269    lt_compile=`echo "$ac_compile" | $SED \
13270    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
13271    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
13272    -e 's:$: $lt_compiler_flag:'`
13273    (eval echo "\"\$as_me:13273: $lt_compile\"" >&5)
13274    (eval "$lt_compile" 2>conftest.err)
13275    ac_status=$?
13276    cat conftest.err >&5
13277    echo "$as_me:13277: \$? = $ac_status" >&5
13278    if (exit $ac_status) && test -s "$ac_outfile"; then
13279      # The compiler can only warn and ignore the option if not recognized
13280      # So say no if there are warnings other than the usual output.
13281      $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
13282      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
13283      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
13284        lt_cv_prog_compiler_rtti_exceptions=yes
13285      fi
13286    fi
13287    $rm conftest*
13288
13289 fi
13290 { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
13291 echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6; }
13292
13293 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
13294     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
13295 else
13296     :
13297 fi
13298
13299 fi
13300
13301 lt_prog_compiler_wl=
13302 lt_prog_compiler_pic=
13303 lt_prog_compiler_static=
13304
13305 { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
13306 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; }
13307
13308   if test "$GCC" = yes; then
13309     lt_prog_compiler_wl='-Wl,'
13310     lt_prog_compiler_static='-static'
13311
13312     case $host_os in
13313       aix*)
13314       # All AIX code is PIC.
13315       if test "$host_cpu" = ia64; then
13316         # AIX 5 now supports IA64 processor
13317         lt_prog_compiler_static='-Bstatic'
13318       fi
13319       ;;
13320
13321     amigaos*)
13322       # FIXME: we need at least 68020 code to build shared libraries, but
13323       # adding the `-m68020' flag to GCC prevents building anything better,
13324       # like `-m68040'.
13325       lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
13326       ;;
13327
13328     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
13329       # PIC is the default for these OSes.
13330       ;;
13331
13332     mingw* | cygwin* | pw32* | os2*)
13333       # This hack is so that the source file can tell whether it is being
13334       # built for inclusion in a dll (and should export symbols for example).
13335       # Although the cygwin gcc ignores -fPIC, still need this for old-style
13336       # (--disable-auto-import) libraries
13337       lt_prog_compiler_pic='-DDLL_EXPORT'
13338       ;;
13339
13340     darwin* | rhapsody*)
13341       # PIC is the default on this platform
13342       # Common symbols not allowed in MH_DYLIB files
13343       lt_prog_compiler_pic='-fno-common'
13344       ;;
13345
13346     interix[3-9]*)
13347       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
13348       # Instead, we relocate shared libraries at runtime.
13349       ;;
13350
13351     msdosdjgpp*)
13352       # Just because we use GCC doesn't mean we suddenly get shared libraries
13353       # on systems that don't support them.
13354       lt_prog_compiler_can_build_shared=no
13355       enable_shared=no
13356       ;;
13357
13358     sysv4*MP*)
13359       if test -d /usr/nec; then
13360         lt_prog_compiler_pic=-Kconform_pic
13361       fi
13362       ;;
13363
13364     hpux*)
13365       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
13366       # not for PA HP-UX.
13367       case $host_cpu in
13368       hppa*64*|ia64*)
13369         # +Z the default
13370         ;;
13371       *)
13372         lt_prog_compiler_pic='-fPIC'
13373         ;;
13374       esac
13375       ;;
13376
13377     *)
13378       lt_prog_compiler_pic='-fPIC'
13379       ;;
13380     esac
13381   else
13382     # PORTME Check for flag to pass linker flags through the system compiler.
13383     case $host_os in
13384     aix*)
13385       lt_prog_compiler_wl='-Wl,'
13386       if test "$host_cpu" = ia64; then
13387         # AIX 5 now supports IA64 processor
13388         lt_prog_compiler_static='-Bstatic'
13389       else
13390         lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
13391       fi
13392       ;;
13393       darwin*)
13394         # PIC is the default on this platform
13395         # Common symbols not allowed in MH_DYLIB files
13396        case $cc_basename in
13397          xlc*)
13398          lt_prog_compiler_pic='-qnocommon'
13399          lt_prog_compiler_wl='-Wl,'
13400          ;;
13401        esac
13402        ;;
13403
13404     mingw* | cygwin* | pw32* | os2*)
13405       # This hack is so that the source file can tell whether it is being
13406       # built for inclusion in a dll (and should export symbols for example).
13407       lt_prog_compiler_pic='-DDLL_EXPORT'
13408       ;;
13409
13410     hpux9* | hpux10* | hpux11*)
13411       lt_prog_compiler_wl='-Wl,'
13412       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
13413       # not for PA HP-UX.
13414       case $host_cpu in
13415       hppa*64*|ia64*)
13416         # +Z the default
13417         ;;
13418       *)
13419         lt_prog_compiler_pic='+Z'
13420         ;;
13421       esac
13422       # Is there a better lt_prog_compiler_static that works with the bundled CC?
13423       lt_prog_compiler_static='${wl}-a ${wl}archive'
13424       ;;
13425
13426     irix5* | irix6* | nonstopux*)
13427       lt_prog_compiler_wl='-Wl,'
13428       # PIC (with -KPIC) is the default.
13429       lt_prog_compiler_static='-non_shared'
13430       ;;
13431
13432     newsos6)
13433       lt_prog_compiler_pic='-KPIC'
13434       lt_prog_compiler_static='-Bstatic'
13435       ;;
13436
13437     linux* | k*bsd*-gnu)
13438       case $cc_basename in
13439       icc* | ecc*)
13440         lt_prog_compiler_wl='-Wl,'
13441         lt_prog_compiler_pic='-KPIC'
13442         lt_prog_compiler_static='-static'
13443         ;;
13444       pgcc* | pgf77* | pgf90* | pgf95*)
13445         # Portland Group compilers (*not* the Pentium gcc compiler,
13446         # which looks to be a dead project)
13447         lt_prog_compiler_wl='-Wl,'
13448         lt_prog_compiler_pic='-fpic'
13449         lt_prog_compiler_static='-Bstatic'
13450         ;;
13451       ccc*)
13452         lt_prog_compiler_wl='-Wl,'
13453         # All Alpha code is PIC.
13454         lt_prog_compiler_static='-non_shared'
13455         ;;
13456       *)
13457         case `$CC -V 2>&1 | sed 5q` in
13458         *Sun\ C*)
13459           # Sun C 5.9
13460           lt_prog_compiler_pic='-KPIC'
13461           lt_prog_compiler_static='-Bstatic'
13462           lt_prog_compiler_wl='-Wl,'
13463           ;;
13464         *Sun\ F*)
13465           # Sun Fortran 8.3 passes all unrecognized flags to the linker
13466           lt_prog_compiler_pic='-KPIC'
13467           lt_prog_compiler_static='-Bstatic'
13468           lt_prog_compiler_wl=''
13469           ;;
13470         esac
13471         ;;
13472       esac
13473       ;;
13474
13475     osf3* | osf4* | osf5*)
13476       lt_prog_compiler_wl='-Wl,'
13477       # All OSF/1 code is PIC.
13478       lt_prog_compiler_static='-non_shared'
13479       ;;
13480
13481     rdos*)
13482       lt_prog_compiler_static='-non_shared'
13483       ;;
13484
13485     solaris*)
13486       lt_prog_compiler_pic='-KPIC'
13487       lt_prog_compiler_static='-Bstatic'
13488       case $cc_basename in
13489       f77* | f90* | f95*)
13490         lt_prog_compiler_wl='-Qoption ld ';;
13491       *)
13492         lt_prog_compiler_wl='-Wl,';;
13493       esac
13494       ;;
13495
13496     sunos4*)
13497       lt_prog_compiler_wl='-Qoption ld '
13498       lt_prog_compiler_pic='-PIC'
13499       lt_prog_compiler_static='-Bstatic'
13500       ;;
13501
13502     sysv4 | sysv4.2uw2* | sysv4.3*)
13503       lt_prog_compiler_wl='-Wl,'
13504       lt_prog_compiler_pic='-KPIC'
13505       lt_prog_compiler_static='-Bstatic'
13506       ;;
13507
13508     sysv4*MP*)
13509       if test -d /usr/nec ;then
13510         lt_prog_compiler_pic='-Kconform_pic'
13511         lt_prog_compiler_static='-Bstatic'
13512       fi
13513       ;;
13514
13515     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
13516       lt_prog_compiler_wl='-Wl,'
13517       lt_prog_compiler_pic='-KPIC'
13518       lt_prog_compiler_static='-Bstatic'
13519       ;;
13520
13521     unicos*)
13522       lt_prog_compiler_wl='-Wl,'
13523       lt_prog_compiler_can_build_shared=no
13524       ;;
13525
13526     uts4*)
13527       lt_prog_compiler_pic='-pic'
13528       lt_prog_compiler_static='-Bstatic'
13529       ;;
13530
13531     *)
13532       lt_prog_compiler_can_build_shared=no
13533       ;;
13534     esac
13535   fi
13536
13537 { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5
13538 echo "${ECHO_T}$lt_prog_compiler_pic" >&6; }
13539
13540 #
13541 # Check to make sure the PIC flag actually works.
13542 #
13543 if test -n "$lt_prog_compiler_pic"; then
13544
13545 { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
13546 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic works... $ECHO_C" >&6; }
13547 if test "${lt_prog_compiler_pic_works+set}" = set; then
13548   echo $ECHO_N "(cached) $ECHO_C" >&6
13549 else
13550   lt_prog_compiler_pic_works=no
13551   ac_outfile=conftest.$ac_objext
13552    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
13553    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
13554    # Insert the option either (1) after the last *FLAGS variable, or
13555    # (2) before a word containing "conftest.", or (3) at the end.
13556    # Note that $ac_compile itself does not contain backslashes and begins
13557    # with a dollar sign (not a hyphen), so the echo should work correctly.
13558    # The option is referenced via a variable to avoid confusing sed.
13559    lt_compile=`echo "$ac_compile" | $SED \
13560    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
13561    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
13562    -e 's:$: $lt_compiler_flag:'`
13563    (eval echo "\"\$as_me:13563: $lt_compile\"" >&5)
13564    (eval "$lt_compile" 2>conftest.err)
13565    ac_status=$?
13566    cat conftest.err >&5
13567    echo "$as_me:13567: \$? = $ac_status" >&5
13568    if (exit $ac_status) && test -s "$ac_outfile"; then
13569      # The compiler can only warn and ignore the option if not recognized
13570      # So say no if there are warnings other than the usual output.
13571      $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
13572      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
13573      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
13574        lt_prog_compiler_pic_works=yes
13575      fi
13576    fi
13577    $rm conftest*
13578
13579 fi
13580 { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works" >&5
13581 echo "${ECHO_T}$lt_prog_compiler_pic_works" >&6; }
13582
13583 if test x"$lt_prog_compiler_pic_works" = xyes; then
13584     case $lt_prog_compiler_pic in
13585      "" | " "*) ;;
13586      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
13587      esac
13588 else
13589     lt_prog_compiler_pic=
13590      lt_prog_compiler_can_build_shared=no
13591 fi
13592
13593 fi
13594 case $host_os in
13595   # For platforms which do not support PIC, -DPIC is meaningless:
13596   *djgpp*)
13597     lt_prog_compiler_pic=
13598     ;;
13599   *)
13600     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
13601     ;;
13602 esac
13603
13604 #
13605 # Check to make sure the static flag actually works.
13606 #
13607 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
13608 { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
13609 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; }
13610 if test "${lt_prog_compiler_static_works+set}" = set; then
13611   echo $ECHO_N "(cached) $ECHO_C" >&6
13612 else
13613   lt_prog_compiler_static_works=no
13614    save_LDFLAGS="$LDFLAGS"
13615    LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
13616    echo "$lt_simple_link_test_code" > conftest.$ac_ext
13617    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
13618      # The linker can only warn and ignore the option if not recognized
13619      # So say no if there are warnings
13620      if test -s conftest.err; then
13621        # Append any errors to the config.log.
13622        cat conftest.err 1>&5
13623        $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
13624        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
13625        if diff conftest.exp conftest.er2 >/dev/null; then
13626          lt_prog_compiler_static_works=yes
13627        fi
13628      else
13629        lt_prog_compiler_static_works=yes
13630      fi
13631    fi
13632    $rm conftest*
13633    LDFLAGS="$save_LDFLAGS"
13634
13635 fi
13636 { echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works" >&5
13637 echo "${ECHO_T}$lt_prog_compiler_static_works" >&6; }
13638
13639 if test x"$lt_prog_compiler_static_works" = xyes; then
13640     :
13641 else
13642     lt_prog_compiler_static=
13643 fi
13644
13645
13646 { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
13647 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; }
13648 if test "${lt_cv_prog_compiler_c_o+set}" = set; then
13649   echo $ECHO_N "(cached) $ECHO_C" >&6
13650 else
13651   lt_cv_prog_compiler_c_o=no
13652    $rm -r conftest 2>/dev/null
13653    mkdir conftest
13654    cd conftest
13655    mkdir out
13656    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
13657
13658    lt_compiler_flag="-o out/conftest2.$ac_objext"
13659    # Insert the option either (1) after the last *FLAGS variable, or
13660    # (2) before a word containing "conftest.", or (3) at the end.
13661    # Note that $ac_compile itself does not contain backslashes and begins
13662    # with a dollar sign (not a hyphen), so the echo should work correctly.
13663    lt_compile=`echo "$ac_compile" | $SED \
13664    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
13665    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
13666    -e 's:$: $lt_compiler_flag:'`
13667    (eval echo "\"\$as_me:13667: $lt_compile\"" >&5)
13668    (eval "$lt_compile" 2>out/conftest.err)
13669    ac_status=$?
13670    cat out/conftest.err >&5
13671    echo "$as_me:13671: \$? = $ac_status" >&5
13672    if (exit $ac_status) && test -s out/conftest2.$ac_objext
13673    then
13674      # The compiler can only warn and ignore the option if not recognized
13675      # So say no if there are warnings
13676      $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
13677      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
13678      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
13679        lt_cv_prog_compiler_c_o=yes
13680      fi
13681    fi
13682    chmod u+w . 2>&5
13683    $rm conftest*
13684    # SGI C++ compiler will create directory out/ii_files/ for
13685    # template instantiation
13686    test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
13687    $rm out/* && rmdir out
13688    cd ..
13689    rmdir conftest
13690    $rm conftest*
13691
13692 fi
13693 { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
13694 echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6; }
13695
13696
13697 hard_links="nottested"
13698 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
13699   # do not overwrite the value of need_locks provided by the user
13700   { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
13701 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; }
13702   hard_links=yes
13703   $rm conftest*
13704   ln conftest.a conftest.b 2>/dev/null && hard_links=no
13705   touch conftest.a
13706   ln conftest.a conftest.b 2>&5 || hard_links=no
13707   ln conftest.a conftest.b 2>/dev/null && hard_links=no
13708   { echo "$as_me:$LINENO: result: $hard_links" >&5
13709 echo "${ECHO_T}$hard_links" >&6; }
13710   if test "$hard_links" = no; then
13711     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
13712 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
13713     need_locks=warn
13714   fi
13715 else
13716   need_locks=no
13717 fi
13718
13719 { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
13720 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; }
13721
13722   runpath_var=
13723   allow_undefined_flag=
13724   enable_shared_with_static_runtimes=no
13725   archive_cmds=
13726   archive_expsym_cmds=
13727   old_archive_From_new_cmds=
13728   old_archive_from_expsyms_cmds=
13729   export_dynamic_flag_spec=
13730   whole_archive_flag_spec=
13731   thread_safe_flag_spec=
13732   hardcode_libdir_flag_spec=
13733   hardcode_libdir_flag_spec_ld=
13734   hardcode_libdir_separator=
13735   hardcode_direct=no
13736   hardcode_minus_L=no
13737   hardcode_shlibpath_var=unsupported
13738   link_all_deplibs=unknown
13739   hardcode_automatic=no
13740   module_cmds=
13741   module_expsym_cmds=
13742   always_export_symbols=no
13743   export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
13744   # include_expsyms should be a list of space-separated symbols to be *always*
13745   # included in the symbol list
13746   include_expsyms=
13747   # exclude_expsyms can be an extended regexp of symbols to exclude
13748   # it will be wrapped by ` (' and `)$', so one must not match beginning or
13749   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
13750   # as well as any symbol that contains `d'.
13751   exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
13752   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
13753   # platforms (ab)use it in PIC code, but their linkers get confused if
13754   # the symbol is explicitly referenced.  Since portable code cannot
13755   # rely on this symbol name, it's probably fine to never include it in
13756   # preloaded symbol tables.
13757   extract_expsyms_cmds=
13758   # Just being paranoid about ensuring that cc_basename is set.
13759   for cc_temp in $compiler""; do
13760   case $cc_temp in
13761     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
13762     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
13763     \-*) ;;
13764     *) break;;
13765   esac
13766 done
13767 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
13768
13769   case $host_os in
13770   cygwin* | mingw* | pw32*)
13771     # FIXME: the MSVC++ port hasn't been tested in a loooong time
13772     # When not using gcc, we currently assume that we are using
13773     # Microsoft Visual C++.
13774     if test "$GCC" != yes; then
13775       with_gnu_ld=no
13776     fi
13777     ;;
13778   interix*)
13779     # we just hope/assume this is gcc and not c89 (= MSVC++)
13780     with_gnu_ld=yes
13781     ;;
13782   openbsd*)
13783     with_gnu_ld=no
13784     ;;
13785   esac
13786
13787   ld_shlibs=yes
13788   if test "$with_gnu_ld" = yes; then
13789     # If archive_cmds runs LD, not CC, wlarc should be empty
13790     wlarc='${wl}'
13791
13792     # Set some defaults for GNU ld with shared library support. These
13793     # are reset later if shared libraries are not supported. Putting them
13794     # here allows them to be overridden if necessary.
13795     runpath_var=LD_RUN_PATH
13796     hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir'
13797     export_dynamic_flag_spec='${wl}--export-dynamic'
13798     # ancient GNU ld didn't support --whole-archive et. al.
13799     if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
13800         whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
13801       else
13802         whole_archive_flag_spec=
13803     fi
13804     supports_anon_versioning=no
13805     case `$LD -v 2>/dev/null` in
13806       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
13807       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
13808       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
13809       *\ 2.11.*) ;; # other 2.11 versions
13810       *) supports_anon_versioning=yes ;;
13811     esac
13812
13813     # See if GNU ld supports shared libraries.
13814     case $host_os in
13815     aix3* | aix4* | aix5*)
13816       # On AIX/PPC, the GNU linker is very broken
13817       if test "$host_cpu" != ia64; then
13818         ld_shlibs=no
13819         cat <<EOF 1>&2
13820
13821 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
13822 *** to be unable to reliably create shared libraries on AIX.
13823 *** Therefore, libtool is disabling shared libraries support.  If you
13824 *** really care for shared libraries, you may want to modify your PATH
13825 *** so that a non-GNU linker is found, and then restart.
13826
13827 EOF
13828       fi
13829       ;;
13830
13831     amigaos*)
13832       archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
13833       hardcode_libdir_flag_spec='-L$libdir'
13834       hardcode_minus_L=yes
13835
13836       # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
13837       # that the semantics of dynamic libraries on AmigaOS, at least up
13838       # to version 4, is to share data among multiple programs linked
13839       # with the same dynamic library.  Since this doesn't match the
13840       # behavior of shared libraries on other platforms, we can't use
13841       # them.
13842       ld_shlibs=no
13843       ;;
13844
13845     beos*)
13846       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
13847         allow_undefined_flag=unsupported
13848         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
13849         # support --undefined.  This deserves some investigation.  FIXME
13850         archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13851       else
13852         ld_shlibs=no
13853       fi
13854       ;;
13855
13856     cygwin* | mingw* | pw32*)
13857       # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
13858       # as there is no search path for DLLs.
13859       hardcode_libdir_flag_spec='-L$libdir'
13860       allow_undefined_flag=unsupported
13861       always_export_symbols=no
13862       enable_shared_with_static_runtimes=yes
13863       export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
13864
13865       if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
13866         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
13867         # If the export-symbols file already is a .def file (1st line
13868         # is EXPORTS), use it as is; otherwise, prepend...
13869         archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
13870           cp $export_symbols $output_objdir/$soname.def;
13871         else
13872           echo EXPORTS > $output_objdir/$soname.def;
13873           cat $export_symbols >> $output_objdir/$soname.def;
13874         fi~
13875         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
13876       else
13877         ld_shlibs=no
13878       fi
13879       ;;
13880
13881     interix[3-9]*)
13882       hardcode_direct=no
13883       hardcode_shlibpath_var=no
13884       hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
13885       export_dynamic_flag_spec='${wl}-E'
13886       # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
13887       # Instead, shared libraries are loaded at an image base (0x10000000 by
13888       # default) and relocated if they conflict, which is a slow very memory
13889       # consuming and fragmenting process.  To avoid this, we pick a random,
13890       # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
13891       # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
13892       archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
13893       archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
13894       ;;
13895
13896     gnu* | linux* | k*bsd*-gnu)
13897       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
13898         tmp_addflag=
13899         case $cc_basename,$host_cpu in
13900         pgcc*)                          # Portland Group C compiler
13901           whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
13902           tmp_addflag=' $pic_flag'
13903           ;;
13904         pgf77* | pgf90* | pgf95*)       # Portland Group f77 and f90 compilers
13905           whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
13906           tmp_addflag=' $pic_flag -Mnomain' ;;
13907         ecc*,ia64* | icc*,ia64*)                # Intel C compiler on ia64
13908           tmp_addflag=' -i_dynamic' ;;
13909         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
13910           tmp_addflag=' -i_dynamic -nofor_main' ;;
13911         ifc* | ifort*)                  # Intel Fortran compiler
13912           tmp_addflag=' -nofor_main' ;;
13913         esac
13914         case `$CC -V 2>&1 | sed 5q` in
13915         *Sun\ C*)                       # Sun C 5.9
13916           whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
13917           tmp_sharedflag='-G' ;;
13918         *Sun\ F*)                       # Sun Fortran 8.3
13919           tmp_sharedflag='-G' ;;
13920         *)
13921           tmp_sharedflag='-shared' ;;
13922         esac
13923         archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13924
13925         if test $supports_anon_versioning = yes; then
13926           archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~
13927   cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
13928   $echo "local: *; };" >> $output_objdir/$libname.ver~
13929           $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
13930         fi
13931       else
13932         ld_shlibs=no
13933       fi
13934       ;;
13935
13936     netbsd*)
13937       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
13938         archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
13939         wlarc=
13940       else
13941         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13942         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
13943       fi
13944       ;;
13945
13946     solaris*)
13947       if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
13948         ld_shlibs=no
13949         cat <<EOF 1>&2
13950
13951 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
13952 *** create shared libraries on Solaris systems.  Therefore, libtool
13953 *** is disabling shared libraries support.  We urge you to upgrade GNU
13954 *** binutils to release 2.9.1 or newer.  Another option is to modify
13955 *** your PATH or compiler configuration so that the native linker is
13956 *** used, and then restart.
13957
13958 EOF
13959       elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
13960         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
13961         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
13962       else
13963         ld_shlibs=no
13964       fi
13965       ;;
13966
13967     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
13968       case `$LD -v 2>&1` in
13969         *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
13970         ld_shlibs=no
13971         cat <<_LT_EOF 1>&2
13972
13973 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
13974 *** reliably create shared libraries on SCO systems.  Therefore, libtool
13975 *** is disabling shared libraries support.  We urge you to upgrade GNU
13976 *** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
13977 *** your PATH or compiler configuration so that the native linker is
13978 *** used, and then restart.
13979
13980 _LT_EOF
13981         ;;
13982         *)
13983           if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
13984             hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
13985             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
13986             archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
13987           else
13988             ld_shlibs=no
13989           fi
13990         ;;
13991       esac
13992       ;;
13993
13994     sunos4*)
13995       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
13996       wlarc=
13997       hardcode_direct=yes
13998       hardcode_shlibpath_var=no
13999       ;;
14000
14001     *)
14002       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
14003         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
14004         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
14005       else
14006         ld_shlibs=no
14007       fi
14008       ;;
14009     esac
14010
14011     if test "$ld_shlibs" = no; then
14012       runpath_var=
14013       hardcode_libdir_flag_spec=
14014       export_dynamic_flag_spec=
14015       whole_archive_flag_spec=
14016     fi
14017   else
14018     # PORTME fill in a description of your system's linker (not GNU ld)
14019     case $host_os in
14020     aix3*)
14021       allow_undefined_flag=unsupported
14022       always_export_symbols=yes
14023       archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
14024       # Note: this linker hardcodes the directories in LIBPATH if there
14025       # are no directories specified by -L.
14026       hardcode_minus_L=yes
14027       if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
14028         # Neither direct hardcoding nor static linking is supported with a
14029         # broken collect2.
14030         hardcode_direct=unsupported
14031       fi
14032       ;;
14033
14034     aix4* | aix5*)
14035       if test "$host_cpu" = ia64; then
14036         # On IA64, the linker does run time linking by default, so we don't
14037         # have to do anything special.
14038         aix_use_runtimelinking=no
14039         exp_sym_flag='-Bexport'
14040         no_entry_flag=""
14041       else
14042         # If we're using GNU nm, then we don't want the "-C" option.
14043         # -C means demangle to AIX nm, but means don't demangle with GNU nm
14044         if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
14045           export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
14046         else
14047           export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
14048         fi
14049         aix_use_runtimelinking=no
14050
14051         # Test if we are trying to use run time linking or normal
14052         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
14053         # need to do runtime linking.
14054         case $host_os in aix4.[23]|aix4.[23].*|aix5*)
14055           for ld_flag in $LDFLAGS; do
14056           if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
14057             aix_use_runtimelinking=yes
14058             break
14059           fi
14060           done
14061           ;;
14062         esac
14063
14064         exp_sym_flag='-bexport'
14065         no_entry_flag='-bnoentry'
14066       fi
14067
14068       # When large executables or shared objects are built, AIX ld can
14069       # have problems creating the table of contents.  If linking a library
14070       # or program results in "error TOC overflow" add -mminimal-toc to
14071       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
14072       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
14073
14074       archive_cmds=''
14075       hardcode_direct=yes
14076       hardcode_libdir_separator=':'
14077       link_all_deplibs=yes
14078
14079       if test "$GCC" = yes; then
14080         case $host_os in aix4.[012]|aix4.[012].*)
14081         # We only want to do this on AIX 4.2 and lower, the check
14082         # below for broken collect2 doesn't work under 4.3+
14083           collect2name=`${CC} -print-prog-name=collect2`
14084           if test -f "$collect2name" && \
14085            strings "$collect2name" | grep resolve_lib_name >/dev/null
14086           then
14087           # We have reworked collect2
14088           :
14089           else
14090           # We have old collect2
14091           hardcode_direct=unsupported
14092           # It fails to find uninstalled libraries when the uninstalled
14093           # path is not listed in the libpath.  Setting hardcode_minus_L
14094           # to unsupported forces relinking
14095           hardcode_minus_L=yes
14096           hardcode_libdir_flag_spec='-L$libdir'
14097           hardcode_libdir_separator=
14098           fi
14099           ;;
14100         esac
14101         shared_flag='-shared'
14102         if test "$aix_use_runtimelinking" = yes; then
14103           shared_flag="$shared_flag "'${wl}-G'
14104         fi
14105       else
14106         # not using gcc
14107         if test "$host_cpu" = ia64; then
14108         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
14109         # chokes on -Wl,-G. The following line is correct:
14110           shared_flag='-G'
14111         else
14112           if test "$aix_use_runtimelinking" = yes; then
14113             shared_flag='${wl}-G'
14114           else
14115             shared_flag='${wl}-bM:SRE'
14116           fi
14117         fi
14118       fi
14119
14120       # It seems that -bexpall does not export symbols beginning with
14121       # underscore (_), so it is better to generate a list of symbols to export.
14122       always_export_symbols=yes
14123       if test "$aix_use_runtimelinking" = yes; then
14124         # Warning - without using the other runtime loading flags (-brtl),
14125         # -berok will link without error, but may produce a broken library.
14126         allow_undefined_flag='-berok'
14127        # Determine the default libpath from the value encoded in an empty executable.
14128        cat >conftest.$ac_ext <<_ACEOF
14129 /* confdefs.h.  */
14130 _ACEOF
14131 cat confdefs.h >>conftest.$ac_ext
14132 cat >>conftest.$ac_ext <<_ACEOF
14133 /* end confdefs.h.  */
14134
14135 int
14136 main ()
14137 {
14138
14139   ;
14140   return 0;
14141 }
14142 _ACEOF
14143 rm -f conftest.$ac_objext conftest$ac_exeext
14144 if { (ac_try="$ac_link"
14145 case "(($ac_try" in
14146   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14147   *) ac_try_echo=$ac_try;;
14148 esac
14149 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14150   (eval "$ac_link") 2>conftest.er1
14151   ac_status=$?
14152   grep -v '^ *+' conftest.er1 >conftest.err
14153   rm -f conftest.er1
14154   cat conftest.err >&5
14155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14156   (exit $ac_status); } && {
14157          test -z "$ac_c_werror_flag" ||
14158          test ! -s conftest.err
14159        } && test -s conftest$ac_exeext &&
14160        $as_test_x conftest$ac_exeext; then
14161
14162 lt_aix_libpath_sed='
14163     /Import File Strings/,/^$/ {
14164         /^0/ {
14165             s/^0  *\(.*\)$/\1/
14166             p
14167         }
14168     }'
14169 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
14170 # Check for a 64-bit object if we didn't find anything.
14171 if test -z "$aix_libpath"; then
14172   aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
14173 fi
14174 else
14175   echo "$as_me: failed program was:" >&5
14176 sed 's/^/| /' conftest.$ac_ext >&5
14177
14178
14179 fi
14180
14181 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14182       conftest$ac_exeext conftest.$ac_ext
14183 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
14184
14185        hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
14186         archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
14187        else
14188         if test "$host_cpu" = ia64; then
14189           hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
14190           allow_undefined_flag="-z nodefs"
14191           archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
14192         else
14193          # Determine the default libpath from the value encoded in an empty executable.
14194          cat >conftest.$ac_ext <<_ACEOF
14195 /* confdefs.h.  */
14196 _ACEOF
14197 cat confdefs.h >>conftest.$ac_ext
14198 cat >>conftest.$ac_ext <<_ACEOF
14199 /* end confdefs.h.  */
14200
14201 int
14202 main ()
14203 {
14204
14205   ;
14206   return 0;
14207 }
14208 _ACEOF
14209 rm -f conftest.$ac_objext conftest$ac_exeext
14210 if { (ac_try="$ac_link"
14211 case "(($ac_try" in
14212   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14213   *) ac_try_echo=$ac_try;;
14214 esac
14215 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14216   (eval "$ac_link") 2>conftest.er1
14217   ac_status=$?
14218   grep -v '^ *+' conftest.er1 >conftest.err
14219   rm -f conftest.er1
14220   cat conftest.err >&5
14221   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14222   (exit $ac_status); } && {
14223          test -z "$ac_c_werror_flag" ||
14224          test ! -s conftest.err
14225        } && test -s conftest$ac_exeext &&
14226        $as_test_x conftest$ac_exeext; then
14227
14228 lt_aix_libpath_sed='
14229     /Import File Strings/,/^$/ {
14230         /^0/ {
14231             s/^0  *\(.*\)$/\1/
14232             p
14233         }
14234     }'
14235 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
14236 # Check for a 64-bit object if we didn't find anything.
14237 if test -z "$aix_libpath"; then
14238   aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
14239 fi
14240 else
14241   echo "$as_me: failed program was:" >&5
14242 sed 's/^/| /' conftest.$ac_ext >&5
14243
14244
14245 fi
14246
14247 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14248       conftest$ac_exeext conftest.$ac_ext
14249 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
14250
14251          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
14252           # Warning - without using the other run time loading flags,
14253           # -berok will link without error, but may produce a broken library.
14254           no_undefined_flag=' ${wl}-bernotok'
14255           allow_undefined_flag=' ${wl}-berok'
14256           # Exported symbols can be pulled into shared objects from archives
14257           whole_archive_flag_spec='$convenience'
14258           archive_cmds_need_lc=yes
14259           # This is similar to how AIX traditionally builds its shared libraries.
14260           archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
14261         fi
14262       fi
14263       ;;
14264
14265     amigaos*)
14266       archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
14267       hardcode_libdir_flag_spec='-L$libdir'
14268       hardcode_minus_L=yes
14269       # see comment about different semantics on the GNU ld section
14270       ld_shlibs=no
14271       ;;
14272
14273     bsdi[45]*)
14274       export_dynamic_flag_spec=-rdynamic
14275       ;;
14276
14277     cygwin* | mingw* | pw32*)
14278       # When not using gcc, we currently assume that we are using
14279       # Microsoft Visual C++.
14280       # hardcode_libdir_flag_spec is actually meaningless, as there is
14281       # no search path for DLLs.
14282       hardcode_libdir_flag_spec=' '
14283       allow_undefined_flag=unsupported
14284       # Tell ltmain to make .lib files, not .a files.
14285       libext=lib
14286       # Tell ltmain to make .dll files, not .so files.
14287       shrext_cmds=".dll"
14288       # FIXME: Setting linknames here is a bad hack.
14289       archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
14290       # The linker will automatically build a .lib file if we build a DLL.
14291       old_archive_From_new_cmds='true'
14292       # FIXME: Should let the user specify the lib program.
14293       old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
14294       fix_srcfile_path='`cygpath -w "$srcfile"`'
14295       enable_shared_with_static_runtimes=yes
14296       ;;
14297
14298     darwin* | rhapsody*)
14299       case $host_os in
14300         rhapsody* | darwin1.[012])
14301          allow_undefined_flag='${wl}-undefined ${wl}suppress'
14302          ;;
14303        *) # Darwin 1.3 on
14304          if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
14305            allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
14306          else
14307            case ${MACOSX_DEPLOYMENT_TARGET} in
14308              10.[012])
14309                allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
14310                ;;
14311              10.*)
14312                allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup'
14313                ;;
14314            esac
14315          fi
14316          ;;
14317       esac
14318       archive_cmds_need_lc=no
14319       hardcode_direct=no
14320       hardcode_automatic=yes
14321       hardcode_shlibpath_var=unsupported
14322       whole_archive_flag_spec=''
14323       link_all_deplibs=yes
14324     if test "$GCC" = yes ; then
14325         output_verbose_link_cmd='echo'
14326         archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
14327       module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
14328       # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
14329       archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
14330       module_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
14331     else
14332       case $cc_basename in
14333         xlc*)
14334          output_verbose_link_cmd='echo'
14335          archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
14336          module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
14337           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
14338          archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
14339           module_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
14340           ;;
14341        *)
14342          ld_shlibs=no
14343           ;;
14344       esac
14345     fi
14346       ;;
14347
14348     dgux*)
14349       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
14350       hardcode_libdir_flag_spec='-L$libdir'
14351       hardcode_shlibpath_var=no
14352       ;;
14353
14354     freebsd1*)
14355       ld_shlibs=no
14356       ;;
14357
14358     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
14359     # support.  Future versions do this automatically, but an explicit c++rt0.o
14360     # does not break anything, and helps significantly (at the cost of a little
14361     # extra space).
14362     freebsd2.2*)
14363       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
14364       hardcode_libdir_flag_spec='-R$libdir'
14365       hardcode_direct=yes
14366       hardcode_shlibpath_var=no
14367       ;;
14368
14369     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
14370     freebsd2*)
14371       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
14372       hardcode_direct=yes
14373       hardcode_minus_L=yes
14374       hardcode_shlibpath_var=no
14375       ;;
14376
14377     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
14378     freebsd* | dragonfly*)
14379       archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
14380       hardcode_libdir_flag_spec='-R$libdir'
14381       hardcode_direct=yes
14382       hardcode_shlibpath_var=no
14383       ;;
14384
14385     hpux9*)
14386       if test "$GCC" = yes; then
14387         archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
14388       else
14389         archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
14390       fi
14391       hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
14392       hardcode_libdir_separator=:
14393       hardcode_direct=yes
14394
14395       # hardcode_minus_L: Not really in the search PATH,
14396       # but as the default location of the library.
14397       hardcode_minus_L=yes
14398       export_dynamic_flag_spec='${wl}-E'
14399       ;;
14400
14401     hpux10*)
14402       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
14403         archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
14404       else
14405         archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
14406       fi
14407       if test "$with_gnu_ld" = no; then
14408         hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
14409         hardcode_libdir_separator=:
14410
14411         hardcode_direct=yes
14412         export_dynamic_flag_spec='${wl}-E'
14413
14414         # hardcode_minus_L: Not really in the search PATH,
14415         # but as the default location of the library.
14416         hardcode_minus_L=yes
14417       fi
14418       ;;
14419
14420     hpux11*)
14421       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
14422         case $host_cpu in
14423         hppa*64*)
14424           archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
14425           ;;
14426         ia64*)
14427           archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
14428           ;;
14429         *)
14430           archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
14431           ;;
14432         esac
14433       else
14434         case $host_cpu in
14435         hppa*64*)
14436           archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
14437           ;;
14438         ia64*)
14439           archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
14440           ;;
14441         *)
14442           archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
14443           ;;
14444         esac
14445       fi
14446       if test "$with_gnu_ld" = no; then
14447         hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
14448         hardcode_libdir_separator=:
14449
14450         case $host_cpu in
14451         hppa*64*|ia64*)
14452           hardcode_libdir_flag_spec_ld='+b $libdir'
14453           hardcode_direct=no
14454           hardcode_shlibpath_var=no
14455           ;;
14456         *)
14457           hardcode_direct=yes
14458           export_dynamic_flag_spec='${wl}-E'
14459
14460           # hardcode_minus_L: Not really in the search PATH,
14461           # but as the default location of the library.
14462           hardcode_minus_L=yes
14463           ;;
14464         esac
14465       fi
14466       ;;
14467
14468     irix5* | irix6* | nonstopux*)
14469       if test "$GCC" = yes; then
14470         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
14471       else
14472         archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
14473         hardcode_libdir_flag_spec_ld='-rpath $libdir'
14474       fi
14475       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
14476       hardcode_libdir_separator=:
14477       link_all_deplibs=yes
14478       ;;
14479
14480     netbsd*)
14481       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
14482         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
14483       else
14484         archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
14485       fi
14486       hardcode_libdir_flag_spec='-R$libdir'
14487       hardcode_direct=yes
14488       hardcode_shlibpath_var=no
14489       ;;
14490
14491     newsos6)
14492       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
14493       hardcode_direct=yes
14494       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
14495       hardcode_libdir_separator=:
14496       hardcode_shlibpath_var=no
14497       ;;
14498
14499     openbsd*)
14500       if test -f /usr/libexec/ld.so; then
14501         hardcode_direct=yes
14502         hardcode_shlibpath_var=no
14503         if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
14504           archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
14505           archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
14506           hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
14507           export_dynamic_flag_spec='${wl}-E'
14508         else
14509           case $host_os in
14510            openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
14511              archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
14512              hardcode_libdir_flag_spec='-R$libdir'
14513              ;;
14514            *)
14515              archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
14516              hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
14517              ;;
14518           esac
14519         fi
14520       else
14521         ld_shlibs=no
14522       fi
14523       ;;
14524
14525     os2*)
14526       hardcode_libdir_flag_spec='-L$libdir'
14527       hardcode_minus_L=yes
14528       allow_undefined_flag=unsupported
14529       archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
14530       old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
14531       ;;
14532
14533     osf3*)
14534       if test "$GCC" = yes; then
14535         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
14536         archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
14537       else
14538         allow_undefined_flag=' -expect_unresolved \*'
14539         archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
14540       fi
14541       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
14542       hardcode_libdir_separator=:
14543       ;;
14544
14545     osf4* | osf5*)      # as osf3* with the addition of -msym flag
14546       if test "$GCC" = yes; then
14547         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
14548         archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
14549         hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
14550       else
14551         allow_undefined_flag=' -expect_unresolved \*'
14552         archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
14553         archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
14554         $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp'
14555
14556         # Both c and cxx compiler support -rpath directly
14557         hardcode_libdir_flag_spec='-rpath $libdir'
14558       fi
14559       hardcode_libdir_separator=:
14560       ;;
14561
14562     solaris*)
14563       no_undefined_flag=' -z text'
14564       if test "$GCC" = yes; then
14565         wlarc='${wl}'
14566         archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
14567         archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
14568           $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
14569       else
14570         wlarc=''
14571         archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
14572         archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
14573         $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
14574       fi
14575       hardcode_libdir_flag_spec='-R$libdir'
14576       hardcode_shlibpath_var=no
14577       case $host_os in
14578       solaris2.[0-5] | solaris2.[0-5].*) ;;
14579       *)
14580         # The compiler driver will combine and reorder linker options,
14581         # but understands `-z linker_flag'.  GCC discards it without `$wl',
14582         # but is careful enough not to reorder.
14583         # Supported since Solaris 2.6 (maybe 2.5.1?)
14584         if test "$GCC" = yes; then
14585           whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
14586         else
14587           whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
14588         fi
14589         ;;
14590       esac
14591       link_all_deplibs=yes
14592       ;;
14593
14594     sunos4*)
14595       if test "x$host_vendor" = xsequent; then
14596         # Use $CC to link under sequent, because it throws in some extra .o
14597         # files that make .init and .fini sections work.
14598         archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
14599       else
14600         archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
14601       fi
14602       hardcode_libdir_flag_spec='-L$libdir'
14603       hardcode_direct=yes
14604       hardcode_minus_L=yes
14605       hardcode_shlibpath_var=no
14606       ;;
14607
14608     sysv4)
14609       case $host_vendor in
14610         sni)
14611           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
14612           hardcode_direct=yes # is this really true???
14613         ;;
14614         siemens)
14615           ## LD is ld it makes a PLAMLIB
14616           ## CC just makes a GrossModule.
14617           archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
14618           reload_cmds='$CC -r -o $output$reload_objs'
14619           hardcode_direct=no
14620         ;;
14621         motorola)
14622           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
14623           hardcode_direct=no #Motorola manual says yes, but my tests say they lie
14624         ;;
14625       esac
14626       runpath_var='LD_RUN_PATH'
14627       hardcode_shlibpath_var=no
14628       ;;
14629
14630     sysv4.3*)
14631       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
14632       hardcode_shlibpath_var=no
14633       export_dynamic_flag_spec='-Bexport'
14634       ;;
14635
14636     sysv4*MP*)
14637       if test -d /usr/nec; then
14638         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
14639         hardcode_shlibpath_var=no
14640         runpath_var=LD_RUN_PATH
14641         hardcode_runpath_var=yes
14642         ld_shlibs=yes
14643       fi
14644       ;;
14645
14646     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
14647       no_undefined_flag='${wl}-z,text'
14648       archive_cmds_need_lc=no
14649       hardcode_shlibpath_var=no
14650       runpath_var='LD_RUN_PATH'
14651
14652       if test "$GCC" = yes; then
14653         archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
14654         archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
14655       else
14656         archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
14657         archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
14658       fi
14659       ;;
14660
14661     sysv5* | sco3.2v5* | sco5v6*)
14662       # Note: We can NOT use -z defs as we might desire, because we do not
14663       # link with -lc, and that would cause any symbols used from libc to
14664       # always be unresolved, which means just about no library would
14665       # ever link correctly.  If we're not using GNU ld we use -z text
14666       # though, which does catch some bad symbols but isn't as heavy-handed
14667       # as -z defs.
14668       no_undefined_flag='${wl}-z,text'
14669       allow_undefined_flag='${wl}-z,nodefs'
14670       archive_cmds_need_lc=no
14671       hardcode_shlibpath_var=no
14672       hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
14673       hardcode_libdir_separator=':'
14674       link_all_deplibs=yes
14675       export_dynamic_flag_spec='${wl}-Bexport'
14676       runpath_var='LD_RUN_PATH'
14677
14678       if test "$GCC" = yes; then
14679         archive_cmds='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
14680         archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
14681       else
14682         archive_cmds='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
14683         archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
14684       fi
14685       ;;
14686
14687     uts4*)
14688       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
14689       hardcode_libdir_flag_spec='-L$libdir'
14690       hardcode_shlibpath_var=no
14691       ;;
14692
14693     *)
14694       ld_shlibs=no
14695       ;;
14696     esac
14697   fi
14698
14699 { echo "$as_me:$LINENO: result: $ld_shlibs" >&5
14700 echo "${ECHO_T}$ld_shlibs" >&6; }
14701 test "$ld_shlibs" = no && can_build_shared=no
14702
14703 #
14704 # Do we need to explicitly link libc?
14705 #
14706 case "x$archive_cmds_need_lc" in
14707 x|xyes)
14708   # Assume -lc should be added
14709   archive_cmds_need_lc=yes
14710
14711   if test "$enable_shared" = yes && test "$GCC" = yes; then
14712     case $archive_cmds in
14713     *'~'*)
14714       # FIXME: we may have to deal with multi-command sequences.
14715       ;;
14716     '$CC '*)
14717       # Test whether the compiler implicitly links with -lc since on some
14718       # systems, -lgcc has to come before -lc. If gcc already passes -lc
14719       # to ld, don't add -lc before -lgcc.
14720       { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
14721 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; }
14722       $rm conftest*
14723       echo "$lt_simple_compile_test_code" > conftest.$ac_ext
14724
14725       if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14726   (eval $ac_compile) 2>&5
14727   ac_status=$?
14728   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14729   (exit $ac_status); } 2>conftest.err; then
14730         soname=conftest
14731         lib=conftest
14732         libobjs=conftest.$ac_objext
14733         deplibs=
14734         wl=$lt_prog_compiler_wl
14735         pic_flag=$lt_prog_compiler_pic
14736         compiler_flags=-v
14737         linker_flags=-v
14738         verstring=
14739         output_objdir=.
14740         libname=conftest
14741         lt_save_allow_undefined_flag=$allow_undefined_flag
14742         allow_undefined_flag=
14743         if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5
14744   (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
14745   ac_status=$?
14746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14747   (exit $ac_status); }
14748         then
14749           archive_cmds_need_lc=no
14750         else
14751           archive_cmds_need_lc=yes
14752         fi
14753         allow_undefined_flag=$lt_save_allow_undefined_flag
14754       else
14755         cat conftest.err 1>&5
14756       fi
14757       $rm conftest*
14758       { echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5
14759 echo "${ECHO_T}$archive_cmds_need_lc" >&6; }
14760       ;;
14761     esac
14762   fi
14763   ;;
14764 esac
14765
14766 { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
14767 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; }
14768 library_names_spec=
14769 libname_spec='lib$name'
14770 soname_spec=
14771 shrext_cmds=".so"
14772 postinstall_cmds=
14773 postuninstall_cmds=
14774 finish_cmds=
14775 finish_eval=
14776 shlibpath_var=
14777 shlibpath_overrides_runpath=unknown
14778 version_type=none
14779 dynamic_linker="$host_os ld.so"
14780 sys_lib_dlsearch_path_spec="/lib /usr/lib"
14781
14782 if test "$GCC" = yes; then
14783   case $host_os in
14784     darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
14785     *) lt_awk_arg="/^libraries:/" ;;
14786   esac
14787   lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
14788   if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then
14789     # if the path contains ";" then we assume it to be the separator
14790     # otherwise default to the standard path separator (i.e. ":") - it is
14791     # assumed that no part of a normal pathname contains ";" but that should
14792     # okay in the real world where ";" in dirpaths is itself problematic.
14793     lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'`
14794   else
14795     lt_search_path_spec=`echo "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
14796   fi
14797   # Ok, now we have the path, separated by spaces, we can step through it
14798   # and add multilib dir if necessary.
14799   lt_tmp_lt_search_path_spec=
14800   lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
14801   for lt_sys_path in $lt_search_path_spec; do
14802     if test -d "$lt_sys_path/$lt_multi_os_dir"; then
14803       lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
14804     else
14805       test -d "$lt_sys_path" && \
14806         lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
14807     fi
14808   done
14809   lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk '
14810 BEGIN {RS=" "; FS="/|\n";} {
14811   lt_foo="";
14812   lt_count=0;
14813   for (lt_i = NF; lt_i > 0; lt_i--) {
14814     if ($lt_i != "" && $lt_i != ".") {
14815       if ($lt_i == "..") {
14816         lt_count++;
14817       } else {
14818         if (lt_count == 0) {
14819           lt_foo="/" $lt_i lt_foo;
14820         } else {
14821           lt_count--;
14822         }
14823       }
14824     }
14825   }
14826   if (lt_foo != "") { lt_freq[lt_foo]++; }
14827   if (lt_freq[lt_foo] == 1) { print lt_foo; }
14828 }'`
14829   sys_lib_search_path_spec=`echo $lt_search_path_spec`
14830 else
14831   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
14832 fi
14833 need_lib_prefix=unknown
14834 hardcode_into_libs=no
14835
14836 # when you set need_version to no, make sure it does not cause -set_version
14837 # flags to be left without arguments
14838 need_version=unknown
14839
14840 case $host_os in
14841 aix3*)
14842   version_type=linux
14843   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
14844   shlibpath_var=LIBPATH
14845
14846   # AIX 3 has no versioning support, so we append a major version to the name.
14847   soname_spec='${libname}${release}${shared_ext}$major'
14848   ;;
14849
14850 aix4* | aix5*)
14851   version_type=linux
14852   need_lib_prefix=no
14853   need_version=no
14854   hardcode_into_libs=yes
14855   if test "$host_cpu" = ia64; then
14856     # AIX 5 supports IA64
14857     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
14858     shlibpath_var=LD_LIBRARY_PATH
14859   else
14860     # With GCC up to 2.95.x, collect2 would create an import file
14861     # for dependence libraries.  The import file would start with
14862     # the line `#! .'.  This would cause the generated library to
14863     # depend on `.', always an invalid library.  This was fixed in
14864     # development snapshots of GCC prior to 3.0.
14865     case $host_os in
14866       aix4 | aix4.[01] | aix4.[01].*)
14867       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
14868            echo ' yes '
14869            echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
14870         :
14871       else
14872         can_build_shared=no
14873       fi
14874       ;;
14875     esac
14876     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
14877     # soname into executable. Probably we can add versioning support to
14878     # collect2, so additional links can be useful in future.
14879     if test "$aix_use_runtimelinking" = yes; then
14880       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
14881       # instead of lib<name>.a to let people know that these are not
14882       # typical AIX shared libraries.
14883       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14884     else
14885       # We preserve .a as extension for shared libraries through AIX4.2
14886       # and later when we are not doing run time linking.
14887       library_names_spec='${libname}${release}.a $libname.a'
14888       soname_spec='${libname}${release}${shared_ext}$major'
14889     fi
14890     shlibpath_var=LIBPATH
14891   fi
14892   ;;
14893
14894 amigaos*)
14895   library_names_spec='$libname.ixlibrary $libname.a'
14896   # Create ${libname}_ixlibrary.a entries in /sys/libs.
14897   finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
14898   ;;
14899
14900 beos*)
14901   library_names_spec='${libname}${shared_ext}'
14902   dynamic_linker="$host_os ld.so"
14903   shlibpath_var=LIBRARY_PATH
14904   ;;
14905
14906 bsdi[45]*)
14907   version_type=linux
14908   need_version=no
14909   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
14910   soname_spec='${libname}${release}${shared_ext}$major'
14911   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
14912   shlibpath_var=LD_LIBRARY_PATH
14913   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
14914   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
14915   # the default ld.so.conf also contains /usr/contrib/lib and
14916   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
14917   # libtool to hard-code these into programs
14918   ;;
14919
14920 cygwin* | mingw* | pw32*)
14921   version_type=windows
14922   shrext_cmds=".dll"
14923   need_version=no
14924   need_lib_prefix=no
14925
14926   case $GCC,$host_os in
14927   yes,cygwin* | yes,mingw* | yes,pw32*)
14928     library_names_spec='$libname.dll.a'
14929     # DLL is installed to $(libdir)/../bin by postinstall_cmds
14930     postinstall_cmds='base_file=`basename \${file}`~
14931       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
14932       dldir=$destdir/`dirname \$dlpath`~
14933       test -d \$dldir || mkdir -p \$dldir~
14934       $install_prog $dir/$dlname \$dldir/$dlname~
14935       chmod a+x \$dldir/$dlname'
14936     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
14937       dlpath=$dir/\$dldll~
14938        $rm \$dlpath'
14939     shlibpath_overrides_runpath=yes
14940
14941     case $host_os in
14942     cygwin*)
14943       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
14944       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
14945       sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
14946       ;;
14947     mingw*)
14948       # MinGW DLLs use traditional 'lib' prefix
14949       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
14950       sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
14951       if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then
14952         # It is most probably a Windows format PATH printed by
14953         # mingw gcc, but we are running on Cygwin. Gcc prints its search
14954         # path with ; separators, and with drive letters. We can handle the
14955         # drive letters (cygwin fileutils understands them), so leave them,
14956         # especially as we might pass files found there to a mingw objdump,
14957         # which wouldn't understand a cygwinified path. Ahh.
14958         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
14959       else
14960         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
14961       fi
14962       ;;
14963     pw32*)
14964       # pw32 DLLs use 'pw' prefix rather than 'lib'
14965       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
14966       ;;
14967     esac
14968     ;;
14969
14970   *)
14971     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
14972     ;;
14973   esac
14974   dynamic_linker='Win32 ld.exe'
14975   # FIXME: first we should search . and the directory the executable is in
14976   shlibpath_var=PATH
14977   ;;
14978
14979 darwin* | rhapsody*)
14980   dynamic_linker="$host_os dyld"
14981   version_type=darwin
14982   need_lib_prefix=no
14983   need_version=no
14984   library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
14985   soname_spec='${libname}${release}${major}$shared_ext'
14986   shlibpath_overrides_runpath=yes
14987   shlibpath_var=DYLD_LIBRARY_PATH
14988   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
14989
14990   sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
14991   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
14992   ;;
14993
14994 dgux*)
14995   version_type=linux
14996   need_lib_prefix=no
14997   need_version=no
14998   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
14999   soname_spec='${libname}${release}${shared_ext}$major'
15000   shlibpath_var=LD_LIBRARY_PATH
15001   ;;
15002
15003 freebsd1*)
15004   dynamic_linker=no
15005   ;;
15006
15007 freebsd* | dragonfly*)
15008   # DragonFly does not have aout.  When/if they implement a new
15009   # versioning mechanism, adjust this.
15010   if test -x /usr/bin/objformat; then
15011     objformat=`/usr/bin/objformat`
15012   else
15013     case $host_os in
15014     freebsd[123]*) objformat=aout ;;
15015     *) objformat=elf ;;
15016     esac
15017   fi
15018   version_type=freebsd-$objformat
15019   case $version_type in
15020     freebsd-elf*)
15021       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
15022       need_version=no
15023       need_lib_prefix=no
15024       ;;
15025     freebsd-*)
15026       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
15027       need_version=yes
15028       ;;
15029   esac
15030   shlibpath_var=LD_LIBRARY_PATH
15031   case $host_os in
15032   freebsd2*)
15033     shlibpath_overrides_runpath=yes
15034     ;;
15035   freebsd3.[01]* | freebsdelf3.[01]*)
15036     shlibpath_overrides_runpath=yes
15037     hardcode_into_libs=yes
15038     ;;
15039   freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
15040   freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
15041     shlibpath_overrides_runpath=no
15042     hardcode_into_libs=yes
15043     ;;
15044   *) # from 4.6 on, and DragonFly
15045     shlibpath_overrides_runpath=yes
15046     hardcode_into_libs=yes
15047     ;;
15048   esac
15049   ;;
15050
15051 gnu*)
15052   version_type=linux
15053   need_lib_prefix=no
15054   need_version=no
15055   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
15056   soname_spec='${libname}${release}${shared_ext}$major'
15057   shlibpath_var=LD_LIBRARY_PATH
15058   hardcode_into_libs=yes
15059   ;;
15060
15061 hpux9* | hpux10* | hpux11*)
15062   # Give a soname corresponding to the major version so that dld.sl refuses to
15063   # link against other versions.
15064   version_type=sunos
15065   need_lib_prefix=no
15066   need_version=no
15067   case $host_cpu in
15068   ia64*)
15069     shrext_cmds='.so'
15070     hardcode_into_libs=yes
15071     dynamic_linker="$host_os dld.so"
15072     shlibpath_var=LD_LIBRARY_PATH
15073     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
15074     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15075     soname_spec='${libname}${release}${shared_ext}$major'
15076     if test "X$HPUX_IA64_MODE" = X32; then
15077       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
15078     else
15079       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
15080     fi
15081     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
15082     ;;
15083    hppa*64*)
15084      shrext_cmds='.sl'
15085      hardcode_into_libs=yes
15086      dynamic_linker="$host_os dld.sl"
15087      shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
15088      shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
15089      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15090      soname_spec='${libname}${release}${shared_ext}$major'
15091      sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
15092      sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
15093      ;;
15094    *)
15095     shrext_cmds='.sl'
15096     dynamic_linker="$host_os dld.sl"
15097     shlibpath_var=SHLIB_PATH
15098     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
15099     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15100     soname_spec='${libname}${release}${shared_ext}$major'
15101     ;;
15102   esac
15103   # HP-UX runs *really* slowly unless shared libraries are mode 555.
15104   postinstall_cmds='chmod 555 $lib'
15105   ;;
15106
15107 interix[3-9]*)
15108   version_type=linux
15109   need_lib_prefix=no
15110   need_version=no
15111   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
15112   soname_spec='${libname}${release}${shared_ext}$major'
15113   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
15114   shlibpath_var=LD_LIBRARY_PATH
15115   shlibpath_overrides_runpath=no
15116   hardcode_into_libs=yes
15117   ;;
15118
15119 irix5* | irix6* | nonstopux*)
15120   case $host_os in
15121     nonstopux*) version_type=nonstopux ;;
15122     *)
15123         if test "$lt_cv_prog_gnu_ld" = yes; then
15124                 version_type=linux
15125         else
15126                 version_type=irix
15127         fi ;;
15128   esac
15129   need_lib_prefix=no
15130   need_version=no
15131   soname_spec='${libname}${release}${shared_ext}$major'
15132   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
15133   case $host_os in
15134   irix5* | nonstopux*)
15135     libsuff= shlibsuff=
15136     ;;
15137   *)
15138     case $LD in # libtool.m4 will add one of these switches to LD
15139     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
15140       libsuff= shlibsuff= libmagic=32-bit;;
15141     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
15142       libsuff=32 shlibsuff=N32 libmagic=N32;;
15143     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
15144       libsuff=64 shlibsuff=64 libmagic=64-bit;;
15145     *) libsuff= shlibsuff= libmagic=never-match;;
15146     esac
15147     ;;
15148   esac
15149   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
15150   shlibpath_overrides_runpath=no
15151   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
15152   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
15153   hardcode_into_libs=yes
15154   ;;
15155
15156 # No shared lib support for Linux oldld, aout, or coff.
15157 linux*oldld* | linux*aout* | linux*coff*)
15158   dynamic_linker=no
15159   ;;
15160
15161 # This must be Linux ELF.
15162 linux* | k*bsd*-gnu)
15163   version_type=linux
15164   need_lib_prefix=no
15165   need_version=no
15166   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15167   soname_spec='${libname}${release}${shared_ext}$major'
15168   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
15169   shlibpath_var=LD_LIBRARY_PATH
15170   shlibpath_overrides_runpath=no
15171   # This implies no fast_install, which is unacceptable.
15172   # Some rework will be needed to allow for fast_install
15173   # before this can be enabled.
15174   hardcode_into_libs=yes
15175
15176   # Append ld.so.conf contents to the search path
15177   if test -f /etc/ld.so.conf; then
15178     lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[      ]*hwcap[        ]/d;s/[:,       ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
15179     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
15180   fi
15181
15182   # We used to test for /lib/ld.so.1 and disable shared libraries on
15183   # powerpc, because MkLinux only supported shared libraries with the
15184   # GNU dynamic linker.  Since this was broken with cross compilers,
15185   # most powerpc-linux boxes support dynamic linking these days and
15186   # people can always --disable-shared, the test was removed, and we
15187   # assume the GNU/Linux dynamic linker is in use.
15188   dynamic_linker='GNU/Linux ld.so'
15189   ;;
15190
15191 netbsd*)
15192   version_type=sunos
15193   need_lib_prefix=no
15194   need_version=no
15195   if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
15196     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
15197     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
15198     dynamic_linker='NetBSD (a.out) ld.so'
15199   else
15200     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
15201     soname_spec='${libname}${release}${shared_ext}$major'
15202     dynamic_linker='NetBSD ld.elf_so'
15203   fi
15204   shlibpath_var=LD_LIBRARY_PATH
15205   shlibpath_overrides_runpath=yes
15206   hardcode_into_libs=yes
15207   ;;
15208
15209 newsos6)
15210   version_type=linux
15211   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15212   shlibpath_var=LD_LIBRARY_PATH
15213   shlibpath_overrides_runpath=yes
15214   ;;
15215
15216 nto-qnx*)
15217   version_type=linux
15218   need_lib_prefix=no
15219   need_version=no
15220   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15221   soname_spec='${libname}${release}${shared_ext}$major'
15222   shlibpath_var=LD_LIBRARY_PATH
15223   shlibpath_overrides_runpath=yes
15224   ;;
15225
15226 openbsd*)
15227   version_type=sunos
15228   sys_lib_dlsearch_path_spec="/usr/lib"
15229   need_lib_prefix=no
15230   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
15231   case $host_os in
15232     openbsd3.3 | openbsd3.3.*) need_version=yes ;;
15233     *)                         need_version=no  ;;
15234   esac
15235   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
15236   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
15237   shlibpath_var=LD_LIBRARY_PATH
15238   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
15239     case $host_os in
15240       openbsd2.[89] | openbsd2.[89].*)
15241         shlibpath_overrides_runpath=no
15242         ;;
15243       *)
15244         shlibpath_overrides_runpath=yes
15245         ;;
15246       esac
15247   else
15248     shlibpath_overrides_runpath=yes
15249   fi
15250   ;;
15251
15252 os2*)
15253   libname_spec='$name'
15254   shrext_cmds=".dll"
15255   need_lib_prefix=no
15256   library_names_spec='$libname${shared_ext} $libname.a'
15257   dynamic_linker='OS/2 ld.exe'
15258   shlibpath_var=LIBPATH
15259   ;;
15260
15261 osf3* | osf4* | osf5*)
15262   version_type=osf
15263   need_lib_prefix=no
15264   need_version=no
15265   soname_spec='${libname}${release}${shared_ext}$major'
15266   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15267   shlibpath_var=LD_LIBRARY_PATH
15268   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
15269   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
15270   ;;
15271
15272 rdos*)
15273   dynamic_linker=no
15274   ;;
15275
15276 solaris*)
15277   version_type=linux
15278   need_lib_prefix=no
15279   need_version=no
15280   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15281   soname_spec='${libname}${release}${shared_ext}$major'
15282   shlibpath_var=LD_LIBRARY_PATH
15283   shlibpath_overrides_runpath=yes
15284   hardcode_into_libs=yes
15285   # ldd complains unless libraries are executable
15286   postinstall_cmds='chmod +x $lib'
15287   ;;
15288
15289 sunos4*)
15290   version_type=sunos
15291   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
15292   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
15293   shlibpath_var=LD_LIBRARY_PATH
15294   shlibpath_overrides_runpath=yes
15295   if test "$with_gnu_ld" = yes; then
15296     need_lib_prefix=no
15297   fi
15298   need_version=yes
15299   ;;
15300
15301 sysv4 | sysv4.3*)
15302   version_type=linux
15303   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15304   soname_spec='${libname}${release}${shared_ext}$major'
15305   shlibpath_var=LD_LIBRARY_PATH
15306   case $host_vendor in
15307     sni)
15308       shlibpath_overrides_runpath=no
15309       need_lib_prefix=no
15310       export_dynamic_flag_spec='${wl}-Blargedynsym'
15311       runpath_var=LD_RUN_PATH
15312       ;;
15313     siemens)
15314       need_lib_prefix=no
15315       ;;
15316     motorola)
15317       need_lib_prefix=no
15318       need_version=no
15319       shlibpath_overrides_runpath=no
15320       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
15321       ;;
15322   esac
15323   ;;
15324
15325 sysv4*MP*)
15326   if test -d /usr/nec ;then
15327     version_type=linux
15328     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
15329     soname_spec='$libname${shared_ext}.$major'
15330     shlibpath_var=LD_LIBRARY_PATH
15331   fi
15332   ;;
15333
15334 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
15335   version_type=freebsd-elf
15336   need_lib_prefix=no
15337   need_version=no
15338   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
15339   soname_spec='${libname}${release}${shared_ext}$major'
15340   shlibpath_var=LD_LIBRARY_PATH
15341   hardcode_into_libs=yes
15342   if test "$with_gnu_ld" = yes; then
15343     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
15344     shlibpath_overrides_runpath=no
15345   else
15346     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
15347     shlibpath_overrides_runpath=yes
15348     case $host_os in
15349       sco3.2v5*)
15350         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
15351         ;;
15352     esac
15353   fi
15354   sys_lib_dlsearch_path_spec='/usr/lib'
15355   ;;
15356
15357 uts4*)
15358   version_type=linux
15359   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
15360   soname_spec='${libname}${release}${shared_ext}$major'
15361   shlibpath_var=LD_LIBRARY_PATH
15362   ;;
15363
15364 *)
15365   dynamic_linker=no
15366   ;;
15367 esac
15368 { echo "$as_me:$LINENO: result: $dynamic_linker" >&5
15369 echo "${ECHO_T}$dynamic_linker" >&6; }
15370 test "$dynamic_linker" = no && can_build_shared=no
15371
15372 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
15373 if test "$GCC" = yes; then
15374   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
15375 fi
15376
15377 { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
15378 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; }
15379 hardcode_action=
15380 if test -n "$hardcode_libdir_flag_spec" || \
15381    test -n "$runpath_var" || \
15382    test "X$hardcode_automatic" = "Xyes" ; then
15383
15384   # We can hardcode non-existant directories.
15385   if test "$hardcode_direct" != no &&
15386      # If the only mechanism to avoid hardcoding is shlibpath_var, we
15387      # have to relink, otherwise we might link with an installed library
15388      # when we should be linking with a yet-to-be-installed one
15389      ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no &&
15390      test "$hardcode_minus_L" != no; then
15391     # Linking always hardcodes the temporary library directory.
15392     hardcode_action=relink
15393   else
15394     # We can link without hardcoding, and we can hardcode nonexisting dirs.
15395     hardcode_action=immediate
15396   fi
15397 else
15398   # We cannot hardcode anything, or else we can only hardcode existing
15399   # directories.
15400   hardcode_action=unsupported
15401 fi
15402 { echo "$as_me:$LINENO: result: $hardcode_action" >&5
15403 echo "${ECHO_T}$hardcode_action" >&6; }
15404
15405 if test "$hardcode_action" = relink; then
15406   # Fast installation is not supported
15407   enable_fast_install=no
15408 elif test "$shlibpath_overrides_runpath" = yes ||
15409      test "$enable_shared" = no; then
15410   # Fast installation is not necessary
15411   enable_fast_install=needless
15412 fi
15413
15414 striplib=
15415 old_striplib=
15416 { echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
15417 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6; }
15418 if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then
15419   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
15420   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
15421   { echo "$as_me:$LINENO: result: yes" >&5
15422 echo "${ECHO_T}yes" >&6; }
15423 else
15424 # FIXME - insert some real tests, host_os isn't really good enough
15425   case $host_os in
15426    darwin*)
15427        if test -n "$STRIP" ; then
15428          striplib="$STRIP -x"
15429          old_striplib="$STRIP -S"
15430          { echo "$as_me:$LINENO: result: yes" >&5
15431 echo "${ECHO_T}yes" >&6; }
15432        else
15433   { echo "$as_me:$LINENO: result: no" >&5
15434 echo "${ECHO_T}no" >&6; }
15435 fi
15436        ;;
15437    *)
15438   { echo "$as_me:$LINENO: result: no" >&5
15439 echo "${ECHO_T}no" >&6; }
15440     ;;
15441   esac
15442 fi
15443
15444 if test "x$enable_dlopen" != xyes; then
15445   enable_dlopen=unknown
15446   enable_dlopen_self=unknown
15447   enable_dlopen_self_static=unknown
15448 else
15449   lt_cv_dlopen=no
15450   lt_cv_dlopen_libs=
15451
15452   case $host_os in
15453   beos*)
15454     lt_cv_dlopen="load_add_on"
15455     lt_cv_dlopen_libs=
15456     lt_cv_dlopen_self=yes
15457     ;;
15458
15459   mingw* | pw32*)
15460     lt_cv_dlopen="LoadLibrary"
15461     lt_cv_dlopen_libs=
15462    ;;
15463
15464   cygwin*)
15465     lt_cv_dlopen="dlopen"
15466     lt_cv_dlopen_libs=
15467    ;;
15468
15469   darwin*)
15470   # if libdl is installed we need to link against it
15471     { echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
15472 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6; }
15473 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
15474   echo $ECHO_N "(cached) $ECHO_C" >&6
15475 else
15476   ac_check_lib_save_LIBS=$LIBS
15477 LIBS="-ldl  $LIBS"
15478 cat >conftest.$ac_ext <<_ACEOF
15479 /* confdefs.h.  */
15480 _ACEOF
15481 cat confdefs.h >>conftest.$ac_ext
15482 cat >>conftest.$ac_ext <<_ACEOF
15483 /* end confdefs.h.  */
15484
15485 /* Override any GCC internal prototype to avoid an error.
15486    Use char because int might match the return type of a GCC
15487    builtin and then its argument prototype would still apply.  */
15488 #ifdef __cplusplus
15489 extern "C"
15490 #endif
15491 char dlopen ();
15492 int
15493 main ()
15494 {
15495 return dlopen ();
15496   ;
15497   return 0;
15498 }
15499 _ACEOF
15500 rm -f conftest.$ac_objext conftest$ac_exeext
15501 if { (ac_try="$ac_link"
15502 case "(($ac_try" in
15503   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15504   *) ac_try_echo=$ac_try;;
15505 esac
15506 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15507   (eval "$ac_link") 2>conftest.er1
15508   ac_status=$?
15509   grep -v '^ *+' conftest.er1 >conftest.err
15510   rm -f conftest.er1
15511   cat conftest.err >&5
15512   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15513   (exit $ac_status); } && {
15514          test -z "$ac_c_werror_flag" ||
15515          test ! -s conftest.err
15516        } && test -s conftest$ac_exeext &&
15517        $as_test_x conftest$ac_exeext; then
15518   ac_cv_lib_dl_dlopen=yes
15519 else
15520   echo "$as_me: failed program was:" >&5
15521 sed 's/^/| /' conftest.$ac_ext >&5
15522
15523         ac_cv_lib_dl_dlopen=no
15524 fi
15525
15526 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15527       conftest$ac_exeext conftest.$ac_ext
15528 LIBS=$ac_check_lib_save_LIBS
15529 fi
15530 { echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
15531 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6; }
15532 if test $ac_cv_lib_dl_dlopen = yes; then
15533   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
15534 else
15535
15536     lt_cv_dlopen="dyld"
15537     lt_cv_dlopen_libs=
15538     lt_cv_dlopen_self=yes
15539
15540 fi
15541
15542    ;;
15543
15544   *)
15545     { echo "$as_me:$LINENO: checking for shl_load" >&5
15546 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6; }
15547 if test "${ac_cv_func_shl_load+set}" = set; then
15548   echo $ECHO_N "(cached) $ECHO_C" >&6
15549 else
15550   cat >conftest.$ac_ext <<_ACEOF
15551 /* confdefs.h.  */
15552 _ACEOF
15553 cat confdefs.h >>conftest.$ac_ext
15554 cat >>conftest.$ac_ext <<_ACEOF
15555 /* end confdefs.h.  */
15556 /* Define shl_load to an innocuous variant, in case <limits.h> declares shl_load.
15557    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15558 #define shl_load innocuous_shl_load
15559
15560 /* System header to define __stub macros and hopefully few prototypes,
15561     which can conflict with char shl_load (); below.
15562     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15563     <limits.h> exists even on freestanding compilers.  */
15564
15565 #ifdef __STDC__
15566 # include <limits.h>
15567 #else
15568 # include <assert.h>
15569 #endif
15570
15571 #undef shl_load
15572
15573 /* Override any GCC internal prototype to avoid an error.
15574    Use char because int might match the return type of a GCC
15575    builtin and then its argument prototype would still apply.  */
15576 #ifdef __cplusplus
15577 extern "C"
15578 #endif
15579 char shl_load ();
15580 /* The GNU C library defines this for functions which it implements
15581     to always fail with ENOSYS.  Some functions are actually named
15582     something starting with __ and the normal name is an alias.  */
15583 #if defined __stub_shl_load || defined __stub___shl_load
15584 choke me
15585 #endif
15586
15587 int
15588 main ()
15589 {
15590 return shl_load ();
15591   ;
15592   return 0;
15593 }
15594 _ACEOF
15595 rm -f conftest.$ac_objext conftest$ac_exeext
15596 if { (ac_try="$ac_link"
15597 case "(($ac_try" in
15598   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15599   *) ac_try_echo=$ac_try;;
15600 esac
15601 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15602   (eval "$ac_link") 2>conftest.er1
15603   ac_status=$?
15604   grep -v '^ *+' conftest.er1 >conftest.err
15605   rm -f conftest.er1
15606   cat conftest.err >&5
15607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15608   (exit $ac_status); } && {
15609          test -z "$ac_c_werror_flag" ||
15610          test ! -s conftest.err
15611        } && test -s conftest$ac_exeext &&
15612        $as_test_x conftest$ac_exeext; then
15613   ac_cv_func_shl_load=yes
15614 else
15615   echo "$as_me: failed program was:" >&5
15616 sed 's/^/| /' conftest.$ac_ext >&5
15617
15618         ac_cv_func_shl_load=no
15619 fi
15620
15621 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15622       conftest$ac_exeext conftest.$ac_ext
15623 fi
15624 { echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
15625 echo "${ECHO_T}$ac_cv_func_shl_load" >&6; }
15626 if test $ac_cv_func_shl_load = yes; then
15627   lt_cv_dlopen="shl_load"
15628 else
15629   { echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
15630 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6; }
15631 if test "${ac_cv_lib_dld_shl_load+set}" = set; then
15632   echo $ECHO_N "(cached) $ECHO_C" >&6
15633 else
15634   ac_check_lib_save_LIBS=$LIBS
15635 LIBS="-ldld  $LIBS"
15636 cat >conftest.$ac_ext <<_ACEOF
15637 /* confdefs.h.  */
15638 _ACEOF
15639 cat confdefs.h >>conftest.$ac_ext
15640 cat >>conftest.$ac_ext <<_ACEOF
15641 /* end confdefs.h.  */
15642
15643 /* Override any GCC internal prototype to avoid an error.
15644    Use char because int might match the return type of a GCC
15645    builtin and then its argument prototype would still apply.  */
15646 #ifdef __cplusplus
15647 extern "C"
15648 #endif
15649 char shl_load ();
15650 int
15651 main ()
15652 {
15653 return shl_load ();
15654   ;
15655   return 0;
15656 }
15657 _ACEOF
15658 rm -f conftest.$ac_objext conftest$ac_exeext
15659 if { (ac_try="$ac_link"
15660 case "(($ac_try" in
15661   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15662   *) ac_try_echo=$ac_try;;
15663 esac
15664 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15665   (eval "$ac_link") 2>conftest.er1
15666   ac_status=$?
15667   grep -v '^ *+' conftest.er1 >conftest.err
15668   rm -f conftest.er1
15669   cat conftest.err >&5
15670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15671   (exit $ac_status); } && {
15672          test -z "$ac_c_werror_flag" ||
15673          test ! -s conftest.err
15674        } && test -s conftest$ac_exeext &&
15675        $as_test_x conftest$ac_exeext; then
15676   ac_cv_lib_dld_shl_load=yes
15677 else
15678   echo "$as_me: failed program was:" >&5
15679 sed 's/^/| /' conftest.$ac_ext >&5
15680
15681         ac_cv_lib_dld_shl_load=no
15682 fi
15683
15684 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15685       conftest$ac_exeext conftest.$ac_ext
15686 LIBS=$ac_check_lib_save_LIBS
15687 fi
15688 { echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
15689 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6; }
15690 if test $ac_cv_lib_dld_shl_load = yes; then
15691   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"
15692 else
15693   { echo "$as_me:$LINENO: checking for dlopen" >&5
15694 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6; }
15695 if test "${ac_cv_func_dlopen+set}" = set; then
15696   echo $ECHO_N "(cached) $ECHO_C" >&6
15697 else
15698   cat >conftest.$ac_ext <<_ACEOF
15699 /* confdefs.h.  */
15700 _ACEOF
15701 cat confdefs.h >>conftest.$ac_ext
15702 cat >>conftest.$ac_ext <<_ACEOF
15703 /* end confdefs.h.  */
15704 /* Define dlopen to an innocuous variant, in case <limits.h> declares dlopen.
15705    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15706 #define dlopen innocuous_dlopen
15707
15708 /* System header to define __stub macros and hopefully few prototypes,
15709     which can conflict with char dlopen (); below.
15710     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15711     <limits.h> exists even on freestanding compilers.  */
15712
15713 #ifdef __STDC__
15714 # include <limits.h>
15715 #else
15716 # include <assert.h>
15717 #endif
15718
15719 #undef dlopen
15720
15721 /* Override any GCC internal prototype to avoid an error.
15722    Use char because int might match the return type of a GCC
15723    builtin and then its argument prototype would still apply.  */
15724 #ifdef __cplusplus
15725 extern "C"
15726 #endif
15727 char dlopen ();
15728 /* The GNU C library defines this for functions which it implements
15729     to always fail with ENOSYS.  Some functions are actually named
15730     something starting with __ and the normal name is an alias.  */
15731 #if defined __stub_dlopen || defined __stub___dlopen
15732 choke me
15733 #endif
15734
15735 int
15736 main ()
15737 {
15738 return dlopen ();
15739   ;
15740   return 0;
15741 }
15742 _ACEOF
15743 rm -f conftest.$ac_objext conftest$ac_exeext
15744 if { (ac_try="$ac_link"
15745 case "(($ac_try" in
15746   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15747   *) ac_try_echo=$ac_try;;
15748 esac
15749 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15750   (eval "$ac_link") 2>conftest.er1
15751   ac_status=$?
15752   grep -v '^ *+' conftest.er1 >conftest.err
15753   rm -f conftest.er1
15754   cat conftest.err >&5
15755   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15756   (exit $ac_status); } && {
15757          test -z "$ac_c_werror_flag" ||
15758          test ! -s conftest.err
15759        } && test -s conftest$ac_exeext &&
15760        $as_test_x conftest$ac_exeext; then
15761   ac_cv_func_dlopen=yes
15762 else
15763   echo "$as_me: failed program was:" >&5
15764 sed 's/^/| /' conftest.$ac_ext >&5
15765
15766         ac_cv_func_dlopen=no
15767 fi
15768
15769 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15770       conftest$ac_exeext conftest.$ac_ext
15771 fi
15772 { echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
15773 echo "${ECHO_T}$ac_cv_func_dlopen" >&6; }
15774 if test $ac_cv_func_dlopen = yes; then
15775   lt_cv_dlopen="dlopen"
15776 else
15777   { echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
15778 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6; }
15779 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
15780   echo $ECHO_N "(cached) $ECHO_C" >&6
15781 else
15782   ac_check_lib_save_LIBS=$LIBS
15783 LIBS="-ldl  $LIBS"
15784 cat >conftest.$ac_ext <<_ACEOF
15785 /* confdefs.h.  */
15786 _ACEOF
15787 cat confdefs.h >>conftest.$ac_ext
15788 cat >>conftest.$ac_ext <<_ACEOF
15789 /* end confdefs.h.  */
15790
15791 /* Override any GCC internal prototype to avoid an error.
15792    Use char because int might match the return type of a GCC
15793    builtin and then its argument prototype would still apply.  */
15794 #ifdef __cplusplus
15795 extern "C"
15796 #endif
15797 char dlopen ();
15798 int
15799 main ()
15800 {
15801 return dlopen ();
15802   ;
15803   return 0;
15804 }
15805 _ACEOF
15806 rm -f conftest.$ac_objext conftest$ac_exeext
15807 if { (ac_try="$ac_link"
15808 case "(($ac_try" in
15809   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15810   *) ac_try_echo=$ac_try;;
15811 esac
15812 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15813   (eval "$ac_link") 2>conftest.er1
15814   ac_status=$?
15815   grep -v '^ *+' conftest.er1 >conftest.err
15816   rm -f conftest.er1
15817   cat conftest.err >&5
15818   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15819   (exit $ac_status); } && {
15820          test -z "$ac_c_werror_flag" ||
15821          test ! -s conftest.err
15822        } && test -s conftest$ac_exeext &&
15823        $as_test_x conftest$ac_exeext; then
15824   ac_cv_lib_dl_dlopen=yes
15825 else
15826   echo "$as_me: failed program was:" >&5
15827 sed 's/^/| /' conftest.$ac_ext >&5
15828
15829         ac_cv_lib_dl_dlopen=no
15830 fi
15831
15832 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15833       conftest$ac_exeext conftest.$ac_ext
15834 LIBS=$ac_check_lib_save_LIBS
15835 fi
15836 { echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
15837 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6; }
15838 if test $ac_cv_lib_dl_dlopen = yes; then
15839   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
15840 else
15841   { echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
15842 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6; }
15843 if test "${ac_cv_lib_svld_dlopen+set}" = set; then
15844   echo $ECHO_N "(cached) $ECHO_C" >&6
15845 else
15846   ac_check_lib_save_LIBS=$LIBS
15847 LIBS="-lsvld  $LIBS"
15848 cat >conftest.$ac_ext <<_ACEOF
15849 /* confdefs.h.  */
15850 _ACEOF
15851 cat confdefs.h >>conftest.$ac_ext
15852 cat >>conftest.$ac_ext <<_ACEOF
15853 /* end confdefs.h.  */
15854
15855 /* Override any GCC internal prototype to avoid an error.
15856    Use char because int might match the return type of a GCC
15857    builtin and then its argument prototype would still apply.  */
15858 #ifdef __cplusplus
15859 extern "C"
15860 #endif
15861 char dlopen ();
15862 int
15863 main ()
15864 {
15865 return dlopen ();
15866   ;
15867   return 0;
15868 }
15869 _ACEOF
15870 rm -f conftest.$ac_objext conftest$ac_exeext
15871 if { (ac_try="$ac_link"
15872 case "(($ac_try" in
15873   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15874   *) ac_try_echo=$ac_try;;
15875 esac
15876 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15877   (eval "$ac_link") 2>conftest.er1
15878   ac_status=$?
15879   grep -v '^ *+' conftest.er1 >conftest.err
15880   rm -f conftest.er1
15881   cat conftest.err >&5
15882   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15883   (exit $ac_status); } && {
15884          test -z "$ac_c_werror_flag" ||
15885          test ! -s conftest.err
15886        } && test -s conftest$ac_exeext &&
15887        $as_test_x conftest$ac_exeext; then
15888   ac_cv_lib_svld_dlopen=yes
15889 else
15890   echo "$as_me: failed program was:" >&5
15891 sed 's/^/| /' conftest.$ac_ext >&5
15892
15893         ac_cv_lib_svld_dlopen=no
15894 fi
15895
15896 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15897       conftest$ac_exeext conftest.$ac_ext
15898 LIBS=$ac_check_lib_save_LIBS
15899 fi
15900 { echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
15901 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6; }
15902 if test $ac_cv_lib_svld_dlopen = yes; then
15903   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
15904 else
15905   { echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
15906 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6; }
15907 if test "${ac_cv_lib_dld_dld_link+set}" = set; then
15908   echo $ECHO_N "(cached) $ECHO_C" >&6
15909 else
15910   ac_check_lib_save_LIBS=$LIBS
15911 LIBS="-ldld  $LIBS"
15912 cat >conftest.$ac_ext <<_ACEOF
15913 /* confdefs.h.  */
15914 _ACEOF
15915 cat confdefs.h >>conftest.$ac_ext
15916 cat >>conftest.$ac_ext <<_ACEOF
15917 /* end confdefs.h.  */
15918
15919 /* Override any GCC internal prototype to avoid an error.
15920    Use char because int might match the return type of a GCC
15921    builtin and then its argument prototype would still apply.  */
15922 #ifdef __cplusplus
15923 extern "C"
15924 #endif
15925 char dld_link ();
15926 int
15927 main ()
15928 {
15929 return dld_link ();
15930   ;
15931   return 0;
15932 }
15933 _ACEOF
15934 rm -f conftest.$ac_objext conftest$ac_exeext
15935 if { (ac_try="$ac_link"
15936 case "(($ac_try" in
15937   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15938   *) ac_try_echo=$ac_try;;
15939 esac
15940 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15941   (eval "$ac_link") 2>conftest.er1
15942   ac_status=$?
15943   grep -v '^ *+' conftest.er1 >conftest.err
15944   rm -f conftest.er1
15945   cat conftest.err >&5
15946   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15947   (exit $ac_status); } && {
15948          test -z "$ac_c_werror_flag" ||
15949          test ! -s conftest.err
15950        } && test -s conftest$ac_exeext &&
15951        $as_test_x conftest$ac_exeext; then
15952   ac_cv_lib_dld_dld_link=yes
15953 else
15954   echo "$as_me: failed program was:" >&5
15955 sed 's/^/| /' conftest.$ac_ext >&5
15956
15957         ac_cv_lib_dld_dld_link=no
15958 fi
15959
15960 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15961       conftest$ac_exeext conftest.$ac_ext
15962 LIBS=$ac_check_lib_save_LIBS
15963 fi
15964 { echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
15965 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6; }
15966 if test $ac_cv_lib_dld_dld_link = yes; then
15967   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"
15968 fi
15969
15970
15971 fi
15972
15973
15974 fi
15975
15976
15977 fi
15978
15979
15980 fi
15981
15982
15983 fi
15984
15985     ;;
15986   esac
15987
15988   if test "x$lt_cv_dlopen" != xno; then
15989     enable_dlopen=yes
15990   else
15991     enable_dlopen=no
15992   fi
15993
15994   case $lt_cv_dlopen in
15995   dlopen)
15996     save_CPPFLAGS="$CPPFLAGS"
15997     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
15998
15999     save_LDFLAGS="$LDFLAGS"
16000     wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
16001
16002     save_LIBS="$LIBS"
16003     LIBS="$lt_cv_dlopen_libs $LIBS"
16004
16005     { echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
16006 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6; }
16007 if test "${lt_cv_dlopen_self+set}" = set; then
16008   echo $ECHO_N "(cached) $ECHO_C" >&6
16009 else
16010           if test "$cross_compiling" = yes; then :
16011   lt_cv_dlopen_self=cross
16012 else
16013   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
16014   lt_status=$lt_dlunknown
16015   cat > conftest.$ac_ext <<EOF
16016 #line 16016 "configure"
16017 #include "confdefs.h"
16018
16019 #if HAVE_DLFCN_H
16020 #include <dlfcn.h>
16021 #endif
16022
16023 #include <stdio.h>
16024
16025 #ifdef RTLD_GLOBAL
16026 #  define LT_DLGLOBAL           RTLD_GLOBAL
16027 #else
16028 #  ifdef DL_GLOBAL
16029 #    define LT_DLGLOBAL         DL_GLOBAL
16030 #  else
16031 #    define LT_DLGLOBAL         0
16032 #  endif
16033 #endif
16034
16035 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
16036    find out it does not work in some platform. */
16037 #ifndef LT_DLLAZY_OR_NOW
16038 #  ifdef RTLD_LAZY
16039 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
16040 #  else
16041 #    ifdef DL_LAZY
16042 #      define LT_DLLAZY_OR_NOW          DL_LAZY
16043 #    else
16044 #      ifdef RTLD_NOW
16045 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
16046 #      else
16047 #        ifdef DL_NOW
16048 #          define LT_DLLAZY_OR_NOW      DL_NOW
16049 #        else
16050 #          define LT_DLLAZY_OR_NOW      0
16051 #        endif
16052 #      endif
16053 #    endif
16054 #  endif
16055 #endif
16056
16057 #ifdef __cplusplus
16058 extern "C" void exit (int);
16059 #endif
16060
16061 void fnord() { int i=42;}
16062 int main ()
16063 {
16064   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
16065   int status = $lt_dlunknown;
16066
16067   if (self)
16068     {
16069       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
16070       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
16071       /* dlclose (self); */
16072     }
16073   else
16074     puts (dlerror ());
16075
16076     exit (status);
16077 }
16078 EOF
16079   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16080   (eval $ac_link) 2>&5
16081   ac_status=$?
16082   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16083   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
16084     (./conftest; exit; ) >&5 2>/dev/null
16085     lt_status=$?
16086     case x$lt_status in
16087       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
16088       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
16089       x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
16090     esac
16091   else :
16092     # compilation failed
16093     lt_cv_dlopen_self=no
16094   fi
16095 fi
16096 rm -fr conftest*
16097
16098
16099 fi
16100 { echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
16101 echo "${ECHO_T}$lt_cv_dlopen_self" >&6; }
16102
16103     if test "x$lt_cv_dlopen_self" = xyes; then
16104       wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
16105       { echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
16106 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6; }
16107 if test "${lt_cv_dlopen_self_static+set}" = set; then
16108   echo $ECHO_N "(cached) $ECHO_C" >&6
16109 else
16110           if test "$cross_compiling" = yes; then :
16111   lt_cv_dlopen_self_static=cross
16112 else
16113   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
16114   lt_status=$lt_dlunknown
16115   cat > conftest.$ac_ext <<EOF
16116 #line 16116 "configure"
16117 #include "confdefs.h"
16118
16119 #if HAVE_DLFCN_H
16120 #include <dlfcn.h>
16121 #endif
16122
16123 #include <stdio.h>
16124
16125 #ifdef RTLD_GLOBAL
16126 #  define LT_DLGLOBAL           RTLD_GLOBAL
16127 #else
16128 #  ifdef DL_GLOBAL
16129 #    define LT_DLGLOBAL         DL_GLOBAL
16130 #  else
16131 #    define LT_DLGLOBAL         0
16132 #  endif
16133 #endif
16134
16135 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
16136    find out it does not work in some platform. */
16137 #ifndef LT_DLLAZY_OR_NOW
16138 #  ifdef RTLD_LAZY
16139 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
16140 #  else
16141 #    ifdef DL_LAZY
16142 #      define LT_DLLAZY_OR_NOW          DL_LAZY
16143 #    else
16144 #      ifdef RTLD_NOW
16145 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
16146 #      else
16147 #        ifdef DL_NOW
16148 #          define LT_DLLAZY_OR_NOW      DL_NOW
16149 #        else
16150 #          define LT_DLLAZY_OR_NOW      0
16151 #        endif
16152 #      endif
16153 #    endif
16154 #  endif
16155 #endif
16156
16157 #ifdef __cplusplus
16158 extern "C" void exit (int);
16159 #endif
16160
16161 void fnord() { int i=42;}
16162 int main ()
16163 {
16164   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
16165   int status = $lt_dlunknown;
16166
16167   if (self)
16168     {
16169       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
16170       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
16171       /* dlclose (self); */
16172     }
16173   else
16174     puts (dlerror ());
16175
16176     exit (status);
16177 }
16178 EOF
16179   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16180   (eval $ac_link) 2>&5
16181   ac_status=$?
16182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16183   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
16184     (./conftest; exit; ) >&5 2>/dev/null
16185     lt_status=$?
16186     case x$lt_status in
16187       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
16188       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
16189       x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
16190     esac
16191   else :
16192     # compilation failed
16193     lt_cv_dlopen_self_static=no
16194   fi
16195 fi
16196 rm -fr conftest*
16197
16198
16199 fi
16200 { echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
16201 echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6; }
16202     fi
16203
16204     CPPFLAGS="$save_CPPFLAGS"
16205     LDFLAGS="$save_LDFLAGS"
16206     LIBS="$save_LIBS"
16207     ;;
16208   esac
16209
16210   case $lt_cv_dlopen_self in
16211   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
16212   *) enable_dlopen_self=unknown ;;
16213   esac
16214
16215   case $lt_cv_dlopen_self_static in
16216   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
16217   *) enable_dlopen_self_static=unknown ;;
16218   esac
16219 fi
16220
16221
16222 # Report which library types will actually be built
16223 { echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
16224 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6; }
16225 { echo "$as_me:$LINENO: result: $can_build_shared" >&5
16226 echo "${ECHO_T}$can_build_shared" >&6; }
16227
16228 { echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
16229 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6; }
16230 test "$can_build_shared" = "no" && enable_shared=no
16231
16232 # On AIX, shared libraries and static libraries use the same namespace, and
16233 # are all built from PIC.
16234 case $host_os in
16235 aix3*)
16236   test "$enable_shared" = yes && enable_static=no
16237   if test -n "$RANLIB"; then
16238     archive_cmds="$archive_cmds~\$RANLIB \$lib"
16239     postinstall_cmds='$RANLIB $lib'
16240   fi
16241   ;;
16242
16243 aix4* | aix5*)
16244   if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
16245     test "$enable_shared" = yes && enable_static=no
16246   fi
16247     ;;
16248 esac
16249 { echo "$as_me:$LINENO: result: $enable_shared" >&5
16250 echo "${ECHO_T}$enable_shared" >&6; }
16251
16252 { echo "$as_me:$LINENO: checking whether to build static libraries" >&5
16253 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6; }
16254 # Make sure either enable_shared or enable_static is yes.
16255 test "$enable_shared" = yes || enable_static=yes
16256 { echo "$as_me:$LINENO: result: $enable_static" >&5
16257 echo "${ECHO_T}$enable_static" >&6; }
16258
16259 # The else clause should only fire when bootstrapping the
16260 # libtool distribution, otherwise you forgot to ship ltmain.sh
16261 # with your package, and you will get complaints that there are
16262 # no rules to generate ltmain.sh.
16263 if test -f "$ltmain"; then
16264   # See if we are running on zsh, and set the options which allow our commands through
16265   # without removal of \ escapes.
16266   if test -n "${ZSH_VERSION+set}" ; then
16267     setopt NO_GLOB_SUBST
16268   fi
16269   # Now quote all the things that may contain metacharacters while being
16270   # careful not to overquote the AC_SUBSTed values.  We take copies of the
16271   # variables and quote the copies for generation of the libtool script.
16272   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
16273     SED SHELL STRIP \
16274     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
16275     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
16276     deplibs_check_method reload_flag reload_cmds need_locks \
16277     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
16278     lt_cv_sys_global_symbol_to_c_name_address \
16279     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
16280     old_postinstall_cmds old_postuninstall_cmds \
16281     compiler \
16282     CC \
16283     LD \
16284     lt_prog_compiler_wl \
16285     lt_prog_compiler_pic \
16286     lt_prog_compiler_static \
16287     lt_prog_compiler_no_builtin_flag \
16288     export_dynamic_flag_spec \
16289     thread_safe_flag_spec \
16290     whole_archive_flag_spec \
16291     enable_shared_with_static_runtimes \
16292     old_archive_cmds \
16293     old_archive_from_new_cmds \
16294     predep_objects \
16295     postdep_objects \
16296     predeps \
16297     postdeps \
16298     compiler_lib_search_path \
16299     archive_cmds \
16300     archive_expsym_cmds \
16301     postinstall_cmds \
16302     postuninstall_cmds \
16303     old_archive_from_expsyms_cmds \
16304     allow_undefined_flag \
16305     no_undefined_flag \
16306     export_symbols_cmds \
16307     hardcode_libdir_flag_spec \
16308     hardcode_libdir_flag_spec_ld \
16309     hardcode_libdir_separator \
16310     hardcode_automatic \
16311     module_cmds \
16312     module_expsym_cmds \
16313     lt_cv_prog_compiler_c_o \
16314     fix_srcfile_path \
16315     exclude_expsyms \
16316     include_expsyms; do
16317
16318     case $var in
16319     old_archive_cmds | \
16320     old_archive_from_new_cmds | \
16321     archive_cmds | \
16322     archive_expsym_cmds | \
16323     module_cmds | \
16324     module_expsym_cmds | \
16325     old_archive_from_expsyms_cmds | \
16326     export_symbols_cmds | \
16327     extract_expsyms_cmds | reload_cmds | finish_cmds | \
16328     postinstall_cmds | postuninstall_cmds | \
16329     old_postinstall_cmds | old_postuninstall_cmds | \
16330     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
16331       # Double-quote double-evaled strings.
16332       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
16333       ;;
16334     *)
16335       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
16336       ;;
16337     esac
16338   done
16339
16340   case $lt_echo in
16341   *'\$0 --fallback-echo"')
16342     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
16343     ;;
16344   esac
16345
16346 cfgfile="${ofile}T"
16347   trap "$rm \"$cfgfile\"; exit 1" 1 2 15
16348   $rm -f "$cfgfile"
16349   { echo "$as_me:$LINENO: creating $ofile" >&5
16350 echo "$as_me: creating $ofile" >&6;}
16351
16352   cat <<__EOF__ >> "$cfgfile"
16353 #! $SHELL
16354
16355 # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
16356 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
16357 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
16358 #
16359 # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
16360 # Free Software Foundation, Inc.
16361 #
16362 # This file is part of GNU Libtool:
16363 # Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
16364 #
16365 # This program is free software; you can redistribute it and/or modify
16366 # it under the terms of the GNU General Public License as published by
16367 # the Free Software Foundation; either version 2 of the License, or
16368 # (at your option) any later version.
16369 #
16370 # This program is distributed in the hope that it will be useful, but
16371 # WITHOUT ANY WARRANTY; without even the implied warranty of
16372 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16373 # General Public License for more details.
16374 #
16375 # You should have received a copy of the GNU General Public License
16376 # along with this program; if not, write to the Free Software
16377 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
16378 #
16379 # As a special exception to the GNU General Public License, if you
16380 # distribute this file as part of a program that contains a
16381 # configuration script generated by Autoconf, you may include it under
16382 # the same distribution terms that you use for the rest of that program.
16383
16384 # A sed program that does not truncate output.
16385 SED=$lt_SED
16386
16387 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
16388 Xsed="$SED -e 1s/^X//"
16389
16390 # The HP-UX ksh and POSIX shell print the target directory to stdout
16391 # if CDPATH is set.
16392 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
16393
16394 # The names of the tagged configurations supported by this script.
16395 available_tags=
16396
16397 # ### BEGIN LIBTOOL CONFIG
16398
16399 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
16400
16401 # Shell to use when invoking shell scripts.
16402 SHELL=$lt_SHELL
16403
16404 # Whether or not to build shared libraries.
16405 build_libtool_libs=$enable_shared
16406
16407 # Whether or not to build static libraries.
16408 build_old_libs=$enable_static
16409
16410 # Whether or not to add -lc for building shared libraries.
16411 build_libtool_need_lc=$archive_cmds_need_lc
16412
16413 # Whether or not to disallow shared libs when runtime libs are static
16414 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
16415
16416 # Whether or not to optimize for fast installation.
16417 fast_install=$enable_fast_install
16418
16419 # The host system.
16420 host_alias=$host_alias
16421 host=$host
16422 host_os=$host_os
16423
16424 # The build system.
16425 build_alias=$build_alias
16426 build=$build
16427 build_os=$build_os
16428
16429 # An echo program that does not interpret backslashes.
16430 echo=$lt_echo
16431
16432 # The archiver.
16433 AR=$lt_AR
16434 AR_FLAGS=$lt_AR_FLAGS
16435
16436 # A C compiler.
16437 LTCC=$lt_LTCC
16438
16439 # LTCC compiler flags.
16440 LTCFLAGS=$lt_LTCFLAGS
16441
16442 # A language-specific compiler.
16443 CC=$lt_compiler
16444
16445 # Is the compiler the GNU C compiler?
16446 with_gcc=$GCC
16447
16448 # An ERE matcher.
16449 EGREP=$lt_EGREP
16450
16451 # The linker used to build libraries.
16452 LD=$lt_LD
16453
16454 # Whether we need hard or soft links.
16455 LN_S=$lt_LN_S
16456
16457 # A BSD-compatible nm program.
16458 NM=$lt_NM
16459
16460 # A symbol stripping program
16461 STRIP=$lt_STRIP
16462
16463 # Used to examine libraries when file_magic_cmd begins "file"
16464 MAGIC_CMD=$MAGIC_CMD
16465
16466 # Used on cygwin: DLL creation program.
16467 DLLTOOL="$DLLTOOL"
16468
16469 # Used on cygwin: object dumper.
16470 OBJDUMP="$OBJDUMP"
16471
16472 # Used on cygwin: assembler.
16473 AS="$AS"
16474
16475 # The name of the directory that contains temporary libtool files.
16476 objdir=$objdir
16477
16478 # How to create reloadable object files.
16479 reload_flag=$lt_reload_flag
16480 reload_cmds=$lt_reload_cmds
16481
16482 # How to pass a linker flag through the compiler.
16483 wl=$lt_lt_prog_compiler_wl
16484
16485 # Object file suffix (normally "o").
16486 objext="$ac_objext"
16487
16488 # Old archive suffix (normally "a").
16489 libext="$libext"
16490
16491 # Shared library suffix (normally ".so").
16492 shrext_cmds='$shrext_cmds'
16493
16494 # Executable file suffix (normally "").
16495 exeext="$exeext"
16496
16497 # Additional compiler flags for building library objects.
16498 pic_flag=$lt_lt_prog_compiler_pic
16499 pic_mode=$pic_mode
16500
16501 # What is the maximum length of a command?
16502 max_cmd_len=$lt_cv_sys_max_cmd_len
16503
16504 # Does compiler simultaneously support -c and -o options?
16505 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
16506
16507 # Must we lock files when doing compilation?
16508 need_locks=$lt_need_locks
16509
16510 # Do we need the lib prefix for modules?
16511 need_lib_prefix=$need_lib_prefix
16512
16513 # Do we need a version for libraries?
16514 need_version=$need_version
16515
16516 # Whether dlopen is supported.
16517 dlopen_support=$enable_dlopen
16518
16519 # Whether dlopen of programs is supported.
16520 dlopen_self=$enable_dlopen_self
16521
16522 # Whether dlopen of statically linked programs is supported.
16523 dlopen_self_static=$enable_dlopen_self_static
16524
16525 # Compiler flag to prevent dynamic linking.
16526 link_static_flag=$lt_lt_prog_compiler_static
16527
16528 # Compiler flag to turn off builtin functions.
16529 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
16530
16531 # Compiler flag to allow reflexive dlopens.
16532 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
16533
16534 # Compiler flag to generate shared objects directly from archives.
16535 whole_archive_flag_spec=$lt_whole_archive_flag_spec
16536
16537 # Compiler flag to generate thread-safe objects.
16538 thread_safe_flag_spec=$lt_thread_safe_flag_spec
16539
16540 # Library versioning type.
16541 version_type=$version_type
16542
16543 # Format of library name prefix.
16544 libname_spec=$lt_libname_spec
16545
16546 # List of archive names.  First name is the real one, the rest are links.
16547 # The last name is the one that the linker finds with -lNAME.
16548 library_names_spec=$lt_library_names_spec
16549
16550 # The coded name of the library, if different from the real name.
16551 soname_spec=$lt_soname_spec
16552
16553 # Commands used to build and install an old-style archive.
16554 RANLIB=$lt_RANLIB
16555 old_archive_cmds=$lt_old_archive_cmds
16556 old_postinstall_cmds=$lt_old_postinstall_cmds
16557 old_postuninstall_cmds=$lt_old_postuninstall_cmds
16558
16559 # Create an old-style archive from a shared archive.
16560 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
16561
16562 # Create a temporary old-style archive to link instead of a shared archive.
16563 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
16564
16565 # Commands used to build and install a shared archive.
16566 archive_cmds=$lt_archive_cmds
16567 archive_expsym_cmds=$lt_archive_expsym_cmds
16568 postinstall_cmds=$lt_postinstall_cmds
16569 postuninstall_cmds=$lt_postuninstall_cmds
16570
16571 # Commands used to build a loadable module (assumed same as above if empty)
16572 module_cmds=$lt_module_cmds
16573 module_expsym_cmds=$lt_module_expsym_cmds
16574
16575 # Commands to strip libraries.
16576 old_striplib=$lt_old_striplib
16577 striplib=$lt_striplib
16578
16579 # Dependencies to place before the objects being linked to create a
16580 # shared library.
16581 predep_objects=$lt_predep_objects
16582
16583 # Dependencies to place after the objects being linked to create a
16584 # shared library.
16585 postdep_objects=$lt_postdep_objects
16586
16587 # Dependencies to place before the objects being linked to create a
16588 # shared library.
16589 predeps=$lt_predeps
16590
16591 # Dependencies to place after the objects being linked to create a
16592 # shared library.
16593 postdeps=$lt_postdeps
16594
16595 # The library search path used internally by the compiler when linking
16596 # a shared library.
16597 compiler_lib_search_path=$lt_compiler_lib_search_path
16598
16599 # Method to check whether dependent libraries are shared objects.
16600 deplibs_check_method=$lt_deplibs_check_method
16601
16602 # Command to use when deplibs_check_method == file_magic.
16603 file_magic_cmd=$lt_file_magic_cmd
16604
16605 # Flag that allows shared libraries with undefined symbols to be built.
16606 allow_undefined_flag=$lt_allow_undefined_flag
16607
16608 # Flag that forces no undefined symbols.
16609 no_undefined_flag=$lt_no_undefined_flag
16610
16611 # Commands used to finish a libtool library installation in a directory.
16612 finish_cmds=$lt_finish_cmds
16613
16614 # Same as above, but a single script fragment to be evaled but not shown.
16615 finish_eval=$lt_finish_eval
16616
16617 # Take the output of nm and produce a listing of raw symbols and C names.
16618 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
16619
16620 # Transform the output of nm in a proper C declaration
16621 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
16622
16623 # Transform the output of nm in a C name address pair
16624 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
16625
16626 # This is the shared library runtime path variable.
16627 runpath_var=$runpath_var
16628
16629 # This is the shared library path variable.
16630 shlibpath_var=$shlibpath_var
16631
16632 # Is shlibpath searched before the hard-coded library search path?
16633 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
16634
16635 # How to hardcode a shared library path into an executable.
16636 hardcode_action=$hardcode_action
16637
16638 # Whether we should hardcode library paths into libraries.
16639 hardcode_into_libs=$hardcode_into_libs
16640
16641 # Flag to hardcode \$libdir into a binary during linking.
16642 # This must work even if \$libdir does not exist.
16643 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
16644
16645 # If ld is used when linking, flag to hardcode \$libdir into
16646 # a binary during linking. This must work even if \$libdir does
16647 # not exist.
16648 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
16649
16650 # Whether we need a single -rpath flag with a separated argument.
16651 hardcode_libdir_separator=$lt_hardcode_libdir_separator
16652
16653 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
16654 # resulting binary.
16655 hardcode_direct=$hardcode_direct
16656
16657 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
16658 # resulting binary.
16659 hardcode_minus_L=$hardcode_minus_L
16660
16661 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
16662 # the resulting binary.
16663 hardcode_shlibpath_var=$hardcode_shlibpath_var
16664
16665 # Set to yes if building a shared library automatically hardcodes DIR into the library
16666 # and all subsequent libraries and executables linked against it.
16667 hardcode_automatic=$hardcode_automatic
16668
16669 # Variables whose values should be saved in libtool wrapper scripts and
16670 # restored at relink time.
16671 variables_saved_for_relink="$variables_saved_for_relink"
16672
16673 # Whether libtool must link a program against all its dependency libraries.
16674 link_all_deplibs=$link_all_deplibs
16675
16676 # Compile-time system search path for libraries
16677 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
16678
16679 # Run-time system search path for libraries
16680 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
16681
16682 # Fix the shell variable \$srcfile for the compiler.
16683 fix_srcfile_path=$lt_fix_srcfile_path
16684
16685 # Set to yes if exported symbols are required.
16686 always_export_symbols=$always_export_symbols
16687
16688 # The commands to list exported symbols.
16689 export_symbols_cmds=$lt_export_symbols_cmds
16690
16691 # The commands to extract the exported symbol list from a shared archive.
16692 extract_expsyms_cmds=$lt_extract_expsyms_cmds
16693
16694 # Symbols that should not be listed in the preloaded symbols.
16695 exclude_expsyms=$lt_exclude_expsyms
16696
16697 # Symbols that must always be exported.
16698 include_expsyms=$lt_include_expsyms
16699
16700 # ### END LIBTOOL CONFIG
16701
16702 __EOF__
16703
16704
16705   case $host_os in
16706   aix3*)
16707     cat <<\EOF >> "$cfgfile"
16708
16709 # AIX sometimes has problems with the GCC collect2 program.  For some
16710 # reason, if we set the COLLECT_NAMES environment variable, the problems
16711 # vanish in a puff of smoke.
16712 if test "X${COLLECT_NAMES+set}" != Xset; then
16713   COLLECT_NAMES=
16714   export COLLECT_NAMES
16715 fi
16716 EOF
16717     ;;
16718   esac
16719
16720   # We use sed instead of cat because bash on DJGPP gets confused if
16721   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
16722   # text mode, it properly converts lines to CR/LF.  This bash problem
16723   # is reportedly fixed, but why not run on old versions too?
16724   sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1)
16725
16726   mv -f "$cfgfile" "$ofile" || \
16727     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
16728   chmod +x "$ofile"
16729
16730 else
16731   # If there is no Makefile yet, we rely on a make rule to execute
16732   # `config.status --recheck' to rerun these tests and create the
16733   # libtool script then.
16734   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
16735   if test -f "$ltmain_in"; then
16736     test -f Makefile && make "$ltmain"
16737   fi
16738 fi
16739
16740
16741 ac_ext=c
16742 ac_cpp='$CPP $CPPFLAGS'
16743 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16744 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16745 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16746
16747 CC="$lt_save_CC"
16748
16749
16750 # Check whether --with-tags was given.
16751 if test "${with_tags+set}" = set; then
16752   withval=$with_tags; tagnames="$withval"
16753 fi
16754
16755
16756 if test -f "$ltmain" && test -n "$tagnames"; then
16757   if test ! -f "${ofile}"; then
16758     { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not exist" >&5
16759 echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;}
16760   fi
16761
16762   if test -z "$LTCC"; then
16763     eval "`$SHELL ${ofile} --config | grep '^LTCC='`"
16764     if test -z "$LTCC"; then
16765       { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not look like a libtool script" >&5
16766 echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;}
16767     else
16768       { echo "$as_me:$LINENO: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5
16769 echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;}
16770     fi
16771   fi
16772   if test -z "$LTCFLAGS"; then
16773     eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
16774   fi
16775
16776   # Extract list of available tagged configurations in $ofile.
16777   # Note that this assumes the entire list is on one line.
16778   available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'`
16779
16780   lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
16781   for tagname in $tagnames; do
16782     IFS="$lt_save_ifs"
16783     # Check whether tagname contains only valid characters
16784     case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in
16785     "") ;;
16786     *)  { { echo "$as_me:$LINENO: error: invalid tag name: $tagname" >&5
16787 echo "$as_me: error: invalid tag name: $tagname" >&2;}
16788    { (exit 1); exit 1; }; }
16789         ;;
16790     esac
16791
16792     if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null
16793     then
16794       { { echo "$as_me:$LINENO: error: tag name \"$tagname\" already exists" >&5
16795 echo "$as_me: error: tag name \"$tagname\" already exists" >&2;}
16796    { (exit 1); exit 1; }; }
16797     fi
16798
16799     # Update the list of available tags.
16800     if test -n "$tagname"; then
16801       echo appending configuration tag \"$tagname\" to $ofile
16802
16803       case $tagname in
16804       CXX)
16805         if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
16806             ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
16807             (test "X$CXX" != "Xg++"))) ; then
16808           ac_ext=cpp
16809 ac_cpp='$CXXCPP $CPPFLAGS'
16810 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16811 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16812 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
16813
16814
16815
16816
16817 archive_cmds_need_lc_CXX=no
16818 allow_undefined_flag_CXX=
16819 always_export_symbols_CXX=no
16820 archive_expsym_cmds_CXX=
16821 export_dynamic_flag_spec_CXX=
16822 hardcode_direct_CXX=no
16823 hardcode_libdir_flag_spec_CXX=
16824 hardcode_libdir_flag_spec_ld_CXX=
16825 hardcode_libdir_separator_CXX=
16826 hardcode_minus_L_CXX=no
16827 hardcode_shlibpath_var_CXX=unsupported
16828 hardcode_automatic_CXX=no
16829 module_cmds_CXX=
16830 module_expsym_cmds_CXX=
16831 link_all_deplibs_CXX=unknown
16832 old_archive_cmds_CXX=$old_archive_cmds
16833 no_undefined_flag_CXX=
16834 whole_archive_flag_spec_CXX=
16835 enable_shared_with_static_runtimes_CXX=no
16836
16837 # Dependencies to place before and after the object being linked:
16838 predep_objects_CXX=
16839 postdep_objects_CXX=
16840 predeps_CXX=
16841 postdeps_CXX=
16842 compiler_lib_search_path_CXX=
16843
16844 # Source file extension for C++ test sources.
16845 ac_ext=cpp
16846
16847 # Object file extension for compiled C++ test sources.
16848 objext=o
16849 objext_CXX=$objext
16850
16851 # Code to be used in simple compile tests
16852 lt_simple_compile_test_code="int some_variable = 0;"
16853
16854 # Code to be used in simple link tests
16855 lt_simple_link_test_code='int main(int, char *[]) { return(0); }'
16856
16857 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
16858
16859 # If no C compiler was specified, use CC.
16860 LTCC=${LTCC-"$CC"}
16861
16862 # If no C compiler flags were specified, use CFLAGS.
16863 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
16864
16865 # Allow CC to be a program name with arguments.
16866 compiler=$CC
16867
16868
16869 # save warnings/boilerplate of simple test code
16870 ac_outfile=conftest.$ac_objext
16871 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
16872 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
16873 _lt_compiler_boilerplate=`cat conftest.err`
16874 $rm conftest*
16875
16876 ac_outfile=conftest.$ac_objext
16877 echo "$lt_simple_link_test_code" >conftest.$ac_ext
16878 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
16879 _lt_linker_boilerplate=`cat conftest.err`
16880 $rm conftest*
16881
16882
16883 # Allow CC to be a program name with arguments.
16884 lt_save_CC=$CC
16885 lt_save_LD=$LD
16886 lt_save_GCC=$GCC
16887 GCC=$GXX
16888 lt_save_with_gnu_ld=$with_gnu_ld
16889 lt_save_path_LD=$lt_cv_path_LD
16890 if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
16891   lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
16892 else
16893   $as_unset lt_cv_prog_gnu_ld
16894 fi
16895 if test -n "${lt_cv_path_LDCXX+set}"; then
16896   lt_cv_path_LD=$lt_cv_path_LDCXX
16897 else
16898   $as_unset lt_cv_path_LD
16899 fi
16900 test -z "${LDCXX+set}" || LD=$LDCXX
16901 CC=${CXX-"c++"}
16902 compiler=$CC
16903 compiler_CXX=$CC
16904 for cc_temp in $compiler""; do
16905   case $cc_temp in
16906     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
16907     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
16908     \-*) ;;
16909     *) break;;
16910   esac
16911 done
16912 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
16913
16914
16915 # We don't want -fno-exception wen compiling C++ code, so set the
16916 # no_builtin_flag separately
16917 if test "$GXX" = yes; then
16918   lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin'
16919 else
16920   lt_prog_compiler_no_builtin_flag_CXX=
16921 fi
16922
16923 if test "$GXX" = yes; then
16924   # Set up default GNU C++ configuration
16925
16926
16927 # Check whether --with-gnu-ld was given.
16928 if test "${with_gnu_ld+set}" = set; then
16929   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
16930 else
16931   with_gnu_ld=no
16932 fi
16933
16934 ac_prog=ld
16935 if test "$GCC" = yes; then
16936   # Check if gcc -print-prog-name=ld gives a path.
16937   { echo "$as_me:$LINENO: checking for ld used by $CC" >&5
16938 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6; }
16939   case $host in
16940   *-*-mingw*)
16941     # gcc leaves a trailing carriage return which upsets mingw
16942     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
16943   *)
16944     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
16945   esac
16946   case $ac_prog in
16947     # Accept absolute paths.
16948     [\\/]* | ?:[\\/]*)
16949       re_direlt='/[^/][^/]*/\.\./'
16950       # Canonicalize the pathname of ld
16951       ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'`
16952       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
16953         ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"`
16954       done
16955       test -z "$LD" && LD="$ac_prog"
16956       ;;
16957   "")
16958     # If it fails, then pretend we aren't using GCC.
16959     ac_prog=ld
16960     ;;
16961   *)
16962     # If it is relative, then search for the first ld in PATH.
16963     with_gnu_ld=unknown
16964     ;;
16965   esac
16966 elif test "$with_gnu_ld" = yes; then
16967   { echo "$as_me:$LINENO: checking for GNU ld" >&5
16968 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6; }
16969 else
16970   { echo "$as_me:$LINENO: checking for non-GNU ld" >&5
16971 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6; }
16972 fi
16973 if test "${lt_cv_path_LD+set}" = set; then
16974   echo $ECHO_N "(cached) $ECHO_C" >&6
16975 else
16976   if test -z "$LD"; then
16977   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
16978   for ac_dir in $PATH; do
16979     IFS="$lt_save_ifs"
16980     test -z "$ac_dir" && ac_dir=.
16981     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
16982       lt_cv_path_LD="$ac_dir/$ac_prog"
16983       # Check to see if the program is GNU ld.  I'd rather use --version,
16984       # but apparently some variants of GNU ld only accept -v.
16985       # Break only if it was the GNU/non-GNU ld that we prefer.
16986       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
16987       *GNU* | *'with BFD'*)
16988         test "$with_gnu_ld" != no && break
16989         ;;
16990       *)
16991         test "$with_gnu_ld" != yes && break
16992         ;;
16993       esac
16994     fi
16995   done
16996   IFS="$lt_save_ifs"
16997 else
16998   lt_cv_path_LD="$LD" # Let the user override the test with a path.
16999 fi
17000 fi
17001
17002 LD="$lt_cv_path_LD"
17003 if test -n "$LD"; then
17004   { echo "$as_me:$LINENO: result: $LD" >&5
17005 echo "${ECHO_T}$LD" >&6; }
17006 else
17007   { echo "$as_me:$LINENO: result: no" >&5
17008 echo "${ECHO_T}no" >&6; }
17009 fi
17010 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
17011 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
17012    { (exit 1); exit 1; }; }
17013 { echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
17014 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6; }
17015 if test "${lt_cv_prog_gnu_ld+set}" = set; then
17016   echo $ECHO_N "(cached) $ECHO_C" >&6
17017 else
17018   # I'd rather use --version here, but apparently some GNU lds only accept -v.
17019 case `$LD -v 2>&1 </dev/null` in
17020 *GNU* | *'with BFD'*)
17021   lt_cv_prog_gnu_ld=yes
17022   ;;
17023 *)
17024   lt_cv_prog_gnu_ld=no
17025   ;;
17026 esac
17027 fi
17028 { echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
17029 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6; }
17030 with_gnu_ld=$lt_cv_prog_gnu_ld
17031
17032
17033
17034   # Check if GNU C++ uses GNU ld as the underlying linker, since the
17035   # archiving commands below assume that GNU ld is being used.
17036   if test "$with_gnu_ld" = yes; then
17037     archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
17038     archive_expsym_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17039
17040     hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir'
17041     export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
17042
17043     # If archive_cmds runs LD, not CC, wlarc should be empty
17044     # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
17045     #     investigate it a little bit more. (MM)
17046     wlarc='${wl}'
17047
17048     # ancient GNU ld didn't support --whole-archive et. al.
17049     if eval "`$CC -print-prog-name=ld` --help 2>&1" | \
17050         grep 'no-whole-archive' > /dev/null; then
17051       whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
17052     else
17053       whole_archive_flag_spec_CXX=
17054     fi
17055   else
17056     with_gnu_ld=no
17057     wlarc=
17058
17059     # A generic and very simple default shared library creation
17060     # command for GNU C++ for the case where it uses the native
17061     # linker, instead of GNU ld.  If possible, this setting should
17062     # overridden to take advantage of the native linker features on
17063     # the platform it is being used on.
17064     archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
17065   fi
17066
17067   # Commands to make compiler produce verbose output that lists
17068   # what "hidden" libraries, object files and flags are used when
17069   # linking a shared library.
17070   output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
17071
17072 else
17073   GXX=no
17074   with_gnu_ld=no
17075   wlarc=
17076 fi
17077
17078 # PORTME: fill in a description of your system's C++ link characteristics
17079 { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
17080 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; }
17081 ld_shlibs_CXX=yes
17082 case $host_os in
17083   aix3*)
17084     # FIXME: insert proper C++ library support
17085     ld_shlibs_CXX=no
17086     ;;
17087   aix4* | aix5*)
17088     if test "$host_cpu" = ia64; then
17089       # On IA64, the linker does run time linking by default, so we don't
17090       # have to do anything special.
17091       aix_use_runtimelinking=no
17092       exp_sym_flag='-Bexport'
17093       no_entry_flag=""
17094     else
17095       aix_use_runtimelinking=no
17096
17097       # Test if we are trying to use run time linking or normal
17098       # AIX style linking. If -brtl is somewhere in LDFLAGS, we
17099       # need to do runtime linking.
17100       case $host_os in aix4.[23]|aix4.[23].*|aix5*)
17101         for ld_flag in $LDFLAGS; do
17102           case $ld_flag in
17103           *-brtl*)
17104             aix_use_runtimelinking=yes
17105             break
17106             ;;
17107           esac
17108         done
17109         ;;
17110       esac
17111
17112       exp_sym_flag='-bexport'
17113       no_entry_flag='-bnoentry'
17114     fi
17115
17116     # When large executables or shared objects are built, AIX ld can
17117     # have problems creating the table of contents.  If linking a library
17118     # or program results in "error TOC overflow" add -mminimal-toc to
17119     # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
17120     # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
17121
17122     archive_cmds_CXX=''
17123     hardcode_direct_CXX=yes
17124     hardcode_libdir_separator_CXX=':'
17125     link_all_deplibs_CXX=yes
17126
17127     if test "$GXX" = yes; then
17128       case $host_os in aix4.[012]|aix4.[012].*)
17129       # We only want to do this on AIX 4.2 and lower, the check
17130       # below for broken collect2 doesn't work under 4.3+
17131         collect2name=`${CC} -print-prog-name=collect2`
17132         if test -f "$collect2name" && \
17133            strings "$collect2name" | grep resolve_lib_name >/dev/null
17134         then
17135           # We have reworked collect2
17136           :
17137         else
17138           # We have old collect2
17139           hardcode_direct_CXX=unsupported
17140           # It fails to find uninstalled libraries when the uninstalled
17141           # path is not listed in the libpath.  Setting hardcode_minus_L
17142           # to unsupported forces relinking
17143           hardcode_minus_L_CXX=yes
17144           hardcode_libdir_flag_spec_CXX='-L$libdir'
17145           hardcode_libdir_separator_CXX=
17146         fi
17147         ;;
17148       esac
17149       shared_flag='-shared'
17150       if test "$aix_use_runtimelinking" = yes; then
17151         shared_flag="$shared_flag "'${wl}-G'
17152       fi
17153     else
17154       # not using gcc
17155       if test "$host_cpu" = ia64; then
17156         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
17157         # chokes on -Wl,-G. The following line is correct:
17158         shared_flag='-G'
17159       else
17160         if test "$aix_use_runtimelinking" = yes; then
17161           shared_flag='${wl}-G'
17162         else
17163           shared_flag='${wl}-bM:SRE'
17164         fi
17165       fi
17166     fi
17167
17168     # It seems that -bexpall does not export symbols beginning with
17169     # underscore (_), so it is better to generate a list of symbols to export.
17170     always_export_symbols_CXX=yes
17171     if test "$aix_use_runtimelinking" = yes; then
17172       # Warning - without using the other runtime loading flags (-brtl),
17173       # -berok will link without error, but may produce a broken library.
17174       allow_undefined_flag_CXX='-berok'
17175       # Determine the default libpath from the value encoded in an empty executable.
17176       cat >conftest.$ac_ext <<_ACEOF
17177 /* confdefs.h.  */
17178 _ACEOF
17179 cat confdefs.h >>conftest.$ac_ext
17180 cat >>conftest.$ac_ext <<_ACEOF
17181 /* end confdefs.h.  */
17182
17183 int
17184 main ()
17185 {
17186
17187   ;
17188   return 0;
17189 }
17190 _ACEOF
17191 rm -f conftest.$ac_objext conftest$ac_exeext
17192 if { (ac_try="$ac_link"
17193 case "(($ac_try" in
17194   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17195   *) ac_try_echo=$ac_try;;
17196 esac
17197 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17198   (eval "$ac_link") 2>conftest.er1
17199   ac_status=$?
17200   grep -v '^ *+' conftest.er1 >conftest.err
17201   rm -f conftest.er1
17202   cat conftest.err >&5
17203   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17204   (exit $ac_status); } && {
17205          test -z "$ac_cxx_werror_flag" ||
17206          test ! -s conftest.err
17207        } && test -s conftest$ac_exeext &&
17208        $as_test_x conftest$ac_exeext; then
17209
17210 lt_aix_libpath_sed='
17211     /Import File Strings/,/^$/ {
17212         /^0/ {
17213             s/^0  *\(.*\)$/\1/
17214             p
17215         }
17216     }'
17217 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17218 # Check for a 64-bit object if we didn't find anything.
17219 if test -z "$aix_libpath"; then
17220   aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17221 fi
17222 else
17223   echo "$as_me: failed program was:" >&5
17224 sed 's/^/| /' conftest.$ac_ext >&5
17225
17226
17227 fi
17228
17229 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17230       conftest$ac_exeext conftest.$ac_ext
17231 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
17232
17233       hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
17234
17235       archive_expsym_cmds_CXX="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
17236      else
17237       if test "$host_cpu" = ia64; then
17238         hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib'
17239         allow_undefined_flag_CXX="-z nodefs"
17240         archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
17241       else
17242         # Determine the default libpath from the value encoded in an empty executable.
17243         cat >conftest.$ac_ext <<_ACEOF
17244 /* confdefs.h.  */
17245 _ACEOF
17246 cat confdefs.h >>conftest.$ac_ext
17247 cat >>conftest.$ac_ext <<_ACEOF
17248 /* end confdefs.h.  */
17249
17250 int
17251 main ()
17252 {
17253
17254   ;
17255   return 0;
17256 }
17257 _ACEOF
17258 rm -f conftest.$ac_objext conftest$ac_exeext
17259 if { (ac_try="$ac_link"
17260 case "(($ac_try" in
17261   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17262   *) ac_try_echo=$ac_try;;
17263 esac
17264 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17265   (eval "$ac_link") 2>conftest.er1
17266   ac_status=$?
17267   grep -v '^ *+' conftest.er1 >conftest.err
17268   rm -f conftest.er1
17269   cat conftest.err >&5
17270   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17271   (exit $ac_status); } && {
17272          test -z "$ac_cxx_werror_flag" ||
17273          test ! -s conftest.err
17274        } && test -s conftest$ac_exeext &&
17275        $as_test_x conftest$ac_exeext; then
17276
17277 lt_aix_libpath_sed='
17278     /Import File Strings/,/^$/ {
17279         /^0/ {
17280             s/^0  *\(.*\)$/\1/
17281             p
17282         }
17283     }'
17284 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17285 # Check for a 64-bit object if we didn't find anything.
17286 if test -z "$aix_libpath"; then
17287   aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
17288 fi
17289 else
17290   echo "$as_me: failed program was:" >&5
17291 sed 's/^/| /' conftest.$ac_ext >&5
17292
17293
17294 fi
17295
17296 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17297       conftest$ac_exeext conftest.$ac_ext
17298 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
17299
17300         hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
17301         # Warning - without using the other run time loading flags,
17302         # -berok will link without error, but may produce a broken library.
17303         no_undefined_flag_CXX=' ${wl}-bernotok'
17304         allow_undefined_flag_CXX=' ${wl}-berok'
17305         # Exported symbols can be pulled into shared objects from archives
17306         whole_archive_flag_spec_CXX='$convenience'
17307         archive_cmds_need_lc_CXX=yes
17308         # This is similar to how AIX traditionally builds its shared libraries.
17309         archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
17310       fi
17311     fi
17312     ;;
17313
17314   beos*)
17315     if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
17316       allow_undefined_flag_CXX=unsupported
17317       # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
17318       # support --undefined.  This deserves some investigation.  FIXME
17319       archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17320     else
17321       ld_shlibs_CXX=no
17322     fi
17323     ;;
17324
17325   chorus*)
17326     case $cc_basename in
17327       *)
17328         # FIXME: insert proper C++ library support
17329         ld_shlibs_CXX=no
17330         ;;
17331     esac
17332     ;;
17333
17334   cygwin* | mingw* | pw32*)
17335     # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless,
17336     # as there is no search path for DLLs.
17337     hardcode_libdir_flag_spec_CXX='-L$libdir'
17338     allow_undefined_flag_CXX=unsupported
17339     always_export_symbols_CXX=no
17340     enable_shared_with_static_runtimes_CXX=yes
17341
17342     if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
17343       archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
17344       # If the export-symbols file already is a .def file (1st line
17345       # is EXPORTS), use it as is; otherwise, prepend...
17346       archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
17347         cp $export_symbols $output_objdir/$soname.def;
17348       else
17349         echo EXPORTS > $output_objdir/$soname.def;
17350         cat $export_symbols >> $output_objdir/$soname.def;
17351       fi~
17352       $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
17353     else
17354       ld_shlibs_CXX=no
17355     fi
17356   ;;
17357       darwin* | rhapsody*)
17358         case $host_os in
17359         rhapsody* | darwin1.[012])
17360          allow_undefined_flag_CXX='${wl}-undefined ${wl}suppress'
17361          ;;
17362        *) # Darwin 1.3 on
17363          if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
17364            allow_undefined_flag_CXX='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
17365          else
17366            case ${MACOSX_DEPLOYMENT_TARGET} in
17367              10.[012])
17368                allow_undefined_flag_CXX='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
17369                ;;
17370              10.*)
17371                allow_undefined_flag_CXX='${wl}-undefined ${wl}dynamic_lookup'
17372                ;;
17373            esac
17374          fi
17375          ;;
17376         esac
17377       archive_cmds_need_lc_CXX=no
17378       hardcode_direct_CXX=no
17379       hardcode_automatic_CXX=yes
17380       hardcode_shlibpath_var_CXX=unsupported
17381       whole_archive_flag_spec_CXX=''
17382       link_all_deplibs_CXX=yes
17383
17384     if test "$GXX" = yes ; then
17385       lt_int_apple_cc_single_mod=no
17386       output_verbose_link_cmd='echo'
17387       if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then
17388        lt_int_apple_cc_single_mod=yes
17389       fi
17390       if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
17391        archive_cmds_CXX='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
17392       else
17393           archive_cmds_CXX='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
17394         fi
17395         module_cmds_CXX='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
17396         # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
17397           if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
17398             archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
17399           else
17400             archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
17401           fi
17402             module_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
17403       else
17404       case $cc_basename in
17405         xlc*)
17406          output_verbose_link_cmd='echo'
17407           archive_cmds_CXX='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
17408           module_cmds_CXX='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
17409           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
17410           archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
17411           module_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
17412           ;;
17413        *)
17414          ld_shlibs_CXX=no
17415           ;;
17416       esac
17417       fi
17418         ;;
17419
17420   dgux*)
17421     case $cc_basename in
17422       ec++*)
17423         # FIXME: insert proper C++ library support
17424         ld_shlibs_CXX=no
17425         ;;
17426       ghcx*)
17427         # Green Hills C++ Compiler
17428         # FIXME: insert proper C++ library support
17429         ld_shlibs_CXX=no
17430         ;;
17431       *)
17432         # FIXME: insert proper C++ library support
17433         ld_shlibs_CXX=no
17434         ;;
17435     esac
17436     ;;
17437   freebsd[12]*)
17438     # C++ shared libraries reported to be fairly broken before switch to ELF
17439     ld_shlibs_CXX=no
17440     ;;
17441   freebsd-elf*)
17442     archive_cmds_need_lc_CXX=no
17443     ;;
17444   freebsd* | dragonfly*)
17445     # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
17446     # conventions
17447     ld_shlibs_CXX=yes
17448     ;;
17449   gnu*)
17450     ;;
17451   hpux9*)
17452     hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
17453     hardcode_libdir_separator_CXX=:
17454     export_dynamic_flag_spec_CXX='${wl}-E'
17455     hardcode_direct_CXX=yes
17456     hardcode_minus_L_CXX=yes # Not in the search PATH,
17457                                 # but as the default
17458                                 # location of the library.
17459
17460     case $cc_basename in
17461     CC*)
17462       # FIXME: insert proper C++ library support
17463       ld_shlibs_CXX=no
17464       ;;
17465     aCC*)
17466       archive_cmds_CXX='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
17467       # Commands to make compiler produce verbose output that lists
17468       # what "hidden" libraries, object files and flags are used when
17469       # linking a shared library.
17470       #
17471       # There doesn't appear to be a way to prevent this compiler from
17472       # explicitly linking system object files so we need to strip them
17473       # from the output so that they don't get included in the library
17474       # dependencies.
17475       output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[-]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
17476       ;;
17477     *)
17478       if test "$GXX" = yes; then
17479         archive_cmds_CXX='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
17480       else
17481         # FIXME: insert proper C++ library support
17482         ld_shlibs_CXX=no
17483       fi
17484       ;;
17485     esac
17486     ;;
17487   hpux10*|hpux11*)
17488     if test $with_gnu_ld = no; then
17489       hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
17490       hardcode_libdir_separator_CXX=:
17491
17492       case $host_cpu in
17493       hppa*64*|ia64*) ;;
17494       *)
17495         export_dynamic_flag_spec_CXX='${wl}-E'
17496         ;;
17497       esac
17498     fi
17499     case $host_cpu in
17500     hppa*64*|ia64*)
17501       hardcode_direct_CXX=no
17502       hardcode_shlibpath_var_CXX=no
17503       ;;
17504     *)
17505       hardcode_direct_CXX=yes
17506       hardcode_minus_L_CXX=yes # Not in the search PATH,
17507                                               # but as the default
17508                                               # location of the library.
17509       ;;
17510     esac
17511
17512     case $cc_basename in
17513       CC*)
17514         # FIXME: insert proper C++ library support
17515         ld_shlibs_CXX=no
17516         ;;
17517       aCC*)
17518         case $host_cpu in
17519         hppa*64*)
17520           archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
17521           ;;
17522         ia64*)
17523           archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
17524           ;;
17525         *)
17526           archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
17527           ;;
17528         esac
17529         # Commands to make compiler produce verbose output that lists
17530         # what "hidden" libraries, object files and flags are used when
17531         # linking a shared library.
17532         #
17533         # There doesn't appear to be a way to prevent this compiler from
17534         # explicitly linking system object files so we need to strip them
17535         # from the output so that they don't get included in the library
17536         # dependencies.
17537         output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
17538         ;;
17539       *)
17540         if test "$GXX" = yes; then
17541           if test $with_gnu_ld = no; then
17542             case $host_cpu in
17543             hppa*64*)
17544               archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
17545               ;;
17546             ia64*)
17547               archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
17548               ;;
17549             *)
17550               archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
17551               ;;
17552             esac
17553           fi
17554         else
17555           # FIXME: insert proper C++ library support
17556           ld_shlibs_CXX=no
17557         fi
17558         ;;
17559     esac
17560     ;;
17561   interix[3-9]*)
17562     hardcode_direct_CXX=no
17563     hardcode_shlibpath_var_CXX=no
17564     hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
17565     export_dynamic_flag_spec_CXX='${wl}-E'
17566     # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
17567     # Instead, shared libraries are loaded at an image base (0x10000000 by
17568     # default) and relocated if they conflict, which is a slow very memory
17569     # consuming and fragmenting process.  To avoid this, we pick a random,
17570     # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
17571     # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
17572     archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
17573     archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
17574     ;;
17575   irix5* | irix6*)
17576     case $cc_basename in
17577       CC*)
17578         # SGI C++
17579         archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
17580
17581         # Archives containing C++ object files must be created using
17582         # "CC -ar", where "CC" is the IRIX C++ compiler.  This is
17583         # necessary to make sure instantiated templates are included
17584         # in the archive.
17585         old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs'
17586         ;;
17587       *)
17588         if test "$GXX" = yes; then
17589           if test "$with_gnu_ld" = no; then
17590             archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
17591           else
17592             archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib'
17593           fi
17594         fi
17595         link_all_deplibs_CXX=yes
17596         ;;
17597     esac
17598     hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
17599     hardcode_libdir_separator_CXX=:
17600     ;;
17601   linux* | k*bsd*-gnu)
17602     case $cc_basename in
17603       KCC*)
17604         # Kuck and Associates, Inc. (KAI) C++ Compiler
17605
17606         # KCC will only create a shared library if the output file
17607         # ends with ".so" (or ".sl" for HP-UX), so rename the library
17608         # to its proper name (with version) after linking.
17609         archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
17610         archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
17611         # Commands to make compiler produce verbose output that lists
17612         # what "hidden" libraries, object files and flags are used when
17613         # linking a shared library.
17614         #
17615         # There doesn't appear to be a way to prevent this compiler from
17616         # explicitly linking system object files so we need to strip them
17617         # from the output so that they don't get included in the library
17618         # dependencies.
17619         output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
17620
17621         hardcode_libdir_flag_spec_CXX='${wl}--rpath,$libdir'
17622         export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
17623
17624         # Archives containing C++ object files must be created using
17625         # "CC -Bstatic", where "CC" is the KAI C++ compiler.
17626         old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs'
17627         ;;
17628       icpc*)
17629         # Intel C++
17630         with_gnu_ld=yes
17631         # version 8.0 and above of icpc choke on multiply defined symbols
17632         # if we add $predep_objects and $postdep_objects, however 7.1 and
17633         # earlier do not add the objects themselves.
17634         case `$CC -V 2>&1` in
17635         *"Version 7."*)
17636           archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
17637           archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17638           ;;
17639         *)  # Version 8.0 or newer
17640           tmp_idyn=
17641           case $host_cpu in
17642             ia64*) tmp_idyn=' -i_dynamic';;
17643           esac
17644           archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
17645           archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
17646           ;;
17647         esac
17648         archive_cmds_need_lc_CXX=no
17649         hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
17650         export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
17651         whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
17652         ;;
17653       pgCC*)
17654         # Portland Group C++ compiler
17655         archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
17656         archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
17657
17658         hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir'
17659         export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
17660         whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
17661         ;;
17662       cxx*)
17663         # Compaq C++
17664         archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
17665         archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname  -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
17666
17667         runpath_var=LD_RUN_PATH
17668         hardcode_libdir_flag_spec_CXX='-rpath $libdir'
17669         hardcode_libdir_separator_CXX=:
17670
17671         # Commands to make compiler produce verbose output that lists
17672         # what "hidden" libraries, object files and flags are used when
17673         # linking a shared library.
17674         #
17675         # There doesn't appear to be a way to prevent this compiler from
17676         # explicitly linking system object files so we need to strip them
17677         # from the output so that they don't get included in the library
17678         # dependencies.
17679         output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
17680         ;;
17681       *)
17682         case `$CC -V 2>&1 | sed 5q` in
17683         *Sun\ C*)
17684           # Sun C++ 5.9
17685           no_undefined_flag_CXX=' -zdefs'
17686           archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
17687           archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
17688           hardcode_libdir_flag_spec_CXX='-R$libdir'
17689           whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
17690
17691           # Not sure whether something based on
17692           # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
17693           # would be better.
17694           output_verbose_link_cmd='echo'
17695
17696           # Archives containing C++ object files must be created using
17697           # "CC -xar", where "CC" is the Sun C++ compiler.  This is
17698           # necessary to make sure instantiated templates are included
17699           # in the archive.
17700           old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
17701           ;;
17702         esac
17703         ;;
17704     esac
17705     ;;
17706   lynxos*)
17707     # FIXME: insert proper C++ library support
17708     ld_shlibs_CXX=no
17709     ;;
17710   m88k*)
17711     # FIXME: insert proper C++ library support
17712     ld_shlibs_CXX=no
17713     ;;
17714   mvs*)
17715     case $cc_basename in
17716       cxx*)
17717         # FIXME: insert proper C++ library support
17718         ld_shlibs_CXX=no
17719         ;;
17720       *)
17721         # FIXME: insert proper C++ library support
17722         ld_shlibs_CXX=no
17723         ;;
17724     esac
17725     ;;
17726   netbsd*)
17727     if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
17728       archive_cmds_CXX='$LD -Bshareable  -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
17729       wlarc=
17730       hardcode_libdir_flag_spec_CXX='-R$libdir'
17731       hardcode_direct_CXX=yes
17732       hardcode_shlibpath_var_CXX=no
17733     fi
17734     # Workaround some broken pre-1.5 toolchains
17735     output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
17736     ;;
17737   openbsd2*)
17738     # C++ shared libraries are fairly broken
17739     ld_shlibs_CXX=no
17740     ;;
17741   openbsd*)
17742     if test -f /usr/libexec/ld.so; then
17743       hardcode_direct_CXX=yes
17744       hardcode_shlibpath_var_CXX=no
17745       archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
17746       hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
17747       if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
17748         archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
17749         export_dynamic_flag_spec_CXX='${wl}-E'
17750         whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
17751       fi
17752       output_verbose_link_cmd='echo'
17753     else
17754       ld_shlibs_CXX=no
17755     fi
17756     ;;
17757   osf3*)
17758     case $cc_basename in
17759       KCC*)
17760         # Kuck and Associates, Inc. (KAI) C++ Compiler
17761
17762         # KCC will only create a shared library if the output file
17763         # ends with ".so" (or ".sl" for HP-UX), so rename the library
17764         # to its proper name (with version) after linking.
17765         archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
17766
17767         hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
17768         hardcode_libdir_separator_CXX=:
17769
17770         # Archives containing C++ object files must be created using
17771         # "CC -Bstatic", where "CC" is the KAI C++ compiler.
17772         old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs'
17773
17774         ;;
17775       RCC*)
17776         # Rational C++ 2.4.1
17777         # FIXME: insert proper C++ library support
17778         ld_shlibs_CXX=no
17779         ;;
17780       cxx*)
17781         allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
17782         archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
17783
17784         hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
17785         hardcode_libdir_separator_CXX=:
17786
17787         # Commands to make compiler produce verbose output that lists
17788         # what "hidden" libraries, object files and flags are used when
17789         # linking a shared library.
17790         #
17791         # There doesn't appear to be a way to prevent this compiler from
17792         # explicitly linking system object files so we need to strip them
17793         # from the output so that they don't get included in the library
17794         # dependencies.
17795         output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
17796         ;;
17797       *)
17798         if test "$GXX" = yes && test "$with_gnu_ld" = no; then
17799           allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
17800           archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
17801
17802           hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
17803           hardcode_libdir_separator_CXX=:
17804
17805           # Commands to make compiler produce verbose output that lists
17806           # what "hidden" libraries, object files and flags are used when
17807           # linking a shared library.
17808           output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
17809
17810         else
17811           # FIXME: insert proper C++ library support
17812           ld_shlibs_CXX=no
17813         fi
17814         ;;
17815     esac
17816     ;;
17817   osf4* | osf5*)
17818     case $cc_basename in
17819       KCC*)
17820         # Kuck and Associates, Inc. (KAI) C++ Compiler
17821
17822         # KCC will only create a shared library if the output file
17823         # ends with ".so" (or ".sl" for HP-UX), so rename the library
17824         # to its proper name (with version) after linking.
17825         archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
17826
17827         hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
17828         hardcode_libdir_separator_CXX=:
17829
17830         # Archives containing C++ object files must be created using
17831         # the KAI C++ compiler.
17832         old_archive_cmds_CXX='$CC -o $oldlib $oldobjs'
17833         ;;
17834       RCC*)
17835         # Rational C++ 2.4.1
17836         # FIXME: insert proper C++ library support
17837         ld_shlibs_CXX=no
17838         ;;
17839       cxx*)
17840         allow_undefined_flag_CXX=' -expect_unresolved \*'
17841         archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
17842         archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
17843           echo "-hidden">> $lib.exp~
17844           $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp  `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~
17845           $rm $lib.exp'
17846
17847         hardcode_libdir_flag_spec_CXX='-rpath $libdir'
17848         hardcode_libdir_separator_CXX=:
17849
17850         # Commands to make compiler produce verbose output that lists
17851         # what "hidden" libraries, object files and flags are used when
17852         # linking a shared library.
17853         #
17854         # There doesn't appear to be a way to prevent this compiler from
17855         # explicitly linking system object files so we need to strip them
17856         # from the output so that they don't get included in the library
17857         # dependencies.
17858         output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
17859         ;;
17860       *)
17861         if test "$GXX" = yes && test "$with_gnu_ld" = no; then
17862           allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
17863          archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
17864
17865           hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
17866           hardcode_libdir_separator_CXX=:
17867
17868           # Commands to make compiler produce verbose output that lists
17869           # what "hidden" libraries, object files and flags are used when
17870           # linking a shared library.
17871           output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"'
17872
17873         else
17874           # FIXME: insert proper C++ library support
17875           ld_shlibs_CXX=no
17876         fi
17877         ;;
17878     esac
17879     ;;
17880   psos*)
17881     # FIXME: insert proper C++ library support
17882     ld_shlibs_CXX=no
17883     ;;
17884   sunos4*)
17885     case $cc_basename in
17886       CC*)
17887         # Sun C++ 4.x
17888         # FIXME: insert proper C++ library support
17889         ld_shlibs_CXX=no
17890         ;;
17891       lcc*)
17892         # Lucid
17893         # FIXME: insert proper C++ library support
17894         ld_shlibs_CXX=no
17895         ;;
17896       *)
17897         # FIXME: insert proper C++ library support
17898         ld_shlibs_CXX=no
17899         ;;
17900     esac
17901     ;;
17902   solaris*)
17903     case $cc_basename in
17904       CC*)
17905         # Sun C++ 4.2, 5.x and Centerline C++
17906         archive_cmds_need_lc_CXX=yes
17907         no_undefined_flag_CXX=' -zdefs'
17908         archive_cmds_CXX='$CC -G${allow_undefined_flag}  -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
17909         archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
17910         $CC -G${allow_undefined_flag}  ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
17911
17912         hardcode_libdir_flag_spec_CXX='-R$libdir'
17913         hardcode_shlibpath_var_CXX=no
17914         case $host_os in
17915           solaris2.[0-5] | solaris2.[0-5].*) ;;
17916           *)
17917             # The compiler driver will combine and reorder linker options,
17918             # but understands `-z linker_flag'.
17919             # Supported since Solaris 2.6 (maybe 2.5.1?)
17920             whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract'
17921             ;;
17922         esac
17923         link_all_deplibs_CXX=yes
17924
17925         output_verbose_link_cmd='echo'
17926
17927         # Archives containing C++ object files must be created using
17928         # "CC -xar", where "CC" is the Sun C++ compiler.  This is
17929         # necessary to make sure instantiated templates are included
17930         # in the archive.
17931         old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
17932         ;;
17933       gcx*)
17934         # Green Hills C++ Compiler
17935         archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
17936
17937         # The C++ compiler must be used to create the archive.
17938         old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
17939         ;;
17940       *)
17941         # GNU C++ compiler with Solaris linker
17942         if test "$GXX" = yes && test "$with_gnu_ld" = no; then
17943           no_undefined_flag_CXX=' ${wl}-z ${wl}defs'
17944           if $CC --version | grep -v '^2\.7' > /dev/null; then
17945             archive_cmds_CXX='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
17946             archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
17947                 $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
17948
17949             # Commands to make compiler produce verbose output that lists
17950             # what "hidden" libraries, object files and flags are used when
17951             # linking a shared library.
17952             output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
17953           else
17954             # g++ 2.7 appears to require `-G' NOT `-shared' on this
17955             # platform.
17956             archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
17957             archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
17958                 $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
17959
17960             # Commands to make compiler produce verbose output that lists
17961             # what "hidden" libraries, object files and flags are used when
17962             # linking a shared library.
17963             output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\""
17964           fi
17965
17966           hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir'
17967           case $host_os in
17968           solaris2.[0-5] | solaris2.[0-5].*) ;;
17969           *)
17970             whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
17971             ;;
17972           esac
17973         fi
17974         ;;
17975     esac
17976     ;;
17977   sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
17978     no_undefined_flag_CXX='${wl}-z,text'
17979     archive_cmds_need_lc_CXX=no
17980     hardcode_shlibpath_var_CXX=no
17981     runpath_var='LD_RUN_PATH'
17982
17983     case $cc_basename in
17984       CC*)
17985         archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
17986         archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
17987         ;;
17988       *)
17989         archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
17990         archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
17991         ;;
17992     esac
17993     ;;
17994   sysv5* | sco3.2v5* | sco5v6*)
17995     # Note: We can NOT use -z defs as we might desire, because we do not
17996     # link with -lc, and that would cause any symbols used from libc to
17997     # always be unresolved, which means just about no library would
17998     # ever link correctly.  If we're not using GNU ld we use -z text
17999     # though, which does catch some bad symbols but isn't as heavy-handed
18000     # as -z defs.
18001     # For security reasons, it is highly recommended that you always
18002     # use absolute paths for naming shared libraries, and exclude the
18003     # DT_RUNPATH tag from executables and libraries.  But doing so
18004     # requires that you compile everything twice, which is a pain.
18005     # So that behaviour is only enabled if SCOABSPATH is set to a
18006     # non-empty value in the environment.  Most likely only useful for
18007     # creating official distributions of packages.
18008     # This is a hack until libtool officially supports absolute path
18009     # names for shared libraries.
18010     no_undefined_flag_CXX='${wl}-z,text'
18011     allow_undefined_flag_CXX='${wl}-z,nodefs'
18012     archive_cmds_need_lc_CXX=no
18013     hardcode_shlibpath_var_CXX=no
18014     hardcode_libdir_flag_spec_CXX='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
18015     hardcode_libdir_separator_CXX=':'
18016     link_all_deplibs_CXX=yes
18017     export_dynamic_flag_spec_CXX='${wl}-Bexport'
18018     runpath_var='LD_RUN_PATH'
18019
18020     case $cc_basename in
18021       CC*)
18022         archive_cmds_CXX='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
18023         archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
18024         ;;
18025       *)
18026         archive_cmds_CXX='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
18027         archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
18028         ;;
18029     esac
18030     ;;
18031   tandem*)
18032     case $cc_basename in
18033       NCC*)
18034         # NonStop-UX NCC 3.20
18035         # FIXME: insert proper C++ library support
18036         ld_shlibs_CXX=no
18037         ;;
18038       *)
18039         # FIXME: insert proper C++ library support
18040         ld_shlibs_CXX=no
18041         ;;
18042     esac
18043     ;;
18044   vxworks*)
18045     # FIXME: insert proper C++ library support
18046     ld_shlibs_CXX=no
18047     ;;
18048   *)
18049     # FIXME: insert proper C++ library support
18050     ld_shlibs_CXX=no
18051     ;;
18052 esac
18053 { echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5
18054 echo "${ECHO_T}$ld_shlibs_CXX" >&6; }
18055 test "$ld_shlibs_CXX" = no && can_build_shared=no
18056
18057 GCC_CXX="$GXX"
18058 LD_CXX="$LD"
18059
18060
18061 cat > conftest.$ac_ext <<EOF
18062 class Foo
18063 {
18064 public:
18065   Foo (void) { a = 0; }
18066 private:
18067   int a;
18068 };
18069 EOF
18070
18071 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18072   (eval $ac_compile) 2>&5
18073   ac_status=$?
18074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18075   (exit $ac_status); }; then
18076   # Parse the compiler output and extract the necessary
18077   # objects, libraries and library flags.
18078
18079   # Sentinel used to keep track of whether or not we are before
18080   # the conftest object file.
18081   pre_test_object_deps_done=no
18082
18083   # The `*' in the case matches for architectures that use `case' in
18084   # $output_verbose_cmd can trigger glob expansion during the loop
18085   # eval without this substitution.
18086   output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"`
18087
18088   for p in `eval $output_verbose_link_cmd`; do
18089     case $p in
18090
18091     -L* | -R* | -l*)
18092        # Some compilers place space between "-{L,R}" and the path.
18093        # Remove the space.
18094        if test $p = "-L" \
18095           || test $p = "-R"; then
18096          prev=$p
18097          continue
18098        else
18099          prev=
18100        fi
18101
18102        if test "$pre_test_object_deps_done" = no; then
18103          case $p in
18104          -L* | -R*)
18105            # Internal compiler library paths should come after those
18106            # provided the user.  The postdeps already come after the
18107            # user supplied libs so there is no need to process them.
18108            if test -z "$compiler_lib_search_path_CXX"; then
18109              compiler_lib_search_path_CXX="${prev}${p}"
18110            else
18111              compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}"
18112            fi
18113            ;;
18114          # The "-l" case would never come before the object being
18115          # linked, so don't bother handling this case.
18116          esac
18117        else
18118          if test -z "$postdeps_CXX"; then
18119            postdeps_CXX="${prev}${p}"
18120          else
18121            postdeps_CXX="${postdeps_CXX} ${prev}${p}"
18122          fi
18123        fi
18124        ;;
18125
18126     *.$objext)
18127        # This assumes that the test object file only shows up
18128        # once in the compiler output.
18129        if test "$p" = "conftest.$objext"; then
18130          pre_test_object_deps_done=yes
18131          continue
18132        fi
18133
18134        if test "$pre_test_object_deps_done" = no; then
18135          if test -z "$predep_objects_CXX"; then
18136            predep_objects_CXX="$p"
18137          else
18138            predep_objects_CXX="$predep_objects_CXX $p"
18139          fi
18140        else
18141          if test -z "$postdep_objects_CXX"; then
18142            postdep_objects_CXX="$p"
18143          else
18144            postdep_objects_CXX="$postdep_objects_CXX $p"
18145          fi
18146        fi
18147        ;;
18148
18149     *) ;; # Ignore the rest.
18150
18151     esac
18152   done
18153
18154   # Clean up.
18155   rm -f a.out a.exe
18156 else
18157   echo "libtool.m4: error: problem compiling CXX test program"
18158 fi
18159
18160 $rm -f confest.$objext
18161
18162 # PORTME: override above test on systems where it is broken
18163 case $host_os in
18164 interix[3-9]*)
18165   # Interix 3.5 installs completely hosed .la files for C++, so rather than
18166   # hack all around it, let's just trust "g++" to DTRT.
18167   predep_objects_CXX=
18168   postdep_objects_CXX=
18169   postdeps_CXX=
18170   ;;
18171
18172 linux*)
18173   case `$CC -V 2>&1 | sed 5q` in
18174   *Sun\ C*)
18175     # Sun C++ 5.9
18176     #
18177     # The more standards-conforming stlport4 library is
18178     # incompatible with the Cstd library. Avoid specifying
18179     # it if it's in CXXFLAGS. Ignore libCrun as
18180     # -library=stlport4 depends on it.
18181     case " $CXX $CXXFLAGS " in
18182     *" -library=stlport4 "*)
18183       solaris_use_stlport4=yes
18184       ;;
18185     esac
18186     if test "$solaris_use_stlport4" != yes; then
18187       postdeps_CXX='-library=Cstd -library=Crun'
18188     fi
18189     ;;
18190   esac
18191   ;;
18192
18193 solaris*)
18194   case $cc_basename in
18195   CC*)
18196     # The more standards-conforming stlport4 library is
18197     # incompatible with the Cstd library. Avoid specifying
18198     # it if it's in CXXFLAGS. Ignore libCrun as
18199     # -library=stlport4 depends on it.
18200     case " $CXX $CXXFLAGS " in
18201     *" -library=stlport4 "*)
18202       solaris_use_stlport4=yes
18203       ;;
18204     esac
18205
18206     # Adding this requires a known-good setup of shared libraries for
18207     # Sun compiler versions before 5.6, else PIC objects from an old
18208     # archive will be linked into the output, leading to subtle bugs.
18209     if test "$solaris_use_stlport4" != yes; then
18210       postdeps_CXX='-library=Cstd -library=Crun'
18211     fi
18212     ;;
18213   esac
18214   ;;
18215 esac
18216
18217
18218 case " $postdeps_CXX " in
18219 *" -lc "*) archive_cmds_need_lc_CXX=no ;;
18220 esac
18221
18222 lt_prog_compiler_wl_CXX=
18223 lt_prog_compiler_pic_CXX=
18224 lt_prog_compiler_static_CXX=
18225
18226 { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
18227 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; }
18228
18229   # C++ specific cases for pic, static, wl, etc.
18230   if test "$GXX" = yes; then
18231     lt_prog_compiler_wl_CXX='-Wl,'
18232     lt_prog_compiler_static_CXX='-static'
18233
18234     case $host_os in
18235     aix*)
18236       # All AIX code is PIC.
18237       if test "$host_cpu" = ia64; then
18238         # AIX 5 now supports IA64 processor
18239         lt_prog_compiler_static_CXX='-Bstatic'
18240       fi
18241       ;;
18242     amigaos*)
18243       # FIXME: we need at least 68020 code to build shared libraries, but
18244       # adding the `-m68020' flag to GCC prevents building anything better,
18245       # like `-m68040'.
18246       lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4'
18247       ;;
18248     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
18249       # PIC is the default for these OSes.
18250       ;;
18251     mingw* | cygwin* | os2* | pw32*)
18252       # This hack is so that the source file can tell whether it is being
18253       # built for inclusion in a dll (and should export symbols for example).
18254       # Although the cygwin gcc ignores -fPIC, still need this for old-style
18255       # (--disable-auto-import) libraries
18256       lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
18257       ;;
18258     darwin* | rhapsody*)
18259       # PIC is the default on this platform
18260       # Common symbols not allowed in MH_DYLIB files
18261       lt_prog_compiler_pic_CXX='-fno-common'
18262       ;;
18263     *djgpp*)
18264       # DJGPP does not support shared libraries at all
18265       lt_prog_compiler_pic_CXX=
18266       ;;
18267     interix[3-9]*)
18268       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
18269       # Instead, we relocate shared libraries at runtime.
18270       ;;
18271     sysv4*MP*)
18272       if test -d /usr/nec; then
18273         lt_prog_compiler_pic_CXX=-Kconform_pic
18274       fi
18275       ;;
18276     hpux*)
18277       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
18278       # not for PA HP-UX.
18279       case $host_cpu in
18280       hppa*64*|ia64*)
18281         ;;
18282       *)
18283         lt_prog_compiler_pic_CXX='-fPIC'
18284         ;;
18285       esac
18286       ;;
18287     *)
18288       lt_prog_compiler_pic_CXX='-fPIC'
18289       ;;
18290     esac
18291   else
18292     case $host_os in
18293       aix4* | aix5*)
18294         # All AIX code is PIC.
18295         if test "$host_cpu" = ia64; then
18296           # AIX 5 now supports IA64 processor
18297           lt_prog_compiler_static_CXX='-Bstatic'
18298         else
18299           lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp'
18300         fi
18301         ;;
18302       chorus*)
18303         case $cc_basename in
18304         cxch68*)
18305           # Green Hills C++ Compiler
18306           # _LT_AC_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
18307           ;;
18308         esac
18309         ;;
18310        darwin*)
18311          # PIC is the default on this platform
18312          # Common symbols not allowed in MH_DYLIB files
18313          case $cc_basename in
18314            xlc*)
18315            lt_prog_compiler_pic_CXX='-qnocommon'
18316            lt_prog_compiler_wl_CXX='-Wl,'
18317            ;;
18318          esac
18319        ;;
18320       dgux*)
18321         case $cc_basename in
18322           ec++*)
18323             lt_prog_compiler_pic_CXX='-KPIC'
18324             ;;
18325           ghcx*)
18326             # Green Hills C++ Compiler
18327             lt_prog_compiler_pic_CXX='-pic'
18328             ;;
18329           *)
18330             ;;
18331         esac
18332         ;;
18333       freebsd* | dragonfly*)
18334         # FreeBSD uses GNU C++
18335         ;;
18336       hpux9* | hpux10* | hpux11*)
18337         case $cc_basename in
18338           CC*)
18339             lt_prog_compiler_wl_CXX='-Wl,'
18340             lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
18341             if test "$host_cpu" != ia64; then
18342               lt_prog_compiler_pic_CXX='+Z'
18343             fi
18344             ;;
18345           aCC*)
18346             lt_prog_compiler_wl_CXX='-Wl,'
18347             lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
18348             case $host_cpu in
18349             hppa*64*|ia64*)
18350               # +Z the default
18351               ;;
18352             *)
18353               lt_prog_compiler_pic_CXX='+Z'
18354               ;;
18355             esac
18356             ;;
18357           *)
18358             ;;
18359         esac
18360         ;;
18361       interix*)
18362         # This is c89, which is MS Visual C++ (no shared libs)
18363         # Anyone wants to do a port?
18364         ;;
18365       irix5* | irix6* | nonstopux*)
18366         case $cc_basename in
18367           CC*)
18368             lt_prog_compiler_wl_CXX='-Wl,'
18369             lt_prog_compiler_static_CXX='-non_shared'
18370             # CC pic flag -KPIC is the default.
18371             ;;
18372           *)
18373             ;;
18374         esac
18375         ;;
18376       linux* | k*bsd*-gnu)
18377         case $cc_basename in
18378           KCC*)
18379             # KAI C++ Compiler
18380             lt_prog_compiler_wl_CXX='--backend -Wl,'
18381             lt_prog_compiler_pic_CXX='-fPIC'
18382             ;;
18383           icpc* | ecpc*)
18384             # Intel C++
18385             lt_prog_compiler_wl_CXX='-Wl,'
18386             lt_prog_compiler_pic_CXX='-KPIC'
18387             lt_prog_compiler_static_CXX='-static'
18388             ;;
18389           pgCC*)
18390             # Portland Group C++ compiler.
18391             lt_prog_compiler_wl_CXX='-Wl,'
18392             lt_prog_compiler_pic_CXX='-fpic'
18393             lt_prog_compiler_static_CXX='-Bstatic'
18394             ;;
18395           cxx*)
18396             # Compaq C++
18397             # Make sure the PIC flag is empty.  It appears that all Alpha
18398             # Linux and Compaq Tru64 Unix objects are PIC.
18399             lt_prog_compiler_pic_CXX=
18400             lt_prog_compiler_static_CXX='-non_shared'
18401             ;;
18402           *)
18403             case `$CC -V 2>&1 | sed 5q` in
18404             *Sun\ C*)
18405               # Sun C++ 5.9
18406               lt_prog_compiler_pic_CXX='-KPIC'
18407               lt_prog_compiler_static_CXX='-Bstatic'
18408               lt_prog_compiler_wl_CXX='-Qoption ld '
18409               ;;
18410             esac
18411             ;;
18412         esac
18413         ;;
18414       lynxos*)
18415         ;;
18416       m88k*)
18417         ;;
18418       mvs*)
18419         case $cc_basename in
18420           cxx*)
18421             lt_prog_compiler_pic_CXX='-W c,exportall'
18422             ;;
18423           *)
18424             ;;
18425         esac
18426         ;;
18427       netbsd*)
18428         ;;
18429       osf3* | osf4* | osf5*)
18430         case $cc_basename in
18431           KCC*)
18432             lt_prog_compiler_wl_CXX='--backend -Wl,'
18433             ;;
18434           RCC*)
18435             # Rational C++ 2.4.1
18436             lt_prog_compiler_pic_CXX='-pic'
18437             ;;
18438           cxx*)
18439             # Digital/Compaq C++
18440             lt_prog_compiler_wl_CXX='-Wl,'
18441             # Make sure the PIC flag is empty.  It appears that all Alpha
18442             # Linux and Compaq Tru64 Unix objects are PIC.
18443             lt_prog_compiler_pic_CXX=
18444             lt_prog_compiler_static_CXX='-non_shared'
18445             ;;
18446           *)
18447             ;;
18448         esac
18449         ;;
18450       psos*)
18451         ;;
18452       solaris*)
18453         case $cc_basename in
18454           CC*)
18455             # Sun C++ 4.2, 5.x and Centerline C++
18456             lt_prog_compiler_pic_CXX='-KPIC'
18457             lt_prog_compiler_static_CXX='-Bstatic'
18458             lt_prog_compiler_wl_CXX='-Qoption ld '
18459             ;;
18460           gcx*)
18461             # Green Hills C++ Compiler
18462             lt_prog_compiler_pic_CXX='-PIC'
18463             ;;
18464           *)
18465             ;;
18466         esac
18467         ;;
18468       sunos4*)
18469         case $cc_basename in
18470           CC*)
18471             # Sun C++ 4.x
18472             lt_prog_compiler_pic_CXX='-pic'
18473             lt_prog_compiler_static_CXX='-Bstatic'
18474             ;;
18475           lcc*)
18476             # Lucid
18477             lt_prog_compiler_pic_CXX='-pic'
18478             ;;
18479           *)
18480             ;;
18481         esac
18482         ;;
18483       tandem*)
18484         case $cc_basename in
18485           NCC*)
18486             # NonStop-UX NCC 3.20
18487             lt_prog_compiler_pic_CXX='-KPIC'
18488             ;;
18489           *)
18490             ;;
18491         esac
18492         ;;
18493       sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
18494         case $cc_basename in
18495           CC*)
18496             lt_prog_compiler_wl_CXX='-Wl,'
18497             lt_prog_compiler_pic_CXX='-KPIC'
18498             lt_prog_compiler_static_CXX='-Bstatic'
18499             ;;
18500         esac
18501         ;;
18502       vxworks*)
18503         ;;
18504       *)
18505         lt_prog_compiler_can_build_shared_CXX=no
18506         ;;
18507     esac
18508   fi
18509
18510 { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_CXX" >&5
18511 echo "${ECHO_T}$lt_prog_compiler_pic_CXX" >&6; }
18512
18513 #
18514 # Check to make sure the PIC flag actually works.
18515 #
18516 if test -n "$lt_prog_compiler_pic_CXX"; then
18517
18518 { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5
18519 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... $ECHO_C" >&6; }
18520 if test "${lt_prog_compiler_pic_works_CXX+set}" = set; then
18521   echo $ECHO_N "(cached) $ECHO_C" >&6
18522 else
18523   lt_prog_compiler_pic_works_CXX=no
18524   ac_outfile=conftest.$ac_objext
18525    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
18526    lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC"
18527    # Insert the option either (1) after the last *FLAGS variable, or
18528    # (2) before a word containing "conftest.", or (3) at the end.
18529    # Note that $ac_compile itself does not contain backslashes and begins
18530    # with a dollar sign (not a hyphen), so the echo should work correctly.
18531    # The option is referenced via a variable to avoid confusing sed.
18532    lt_compile=`echo "$ac_compile" | $SED \
18533    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
18534    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
18535    -e 's:$: $lt_compiler_flag:'`
18536    (eval echo "\"\$as_me:18536: $lt_compile\"" >&5)
18537    (eval "$lt_compile" 2>conftest.err)
18538    ac_status=$?
18539    cat conftest.err >&5
18540    echo "$as_me:18540: \$? = $ac_status" >&5
18541    if (exit $ac_status) && test -s "$ac_outfile"; then
18542      # The compiler can only warn and ignore the option if not recognized
18543      # So say no if there are warnings other than the usual output.
18544      $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
18545      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
18546      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
18547        lt_prog_compiler_pic_works_CXX=yes
18548      fi
18549    fi
18550    $rm conftest*
18551
18552 fi
18553 { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_CXX" >&5
18554 echo "${ECHO_T}$lt_prog_compiler_pic_works_CXX" >&6; }
18555
18556 if test x"$lt_prog_compiler_pic_works_CXX" = xyes; then
18557     case $lt_prog_compiler_pic_CXX in
18558      "" | " "*) ;;
18559      *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;;
18560      esac
18561 else
18562     lt_prog_compiler_pic_CXX=
18563      lt_prog_compiler_can_build_shared_CXX=no
18564 fi
18565
18566 fi
18567 case $host_os in
18568   # For platforms which do not support PIC, -DPIC is meaningless:
18569   *djgpp*)
18570     lt_prog_compiler_pic_CXX=
18571     ;;
18572   *)
18573     lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC"
18574     ;;
18575 esac
18576
18577 #
18578 # Check to make sure the static flag actually works.
18579 #
18580 wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\"
18581 { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
18582 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; }
18583 if test "${lt_prog_compiler_static_works_CXX+set}" = set; then
18584   echo $ECHO_N "(cached) $ECHO_C" >&6
18585 else
18586   lt_prog_compiler_static_works_CXX=no
18587    save_LDFLAGS="$LDFLAGS"
18588    LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
18589    echo "$lt_simple_link_test_code" > conftest.$ac_ext
18590    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
18591      # The linker can only warn and ignore the option if not recognized
18592      # So say no if there are warnings
18593      if test -s conftest.err; then
18594        # Append any errors to the config.log.
18595        cat conftest.err 1>&5
18596        $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
18597        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
18598        if diff conftest.exp conftest.er2 >/dev/null; then
18599          lt_prog_compiler_static_works_CXX=yes
18600        fi
18601      else
18602        lt_prog_compiler_static_works_CXX=yes
18603      fi
18604    fi
18605    $rm conftest*
18606    LDFLAGS="$save_LDFLAGS"
18607
18608 fi
18609 { echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works_CXX" >&5
18610 echo "${ECHO_T}$lt_prog_compiler_static_works_CXX" >&6; }
18611
18612 if test x"$lt_prog_compiler_static_works_CXX" = xyes; then
18613     :
18614 else
18615     lt_prog_compiler_static_CXX=
18616 fi
18617
18618
18619 { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
18620 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; }
18621 if test "${lt_cv_prog_compiler_c_o_CXX+set}" = set; then
18622   echo $ECHO_N "(cached) $ECHO_C" >&6
18623 else
18624   lt_cv_prog_compiler_c_o_CXX=no
18625    $rm -r conftest 2>/dev/null
18626    mkdir conftest
18627    cd conftest
18628    mkdir out
18629    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
18630
18631    lt_compiler_flag="-o out/conftest2.$ac_objext"
18632    # Insert the option either (1) after the last *FLAGS variable, or
18633    # (2) before a word containing "conftest.", or (3) at the end.
18634    # Note that $ac_compile itself does not contain backslashes and begins
18635    # with a dollar sign (not a hyphen), so the echo should work correctly.
18636    lt_compile=`echo "$ac_compile" | $SED \
18637    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
18638    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
18639    -e 's:$: $lt_compiler_flag:'`
18640    (eval echo "\"\$as_me:18640: $lt_compile\"" >&5)
18641    (eval "$lt_compile" 2>out/conftest.err)
18642    ac_status=$?
18643    cat out/conftest.err >&5
18644    echo "$as_me:18644: \$? = $ac_status" >&5
18645    if (exit $ac_status) && test -s out/conftest2.$ac_objext
18646    then
18647      # The compiler can only warn and ignore the option if not recognized
18648      # So say no if there are warnings
18649      $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
18650      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
18651      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
18652        lt_cv_prog_compiler_c_o_CXX=yes
18653      fi
18654    fi
18655    chmod u+w . 2>&5
18656    $rm conftest*
18657    # SGI C++ compiler will create directory out/ii_files/ for
18658    # template instantiation
18659    test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
18660    $rm out/* && rmdir out
18661    cd ..
18662    rmdir conftest
18663    $rm conftest*
18664
18665 fi
18666 { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_CXX" >&5
18667 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_CXX" >&6; }
18668
18669
18670 hard_links="nottested"
18671 if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then
18672   # do not overwrite the value of need_locks provided by the user
18673   { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
18674 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; }
18675   hard_links=yes
18676   $rm conftest*
18677   ln conftest.a conftest.b 2>/dev/null && hard_links=no
18678   touch conftest.a
18679   ln conftest.a conftest.b 2>&5 || hard_links=no
18680   ln conftest.a conftest.b 2>/dev/null && hard_links=no
18681   { echo "$as_me:$LINENO: result: $hard_links" >&5
18682 echo "${ECHO_T}$hard_links" >&6; }
18683   if test "$hard_links" = no; then
18684     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
18685 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
18686     need_locks=warn
18687   fi
18688 else
18689   need_locks=no
18690 fi
18691
18692 { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
18693 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; }
18694
18695   export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
18696   case $host_os in
18697   aix4* | aix5*)
18698     # If we're using GNU nm, then we don't want the "-C" option.
18699     # -C means demangle to AIX nm, but means don't demangle with GNU nm
18700     if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
18701       export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
18702     else
18703       export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
18704     fi
18705     ;;
18706   pw32*)
18707     export_symbols_cmds_CXX="$ltdll_cmds"
18708   ;;
18709   cygwin* | mingw*)
18710     export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;/^.*[ ]__nm__/s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
18711   ;;
18712   *)
18713     export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
18714   ;;
18715   esac
18716
18717 { echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5
18718 echo "${ECHO_T}$ld_shlibs_CXX" >&6; }
18719 test "$ld_shlibs_CXX" = no && can_build_shared=no
18720
18721 #
18722 # Do we need to explicitly link libc?
18723 #
18724 case "x$archive_cmds_need_lc_CXX" in
18725 x|xyes)
18726   # Assume -lc should be added
18727   archive_cmds_need_lc_CXX=yes
18728
18729   if test "$enable_shared" = yes && test "$GCC" = yes; then
18730     case $archive_cmds_CXX in
18731     *'~'*)
18732       # FIXME: we may have to deal with multi-command sequences.
18733       ;;
18734     '$CC '*)
18735       # Test whether the compiler implicitly links with -lc since on some
18736       # systems, -lgcc has to come before -lc. If gcc already passes -lc
18737       # to ld, don't add -lc before -lgcc.
18738       { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
18739 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; }
18740       $rm conftest*
18741       echo "$lt_simple_compile_test_code" > conftest.$ac_ext
18742
18743       if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18744   (eval $ac_compile) 2>&5
18745   ac_status=$?
18746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18747   (exit $ac_status); } 2>conftest.err; then
18748         soname=conftest
18749         lib=conftest
18750         libobjs=conftest.$ac_objext
18751         deplibs=
18752         wl=$lt_prog_compiler_wl_CXX
18753         pic_flag=$lt_prog_compiler_pic_CXX
18754         compiler_flags=-v
18755         linker_flags=-v
18756         verstring=
18757         output_objdir=.
18758         libname=conftest
18759         lt_save_allow_undefined_flag=$allow_undefined_flag_CXX
18760         allow_undefined_flag_CXX=
18761         if { (eval echo "$as_me:$LINENO: \"$archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5
18762   (eval $archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
18763   ac_status=$?
18764   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18765   (exit $ac_status); }
18766         then
18767           archive_cmds_need_lc_CXX=no
18768         else
18769           archive_cmds_need_lc_CXX=yes
18770         fi
18771         allow_undefined_flag_CXX=$lt_save_allow_undefined_flag
18772       else
18773         cat conftest.err 1>&5
18774       fi
18775       $rm conftest*
18776       { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_CXX" >&5
18777 echo "${ECHO_T}$archive_cmds_need_lc_CXX" >&6; }
18778       ;;
18779     esac
18780   fi
18781   ;;
18782 esac
18783
18784 { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
18785 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; }
18786 library_names_spec=
18787 libname_spec='lib$name'
18788 soname_spec=
18789 shrext_cmds=".so"
18790 postinstall_cmds=
18791 postuninstall_cmds=
18792 finish_cmds=
18793 finish_eval=
18794 shlibpath_var=
18795 shlibpath_overrides_runpath=unknown
18796 version_type=none
18797 dynamic_linker="$host_os ld.so"
18798 sys_lib_dlsearch_path_spec="/lib /usr/lib"
18799
18800 need_lib_prefix=unknown
18801 hardcode_into_libs=no
18802
18803 # when you set need_version to no, make sure it does not cause -set_version
18804 # flags to be left without arguments
18805 need_version=unknown
18806
18807 case $host_os in
18808 aix3*)
18809   version_type=linux
18810   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
18811   shlibpath_var=LIBPATH
18812
18813   # AIX 3 has no versioning support, so we append a major version to the name.
18814   soname_spec='${libname}${release}${shared_ext}$major'
18815   ;;
18816
18817 aix4* | aix5*)
18818   version_type=linux
18819   need_lib_prefix=no
18820   need_version=no
18821   hardcode_into_libs=yes
18822   if test "$host_cpu" = ia64; then
18823     # AIX 5 supports IA64
18824     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
18825     shlibpath_var=LD_LIBRARY_PATH
18826   else
18827     # With GCC up to 2.95.x, collect2 would create an import file
18828     # for dependence libraries.  The import file would start with
18829     # the line `#! .'.  This would cause the generated library to
18830     # depend on `.', always an invalid library.  This was fixed in
18831     # development snapshots of GCC prior to 3.0.
18832     case $host_os in
18833       aix4 | aix4.[01] | aix4.[01].*)
18834       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
18835            echo ' yes '
18836            echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
18837         :
18838       else
18839         can_build_shared=no
18840       fi
18841       ;;
18842     esac
18843     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
18844     # soname into executable. Probably we can add versioning support to
18845     # collect2, so additional links can be useful in future.
18846     if test "$aix_use_runtimelinking" = yes; then
18847       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
18848       # instead of lib<name>.a to let people know that these are not
18849       # typical AIX shared libraries.
18850       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
18851     else
18852       # We preserve .a as extension for shared libraries through AIX4.2
18853       # and later when we are not doing run time linking.
18854       library_names_spec='${libname}${release}.a $libname.a'
18855       soname_spec='${libname}${release}${shared_ext}$major'
18856     fi
18857     shlibpath_var=LIBPATH
18858   fi
18859   ;;
18860
18861 amigaos*)
18862   library_names_spec='$libname.ixlibrary $libname.a'
18863   # Create ${libname}_ixlibrary.a entries in /sys/libs.
18864   finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
18865   ;;
18866
18867 beos*)
18868   library_names_spec='${libname}${shared_ext}'
18869   dynamic_linker="$host_os ld.so"
18870   shlibpath_var=LIBRARY_PATH
18871   ;;
18872
18873 bsdi[45]*)
18874   version_type=linux
18875   need_version=no
18876   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
18877   soname_spec='${libname}${release}${shared_ext}$major'
18878   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
18879   shlibpath_var=LD_LIBRARY_PATH
18880   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
18881   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
18882   # the default ld.so.conf also contains /usr/contrib/lib and
18883   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
18884   # libtool to hard-code these into programs
18885   ;;
18886
18887 cygwin* | mingw* | pw32*)
18888   version_type=windows
18889   shrext_cmds=".dll"
18890   need_version=no
18891   need_lib_prefix=no
18892
18893   case $GCC,$host_os in
18894   yes,cygwin* | yes,mingw* | yes,pw32*)
18895     library_names_spec='$libname.dll.a'
18896     # DLL is installed to $(libdir)/../bin by postinstall_cmds
18897     postinstall_cmds='base_file=`basename \${file}`~
18898       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
18899       dldir=$destdir/`dirname \$dlpath`~
18900       test -d \$dldir || mkdir -p \$dldir~
18901       $install_prog $dir/$dlname \$dldir/$dlname~
18902       chmod a+x \$dldir/$dlname'
18903     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
18904       dlpath=$dir/\$dldll~
18905        $rm \$dlpath'
18906     shlibpath_overrides_runpath=yes
18907
18908     case $host_os in
18909     cygwin*)
18910       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
18911       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
18912       sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
18913       ;;
18914     mingw*)
18915       # MinGW DLLs use traditional 'lib' prefix
18916       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
18917       sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
18918       if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then
18919         # It is most probably a Windows format PATH printed by
18920         # mingw gcc, but we are running on Cygwin. Gcc prints its search
18921         # path with ; separators, and with drive letters. We can handle the
18922         # drive letters (cygwin fileutils understands them), so leave them,
18923         # especially as we might pass files found there to a mingw objdump,
18924         # which wouldn't understand a cygwinified path. Ahh.
18925         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
18926       else
18927         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
18928       fi
18929       ;;
18930     pw32*)
18931       # pw32 DLLs use 'pw' prefix rather than 'lib'
18932       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
18933       ;;
18934     esac
18935     ;;
18936
18937   *)
18938     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
18939     ;;
18940   esac
18941   dynamic_linker='Win32 ld.exe'
18942   # FIXME: first we should search . and the directory the executable is in
18943   shlibpath_var=PATH
18944   ;;
18945
18946 darwin* | rhapsody*)
18947   dynamic_linker="$host_os dyld"
18948   version_type=darwin
18949   need_lib_prefix=no
18950   need_version=no
18951   library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
18952   soname_spec='${libname}${release}${major}$shared_ext'
18953   shlibpath_overrides_runpath=yes
18954   shlibpath_var=DYLD_LIBRARY_PATH
18955   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
18956
18957   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
18958   ;;
18959
18960 dgux*)
18961   version_type=linux
18962   need_lib_prefix=no
18963   need_version=no
18964   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
18965   soname_spec='${libname}${release}${shared_ext}$major'
18966   shlibpath_var=LD_LIBRARY_PATH
18967   ;;
18968
18969 freebsd1*)
18970   dynamic_linker=no
18971   ;;
18972
18973 freebsd* | dragonfly*)
18974   # DragonFly does not have aout.  When/if they implement a new
18975   # versioning mechanism, adjust this.
18976   if test -x /usr/bin/objformat; then
18977     objformat=`/usr/bin/objformat`
18978   else
18979     case $host_os in
18980     freebsd[123]*) objformat=aout ;;
18981     *) objformat=elf ;;
18982     esac
18983   fi
18984   version_type=freebsd-$objformat
18985   case $version_type in
18986     freebsd-elf*)
18987       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
18988       need_version=no
18989       need_lib_prefix=no
18990       ;;
18991     freebsd-*)
18992       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
18993       need_version=yes
18994       ;;
18995   esac
18996   shlibpath_var=LD_LIBRARY_PATH
18997   case $host_os in
18998   freebsd2*)
18999     shlibpath_overrides_runpath=yes
19000     ;;
19001   freebsd3.[01]* | freebsdelf3.[01]*)
19002     shlibpath_overrides_runpath=yes
19003     hardcode_into_libs=yes
19004     ;;
19005   freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
19006   freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
19007     shlibpath_overrides_runpath=no
19008     hardcode_into_libs=yes
19009     ;;
19010   *) # from 4.6 on, and DragonFly
19011     shlibpath_overrides_runpath=yes
19012     hardcode_into_libs=yes
19013     ;;
19014   esac
19015   ;;
19016
19017 gnu*)
19018   version_type=linux
19019   need_lib_prefix=no
19020   need_version=no
19021   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
19022   soname_spec='${libname}${release}${shared_ext}$major'
19023   shlibpath_var=LD_LIBRARY_PATH
19024   hardcode_into_libs=yes
19025   ;;
19026
19027 hpux9* | hpux10* | hpux11*)
19028   # Give a soname corresponding to the major version so that dld.sl refuses to
19029   # link against other versions.
19030   version_type=sunos
19031   need_lib_prefix=no
19032   need_version=no
19033   case $host_cpu in
19034   ia64*)
19035     shrext_cmds='.so'
19036     hardcode_into_libs=yes
19037     dynamic_linker="$host_os dld.so"
19038     shlibpath_var=LD_LIBRARY_PATH
19039     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
19040     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19041     soname_spec='${libname}${release}${shared_ext}$major'
19042     if test "X$HPUX_IA64_MODE" = X32; then
19043       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
19044     else
19045       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
19046     fi
19047     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
19048     ;;
19049    hppa*64*)
19050      shrext_cmds='.sl'
19051      hardcode_into_libs=yes
19052      dynamic_linker="$host_os dld.sl"
19053      shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
19054      shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
19055      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19056      soname_spec='${libname}${release}${shared_ext}$major'
19057      sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
19058      sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
19059      ;;
19060    *)
19061     shrext_cmds='.sl'
19062     dynamic_linker="$host_os dld.sl"
19063     shlibpath_var=SHLIB_PATH
19064     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
19065     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19066     soname_spec='${libname}${release}${shared_ext}$major'
19067     ;;
19068   esac
19069   # HP-UX runs *really* slowly unless shared libraries are mode 555.
19070   postinstall_cmds='chmod 555 $lib'
19071   ;;
19072
19073 interix[3-9]*)
19074   version_type=linux
19075   need_lib_prefix=no
19076   need_version=no
19077   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
19078   soname_spec='${libname}${release}${shared_ext}$major'
19079   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
19080   shlibpath_var=LD_LIBRARY_PATH
19081   shlibpath_overrides_runpath=no
19082   hardcode_into_libs=yes
19083   ;;
19084
19085 irix5* | irix6* | nonstopux*)
19086   case $host_os in
19087     nonstopux*) version_type=nonstopux ;;
19088     *)
19089         if test "$lt_cv_prog_gnu_ld" = yes; then
19090                 version_type=linux
19091         else
19092                 version_type=irix
19093         fi ;;
19094   esac
19095   need_lib_prefix=no
19096   need_version=no
19097   soname_spec='${libname}${release}${shared_ext}$major'
19098   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
19099   case $host_os in
19100   irix5* | nonstopux*)
19101     libsuff= shlibsuff=
19102     ;;
19103   *)
19104     case $LD in # libtool.m4 will add one of these switches to LD
19105     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
19106       libsuff= shlibsuff= libmagic=32-bit;;
19107     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
19108       libsuff=32 shlibsuff=N32 libmagic=N32;;
19109     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
19110       libsuff=64 shlibsuff=64 libmagic=64-bit;;
19111     *) libsuff= shlibsuff= libmagic=never-match;;
19112     esac
19113     ;;
19114   esac
19115   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
19116   shlibpath_overrides_runpath=no
19117   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
19118   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
19119   hardcode_into_libs=yes
19120   ;;
19121
19122 # No shared lib support for Linux oldld, aout, or coff.
19123 linux*oldld* | linux*aout* | linux*coff*)
19124   dynamic_linker=no
19125   ;;
19126
19127 # This must be Linux ELF.
19128 linux* | k*bsd*-gnu)
19129   version_type=linux
19130   need_lib_prefix=no
19131   need_version=no
19132   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19133   soname_spec='${libname}${release}${shared_ext}$major'
19134   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
19135   shlibpath_var=LD_LIBRARY_PATH
19136   shlibpath_overrides_runpath=no
19137   # This implies no fast_install, which is unacceptable.
19138   # Some rework will be needed to allow for fast_install
19139   # before this can be enabled.
19140   hardcode_into_libs=yes
19141
19142   # Append ld.so.conf contents to the search path
19143   if test -f /etc/ld.so.conf; then
19144     lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[      ]*hwcap[        ]/d;s/[:,       ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
19145     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
19146   fi
19147
19148   # We used to test for /lib/ld.so.1 and disable shared libraries on
19149   # powerpc, because MkLinux only supported shared libraries with the
19150   # GNU dynamic linker.  Since this was broken with cross compilers,
19151   # most powerpc-linux boxes support dynamic linking these days and
19152   # people can always --disable-shared, the test was removed, and we
19153   # assume the GNU/Linux dynamic linker is in use.
19154   dynamic_linker='GNU/Linux ld.so'
19155   ;;
19156
19157 netbsd*)
19158   version_type=sunos
19159   need_lib_prefix=no
19160   need_version=no
19161   if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
19162     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
19163     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
19164     dynamic_linker='NetBSD (a.out) ld.so'
19165   else
19166     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
19167     soname_spec='${libname}${release}${shared_ext}$major'
19168     dynamic_linker='NetBSD ld.elf_so'
19169   fi
19170   shlibpath_var=LD_LIBRARY_PATH
19171   shlibpath_overrides_runpath=yes
19172   hardcode_into_libs=yes
19173   ;;
19174
19175 newsos6)
19176   version_type=linux
19177   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19178   shlibpath_var=LD_LIBRARY_PATH
19179   shlibpath_overrides_runpath=yes
19180   ;;
19181
19182 nto-qnx*)
19183   version_type=linux
19184   need_lib_prefix=no
19185   need_version=no
19186   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19187   soname_spec='${libname}${release}${shared_ext}$major'
19188   shlibpath_var=LD_LIBRARY_PATH
19189   shlibpath_overrides_runpath=yes
19190   ;;
19191
19192 openbsd*)
19193   version_type=sunos
19194   sys_lib_dlsearch_path_spec="/usr/lib"
19195   need_lib_prefix=no
19196   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
19197   case $host_os in
19198     openbsd3.3 | openbsd3.3.*) need_version=yes ;;
19199     *)                         need_version=no  ;;
19200   esac
19201   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
19202   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
19203   shlibpath_var=LD_LIBRARY_PATH
19204   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
19205     case $host_os in
19206       openbsd2.[89] | openbsd2.[89].*)
19207         shlibpath_overrides_runpath=no
19208         ;;
19209       *)
19210         shlibpath_overrides_runpath=yes
19211         ;;
19212       esac
19213   else
19214     shlibpath_overrides_runpath=yes
19215   fi
19216   ;;
19217
19218 os2*)
19219   libname_spec='$name'
19220   shrext_cmds=".dll"
19221   need_lib_prefix=no
19222   library_names_spec='$libname${shared_ext} $libname.a'
19223   dynamic_linker='OS/2 ld.exe'
19224   shlibpath_var=LIBPATH
19225   ;;
19226
19227 osf3* | osf4* | osf5*)
19228   version_type=osf
19229   need_lib_prefix=no
19230   need_version=no
19231   soname_spec='${libname}${release}${shared_ext}$major'
19232   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19233   shlibpath_var=LD_LIBRARY_PATH
19234   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
19235   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
19236   ;;
19237
19238 rdos*)
19239   dynamic_linker=no
19240   ;;
19241
19242 solaris*)
19243   version_type=linux
19244   need_lib_prefix=no
19245   need_version=no
19246   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19247   soname_spec='${libname}${release}${shared_ext}$major'
19248   shlibpath_var=LD_LIBRARY_PATH
19249   shlibpath_overrides_runpath=yes
19250   hardcode_into_libs=yes
19251   # ldd complains unless libraries are executable
19252   postinstall_cmds='chmod +x $lib'
19253   ;;
19254
19255 sunos4*)
19256   version_type=sunos
19257   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
19258   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
19259   shlibpath_var=LD_LIBRARY_PATH
19260   shlibpath_overrides_runpath=yes
19261   if test "$with_gnu_ld" = yes; then
19262     need_lib_prefix=no
19263   fi
19264   need_version=yes
19265   ;;
19266
19267 sysv4 | sysv4.3*)
19268   version_type=linux
19269   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19270   soname_spec='${libname}${release}${shared_ext}$major'
19271   shlibpath_var=LD_LIBRARY_PATH
19272   case $host_vendor in
19273     sni)
19274       shlibpath_overrides_runpath=no
19275       need_lib_prefix=no
19276       export_dynamic_flag_spec='${wl}-Blargedynsym'
19277       runpath_var=LD_RUN_PATH
19278       ;;
19279     siemens)
19280       need_lib_prefix=no
19281       ;;
19282     motorola)
19283       need_lib_prefix=no
19284       need_version=no
19285       shlibpath_overrides_runpath=no
19286       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
19287       ;;
19288   esac
19289   ;;
19290
19291 sysv4*MP*)
19292   if test -d /usr/nec ;then
19293     version_type=linux
19294     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
19295     soname_spec='$libname${shared_ext}.$major'
19296     shlibpath_var=LD_LIBRARY_PATH
19297   fi
19298   ;;
19299
19300 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
19301   version_type=freebsd-elf
19302   need_lib_prefix=no
19303   need_version=no
19304   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
19305   soname_spec='${libname}${release}${shared_ext}$major'
19306   shlibpath_var=LD_LIBRARY_PATH
19307   hardcode_into_libs=yes
19308   if test "$with_gnu_ld" = yes; then
19309     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
19310     shlibpath_overrides_runpath=no
19311   else
19312     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
19313     shlibpath_overrides_runpath=yes
19314     case $host_os in
19315       sco3.2v5*)
19316         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
19317         ;;
19318     esac
19319   fi
19320   sys_lib_dlsearch_path_spec='/usr/lib'
19321   ;;
19322
19323 uts4*)
19324   version_type=linux
19325   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
19326   soname_spec='${libname}${release}${shared_ext}$major'
19327   shlibpath_var=LD_LIBRARY_PATH
19328   ;;
19329
19330 *)
19331   dynamic_linker=no
19332   ;;
19333 esac
19334 { echo "$as_me:$LINENO: result: $dynamic_linker" >&5
19335 echo "${ECHO_T}$dynamic_linker" >&6; }
19336 test "$dynamic_linker" = no && can_build_shared=no
19337
19338 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
19339 if test "$GCC" = yes; then
19340   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
19341 fi
19342
19343 { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
19344 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; }
19345 hardcode_action_CXX=
19346 if test -n "$hardcode_libdir_flag_spec_CXX" || \
19347    test -n "$runpath_var_CXX" || \
19348    test "X$hardcode_automatic_CXX" = "Xyes" ; then
19349
19350   # We can hardcode non-existant directories.
19351   if test "$hardcode_direct_CXX" != no &&
19352      # If the only mechanism to avoid hardcoding is shlibpath_var, we
19353      # have to relink, otherwise we might link with an installed library
19354      # when we should be linking with a yet-to-be-installed one
19355      ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, CXX)" != no &&
19356      test "$hardcode_minus_L_CXX" != no; then
19357     # Linking always hardcodes the temporary library directory.
19358     hardcode_action_CXX=relink
19359   else
19360     # We can link without hardcoding, and we can hardcode nonexisting dirs.
19361     hardcode_action_CXX=immediate
19362   fi
19363 else
19364   # We cannot hardcode anything, or else we can only hardcode existing
19365   # directories.
19366   hardcode_action_CXX=unsupported
19367 fi
19368 { echo "$as_me:$LINENO: result: $hardcode_action_CXX" >&5
19369 echo "${ECHO_T}$hardcode_action_CXX" >&6; }
19370
19371 if test "$hardcode_action_CXX" = relink; then
19372   # Fast installation is not supported
19373   enable_fast_install=no
19374 elif test "$shlibpath_overrides_runpath" = yes ||
19375      test "$enable_shared" = no; then
19376   # Fast installation is not necessary
19377   enable_fast_install=needless
19378 fi
19379
19380
19381 # The else clause should only fire when bootstrapping the
19382 # libtool distribution, otherwise you forgot to ship ltmain.sh
19383 # with your package, and you will get complaints that there are
19384 # no rules to generate ltmain.sh.
19385 if test -f "$ltmain"; then
19386   # See if we are running on zsh, and set the options which allow our commands through
19387   # without removal of \ escapes.
19388   if test -n "${ZSH_VERSION+set}" ; then
19389     setopt NO_GLOB_SUBST
19390   fi
19391   # Now quote all the things that may contain metacharacters while being
19392   # careful not to overquote the AC_SUBSTed values.  We take copies of the
19393   # variables and quote the copies for generation of the libtool script.
19394   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
19395     SED SHELL STRIP \
19396     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
19397     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
19398     deplibs_check_method reload_flag reload_cmds need_locks \
19399     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
19400     lt_cv_sys_global_symbol_to_c_name_address \
19401     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
19402     old_postinstall_cmds old_postuninstall_cmds \
19403     compiler_CXX \
19404     CC_CXX \
19405     LD_CXX \
19406     lt_prog_compiler_wl_CXX \
19407     lt_prog_compiler_pic_CXX \
19408     lt_prog_compiler_static_CXX \
19409     lt_prog_compiler_no_builtin_flag_CXX \
19410     export_dynamic_flag_spec_CXX \
19411     thread_safe_flag_spec_CXX \
19412     whole_archive_flag_spec_CXX \
19413     enable_shared_with_static_runtimes_CXX \
19414     old_archive_cmds_CXX \
19415     old_archive_from_new_cmds_CXX \
19416     predep_objects_CXX \
19417     postdep_objects_CXX \
19418     predeps_CXX \
19419     postdeps_CXX \
19420     compiler_lib_search_path_CXX \
19421     archive_cmds_CXX \
19422     archive_expsym_cmds_CXX \
19423     postinstall_cmds_CXX \
19424     postuninstall_cmds_CXX \
19425     old_archive_from_expsyms_cmds_CXX \
19426     allow_undefined_flag_CXX \
19427     no_undefined_flag_CXX \
19428     export_symbols_cmds_CXX \
19429     hardcode_libdir_flag_spec_CXX \
19430     hardcode_libdir_flag_spec_ld_CXX \
19431     hardcode_libdir_separator_CXX \
19432     hardcode_automatic_CXX \
19433     module_cmds_CXX \
19434     module_expsym_cmds_CXX \
19435     lt_cv_prog_compiler_c_o_CXX \
19436     fix_srcfile_path_CXX \
19437     exclude_expsyms_CXX \
19438     include_expsyms_CXX; do
19439
19440     case $var in
19441     old_archive_cmds_CXX | \
19442     old_archive_from_new_cmds_CXX | \
19443     archive_cmds_CXX | \
19444     archive_expsym_cmds_CXX | \
19445     module_cmds_CXX | \
19446     module_expsym_cmds_CXX | \
19447     old_archive_from_expsyms_cmds_CXX | \
19448     export_symbols_cmds_CXX | \
19449     extract_expsyms_cmds | reload_cmds | finish_cmds | \
19450     postinstall_cmds | postuninstall_cmds | \
19451     old_postinstall_cmds | old_postuninstall_cmds | \
19452     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
19453       # Double-quote double-evaled strings.
19454       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
19455       ;;
19456     *)
19457       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
19458       ;;
19459     esac
19460   done
19461
19462   case $lt_echo in
19463   *'\$0 --fallback-echo"')
19464     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
19465     ;;
19466   esac
19467
19468 cfgfile="$ofile"
19469
19470   cat <<__EOF__ >> "$cfgfile"
19471 # ### BEGIN LIBTOOL TAG CONFIG: $tagname
19472
19473 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
19474
19475 # Shell to use when invoking shell scripts.
19476 SHELL=$lt_SHELL
19477
19478 # Whether or not to build shared libraries.
19479 build_libtool_libs=$enable_shared
19480
19481 # Whether or not to build static libraries.
19482 build_old_libs=$enable_static
19483
19484 # Whether or not to add -lc for building shared libraries.
19485 build_libtool_need_lc=$archive_cmds_need_lc_CXX
19486
19487 # Whether or not to disallow shared libs when runtime libs are static
19488 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX
19489
19490 # Whether or not to optimize for fast installation.
19491 fast_install=$enable_fast_install
19492
19493 # The host system.
19494 host_alias=$host_alias
19495 host=$host
19496 host_os=$host_os
19497
19498 # The build system.
19499 build_alias=$build_alias
19500 build=$build
19501 build_os=$build_os
19502
19503 # An echo program that does not interpret backslashes.
19504 echo=$lt_echo
19505
19506 # The archiver.
19507 AR=$lt_AR
19508 AR_FLAGS=$lt_AR_FLAGS
19509
19510 # A C compiler.
19511 LTCC=$lt_LTCC
19512
19513 # LTCC compiler flags.
19514 LTCFLAGS=$lt_LTCFLAGS
19515
19516 # A language-specific compiler.
19517 CC=$lt_compiler_CXX
19518
19519 # Is the compiler the GNU C compiler?
19520 with_gcc=$GCC_CXX
19521
19522 # An ERE matcher.
19523 EGREP=$lt_EGREP
19524
19525 # The linker used to build libraries.
19526 LD=$lt_LD_CXX
19527
19528 # Whether we need hard or soft links.
19529 LN_S=$lt_LN_S
19530
19531 # A BSD-compatible nm program.
19532 NM=$lt_NM
19533
19534 # A symbol stripping program
19535 STRIP=$lt_STRIP
19536
19537 # Used to examine libraries when file_magic_cmd begins "file"
19538 MAGIC_CMD=$MAGIC_CMD
19539
19540 # Used on cygwin: DLL creation program.
19541 DLLTOOL="$DLLTOOL"
19542
19543 # Used on cygwin: object dumper.
19544 OBJDUMP="$OBJDUMP"
19545
19546 # Used on cygwin: assembler.
19547 AS="$AS"
19548
19549 # The name of the directory that contains temporary libtool files.
19550 objdir=$objdir
19551
19552 # How to create reloadable object files.
19553 reload_flag=$lt_reload_flag
19554 reload_cmds=$lt_reload_cmds
19555
19556 # How to pass a linker flag through the compiler.
19557 wl=$lt_lt_prog_compiler_wl_CXX
19558
19559 # Object file suffix (normally "o").
19560 objext="$ac_objext"
19561
19562 # Old archive suffix (normally "a").
19563 libext="$libext"
19564
19565 # Shared library suffix (normally ".so").
19566 shrext_cmds='$shrext_cmds'
19567
19568 # Executable file suffix (normally "").
19569 exeext="$exeext"
19570
19571 # Additional compiler flags for building library objects.
19572 pic_flag=$lt_lt_prog_compiler_pic_CXX
19573 pic_mode=$pic_mode
19574
19575 # What is the maximum length of a command?
19576 max_cmd_len=$lt_cv_sys_max_cmd_len
19577
19578 # Does compiler simultaneously support -c and -o options?
19579 compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX
19580
19581 # Must we lock files when doing compilation?
19582 need_locks=$lt_need_locks
19583
19584 # Do we need the lib prefix for modules?
19585 need_lib_prefix=$need_lib_prefix
19586
19587 # Do we need a version for libraries?
19588 need_version=$need_version
19589
19590 # Whether dlopen is supported.
19591 dlopen_support=$enable_dlopen
19592
19593 # Whether dlopen of programs is supported.
19594 dlopen_self=$enable_dlopen_self
19595
19596 # Whether dlopen of statically linked programs is supported.
19597 dlopen_self_static=$enable_dlopen_self_static
19598
19599 # Compiler flag to prevent dynamic linking.
19600 link_static_flag=$lt_lt_prog_compiler_static_CXX
19601
19602 # Compiler flag to turn off builtin functions.
19603 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX
19604
19605 # Compiler flag to allow reflexive dlopens.
19606 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX
19607
19608 # Compiler flag to generate shared objects directly from archives.
19609 whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX
19610
19611 # Compiler flag to generate thread-safe objects.
19612 thread_safe_flag_spec=$lt_thread_safe_flag_spec_CXX
19613
19614 # Library versioning type.
19615 version_type=$version_type
19616
19617 # Format of library name prefix.
19618 libname_spec=$lt_libname_spec
19619
19620 # List of archive names.  First name is the real one, the rest are links.
19621 # The last name is the one that the linker finds with -lNAME.
19622 library_names_spec=$lt_library_names_spec
19623
19624 # The coded name of the library, if different from the real name.
19625 soname_spec=$lt_soname_spec
19626
19627 # Commands used to build and install an old-style archive.
19628 RANLIB=$lt_RANLIB
19629 old_archive_cmds=$lt_old_archive_cmds_CXX
19630 old_postinstall_cmds=$lt_old_postinstall_cmds
19631 old_postuninstall_cmds=$lt_old_postuninstall_cmds
19632
19633 # Create an old-style archive from a shared archive.
19634 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX
19635
19636 # Create a temporary old-style archive to link instead of a shared archive.
19637 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX
19638
19639 # Commands used to build and install a shared archive.
19640 archive_cmds=$lt_archive_cmds_CXX
19641 archive_expsym_cmds=$lt_archive_expsym_cmds_CXX
19642 postinstall_cmds=$lt_postinstall_cmds
19643 postuninstall_cmds=$lt_postuninstall_cmds
19644
19645 # Commands used to build a loadable module (assumed same as above if empty)
19646 module_cmds=$lt_module_cmds_CXX
19647 module_expsym_cmds=$lt_module_expsym_cmds_CXX
19648
19649 # Commands to strip libraries.
19650 old_striplib=$lt_old_striplib
19651 striplib=$lt_striplib
19652
19653 # Dependencies to place before the objects being linked to create a
19654 # shared library.
19655 predep_objects=$lt_predep_objects_CXX
19656
19657 # Dependencies to place after the objects being linked to create a
19658 # shared library.
19659 postdep_objects=$lt_postdep_objects_CXX
19660
19661 # Dependencies to place before the objects being linked to create a
19662 # shared library.
19663 predeps=$lt_predeps_CXX
19664
19665 # Dependencies to place after the objects being linked to create a
19666 # shared library.
19667 postdeps=$lt_postdeps_CXX
19668
19669 # The library search path used internally by the compiler when linking
19670 # a shared library.
19671 compiler_lib_search_path=$lt_compiler_lib_search_path_CXX
19672
19673 # Method to check whether dependent libraries are shared objects.
19674 deplibs_check_method=$lt_deplibs_check_method
19675
19676 # Command to use when deplibs_check_method == file_magic.
19677 file_magic_cmd=$lt_file_magic_cmd
19678
19679 # Flag that allows shared libraries with undefined symbols to be built.
19680 allow_undefined_flag=$lt_allow_undefined_flag_CXX
19681
19682 # Flag that forces no undefined symbols.
19683 no_undefined_flag=$lt_no_undefined_flag_CXX
19684
19685 # Commands used to finish a libtool library installation in a directory.
19686 finish_cmds=$lt_finish_cmds
19687
19688 # Same as above, but a single script fragment to be evaled but not shown.
19689 finish_eval=$lt_finish_eval
19690
19691 # Take the output of nm and produce a listing of raw symbols and C names.
19692 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
19693
19694 # Transform the output of nm in a proper C declaration
19695 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
19696
19697 # Transform the output of nm in a C name address pair
19698 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
19699
19700 # This is the shared library runtime path variable.
19701 runpath_var=$runpath_var
19702
19703 # This is the shared library path variable.
19704 shlibpath_var=$shlibpath_var
19705
19706 # Is shlibpath searched before the hard-coded library search path?
19707 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
19708
19709 # How to hardcode a shared library path into an executable.
19710 hardcode_action=$hardcode_action_CXX
19711
19712 # Whether we should hardcode library paths into libraries.
19713 hardcode_into_libs=$hardcode_into_libs
19714
19715 # Flag to hardcode \$libdir into a binary during linking.
19716 # This must work even if \$libdir does not exist.
19717 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX
19718
19719 # If ld is used when linking, flag to hardcode \$libdir into
19720 # a binary during linking. This must work even if \$libdir does
19721 # not exist.
19722 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX
19723
19724 # Whether we need a single -rpath flag with a separated argument.
19725 hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX
19726
19727 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
19728 # resulting binary.
19729 hardcode_direct=$hardcode_direct_CXX
19730
19731 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
19732 # resulting binary.
19733 hardcode_minus_L=$hardcode_minus_L_CXX
19734
19735 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
19736 # the resulting binary.
19737 hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX
19738
19739 # Set to yes if building a shared library automatically hardcodes DIR into the library
19740 # and all subsequent libraries and executables linked against it.
19741 hardcode_automatic=$hardcode_automatic_CXX
19742
19743 # Variables whose values should be saved in libtool wrapper scripts and
19744 # restored at relink time.
19745 variables_saved_for_relink="$variables_saved_for_relink"
19746
19747 # Whether libtool must link a program against all its dependency libraries.
19748 link_all_deplibs=$link_all_deplibs_CXX
19749
19750 # Compile-time system search path for libraries
19751 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
19752
19753 # Run-time system search path for libraries
19754 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
19755
19756 # Fix the shell variable \$srcfile for the compiler.
19757 fix_srcfile_path=$lt_fix_srcfile_path
19758
19759 # Set to yes if exported symbols are required.
19760 always_export_symbols=$always_export_symbols_CXX
19761
19762 # The commands to list exported symbols.
19763 export_symbols_cmds=$lt_export_symbols_cmds_CXX
19764
19765 # The commands to extract the exported symbol list from a shared archive.
19766 extract_expsyms_cmds=$lt_extract_expsyms_cmds
19767
19768 # Symbols that should not be listed in the preloaded symbols.
19769 exclude_expsyms=$lt_exclude_expsyms_CXX
19770
19771 # Symbols that must always be exported.
19772 include_expsyms=$lt_include_expsyms_CXX
19773
19774 # ### END LIBTOOL TAG CONFIG: $tagname
19775
19776 __EOF__
19777
19778
19779 else
19780   # If there is no Makefile yet, we rely on a make rule to execute
19781   # `config.status --recheck' to rerun these tests and create the
19782   # libtool script then.
19783   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
19784   if test -f "$ltmain_in"; then
19785     test -f Makefile && make "$ltmain"
19786   fi
19787 fi
19788
19789
19790 ac_ext=c
19791 ac_cpp='$CPP $CPPFLAGS'
19792 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
19793 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
19794 ac_compiler_gnu=$ac_cv_c_compiler_gnu
19795
19796 CC=$lt_save_CC
19797 LDCXX=$LD
19798 LD=$lt_save_LD
19799 GCC=$lt_save_GCC
19800 with_gnu_ldcxx=$with_gnu_ld
19801 with_gnu_ld=$lt_save_with_gnu_ld
19802 lt_cv_path_LDCXX=$lt_cv_path_LD
19803 lt_cv_path_LD=$lt_save_path_LD
19804 lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
19805 lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
19806
19807         else
19808           tagname=""
19809         fi
19810         ;;
19811
19812       F77)
19813         if test -n "$F77" && test "X$F77" != "Xno"; then
19814
19815 ac_ext=f
19816 ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&5'
19817 ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
19818 ac_compiler_gnu=$ac_cv_f77_compiler_gnu
19819
19820
19821 archive_cmds_need_lc_F77=no
19822 allow_undefined_flag_F77=
19823 always_export_symbols_F77=no
19824 archive_expsym_cmds_F77=
19825 export_dynamic_flag_spec_F77=
19826 hardcode_direct_F77=no
19827 hardcode_libdir_flag_spec_F77=
19828 hardcode_libdir_flag_spec_ld_F77=
19829 hardcode_libdir_separator_F77=
19830 hardcode_minus_L_F77=no
19831 hardcode_automatic_F77=no
19832 module_cmds_F77=
19833 module_expsym_cmds_F77=
19834 link_all_deplibs_F77=unknown
19835 old_archive_cmds_F77=$old_archive_cmds
19836 no_undefined_flag_F77=
19837 whole_archive_flag_spec_F77=
19838 enable_shared_with_static_runtimes_F77=no
19839
19840 # Source file extension for f77 test sources.
19841 ac_ext=f
19842
19843 # Object file extension for compiled f77 test sources.
19844 objext=o
19845 objext_F77=$objext
19846
19847 # Code to be used in simple compile tests
19848 lt_simple_compile_test_code="\
19849       subroutine t
19850       return
19851       end
19852 "
19853
19854 # Code to be used in simple link tests
19855 lt_simple_link_test_code="\
19856       program t
19857       end
19858 "
19859
19860 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
19861
19862 # If no C compiler was specified, use CC.
19863 LTCC=${LTCC-"$CC"}
19864
19865 # If no C compiler flags were specified, use CFLAGS.
19866 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
19867
19868 # Allow CC to be a program name with arguments.
19869 compiler=$CC
19870
19871
19872 # save warnings/boilerplate of simple test code
19873 ac_outfile=conftest.$ac_objext
19874 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
19875 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
19876 _lt_compiler_boilerplate=`cat conftest.err`
19877 $rm conftest*
19878
19879 ac_outfile=conftest.$ac_objext
19880 echo "$lt_simple_link_test_code" >conftest.$ac_ext
19881 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
19882 _lt_linker_boilerplate=`cat conftest.err`
19883 $rm conftest*
19884
19885
19886 # Allow CC to be a program name with arguments.
19887 lt_save_CC="$CC"
19888 CC=${F77-"f77"}
19889 compiler=$CC
19890 compiler_F77=$CC
19891 for cc_temp in $compiler""; do
19892   case $cc_temp in
19893     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
19894     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
19895     \-*) ;;
19896     *) break;;
19897   esac
19898 done
19899 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
19900
19901
19902 { echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
19903 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6; }
19904 { echo "$as_me:$LINENO: result: $can_build_shared" >&5
19905 echo "${ECHO_T}$can_build_shared" >&6; }
19906
19907 { echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
19908 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6; }
19909 test "$can_build_shared" = "no" && enable_shared=no
19910
19911 # On AIX, shared libraries and static libraries use the same namespace, and
19912 # are all built from PIC.
19913 case $host_os in
19914 aix3*)
19915   test "$enable_shared" = yes && enable_static=no
19916   if test -n "$RANLIB"; then
19917     archive_cmds="$archive_cmds~\$RANLIB \$lib"
19918     postinstall_cmds='$RANLIB $lib'
19919   fi
19920   ;;
19921 aix4* | aix5*)
19922   if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
19923     test "$enable_shared" = yes && enable_static=no
19924   fi
19925   ;;
19926 esac
19927 { echo "$as_me:$LINENO: result: $enable_shared" >&5
19928 echo "${ECHO_T}$enable_shared" >&6; }
19929
19930 { echo "$as_me:$LINENO: checking whether to build static libraries" >&5
19931 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6; }
19932 # Make sure either enable_shared or enable_static is yes.
19933 test "$enable_shared" = yes || enable_static=yes
19934 { echo "$as_me:$LINENO: result: $enable_static" >&5
19935 echo "${ECHO_T}$enable_static" >&6; }
19936
19937 GCC_F77="$G77"
19938 LD_F77="$LD"
19939
19940 lt_prog_compiler_wl_F77=
19941 lt_prog_compiler_pic_F77=
19942 lt_prog_compiler_static_F77=
19943
19944 { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
19945 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; }
19946
19947   if test "$GCC" = yes; then
19948     lt_prog_compiler_wl_F77='-Wl,'
19949     lt_prog_compiler_static_F77='-static'
19950
19951     case $host_os in
19952       aix*)
19953       # All AIX code is PIC.
19954       if test "$host_cpu" = ia64; then
19955         # AIX 5 now supports IA64 processor
19956         lt_prog_compiler_static_F77='-Bstatic'
19957       fi
19958       ;;
19959
19960     amigaos*)
19961       # FIXME: we need at least 68020 code to build shared libraries, but
19962       # adding the `-m68020' flag to GCC prevents building anything better,
19963       # like `-m68040'.
19964       lt_prog_compiler_pic_F77='-m68020 -resident32 -malways-restore-a4'
19965       ;;
19966
19967     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
19968       # PIC is the default for these OSes.
19969       ;;
19970
19971     mingw* | cygwin* | pw32* | os2*)
19972       # This hack is so that the source file can tell whether it is being
19973       # built for inclusion in a dll (and should export symbols for example).
19974       # Although the cygwin gcc ignores -fPIC, still need this for old-style
19975       # (--disable-auto-import) libraries
19976       lt_prog_compiler_pic_F77='-DDLL_EXPORT'
19977       ;;
19978
19979     darwin* | rhapsody*)
19980       # PIC is the default on this platform
19981       # Common symbols not allowed in MH_DYLIB files
19982       lt_prog_compiler_pic_F77='-fno-common'
19983       ;;
19984
19985     interix[3-9]*)
19986       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
19987       # Instead, we relocate shared libraries at runtime.
19988       ;;
19989
19990     msdosdjgpp*)
19991       # Just because we use GCC doesn't mean we suddenly get shared libraries
19992       # on systems that don't support them.
19993       lt_prog_compiler_can_build_shared_F77=no
19994       enable_shared=no
19995       ;;
19996
19997     sysv4*MP*)
19998       if test -d /usr/nec; then
19999         lt_prog_compiler_pic_F77=-Kconform_pic
20000       fi
20001       ;;
20002
20003     hpux*)
20004       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
20005       # not for PA HP-UX.
20006       case $host_cpu in
20007       hppa*64*|ia64*)
20008         # +Z the default
20009         ;;
20010       *)
20011         lt_prog_compiler_pic_F77='-fPIC'
20012         ;;
20013       esac
20014       ;;
20015
20016     *)
20017       lt_prog_compiler_pic_F77='-fPIC'
20018       ;;
20019     esac
20020   else
20021     # PORTME Check for flag to pass linker flags through the system compiler.
20022     case $host_os in
20023     aix*)
20024       lt_prog_compiler_wl_F77='-Wl,'
20025       if test "$host_cpu" = ia64; then
20026         # AIX 5 now supports IA64 processor
20027         lt_prog_compiler_static_F77='-Bstatic'
20028       else
20029         lt_prog_compiler_static_F77='-bnso -bI:/lib/syscalls.exp'
20030       fi
20031       ;;
20032       darwin*)
20033         # PIC is the default on this platform
20034         # Common symbols not allowed in MH_DYLIB files
20035        case $cc_basename in
20036          xlc*)
20037          lt_prog_compiler_pic_F77='-qnocommon'
20038          lt_prog_compiler_wl_F77='-Wl,'
20039          ;;
20040        esac
20041        ;;
20042
20043     mingw* | cygwin* | pw32* | os2*)
20044       # This hack is so that the source file can tell whether it is being
20045       # built for inclusion in a dll (and should export symbols for example).
20046       lt_prog_compiler_pic_F77='-DDLL_EXPORT'
20047       ;;
20048
20049     hpux9* | hpux10* | hpux11*)
20050       lt_prog_compiler_wl_F77='-Wl,'
20051       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
20052       # not for PA HP-UX.
20053       case $host_cpu in
20054       hppa*64*|ia64*)
20055         # +Z the default
20056         ;;
20057       *)
20058         lt_prog_compiler_pic_F77='+Z'
20059         ;;
20060       esac
20061       # Is there a better lt_prog_compiler_static that works with the bundled CC?
20062       lt_prog_compiler_static_F77='${wl}-a ${wl}archive'
20063       ;;
20064
20065     irix5* | irix6* | nonstopux*)
20066       lt_prog_compiler_wl_F77='-Wl,'
20067       # PIC (with -KPIC) is the default.
20068       lt_prog_compiler_static_F77='-non_shared'
20069       ;;
20070
20071     newsos6)
20072       lt_prog_compiler_pic_F77='-KPIC'
20073       lt_prog_compiler_static_F77='-Bstatic'
20074       ;;
20075
20076     linux* | k*bsd*-gnu)
20077       case $cc_basename in
20078       icc* | ecc*)
20079         lt_prog_compiler_wl_F77='-Wl,'
20080         lt_prog_compiler_pic_F77='-KPIC'
20081         lt_prog_compiler_static_F77='-static'
20082         ;;
20083       pgcc* | pgf77* | pgf90* | pgf95*)
20084         # Portland Group compilers (*not* the Pentium gcc compiler,
20085         # which looks to be a dead project)
20086         lt_prog_compiler_wl_F77='-Wl,'
20087         lt_prog_compiler_pic_F77='-fpic'
20088         lt_prog_compiler_static_F77='-Bstatic'
20089         ;;
20090       ccc*)
20091         lt_prog_compiler_wl_F77='-Wl,'
20092         # All Alpha code is PIC.
20093         lt_prog_compiler_static_F77='-non_shared'
20094         ;;
20095       *)
20096         case `$CC -V 2>&1 | sed 5q` in
20097         *Sun\ C*)
20098           # Sun C 5.9
20099           lt_prog_compiler_pic_F77='-KPIC'
20100           lt_prog_compiler_static_F77='-Bstatic'
20101           lt_prog_compiler_wl_F77='-Wl,'
20102           ;;
20103         *Sun\ F*)
20104           # Sun Fortran 8.3 passes all unrecognized flags to the linker
20105           lt_prog_compiler_pic_F77='-KPIC'
20106           lt_prog_compiler_static_F77='-Bstatic'
20107           lt_prog_compiler_wl_F77=''
20108           ;;
20109         esac
20110         ;;
20111       esac
20112       ;;
20113
20114     osf3* | osf4* | osf5*)
20115       lt_prog_compiler_wl_F77='-Wl,'
20116       # All OSF/1 code is PIC.
20117       lt_prog_compiler_static_F77='-non_shared'
20118       ;;
20119
20120     rdos*)
20121       lt_prog_compiler_static_F77='-non_shared'
20122       ;;
20123
20124     solaris*)
20125       lt_prog_compiler_pic_F77='-KPIC'
20126       lt_prog_compiler_static_F77='-Bstatic'
20127       case $cc_basename in
20128       f77* | f90* | f95*)
20129         lt_prog_compiler_wl_F77='-Qoption ld ';;
20130       *)
20131         lt_prog_compiler_wl_F77='-Wl,';;
20132       esac
20133       ;;
20134
20135     sunos4*)
20136       lt_prog_compiler_wl_F77='-Qoption ld '
20137       lt_prog_compiler_pic_F77='-PIC'
20138       lt_prog_compiler_static_F77='-Bstatic'
20139       ;;
20140
20141     sysv4 | sysv4.2uw2* | sysv4.3*)
20142       lt_prog_compiler_wl_F77='-Wl,'
20143       lt_prog_compiler_pic_F77='-KPIC'
20144       lt_prog_compiler_static_F77='-Bstatic'
20145       ;;
20146
20147     sysv4*MP*)
20148       if test -d /usr/nec ;then
20149         lt_prog_compiler_pic_F77='-Kconform_pic'
20150         lt_prog_compiler_static_F77='-Bstatic'
20151       fi
20152       ;;
20153
20154     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
20155       lt_prog_compiler_wl_F77='-Wl,'
20156       lt_prog_compiler_pic_F77='-KPIC'
20157       lt_prog_compiler_static_F77='-Bstatic'
20158       ;;
20159
20160     unicos*)
20161       lt_prog_compiler_wl_F77='-Wl,'
20162       lt_prog_compiler_can_build_shared_F77=no
20163       ;;
20164
20165     uts4*)
20166       lt_prog_compiler_pic_F77='-pic'
20167       lt_prog_compiler_static_F77='-Bstatic'
20168       ;;
20169
20170     *)
20171       lt_prog_compiler_can_build_shared_F77=no
20172       ;;
20173     esac
20174   fi
20175
20176 { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_F77" >&5
20177 echo "${ECHO_T}$lt_prog_compiler_pic_F77" >&6; }
20178
20179 #
20180 # Check to make sure the PIC flag actually works.
20181 #
20182 if test -n "$lt_prog_compiler_pic_F77"; then
20183
20184 { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works" >&5
20185 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works... $ECHO_C" >&6; }
20186 if test "${lt_prog_compiler_pic_works_F77+set}" = set; then
20187   echo $ECHO_N "(cached) $ECHO_C" >&6
20188 else
20189   lt_prog_compiler_pic_works_F77=no
20190   ac_outfile=conftest.$ac_objext
20191    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
20192    lt_compiler_flag="$lt_prog_compiler_pic_F77"
20193    # Insert the option either (1) after the last *FLAGS variable, or
20194    # (2) before a word containing "conftest.", or (3) at the end.
20195    # Note that $ac_compile itself does not contain backslashes and begins
20196    # with a dollar sign (not a hyphen), so the echo should work correctly.
20197    # The option is referenced via a variable to avoid confusing sed.
20198    lt_compile=`echo "$ac_compile" | $SED \
20199    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
20200    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
20201    -e 's:$: $lt_compiler_flag:'`
20202    (eval echo "\"\$as_me:20202: $lt_compile\"" >&5)
20203    (eval "$lt_compile" 2>conftest.err)
20204    ac_status=$?
20205    cat conftest.err >&5
20206    echo "$as_me:20206: \$? = $ac_status" >&5
20207    if (exit $ac_status) && test -s "$ac_outfile"; then
20208      # The compiler can only warn and ignore the option if not recognized
20209      # So say no if there are warnings other than the usual output.
20210      $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
20211      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
20212      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
20213        lt_prog_compiler_pic_works_F77=yes
20214      fi
20215    fi
20216    $rm conftest*
20217
20218 fi
20219 { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_F77" >&5
20220 echo "${ECHO_T}$lt_prog_compiler_pic_works_F77" >&6; }
20221
20222 if test x"$lt_prog_compiler_pic_works_F77" = xyes; then
20223     case $lt_prog_compiler_pic_F77 in
20224      "" | " "*) ;;
20225      *) lt_prog_compiler_pic_F77=" $lt_prog_compiler_pic_F77" ;;
20226      esac
20227 else
20228     lt_prog_compiler_pic_F77=
20229      lt_prog_compiler_can_build_shared_F77=no
20230 fi
20231
20232 fi
20233 case $host_os in
20234   # For platforms which do not support PIC, -DPIC is meaningless:
20235   *djgpp*)
20236     lt_prog_compiler_pic_F77=
20237     ;;
20238   *)
20239     lt_prog_compiler_pic_F77="$lt_prog_compiler_pic_F77"
20240     ;;
20241 esac
20242
20243 #
20244 # Check to make sure the static flag actually works.
20245 #
20246 wl=$lt_prog_compiler_wl_F77 eval lt_tmp_static_flag=\"$lt_prog_compiler_static_F77\"
20247 { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
20248 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; }
20249 if test "${lt_prog_compiler_static_works_F77+set}" = set; then
20250   echo $ECHO_N "(cached) $ECHO_C" >&6
20251 else
20252   lt_prog_compiler_static_works_F77=no
20253    save_LDFLAGS="$LDFLAGS"
20254    LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
20255    echo "$lt_simple_link_test_code" > conftest.$ac_ext
20256    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
20257      # The linker can only warn and ignore the option if not recognized
20258      # So say no if there are warnings
20259      if test -s conftest.err; then
20260        # Append any errors to the config.log.
20261        cat conftest.err 1>&5
20262        $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
20263        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
20264        if diff conftest.exp conftest.er2 >/dev/null; then
20265          lt_prog_compiler_static_works_F77=yes
20266        fi
20267      else
20268        lt_prog_compiler_static_works_F77=yes
20269      fi
20270    fi
20271    $rm conftest*
20272    LDFLAGS="$save_LDFLAGS"
20273
20274 fi
20275 { echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works_F77" >&5
20276 echo "${ECHO_T}$lt_prog_compiler_static_works_F77" >&6; }
20277
20278 if test x"$lt_prog_compiler_static_works_F77" = xyes; then
20279     :
20280 else
20281     lt_prog_compiler_static_F77=
20282 fi
20283
20284
20285 { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
20286 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; }
20287 if test "${lt_cv_prog_compiler_c_o_F77+set}" = set; then
20288   echo $ECHO_N "(cached) $ECHO_C" >&6
20289 else
20290   lt_cv_prog_compiler_c_o_F77=no
20291    $rm -r conftest 2>/dev/null
20292    mkdir conftest
20293    cd conftest
20294    mkdir out
20295    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
20296
20297    lt_compiler_flag="-o out/conftest2.$ac_objext"
20298    # Insert the option either (1) after the last *FLAGS variable, or
20299    # (2) before a word containing "conftest.", or (3) at the end.
20300    # Note that $ac_compile itself does not contain backslashes and begins
20301    # with a dollar sign (not a hyphen), so the echo should work correctly.
20302    lt_compile=`echo "$ac_compile" | $SED \
20303    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
20304    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
20305    -e 's:$: $lt_compiler_flag:'`
20306    (eval echo "\"\$as_me:20306: $lt_compile\"" >&5)
20307    (eval "$lt_compile" 2>out/conftest.err)
20308    ac_status=$?
20309    cat out/conftest.err >&5
20310    echo "$as_me:20310: \$? = $ac_status" >&5
20311    if (exit $ac_status) && test -s out/conftest2.$ac_objext
20312    then
20313      # The compiler can only warn and ignore the option if not recognized
20314      # So say no if there are warnings
20315      $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
20316      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
20317      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
20318        lt_cv_prog_compiler_c_o_F77=yes
20319      fi
20320    fi
20321    chmod u+w . 2>&5
20322    $rm conftest*
20323    # SGI C++ compiler will create directory out/ii_files/ for
20324    # template instantiation
20325    test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
20326    $rm out/* && rmdir out
20327    cd ..
20328    rmdir conftest
20329    $rm conftest*
20330
20331 fi
20332 { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_F77" >&5
20333 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_F77" >&6; }
20334
20335
20336 hard_links="nottested"
20337 if test "$lt_cv_prog_compiler_c_o_F77" = no && test "$need_locks" != no; then
20338   # do not overwrite the value of need_locks provided by the user
20339   { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
20340 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; }
20341   hard_links=yes
20342   $rm conftest*
20343   ln conftest.a conftest.b 2>/dev/null && hard_links=no
20344   touch conftest.a
20345   ln conftest.a conftest.b 2>&5 || hard_links=no
20346   ln conftest.a conftest.b 2>/dev/null && hard_links=no
20347   { echo "$as_me:$LINENO: result: $hard_links" >&5
20348 echo "${ECHO_T}$hard_links" >&6; }
20349   if test "$hard_links" = no; then
20350     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
20351 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
20352     need_locks=warn
20353   fi
20354 else
20355   need_locks=no
20356 fi
20357
20358 { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
20359 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; }
20360
20361   runpath_var=
20362   allow_undefined_flag_F77=
20363   enable_shared_with_static_runtimes_F77=no
20364   archive_cmds_F77=
20365   archive_expsym_cmds_F77=
20366   old_archive_From_new_cmds_F77=
20367   old_archive_from_expsyms_cmds_F77=
20368   export_dynamic_flag_spec_F77=
20369   whole_archive_flag_spec_F77=
20370   thread_safe_flag_spec_F77=
20371   hardcode_libdir_flag_spec_F77=
20372   hardcode_libdir_flag_spec_ld_F77=
20373   hardcode_libdir_separator_F77=
20374   hardcode_direct_F77=no
20375   hardcode_minus_L_F77=no
20376   hardcode_shlibpath_var_F77=unsupported
20377   link_all_deplibs_F77=unknown
20378   hardcode_automatic_F77=no
20379   module_cmds_F77=
20380   module_expsym_cmds_F77=
20381   always_export_symbols_F77=no
20382   export_symbols_cmds_F77='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
20383   # include_expsyms should be a list of space-separated symbols to be *always*
20384   # included in the symbol list
20385   include_expsyms_F77=
20386   # exclude_expsyms can be an extended regexp of symbols to exclude
20387   # it will be wrapped by ` (' and `)$', so one must not match beginning or
20388   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
20389   # as well as any symbol that contains `d'.
20390   exclude_expsyms_F77="_GLOBAL_OFFSET_TABLE_"
20391   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
20392   # platforms (ab)use it in PIC code, but their linkers get confused if
20393   # the symbol is explicitly referenced.  Since portable code cannot
20394   # rely on this symbol name, it's probably fine to never include it in
20395   # preloaded symbol tables.
20396   extract_expsyms_cmds=
20397   # Just being paranoid about ensuring that cc_basename is set.
20398   for cc_temp in $compiler""; do
20399   case $cc_temp in
20400     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
20401     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
20402     \-*) ;;
20403     *) break;;
20404   esac
20405 done
20406 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
20407
20408   case $host_os in
20409   cygwin* | mingw* | pw32*)
20410     # FIXME: the MSVC++ port hasn't been tested in a loooong time
20411     # When not using gcc, we currently assume that we are using
20412     # Microsoft Visual C++.
20413     if test "$GCC" != yes; then
20414       with_gnu_ld=no
20415     fi
20416     ;;
20417   interix*)
20418     # we just hope/assume this is gcc and not c89 (= MSVC++)
20419     with_gnu_ld=yes
20420     ;;
20421   openbsd*)
20422     with_gnu_ld=no
20423     ;;
20424   esac
20425
20426   ld_shlibs_F77=yes
20427   if test "$with_gnu_ld" = yes; then
20428     # If archive_cmds runs LD, not CC, wlarc should be empty
20429     wlarc='${wl}'
20430
20431     # Set some defaults for GNU ld with shared library support. These
20432     # are reset later if shared libraries are not supported. Putting them
20433     # here allows them to be overridden if necessary.
20434     runpath_var=LD_RUN_PATH
20435     hardcode_libdir_flag_spec_F77='${wl}--rpath ${wl}$libdir'
20436     export_dynamic_flag_spec_F77='${wl}--export-dynamic'
20437     # ancient GNU ld didn't support --whole-archive et. al.
20438     if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
20439         whole_archive_flag_spec_F77="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
20440       else
20441         whole_archive_flag_spec_F77=
20442     fi
20443     supports_anon_versioning=no
20444     case `$LD -v 2>/dev/null` in
20445       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
20446       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
20447       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
20448       *\ 2.11.*) ;; # other 2.11 versions
20449       *) supports_anon_versioning=yes ;;
20450     esac
20451
20452     # See if GNU ld supports shared libraries.
20453     case $host_os in
20454     aix3* | aix4* | aix5*)
20455       # On AIX/PPC, the GNU linker is very broken
20456       if test "$host_cpu" != ia64; then
20457         ld_shlibs_F77=no
20458         cat <<EOF 1>&2
20459
20460 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
20461 *** to be unable to reliably create shared libraries on AIX.
20462 *** Therefore, libtool is disabling shared libraries support.  If you
20463 *** really care for shared libraries, you may want to modify your PATH
20464 *** so that a non-GNU linker is found, and then restart.
20465
20466 EOF
20467       fi
20468       ;;
20469
20470     amigaos*)
20471       archive_cmds_F77='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
20472       hardcode_libdir_flag_spec_F77='-L$libdir'
20473       hardcode_minus_L_F77=yes
20474
20475       # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
20476       # that the semantics of dynamic libraries on AmigaOS, at least up
20477       # to version 4, is to share data among multiple programs linked
20478       # with the same dynamic library.  Since this doesn't match the
20479       # behavior of shared libraries on other platforms, we can't use
20480       # them.
20481       ld_shlibs_F77=no
20482       ;;
20483
20484     beos*)
20485       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
20486         allow_undefined_flag_F77=unsupported
20487         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
20488         # support --undefined.  This deserves some investigation.  FIXME
20489         archive_cmds_F77='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20490       else
20491         ld_shlibs_F77=no
20492       fi
20493       ;;
20494
20495     cygwin* | mingw* | pw32*)
20496       # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, F77) is actually meaningless,
20497       # as there is no search path for DLLs.
20498       hardcode_libdir_flag_spec_F77='-L$libdir'
20499       allow_undefined_flag_F77=unsupported
20500       always_export_symbols_F77=no
20501       enable_shared_with_static_runtimes_F77=yes
20502       export_symbols_cmds_F77='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
20503
20504       if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
20505         archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
20506         # If the export-symbols file already is a .def file (1st line
20507         # is EXPORTS), use it as is; otherwise, prepend...
20508         archive_expsym_cmds_F77='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
20509           cp $export_symbols $output_objdir/$soname.def;
20510         else
20511           echo EXPORTS > $output_objdir/$soname.def;
20512           cat $export_symbols >> $output_objdir/$soname.def;
20513         fi~
20514         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
20515       else
20516         ld_shlibs_F77=no
20517       fi
20518       ;;
20519
20520     interix[3-9]*)
20521       hardcode_direct_F77=no
20522       hardcode_shlibpath_var_F77=no
20523       hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir'
20524       export_dynamic_flag_spec_F77='${wl}-E'
20525       # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
20526       # Instead, shared libraries are loaded at an image base (0x10000000 by
20527       # default) and relocated if they conflict, which is a slow very memory
20528       # consuming and fragmenting process.  To avoid this, we pick a random,
20529       # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
20530       # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
20531       archive_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
20532       archive_expsym_cmds_F77='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
20533       ;;
20534
20535     gnu* | linux* | k*bsd*-gnu)
20536       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
20537         tmp_addflag=
20538         case $cc_basename,$host_cpu in
20539         pgcc*)                          # Portland Group C compiler
20540           whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
20541           tmp_addflag=' $pic_flag'
20542           ;;
20543         pgf77* | pgf90* | pgf95*)       # Portland Group f77 and f90 compilers
20544           whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
20545           tmp_addflag=' $pic_flag -Mnomain' ;;
20546         ecc*,ia64* | icc*,ia64*)                # Intel C compiler on ia64
20547           tmp_addflag=' -i_dynamic' ;;
20548         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
20549           tmp_addflag=' -i_dynamic -nofor_main' ;;
20550         ifc* | ifort*)                  # Intel Fortran compiler
20551           tmp_addflag=' -nofor_main' ;;
20552         esac
20553         case `$CC -V 2>&1 | sed 5q` in
20554         *Sun\ C*)                       # Sun C 5.9
20555           whole_archive_flag_spec_F77='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
20556           tmp_sharedflag='-G' ;;
20557         *Sun\ F*)                       # Sun Fortran 8.3
20558           tmp_sharedflag='-G' ;;
20559         *)
20560           tmp_sharedflag='-shared' ;;
20561         esac
20562         archive_cmds_F77='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20563
20564         if test $supports_anon_versioning = yes; then
20565           archive_expsym_cmds_F77='$echo "{ global:" > $output_objdir/$libname.ver~
20566   cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
20567   $echo "local: *; };" >> $output_objdir/$libname.ver~
20568           $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
20569         fi
20570       else
20571         ld_shlibs_F77=no
20572       fi
20573       ;;
20574
20575     netbsd*)
20576       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
20577         archive_cmds_F77='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
20578         wlarc=
20579       else
20580         archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20581         archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
20582       fi
20583       ;;
20584
20585     solaris*)
20586       if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
20587         ld_shlibs_F77=no
20588         cat <<EOF 1>&2
20589
20590 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
20591 *** create shared libraries on Solaris systems.  Therefore, libtool
20592 *** is disabling shared libraries support.  We urge you to upgrade GNU
20593 *** binutils to release 2.9.1 or newer.  Another option is to modify
20594 *** your PATH or compiler configuration so that the native linker is
20595 *** used, and then restart.
20596
20597 EOF
20598       elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
20599         archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20600         archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
20601       else
20602         ld_shlibs_F77=no
20603       fi
20604       ;;
20605
20606     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
20607       case `$LD -v 2>&1` in
20608         *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
20609         ld_shlibs_F77=no
20610         cat <<_LT_EOF 1>&2
20611
20612 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
20613 *** reliably create shared libraries on SCO systems.  Therefore, libtool
20614 *** is disabling shared libraries support.  We urge you to upgrade GNU
20615 *** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
20616 *** your PATH or compiler configuration so that the native linker is
20617 *** used, and then restart.
20618
20619 _LT_EOF
20620         ;;
20621         *)
20622           if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
20623             hardcode_libdir_flag_spec_F77='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
20624             archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
20625             archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
20626           else
20627             ld_shlibs_F77=no
20628           fi
20629         ;;
20630       esac
20631       ;;
20632
20633     sunos4*)
20634       archive_cmds_F77='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
20635       wlarc=
20636       hardcode_direct_F77=yes
20637       hardcode_shlibpath_var_F77=no
20638       ;;
20639
20640     *)
20641       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
20642         archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20643         archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
20644       else
20645         ld_shlibs_F77=no
20646       fi
20647       ;;
20648     esac
20649
20650     if test "$ld_shlibs_F77" = no; then
20651       runpath_var=
20652       hardcode_libdir_flag_spec_F77=
20653       export_dynamic_flag_spec_F77=
20654       whole_archive_flag_spec_F77=
20655     fi
20656   else
20657     # PORTME fill in a description of your system's linker (not GNU ld)
20658     case $host_os in
20659     aix3*)
20660       allow_undefined_flag_F77=unsupported
20661       always_export_symbols_F77=yes
20662       archive_expsym_cmds_F77='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
20663       # Note: this linker hardcodes the directories in LIBPATH if there
20664       # are no directories specified by -L.
20665       hardcode_minus_L_F77=yes
20666       if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
20667         # Neither direct hardcoding nor static linking is supported with a
20668         # broken collect2.
20669         hardcode_direct_F77=unsupported
20670       fi
20671       ;;
20672
20673     aix4* | aix5*)
20674       if test "$host_cpu" = ia64; then
20675         # On IA64, the linker does run time linking by default, so we don't
20676         # have to do anything special.
20677         aix_use_runtimelinking=no
20678         exp_sym_flag='-Bexport'
20679         no_entry_flag=""
20680       else
20681         # If we're using GNU nm, then we don't want the "-C" option.
20682         # -C means demangle to AIX nm, but means don't demangle with GNU nm
20683         if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
20684           export_symbols_cmds_F77='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
20685         else
20686           export_symbols_cmds_F77='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
20687         fi
20688         aix_use_runtimelinking=no
20689
20690         # Test if we are trying to use run time linking or normal
20691         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
20692         # need to do runtime linking.
20693         case $host_os in aix4.[23]|aix4.[23].*|aix5*)
20694           for ld_flag in $LDFLAGS; do
20695           if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
20696             aix_use_runtimelinking=yes
20697             break
20698           fi
20699           done
20700           ;;
20701         esac
20702
20703         exp_sym_flag='-bexport'
20704         no_entry_flag='-bnoentry'
20705       fi
20706
20707       # When large executables or shared objects are built, AIX ld can
20708       # have problems creating the table of contents.  If linking a library
20709       # or program results in "error TOC overflow" add -mminimal-toc to
20710       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
20711       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
20712
20713       archive_cmds_F77=''
20714       hardcode_direct_F77=yes
20715       hardcode_libdir_separator_F77=':'
20716       link_all_deplibs_F77=yes
20717
20718       if test "$GCC" = yes; then
20719         case $host_os in aix4.[012]|aix4.[012].*)
20720         # We only want to do this on AIX 4.2 and lower, the check
20721         # below for broken collect2 doesn't work under 4.3+
20722           collect2name=`${CC} -print-prog-name=collect2`
20723           if test -f "$collect2name" && \
20724            strings "$collect2name" | grep resolve_lib_name >/dev/null
20725           then
20726           # We have reworked collect2
20727           :
20728           else
20729           # We have old collect2
20730           hardcode_direct_F77=unsupported
20731           # It fails to find uninstalled libraries when the uninstalled
20732           # path is not listed in the libpath.  Setting hardcode_minus_L
20733           # to unsupported forces relinking
20734           hardcode_minus_L_F77=yes
20735           hardcode_libdir_flag_spec_F77='-L$libdir'
20736           hardcode_libdir_separator_F77=
20737           fi
20738           ;;
20739         esac
20740         shared_flag='-shared'
20741         if test "$aix_use_runtimelinking" = yes; then
20742           shared_flag="$shared_flag "'${wl}-G'
20743         fi
20744       else
20745         # not using gcc
20746         if test "$host_cpu" = ia64; then
20747         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
20748         # chokes on -Wl,-G. The following line is correct:
20749           shared_flag='-G'
20750         else
20751           if test "$aix_use_runtimelinking" = yes; then
20752             shared_flag='${wl}-G'
20753           else
20754             shared_flag='${wl}-bM:SRE'
20755           fi
20756         fi
20757       fi
20758
20759       # It seems that -bexpall does not export symbols beginning with
20760       # underscore (_), so it is better to generate a list of symbols to export.
20761       always_export_symbols_F77=yes
20762       if test "$aix_use_runtimelinking" = yes; then
20763         # Warning - without using the other runtime loading flags (-brtl),
20764         # -berok will link without error, but may produce a broken library.
20765         allow_undefined_flag_F77='-berok'
20766        # Determine the default libpath from the value encoded in an empty executable.
20767        cat >conftest.$ac_ext <<_ACEOF
20768       program main
20769
20770       end
20771 _ACEOF
20772 rm -f conftest.$ac_objext conftest$ac_exeext
20773 if { (ac_try="$ac_link"
20774 case "(($ac_try" in
20775   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20776   *) ac_try_echo=$ac_try;;
20777 esac
20778 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20779   (eval "$ac_link") 2>conftest.er1
20780   ac_status=$?
20781   grep -v '^ *+' conftest.er1 >conftest.err
20782   rm -f conftest.er1
20783   cat conftest.err >&5
20784   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20785   (exit $ac_status); } && {
20786          test -z "$ac_f77_werror_flag" ||
20787          test ! -s conftest.err
20788        } && test -s conftest$ac_exeext &&
20789        $as_test_x conftest$ac_exeext; then
20790
20791 lt_aix_libpath_sed='
20792     /Import File Strings/,/^$/ {
20793         /^0/ {
20794             s/^0  *\(.*\)$/\1/
20795             p
20796         }
20797     }'
20798 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20799 # Check for a 64-bit object if we didn't find anything.
20800 if test -z "$aix_libpath"; then
20801   aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20802 fi
20803 else
20804   echo "$as_me: failed program was:" >&5
20805 sed 's/^/| /' conftest.$ac_ext >&5
20806
20807
20808 fi
20809
20810 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20811       conftest$ac_exeext conftest.$ac_ext
20812 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
20813
20814        hardcode_libdir_flag_spec_F77='${wl}-blibpath:$libdir:'"$aix_libpath"
20815         archive_expsym_cmds_F77="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
20816        else
20817         if test "$host_cpu" = ia64; then
20818           hardcode_libdir_flag_spec_F77='${wl}-R $libdir:/usr/lib:/lib'
20819           allow_undefined_flag_F77="-z nodefs"
20820           archive_expsym_cmds_F77="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
20821         else
20822          # Determine the default libpath from the value encoded in an empty executable.
20823          cat >conftest.$ac_ext <<_ACEOF
20824       program main
20825
20826       end
20827 _ACEOF
20828 rm -f conftest.$ac_objext conftest$ac_exeext
20829 if { (ac_try="$ac_link"
20830 case "(($ac_try" in
20831   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20832   *) ac_try_echo=$ac_try;;
20833 esac
20834 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20835   (eval "$ac_link") 2>conftest.er1
20836   ac_status=$?
20837   grep -v '^ *+' conftest.er1 >conftest.err
20838   rm -f conftest.er1
20839   cat conftest.err >&5
20840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20841   (exit $ac_status); } && {
20842          test -z "$ac_f77_werror_flag" ||
20843          test ! -s conftest.err
20844        } && test -s conftest$ac_exeext &&
20845        $as_test_x conftest$ac_exeext; then
20846
20847 lt_aix_libpath_sed='
20848     /Import File Strings/,/^$/ {
20849         /^0/ {
20850             s/^0  *\(.*\)$/\1/
20851             p
20852         }
20853     }'
20854 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20855 # Check for a 64-bit object if we didn't find anything.
20856 if test -z "$aix_libpath"; then
20857   aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20858 fi
20859 else
20860   echo "$as_me: failed program was:" >&5
20861 sed 's/^/| /' conftest.$ac_ext >&5
20862
20863
20864 fi
20865
20866 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20867       conftest$ac_exeext conftest.$ac_ext
20868 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
20869
20870          hardcode_libdir_flag_spec_F77='${wl}-blibpath:$libdir:'"$aix_libpath"
20871           # Warning - without using the other run time loading flags,
20872           # -berok will link without error, but may produce a broken library.
20873           no_undefined_flag_F77=' ${wl}-bernotok'
20874           allow_undefined_flag_F77=' ${wl}-berok'
20875           # Exported symbols can be pulled into shared objects from archives
20876           whole_archive_flag_spec_F77='$convenience'
20877           archive_cmds_need_lc_F77=yes
20878           # This is similar to how AIX traditionally builds its shared libraries.
20879           archive_expsym_cmds_F77="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
20880         fi
20881       fi
20882       ;;
20883
20884     amigaos*)
20885       archive_cmds_F77='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
20886       hardcode_libdir_flag_spec_F77='-L$libdir'
20887       hardcode_minus_L_F77=yes
20888       # see comment about different semantics on the GNU ld section
20889       ld_shlibs_F77=no
20890       ;;
20891
20892     bsdi[45]*)
20893       export_dynamic_flag_spec_F77=-rdynamic
20894       ;;
20895
20896     cygwin* | mingw* | pw32*)
20897       # When not using gcc, we currently assume that we are using
20898       # Microsoft Visual C++.
20899       # hardcode_libdir_flag_spec is actually meaningless, as there is
20900       # no search path for DLLs.
20901       hardcode_libdir_flag_spec_F77=' '
20902       allow_undefined_flag_F77=unsupported
20903       # Tell ltmain to make .lib files, not .a files.
20904       libext=lib
20905       # Tell ltmain to make .dll files, not .so files.
20906       shrext_cmds=".dll"
20907       # FIXME: Setting linknames here is a bad hack.
20908       archive_cmds_F77='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
20909       # The linker will automatically build a .lib file if we build a DLL.
20910       old_archive_From_new_cmds_F77='true'
20911       # FIXME: Should let the user specify the lib program.
20912       old_archive_cmds_F77='lib -OUT:$oldlib$oldobjs$old_deplibs'
20913       fix_srcfile_path_F77='`cygpath -w "$srcfile"`'
20914       enable_shared_with_static_runtimes_F77=yes
20915       ;;
20916
20917     darwin* | rhapsody*)
20918       case $host_os in
20919         rhapsody* | darwin1.[012])
20920          allow_undefined_flag_F77='${wl}-undefined ${wl}suppress'
20921          ;;
20922        *) # Darwin 1.3 on
20923          if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
20924            allow_undefined_flag_F77='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
20925          else
20926            case ${MACOSX_DEPLOYMENT_TARGET} in
20927              10.[012])
20928                allow_undefined_flag_F77='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
20929                ;;
20930              10.*)
20931                allow_undefined_flag_F77='${wl}-undefined ${wl}dynamic_lookup'
20932                ;;
20933            esac
20934          fi
20935          ;;
20936       esac
20937       archive_cmds_need_lc_F77=no
20938       hardcode_direct_F77=no
20939       hardcode_automatic_F77=yes
20940       hardcode_shlibpath_var_F77=unsupported
20941       whole_archive_flag_spec_F77=''
20942       link_all_deplibs_F77=yes
20943     if test "$GCC" = yes ; then
20944         output_verbose_link_cmd='echo'
20945         archive_cmds_F77='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
20946       module_cmds_F77='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
20947       # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
20948       archive_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
20949       module_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
20950     else
20951       case $cc_basename in
20952         xlc*)
20953          output_verbose_link_cmd='echo'
20954          archive_cmds_F77='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
20955          module_cmds_F77='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
20956           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
20957          archive_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
20958           module_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
20959           ;;
20960        *)
20961          ld_shlibs_F77=no
20962           ;;
20963       esac
20964     fi
20965       ;;
20966
20967     dgux*)
20968       archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
20969       hardcode_libdir_flag_spec_F77='-L$libdir'
20970       hardcode_shlibpath_var_F77=no
20971       ;;
20972
20973     freebsd1*)
20974       ld_shlibs_F77=no
20975       ;;
20976
20977     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
20978     # support.  Future versions do this automatically, but an explicit c++rt0.o
20979     # does not break anything, and helps significantly (at the cost of a little
20980     # extra space).
20981     freebsd2.2*)
20982       archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
20983       hardcode_libdir_flag_spec_F77='-R$libdir'
20984       hardcode_direct_F77=yes
20985       hardcode_shlibpath_var_F77=no
20986       ;;
20987
20988     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
20989     freebsd2*)
20990       archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
20991       hardcode_direct_F77=yes
20992       hardcode_minus_L_F77=yes
20993       hardcode_shlibpath_var_F77=no
20994       ;;
20995
20996     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
20997     freebsd* | dragonfly*)
20998       archive_cmds_F77='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
20999       hardcode_libdir_flag_spec_F77='-R$libdir'
21000       hardcode_direct_F77=yes
21001       hardcode_shlibpath_var_F77=no
21002       ;;
21003
21004     hpux9*)
21005       if test "$GCC" = yes; then
21006         archive_cmds_F77='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
21007       else
21008         archive_cmds_F77='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
21009       fi
21010       hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir'
21011       hardcode_libdir_separator_F77=:
21012       hardcode_direct_F77=yes
21013
21014       # hardcode_minus_L: Not really in the search PATH,
21015       # but as the default location of the library.
21016       hardcode_minus_L_F77=yes
21017       export_dynamic_flag_spec_F77='${wl}-E'
21018       ;;
21019
21020     hpux10*)
21021       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
21022         archive_cmds_F77='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
21023       else
21024         archive_cmds_F77='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
21025       fi
21026       if test "$with_gnu_ld" = no; then
21027         hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir'
21028         hardcode_libdir_separator_F77=:
21029
21030         hardcode_direct_F77=yes
21031         export_dynamic_flag_spec_F77='${wl}-E'
21032
21033         # hardcode_minus_L: Not really in the search PATH,
21034         # but as the default location of the library.
21035         hardcode_minus_L_F77=yes
21036       fi
21037       ;;
21038
21039     hpux11*)
21040       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
21041         case $host_cpu in
21042         hppa*64*)
21043           archive_cmds_F77='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
21044           ;;
21045         ia64*)
21046           archive_cmds_F77='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
21047           ;;
21048         *)
21049           archive_cmds_F77='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
21050           ;;
21051         esac
21052       else
21053         case $host_cpu in
21054         hppa*64*)
21055           archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
21056           ;;
21057         ia64*)
21058           archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
21059           ;;
21060         *)
21061           archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
21062           ;;
21063         esac
21064       fi
21065       if test "$with_gnu_ld" = no; then
21066         hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir'
21067         hardcode_libdir_separator_F77=:
21068
21069         case $host_cpu in
21070         hppa*64*|ia64*)
21071           hardcode_libdir_flag_spec_ld_F77='+b $libdir'
21072           hardcode_direct_F77=no
21073           hardcode_shlibpath_var_F77=no
21074           ;;
21075         *)
21076           hardcode_direct_F77=yes
21077           export_dynamic_flag_spec_F77='${wl}-E'
21078
21079           # hardcode_minus_L: Not really in the search PATH,
21080           # but as the default location of the library.
21081           hardcode_minus_L_F77=yes
21082           ;;
21083         esac
21084       fi
21085       ;;
21086
21087     irix5* | irix6* | nonstopux*)
21088       if test "$GCC" = yes; then
21089         archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
21090       else
21091         archive_cmds_F77='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
21092         hardcode_libdir_flag_spec_ld_F77='-rpath $libdir'
21093       fi
21094       hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir'
21095       hardcode_libdir_separator_F77=:
21096       link_all_deplibs_F77=yes
21097       ;;
21098
21099     netbsd*)
21100       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
21101         archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
21102       else
21103         archive_cmds_F77='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
21104       fi
21105       hardcode_libdir_flag_spec_F77='-R$libdir'
21106       hardcode_direct_F77=yes
21107       hardcode_shlibpath_var_F77=no
21108       ;;
21109
21110     newsos6)
21111       archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
21112       hardcode_direct_F77=yes
21113       hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir'
21114       hardcode_libdir_separator_F77=:
21115       hardcode_shlibpath_var_F77=no
21116       ;;
21117
21118     openbsd*)
21119       if test -f /usr/libexec/ld.so; then
21120         hardcode_direct_F77=yes
21121         hardcode_shlibpath_var_F77=no
21122         if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
21123           archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
21124           archive_expsym_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
21125           hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir'
21126           export_dynamic_flag_spec_F77='${wl}-E'
21127         else
21128           case $host_os in
21129            openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
21130              archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
21131              hardcode_libdir_flag_spec_F77='-R$libdir'
21132              ;;
21133            *)
21134              archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
21135              hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir'
21136              ;;
21137           esac
21138         fi
21139       else
21140         ld_shlibs_F77=no
21141       fi
21142       ;;
21143
21144     os2*)
21145       hardcode_libdir_flag_spec_F77='-L$libdir'
21146       hardcode_minus_L_F77=yes
21147       allow_undefined_flag_F77=unsupported
21148       archive_cmds_F77='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
21149       old_archive_From_new_cmds_F77='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
21150       ;;
21151
21152     osf3*)
21153       if test "$GCC" = yes; then
21154         allow_undefined_flag_F77=' ${wl}-expect_unresolved ${wl}\*'
21155         archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
21156       else
21157         allow_undefined_flag_F77=' -expect_unresolved \*'
21158         archive_cmds_F77='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
21159       fi
21160       hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir'
21161       hardcode_libdir_separator_F77=:
21162       ;;
21163
21164     osf4* | osf5*)      # as osf3* with the addition of -msym flag
21165       if test "$GCC" = yes; then
21166         allow_undefined_flag_F77=' ${wl}-expect_unresolved ${wl}\*'
21167         archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
21168         hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir'
21169       else
21170         allow_undefined_flag_F77=' -expect_unresolved \*'
21171         archive_cmds_F77='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
21172         archive_expsym_cmds_F77='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
21173         $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp'
21174
21175         # Both c and cxx compiler support -rpath directly
21176         hardcode_libdir_flag_spec_F77='-rpath $libdir'
21177       fi
21178       hardcode_libdir_separator_F77=:
21179       ;;
21180
21181     solaris*)
21182       no_undefined_flag_F77=' -z text'
21183       if test "$GCC" = yes; then
21184         wlarc='${wl}'
21185         archive_cmds_F77='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
21186         archive_expsym_cmds_F77='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
21187           $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
21188       else
21189         wlarc=''
21190         archive_cmds_F77='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
21191         archive_expsym_cmds_F77='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
21192         $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
21193       fi
21194       hardcode_libdir_flag_spec_F77='-R$libdir'
21195       hardcode_shlibpath_var_F77=no
21196       case $host_os in
21197       solaris2.[0-5] | solaris2.[0-5].*) ;;
21198       *)
21199         # The compiler driver will combine and reorder linker options,
21200         # but understands `-z linker_flag'.  GCC discards it without `$wl',
21201         # but is careful enough not to reorder.
21202         # Supported since Solaris 2.6 (maybe 2.5.1?)
21203         if test "$GCC" = yes; then
21204           whole_archive_flag_spec_F77='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
21205         else
21206           whole_archive_flag_spec_F77='-z allextract$convenience -z defaultextract'
21207         fi
21208         ;;
21209       esac
21210       link_all_deplibs_F77=yes
21211       ;;
21212
21213     sunos4*)
21214       if test "x$host_vendor" = xsequent; then
21215         # Use $CC to link under sequent, because it throws in some extra .o
21216         # files that make .init and .fini sections work.
21217         archive_cmds_F77='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
21218       else
21219         archive_cmds_F77='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
21220       fi
21221       hardcode_libdir_flag_spec_F77='-L$libdir'
21222       hardcode_direct_F77=yes
21223       hardcode_minus_L_F77=yes
21224       hardcode_shlibpath_var_F77=no
21225       ;;
21226
21227     sysv4)
21228       case $host_vendor in
21229         sni)
21230           archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
21231           hardcode_direct_F77=yes # is this really true???
21232         ;;
21233         siemens)
21234           ## LD is ld it makes a PLAMLIB
21235           ## CC just makes a GrossModule.
21236           archive_cmds_F77='$LD -G -o $lib $libobjs $deplibs $linker_flags'
21237           reload_cmds_F77='$CC -r -o $output$reload_objs'
21238           hardcode_direct_F77=no
21239         ;;
21240         motorola)
21241           archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
21242           hardcode_direct_F77=no #Motorola manual says yes, but my tests say they lie
21243         ;;
21244       esac
21245       runpath_var='LD_RUN_PATH'
21246       hardcode_shlibpath_var_F77=no
21247       ;;
21248
21249     sysv4.3*)
21250       archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
21251       hardcode_shlibpath_var_F77=no
21252       export_dynamic_flag_spec_F77='-Bexport'
21253       ;;
21254
21255     sysv4*MP*)
21256       if test -d /usr/nec; then
21257         archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
21258         hardcode_shlibpath_var_F77=no
21259         runpath_var=LD_RUN_PATH
21260         hardcode_runpath_var=yes
21261         ld_shlibs_F77=yes
21262       fi
21263       ;;
21264
21265     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
21266       no_undefined_flag_F77='${wl}-z,text'
21267       archive_cmds_need_lc_F77=no
21268       hardcode_shlibpath_var_F77=no
21269       runpath_var='LD_RUN_PATH'
21270
21271       if test "$GCC" = yes; then
21272         archive_cmds_F77='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21273         archive_expsym_cmds_F77='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21274       else
21275         archive_cmds_F77='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21276         archive_expsym_cmds_F77='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21277       fi
21278       ;;
21279
21280     sysv5* | sco3.2v5* | sco5v6*)
21281       # Note: We can NOT use -z defs as we might desire, because we do not
21282       # link with -lc, and that would cause any symbols used from libc to
21283       # always be unresolved, which means just about no library would
21284       # ever link correctly.  If we're not using GNU ld we use -z text
21285       # though, which does catch some bad symbols but isn't as heavy-handed
21286       # as -z defs.
21287       no_undefined_flag_F77='${wl}-z,text'
21288       allow_undefined_flag_F77='${wl}-z,nodefs'
21289       archive_cmds_need_lc_F77=no
21290       hardcode_shlibpath_var_F77=no
21291       hardcode_libdir_flag_spec_F77='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
21292       hardcode_libdir_separator_F77=':'
21293       link_all_deplibs_F77=yes
21294       export_dynamic_flag_spec_F77='${wl}-Bexport'
21295       runpath_var='LD_RUN_PATH'
21296
21297       if test "$GCC" = yes; then
21298         archive_cmds_F77='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
21299         archive_expsym_cmds_F77='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
21300       else
21301         archive_cmds_F77='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
21302         archive_expsym_cmds_F77='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
21303       fi
21304       ;;
21305
21306     uts4*)
21307       archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
21308       hardcode_libdir_flag_spec_F77='-L$libdir'
21309       hardcode_shlibpath_var_F77=no
21310       ;;
21311
21312     *)
21313       ld_shlibs_F77=no
21314       ;;
21315     esac
21316   fi
21317
21318 { echo "$as_me:$LINENO: result: $ld_shlibs_F77" >&5
21319 echo "${ECHO_T}$ld_shlibs_F77" >&6; }
21320 test "$ld_shlibs_F77" = no && can_build_shared=no
21321
21322 #
21323 # Do we need to explicitly link libc?
21324 #
21325 case "x$archive_cmds_need_lc_F77" in
21326 x|xyes)
21327   # Assume -lc should be added
21328   archive_cmds_need_lc_F77=yes
21329
21330   if test "$enable_shared" = yes && test "$GCC" = yes; then
21331     case $archive_cmds_F77 in
21332     *'~'*)
21333       # FIXME: we may have to deal with multi-command sequences.
21334       ;;
21335     '$CC '*)
21336       # Test whether the compiler implicitly links with -lc since on some
21337       # systems, -lgcc has to come before -lc. If gcc already passes -lc
21338       # to ld, don't add -lc before -lgcc.
21339       { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
21340 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; }
21341       $rm conftest*
21342       echo "$lt_simple_compile_test_code" > conftest.$ac_ext
21343
21344       if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21345   (eval $ac_compile) 2>&5
21346   ac_status=$?
21347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21348   (exit $ac_status); } 2>conftest.err; then
21349         soname=conftest
21350         lib=conftest
21351         libobjs=conftest.$ac_objext
21352         deplibs=
21353         wl=$lt_prog_compiler_wl_F77
21354         pic_flag=$lt_prog_compiler_pic_F77
21355         compiler_flags=-v
21356         linker_flags=-v
21357         verstring=
21358         output_objdir=.
21359         libname=conftest
21360         lt_save_allow_undefined_flag=$allow_undefined_flag_F77
21361         allow_undefined_flag_F77=
21362         if { (eval echo "$as_me:$LINENO: \"$archive_cmds_F77 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5
21363   (eval $archive_cmds_F77 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
21364   ac_status=$?
21365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21366   (exit $ac_status); }
21367         then
21368           archive_cmds_need_lc_F77=no
21369         else
21370           archive_cmds_need_lc_F77=yes
21371         fi
21372         allow_undefined_flag_F77=$lt_save_allow_undefined_flag
21373       else
21374         cat conftest.err 1>&5
21375       fi
21376       $rm conftest*
21377       { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_F77" >&5
21378 echo "${ECHO_T}$archive_cmds_need_lc_F77" >&6; }
21379       ;;
21380     esac
21381   fi
21382   ;;
21383 esac
21384
21385 { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
21386 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; }
21387 library_names_spec=
21388 libname_spec='lib$name'
21389 soname_spec=
21390 shrext_cmds=".so"
21391 postinstall_cmds=
21392 postuninstall_cmds=
21393 finish_cmds=
21394 finish_eval=
21395 shlibpath_var=
21396 shlibpath_overrides_runpath=unknown
21397 version_type=none
21398 dynamic_linker="$host_os ld.so"
21399 sys_lib_dlsearch_path_spec="/lib /usr/lib"
21400
21401 need_lib_prefix=unknown
21402 hardcode_into_libs=no
21403
21404 # when you set need_version to no, make sure it does not cause -set_version
21405 # flags to be left without arguments
21406 need_version=unknown
21407
21408 case $host_os in
21409 aix3*)
21410   version_type=linux
21411   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
21412   shlibpath_var=LIBPATH
21413
21414   # AIX 3 has no versioning support, so we append a major version to the name.
21415   soname_spec='${libname}${release}${shared_ext}$major'
21416   ;;
21417
21418 aix4* | aix5*)
21419   version_type=linux
21420   need_lib_prefix=no
21421   need_version=no
21422   hardcode_into_libs=yes
21423   if test "$host_cpu" = ia64; then
21424     # AIX 5 supports IA64
21425     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
21426     shlibpath_var=LD_LIBRARY_PATH
21427   else
21428     # With GCC up to 2.95.x, collect2 would create an import file
21429     # for dependence libraries.  The import file would start with
21430     # the line `#! .'.  This would cause the generated library to
21431     # depend on `.', always an invalid library.  This was fixed in
21432     # development snapshots of GCC prior to 3.0.
21433     case $host_os in
21434       aix4 | aix4.[01] | aix4.[01].*)
21435       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
21436            echo ' yes '
21437            echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
21438         :
21439       else
21440         can_build_shared=no
21441       fi
21442       ;;
21443     esac
21444     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
21445     # soname into executable. Probably we can add versioning support to
21446     # collect2, so additional links can be useful in future.
21447     if test "$aix_use_runtimelinking" = yes; then
21448       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
21449       # instead of lib<name>.a to let people know that these are not
21450       # typical AIX shared libraries.
21451       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21452     else
21453       # We preserve .a as extension for shared libraries through AIX4.2
21454       # and later when we are not doing run time linking.
21455       library_names_spec='${libname}${release}.a $libname.a'
21456       soname_spec='${libname}${release}${shared_ext}$major'
21457     fi
21458     shlibpath_var=LIBPATH
21459   fi
21460   ;;
21461
21462 amigaos*)
21463   library_names_spec='$libname.ixlibrary $libname.a'
21464   # Create ${libname}_ixlibrary.a entries in /sys/libs.
21465   finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
21466   ;;
21467
21468 beos*)
21469   library_names_spec='${libname}${shared_ext}'
21470   dynamic_linker="$host_os ld.so"
21471   shlibpath_var=LIBRARY_PATH
21472   ;;
21473
21474 bsdi[45]*)
21475   version_type=linux
21476   need_version=no
21477   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21478   soname_spec='${libname}${release}${shared_ext}$major'
21479   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
21480   shlibpath_var=LD_LIBRARY_PATH
21481   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
21482   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
21483   # the default ld.so.conf also contains /usr/contrib/lib and
21484   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
21485   # libtool to hard-code these into programs
21486   ;;
21487
21488 cygwin* | mingw* | pw32*)
21489   version_type=windows
21490   shrext_cmds=".dll"
21491   need_version=no
21492   need_lib_prefix=no
21493
21494   case $GCC,$host_os in
21495   yes,cygwin* | yes,mingw* | yes,pw32*)
21496     library_names_spec='$libname.dll.a'
21497     # DLL is installed to $(libdir)/../bin by postinstall_cmds
21498     postinstall_cmds='base_file=`basename \${file}`~
21499       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
21500       dldir=$destdir/`dirname \$dlpath`~
21501       test -d \$dldir || mkdir -p \$dldir~
21502       $install_prog $dir/$dlname \$dldir/$dlname~
21503       chmod a+x \$dldir/$dlname'
21504     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
21505       dlpath=$dir/\$dldll~
21506        $rm \$dlpath'
21507     shlibpath_overrides_runpath=yes
21508
21509     case $host_os in
21510     cygwin*)
21511       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
21512       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
21513       sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
21514       ;;
21515     mingw*)
21516       # MinGW DLLs use traditional 'lib' prefix
21517       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
21518       sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
21519       if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then
21520         # It is most probably a Windows format PATH printed by
21521         # mingw gcc, but we are running on Cygwin. Gcc prints its search
21522         # path with ; separators, and with drive letters. We can handle the
21523         # drive letters (cygwin fileutils understands them), so leave them,
21524         # especially as we might pass files found there to a mingw objdump,
21525         # which wouldn't understand a cygwinified path. Ahh.
21526         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
21527       else
21528         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
21529       fi
21530       ;;
21531     pw32*)
21532       # pw32 DLLs use 'pw' prefix rather than 'lib'
21533       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
21534       ;;
21535     esac
21536     ;;
21537
21538   *)
21539     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
21540     ;;
21541   esac
21542   dynamic_linker='Win32 ld.exe'
21543   # FIXME: first we should search . and the directory the executable is in
21544   shlibpath_var=PATH
21545   ;;
21546
21547 darwin* | rhapsody*)
21548   dynamic_linker="$host_os dyld"
21549   version_type=darwin
21550   need_lib_prefix=no
21551   need_version=no
21552   library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
21553   soname_spec='${libname}${release}${major}$shared_ext'
21554   shlibpath_overrides_runpath=yes
21555   shlibpath_var=DYLD_LIBRARY_PATH
21556   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
21557
21558   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
21559   ;;
21560
21561 dgux*)
21562   version_type=linux
21563   need_lib_prefix=no
21564   need_version=no
21565   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
21566   soname_spec='${libname}${release}${shared_ext}$major'
21567   shlibpath_var=LD_LIBRARY_PATH
21568   ;;
21569
21570 freebsd1*)
21571   dynamic_linker=no
21572   ;;
21573
21574 freebsd* | dragonfly*)
21575   # DragonFly does not have aout.  When/if they implement a new
21576   # versioning mechanism, adjust this.
21577   if test -x /usr/bin/objformat; then
21578     objformat=`/usr/bin/objformat`
21579   else
21580     case $host_os in
21581     freebsd[123]*) objformat=aout ;;
21582     *) objformat=elf ;;
21583     esac
21584   fi
21585   version_type=freebsd-$objformat
21586   case $version_type in
21587     freebsd-elf*)
21588       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
21589       need_version=no
21590       need_lib_prefix=no
21591       ;;
21592     freebsd-*)
21593       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
21594       need_version=yes
21595       ;;
21596   esac
21597   shlibpath_var=LD_LIBRARY_PATH
21598   case $host_os in
21599   freebsd2*)
21600     shlibpath_overrides_runpath=yes
21601     ;;
21602   freebsd3.[01]* | freebsdelf3.[01]*)
21603     shlibpath_overrides_runpath=yes
21604     hardcode_into_libs=yes
21605     ;;
21606   freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
21607   freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
21608     shlibpath_overrides_runpath=no
21609     hardcode_into_libs=yes
21610     ;;
21611   *) # from 4.6 on, and DragonFly
21612     shlibpath_overrides_runpath=yes
21613     hardcode_into_libs=yes
21614     ;;
21615   esac
21616   ;;
21617
21618 gnu*)
21619   version_type=linux
21620   need_lib_prefix=no
21621   need_version=no
21622   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
21623   soname_spec='${libname}${release}${shared_ext}$major'
21624   shlibpath_var=LD_LIBRARY_PATH
21625   hardcode_into_libs=yes
21626   ;;
21627
21628 hpux9* | hpux10* | hpux11*)
21629   # Give a soname corresponding to the major version so that dld.sl refuses to
21630   # link against other versions.
21631   version_type=sunos
21632   need_lib_prefix=no
21633   need_version=no
21634   case $host_cpu in
21635   ia64*)
21636     shrext_cmds='.so'
21637     hardcode_into_libs=yes
21638     dynamic_linker="$host_os dld.so"
21639     shlibpath_var=LD_LIBRARY_PATH
21640     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
21641     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21642     soname_spec='${libname}${release}${shared_ext}$major'
21643     if test "X$HPUX_IA64_MODE" = X32; then
21644       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
21645     else
21646       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
21647     fi
21648     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
21649     ;;
21650    hppa*64*)
21651      shrext_cmds='.sl'
21652      hardcode_into_libs=yes
21653      dynamic_linker="$host_os dld.sl"
21654      shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
21655      shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
21656      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21657      soname_spec='${libname}${release}${shared_ext}$major'
21658      sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
21659      sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
21660      ;;
21661    *)
21662     shrext_cmds='.sl'
21663     dynamic_linker="$host_os dld.sl"
21664     shlibpath_var=SHLIB_PATH
21665     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
21666     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21667     soname_spec='${libname}${release}${shared_ext}$major'
21668     ;;
21669   esac
21670   # HP-UX runs *really* slowly unless shared libraries are mode 555.
21671   postinstall_cmds='chmod 555 $lib'
21672   ;;
21673
21674 interix[3-9]*)
21675   version_type=linux
21676   need_lib_prefix=no
21677   need_version=no
21678   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
21679   soname_spec='${libname}${release}${shared_ext}$major'
21680   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
21681   shlibpath_var=LD_LIBRARY_PATH
21682   shlibpath_overrides_runpath=no
21683   hardcode_into_libs=yes
21684   ;;
21685
21686 irix5* | irix6* | nonstopux*)
21687   case $host_os in
21688     nonstopux*) version_type=nonstopux ;;
21689     *)
21690         if test "$lt_cv_prog_gnu_ld" = yes; then
21691                 version_type=linux
21692         else
21693                 version_type=irix
21694         fi ;;
21695   esac
21696   need_lib_prefix=no
21697   need_version=no
21698   soname_spec='${libname}${release}${shared_ext}$major'
21699   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
21700   case $host_os in
21701   irix5* | nonstopux*)
21702     libsuff= shlibsuff=
21703     ;;
21704   *)
21705     case $LD in # libtool.m4 will add one of these switches to LD
21706     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
21707       libsuff= shlibsuff= libmagic=32-bit;;
21708     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
21709       libsuff=32 shlibsuff=N32 libmagic=N32;;
21710     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
21711       libsuff=64 shlibsuff=64 libmagic=64-bit;;
21712     *) libsuff= shlibsuff= libmagic=never-match;;
21713     esac
21714     ;;
21715   esac
21716   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
21717   shlibpath_overrides_runpath=no
21718   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
21719   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
21720   hardcode_into_libs=yes
21721   ;;
21722
21723 # No shared lib support for Linux oldld, aout, or coff.
21724 linux*oldld* | linux*aout* | linux*coff*)
21725   dynamic_linker=no
21726   ;;
21727
21728 # This must be Linux ELF.
21729 linux* | k*bsd*-gnu)
21730   version_type=linux
21731   need_lib_prefix=no
21732   need_version=no
21733   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21734   soname_spec='${libname}${release}${shared_ext}$major'
21735   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
21736   shlibpath_var=LD_LIBRARY_PATH
21737   shlibpath_overrides_runpath=no
21738   # This implies no fast_install, which is unacceptable.
21739   # Some rework will be needed to allow for fast_install
21740   # before this can be enabled.
21741   hardcode_into_libs=yes
21742
21743   # Append ld.so.conf contents to the search path
21744   if test -f /etc/ld.so.conf; then
21745     lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[      ]*hwcap[        ]/d;s/[:,       ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
21746     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
21747   fi
21748
21749   # We used to test for /lib/ld.so.1 and disable shared libraries on
21750   # powerpc, because MkLinux only supported shared libraries with the
21751   # GNU dynamic linker.  Since this was broken with cross compilers,
21752   # most powerpc-linux boxes support dynamic linking these days and
21753   # people can always --disable-shared, the test was removed, and we
21754   # assume the GNU/Linux dynamic linker is in use.
21755   dynamic_linker='GNU/Linux ld.so'
21756   ;;
21757
21758 netbsd*)
21759   version_type=sunos
21760   need_lib_prefix=no
21761   need_version=no
21762   if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
21763     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
21764     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
21765     dynamic_linker='NetBSD (a.out) ld.so'
21766   else
21767     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
21768     soname_spec='${libname}${release}${shared_ext}$major'
21769     dynamic_linker='NetBSD ld.elf_so'
21770   fi
21771   shlibpath_var=LD_LIBRARY_PATH
21772   shlibpath_overrides_runpath=yes
21773   hardcode_into_libs=yes
21774   ;;
21775
21776 newsos6)
21777   version_type=linux
21778   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21779   shlibpath_var=LD_LIBRARY_PATH
21780   shlibpath_overrides_runpath=yes
21781   ;;
21782
21783 nto-qnx*)
21784   version_type=linux
21785   need_lib_prefix=no
21786   need_version=no
21787   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21788   soname_spec='${libname}${release}${shared_ext}$major'
21789   shlibpath_var=LD_LIBRARY_PATH
21790   shlibpath_overrides_runpath=yes
21791   ;;
21792
21793 openbsd*)
21794   version_type=sunos
21795   sys_lib_dlsearch_path_spec="/usr/lib"
21796   need_lib_prefix=no
21797   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
21798   case $host_os in
21799     openbsd3.3 | openbsd3.3.*) need_version=yes ;;
21800     *)                         need_version=no  ;;
21801   esac
21802   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
21803   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
21804   shlibpath_var=LD_LIBRARY_PATH
21805   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
21806     case $host_os in
21807       openbsd2.[89] | openbsd2.[89].*)
21808         shlibpath_overrides_runpath=no
21809         ;;
21810       *)
21811         shlibpath_overrides_runpath=yes
21812         ;;
21813       esac
21814   else
21815     shlibpath_overrides_runpath=yes
21816   fi
21817   ;;
21818
21819 os2*)
21820   libname_spec='$name'
21821   shrext_cmds=".dll"
21822   need_lib_prefix=no
21823   library_names_spec='$libname${shared_ext} $libname.a'
21824   dynamic_linker='OS/2 ld.exe'
21825   shlibpath_var=LIBPATH
21826   ;;
21827
21828 osf3* | osf4* | osf5*)
21829   version_type=osf
21830   need_lib_prefix=no
21831   need_version=no
21832   soname_spec='${libname}${release}${shared_ext}$major'
21833   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21834   shlibpath_var=LD_LIBRARY_PATH
21835   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
21836   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
21837   ;;
21838
21839 rdos*)
21840   dynamic_linker=no
21841   ;;
21842
21843 solaris*)
21844   version_type=linux
21845   need_lib_prefix=no
21846   need_version=no
21847   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21848   soname_spec='${libname}${release}${shared_ext}$major'
21849   shlibpath_var=LD_LIBRARY_PATH
21850   shlibpath_overrides_runpath=yes
21851   hardcode_into_libs=yes
21852   # ldd complains unless libraries are executable
21853   postinstall_cmds='chmod +x $lib'
21854   ;;
21855
21856 sunos4*)
21857   version_type=sunos
21858   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
21859   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
21860   shlibpath_var=LD_LIBRARY_PATH
21861   shlibpath_overrides_runpath=yes
21862   if test "$with_gnu_ld" = yes; then
21863     need_lib_prefix=no
21864   fi
21865   need_version=yes
21866   ;;
21867
21868 sysv4 | sysv4.3*)
21869   version_type=linux
21870   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21871   soname_spec='${libname}${release}${shared_ext}$major'
21872   shlibpath_var=LD_LIBRARY_PATH
21873   case $host_vendor in
21874     sni)
21875       shlibpath_overrides_runpath=no
21876       need_lib_prefix=no
21877       export_dynamic_flag_spec='${wl}-Blargedynsym'
21878       runpath_var=LD_RUN_PATH
21879       ;;
21880     siemens)
21881       need_lib_prefix=no
21882       ;;
21883     motorola)
21884       need_lib_prefix=no
21885       need_version=no
21886       shlibpath_overrides_runpath=no
21887       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
21888       ;;
21889   esac
21890   ;;
21891
21892 sysv4*MP*)
21893   if test -d /usr/nec ;then
21894     version_type=linux
21895     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
21896     soname_spec='$libname${shared_ext}.$major'
21897     shlibpath_var=LD_LIBRARY_PATH
21898   fi
21899   ;;
21900
21901 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
21902   version_type=freebsd-elf
21903   need_lib_prefix=no
21904   need_version=no
21905   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
21906   soname_spec='${libname}${release}${shared_ext}$major'
21907   shlibpath_var=LD_LIBRARY_PATH
21908   hardcode_into_libs=yes
21909   if test "$with_gnu_ld" = yes; then
21910     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
21911     shlibpath_overrides_runpath=no
21912   else
21913     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
21914     shlibpath_overrides_runpath=yes
21915     case $host_os in
21916       sco3.2v5*)
21917         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
21918         ;;
21919     esac
21920   fi
21921   sys_lib_dlsearch_path_spec='/usr/lib'
21922   ;;
21923
21924 uts4*)
21925   version_type=linux
21926   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21927   soname_spec='${libname}${release}${shared_ext}$major'
21928   shlibpath_var=LD_LIBRARY_PATH
21929   ;;
21930
21931 *)
21932   dynamic_linker=no
21933   ;;
21934 esac
21935 { echo "$as_me:$LINENO: result: $dynamic_linker" >&5
21936 echo "${ECHO_T}$dynamic_linker" >&6; }
21937 test "$dynamic_linker" = no && can_build_shared=no
21938
21939 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
21940 if test "$GCC" = yes; then
21941   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
21942 fi
21943
21944 { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
21945 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; }
21946 hardcode_action_F77=
21947 if test -n "$hardcode_libdir_flag_spec_F77" || \
21948    test -n "$runpath_var_F77" || \
21949    test "X$hardcode_automatic_F77" = "Xyes" ; then
21950
21951   # We can hardcode non-existant directories.
21952   if test "$hardcode_direct_F77" != no &&
21953      # If the only mechanism to avoid hardcoding is shlibpath_var, we
21954      # have to relink, otherwise we might link with an installed library
21955      # when we should be linking with a yet-to-be-installed one
21956      ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, F77)" != no &&
21957      test "$hardcode_minus_L_F77" != no; then
21958     # Linking always hardcodes the temporary library directory.
21959     hardcode_action_F77=relink
21960   else
21961     # We can link without hardcoding, and we can hardcode nonexisting dirs.
21962     hardcode_action_F77=immediate
21963   fi
21964 else
21965   # We cannot hardcode anything, or else we can only hardcode existing
21966   # directories.
21967   hardcode_action_F77=unsupported
21968 fi
21969 { echo "$as_me:$LINENO: result: $hardcode_action_F77" >&5
21970 echo "${ECHO_T}$hardcode_action_F77" >&6; }
21971
21972 if test "$hardcode_action_F77" = relink; then
21973   # Fast installation is not supported
21974   enable_fast_install=no
21975 elif test "$shlibpath_overrides_runpath" = yes ||
21976      test "$enable_shared" = no; then
21977   # Fast installation is not necessary
21978   enable_fast_install=needless
21979 fi
21980
21981
21982 # The else clause should only fire when bootstrapping the
21983 # libtool distribution, otherwise you forgot to ship ltmain.sh
21984 # with your package, and you will get complaints that there are
21985 # no rules to generate ltmain.sh.
21986 if test -f "$ltmain"; then
21987   # See if we are running on zsh, and set the options which allow our commands through
21988   # without removal of \ escapes.
21989   if test -n "${ZSH_VERSION+set}" ; then
21990     setopt NO_GLOB_SUBST
21991   fi
21992   # Now quote all the things that may contain metacharacters while being
21993   # careful not to overquote the AC_SUBSTed values.  We take copies of the
21994   # variables and quote the copies for generation of the libtool script.
21995   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
21996     SED SHELL STRIP \
21997     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
21998     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
21999     deplibs_check_method reload_flag reload_cmds need_locks \
22000     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
22001     lt_cv_sys_global_symbol_to_c_name_address \
22002     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
22003     old_postinstall_cmds old_postuninstall_cmds \
22004     compiler_F77 \
22005     CC_F77 \
22006     LD_F77 \
22007     lt_prog_compiler_wl_F77 \
22008     lt_prog_compiler_pic_F77 \
22009     lt_prog_compiler_static_F77 \
22010     lt_prog_compiler_no_builtin_flag_F77 \
22011     export_dynamic_flag_spec_F77 \
22012     thread_safe_flag_spec_F77 \
22013     whole_archive_flag_spec_F77 \
22014     enable_shared_with_static_runtimes_F77 \
22015     old_archive_cmds_F77 \
22016     old_archive_from_new_cmds_F77 \
22017     predep_objects_F77 \
22018     postdep_objects_F77 \
22019     predeps_F77 \
22020     postdeps_F77 \
22021     compiler_lib_search_path_F77 \
22022     archive_cmds_F77 \
22023     archive_expsym_cmds_F77 \
22024     postinstall_cmds_F77 \
22025     postuninstall_cmds_F77 \
22026     old_archive_from_expsyms_cmds_F77 \
22027     allow_undefined_flag_F77 \
22028     no_undefined_flag_F77 \
22029     export_symbols_cmds_F77 \
22030     hardcode_libdir_flag_spec_F77 \
22031     hardcode_libdir_flag_spec_ld_F77 \
22032     hardcode_libdir_separator_F77 \
22033     hardcode_automatic_F77 \
22034     module_cmds_F77 \
22035     module_expsym_cmds_F77 \
22036     lt_cv_prog_compiler_c_o_F77 \
22037     fix_srcfile_path_F77 \
22038     exclude_expsyms_F77 \
22039     include_expsyms_F77; do
22040
22041     case $var in
22042     old_archive_cmds_F77 | \
22043     old_archive_from_new_cmds_F77 | \
22044     archive_cmds_F77 | \
22045     archive_expsym_cmds_F77 | \
22046     module_cmds_F77 | \
22047     module_expsym_cmds_F77 | \
22048     old_archive_from_expsyms_cmds_F77 | \
22049     export_symbols_cmds_F77 | \
22050     extract_expsyms_cmds | reload_cmds | finish_cmds | \
22051     postinstall_cmds | postuninstall_cmds | \
22052     old_postinstall_cmds | old_postuninstall_cmds | \
22053     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
22054       # Double-quote double-evaled strings.
22055       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
22056       ;;
22057     *)
22058       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
22059       ;;
22060     esac
22061   done
22062
22063   case $lt_echo in
22064   *'\$0 --fallback-echo"')
22065     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
22066     ;;
22067   esac
22068
22069 cfgfile="$ofile"
22070
22071   cat <<__EOF__ >> "$cfgfile"
22072 # ### BEGIN LIBTOOL TAG CONFIG: $tagname
22073
22074 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
22075
22076 # Shell to use when invoking shell scripts.
22077 SHELL=$lt_SHELL
22078
22079 # Whether or not to build shared libraries.
22080 build_libtool_libs=$enable_shared
22081
22082 # Whether or not to build static libraries.
22083 build_old_libs=$enable_static
22084
22085 # Whether or not to add -lc for building shared libraries.
22086 build_libtool_need_lc=$archive_cmds_need_lc_F77
22087
22088 # Whether or not to disallow shared libs when runtime libs are static
22089 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_F77
22090
22091 # Whether or not to optimize for fast installation.
22092 fast_install=$enable_fast_install
22093
22094 # The host system.
22095 host_alias=$host_alias
22096 host=$host
22097 host_os=$host_os
22098
22099 # The build system.
22100 build_alias=$build_alias
22101 build=$build
22102 build_os=$build_os
22103
22104 # An echo program that does not interpret backslashes.
22105 echo=$lt_echo
22106
22107 # The archiver.
22108 AR=$lt_AR
22109 AR_FLAGS=$lt_AR_FLAGS
22110
22111 # A C compiler.
22112 LTCC=$lt_LTCC
22113
22114 # LTCC compiler flags.
22115 LTCFLAGS=$lt_LTCFLAGS
22116
22117 # A language-specific compiler.
22118 CC=$lt_compiler_F77
22119
22120 # Is the compiler the GNU C compiler?
22121 with_gcc=$GCC_F77
22122
22123 # An ERE matcher.
22124 EGREP=$lt_EGREP
22125
22126 # The linker used to build libraries.
22127 LD=$lt_LD_F77
22128
22129 # Whether we need hard or soft links.
22130 LN_S=$lt_LN_S
22131
22132 # A BSD-compatible nm program.
22133 NM=$lt_NM
22134
22135 # A symbol stripping program
22136 STRIP=$lt_STRIP
22137
22138 # Used to examine libraries when file_magic_cmd begins "file"
22139 MAGIC_CMD=$MAGIC_CMD
22140
22141 # Used on cygwin: DLL creation program.
22142 DLLTOOL="$DLLTOOL"
22143
22144 # Used on cygwin: object dumper.
22145 OBJDUMP="$OBJDUMP"
22146
22147 # Used on cygwin: assembler.
22148 AS="$AS"
22149
22150 # The name of the directory that contains temporary libtool files.
22151 objdir=$objdir
22152
22153 # How to create reloadable object files.
22154 reload_flag=$lt_reload_flag
22155 reload_cmds=$lt_reload_cmds
22156
22157 # How to pass a linker flag through the compiler.
22158 wl=$lt_lt_prog_compiler_wl_F77
22159
22160 # Object file suffix (normally "o").
22161 objext="$ac_objext"
22162
22163 # Old archive suffix (normally "a").
22164 libext="$libext"
22165
22166 # Shared library suffix (normally ".so").
22167 shrext_cmds='$shrext_cmds'
22168
22169 # Executable file suffix (normally "").
22170 exeext="$exeext"
22171
22172 # Additional compiler flags for building library objects.
22173 pic_flag=$lt_lt_prog_compiler_pic_F77
22174 pic_mode=$pic_mode
22175
22176 # What is the maximum length of a command?
22177 max_cmd_len=$lt_cv_sys_max_cmd_len
22178
22179 # Does compiler simultaneously support -c and -o options?
22180 compiler_c_o=$lt_lt_cv_prog_compiler_c_o_F77
22181
22182 # Must we lock files when doing compilation?
22183 need_locks=$lt_need_locks
22184
22185 # Do we need the lib prefix for modules?
22186 need_lib_prefix=$need_lib_prefix
22187
22188 # Do we need a version for libraries?
22189 need_version=$need_version
22190
22191 # Whether dlopen is supported.
22192 dlopen_support=$enable_dlopen
22193
22194 # Whether dlopen of programs is supported.
22195 dlopen_self=$enable_dlopen_self
22196
22197 # Whether dlopen of statically linked programs is supported.
22198 dlopen_self_static=$enable_dlopen_self_static
22199
22200 # Compiler flag to prevent dynamic linking.
22201 link_static_flag=$lt_lt_prog_compiler_static_F77
22202
22203 # Compiler flag to turn off builtin functions.
22204 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_F77
22205
22206 # Compiler flag to allow reflexive dlopens.
22207 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_F77
22208
22209 # Compiler flag to generate shared objects directly from archives.
22210 whole_archive_flag_spec=$lt_whole_archive_flag_spec_F77
22211
22212 # Compiler flag to generate thread-safe objects.
22213 thread_safe_flag_spec=$lt_thread_safe_flag_spec_F77
22214
22215 # Library versioning type.
22216 version_type=$version_type
22217
22218 # Format of library name prefix.
22219 libname_spec=$lt_libname_spec
22220
22221 # List of archive names.  First name is the real one, the rest are links.
22222 # The last name is the one that the linker finds with -lNAME.
22223 library_names_spec=$lt_library_names_spec
22224
22225 # The coded name of the library, if different from the real name.
22226 soname_spec=$lt_soname_spec
22227
22228 # Commands used to build and install an old-style archive.
22229 RANLIB=$lt_RANLIB
22230 old_archive_cmds=$lt_old_archive_cmds_F77
22231 old_postinstall_cmds=$lt_old_postinstall_cmds
22232 old_postuninstall_cmds=$lt_old_postuninstall_cmds
22233
22234 # Create an old-style archive from a shared archive.
22235 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_F77
22236
22237 # Create a temporary old-style archive to link instead of a shared archive.
22238 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_F77
22239
22240 # Commands used to build and install a shared archive.
22241 archive_cmds=$lt_archive_cmds_F77
22242 archive_expsym_cmds=$lt_archive_expsym_cmds_F77
22243 postinstall_cmds=$lt_postinstall_cmds
22244 postuninstall_cmds=$lt_postuninstall_cmds
22245
22246 # Commands used to build a loadable module (assumed same as above if empty)
22247 module_cmds=$lt_module_cmds_F77
22248 module_expsym_cmds=$lt_module_expsym_cmds_F77
22249
22250 # Commands to strip libraries.
22251 old_striplib=$lt_old_striplib
22252 striplib=$lt_striplib
22253
22254 # Dependencies to place before the objects being linked to create a
22255 # shared library.
22256 predep_objects=$lt_predep_objects_F77
22257
22258 # Dependencies to place after the objects being linked to create a
22259 # shared library.
22260 postdep_objects=$lt_postdep_objects_F77
22261
22262 # Dependencies to place before the objects being linked to create a
22263 # shared library.
22264 predeps=$lt_predeps_F77
22265
22266 # Dependencies to place after the objects being linked to create a
22267 # shared library.
22268 postdeps=$lt_postdeps_F77
22269
22270 # The library search path used internally by the compiler when linking
22271 # a shared library.
22272 compiler_lib_search_path=$lt_compiler_lib_search_path_F77
22273
22274 # Method to check whether dependent libraries are shared objects.
22275 deplibs_check_method=$lt_deplibs_check_method
22276
22277 # Command to use when deplibs_check_method == file_magic.
22278 file_magic_cmd=$lt_file_magic_cmd
22279
22280 # Flag that allows shared libraries with undefined symbols to be built.
22281 allow_undefined_flag=$lt_allow_undefined_flag_F77
22282
22283 # Flag that forces no undefined symbols.
22284 no_undefined_flag=$lt_no_undefined_flag_F77
22285
22286 # Commands used to finish a libtool library installation in a directory.
22287 finish_cmds=$lt_finish_cmds
22288
22289 # Same as above, but a single script fragment to be evaled but not shown.
22290 finish_eval=$lt_finish_eval
22291
22292 # Take the output of nm and produce a listing of raw symbols and C names.
22293 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
22294
22295 # Transform the output of nm in a proper C declaration
22296 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
22297
22298 # Transform the output of nm in a C name address pair
22299 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
22300
22301 # This is the shared library runtime path variable.
22302 runpath_var=$runpath_var
22303
22304 # This is the shared library path variable.
22305 shlibpath_var=$shlibpath_var
22306
22307 # Is shlibpath searched before the hard-coded library search path?
22308 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
22309
22310 # How to hardcode a shared library path into an executable.
22311 hardcode_action=$hardcode_action_F77
22312
22313 # Whether we should hardcode library paths into libraries.
22314 hardcode_into_libs=$hardcode_into_libs
22315
22316 # Flag to hardcode \$libdir into a binary during linking.
22317 # This must work even if \$libdir does not exist.
22318 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_F77
22319
22320 # If ld is used when linking, flag to hardcode \$libdir into
22321 # a binary during linking. This must work even if \$libdir does
22322 # not exist.
22323 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_F77
22324
22325 # Whether we need a single -rpath flag with a separated argument.
22326 hardcode_libdir_separator=$lt_hardcode_libdir_separator_F77
22327
22328 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
22329 # resulting binary.
22330 hardcode_direct=$hardcode_direct_F77
22331
22332 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
22333 # resulting binary.
22334 hardcode_minus_L=$hardcode_minus_L_F77
22335
22336 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
22337 # the resulting binary.
22338 hardcode_shlibpath_var=$hardcode_shlibpath_var_F77
22339
22340 # Set to yes if building a shared library automatically hardcodes DIR into the library
22341 # and all subsequent libraries and executables linked against it.
22342 hardcode_automatic=$hardcode_automatic_F77
22343
22344 # Variables whose values should be saved in libtool wrapper scripts and
22345 # restored at relink time.
22346 variables_saved_for_relink="$variables_saved_for_relink"
22347
22348 # Whether libtool must link a program against all its dependency libraries.
22349 link_all_deplibs=$link_all_deplibs_F77
22350
22351 # Compile-time system search path for libraries
22352 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
22353
22354 # Run-time system search path for libraries
22355 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
22356
22357 # Fix the shell variable \$srcfile for the compiler.
22358 fix_srcfile_path=$lt_fix_srcfile_path
22359
22360 # Set to yes if exported symbols are required.
22361 always_export_symbols=$always_export_symbols_F77
22362
22363 # The commands to list exported symbols.
22364 export_symbols_cmds=$lt_export_symbols_cmds_F77
22365
22366 # The commands to extract the exported symbol list from a shared archive.
22367 extract_expsyms_cmds=$lt_extract_expsyms_cmds
22368
22369 # Symbols that should not be listed in the preloaded symbols.
22370 exclude_expsyms=$lt_exclude_expsyms_F77
22371
22372 # Symbols that must always be exported.
22373 include_expsyms=$lt_include_expsyms_F77
22374
22375 # ### END LIBTOOL TAG CONFIG: $tagname
22376
22377 __EOF__
22378
22379
22380 else
22381   # If there is no Makefile yet, we rely on a make rule to execute
22382   # `config.status --recheck' to rerun these tests and create the
22383   # libtool script then.
22384   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
22385   if test -f "$ltmain_in"; then
22386     test -f Makefile && make "$ltmain"
22387   fi
22388 fi
22389
22390
22391 ac_ext=c
22392 ac_cpp='$CPP $CPPFLAGS'
22393 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22394 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22395 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22396
22397 CC="$lt_save_CC"
22398
22399         else
22400           tagname=""
22401         fi
22402         ;;
22403
22404       GCJ)
22405         if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
22406
22407
22408 # Source file extension for Java test sources.
22409 ac_ext=java
22410
22411 # Object file extension for compiled Java test sources.
22412 objext=o
22413 objext_GCJ=$objext
22414
22415 # Code to be used in simple compile tests
22416 lt_simple_compile_test_code="class foo {}"
22417
22418 # Code to be used in simple link tests
22419 lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }'
22420
22421 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
22422
22423 # If no C compiler was specified, use CC.
22424 LTCC=${LTCC-"$CC"}
22425
22426 # If no C compiler flags were specified, use CFLAGS.
22427 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
22428
22429 # Allow CC to be a program name with arguments.
22430 compiler=$CC
22431
22432
22433 # save warnings/boilerplate of simple test code
22434 ac_outfile=conftest.$ac_objext
22435 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
22436 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
22437 _lt_compiler_boilerplate=`cat conftest.err`
22438 $rm conftest*
22439
22440 ac_outfile=conftest.$ac_objext
22441 echo "$lt_simple_link_test_code" >conftest.$ac_ext
22442 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
22443 _lt_linker_boilerplate=`cat conftest.err`
22444 $rm conftest*
22445
22446
22447 # Allow CC to be a program name with arguments.
22448 lt_save_CC="$CC"
22449 CC=${GCJ-"gcj"}
22450 compiler=$CC
22451 compiler_GCJ=$CC
22452 for cc_temp in $compiler""; do
22453   case $cc_temp in
22454     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
22455     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
22456     \-*) ;;
22457     *) break;;
22458   esac
22459 done
22460 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
22461
22462
22463 # GCJ did not exist at the time GCC didn't implicitly link libc in.
22464 archive_cmds_need_lc_GCJ=no
22465
22466 old_archive_cmds_GCJ=$old_archive_cmds
22467
22468
22469 lt_prog_compiler_no_builtin_flag_GCJ=
22470
22471 if test "$GCC" = yes; then
22472   lt_prog_compiler_no_builtin_flag_GCJ=' -fno-builtin'
22473
22474
22475 { echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
22476 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6; }
22477 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then
22478   echo $ECHO_N "(cached) $ECHO_C" >&6
22479 else
22480   lt_cv_prog_compiler_rtti_exceptions=no
22481   ac_outfile=conftest.$ac_objext
22482    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
22483    lt_compiler_flag="-fno-rtti -fno-exceptions"
22484    # Insert the option either (1) after the last *FLAGS variable, or
22485    # (2) before a word containing "conftest.", or (3) at the end.
22486    # Note that $ac_compile itself does not contain backslashes and begins
22487    # with a dollar sign (not a hyphen), so the echo should work correctly.
22488    # The option is referenced via a variable to avoid confusing sed.
22489    lt_compile=`echo "$ac_compile" | $SED \
22490    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
22491    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
22492    -e 's:$: $lt_compiler_flag:'`
22493    (eval echo "\"\$as_me:22493: $lt_compile\"" >&5)
22494    (eval "$lt_compile" 2>conftest.err)
22495    ac_status=$?
22496    cat conftest.err >&5
22497    echo "$as_me:22497: \$? = $ac_status" >&5
22498    if (exit $ac_status) && test -s "$ac_outfile"; then
22499      # The compiler can only warn and ignore the option if not recognized
22500      # So say no if there are warnings other than the usual output.
22501      $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
22502      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
22503      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
22504        lt_cv_prog_compiler_rtti_exceptions=yes
22505      fi
22506    fi
22507    $rm conftest*
22508
22509 fi
22510 { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
22511 echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6; }
22512
22513 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
22514     lt_prog_compiler_no_builtin_flag_GCJ="$lt_prog_compiler_no_builtin_flag_GCJ -fno-rtti -fno-exceptions"
22515 else
22516     :
22517 fi
22518
22519 fi
22520
22521 lt_prog_compiler_wl_GCJ=
22522 lt_prog_compiler_pic_GCJ=
22523 lt_prog_compiler_static_GCJ=
22524
22525 { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
22526 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; }
22527
22528   if test "$GCC" = yes; then
22529     lt_prog_compiler_wl_GCJ='-Wl,'
22530     lt_prog_compiler_static_GCJ='-static'
22531
22532     case $host_os in
22533       aix*)
22534       # All AIX code is PIC.
22535       if test "$host_cpu" = ia64; then
22536         # AIX 5 now supports IA64 processor
22537         lt_prog_compiler_static_GCJ='-Bstatic'
22538       fi
22539       ;;
22540
22541     amigaos*)
22542       # FIXME: we need at least 68020 code to build shared libraries, but
22543       # adding the `-m68020' flag to GCC prevents building anything better,
22544       # like `-m68040'.
22545       lt_prog_compiler_pic_GCJ='-m68020 -resident32 -malways-restore-a4'
22546       ;;
22547
22548     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
22549       # PIC is the default for these OSes.
22550       ;;
22551
22552     mingw* | cygwin* | pw32* | os2*)
22553       # This hack is so that the source file can tell whether it is being
22554       # built for inclusion in a dll (and should export symbols for example).
22555       # Although the cygwin gcc ignores -fPIC, still need this for old-style
22556       # (--disable-auto-import) libraries
22557       lt_prog_compiler_pic_GCJ='-DDLL_EXPORT'
22558       ;;
22559
22560     darwin* | rhapsody*)
22561       # PIC is the default on this platform
22562       # Common symbols not allowed in MH_DYLIB files
22563       lt_prog_compiler_pic_GCJ='-fno-common'
22564       ;;
22565
22566     interix[3-9]*)
22567       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
22568       # Instead, we relocate shared libraries at runtime.
22569       ;;
22570
22571     msdosdjgpp*)
22572       # Just because we use GCC doesn't mean we suddenly get shared libraries
22573       # on systems that don't support them.
22574       lt_prog_compiler_can_build_shared_GCJ=no
22575       enable_shared=no
22576       ;;
22577
22578     sysv4*MP*)
22579       if test -d /usr/nec; then
22580         lt_prog_compiler_pic_GCJ=-Kconform_pic
22581       fi
22582       ;;
22583
22584     hpux*)
22585       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
22586       # not for PA HP-UX.
22587       case $host_cpu in
22588       hppa*64*|ia64*)
22589         # +Z the default
22590         ;;
22591       *)
22592         lt_prog_compiler_pic_GCJ='-fPIC'
22593         ;;
22594       esac
22595       ;;
22596
22597     *)
22598       lt_prog_compiler_pic_GCJ='-fPIC'
22599       ;;
22600     esac
22601   else
22602     # PORTME Check for flag to pass linker flags through the system compiler.
22603     case $host_os in
22604     aix*)
22605       lt_prog_compiler_wl_GCJ='-Wl,'
22606       if test "$host_cpu" = ia64; then
22607         # AIX 5 now supports IA64 processor
22608         lt_prog_compiler_static_GCJ='-Bstatic'
22609       else
22610         lt_prog_compiler_static_GCJ='-bnso -bI:/lib/syscalls.exp'
22611       fi
22612       ;;
22613       darwin*)
22614         # PIC is the default on this platform
22615         # Common symbols not allowed in MH_DYLIB files
22616        case $cc_basename in
22617          xlc*)
22618          lt_prog_compiler_pic_GCJ='-qnocommon'
22619          lt_prog_compiler_wl_GCJ='-Wl,'
22620          ;;
22621        esac
22622        ;;
22623
22624     mingw* | cygwin* | pw32* | os2*)
22625       # This hack is so that the source file can tell whether it is being
22626       # built for inclusion in a dll (and should export symbols for example).
22627       lt_prog_compiler_pic_GCJ='-DDLL_EXPORT'
22628       ;;
22629
22630     hpux9* | hpux10* | hpux11*)
22631       lt_prog_compiler_wl_GCJ='-Wl,'
22632       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
22633       # not for PA HP-UX.
22634       case $host_cpu in
22635       hppa*64*|ia64*)
22636         # +Z the default
22637         ;;
22638       *)
22639         lt_prog_compiler_pic_GCJ='+Z'
22640         ;;
22641       esac
22642       # Is there a better lt_prog_compiler_static that works with the bundled CC?
22643       lt_prog_compiler_static_GCJ='${wl}-a ${wl}archive'
22644       ;;
22645
22646     irix5* | irix6* | nonstopux*)
22647       lt_prog_compiler_wl_GCJ='-Wl,'
22648       # PIC (with -KPIC) is the default.
22649       lt_prog_compiler_static_GCJ='-non_shared'
22650       ;;
22651
22652     newsos6)
22653       lt_prog_compiler_pic_GCJ='-KPIC'
22654       lt_prog_compiler_static_GCJ='-Bstatic'
22655       ;;
22656
22657     linux* | k*bsd*-gnu)
22658       case $cc_basename in
22659       icc* | ecc*)
22660         lt_prog_compiler_wl_GCJ='-Wl,'
22661         lt_prog_compiler_pic_GCJ='-KPIC'
22662         lt_prog_compiler_static_GCJ='-static'
22663         ;;
22664       pgcc* | pgf77* | pgf90* | pgf95*)
22665         # Portland Group compilers (*not* the Pentium gcc compiler,
22666         # which looks to be a dead project)
22667         lt_prog_compiler_wl_GCJ='-Wl,'
22668         lt_prog_compiler_pic_GCJ='-fpic'
22669         lt_prog_compiler_static_GCJ='-Bstatic'
22670         ;;
22671       ccc*)
22672         lt_prog_compiler_wl_GCJ='-Wl,'
22673         # All Alpha code is PIC.
22674         lt_prog_compiler_static_GCJ='-non_shared'
22675         ;;
22676       *)
22677         case `$CC -V 2>&1 | sed 5q` in
22678         *Sun\ C*)
22679           # Sun C 5.9
22680           lt_prog_compiler_pic_GCJ='-KPIC'
22681           lt_prog_compiler_static_GCJ='-Bstatic'
22682           lt_prog_compiler_wl_GCJ='-Wl,'
22683           ;;
22684         *Sun\ F*)
22685           # Sun Fortran 8.3 passes all unrecognized flags to the linker
22686           lt_prog_compiler_pic_GCJ='-KPIC'
22687           lt_prog_compiler_static_GCJ='-Bstatic'
22688           lt_prog_compiler_wl_GCJ=''
22689           ;;
22690         esac
22691         ;;
22692       esac
22693       ;;
22694
22695     osf3* | osf4* | osf5*)
22696       lt_prog_compiler_wl_GCJ='-Wl,'
22697       # All OSF/1 code is PIC.
22698       lt_prog_compiler_static_GCJ='-non_shared'
22699       ;;
22700
22701     rdos*)
22702       lt_prog_compiler_static_GCJ='-non_shared'
22703       ;;
22704
22705     solaris*)
22706       lt_prog_compiler_pic_GCJ='-KPIC'
22707       lt_prog_compiler_static_GCJ='-Bstatic'
22708       case $cc_basename in
22709       f77* | f90* | f95*)
22710         lt_prog_compiler_wl_GCJ='-Qoption ld ';;
22711       *)
22712         lt_prog_compiler_wl_GCJ='-Wl,';;
22713       esac
22714       ;;
22715
22716     sunos4*)
22717       lt_prog_compiler_wl_GCJ='-Qoption ld '
22718       lt_prog_compiler_pic_GCJ='-PIC'
22719       lt_prog_compiler_static_GCJ='-Bstatic'
22720       ;;
22721
22722     sysv4 | sysv4.2uw2* | sysv4.3*)
22723       lt_prog_compiler_wl_GCJ='-Wl,'
22724       lt_prog_compiler_pic_GCJ='-KPIC'
22725       lt_prog_compiler_static_GCJ='-Bstatic'
22726       ;;
22727
22728     sysv4*MP*)
22729       if test -d /usr/nec ;then
22730         lt_prog_compiler_pic_GCJ='-Kconform_pic'
22731         lt_prog_compiler_static_GCJ='-Bstatic'
22732       fi
22733       ;;
22734
22735     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
22736       lt_prog_compiler_wl_GCJ='-Wl,'
22737       lt_prog_compiler_pic_GCJ='-KPIC'
22738       lt_prog_compiler_static_GCJ='-Bstatic'
22739       ;;
22740
22741     unicos*)
22742       lt_prog_compiler_wl_GCJ='-Wl,'
22743       lt_prog_compiler_can_build_shared_GCJ=no
22744       ;;
22745
22746     uts4*)
22747       lt_prog_compiler_pic_GCJ='-pic'
22748       lt_prog_compiler_static_GCJ='-Bstatic'
22749       ;;
22750
22751     *)
22752       lt_prog_compiler_can_build_shared_GCJ=no
22753       ;;
22754     esac
22755   fi
22756
22757 { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_GCJ" >&5
22758 echo "${ECHO_T}$lt_prog_compiler_pic_GCJ" >&6; }
22759
22760 #
22761 # Check to make sure the PIC flag actually works.
22762 #
22763 if test -n "$lt_prog_compiler_pic_GCJ"; then
22764
22765 { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works" >&5
22766 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works... $ECHO_C" >&6; }
22767 if test "${lt_prog_compiler_pic_works_GCJ+set}" = set; then
22768   echo $ECHO_N "(cached) $ECHO_C" >&6
22769 else
22770   lt_prog_compiler_pic_works_GCJ=no
22771   ac_outfile=conftest.$ac_objext
22772    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
22773    lt_compiler_flag="$lt_prog_compiler_pic_GCJ"
22774    # Insert the option either (1) after the last *FLAGS variable, or
22775    # (2) before a word containing "conftest.", or (3) at the end.
22776    # Note that $ac_compile itself does not contain backslashes and begins
22777    # with a dollar sign (not a hyphen), so the echo should work correctly.
22778    # The option is referenced via a variable to avoid confusing sed.
22779    lt_compile=`echo "$ac_compile" | $SED \
22780    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
22781    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
22782    -e 's:$: $lt_compiler_flag:'`
22783    (eval echo "\"\$as_me:22783: $lt_compile\"" >&5)
22784    (eval "$lt_compile" 2>conftest.err)
22785    ac_status=$?
22786    cat conftest.err >&5
22787    echo "$as_me:22787: \$? = $ac_status" >&5
22788    if (exit $ac_status) && test -s "$ac_outfile"; then
22789      # The compiler can only warn and ignore the option if not recognized
22790      # So say no if there are warnings other than the usual output.
22791      $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
22792      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
22793      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
22794        lt_prog_compiler_pic_works_GCJ=yes
22795      fi
22796    fi
22797    $rm conftest*
22798
22799 fi
22800 { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_works_GCJ" >&5
22801 echo "${ECHO_T}$lt_prog_compiler_pic_works_GCJ" >&6; }
22802
22803 if test x"$lt_prog_compiler_pic_works_GCJ" = xyes; then
22804     case $lt_prog_compiler_pic_GCJ in
22805      "" | " "*) ;;
22806      *) lt_prog_compiler_pic_GCJ=" $lt_prog_compiler_pic_GCJ" ;;
22807      esac
22808 else
22809     lt_prog_compiler_pic_GCJ=
22810      lt_prog_compiler_can_build_shared_GCJ=no
22811 fi
22812
22813 fi
22814 case $host_os in
22815   # For platforms which do not support PIC, -DPIC is meaningless:
22816   *djgpp*)
22817     lt_prog_compiler_pic_GCJ=
22818     ;;
22819   *)
22820     lt_prog_compiler_pic_GCJ="$lt_prog_compiler_pic_GCJ"
22821     ;;
22822 esac
22823
22824 #
22825 # Check to make sure the static flag actually works.
22826 #
22827 wl=$lt_prog_compiler_wl_GCJ eval lt_tmp_static_flag=\"$lt_prog_compiler_static_GCJ\"
22828 { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
22829 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; }
22830 if test "${lt_prog_compiler_static_works_GCJ+set}" = set; then
22831   echo $ECHO_N "(cached) $ECHO_C" >&6
22832 else
22833   lt_prog_compiler_static_works_GCJ=no
22834    save_LDFLAGS="$LDFLAGS"
22835    LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
22836    echo "$lt_simple_link_test_code" > conftest.$ac_ext
22837    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
22838      # The linker can only warn and ignore the option if not recognized
22839      # So say no if there are warnings
22840      if test -s conftest.err; then
22841        # Append any errors to the config.log.
22842        cat conftest.err 1>&5
22843        $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
22844        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
22845        if diff conftest.exp conftest.er2 >/dev/null; then
22846          lt_prog_compiler_static_works_GCJ=yes
22847        fi
22848      else
22849        lt_prog_compiler_static_works_GCJ=yes
22850      fi
22851    fi
22852    $rm conftest*
22853    LDFLAGS="$save_LDFLAGS"
22854
22855 fi
22856 { echo "$as_me:$LINENO: result: $lt_prog_compiler_static_works_GCJ" >&5
22857 echo "${ECHO_T}$lt_prog_compiler_static_works_GCJ" >&6; }
22858
22859 if test x"$lt_prog_compiler_static_works_GCJ" = xyes; then
22860     :
22861 else
22862     lt_prog_compiler_static_GCJ=
22863 fi
22864
22865
22866 { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
22867 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; }
22868 if test "${lt_cv_prog_compiler_c_o_GCJ+set}" = set; then
22869   echo $ECHO_N "(cached) $ECHO_C" >&6
22870 else
22871   lt_cv_prog_compiler_c_o_GCJ=no
22872    $rm -r conftest 2>/dev/null
22873    mkdir conftest
22874    cd conftest
22875    mkdir out
22876    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
22877
22878    lt_compiler_flag="-o out/conftest2.$ac_objext"
22879    # Insert the option either (1) after the last *FLAGS variable, or
22880    # (2) before a word containing "conftest.", or (3) at the end.
22881    # Note that $ac_compile itself does not contain backslashes and begins
22882    # with a dollar sign (not a hyphen), so the echo should work correctly.
22883    lt_compile=`echo "$ac_compile" | $SED \
22884    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
22885    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
22886    -e 's:$: $lt_compiler_flag:'`
22887    (eval echo "\"\$as_me:22887: $lt_compile\"" >&5)
22888    (eval "$lt_compile" 2>out/conftest.err)
22889    ac_status=$?
22890    cat out/conftest.err >&5
22891    echo "$as_me:22891: \$? = $ac_status" >&5
22892    if (exit $ac_status) && test -s out/conftest2.$ac_objext
22893    then
22894      # The compiler can only warn and ignore the option if not recognized
22895      # So say no if there are warnings
22896      $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
22897      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
22898      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
22899        lt_cv_prog_compiler_c_o_GCJ=yes
22900      fi
22901    fi
22902    chmod u+w . 2>&5
22903    $rm conftest*
22904    # SGI C++ compiler will create directory out/ii_files/ for
22905    # template instantiation
22906    test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files
22907    $rm out/* && rmdir out
22908    cd ..
22909    rmdir conftest
22910    $rm conftest*
22911
22912 fi
22913 { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_GCJ" >&5
22914 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_GCJ" >&6; }
22915
22916
22917 hard_links="nottested"
22918 if test "$lt_cv_prog_compiler_c_o_GCJ" = no && test "$need_locks" != no; then
22919   # do not overwrite the value of need_locks provided by the user
22920   { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
22921 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; }
22922   hard_links=yes
22923   $rm conftest*
22924   ln conftest.a conftest.b 2>/dev/null && hard_links=no
22925   touch conftest.a
22926   ln conftest.a conftest.b 2>&5 || hard_links=no
22927   ln conftest.a conftest.b 2>/dev/null && hard_links=no
22928   { echo "$as_me:$LINENO: result: $hard_links" >&5
22929 echo "${ECHO_T}$hard_links" >&6; }
22930   if test "$hard_links" = no; then
22931     { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
22932 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
22933     need_locks=warn
22934   fi
22935 else
22936   need_locks=no
22937 fi
22938
22939 { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
22940 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; }
22941
22942   runpath_var=
22943   allow_undefined_flag_GCJ=
22944   enable_shared_with_static_runtimes_GCJ=no
22945   archive_cmds_GCJ=
22946   archive_expsym_cmds_GCJ=
22947   old_archive_From_new_cmds_GCJ=
22948   old_archive_from_expsyms_cmds_GCJ=
22949   export_dynamic_flag_spec_GCJ=
22950   whole_archive_flag_spec_GCJ=
22951   thread_safe_flag_spec_GCJ=
22952   hardcode_libdir_flag_spec_GCJ=
22953   hardcode_libdir_flag_spec_ld_GCJ=
22954   hardcode_libdir_separator_GCJ=
22955   hardcode_direct_GCJ=no
22956   hardcode_minus_L_GCJ=no
22957   hardcode_shlibpath_var_GCJ=unsupported
22958   link_all_deplibs_GCJ=unknown
22959   hardcode_automatic_GCJ=no
22960   module_cmds_GCJ=
22961   module_expsym_cmds_GCJ=
22962   always_export_symbols_GCJ=no
22963   export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
22964   # include_expsyms should be a list of space-separated symbols to be *always*
22965   # included in the symbol list
22966   include_expsyms_GCJ=
22967   # exclude_expsyms can be an extended regexp of symbols to exclude
22968   # it will be wrapped by ` (' and `)$', so one must not match beginning or
22969   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
22970   # as well as any symbol that contains `d'.
22971   exclude_expsyms_GCJ="_GLOBAL_OFFSET_TABLE_"
22972   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
22973   # platforms (ab)use it in PIC code, but their linkers get confused if
22974   # the symbol is explicitly referenced.  Since portable code cannot
22975   # rely on this symbol name, it's probably fine to never include it in
22976   # preloaded symbol tables.
22977   extract_expsyms_cmds=
22978   # Just being paranoid about ensuring that cc_basename is set.
22979   for cc_temp in $compiler""; do
22980   case $cc_temp in
22981     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
22982     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
22983     \-*) ;;
22984     *) break;;
22985   esac
22986 done
22987 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
22988
22989   case $host_os in
22990   cygwin* | mingw* | pw32*)
22991     # FIXME: the MSVC++ port hasn't been tested in a loooong time
22992     # When not using gcc, we currently assume that we are using
22993     # Microsoft Visual C++.
22994     if test "$GCC" != yes; then
22995       with_gnu_ld=no
22996     fi
22997     ;;
22998   interix*)
22999     # we just hope/assume this is gcc and not c89 (= MSVC++)
23000     with_gnu_ld=yes
23001     ;;
23002   openbsd*)
23003     with_gnu_ld=no
23004     ;;
23005   esac
23006
23007   ld_shlibs_GCJ=yes
23008   if test "$with_gnu_ld" = yes; then
23009     # If archive_cmds runs LD, not CC, wlarc should be empty
23010     wlarc='${wl}'
23011
23012     # Set some defaults for GNU ld with shared library support. These
23013     # are reset later if shared libraries are not supported. Putting them
23014     # here allows them to be overridden if necessary.
23015     runpath_var=LD_RUN_PATH
23016     hardcode_libdir_flag_spec_GCJ='${wl}--rpath ${wl}$libdir'
23017     export_dynamic_flag_spec_GCJ='${wl}--export-dynamic'
23018     # ancient GNU ld didn't support --whole-archive et. al.
23019     if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then
23020         whole_archive_flag_spec_GCJ="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
23021       else
23022         whole_archive_flag_spec_GCJ=
23023     fi
23024     supports_anon_versioning=no
23025     case `$LD -v 2>/dev/null` in
23026       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
23027       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
23028       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
23029       *\ 2.11.*) ;; # other 2.11 versions
23030       *) supports_anon_versioning=yes ;;
23031     esac
23032
23033     # See if GNU ld supports shared libraries.
23034     case $host_os in
23035     aix3* | aix4* | aix5*)
23036       # On AIX/PPC, the GNU linker is very broken
23037       if test "$host_cpu" != ia64; then
23038         ld_shlibs_GCJ=no
23039         cat <<EOF 1>&2
23040
23041 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
23042 *** to be unable to reliably create shared libraries on AIX.
23043 *** Therefore, libtool is disabling shared libraries support.  If you
23044 *** really care for shared libraries, you may want to modify your PATH
23045 *** so that a non-GNU linker is found, and then restart.
23046
23047 EOF
23048       fi
23049       ;;
23050
23051     amigaos*)
23052       archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
23053       hardcode_libdir_flag_spec_GCJ='-L$libdir'
23054       hardcode_minus_L_GCJ=yes
23055
23056       # Samuel A. Falvo II <kc5tja@dolphin.openprojects.net> reports
23057       # that the semantics of dynamic libraries on AmigaOS, at least up
23058       # to version 4, is to share data among multiple programs linked
23059       # with the same dynamic library.  Since this doesn't match the
23060       # behavior of shared libraries on other platforms, we can't use
23061       # them.
23062       ld_shlibs_GCJ=no
23063       ;;
23064
23065     beos*)
23066       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
23067         allow_undefined_flag_GCJ=unsupported
23068         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
23069         # support --undefined.  This deserves some investigation.  FIXME
23070         archive_cmds_GCJ='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
23071       else
23072         ld_shlibs_GCJ=no
23073       fi
23074       ;;
23075
23076     cygwin* | mingw* | pw32*)
23077       # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, GCJ) is actually meaningless,
23078       # as there is no search path for DLLs.
23079       hardcode_libdir_flag_spec_GCJ='-L$libdir'
23080       allow_undefined_flag_GCJ=unsupported
23081       always_export_symbols_GCJ=no
23082       enable_shared_with_static_runtimes_GCJ=yes
23083       export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
23084
23085       if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
23086         archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
23087         # If the export-symbols file already is a .def file (1st line
23088         # is EXPORTS), use it as is; otherwise, prepend...
23089         archive_expsym_cmds_GCJ='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
23090           cp $export_symbols $output_objdir/$soname.def;
23091         else
23092           echo EXPORTS > $output_objdir/$soname.def;
23093           cat $export_symbols >> $output_objdir/$soname.def;
23094         fi~
23095         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
23096       else
23097         ld_shlibs_GCJ=no
23098       fi
23099       ;;
23100
23101     interix[3-9]*)
23102       hardcode_direct_GCJ=no
23103       hardcode_shlibpath_var_GCJ=no
23104       hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir'
23105       export_dynamic_flag_spec_GCJ='${wl}-E'
23106       # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
23107       # Instead, shared libraries are loaded at an image base (0x10000000 by
23108       # default) and relocated if they conflict, which is a slow very memory
23109       # consuming and fragmenting process.  To avoid this, we pick a random,
23110       # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
23111       # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
23112       archive_cmds_GCJ='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
23113       archive_expsym_cmds_GCJ='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
23114       ;;
23115
23116     gnu* | linux* | k*bsd*-gnu)
23117       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
23118         tmp_addflag=
23119         case $cc_basename,$host_cpu in
23120         pgcc*)                          # Portland Group C compiler
23121           whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
23122           tmp_addflag=' $pic_flag'
23123           ;;
23124         pgf77* | pgf90* | pgf95*)       # Portland Group f77 and f90 compilers
23125           whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
23126           tmp_addflag=' $pic_flag -Mnomain' ;;
23127         ecc*,ia64* | icc*,ia64*)                # Intel C compiler on ia64
23128           tmp_addflag=' -i_dynamic' ;;
23129         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
23130           tmp_addflag=' -i_dynamic -nofor_main' ;;
23131         ifc* | ifort*)                  # Intel Fortran compiler
23132           tmp_addflag=' -nofor_main' ;;
23133         esac
23134         case `$CC -V 2>&1 | sed 5q` in
23135         *Sun\ C*)                       # Sun C 5.9
23136           whole_archive_flag_spec_GCJ='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
23137           tmp_sharedflag='-G' ;;
23138         *Sun\ F*)                       # Sun Fortran 8.3
23139           tmp_sharedflag='-G' ;;
23140         *)
23141           tmp_sharedflag='-shared' ;;
23142         esac
23143         archive_cmds_GCJ='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
23144
23145         if test $supports_anon_versioning = yes; then
23146           archive_expsym_cmds_GCJ='$echo "{ global:" > $output_objdir/$libname.ver~
23147   cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
23148   $echo "local: *; };" >> $output_objdir/$libname.ver~
23149           $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
23150         fi
23151       else
23152         ld_shlibs_GCJ=no
23153       fi
23154       ;;
23155
23156     netbsd*)
23157       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
23158         archive_cmds_GCJ='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
23159         wlarc=
23160       else
23161         archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
23162         archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
23163       fi
23164       ;;
23165
23166     solaris*)
23167       if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
23168         ld_shlibs_GCJ=no
23169         cat <<EOF 1>&2
23170
23171 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
23172 *** create shared libraries on Solaris systems.  Therefore, libtool
23173 *** is disabling shared libraries support.  We urge you to upgrade GNU
23174 *** binutils to release 2.9.1 or newer.  Another option is to modify
23175 *** your PATH or compiler configuration so that the native linker is
23176 *** used, and then restart.
23177
23178 EOF
23179       elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
23180         archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
23181         archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
23182       else
23183         ld_shlibs_GCJ=no
23184       fi
23185       ;;
23186
23187     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
23188       case `$LD -v 2>&1` in
23189         *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
23190         ld_shlibs_GCJ=no
23191         cat <<_LT_EOF 1>&2
23192
23193 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
23194 *** reliably create shared libraries on SCO systems.  Therefore, libtool
23195 *** is disabling shared libraries support.  We urge you to upgrade GNU
23196 *** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
23197 *** your PATH or compiler configuration so that the native linker is
23198 *** used, and then restart.
23199
23200 _LT_EOF
23201         ;;
23202         *)
23203           if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
23204             hardcode_libdir_flag_spec_GCJ='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
23205             archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
23206             archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
23207           else
23208             ld_shlibs_GCJ=no
23209           fi
23210         ;;
23211       esac
23212       ;;
23213
23214     sunos4*)
23215       archive_cmds_GCJ='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
23216       wlarc=
23217       hardcode_direct_GCJ=yes
23218       hardcode_shlibpath_var_GCJ=no
23219       ;;
23220
23221     *)
23222       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
23223         archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
23224         archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
23225       else
23226         ld_shlibs_GCJ=no
23227       fi
23228       ;;
23229     esac
23230
23231     if test "$ld_shlibs_GCJ" = no; then
23232       runpath_var=
23233       hardcode_libdir_flag_spec_GCJ=
23234       export_dynamic_flag_spec_GCJ=
23235       whole_archive_flag_spec_GCJ=
23236     fi
23237   else
23238     # PORTME fill in a description of your system's linker (not GNU ld)
23239     case $host_os in
23240     aix3*)
23241       allow_undefined_flag_GCJ=unsupported
23242       always_export_symbols_GCJ=yes
23243       archive_expsym_cmds_GCJ='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
23244       # Note: this linker hardcodes the directories in LIBPATH if there
23245       # are no directories specified by -L.
23246       hardcode_minus_L_GCJ=yes
23247       if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
23248         # Neither direct hardcoding nor static linking is supported with a
23249         # broken collect2.
23250         hardcode_direct_GCJ=unsupported
23251       fi
23252       ;;
23253
23254     aix4* | aix5*)
23255       if test "$host_cpu" = ia64; then
23256         # On IA64, the linker does run time linking by default, so we don't
23257         # have to do anything special.
23258         aix_use_runtimelinking=no
23259         exp_sym_flag='-Bexport'
23260         no_entry_flag=""
23261       else
23262         # If we're using GNU nm, then we don't want the "-C" option.
23263         # -C means demangle to AIX nm, but means don't demangle with GNU nm
23264         if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
23265           export_symbols_cmds_GCJ='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
23266         else
23267           export_symbols_cmds_GCJ='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols'
23268         fi
23269         aix_use_runtimelinking=no
23270
23271         # Test if we are trying to use run time linking or normal
23272         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
23273         # need to do runtime linking.
23274         case $host_os in aix4.[23]|aix4.[23].*|aix5*)
23275           for ld_flag in $LDFLAGS; do
23276           if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
23277             aix_use_runtimelinking=yes
23278             break
23279           fi
23280           done
23281           ;;
23282         esac
23283
23284         exp_sym_flag='-bexport'
23285         no_entry_flag='-bnoentry'
23286       fi
23287
23288       # When large executables or shared objects are built, AIX ld can
23289       # have problems creating the table of contents.  If linking a library
23290       # or program results in "error TOC overflow" add -mminimal-toc to
23291       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
23292       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
23293
23294       archive_cmds_GCJ=''
23295       hardcode_direct_GCJ=yes
23296       hardcode_libdir_separator_GCJ=':'
23297       link_all_deplibs_GCJ=yes
23298
23299       if test "$GCC" = yes; then
23300         case $host_os in aix4.[012]|aix4.[012].*)
23301         # We only want to do this on AIX 4.2 and lower, the check
23302         # below for broken collect2 doesn't work under 4.3+
23303           collect2name=`${CC} -print-prog-name=collect2`
23304           if test -f "$collect2name" && \
23305            strings "$collect2name" | grep resolve_lib_name >/dev/null
23306           then
23307           # We have reworked collect2
23308           :
23309           else
23310           # We have old collect2
23311           hardcode_direct_GCJ=unsupported
23312           # It fails to find uninstalled libraries when the uninstalled
23313           # path is not listed in the libpath.  Setting hardcode_minus_L
23314           # to unsupported forces relinking
23315           hardcode_minus_L_GCJ=yes
23316           hardcode_libdir_flag_spec_GCJ='-L$libdir'
23317           hardcode_libdir_separator_GCJ=
23318           fi
23319           ;;
23320         esac
23321         shared_flag='-shared'
23322         if test "$aix_use_runtimelinking" = yes; then
23323           shared_flag="$shared_flag "'${wl}-G'
23324         fi
23325       else
23326         # not using gcc
23327         if test "$host_cpu" = ia64; then
23328         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
23329         # chokes on -Wl,-G. The following line is correct:
23330           shared_flag='-G'
23331         else
23332           if test "$aix_use_runtimelinking" = yes; then
23333             shared_flag='${wl}-G'
23334           else
23335             shared_flag='${wl}-bM:SRE'
23336           fi
23337         fi
23338       fi
23339
23340       # It seems that -bexpall does not export symbols beginning with
23341       # underscore (_), so it is better to generate a list of symbols to export.
23342       always_export_symbols_GCJ=yes
23343       if test "$aix_use_runtimelinking" = yes; then
23344         # Warning - without using the other runtime loading flags (-brtl),
23345         # -berok will link without error, but may produce a broken library.
23346         allow_undefined_flag_GCJ='-berok'
23347        # Determine the default libpath from the value encoded in an empty executable.
23348        cat >conftest.$ac_ext <<_ACEOF
23349 /* confdefs.h.  */
23350 _ACEOF
23351 cat confdefs.h >>conftest.$ac_ext
23352 cat >>conftest.$ac_ext <<_ACEOF
23353 /* end confdefs.h.  */
23354
23355 int
23356 main ()
23357 {
23358
23359   ;
23360   return 0;
23361 }
23362 _ACEOF
23363 rm -f conftest.$ac_objext conftest$ac_exeext
23364 if { (ac_try="$ac_link"
23365 case "(($ac_try" in
23366   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23367   *) ac_try_echo=$ac_try;;
23368 esac
23369 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23370   (eval "$ac_link") 2>conftest.er1
23371   ac_status=$?
23372   grep -v '^ *+' conftest.er1 >conftest.err
23373   rm -f conftest.er1
23374   cat conftest.err >&5
23375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23376   (exit $ac_status); } && {
23377          test -z "$ac_c_werror_flag" ||
23378          test ! -s conftest.err
23379        } && test -s conftest$ac_exeext &&
23380        $as_test_x conftest$ac_exeext; then
23381
23382 lt_aix_libpath_sed='
23383     /Import File Strings/,/^$/ {
23384         /^0/ {
23385             s/^0  *\(.*\)$/\1/
23386             p
23387         }
23388     }'
23389 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
23390 # Check for a 64-bit object if we didn't find anything.
23391 if test -z "$aix_libpath"; then
23392   aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
23393 fi
23394 else
23395   echo "$as_me: failed program was:" >&5
23396 sed 's/^/| /' conftest.$ac_ext >&5
23397
23398
23399 fi
23400
23401 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23402       conftest$ac_exeext conftest.$ac_ext
23403 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
23404
23405        hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath"
23406         archive_expsym_cmds_GCJ="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
23407        else
23408         if test "$host_cpu" = ia64; then
23409           hardcode_libdir_flag_spec_GCJ='${wl}-R $libdir:/usr/lib:/lib'
23410           allow_undefined_flag_GCJ="-z nodefs"
23411           archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
23412         else
23413          # Determine the default libpath from the value encoded in an empty executable.
23414          cat >conftest.$ac_ext <<_ACEOF
23415 /* confdefs.h.  */
23416 _ACEOF
23417 cat confdefs.h >>conftest.$ac_ext
23418 cat >>conftest.$ac_ext <<_ACEOF
23419 /* end confdefs.h.  */
23420
23421 int
23422 main ()
23423 {
23424
23425   ;
23426   return 0;
23427 }
23428 _ACEOF
23429 rm -f conftest.$ac_objext conftest$ac_exeext
23430 if { (ac_try="$ac_link"
23431 case "(($ac_try" in
23432   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23433   *) ac_try_echo=$ac_try;;
23434 esac
23435 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23436   (eval "$ac_link") 2>conftest.er1
23437   ac_status=$?
23438   grep -v '^ *+' conftest.er1 >conftest.err
23439   rm -f conftest.er1
23440   cat conftest.err >&5
23441   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23442   (exit $ac_status); } && {
23443          test -z "$ac_c_werror_flag" ||
23444          test ! -s conftest.err
23445        } && test -s conftest$ac_exeext &&
23446        $as_test_x conftest$ac_exeext; then
23447
23448 lt_aix_libpath_sed='
23449     /Import File Strings/,/^$/ {
23450         /^0/ {
23451             s/^0  *\(.*\)$/\1/
23452             p
23453         }
23454     }'
23455 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
23456 # Check for a 64-bit object if we didn't find anything.
23457 if test -z "$aix_libpath"; then
23458   aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
23459 fi
23460 else
23461   echo "$as_me: failed program was:" >&5
23462 sed 's/^/| /' conftest.$ac_ext >&5
23463
23464
23465 fi
23466
23467 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23468       conftest$ac_exeext conftest.$ac_ext
23469 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
23470
23471          hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath"
23472           # Warning - without using the other run time loading flags,
23473           # -berok will link without error, but may produce a broken library.
23474           no_undefined_flag_GCJ=' ${wl}-bernotok'
23475           allow_undefined_flag_GCJ=' ${wl}-berok'
23476           # Exported symbols can be pulled into shared objects from archives
23477           whole_archive_flag_spec_GCJ='$convenience'
23478           archive_cmds_need_lc_GCJ=yes
23479           # This is similar to how AIX traditionally builds its shared libraries.
23480           archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
23481         fi
23482       fi
23483       ;;
23484
23485     amigaos*)
23486       archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
23487       hardcode_libdir_flag_spec_GCJ='-L$libdir'
23488       hardcode_minus_L_GCJ=yes
23489       # see comment about different semantics on the GNU ld section
23490       ld_shlibs_GCJ=no
23491       ;;
23492
23493     bsdi[45]*)
23494       export_dynamic_flag_spec_GCJ=-rdynamic
23495       ;;
23496
23497     cygwin* | mingw* | pw32*)
23498       # When not using gcc, we currently assume that we are using
23499       # Microsoft Visual C++.
23500       # hardcode_libdir_flag_spec is actually meaningless, as there is
23501       # no search path for DLLs.
23502       hardcode_libdir_flag_spec_GCJ=' '
23503       allow_undefined_flag_GCJ=unsupported
23504       # Tell ltmain to make .lib files, not .a files.
23505       libext=lib
23506       # Tell ltmain to make .dll files, not .so files.
23507       shrext_cmds=".dll"
23508       # FIXME: Setting linknames here is a bad hack.
23509       archive_cmds_GCJ='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames='
23510       # The linker will automatically build a .lib file if we build a DLL.
23511       old_archive_From_new_cmds_GCJ='true'
23512       # FIXME: Should let the user specify the lib program.
23513       old_archive_cmds_GCJ='lib -OUT:$oldlib$oldobjs$old_deplibs'
23514       fix_srcfile_path_GCJ='`cygpath -w "$srcfile"`'
23515       enable_shared_with_static_runtimes_GCJ=yes
23516       ;;
23517
23518     darwin* | rhapsody*)
23519       case $host_os in
23520         rhapsody* | darwin1.[012])
23521          allow_undefined_flag_GCJ='${wl}-undefined ${wl}suppress'
23522          ;;
23523        *) # Darwin 1.3 on
23524          if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
23525            allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
23526          else
23527            case ${MACOSX_DEPLOYMENT_TARGET} in
23528              10.[012])
23529                allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
23530                ;;
23531              10.*)
23532                allow_undefined_flag_GCJ='${wl}-undefined ${wl}dynamic_lookup'
23533                ;;
23534            esac
23535          fi
23536          ;;
23537       esac
23538       archive_cmds_need_lc_GCJ=no
23539       hardcode_direct_GCJ=no
23540       hardcode_automatic_GCJ=yes
23541       hardcode_shlibpath_var_GCJ=unsupported
23542       whole_archive_flag_spec_GCJ=''
23543       link_all_deplibs_GCJ=yes
23544     if test "$GCC" = yes ; then
23545         output_verbose_link_cmd='echo'
23546         archive_cmds_GCJ='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
23547       module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
23548       # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
23549       archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
23550       module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
23551     else
23552       case $cc_basename in
23553         xlc*)
23554          output_verbose_link_cmd='echo'
23555          archive_cmds_GCJ='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
23556          module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
23557           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
23558          archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
23559           module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
23560           ;;
23561        *)
23562          ld_shlibs_GCJ=no
23563           ;;
23564       esac
23565     fi
23566       ;;
23567
23568     dgux*)
23569       archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
23570       hardcode_libdir_flag_spec_GCJ='-L$libdir'
23571       hardcode_shlibpath_var_GCJ=no
23572       ;;
23573
23574     freebsd1*)
23575       ld_shlibs_GCJ=no
23576       ;;
23577
23578     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
23579     # support.  Future versions do this automatically, but an explicit c++rt0.o
23580     # does not break anything, and helps significantly (at the cost of a little
23581     # extra space).
23582     freebsd2.2*)
23583       archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
23584       hardcode_libdir_flag_spec_GCJ='-R$libdir'
23585       hardcode_direct_GCJ=yes
23586       hardcode_shlibpath_var_GCJ=no
23587       ;;
23588
23589     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
23590     freebsd2*)
23591       archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
23592       hardcode_direct_GCJ=yes
23593       hardcode_minus_L_GCJ=yes
23594       hardcode_shlibpath_var_GCJ=no
23595       ;;
23596
23597     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
23598     freebsd* | dragonfly*)
23599       archive_cmds_GCJ='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
23600       hardcode_libdir_flag_spec_GCJ='-R$libdir'
23601       hardcode_direct_GCJ=yes
23602       hardcode_shlibpath_var_GCJ=no
23603       ;;
23604
23605     hpux9*)
23606       if test "$GCC" = yes; then
23607         archive_cmds_GCJ='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
23608       else
23609         archive_cmds_GCJ='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
23610       fi
23611       hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir'
23612       hardcode_libdir_separator_GCJ=:
23613       hardcode_direct_GCJ=yes
23614
23615       # hardcode_minus_L: Not really in the search PATH,
23616       # but as the default location of the library.
23617       hardcode_minus_L_GCJ=yes
23618       export_dynamic_flag_spec_GCJ='${wl}-E'
23619       ;;
23620
23621     hpux10*)
23622       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
23623         archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
23624       else
23625         archive_cmds_GCJ='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
23626       fi
23627       if test "$with_gnu_ld" = no; then
23628         hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir'
23629         hardcode_libdir_separator_GCJ=:
23630
23631         hardcode_direct_GCJ=yes
23632         export_dynamic_flag_spec_GCJ='${wl}-E'
23633
23634         # hardcode_minus_L: Not really in the search PATH,
23635         # but as the default location of the library.
23636         hardcode_minus_L_GCJ=yes
23637       fi
23638       ;;
23639
23640     hpux11*)
23641       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
23642         case $host_cpu in
23643         hppa*64*)
23644           archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
23645           ;;
23646         ia64*)
23647           archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
23648           ;;
23649         *)
23650           archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
23651           ;;
23652         esac
23653       else
23654         case $host_cpu in
23655         hppa*64*)
23656           archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
23657           ;;
23658         ia64*)
23659           archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
23660           ;;
23661         *)
23662           archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
23663           ;;
23664         esac
23665       fi
23666       if test "$with_gnu_ld" = no; then
23667         hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir'
23668         hardcode_libdir_separator_GCJ=:
23669
23670         case $host_cpu in
23671         hppa*64*|ia64*)
23672           hardcode_libdir_flag_spec_ld_GCJ='+b $libdir'
23673           hardcode_direct_GCJ=no
23674           hardcode_shlibpath_var_GCJ=no
23675           ;;
23676         *)
23677           hardcode_direct_GCJ=yes
23678           export_dynamic_flag_spec_GCJ='${wl}-E'
23679
23680           # hardcode_minus_L: Not really in the search PATH,
23681           # but as the default location of the library.
23682           hardcode_minus_L_GCJ=yes
23683           ;;
23684         esac
23685       fi
23686       ;;
23687
23688     irix5* | irix6* | nonstopux*)
23689       if test "$GCC" = yes; then
23690         archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
23691       else
23692         archive_cmds_GCJ='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
23693         hardcode_libdir_flag_spec_ld_GCJ='-rpath $libdir'
23694       fi
23695       hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir'
23696       hardcode_libdir_separator_GCJ=:
23697       link_all_deplibs_GCJ=yes
23698       ;;
23699
23700     netbsd*)
23701       if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
23702         archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
23703       else
23704         archive_cmds_GCJ='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
23705       fi
23706       hardcode_libdir_flag_spec_GCJ='-R$libdir'
23707       hardcode_direct_GCJ=yes
23708       hardcode_shlibpath_var_GCJ=no
23709       ;;
23710
23711     newsos6)
23712       archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
23713       hardcode_direct_GCJ=yes
23714       hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir'
23715       hardcode_libdir_separator_GCJ=:
23716       hardcode_shlibpath_var_GCJ=no
23717       ;;
23718
23719     openbsd*)
23720       if test -f /usr/libexec/ld.so; then
23721         hardcode_direct_GCJ=yes
23722         hardcode_shlibpath_var_GCJ=no
23723         if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
23724           archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
23725           archive_expsym_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
23726           hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir'
23727           export_dynamic_flag_spec_GCJ='${wl}-E'
23728         else
23729           case $host_os in
23730            openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
23731              archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
23732              hardcode_libdir_flag_spec_GCJ='-R$libdir'
23733              ;;
23734            *)
23735              archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
23736              hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir'
23737              ;;
23738           esac
23739         fi
23740       else
23741         ld_shlibs_GCJ=no
23742       fi
23743       ;;
23744
23745     os2*)
23746       hardcode_libdir_flag_spec_GCJ='-L$libdir'
23747       hardcode_minus_L_GCJ=yes
23748       allow_undefined_flag_GCJ=unsupported
23749       archive_cmds_GCJ='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
23750       old_archive_From_new_cmds_GCJ='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
23751       ;;
23752
23753     osf3*)
23754       if test "$GCC" = yes; then
23755         allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*'
23756         archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
23757       else
23758         allow_undefined_flag_GCJ=' -expect_unresolved \*'
23759         archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
23760       fi
23761       hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir'
23762       hardcode_libdir_separator_GCJ=:
23763       ;;
23764
23765     osf4* | osf5*)      # as osf3* with the addition of -msym flag
23766       if test "$GCC" = yes; then
23767         allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*'
23768         archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
23769         hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir'
23770       else
23771         allow_undefined_flag_GCJ=' -expect_unresolved \*'
23772         archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib'
23773         archive_expsym_cmds_GCJ='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~
23774         $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp'
23775
23776         # Both c and cxx compiler support -rpath directly
23777         hardcode_libdir_flag_spec_GCJ='-rpath $libdir'
23778       fi
23779       hardcode_libdir_separator_GCJ=:
23780       ;;
23781
23782     solaris*)
23783       no_undefined_flag_GCJ=' -z text'
23784       if test "$GCC" = yes; then
23785         wlarc='${wl}'
23786         archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
23787         archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
23788           $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp'
23789       else
23790         wlarc=''
23791         archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
23792         archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
23793         $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
23794       fi
23795       hardcode_libdir_flag_spec_GCJ='-R$libdir'
23796       hardcode_shlibpath_var_GCJ=no
23797       case $host_os in
23798       solaris2.[0-5] | solaris2.[0-5].*) ;;
23799       *)
23800         # The compiler driver will combine and reorder linker options,
23801         # but understands `-z linker_flag'.  GCC discards it without `$wl',
23802         # but is careful enough not to reorder.
23803         # Supported since Solaris 2.6 (maybe 2.5.1?)
23804         if test "$GCC" = yes; then
23805           whole_archive_flag_spec_GCJ='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
23806         else
23807           whole_archive_flag_spec_GCJ='-z allextract$convenience -z defaultextract'
23808         fi
23809         ;;
23810       esac
23811       link_all_deplibs_GCJ=yes
23812       ;;
23813
23814     sunos4*)
23815       if test "x$host_vendor" = xsequent; then
23816         # Use $CC to link under sequent, because it throws in some extra .o
23817         # files that make .init and .fini sections work.
23818         archive_cmds_GCJ='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
23819       else
23820         archive_cmds_GCJ='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
23821       fi
23822       hardcode_libdir_flag_spec_GCJ='-L$libdir'
23823       hardcode_direct_GCJ=yes
23824       hardcode_minus_L_GCJ=yes
23825       hardcode_shlibpath_var_GCJ=no
23826       ;;
23827
23828     sysv4)
23829       case $host_vendor in
23830         sni)
23831           archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
23832           hardcode_direct_GCJ=yes # is this really true???
23833         ;;
23834         siemens)
23835           ## LD is ld it makes a PLAMLIB
23836           ## CC just makes a GrossModule.
23837           archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags'
23838           reload_cmds_GCJ='$CC -r -o $output$reload_objs'
23839           hardcode_direct_GCJ=no
23840         ;;
23841         motorola)
23842           archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
23843           hardcode_direct_GCJ=no #Motorola manual says yes, but my tests say they lie
23844         ;;
23845       esac
23846       runpath_var='LD_RUN_PATH'
23847       hardcode_shlibpath_var_GCJ=no
23848       ;;
23849
23850     sysv4.3*)
23851       archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
23852       hardcode_shlibpath_var_GCJ=no
23853       export_dynamic_flag_spec_GCJ='-Bexport'
23854       ;;
23855
23856     sysv4*MP*)
23857       if test -d /usr/nec; then
23858         archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
23859         hardcode_shlibpath_var_GCJ=no
23860         runpath_var=LD_RUN_PATH
23861         hardcode_runpath_var=yes
23862         ld_shlibs_GCJ=yes
23863       fi
23864       ;;
23865
23866     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
23867       no_undefined_flag_GCJ='${wl}-z,text'
23868       archive_cmds_need_lc_GCJ=no
23869       hardcode_shlibpath_var_GCJ=no
23870       runpath_var='LD_RUN_PATH'
23871
23872       if test "$GCC" = yes; then
23873         archive_cmds_GCJ='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
23874         archive_expsym_cmds_GCJ='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
23875       else
23876         archive_cmds_GCJ='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
23877         archive_expsym_cmds_GCJ='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
23878       fi
23879       ;;
23880
23881     sysv5* | sco3.2v5* | sco5v6*)
23882       # Note: We can NOT use -z defs as we might desire, because we do not
23883       # link with -lc, and that would cause any symbols used from libc to
23884       # always be unresolved, which means just about no library would
23885       # ever link correctly.  If we're not using GNU ld we use -z text
23886       # though, which does catch some bad symbols but isn't as heavy-handed
23887       # as -z defs.
23888       no_undefined_flag_GCJ='${wl}-z,text'
23889       allow_undefined_flag_GCJ='${wl}-z,nodefs'
23890       archive_cmds_need_lc_GCJ=no
23891       hardcode_shlibpath_var_GCJ=no
23892       hardcode_libdir_flag_spec_GCJ='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
23893       hardcode_libdir_separator_GCJ=':'
23894       link_all_deplibs_GCJ=yes
23895       export_dynamic_flag_spec_GCJ='${wl}-Bexport'
23896       runpath_var='LD_RUN_PATH'
23897
23898       if test "$GCC" = yes; then
23899         archive_cmds_GCJ='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
23900         archive_expsym_cmds_GCJ='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
23901       else
23902         archive_cmds_GCJ='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
23903         archive_expsym_cmds_GCJ='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
23904       fi
23905       ;;
23906
23907     uts4*)
23908       archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
23909       hardcode_libdir_flag_spec_GCJ='-L$libdir'
23910       hardcode_shlibpath_var_GCJ=no
23911       ;;
23912
23913     *)
23914       ld_shlibs_GCJ=no
23915       ;;
23916     esac
23917   fi
23918
23919 { echo "$as_me:$LINENO: result: $ld_shlibs_GCJ" >&5
23920 echo "${ECHO_T}$ld_shlibs_GCJ" >&6; }
23921 test "$ld_shlibs_GCJ" = no && can_build_shared=no
23922
23923 #
23924 # Do we need to explicitly link libc?
23925 #
23926 case "x$archive_cmds_need_lc_GCJ" in
23927 x|xyes)
23928   # Assume -lc should be added
23929   archive_cmds_need_lc_GCJ=yes
23930
23931   if test "$enable_shared" = yes && test "$GCC" = yes; then
23932     case $archive_cmds_GCJ in
23933     *'~'*)
23934       # FIXME: we may have to deal with multi-command sequences.
23935       ;;
23936     '$CC '*)
23937       # Test whether the compiler implicitly links with -lc since on some
23938       # systems, -lgcc has to come before -lc. If gcc already passes -lc
23939       # to ld, don't add -lc before -lgcc.
23940       { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
23941 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; }
23942       $rm conftest*
23943       echo "$lt_simple_compile_test_code" > conftest.$ac_ext
23944
23945       if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
23946   (eval $ac_compile) 2>&5
23947   ac_status=$?
23948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23949   (exit $ac_status); } 2>conftest.err; then
23950         soname=conftest
23951         lib=conftest
23952         libobjs=conftest.$ac_objext
23953         deplibs=
23954         wl=$lt_prog_compiler_wl_GCJ
23955         pic_flag=$lt_prog_compiler_pic_GCJ
23956         compiler_flags=-v
23957         linker_flags=-v
23958         verstring=
23959         output_objdir=.
23960         libname=conftest
23961         lt_save_allow_undefined_flag=$allow_undefined_flag_GCJ
23962         allow_undefined_flag_GCJ=
23963         if { (eval echo "$as_me:$LINENO: \"$archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5
23964   (eval $archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5
23965   ac_status=$?
23966   echo "$as_me:$LINENO: \$? = $ac_status" >&5
23967   (exit $ac_status); }
23968         then
23969           archive_cmds_need_lc_GCJ=no
23970         else
23971           archive_cmds_need_lc_GCJ=yes
23972         fi
23973         allow_undefined_flag_GCJ=$lt_save_allow_undefined_flag
23974       else
23975         cat conftest.err 1>&5
23976       fi
23977       $rm conftest*
23978       { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_GCJ" >&5
23979 echo "${ECHO_T}$archive_cmds_need_lc_GCJ" >&6; }
23980       ;;
23981     esac
23982   fi
23983   ;;
23984 esac
23985
23986 { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
23987 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; }
23988 library_names_spec=
23989 libname_spec='lib$name'
23990 soname_spec=
23991 shrext_cmds=".so"
23992 postinstall_cmds=
23993 postuninstall_cmds=
23994 finish_cmds=
23995 finish_eval=
23996 shlibpath_var=
23997 shlibpath_overrides_runpath=unknown
23998 version_type=none
23999 dynamic_linker="$host_os ld.so"
24000 sys_lib_dlsearch_path_spec="/lib /usr/lib"
24001
24002 need_lib_prefix=unknown
24003 hardcode_into_libs=no
24004
24005 # when you set need_version to no, make sure it does not cause -set_version
24006 # flags to be left without arguments
24007 need_version=unknown
24008
24009 case $host_os in
24010 aix3*)
24011   version_type=linux
24012   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
24013   shlibpath_var=LIBPATH
24014
24015   # AIX 3 has no versioning support, so we append a major version to the name.
24016   soname_spec='${libname}${release}${shared_ext}$major'
24017   ;;
24018
24019 aix4* | aix5*)
24020   version_type=linux
24021   need_lib_prefix=no
24022   need_version=no
24023   hardcode_into_libs=yes
24024   if test "$host_cpu" = ia64; then
24025     # AIX 5 supports IA64
24026     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
24027     shlibpath_var=LD_LIBRARY_PATH
24028   else
24029     # With GCC up to 2.95.x, collect2 would create an import file
24030     # for dependence libraries.  The import file would start with
24031     # the line `#! .'.  This would cause the generated library to
24032     # depend on `.', always an invalid library.  This was fixed in
24033     # development snapshots of GCC prior to 3.0.
24034     case $host_os in
24035       aix4 | aix4.[01] | aix4.[01].*)
24036       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
24037            echo ' yes '
24038            echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then
24039         :
24040       else
24041         can_build_shared=no
24042       fi
24043       ;;
24044     esac
24045     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
24046     # soname into executable. Probably we can add versioning support to
24047     # collect2, so additional links can be useful in future.
24048     if test "$aix_use_runtimelinking" = yes; then
24049       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
24050       # instead of lib<name>.a to let people know that these are not
24051       # typical AIX shared libraries.
24052       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24053     else
24054       # We preserve .a as extension for shared libraries through AIX4.2
24055       # and later when we are not doing run time linking.
24056       library_names_spec='${libname}${release}.a $libname.a'
24057       soname_spec='${libname}${release}${shared_ext}$major'
24058     fi
24059     shlibpath_var=LIBPATH
24060   fi
24061   ;;
24062
24063 amigaos*)
24064   library_names_spec='$libname.ixlibrary $libname.a'
24065   # Create ${libname}_ixlibrary.a entries in /sys/libs.
24066   finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
24067   ;;
24068
24069 beos*)
24070   library_names_spec='${libname}${shared_ext}'
24071   dynamic_linker="$host_os ld.so"
24072   shlibpath_var=LIBRARY_PATH
24073   ;;
24074
24075 bsdi[45]*)
24076   version_type=linux
24077   need_version=no
24078   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24079   soname_spec='${libname}${release}${shared_ext}$major'
24080   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
24081   shlibpath_var=LD_LIBRARY_PATH
24082   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
24083   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
24084   # the default ld.so.conf also contains /usr/contrib/lib and
24085   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
24086   # libtool to hard-code these into programs
24087   ;;
24088
24089 cygwin* | mingw* | pw32*)
24090   version_type=windows
24091   shrext_cmds=".dll"
24092   need_version=no
24093   need_lib_prefix=no
24094
24095   case $GCC,$host_os in
24096   yes,cygwin* | yes,mingw* | yes,pw32*)
24097     library_names_spec='$libname.dll.a'
24098     # DLL is installed to $(libdir)/../bin by postinstall_cmds
24099     postinstall_cmds='base_file=`basename \${file}`~
24100       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~
24101       dldir=$destdir/`dirname \$dlpath`~
24102       test -d \$dldir || mkdir -p \$dldir~
24103       $install_prog $dir/$dlname \$dldir/$dlname~
24104       chmod a+x \$dldir/$dlname'
24105     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
24106       dlpath=$dir/\$dldll~
24107        $rm \$dlpath'
24108     shlibpath_overrides_runpath=yes
24109
24110     case $host_os in
24111     cygwin*)
24112       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
24113       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
24114       sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
24115       ;;
24116     mingw*)
24117       # MinGW DLLs use traditional 'lib' prefix
24118       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
24119       sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
24120       if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then
24121         # It is most probably a Windows format PATH printed by
24122         # mingw gcc, but we are running on Cygwin. Gcc prints its search
24123         # path with ; separators, and with drive letters. We can handle the
24124         # drive letters (cygwin fileutils understands them), so leave them,
24125         # especially as we might pass files found there to a mingw objdump,
24126         # which wouldn't understand a cygwinified path. Ahh.
24127         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
24128       else
24129         sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
24130       fi
24131       ;;
24132     pw32*)
24133       # pw32 DLLs use 'pw' prefix rather than 'lib'
24134       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
24135       ;;
24136     esac
24137     ;;
24138
24139   *)
24140     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
24141     ;;
24142   esac
24143   dynamic_linker='Win32 ld.exe'
24144   # FIXME: first we should search . and the directory the executable is in
24145   shlibpath_var=PATH
24146   ;;
24147
24148 darwin* | rhapsody*)
24149   dynamic_linker="$host_os dyld"
24150   version_type=darwin
24151   need_lib_prefix=no
24152   need_version=no
24153   library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext'
24154   soname_spec='${libname}${release}${major}$shared_ext'
24155   shlibpath_overrides_runpath=yes
24156   shlibpath_var=DYLD_LIBRARY_PATH
24157   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
24158
24159   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
24160   ;;
24161
24162 dgux*)
24163   version_type=linux
24164   need_lib_prefix=no
24165   need_version=no
24166   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
24167   soname_spec='${libname}${release}${shared_ext}$major'
24168   shlibpath_var=LD_LIBRARY_PATH
24169   ;;
24170
24171 freebsd1*)
24172   dynamic_linker=no
24173   ;;
24174
24175 freebsd* | dragonfly*)
24176   # DragonFly does not have aout.  When/if they implement a new
24177   # versioning mechanism, adjust this.
24178   if test -x /usr/bin/objformat; then
24179     objformat=`/usr/bin/objformat`
24180   else
24181     case $host_os in
24182     freebsd[123]*) objformat=aout ;;
24183     *) objformat=elf ;;
24184     esac
24185   fi
24186   version_type=freebsd-$objformat
24187   case $version_type in
24188     freebsd-elf*)
24189       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
24190       need_version=no
24191       need_lib_prefix=no
24192       ;;
24193     freebsd-*)
24194       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
24195       need_version=yes
24196       ;;
24197   esac
24198   shlibpath_var=LD_LIBRARY_PATH
24199   case $host_os in
24200   freebsd2*)
24201     shlibpath_overrides_runpath=yes
24202     ;;
24203   freebsd3.[01]* | freebsdelf3.[01]*)
24204     shlibpath_overrides_runpath=yes
24205     hardcode_into_libs=yes
24206     ;;
24207   freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
24208   freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
24209     shlibpath_overrides_runpath=no
24210     hardcode_into_libs=yes
24211     ;;
24212   *) # from 4.6 on, and DragonFly
24213     shlibpath_overrides_runpath=yes
24214     hardcode_into_libs=yes
24215     ;;
24216   esac
24217   ;;
24218
24219 gnu*)
24220   version_type=linux
24221   need_lib_prefix=no
24222   need_version=no
24223   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
24224   soname_spec='${libname}${release}${shared_ext}$major'
24225   shlibpath_var=LD_LIBRARY_PATH
24226   hardcode_into_libs=yes
24227   ;;
24228
24229 hpux9* | hpux10* | hpux11*)
24230   # Give a soname corresponding to the major version so that dld.sl refuses to
24231   # link against other versions.
24232   version_type=sunos
24233   need_lib_prefix=no
24234   need_version=no
24235   case $host_cpu in
24236   ia64*)
24237     shrext_cmds='.so'
24238     hardcode_into_libs=yes
24239     dynamic_linker="$host_os dld.so"
24240     shlibpath_var=LD_LIBRARY_PATH
24241     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
24242     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24243     soname_spec='${libname}${release}${shared_ext}$major'
24244     if test "X$HPUX_IA64_MODE" = X32; then
24245       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
24246     else
24247       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
24248     fi
24249     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
24250     ;;
24251    hppa*64*)
24252      shrext_cmds='.sl'
24253      hardcode_into_libs=yes
24254      dynamic_linker="$host_os dld.sl"
24255      shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
24256      shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
24257      library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24258      soname_spec='${libname}${release}${shared_ext}$major'
24259      sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
24260      sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
24261      ;;
24262    *)
24263     shrext_cmds='.sl'
24264     dynamic_linker="$host_os dld.sl"
24265     shlibpath_var=SHLIB_PATH
24266     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
24267     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24268     soname_spec='${libname}${release}${shared_ext}$major'
24269     ;;
24270   esac
24271   # HP-UX runs *really* slowly unless shared libraries are mode 555.
24272   postinstall_cmds='chmod 555 $lib'
24273   ;;
24274
24275 interix[3-9]*)
24276   version_type=linux
24277   need_lib_prefix=no
24278   need_version=no
24279   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
24280   soname_spec='${libname}${release}${shared_ext}$major'
24281   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
24282   shlibpath_var=LD_LIBRARY_PATH
24283   shlibpath_overrides_runpath=no
24284   hardcode_into_libs=yes
24285   ;;
24286
24287 irix5* | irix6* | nonstopux*)
24288   case $host_os in
24289     nonstopux*) version_type=nonstopux ;;
24290     *)
24291         if test "$lt_cv_prog_gnu_ld" = yes; then
24292                 version_type=linux
24293         else
24294                 version_type=irix
24295         fi ;;
24296   esac
24297   need_lib_prefix=no
24298   need_version=no
24299   soname_spec='${libname}${release}${shared_ext}$major'
24300   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
24301   case $host_os in
24302   irix5* | nonstopux*)
24303     libsuff= shlibsuff=
24304     ;;
24305   *)
24306     case $LD in # libtool.m4 will add one of these switches to LD
24307     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
24308       libsuff= shlibsuff= libmagic=32-bit;;
24309     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
24310       libsuff=32 shlibsuff=N32 libmagic=N32;;
24311     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
24312       libsuff=64 shlibsuff=64 libmagic=64-bit;;
24313     *) libsuff= shlibsuff= libmagic=never-match;;
24314     esac
24315     ;;
24316   esac
24317   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
24318   shlibpath_overrides_runpath=no
24319   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
24320   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
24321   hardcode_into_libs=yes
24322   ;;
24323
24324 # No shared lib support for Linux oldld, aout, or coff.
24325 linux*oldld* | linux*aout* | linux*coff*)
24326   dynamic_linker=no
24327   ;;
24328
24329 # This must be Linux ELF.
24330 linux* | k*bsd*-gnu)
24331   version_type=linux
24332   need_lib_prefix=no
24333   need_version=no
24334   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24335   soname_spec='${libname}${release}${shared_ext}$major'
24336   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
24337   shlibpath_var=LD_LIBRARY_PATH
24338   shlibpath_overrides_runpath=no
24339   # This implies no fast_install, which is unacceptable.
24340   # Some rework will be needed to allow for fast_install
24341   # before this can be enabled.
24342   hardcode_into_libs=yes
24343
24344   # Append ld.so.conf contents to the search path
24345   if test -f /etc/ld.so.conf; then
24346     lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[      ]*hwcap[        ]/d;s/[:,       ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
24347     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
24348   fi
24349
24350   # We used to test for /lib/ld.so.1 and disable shared libraries on
24351   # powerpc, because MkLinux only supported shared libraries with the
24352   # GNU dynamic linker.  Since this was broken with cross compilers,
24353   # most powerpc-linux boxes support dynamic linking these days and
24354   # people can always --disable-shared, the test was removed, and we
24355   # assume the GNU/Linux dynamic linker is in use.
24356   dynamic_linker='GNU/Linux ld.so'
24357   ;;
24358
24359 netbsd*)
24360   version_type=sunos
24361   need_lib_prefix=no
24362   need_version=no
24363   if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then
24364     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
24365     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
24366     dynamic_linker='NetBSD (a.out) ld.so'
24367   else
24368     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
24369     soname_spec='${libname}${release}${shared_ext}$major'
24370     dynamic_linker='NetBSD ld.elf_so'
24371   fi
24372   shlibpath_var=LD_LIBRARY_PATH
24373   shlibpath_overrides_runpath=yes
24374   hardcode_into_libs=yes
24375   ;;
24376
24377 newsos6)
24378   version_type=linux
24379   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24380   shlibpath_var=LD_LIBRARY_PATH
24381   shlibpath_overrides_runpath=yes
24382   ;;
24383
24384 nto-qnx*)
24385   version_type=linux
24386   need_lib_prefix=no
24387   need_version=no
24388   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24389   soname_spec='${libname}${release}${shared_ext}$major'
24390   shlibpath_var=LD_LIBRARY_PATH
24391   shlibpath_overrides_runpath=yes
24392   ;;
24393
24394 openbsd*)
24395   version_type=sunos
24396   sys_lib_dlsearch_path_spec="/usr/lib"
24397   need_lib_prefix=no
24398   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
24399   case $host_os in
24400     openbsd3.3 | openbsd3.3.*) need_version=yes ;;
24401     *)                         need_version=no  ;;
24402   esac
24403   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
24404   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
24405   shlibpath_var=LD_LIBRARY_PATH
24406   if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
24407     case $host_os in
24408       openbsd2.[89] | openbsd2.[89].*)
24409         shlibpath_overrides_runpath=no
24410         ;;
24411       *)
24412         shlibpath_overrides_runpath=yes
24413         ;;
24414       esac
24415   else
24416     shlibpath_overrides_runpath=yes
24417   fi
24418   ;;
24419
24420 os2*)
24421   libname_spec='$name'
24422   shrext_cmds=".dll"
24423   need_lib_prefix=no
24424   library_names_spec='$libname${shared_ext} $libname.a'
24425   dynamic_linker='OS/2 ld.exe'
24426   shlibpath_var=LIBPATH
24427   ;;
24428
24429 osf3* | osf4* | osf5*)
24430   version_type=osf
24431   need_lib_prefix=no
24432   need_version=no
24433   soname_spec='${libname}${release}${shared_ext}$major'
24434   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24435   shlibpath_var=LD_LIBRARY_PATH
24436   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
24437   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
24438   ;;
24439
24440 rdos*)
24441   dynamic_linker=no
24442   ;;
24443
24444 solaris*)
24445   version_type=linux
24446   need_lib_prefix=no
24447   need_version=no
24448   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24449   soname_spec='${libname}${release}${shared_ext}$major'
24450   shlibpath_var=LD_LIBRARY_PATH
24451   shlibpath_overrides_runpath=yes
24452   hardcode_into_libs=yes
24453   # ldd complains unless libraries are executable
24454   postinstall_cmds='chmod +x $lib'
24455   ;;
24456
24457 sunos4*)
24458   version_type=sunos
24459   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
24460   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
24461   shlibpath_var=LD_LIBRARY_PATH
24462   shlibpath_overrides_runpath=yes
24463   if test "$with_gnu_ld" = yes; then
24464     need_lib_prefix=no
24465   fi
24466   need_version=yes
24467   ;;
24468
24469 sysv4 | sysv4.3*)
24470   version_type=linux
24471   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24472   soname_spec='${libname}${release}${shared_ext}$major'
24473   shlibpath_var=LD_LIBRARY_PATH
24474   case $host_vendor in
24475     sni)
24476       shlibpath_overrides_runpath=no
24477       need_lib_prefix=no
24478       export_dynamic_flag_spec='${wl}-Blargedynsym'
24479       runpath_var=LD_RUN_PATH
24480       ;;
24481     siemens)
24482       need_lib_prefix=no
24483       ;;
24484     motorola)
24485       need_lib_prefix=no
24486       need_version=no
24487       shlibpath_overrides_runpath=no
24488       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
24489       ;;
24490   esac
24491   ;;
24492
24493 sysv4*MP*)
24494   if test -d /usr/nec ;then
24495     version_type=linux
24496     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
24497     soname_spec='$libname${shared_ext}.$major'
24498     shlibpath_var=LD_LIBRARY_PATH
24499   fi
24500   ;;
24501
24502 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
24503   version_type=freebsd-elf
24504   need_lib_prefix=no
24505   need_version=no
24506   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
24507   soname_spec='${libname}${release}${shared_ext}$major'
24508   shlibpath_var=LD_LIBRARY_PATH
24509   hardcode_into_libs=yes
24510   if test "$with_gnu_ld" = yes; then
24511     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
24512     shlibpath_overrides_runpath=no
24513   else
24514     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
24515     shlibpath_overrides_runpath=yes
24516     case $host_os in
24517       sco3.2v5*)
24518         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
24519         ;;
24520     esac
24521   fi
24522   sys_lib_dlsearch_path_spec='/usr/lib'
24523   ;;
24524
24525 uts4*)
24526   version_type=linux
24527   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
24528   soname_spec='${libname}${release}${shared_ext}$major'
24529   shlibpath_var=LD_LIBRARY_PATH
24530   ;;
24531
24532 *)
24533   dynamic_linker=no
24534   ;;
24535 esac
24536 { echo "$as_me:$LINENO: result: $dynamic_linker" >&5
24537 echo "${ECHO_T}$dynamic_linker" >&6; }
24538 test "$dynamic_linker" = no && can_build_shared=no
24539
24540 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
24541 if test "$GCC" = yes; then
24542   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
24543 fi
24544
24545 { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
24546 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; }
24547 hardcode_action_GCJ=
24548 if test -n "$hardcode_libdir_flag_spec_GCJ" || \
24549    test -n "$runpath_var_GCJ" || \
24550    test "X$hardcode_automatic_GCJ" = "Xyes" ; then
24551
24552   # We can hardcode non-existant directories.
24553   if test "$hardcode_direct_GCJ" != no &&
24554      # If the only mechanism to avoid hardcoding is shlibpath_var, we
24555      # have to relink, otherwise we might link with an installed library
24556      # when we should be linking with a yet-to-be-installed one
24557      ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, GCJ)" != no &&
24558      test "$hardcode_minus_L_GCJ" != no; then
24559     # Linking always hardcodes the temporary library directory.
24560     hardcode_action_GCJ=relink
24561   else
24562     # We can link without hardcoding, and we can hardcode nonexisting dirs.
24563     hardcode_action_GCJ=immediate
24564   fi
24565 else
24566   # We cannot hardcode anything, or else we can only hardcode existing
24567   # directories.
24568   hardcode_action_GCJ=unsupported
24569 fi
24570 { echo "$as_me:$LINENO: result: $hardcode_action_GCJ" >&5
24571 echo "${ECHO_T}$hardcode_action_GCJ" >&6; }
24572
24573 if test "$hardcode_action_GCJ" = relink; then
24574   # Fast installation is not supported
24575   enable_fast_install=no
24576 elif test "$shlibpath_overrides_runpath" = yes ||
24577      test "$enable_shared" = no; then
24578   # Fast installation is not necessary
24579   enable_fast_install=needless
24580 fi
24581
24582
24583 # The else clause should only fire when bootstrapping the
24584 # libtool distribution, otherwise you forgot to ship ltmain.sh
24585 # with your package, and you will get complaints that there are
24586 # no rules to generate ltmain.sh.
24587 if test -f "$ltmain"; then
24588   # See if we are running on zsh, and set the options which allow our commands through
24589   # without removal of \ escapes.
24590   if test -n "${ZSH_VERSION+set}" ; then
24591     setopt NO_GLOB_SUBST
24592   fi
24593   # Now quote all the things that may contain metacharacters while being
24594   # careful not to overquote the AC_SUBSTed values.  We take copies of the
24595   # variables and quote the copies for generation of the libtool script.
24596   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
24597     SED SHELL STRIP \
24598     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
24599     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
24600     deplibs_check_method reload_flag reload_cmds need_locks \
24601     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
24602     lt_cv_sys_global_symbol_to_c_name_address \
24603     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
24604     old_postinstall_cmds old_postuninstall_cmds \
24605     compiler_GCJ \
24606     CC_GCJ \
24607     LD_GCJ \
24608     lt_prog_compiler_wl_GCJ \
24609     lt_prog_compiler_pic_GCJ \
24610     lt_prog_compiler_static_GCJ \
24611     lt_prog_compiler_no_builtin_flag_GCJ \
24612     export_dynamic_flag_spec_GCJ \
24613     thread_safe_flag_spec_GCJ \
24614     whole_archive_flag_spec_GCJ \
24615     enable_shared_with_static_runtimes_GCJ \
24616     old_archive_cmds_GCJ \
24617     old_archive_from_new_cmds_GCJ \
24618     predep_objects_GCJ \
24619     postdep_objects_GCJ \
24620     predeps_GCJ \
24621     postdeps_GCJ \
24622     compiler_lib_search_path_GCJ \
24623     archive_cmds_GCJ \
24624     archive_expsym_cmds_GCJ \
24625     postinstall_cmds_GCJ \
24626     postuninstall_cmds_GCJ \
24627     old_archive_from_expsyms_cmds_GCJ \
24628     allow_undefined_flag_GCJ \
24629     no_undefined_flag_GCJ \
24630     export_symbols_cmds_GCJ \
24631     hardcode_libdir_flag_spec_GCJ \
24632     hardcode_libdir_flag_spec_ld_GCJ \
24633     hardcode_libdir_separator_GCJ \
24634     hardcode_automatic_GCJ \
24635     module_cmds_GCJ \
24636     module_expsym_cmds_GCJ \
24637     lt_cv_prog_compiler_c_o_GCJ \
24638     fix_srcfile_path_GCJ \
24639     exclude_expsyms_GCJ \
24640     include_expsyms_GCJ; do
24641
24642     case $var in
24643     old_archive_cmds_GCJ | \
24644     old_archive_from_new_cmds_GCJ | \
24645     archive_cmds_GCJ | \
24646     archive_expsym_cmds_GCJ | \
24647     module_cmds_GCJ | \
24648     module_expsym_cmds_GCJ | \
24649     old_archive_from_expsyms_cmds_GCJ | \
24650     export_symbols_cmds_GCJ | \
24651     extract_expsyms_cmds | reload_cmds | finish_cmds | \
24652     postinstall_cmds | postuninstall_cmds | \
24653     old_postinstall_cmds | old_postuninstall_cmds | \
24654     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
24655       # Double-quote double-evaled strings.
24656       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
24657       ;;
24658     *)
24659       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
24660       ;;
24661     esac
24662   done
24663
24664   case $lt_echo in
24665   *'\$0 --fallback-echo"')
24666     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
24667     ;;
24668   esac
24669
24670 cfgfile="$ofile"
24671
24672   cat <<__EOF__ >> "$cfgfile"
24673 # ### BEGIN LIBTOOL TAG CONFIG: $tagname
24674
24675 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
24676
24677 # Shell to use when invoking shell scripts.
24678 SHELL=$lt_SHELL
24679
24680 # Whether or not to build shared libraries.
24681 build_libtool_libs=$enable_shared
24682
24683 # Whether or not to build static libraries.
24684 build_old_libs=$enable_static
24685
24686 # Whether or not to add -lc for building shared libraries.
24687 build_libtool_need_lc=$archive_cmds_need_lc_GCJ
24688
24689 # Whether or not to disallow shared libs when runtime libs are static
24690 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_GCJ
24691
24692 # Whether or not to optimize for fast installation.
24693 fast_install=$enable_fast_install
24694
24695 # The host system.
24696 host_alias=$host_alias
24697 host=$host
24698 host_os=$host_os
24699
24700 # The build system.
24701 build_alias=$build_alias
24702 build=$build
24703 build_os=$build_os
24704
24705 # An echo program that does not interpret backslashes.
24706 echo=$lt_echo
24707
24708 # The archiver.
24709 AR=$lt_AR
24710 AR_FLAGS=$lt_AR_FLAGS
24711
24712 # A C compiler.
24713 LTCC=$lt_LTCC
24714
24715 # LTCC compiler flags.
24716 LTCFLAGS=$lt_LTCFLAGS
24717
24718 # A language-specific compiler.
24719 CC=$lt_compiler_GCJ
24720
24721 # Is the compiler the GNU C compiler?
24722 with_gcc=$GCC_GCJ
24723
24724 # An ERE matcher.
24725 EGREP=$lt_EGREP
24726
24727 # The linker used to build libraries.
24728 LD=$lt_LD_GCJ
24729
24730 # Whether we need hard or soft links.
24731 LN_S=$lt_LN_S
24732
24733 # A BSD-compatible nm program.
24734 NM=$lt_NM
24735
24736 # A symbol stripping program
24737 STRIP=$lt_STRIP
24738
24739 # Used to examine libraries when file_magic_cmd begins "file"
24740 MAGIC_CMD=$MAGIC_CMD
24741
24742 # Used on cygwin: DLL creation program.
24743 DLLTOOL="$DLLTOOL"
24744
24745 # Used on cygwin: object dumper.
24746 OBJDUMP="$OBJDUMP"
24747
24748 # Used on cygwin: assembler.
24749 AS="$AS"
24750
24751 # The name of the directory that contains temporary libtool files.
24752 objdir=$objdir
24753
24754 # How to create reloadable object files.
24755 reload_flag=$lt_reload_flag
24756 reload_cmds=$lt_reload_cmds
24757
24758 # How to pass a linker flag through the compiler.
24759 wl=$lt_lt_prog_compiler_wl_GCJ
24760
24761 # Object file suffix (normally "o").
24762 objext="$ac_objext"
24763
24764 # Old archive suffix (normally "a").
24765 libext="$libext"
24766
24767 # Shared library suffix (normally ".so").
24768 shrext_cmds='$shrext_cmds'
24769
24770 # Executable file suffix (normally "").
24771 exeext="$exeext"
24772
24773 # Additional compiler flags for building library objects.
24774 pic_flag=$lt_lt_prog_compiler_pic_GCJ
24775 pic_mode=$pic_mode
24776
24777 # What is the maximum length of a command?
24778 max_cmd_len=$lt_cv_sys_max_cmd_len
24779
24780 # Does compiler simultaneously support -c and -o options?
24781 compiler_c_o=$lt_lt_cv_prog_compiler_c_o_GCJ
24782
24783 # Must we lock files when doing compilation?
24784 need_locks=$lt_need_locks
24785
24786 # Do we need the lib prefix for modules?
24787 need_lib_prefix=$need_lib_prefix
24788
24789 # Do we need a version for libraries?
24790 need_version=$need_version
24791
24792 # Whether dlopen is supported.
24793 dlopen_support=$enable_dlopen
24794
24795 # Whether dlopen of programs is supported.
24796 dlopen_self=$enable_dlopen_self
24797
24798 # Whether dlopen of statically linked programs is supported.
24799 dlopen_self_static=$enable_dlopen_self_static
24800
24801 # Compiler flag to prevent dynamic linking.
24802 link_static_flag=$lt_lt_prog_compiler_static_GCJ
24803
24804 # Compiler flag to turn off builtin functions.
24805 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_GCJ
24806
24807 # Compiler flag to allow reflexive dlopens.
24808 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_GCJ
24809
24810 # Compiler flag to generate shared objects directly from archives.
24811 whole_archive_flag_spec=$lt_whole_archive_flag_spec_GCJ
24812
24813 # Compiler flag to generate thread-safe objects.
24814 thread_safe_flag_spec=$lt_thread_safe_flag_spec_GCJ
24815
24816 # Library versioning type.
24817 version_type=$version_type
24818
24819 # Format of library name prefix.
24820 libname_spec=$lt_libname_spec
24821
24822 # List of archive names.  First name is the real one, the rest are links.
24823 # The last name is the one that the linker finds with -lNAME.
24824 library_names_spec=$lt_library_names_spec
24825
24826 # The coded name of the library, if different from the real name.
24827 soname_spec=$lt_soname_spec
24828
24829 # Commands used to build and install an old-style archive.
24830 RANLIB=$lt_RANLIB
24831 old_archive_cmds=$lt_old_archive_cmds_GCJ
24832 old_postinstall_cmds=$lt_old_postinstall_cmds
24833 old_postuninstall_cmds=$lt_old_postuninstall_cmds
24834
24835 # Create an old-style archive from a shared archive.
24836 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_GCJ
24837
24838 # Create a temporary old-style archive to link instead of a shared archive.
24839 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_GCJ
24840
24841 # Commands used to build and install a shared archive.
24842 archive_cmds=$lt_archive_cmds_GCJ
24843 archive_expsym_cmds=$lt_archive_expsym_cmds_GCJ
24844 postinstall_cmds=$lt_postinstall_cmds
24845 postuninstall_cmds=$lt_postuninstall_cmds
24846
24847 # Commands used to build a loadable module (assumed same as above if empty)
24848 module_cmds=$lt_module_cmds_GCJ
24849 module_expsym_cmds=$lt_module_expsym_cmds_GCJ
24850
24851 # Commands to strip libraries.
24852 old_striplib=$lt_old_striplib
24853 striplib=$lt_striplib
24854
24855 # Dependencies to place before the objects being linked to create a
24856 # shared library.
24857 predep_objects=$lt_predep_objects_GCJ
24858
24859 # Dependencies to place after the objects being linked to create a
24860 # shared library.
24861 postdep_objects=$lt_postdep_objects_GCJ
24862
24863 # Dependencies to place before the objects being linked to create a
24864 # shared library.
24865 predeps=$lt_predeps_GCJ
24866
24867 # Dependencies to place after the objects being linked to create a
24868 # shared library.
24869 postdeps=$lt_postdeps_GCJ
24870
24871 # The library search path used internally by the compiler when linking
24872 # a shared library.
24873 compiler_lib_search_path=$lt_compiler_lib_search_path_GCJ
24874
24875 # Method to check whether dependent libraries are shared objects.
24876 deplibs_check_method=$lt_deplibs_check_method
24877
24878 # Command to use when deplibs_check_method == file_magic.
24879 file_magic_cmd=$lt_file_magic_cmd
24880
24881 # Flag that allows shared libraries with undefined symbols to be built.
24882 allow_undefined_flag=$lt_allow_undefined_flag_GCJ
24883
24884 # Flag that forces no undefined symbols.
24885 no_undefined_flag=$lt_no_undefined_flag_GCJ
24886
24887 # Commands used to finish a libtool library installation in a directory.
24888 finish_cmds=$lt_finish_cmds
24889
24890 # Same as above, but a single script fragment to be evaled but not shown.
24891 finish_eval=$lt_finish_eval
24892
24893 # Take the output of nm and produce a listing of raw symbols and C names.
24894 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
24895
24896 # Transform the output of nm in a proper C declaration
24897 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
24898
24899 # Transform the output of nm in a C name address pair
24900 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
24901
24902 # This is the shared library runtime path variable.
24903 runpath_var=$runpath_var
24904
24905 # This is the shared library path variable.
24906 shlibpath_var=$shlibpath_var
24907
24908 # Is shlibpath searched before the hard-coded library search path?
24909 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
24910
24911 # How to hardcode a shared library path into an executable.
24912 hardcode_action=$hardcode_action_GCJ
24913
24914 # Whether we should hardcode library paths into libraries.
24915 hardcode_into_libs=$hardcode_into_libs
24916
24917 # Flag to hardcode \$libdir into a binary during linking.
24918 # This must work even if \$libdir does not exist.
24919 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_GCJ
24920
24921 # If ld is used when linking, flag to hardcode \$libdir into
24922 # a binary during linking. This must work even if \$libdir does
24923 # not exist.
24924 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_GCJ
24925
24926 # Whether we need a single -rpath flag with a separated argument.
24927 hardcode_libdir_separator=$lt_hardcode_libdir_separator_GCJ
24928
24929 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
24930 # resulting binary.
24931 hardcode_direct=$hardcode_direct_GCJ
24932
24933 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
24934 # resulting binary.
24935 hardcode_minus_L=$hardcode_minus_L_GCJ
24936
24937 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
24938 # the resulting binary.
24939 hardcode_shlibpath_var=$hardcode_shlibpath_var_GCJ
24940
24941 # Set to yes if building a shared library automatically hardcodes DIR into the library
24942 # and all subsequent libraries and executables linked against it.
24943 hardcode_automatic=$hardcode_automatic_GCJ
24944
24945 # Variables whose values should be saved in libtool wrapper scripts and
24946 # restored at relink time.
24947 variables_saved_for_relink="$variables_saved_for_relink"
24948
24949 # Whether libtool must link a program against all its dependency libraries.
24950 link_all_deplibs=$link_all_deplibs_GCJ
24951
24952 # Compile-time system search path for libraries
24953 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
24954
24955 # Run-time system search path for libraries
24956 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
24957
24958 # Fix the shell variable \$srcfile for the compiler.
24959 fix_srcfile_path=$lt_fix_srcfile_path
24960
24961 # Set to yes if exported symbols are required.
24962 always_export_symbols=$always_export_symbols_GCJ
24963
24964 # The commands to list exported symbols.
24965 export_symbols_cmds=$lt_export_symbols_cmds_GCJ
24966
24967 # The commands to extract the exported symbol list from a shared archive.
24968 extract_expsyms_cmds=$lt_extract_expsyms_cmds
24969
24970 # Symbols that should not be listed in the preloaded symbols.
24971 exclude_expsyms=$lt_exclude_expsyms_GCJ
24972
24973 # Symbols that must always be exported.
24974 include_expsyms=$lt_include_expsyms_GCJ
24975
24976 # ### END LIBTOOL TAG CONFIG: $tagname
24977
24978 __EOF__
24979
24980
24981 else
24982   # If there is no Makefile yet, we rely on a make rule to execute
24983   # `config.status --recheck' to rerun these tests and create the
24984   # libtool script then.
24985   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
24986   if test -f "$ltmain_in"; then
24987     test -f Makefile && make "$ltmain"
24988   fi
24989 fi
24990
24991
24992 ac_ext=c
24993 ac_cpp='$CPP $CPPFLAGS'
24994 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
24995 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
24996 ac_compiler_gnu=$ac_cv_c_compiler_gnu
24997
24998 CC="$lt_save_CC"
24999
25000         else
25001           tagname=""
25002         fi
25003         ;;
25004
25005       RC)
25006
25007
25008 # Source file extension for RC test sources.
25009 ac_ext=rc
25010
25011 # Object file extension for compiled RC test sources.
25012 objext=o
25013 objext_RC=$objext
25014
25015 # Code to be used in simple compile tests
25016 lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }'
25017
25018 # Code to be used in simple link tests
25019 lt_simple_link_test_code="$lt_simple_compile_test_code"
25020
25021 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
25022
25023 # If no C compiler was specified, use CC.
25024 LTCC=${LTCC-"$CC"}
25025
25026 # If no C compiler flags were specified, use CFLAGS.
25027 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
25028
25029 # Allow CC to be a program name with arguments.
25030 compiler=$CC
25031
25032
25033 # save warnings/boilerplate of simple test code
25034 ac_outfile=conftest.$ac_objext
25035 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
25036 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
25037 _lt_compiler_boilerplate=`cat conftest.err`
25038 $rm conftest*
25039
25040 ac_outfile=conftest.$ac_objext
25041 echo "$lt_simple_link_test_code" >conftest.$ac_ext
25042 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
25043 _lt_linker_boilerplate=`cat conftest.err`
25044 $rm conftest*
25045
25046
25047 # Allow CC to be a program name with arguments.
25048 lt_save_CC="$CC"
25049 CC=${RC-"windres"}
25050 compiler=$CC
25051 compiler_RC=$CC
25052 for cc_temp in $compiler""; do
25053   case $cc_temp in
25054     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
25055     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
25056     \-*) ;;
25057     *) break;;
25058   esac
25059 done
25060 cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
25061
25062 lt_cv_prog_compiler_c_o_RC=yes
25063
25064 # The else clause should only fire when bootstrapping the
25065 # libtool distribution, otherwise you forgot to ship ltmain.sh
25066 # with your package, and you will get complaints that there are
25067 # no rules to generate ltmain.sh.
25068 if test -f "$ltmain"; then
25069   # See if we are running on zsh, and set the options which allow our commands through
25070   # without removal of \ escapes.
25071   if test -n "${ZSH_VERSION+set}" ; then
25072     setopt NO_GLOB_SUBST
25073   fi
25074   # Now quote all the things that may contain metacharacters while being
25075   # careful not to overquote the AC_SUBSTed values.  We take copies of the
25076   # variables and quote the copies for generation of the libtool script.
25077   for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
25078     SED SHELL STRIP \
25079     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
25080     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
25081     deplibs_check_method reload_flag reload_cmds need_locks \
25082     lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \
25083     lt_cv_sys_global_symbol_to_c_name_address \
25084     sys_lib_search_path_spec sys_lib_dlsearch_path_spec \
25085     old_postinstall_cmds old_postuninstall_cmds \
25086     compiler_RC \
25087     CC_RC \
25088     LD_RC \
25089     lt_prog_compiler_wl_RC \
25090     lt_prog_compiler_pic_RC \
25091     lt_prog_compiler_static_RC \
25092     lt_prog_compiler_no_builtin_flag_RC \
25093     export_dynamic_flag_spec_RC \
25094     thread_safe_flag_spec_RC \
25095     whole_archive_flag_spec_RC \
25096     enable_shared_with_static_runtimes_RC \
25097     old_archive_cmds_RC \
25098     old_archive_from_new_cmds_RC \
25099     predep_objects_RC \
25100     postdep_objects_RC \
25101     predeps_RC \
25102     postdeps_RC \
25103     compiler_lib_search_path_RC \
25104     archive_cmds_RC \
25105     archive_expsym_cmds_RC \
25106     postinstall_cmds_RC \
25107     postuninstall_cmds_RC \
25108     old_archive_from_expsyms_cmds_RC \
25109     allow_undefined_flag_RC \
25110     no_undefined_flag_RC \
25111     export_symbols_cmds_RC \
25112     hardcode_libdir_flag_spec_RC \
25113     hardcode_libdir_flag_spec_ld_RC \
25114     hardcode_libdir_separator_RC \
25115     hardcode_automatic_RC \
25116     module_cmds_RC \
25117     module_expsym_cmds_RC \
25118     lt_cv_prog_compiler_c_o_RC \
25119     fix_srcfile_path_RC \
25120     exclude_expsyms_RC \
25121     include_expsyms_RC; do
25122
25123     case $var in
25124     old_archive_cmds_RC | \
25125     old_archive_from_new_cmds_RC | \
25126     archive_cmds_RC | \
25127     archive_expsym_cmds_RC | \
25128     module_cmds_RC | \
25129     module_expsym_cmds_RC | \
25130     old_archive_from_expsyms_cmds_RC | \
25131     export_symbols_cmds_RC | \
25132     extract_expsyms_cmds | reload_cmds | finish_cmds | \
25133     postinstall_cmds | postuninstall_cmds | \
25134     old_postinstall_cmds | old_postuninstall_cmds | \
25135     sys_lib_search_path_spec | sys_lib_dlsearch_path_spec)
25136       # Double-quote double-evaled strings.
25137       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\""
25138       ;;
25139     *)
25140       eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\""
25141       ;;
25142     esac
25143   done
25144
25145   case $lt_echo in
25146   *'\$0 --fallback-echo"')
25147     lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'`
25148     ;;
25149   esac
25150
25151 cfgfile="$ofile"
25152
25153   cat <<__EOF__ >> "$cfgfile"
25154 # ### BEGIN LIBTOOL TAG CONFIG: $tagname
25155
25156 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
25157
25158 # Shell to use when invoking shell scripts.
25159 SHELL=$lt_SHELL
25160
25161 # Whether or not to build shared libraries.
25162 build_libtool_libs=$enable_shared
25163
25164 # Whether or not to build static libraries.
25165 build_old_libs=$enable_static
25166
25167 # Whether or not to add -lc for building shared libraries.
25168 build_libtool_need_lc=$archive_cmds_need_lc_RC
25169
25170 # Whether or not to disallow shared libs when runtime libs are static
25171 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC
25172
25173 # Whether or not to optimize for fast installation.
25174 fast_install=$enable_fast_install
25175
25176 # The host system.
25177 host_alias=$host_alias
25178 host=$host
25179 host_os=$host_os
25180
25181 # The build system.
25182 build_alias=$build_alias
25183 build=$build
25184 build_os=$build_os
25185
25186 # An echo program that does not interpret backslashes.
25187 echo=$lt_echo
25188
25189 # The archiver.
25190 AR=$lt_AR
25191 AR_FLAGS=$lt_AR_FLAGS
25192
25193 # A C compiler.
25194 LTCC=$lt_LTCC
25195
25196 # LTCC compiler flags.
25197 LTCFLAGS=$lt_LTCFLAGS
25198
25199 # A language-specific compiler.
25200 CC=$lt_compiler_RC
25201
25202 # Is the compiler the GNU C compiler?
25203 with_gcc=$GCC_RC
25204
25205 # An ERE matcher.
25206 EGREP=$lt_EGREP
25207
25208 # The linker used to build libraries.
25209 LD=$lt_LD_RC
25210
25211 # Whether we need hard or soft links.
25212 LN_S=$lt_LN_S
25213
25214 # A BSD-compatible nm program.
25215 NM=$lt_NM
25216
25217 # A symbol stripping program
25218 STRIP=$lt_STRIP
25219
25220 # Used to examine libraries when file_magic_cmd begins "file"
25221 MAGIC_CMD=$MAGIC_CMD
25222
25223 # Used on cygwin: DLL creation program.
25224 DLLTOOL="$DLLTOOL"
25225
25226 # Used on cygwin: object dumper.
25227 OBJDUMP="$OBJDUMP"
25228
25229 # Used on cygwin: assembler.
25230 AS="$AS"
25231
25232 # The name of the directory that contains temporary libtool files.
25233 objdir=$objdir
25234
25235 # How to create reloadable object files.
25236 reload_flag=$lt_reload_flag
25237 reload_cmds=$lt_reload_cmds
25238
25239 # How to pass a linker flag through the compiler.
25240 wl=$lt_lt_prog_compiler_wl_RC
25241
25242 # Object file suffix (normally "o").
25243 objext="$ac_objext"
25244
25245 # Old archive suffix (normally "a").
25246 libext="$libext"
25247
25248 # Shared library suffix (normally ".so").
25249 shrext_cmds='$shrext_cmds'
25250
25251 # Executable file suffix (normally "").
25252 exeext="$exeext"
25253
25254 # Additional compiler flags for building library objects.
25255 pic_flag=$lt_lt_prog_compiler_pic_RC
25256 pic_mode=$pic_mode
25257
25258 # What is the maximum length of a command?
25259 max_cmd_len=$lt_cv_sys_max_cmd_len
25260
25261 # Does compiler simultaneously support -c and -o options?
25262 compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC
25263
25264 # Must we lock files when doing compilation?
25265 need_locks=$lt_need_locks
25266
25267 # Do we need the lib prefix for modules?
25268 need_lib_prefix=$need_lib_prefix
25269
25270 # Do we need a version for libraries?
25271 need_version=$need_version
25272
25273 # Whether dlopen is supported.
25274 dlopen_support=$enable_dlopen
25275
25276 # Whether dlopen of programs is supported.
25277 dlopen_self=$enable_dlopen_self
25278
25279 # Whether dlopen of statically linked programs is supported.
25280 dlopen_self_static=$enable_dlopen_self_static
25281
25282 # Compiler flag to prevent dynamic linking.
25283 link_static_flag=$lt_lt_prog_compiler_static_RC
25284
25285 # Compiler flag to turn off builtin functions.
25286 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC
25287
25288 # Compiler flag to allow reflexive dlopens.
25289 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC
25290
25291 # Compiler flag to generate shared objects directly from archives.
25292 whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC
25293
25294 # Compiler flag to generate thread-safe objects.
25295 thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC
25296
25297 # Library versioning type.
25298 version_type=$version_type
25299
25300 # Format of library name prefix.
25301 libname_spec=$lt_libname_spec
25302
25303 # List of archive names.  First name is the real one, the rest are links.
25304 # The last name is the one that the linker finds with -lNAME.
25305 library_names_spec=$lt_library_names_spec
25306
25307 # The coded name of the library, if different from the real name.
25308 soname_spec=$lt_soname_spec
25309
25310 # Commands used to build and install an old-style archive.
25311 RANLIB=$lt_RANLIB
25312 old_archive_cmds=$lt_old_archive_cmds_RC
25313 old_postinstall_cmds=$lt_old_postinstall_cmds
25314 old_postuninstall_cmds=$lt_old_postuninstall_cmds
25315
25316 # Create an old-style archive from a shared archive.
25317 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC
25318
25319 # Create a temporary old-style archive to link instead of a shared archive.
25320 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC
25321
25322 # Commands used to build and install a shared archive.
25323 archive_cmds=$lt_archive_cmds_RC
25324 archive_expsym_cmds=$lt_archive_expsym_cmds_RC
25325 postinstall_cmds=$lt_postinstall_cmds
25326 postuninstall_cmds=$lt_postuninstall_cmds
25327
25328 # Commands used to build a loadable module (assumed same as above if empty)
25329 module_cmds=$lt_module_cmds_RC
25330 module_expsym_cmds=$lt_module_expsym_cmds_RC
25331
25332 # Commands to strip libraries.
25333 old_striplib=$lt_old_striplib
25334 striplib=$lt_striplib
25335
25336 # Dependencies to place before the objects being linked to create a
25337 # shared library.
25338 predep_objects=$lt_predep_objects_RC
25339
25340 # Dependencies to place after the objects being linked to create a
25341 # shared library.
25342 postdep_objects=$lt_postdep_objects_RC
25343
25344 # Dependencies to place before the objects being linked to create a
25345 # shared library.
25346 predeps=$lt_predeps_RC
25347
25348 # Dependencies to place after the objects being linked to create a
25349 # shared library.
25350 postdeps=$lt_postdeps_RC
25351
25352 # The library search path used internally by the compiler when linking
25353 # a shared library.
25354 compiler_lib_search_path=$lt_compiler_lib_search_path_RC
25355
25356 # Method to check whether dependent libraries are shared objects.
25357 deplibs_check_method=$lt_deplibs_check_method
25358
25359 # Command to use when deplibs_check_method == file_magic.
25360 file_magic_cmd=$lt_file_magic_cmd
25361
25362 # Flag that allows shared libraries with undefined symbols to be built.
25363 allow_undefined_flag=$lt_allow_undefined_flag_RC
25364
25365 # Flag that forces no undefined symbols.
25366 no_undefined_flag=$lt_no_undefined_flag_RC
25367
25368 # Commands used to finish a libtool library installation in a directory.
25369 finish_cmds=$lt_finish_cmds
25370
25371 # Same as above, but a single script fragment to be evaled but not shown.
25372 finish_eval=$lt_finish_eval
25373
25374 # Take the output of nm and produce a listing of raw symbols and C names.
25375 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
25376
25377 # Transform the output of nm in a proper C declaration
25378 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
25379
25380 # Transform the output of nm in a C name address pair
25381 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
25382
25383 # This is the shared library runtime path variable.
25384 runpath_var=$runpath_var
25385
25386 # This is the shared library path variable.
25387 shlibpath_var=$shlibpath_var
25388
25389 # Is shlibpath searched before the hard-coded library search path?
25390 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
25391
25392 # How to hardcode a shared library path into an executable.
25393 hardcode_action=$hardcode_action_RC
25394
25395 # Whether we should hardcode library paths into libraries.
25396 hardcode_into_libs=$hardcode_into_libs
25397
25398 # Flag to hardcode \$libdir into a binary during linking.
25399 # This must work even if \$libdir does not exist.
25400 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC
25401
25402 # If ld is used when linking, flag to hardcode \$libdir into
25403 # a binary during linking. This must work even if \$libdir does
25404 # not exist.
25405 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC
25406
25407 # Whether we need a single -rpath flag with a separated argument.
25408 hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC
25409
25410 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the
25411 # resulting binary.
25412 hardcode_direct=$hardcode_direct_RC
25413
25414 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the
25415 # resulting binary.
25416 hardcode_minus_L=$hardcode_minus_L_RC
25417
25418 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into
25419 # the resulting binary.
25420 hardcode_shlibpath_var=$hardcode_shlibpath_var_RC
25421
25422 # Set to yes if building a shared library automatically hardcodes DIR into the library
25423 # and all subsequent libraries and executables linked against it.
25424 hardcode_automatic=$hardcode_automatic_RC
25425
25426 # Variables whose values should be saved in libtool wrapper scripts and
25427 # restored at relink time.
25428 variables_saved_for_relink="$variables_saved_for_relink"
25429
25430 # Whether libtool must link a program against all its dependency libraries.
25431 link_all_deplibs=$link_all_deplibs_RC
25432
25433 # Compile-time system search path for libraries
25434 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
25435
25436 # Run-time system search path for libraries
25437 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
25438
25439 # Fix the shell variable \$srcfile for the compiler.
25440 fix_srcfile_path=$lt_fix_srcfile_path
25441
25442 # Set to yes if exported symbols are required.
25443 always_export_symbols=$always_export_symbols_RC
25444
25445 # The commands to list exported symbols.
25446 export_symbols_cmds=$lt_export_symbols_cmds_RC
25447
25448 # The commands to extract the exported symbol list from a shared archive.
25449 extract_expsyms_cmds=$lt_extract_expsyms_cmds
25450
25451 # Symbols that should not be listed in the preloaded symbols.
25452 exclude_expsyms=$lt_exclude_expsyms_RC
25453
25454 # Symbols that must always be exported.
25455 include_expsyms=$lt_include_expsyms_RC
25456
25457 # ### END LIBTOOL TAG CONFIG: $tagname
25458
25459 __EOF__
25460
25461
25462 else
25463   # If there is no Makefile yet, we rely on a make rule to execute
25464   # `config.status --recheck' to rerun these tests and create the
25465   # libtool script then.
25466   ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'`
25467   if test -f "$ltmain_in"; then
25468     test -f Makefile && make "$ltmain"
25469   fi
25470 fi
25471
25472
25473 ac_ext=c
25474 ac_cpp='$CPP $CPPFLAGS'
25475 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
25476 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
25477 ac_compiler_gnu=$ac_cv_c_compiler_gnu
25478
25479 CC="$lt_save_CC"
25480
25481         ;;
25482
25483       *)
25484         { { echo "$as_me:$LINENO: error: Unsupported tag name: $tagname" >&5
25485 echo "$as_me: error: Unsupported tag name: $tagname" >&2;}
25486    { (exit 1); exit 1; }; }
25487         ;;
25488       esac
25489
25490       # Append the new tag name to the list of available tags.
25491       if test -n "$tagname" ; then
25492       available_tags="$available_tags $tagname"
25493     fi
25494     fi
25495   done
25496   IFS="$lt_save_ifs"
25497
25498   # Now substitute the updated list of available tags.
25499   if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then
25500     mv "${ofile}T" "$ofile"
25501     chmod +x "$ofile"
25502   else
25503     rm -f "${ofile}T"
25504     { { echo "$as_me:$LINENO: error: unable to update list of available tagged configurations." >&5
25505 echo "$as_me: error: unable to update list of available tagged configurations." >&2;}
25506    { (exit 1); exit 1; }; }
25507   fi
25508 fi
25509
25510
25511
25512 # This can be used to rebuild libtool when needed
25513 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
25514
25515 # Always use our own libtool.
25516 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
25517
25518 # Prevent multiple expansion
25519
25520
25521
25522
25523
25524
25525
25526
25527
25528
25529
25530
25531
25532
25533
25534
25535
25536
25537
25538
25539
25540 # Generate an error here if attempting to build both shared and static when
25541 # $libname.a is in $library_names_spec (as mentioned above), rather than
25542 # wait for ar or ld to fail.
25543 #
25544 if test "$enable_shared" = yes && test "$enable_static" = yes; then
25545   case $library_names_spec in
25546     *libname.a*)
25547       { { echo "$as_me:$LINENO: error: cannot create both shared and static libraries on this system, --disable one of the two" >&5
25548 echo "$as_me: error: cannot create both shared and static libraries on this system, --disable one of the two" >&2;}
25549    { (exit 1); exit 1; }; }
25550       ;;
25551   esac
25552 fi
25553
25554
25555
25556 if test "$enable_static" = yes; then
25557   ENABLE_STATIC_TRUE=
25558   ENABLE_STATIC_FALSE='#'
25559 else
25560   ENABLE_STATIC_TRUE='#'
25561   ENABLE_STATIC_FALSE=
25562 fi
25563
25564
25565
25566 # Many of these library and header checks are for the benefit of
25567 # supplementary programs.  libgmp doesn't use anything too weird.
25568
25569 { echo "$as_me:$LINENO: checking for ANSI C header files" >&5
25570 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
25571 if test "${ac_cv_header_stdc+set}" = set; then
25572   echo $ECHO_N "(cached) $ECHO_C" >&6
25573 else
25574   cat >conftest.$ac_ext <<_ACEOF
25575 /* confdefs.h.  */
25576 _ACEOF
25577 cat confdefs.h >>conftest.$ac_ext
25578 cat >>conftest.$ac_ext <<_ACEOF
25579 /* end confdefs.h.  */
25580 #include <stdlib.h>
25581 #include <stdarg.h>
25582 #include <string.h>
25583 #include <float.h>
25584
25585 int
25586 main ()
25587 {
25588
25589   ;
25590   return 0;
25591 }
25592 _ACEOF
25593 rm -f conftest.$ac_objext
25594 if { (ac_try="$ac_compile"
25595 case "(($ac_try" in
25596   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25597   *) ac_try_echo=$ac_try;;
25598 esac
25599 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25600   (eval "$ac_compile") 2>conftest.er1
25601   ac_status=$?
25602   grep -v '^ *+' conftest.er1 >conftest.err
25603   rm -f conftest.er1
25604   cat conftest.err >&5
25605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25606   (exit $ac_status); } && {
25607          test -z "$ac_c_werror_flag" ||
25608          test ! -s conftest.err
25609        } && test -s conftest.$ac_objext; then
25610   ac_cv_header_stdc=yes
25611 else
25612   echo "$as_me: failed program was:" >&5
25613 sed 's/^/| /' conftest.$ac_ext >&5
25614
25615         ac_cv_header_stdc=no
25616 fi
25617
25618 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25619
25620 if test $ac_cv_header_stdc = yes; then
25621   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
25622   cat >conftest.$ac_ext <<_ACEOF
25623 /* confdefs.h.  */
25624 _ACEOF
25625 cat confdefs.h >>conftest.$ac_ext
25626 cat >>conftest.$ac_ext <<_ACEOF
25627 /* end confdefs.h.  */
25628 #include <string.h>
25629
25630 _ACEOF
25631 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
25632   $EGREP "memchr" >/dev/null 2>&1; then
25633   :
25634 else
25635   ac_cv_header_stdc=no
25636 fi
25637 rm -f conftest*
25638
25639 fi
25640
25641 if test $ac_cv_header_stdc = yes; then
25642   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
25643   cat >conftest.$ac_ext <<_ACEOF
25644 /* confdefs.h.  */
25645 _ACEOF
25646 cat confdefs.h >>conftest.$ac_ext
25647 cat >>conftest.$ac_ext <<_ACEOF
25648 /* end confdefs.h.  */
25649 #include <stdlib.h>
25650
25651 _ACEOF
25652 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
25653   $EGREP "free" >/dev/null 2>&1; then
25654   :
25655 else
25656   ac_cv_header_stdc=no
25657 fi
25658 rm -f conftest*
25659
25660 fi
25661
25662 if test $ac_cv_header_stdc = yes; then
25663   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
25664   if test "$cross_compiling" = yes; then
25665   :
25666 else
25667   cat >conftest.$ac_ext <<_ACEOF
25668 /* confdefs.h.  */
25669 _ACEOF
25670 cat confdefs.h >>conftest.$ac_ext
25671 cat >>conftest.$ac_ext <<_ACEOF
25672 /* end confdefs.h.  */
25673 #include <ctype.h>
25674 #include <stdlib.h>
25675 #if ((' ' & 0x0FF) == 0x020)
25676 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
25677 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
25678 #else
25679 # define ISLOWER(c) \
25680                    (('a' <= (c) && (c) <= 'i') \
25681                      || ('j' <= (c) && (c) <= 'r') \
25682                      || ('s' <= (c) && (c) <= 'z'))
25683 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
25684 #endif
25685
25686 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
25687 int
25688 main ()
25689 {
25690   int i;
25691   for (i = 0; i < 256; i++)
25692     if (XOR (islower (i), ISLOWER (i))
25693         || toupper (i) != TOUPPER (i))
25694       return 2;
25695   return 0;
25696 }
25697 _ACEOF
25698 rm -f conftest$ac_exeext
25699 if { (ac_try="$ac_link"
25700 case "(($ac_try" in
25701   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25702   *) ac_try_echo=$ac_try;;
25703 esac
25704 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25705   (eval "$ac_link") 2>&5
25706   ac_status=$?
25707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25708   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25709   { (case "(($ac_try" in
25710   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25711   *) ac_try_echo=$ac_try;;
25712 esac
25713 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25714   (eval "$ac_try") 2>&5
25715   ac_status=$?
25716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25717   (exit $ac_status); }; }; then
25718   :
25719 else
25720   echo "$as_me: program exited with status $ac_status" >&5
25721 echo "$as_me: failed program was:" >&5
25722 sed 's/^/| /' conftest.$ac_ext >&5
25723
25724 ( exit $ac_status )
25725 ac_cv_header_stdc=no
25726 fi
25727 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25728 fi
25729
25730
25731 fi
25732 fi
25733 { echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
25734 echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
25735 if test $ac_cv_header_stdc = yes; then
25736
25737 cat >>confdefs.h <<\_ACEOF
25738 #define STDC_HEADERS 1
25739 _ACEOF
25740
25741 fi
25742
25743 { echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
25744 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6; }
25745 if test "${ac_cv_header_time+set}" = set; then
25746   echo $ECHO_N "(cached) $ECHO_C" >&6
25747 else
25748   cat >conftest.$ac_ext <<_ACEOF
25749 /* confdefs.h.  */
25750 _ACEOF
25751 cat confdefs.h >>conftest.$ac_ext
25752 cat >>conftest.$ac_ext <<_ACEOF
25753 /* end confdefs.h.  */
25754 #include <sys/types.h>
25755 #include <sys/time.h>
25756 #include <time.h>
25757
25758 int
25759 main ()
25760 {
25761 if ((struct tm *) 0)
25762 return 0;
25763   ;
25764   return 0;
25765 }
25766 _ACEOF
25767 rm -f conftest.$ac_objext
25768 if { (ac_try="$ac_compile"
25769 case "(($ac_try" in
25770   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25771   *) ac_try_echo=$ac_try;;
25772 esac
25773 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25774   (eval "$ac_compile") 2>conftest.er1
25775   ac_status=$?
25776   grep -v '^ *+' conftest.er1 >conftest.err
25777   rm -f conftest.er1
25778   cat conftest.err >&5
25779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25780   (exit $ac_status); } && {
25781          test -z "$ac_c_werror_flag" ||
25782          test ! -s conftest.err
25783        } && test -s conftest.$ac_objext; then
25784   ac_cv_header_time=yes
25785 else
25786   echo "$as_me: failed program was:" >&5
25787 sed 's/^/| /' conftest.$ac_ext >&5
25788
25789         ac_cv_header_time=no
25790 fi
25791
25792 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25793 fi
25794 { echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
25795 echo "${ECHO_T}$ac_cv_header_time" >&6; }
25796 if test $ac_cv_header_time = yes; then
25797
25798 cat >>confdefs.h <<\_ACEOF
25799 #define TIME_WITH_SYS_TIME 1
25800 _ACEOF
25801
25802 fi
25803
25804
25805 # Reasons for testing:
25806 #   float.h - not in SunOS bundled cc
25807 #   invent.h - IRIX specific
25808 #   langinfo.h - X/Open standard only, not in djgpp for instance
25809 #   locale.h - old systems won't have this
25810 #   nl_types.h - X/Open standard only, not in djgpp for instance
25811 #       (usually langinfo.h gives nl_item etc, but not on netbsd 1.4.1)
25812 #   sys/attributes.h - IRIX specific
25813 #   sys/iograph.h - IRIX specific
25814 #   sys/mman.h - not in Cray Unicos
25815 #   sys/param.h - not in mingw
25816 #   sys/processor.h - solaris specific, though also present in macos
25817 #   sys/pstat.h - HPUX specific
25818 #   sys/resource.h - not in mingw
25819 #   sys/sysctl.h - not in mingw
25820 #   sys/sysinfo.h - OSF specific
25821 #   sys/syssgi.h - IRIX specific
25822 #   sys/systemcfg.h - AIX specific
25823 #   sys/time.h - autoconf suggests testing, don't know anywhere without it
25824 #   sys/times.h - not in mingw
25825 #   machine/hal_sysinfo.h - OSF specific
25826 #
25827 # inttypes.h, stdint.h, unistd.h and sys/types.h are already in the autoconf
25828 # default tests
25829 #
25830
25831
25832
25833
25834
25835
25836
25837
25838
25839
25840
25841
25842
25843
25844
25845
25846
25847 for ac_header in fcntl.h float.h invent.h langinfo.h locale.h nl_types.h sys/attributes.h sys/iograph.h sys/mman.h sys/param.h sys/processor.h sys/pstat.h sys/sysinfo.h sys/syssgi.h sys/systemcfg.h sys/time.h sys/times.h
25848 do
25849 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25850 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
25851   { echo "$as_me:$LINENO: checking for $ac_header" >&5
25852 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
25853 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
25854   echo $ECHO_N "(cached) $ECHO_C" >&6
25855 fi
25856 ac_res=`eval echo '${'$as_ac_Header'}'`
25857                { echo "$as_me:$LINENO: result: $ac_res" >&5
25858 echo "${ECHO_T}$ac_res" >&6; }
25859 else
25860   # Is the header compilable?
25861 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
25862 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
25863 cat >conftest.$ac_ext <<_ACEOF
25864 /* confdefs.h.  */
25865 _ACEOF
25866 cat confdefs.h >>conftest.$ac_ext
25867 cat >>conftest.$ac_ext <<_ACEOF
25868 /* end confdefs.h.  */
25869 $ac_includes_default
25870 #include <$ac_header>
25871 _ACEOF
25872 rm -f conftest.$ac_objext
25873 if { (ac_try="$ac_compile"
25874 case "(($ac_try" in
25875   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25876   *) ac_try_echo=$ac_try;;
25877 esac
25878 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25879   (eval "$ac_compile") 2>conftest.er1
25880   ac_status=$?
25881   grep -v '^ *+' conftest.er1 >conftest.err
25882   rm -f conftest.er1
25883   cat conftest.err >&5
25884   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25885   (exit $ac_status); } && {
25886          test -z "$ac_c_werror_flag" ||
25887          test ! -s conftest.err
25888        } && test -s conftest.$ac_objext; then
25889   ac_header_compiler=yes
25890 else
25891   echo "$as_me: failed program was:" >&5
25892 sed 's/^/| /' conftest.$ac_ext >&5
25893
25894         ac_header_compiler=no
25895 fi
25896
25897 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25898 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25899 echo "${ECHO_T}$ac_header_compiler" >&6; }
25900
25901 # Is the header present?
25902 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
25903 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
25904 cat >conftest.$ac_ext <<_ACEOF
25905 /* confdefs.h.  */
25906 _ACEOF
25907 cat confdefs.h >>conftest.$ac_ext
25908 cat >>conftest.$ac_ext <<_ACEOF
25909 /* end confdefs.h.  */
25910 #include <$ac_header>
25911 _ACEOF
25912 if { (ac_try="$ac_cpp conftest.$ac_ext"
25913 case "(($ac_try" in
25914   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25915   *) ac_try_echo=$ac_try;;
25916 esac
25917 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25918   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
25919   ac_status=$?
25920   grep -v '^ *+' conftest.er1 >conftest.err
25921   rm -f conftest.er1
25922   cat conftest.err >&5
25923   echo "$as_me:$LINENO: \$? = $ac_status" >&5
25924   (exit $ac_status); } >/dev/null && {
25925          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
25926          test ! -s conftest.err
25927        }; then
25928   ac_header_preproc=yes
25929 else
25930   echo "$as_me: failed program was:" >&5
25931 sed 's/^/| /' conftest.$ac_ext >&5
25932
25933   ac_header_preproc=no
25934 fi
25935
25936 rm -f conftest.err conftest.$ac_ext
25937 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25938 echo "${ECHO_T}$ac_header_preproc" >&6; }
25939
25940 # So?  What about this header?
25941 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25942   yes:no: )
25943     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
25944 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
25945     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
25946 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
25947     ac_header_preproc=yes
25948     ;;
25949   no:yes:* )
25950     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
25951 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
25952     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
25953 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
25954     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
25955 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
25956     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
25957 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
25958     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
25959 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
25960     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
25961 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
25962     ( cat <<\_ASBOX
25963 ## ---------------------------------- ##
25964 ## Report this to gmp-bugs@gmplib.org ##
25965 ## ---------------------------------- ##
25966 _ASBOX
25967      ) | sed "s/^/$as_me: WARNING:     /" >&2
25968     ;;
25969 esac
25970 { echo "$as_me:$LINENO: checking for $ac_header" >&5
25971 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
25972 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
25973   echo $ECHO_N "(cached) $ECHO_C" >&6
25974 else
25975   eval "$as_ac_Header=\$ac_header_preproc"
25976 fi
25977 ac_res=`eval echo '${'$as_ac_Header'}'`
25978                { echo "$as_me:$LINENO: result: $ac_res" >&5
25979 echo "${ECHO_T}$ac_res" >&6; }
25980
25981 fi
25982 if test `eval echo '${'$as_ac_Header'}'` = yes; then
25983   cat >>confdefs.h <<_ACEOF
25984 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
25985 _ACEOF
25986
25987 fi
25988
25989 done
25990
25991
25992 # On SunOS, sys/resource.h needs sys/time.h (for struct timeval)
25993
25994 for ac_header in sys/resource.h
25995 do
25996 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
25997 { echo "$as_me:$LINENO: checking for $ac_header" >&5
25998 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
25999 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
26000   echo $ECHO_N "(cached) $ECHO_C" >&6
26001 else
26002   cat >conftest.$ac_ext <<_ACEOF
26003 /* confdefs.h.  */
26004 _ACEOF
26005 cat confdefs.h >>conftest.$ac_ext
26006 cat >>conftest.$ac_ext <<_ACEOF
26007 /* end confdefs.h.  */
26008 #if TIME_WITH_SYS_TIME
26009 # include <sys/time.h>
26010 # include <time.h>
26011 #else
26012 # if HAVE_SYS_TIME_H
26013 #  include <sys/time.h>
26014 # else
26015 #  include <time.h>
26016 # endif
26017 #endif
26018
26019 #include <$ac_header>
26020 _ACEOF
26021 rm -f conftest.$ac_objext
26022 if { (ac_try="$ac_compile"
26023 case "(($ac_try" in
26024   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26025   *) ac_try_echo=$ac_try;;
26026 esac
26027 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26028   (eval "$ac_compile") 2>conftest.er1
26029   ac_status=$?
26030   grep -v '^ *+' conftest.er1 >conftest.err
26031   rm -f conftest.er1
26032   cat conftest.err >&5
26033   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26034   (exit $ac_status); } && {
26035          test -z "$ac_c_werror_flag" ||
26036          test ! -s conftest.err
26037        } && test -s conftest.$ac_objext; then
26038   eval "$as_ac_Header=yes"
26039 else
26040   echo "$as_me: failed program was:" >&5
26041 sed 's/^/| /' conftest.$ac_ext >&5
26042
26043         eval "$as_ac_Header=no"
26044 fi
26045
26046 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26047 fi
26048 ac_res=`eval echo '${'$as_ac_Header'}'`
26049                { echo "$as_me:$LINENO: result: $ac_res" >&5
26050 echo "${ECHO_T}$ac_res" >&6; }
26051 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26052   cat >>confdefs.h <<_ACEOF
26053 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26054 _ACEOF
26055
26056 fi
26057
26058 done
26059
26060
26061 # On NetBSD and OpenBSD, sys/sysctl.h needs sys/param.h for various constants
26062
26063 for ac_header in sys/sysctl.h
26064 do
26065 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26066 { echo "$as_me:$LINENO: checking for $ac_header" >&5
26067 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
26068 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
26069   echo $ECHO_N "(cached) $ECHO_C" >&6
26070 else
26071   cat >conftest.$ac_ext <<_ACEOF
26072 /* confdefs.h.  */
26073 _ACEOF
26074 cat confdefs.h >>conftest.$ac_ext
26075 cat >>conftest.$ac_ext <<_ACEOF
26076 /* end confdefs.h.  */
26077 #if HAVE_SYS_PARAM_H
26078 # include <sys/param.h>
26079 #endif
26080
26081 #include <$ac_header>
26082 _ACEOF
26083 rm -f conftest.$ac_objext
26084 if { (ac_try="$ac_compile"
26085 case "(($ac_try" in
26086   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26087   *) ac_try_echo=$ac_try;;
26088 esac
26089 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26090   (eval "$ac_compile") 2>conftest.er1
26091   ac_status=$?
26092   grep -v '^ *+' conftest.er1 >conftest.err
26093   rm -f conftest.er1
26094   cat conftest.err >&5
26095   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26096   (exit $ac_status); } && {
26097          test -z "$ac_c_werror_flag" ||
26098          test ! -s conftest.err
26099        } && test -s conftest.$ac_objext; then
26100   eval "$as_ac_Header=yes"
26101 else
26102   echo "$as_me: failed program was:" >&5
26103 sed 's/^/| /' conftest.$ac_ext >&5
26104
26105         eval "$as_ac_Header=no"
26106 fi
26107
26108 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26109 fi
26110 ac_res=`eval echo '${'$as_ac_Header'}'`
26111                { echo "$as_me:$LINENO: result: $ac_res" >&5
26112 echo "${ECHO_T}$ac_res" >&6; }
26113 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26114   cat >>confdefs.h <<_ACEOF
26115 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26116 _ACEOF
26117
26118 fi
26119
26120 done
26121
26122
26123 # On OSF 4.0, <machine/hal_sysinfo.h> must have <sys/sysinfo.h> for ulong_t
26124
26125 for ac_header in machine/hal_sysinfo.h
26126 do
26127 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
26128 { echo "$as_me:$LINENO: checking for $ac_header" >&5
26129 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
26130 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
26131   echo $ECHO_N "(cached) $ECHO_C" >&6
26132 else
26133   cat >conftest.$ac_ext <<_ACEOF
26134 /* confdefs.h.  */
26135 _ACEOF
26136 cat confdefs.h >>conftest.$ac_ext
26137 cat >>conftest.$ac_ext <<_ACEOF
26138 /* end confdefs.h.  */
26139 #if HAVE_SYS_SYSINFO_H
26140 # include <sys/sysinfo.h>
26141 #endif
26142
26143 #include <$ac_header>
26144 _ACEOF
26145 rm -f conftest.$ac_objext
26146 if { (ac_try="$ac_compile"
26147 case "(($ac_try" in
26148   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26149   *) ac_try_echo=$ac_try;;
26150 esac
26151 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26152   (eval "$ac_compile") 2>conftest.er1
26153   ac_status=$?
26154   grep -v '^ *+' conftest.er1 >conftest.err
26155   rm -f conftest.er1
26156   cat conftest.err >&5
26157   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26158   (exit $ac_status); } && {
26159          test -z "$ac_c_werror_flag" ||
26160          test ! -s conftest.err
26161        } && test -s conftest.$ac_objext; then
26162   eval "$as_ac_Header=yes"
26163 else
26164   echo "$as_me: failed program was:" >&5
26165 sed 's/^/| /' conftest.$ac_ext >&5
26166
26167         eval "$as_ac_Header=no"
26168 fi
26169
26170 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26171 fi
26172 ac_res=`eval echo '${'$as_ac_Header'}'`
26173                { echo "$as_me:$LINENO: result: $ac_res" >&5
26174 echo "${ECHO_T}$ac_res" >&6; }
26175 if test `eval echo '${'$as_ac_Header'}'` = yes; then
26176   cat >>confdefs.h <<_ACEOF
26177 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
26178 _ACEOF
26179
26180 fi
26181
26182 done
26183
26184
26185 # Reasons for testing:
26186 #   optarg - not declared in mingw
26187 #   fgetc, fscanf, ungetc, vfprintf - not declared in SunOS 4
26188 #   sys_errlist, sys_nerr - not declared in SunOS 4
26189 #
26190 # optarg should be in unistd.h and the rest in stdio.h, both of which are
26191 # in the autoconf default includes.
26192 #
26193 # sys_errlist and sys_nerr are supposed to be in <errno.h> on SunOS according
26194 # to the man page (but aren't), in glibc they're in stdio.h.
26195 #
26196 { echo "$as_me:$LINENO: checking whether fgetc is declared" >&5
26197 echo $ECHO_N "checking whether fgetc is declared... $ECHO_C" >&6; }
26198 if test "${ac_cv_have_decl_fgetc+set}" = set; then
26199   echo $ECHO_N "(cached) $ECHO_C" >&6
26200 else
26201   cat >conftest.$ac_ext <<_ACEOF
26202 /* confdefs.h.  */
26203 _ACEOF
26204 cat confdefs.h >>conftest.$ac_ext
26205 cat >>conftest.$ac_ext <<_ACEOF
26206 /* end confdefs.h.  */
26207 $ac_includes_default
26208 int
26209 main ()
26210 {
26211 #ifndef fgetc
26212   (void) fgetc;
26213 #endif
26214
26215   ;
26216   return 0;
26217 }
26218 _ACEOF
26219 rm -f conftest.$ac_objext
26220 if { (ac_try="$ac_compile"
26221 case "(($ac_try" in
26222   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26223   *) ac_try_echo=$ac_try;;
26224 esac
26225 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26226   (eval "$ac_compile") 2>conftest.er1
26227   ac_status=$?
26228   grep -v '^ *+' conftest.er1 >conftest.err
26229   rm -f conftest.er1
26230   cat conftest.err >&5
26231   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26232   (exit $ac_status); } && {
26233          test -z "$ac_c_werror_flag" ||
26234          test ! -s conftest.err
26235        } && test -s conftest.$ac_objext; then
26236   ac_cv_have_decl_fgetc=yes
26237 else
26238   echo "$as_me: failed program was:" >&5
26239 sed 's/^/| /' conftest.$ac_ext >&5
26240
26241         ac_cv_have_decl_fgetc=no
26242 fi
26243
26244 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26245 fi
26246 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_fgetc" >&5
26247 echo "${ECHO_T}$ac_cv_have_decl_fgetc" >&6; }
26248 if test $ac_cv_have_decl_fgetc = yes; then
26249
26250 cat >>confdefs.h <<_ACEOF
26251 #define HAVE_DECL_FGETC 1
26252 _ACEOF
26253
26254
26255 else
26256   cat >>confdefs.h <<_ACEOF
26257 #define HAVE_DECL_FGETC 0
26258 _ACEOF
26259
26260
26261 fi
26262 { echo "$as_me:$LINENO: checking whether fscanf is declared" >&5
26263 echo $ECHO_N "checking whether fscanf is declared... $ECHO_C" >&6; }
26264 if test "${ac_cv_have_decl_fscanf+set}" = set; then
26265   echo $ECHO_N "(cached) $ECHO_C" >&6
26266 else
26267   cat >conftest.$ac_ext <<_ACEOF
26268 /* confdefs.h.  */
26269 _ACEOF
26270 cat confdefs.h >>conftest.$ac_ext
26271 cat >>conftest.$ac_ext <<_ACEOF
26272 /* end confdefs.h.  */
26273 $ac_includes_default
26274 int
26275 main ()
26276 {
26277 #ifndef fscanf
26278   (void) fscanf;
26279 #endif
26280
26281   ;
26282   return 0;
26283 }
26284 _ACEOF
26285 rm -f conftest.$ac_objext
26286 if { (ac_try="$ac_compile"
26287 case "(($ac_try" in
26288   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26289   *) ac_try_echo=$ac_try;;
26290 esac
26291 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26292   (eval "$ac_compile") 2>conftest.er1
26293   ac_status=$?
26294   grep -v '^ *+' conftest.er1 >conftest.err
26295   rm -f conftest.er1
26296   cat conftest.err >&5
26297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26298   (exit $ac_status); } && {
26299          test -z "$ac_c_werror_flag" ||
26300          test ! -s conftest.err
26301        } && test -s conftest.$ac_objext; then
26302   ac_cv_have_decl_fscanf=yes
26303 else
26304   echo "$as_me: failed program was:" >&5
26305 sed 's/^/| /' conftest.$ac_ext >&5
26306
26307         ac_cv_have_decl_fscanf=no
26308 fi
26309
26310 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26311 fi
26312 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_fscanf" >&5
26313 echo "${ECHO_T}$ac_cv_have_decl_fscanf" >&6; }
26314 if test $ac_cv_have_decl_fscanf = yes; then
26315
26316 cat >>confdefs.h <<_ACEOF
26317 #define HAVE_DECL_FSCANF 1
26318 _ACEOF
26319
26320
26321 else
26322   cat >>confdefs.h <<_ACEOF
26323 #define HAVE_DECL_FSCANF 0
26324 _ACEOF
26325
26326
26327 fi
26328 { echo "$as_me:$LINENO: checking whether optarg is declared" >&5
26329 echo $ECHO_N "checking whether optarg is declared... $ECHO_C" >&6; }
26330 if test "${ac_cv_have_decl_optarg+set}" = set; then
26331   echo $ECHO_N "(cached) $ECHO_C" >&6
26332 else
26333   cat >conftest.$ac_ext <<_ACEOF
26334 /* confdefs.h.  */
26335 _ACEOF
26336 cat confdefs.h >>conftest.$ac_ext
26337 cat >>conftest.$ac_ext <<_ACEOF
26338 /* end confdefs.h.  */
26339 $ac_includes_default
26340 int
26341 main ()
26342 {
26343 #ifndef optarg
26344   (void) optarg;
26345 #endif
26346
26347   ;
26348   return 0;
26349 }
26350 _ACEOF
26351 rm -f conftest.$ac_objext
26352 if { (ac_try="$ac_compile"
26353 case "(($ac_try" in
26354   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26355   *) ac_try_echo=$ac_try;;
26356 esac
26357 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26358   (eval "$ac_compile") 2>conftest.er1
26359   ac_status=$?
26360   grep -v '^ *+' conftest.er1 >conftest.err
26361   rm -f conftest.er1
26362   cat conftest.err >&5
26363   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26364   (exit $ac_status); } && {
26365          test -z "$ac_c_werror_flag" ||
26366          test ! -s conftest.err
26367        } && test -s conftest.$ac_objext; then
26368   ac_cv_have_decl_optarg=yes
26369 else
26370   echo "$as_me: failed program was:" >&5
26371 sed 's/^/| /' conftest.$ac_ext >&5
26372
26373         ac_cv_have_decl_optarg=no
26374 fi
26375
26376 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26377 fi
26378 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_optarg" >&5
26379 echo "${ECHO_T}$ac_cv_have_decl_optarg" >&6; }
26380 if test $ac_cv_have_decl_optarg = yes; then
26381
26382 cat >>confdefs.h <<_ACEOF
26383 #define HAVE_DECL_OPTARG 1
26384 _ACEOF
26385
26386
26387 else
26388   cat >>confdefs.h <<_ACEOF
26389 #define HAVE_DECL_OPTARG 0
26390 _ACEOF
26391
26392
26393 fi
26394 { echo "$as_me:$LINENO: checking whether ungetc is declared" >&5
26395 echo $ECHO_N "checking whether ungetc is declared... $ECHO_C" >&6; }
26396 if test "${ac_cv_have_decl_ungetc+set}" = set; then
26397   echo $ECHO_N "(cached) $ECHO_C" >&6
26398 else
26399   cat >conftest.$ac_ext <<_ACEOF
26400 /* confdefs.h.  */
26401 _ACEOF
26402 cat confdefs.h >>conftest.$ac_ext
26403 cat >>conftest.$ac_ext <<_ACEOF
26404 /* end confdefs.h.  */
26405 $ac_includes_default
26406 int
26407 main ()
26408 {
26409 #ifndef ungetc
26410   (void) ungetc;
26411 #endif
26412
26413   ;
26414   return 0;
26415 }
26416 _ACEOF
26417 rm -f conftest.$ac_objext
26418 if { (ac_try="$ac_compile"
26419 case "(($ac_try" in
26420   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26421   *) ac_try_echo=$ac_try;;
26422 esac
26423 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26424   (eval "$ac_compile") 2>conftest.er1
26425   ac_status=$?
26426   grep -v '^ *+' conftest.er1 >conftest.err
26427   rm -f conftest.er1
26428   cat conftest.err >&5
26429   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26430   (exit $ac_status); } && {
26431          test -z "$ac_c_werror_flag" ||
26432          test ! -s conftest.err
26433        } && test -s conftest.$ac_objext; then
26434   ac_cv_have_decl_ungetc=yes
26435 else
26436   echo "$as_me: failed program was:" >&5
26437 sed 's/^/| /' conftest.$ac_ext >&5
26438
26439         ac_cv_have_decl_ungetc=no
26440 fi
26441
26442 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26443 fi
26444 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_ungetc" >&5
26445 echo "${ECHO_T}$ac_cv_have_decl_ungetc" >&6; }
26446 if test $ac_cv_have_decl_ungetc = yes; then
26447
26448 cat >>confdefs.h <<_ACEOF
26449 #define HAVE_DECL_UNGETC 1
26450 _ACEOF
26451
26452
26453 else
26454   cat >>confdefs.h <<_ACEOF
26455 #define HAVE_DECL_UNGETC 0
26456 _ACEOF
26457
26458
26459 fi
26460 { echo "$as_me:$LINENO: checking whether vfprintf is declared" >&5
26461 echo $ECHO_N "checking whether vfprintf is declared... $ECHO_C" >&6; }
26462 if test "${ac_cv_have_decl_vfprintf+set}" = set; then
26463   echo $ECHO_N "(cached) $ECHO_C" >&6
26464 else
26465   cat >conftest.$ac_ext <<_ACEOF
26466 /* confdefs.h.  */
26467 _ACEOF
26468 cat confdefs.h >>conftest.$ac_ext
26469 cat >>conftest.$ac_ext <<_ACEOF
26470 /* end confdefs.h.  */
26471 $ac_includes_default
26472 int
26473 main ()
26474 {
26475 #ifndef vfprintf
26476   (void) vfprintf;
26477 #endif
26478
26479   ;
26480   return 0;
26481 }
26482 _ACEOF
26483 rm -f conftest.$ac_objext
26484 if { (ac_try="$ac_compile"
26485 case "(($ac_try" in
26486   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26487   *) ac_try_echo=$ac_try;;
26488 esac
26489 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26490   (eval "$ac_compile") 2>conftest.er1
26491   ac_status=$?
26492   grep -v '^ *+' conftest.er1 >conftest.err
26493   rm -f conftest.er1
26494   cat conftest.err >&5
26495   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26496   (exit $ac_status); } && {
26497          test -z "$ac_c_werror_flag" ||
26498          test ! -s conftest.err
26499        } && test -s conftest.$ac_objext; then
26500   ac_cv_have_decl_vfprintf=yes
26501 else
26502   echo "$as_me: failed program was:" >&5
26503 sed 's/^/| /' conftest.$ac_ext >&5
26504
26505         ac_cv_have_decl_vfprintf=no
26506 fi
26507
26508 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26509 fi
26510 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_vfprintf" >&5
26511 echo "${ECHO_T}$ac_cv_have_decl_vfprintf" >&6; }
26512 if test $ac_cv_have_decl_vfprintf = yes; then
26513
26514 cat >>confdefs.h <<_ACEOF
26515 #define HAVE_DECL_VFPRINTF 1
26516 _ACEOF
26517
26518
26519 else
26520   cat >>confdefs.h <<_ACEOF
26521 #define HAVE_DECL_VFPRINTF 0
26522 _ACEOF
26523
26524
26525 fi
26526
26527
26528 { echo "$as_me:$LINENO: checking whether sys_errlist is declared" >&5
26529 echo $ECHO_N "checking whether sys_errlist is declared... $ECHO_C" >&6; }
26530 if test "${ac_cv_have_decl_sys_errlist+set}" = set; then
26531   echo $ECHO_N "(cached) $ECHO_C" >&6
26532 else
26533   cat >conftest.$ac_ext <<_ACEOF
26534 /* confdefs.h.  */
26535 _ACEOF
26536 cat confdefs.h >>conftest.$ac_ext
26537 cat >>conftest.$ac_ext <<_ACEOF
26538 /* end confdefs.h.  */
26539 #include <stdio.h>
26540 #include <errno.h>
26541
26542 int
26543 main ()
26544 {
26545 #ifndef sys_errlist
26546   (void) sys_errlist;
26547 #endif
26548
26549   ;
26550   return 0;
26551 }
26552 _ACEOF
26553 rm -f conftest.$ac_objext
26554 if { (ac_try="$ac_compile"
26555 case "(($ac_try" in
26556   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26557   *) ac_try_echo=$ac_try;;
26558 esac
26559 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26560   (eval "$ac_compile") 2>conftest.er1
26561   ac_status=$?
26562   grep -v '^ *+' conftest.er1 >conftest.err
26563   rm -f conftest.er1
26564   cat conftest.err >&5
26565   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26566   (exit $ac_status); } && {
26567          test -z "$ac_c_werror_flag" ||
26568          test ! -s conftest.err
26569        } && test -s conftest.$ac_objext; then
26570   ac_cv_have_decl_sys_errlist=yes
26571 else
26572   echo "$as_me: failed program was:" >&5
26573 sed 's/^/| /' conftest.$ac_ext >&5
26574
26575         ac_cv_have_decl_sys_errlist=no
26576 fi
26577
26578 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26579 fi
26580 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_errlist" >&5
26581 echo "${ECHO_T}$ac_cv_have_decl_sys_errlist" >&6; }
26582 if test $ac_cv_have_decl_sys_errlist = yes; then
26583
26584 cat >>confdefs.h <<_ACEOF
26585 #define HAVE_DECL_SYS_ERRLIST 1
26586 _ACEOF
26587
26588
26589 else
26590   cat >>confdefs.h <<_ACEOF
26591 #define HAVE_DECL_SYS_ERRLIST 0
26592 _ACEOF
26593
26594
26595 fi
26596 { echo "$as_me:$LINENO: checking whether sys_nerr is declared" >&5
26597 echo $ECHO_N "checking whether sys_nerr is declared... $ECHO_C" >&6; }
26598 if test "${ac_cv_have_decl_sys_nerr+set}" = set; then
26599   echo $ECHO_N "(cached) $ECHO_C" >&6
26600 else
26601   cat >conftest.$ac_ext <<_ACEOF
26602 /* confdefs.h.  */
26603 _ACEOF
26604 cat confdefs.h >>conftest.$ac_ext
26605 cat >>conftest.$ac_ext <<_ACEOF
26606 /* end confdefs.h.  */
26607 #include <stdio.h>
26608 #include <errno.h>
26609
26610 int
26611 main ()
26612 {
26613 #ifndef sys_nerr
26614   (void) sys_nerr;
26615 #endif
26616
26617   ;
26618   return 0;
26619 }
26620 _ACEOF
26621 rm -f conftest.$ac_objext
26622 if { (ac_try="$ac_compile"
26623 case "(($ac_try" in
26624   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26625   *) ac_try_echo=$ac_try;;
26626 esac
26627 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26628   (eval "$ac_compile") 2>conftest.er1
26629   ac_status=$?
26630   grep -v '^ *+' conftest.er1 >conftest.err
26631   rm -f conftest.er1
26632   cat conftest.err >&5
26633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26634   (exit $ac_status); } && {
26635          test -z "$ac_c_werror_flag" ||
26636          test ! -s conftest.err
26637        } && test -s conftest.$ac_objext; then
26638   ac_cv_have_decl_sys_nerr=yes
26639 else
26640   echo "$as_me: failed program was:" >&5
26641 sed 's/^/| /' conftest.$ac_ext >&5
26642
26643         ac_cv_have_decl_sys_nerr=no
26644 fi
26645
26646 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26647 fi
26648 { echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_nerr" >&5
26649 echo "${ECHO_T}$ac_cv_have_decl_sys_nerr" >&6; }
26650 if test $ac_cv_have_decl_sys_nerr = yes; then
26651
26652 cat >>confdefs.h <<_ACEOF
26653 #define HAVE_DECL_SYS_NERR 1
26654 _ACEOF
26655
26656
26657 else
26658   cat >>confdefs.h <<_ACEOF
26659 #define HAVE_DECL_SYS_NERR 0
26660 _ACEOF
26661
26662
26663 fi
26664
26665
26666
26667 { echo "$as_me:$LINENO: checking return type of signal handlers" >&5
26668 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6; }
26669 if test "${ac_cv_type_signal+set}" = set; then
26670   echo $ECHO_N "(cached) $ECHO_C" >&6
26671 else
26672   cat >conftest.$ac_ext <<_ACEOF
26673 /* confdefs.h.  */
26674 _ACEOF
26675 cat confdefs.h >>conftest.$ac_ext
26676 cat >>conftest.$ac_ext <<_ACEOF
26677 /* end confdefs.h.  */
26678 #include <sys/types.h>
26679 #include <signal.h>
26680
26681 int
26682 main ()
26683 {
26684 return *(signal (0, 0)) (0) == 1;
26685   ;
26686   return 0;
26687 }
26688 _ACEOF
26689 rm -f conftest.$ac_objext
26690 if { (ac_try="$ac_compile"
26691 case "(($ac_try" in
26692   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26693   *) ac_try_echo=$ac_try;;
26694 esac
26695 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26696   (eval "$ac_compile") 2>conftest.er1
26697   ac_status=$?
26698   grep -v '^ *+' conftest.er1 >conftest.err
26699   rm -f conftest.er1
26700   cat conftest.err >&5
26701   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26702   (exit $ac_status); } && {
26703          test -z "$ac_c_werror_flag" ||
26704          test ! -s conftest.err
26705        } && test -s conftest.$ac_objext; then
26706   ac_cv_type_signal=int
26707 else
26708   echo "$as_me: failed program was:" >&5
26709 sed 's/^/| /' conftest.$ac_ext >&5
26710
26711         ac_cv_type_signal=void
26712 fi
26713
26714 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26715 fi
26716 { echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5
26717 echo "${ECHO_T}$ac_cv_type_signal" >&6; }
26718
26719 cat >>confdefs.h <<_ACEOF
26720 #define RETSIGTYPE $ac_cv_type_signal
26721 _ACEOF
26722
26723
26724
26725 # Reasons for testing:
26726 #   intmax_t       - C99
26727 #   long double    - not in the HP bundled K&R cc
26728 #   long long      - only in reasonably recent compilers
26729 #   ptrdiff_t      - seems to be everywhere, maybe don't need to check this
26730 #   quad_t         - BSD specific
26731 #   uint_least32_t - C99
26732 #
26733 # the default includes are sufficient for all these types
26734 #
26735 { echo "$as_me:$LINENO: checking for intmax_t" >&5
26736 echo $ECHO_N "checking for intmax_t... $ECHO_C" >&6; }
26737 if test "${ac_cv_type_intmax_t+set}" = set; then
26738   echo $ECHO_N "(cached) $ECHO_C" >&6
26739 else
26740   cat >conftest.$ac_ext <<_ACEOF
26741 /* confdefs.h.  */
26742 _ACEOF
26743 cat confdefs.h >>conftest.$ac_ext
26744 cat >>conftest.$ac_ext <<_ACEOF
26745 /* end confdefs.h.  */
26746 $ac_includes_default
26747 typedef intmax_t ac__type_new_;
26748 int
26749 main ()
26750 {
26751 if ((ac__type_new_ *) 0)
26752   return 0;
26753 if (sizeof (ac__type_new_))
26754   return 0;
26755   ;
26756   return 0;
26757 }
26758 _ACEOF
26759 rm -f conftest.$ac_objext
26760 if { (ac_try="$ac_compile"
26761 case "(($ac_try" in
26762   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26763   *) ac_try_echo=$ac_try;;
26764 esac
26765 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26766   (eval "$ac_compile") 2>conftest.er1
26767   ac_status=$?
26768   grep -v '^ *+' conftest.er1 >conftest.err
26769   rm -f conftest.er1
26770   cat conftest.err >&5
26771   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26772   (exit $ac_status); } && {
26773          test -z "$ac_c_werror_flag" ||
26774          test ! -s conftest.err
26775        } && test -s conftest.$ac_objext; then
26776   ac_cv_type_intmax_t=yes
26777 else
26778   echo "$as_me: failed program was:" >&5
26779 sed 's/^/| /' conftest.$ac_ext >&5
26780
26781         ac_cv_type_intmax_t=no
26782 fi
26783
26784 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26785 fi
26786 { echo "$as_me:$LINENO: result: $ac_cv_type_intmax_t" >&5
26787 echo "${ECHO_T}$ac_cv_type_intmax_t" >&6; }
26788 if test $ac_cv_type_intmax_t = yes; then
26789
26790 cat >>confdefs.h <<_ACEOF
26791 #define HAVE_INTMAX_T 1
26792 _ACEOF
26793
26794
26795 fi
26796 { echo "$as_me:$LINENO: checking for long double" >&5
26797 echo $ECHO_N "checking for long double... $ECHO_C" >&6; }
26798 if test "${ac_cv_type_long_double+set}" = set; then
26799   echo $ECHO_N "(cached) $ECHO_C" >&6
26800 else
26801   cat >conftest.$ac_ext <<_ACEOF
26802 /* confdefs.h.  */
26803 _ACEOF
26804 cat confdefs.h >>conftest.$ac_ext
26805 cat >>conftest.$ac_ext <<_ACEOF
26806 /* end confdefs.h.  */
26807 $ac_includes_default
26808 typedef long double ac__type_new_;
26809 int
26810 main ()
26811 {
26812 if ((ac__type_new_ *) 0)
26813   return 0;
26814 if (sizeof (ac__type_new_))
26815   return 0;
26816   ;
26817   return 0;
26818 }
26819 _ACEOF
26820 rm -f conftest.$ac_objext
26821 if { (ac_try="$ac_compile"
26822 case "(($ac_try" in
26823   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26824   *) ac_try_echo=$ac_try;;
26825 esac
26826 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26827   (eval "$ac_compile") 2>conftest.er1
26828   ac_status=$?
26829   grep -v '^ *+' conftest.er1 >conftest.err
26830   rm -f conftest.er1
26831   cat conftest.err >&5
26832   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26833   (exit $ac_status); } && {
26834          test -z "$ac_c_werror_flag" ||
26835          test ! -s conftest.err
26836        } && test -s conftest.$ac_objext; then
26837   ac_cv_type_long_double=yes
26838 else
26839   echo "$as_me: failed program was:" >&5
26840 sed 's/^/| /' conftest.$ac_ext >&5
26841
26842         ac_cv_type_long_double=no
26843 fi
26844
26845 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26846 fi
26847 { echo "$as_me:$LINENO: result: $ac_cv_type_long_double" >&5
26848 echo "${ECHO_T}$ac_cv_type_long_double" >&6; }
26849 if test $ac_cv_type_long_double = yes; then
26850
26851 cat >>confdefs.h <<_ACEOF
26852 #define HAVE_LONG_DOUBLE 1
26853 _ACEOF
26854
26855
26856 fi
26857 { echo "$as_me:$LINENO: checking for long long" >&5
26858 echo $ECHO_N "checking for long long... $ECHO_C" >&6; }
26859 if test "${ac_cv_type_long_long+set}" = set; then
26860   echo $ECHO_N "(cached) $ECHO_C" >&6
26861 else
26862   cat >conftest.$ac_ext <<_ACEOF
26863 /* confdefs.h.  */
26864 _ACEOF
26865 cat confdefs.h >>conftest.$ac_ext
26866 cat >>conftest.$ac_ext <<_ACEOF
26867 /* end confdefs.h.  */
26868 $ac_includes_default
26869 typedef long long ac__type_new_;
26870 int
26871 main ()
26872 {
26873 if ((ac__type_new_ *) 0)
26874   return 0;
26875 if (sizeof (ac__type_new_))
26876   return 0;
26877   ;
26878   return 0;
26879 }
26880 _ACEOF
26881 rm -f conftest.$ac_objext
26882 if { (ac_try="$ac_compile"
26883 case "(($ac_try" in
26884   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26885   *) ac_try_echo=$ac_try;;
26886 esac
26887 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26888   (eval "$ac_compile") 2>conftest.er1
26889   ac_status=$?
26890   grep -v '^ *+' conftest.er1 >conftest.err
26891   rm -f conftest.er1
26892   cat conftest.err >&5
26893   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26894   (exit $ac_status); } && {
26895          test -z "$ac_c_werror_flag" ||
26896          test ! -s conftest.err
26897        } && test -s conftest.$ac_objext; then
26898   ac_cv_type_long_long=yes
26899 else
26900   echo "$as_me: failed program was:" >&5
26901 sed 's/^/| /' conftest.$ac_ext >&5
26902
26903         ac_cv_type_long_long=no
26904 fi
26905
26906 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26907 fi
26908 { echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
26909 echo "${ECHO_T}$ac_cv_type_long_long" >&6; }
26910 if test $ac_cv_type_long_long = yes; then
26911
26912 cat >>confdefs.h <<_ACEOF
26913 #define HAVE_LONG_LONG 1
26914 _ACEOF
26915
26916
26917 fi
26918 { echo "$as_me:$LINENO: checking for ptrdiff_t" >&5
26919 echo $ECHO_N "checking for ptrdiff_t... $ECHO_C" >&6; }
26920 if test "${ac_cv_type_ptrdiff_t+set}" = set; then
26921   echo $ECHO_N "(cached) $ECHO_C" >&6
26922 else
26923   cat >conftest.$ac_ext <<_ACEOF
26924 /* confdefs.h.  */
26925 _ACEOF
26926 cat confdefs.h >>conftest.$ac_ext
26927 cat >>conftest.$ac_ext <<_ACEOF
26928 /* end confdefs.h.  */
26929 $ac_includes_default
26930 typedef ptrdiff_t ac__type_new_;
26931 int
26932 main ()
26933 {
26934 if ((ac__type_new_ *) 0)
26935   return 0;
26936 if (sizeof (ac__type_new_))
26937   return 0;
26938   ;
26939   return 0;
26940 }
26941 _ACEOF
26942 rm -f conftest.$ac_objext
26943 if { (ac_try="$ac_compile"
26944 case "(($ac_try" in
26945   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26946   *) ac_try_echo=$ac_try;;
26947 esac
26948 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26949   (eval "$ac_compile") 2>conftest.er1
26950   ac_status=$?
26951   grep -v '^ *+' conftest.er1 >conftest.err
26952   rm -f conftest.er1
26953   cat conftest.err >&5
26954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
26955   (exit $ac_status); } && {
26956          test -z "$ac_c_werror_flag" ||
26957          test ! -s conftest.err
26958        } && test -s conftest.$ac_objext; then
26959   ac_cv_type_ptrdiff_t=yes
26960 else
26961   echo "$as_me: failed program was:" >&5
26962 sed 's/^/| /' conftest.$ac_ext >&5
26963
26964         ac_cv_type_ptrdiff_t=no
26965 fi
26966
26967 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26968 fi
26969 { echo "$as_me:$LINENO: result: $ac_cv_type_ptrdiff_t" >&5
26970 echo "${ECHO_T}$ac_cv_type_ptrdiff_t" >&6; }
26971 if test $ac_cv_type_ptrdiff_t = yes; then
26972
26973 cat >>confdefs.h <<_ACEOF
26974 #define HAVE_PTRDIFF_T 1
26975 _ACEOF
26976
26977
26978 fi
26979 { echo "$as_me:$LINENO: checking for quad_t" >&5
26980 echo $ECHO_N "checking for quad_t... $ECHO_C" >&6; }
26981 if test "${ac_cv_type_quad_t+set}" = set; then
26982   echo $ECHO_N "(cached) $ECHO_C" >&6
26983 else
26984   cat >conftest.$ac_ext <<_ACEOF
26985 /* confdefs.h.  */
26986 _ACEOF
26987 cat confdefs.h >>conftest.$ac_ext
26988 cat >>conftest.$ac_ext <<_ACEOF
26989 /* end confdefs.h.  */
26990 $ac_includes_default
26991 typedef quad_t ac__type_new_;
26992 int
26993 main ()
26994 {
26995 if ((ac__type_new_ *) 0)
26996   return 0;
26997 if (sizeof (ac__type_new_))
26998   return 0;
26999   ;
27000   return 0;
27001 }
27002 _ACEOF
27003 rm -f conftest.$ac_objext
27004 if { (ac_try="$ac_compile"
27005 case "(($ac_try" in
27006   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27007   *) ac_try_echo=$ac_try;;
27008 esac
27009 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27010   (eval "$ac_compile") 2>conftest.er1
27011   ac_status=$?
27012   grep -v '^ *+' conftest.er1 >conftest.err
27013   rm -f conftest.er1
27014   cat conftest.err >&5
27015   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27016   (exit $ac_status); } && {
27017          test -z "$ac_c_werror_flag" ||
27018          test ! -s conftest.err
27019        } && test -s conftest.$ac_objext; then
27020   ac_cv_type_quad_t=yes
27021 else
27022   echo "$as_me: failed program was:" >&5
27023 sed 's/^/| /' conftest.$ac_ext >&5
27024
27025         ac_cv_type_quad_t=no
27026 fi
27027
27028 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27029 fi
27030 { echo "$as_me:$LINENO: result: $ac_cv_type_quad_t" >&5
27031 echo "${ECHO_T}$ac_cv_type_quad_t" >&6; }
27032 if test $ac_cv_type_quad_t = yes; then
27033
27034 cat >>confdefs.h <<_ACEOF
27035 #define HAVE_QUAD_T 1
27036 _ACEOF
27037
27038
27039 fi
27040 { echo "$as_me:$LINENO: checking for uint_least32_t" >&5
27041 echo $ECHO_N "checking for uint_least32_t... $ECHO_C" >&6; }
27042 if test "${ac_cv_type_uint_least32_t+set}" = set; then
27043   echo $ECHO_N "(cached) $ECHO_C" >&6
27044 else
27045   cat >conftest.$ac_ext <<_ACEOF
27046 /* confdefs.h.  */
27047 _ACEOF
27048 cat confdefs.h >>conftest.$ac_ext
27049 cat >>conftest.$ac_ext <<_ACEOF
27050 /* end confdefs.h.  */
27051 $ac_includes_default
27052 typedef uint_least32_t ac__type_new_;
27053 int
27054 main ()
27055 {
27056 if ((ac__type_new_ *) 0)
27057   return 0;
27058 if (sizeof (ac__type_new_))
27059   return 0;
27060   ;
27061   return 0;
27062 }
27063 _ACEOF
27064 rm -f conftest.$ac_objext
27065 if { (ac_try="$ac_compile"
27066 case "(($ac_try" in
27067   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27068   *) ac_try_echo=$ac_try;;
27069 esac
27070 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27071   (eval "$ac_compile") 2>conftest.er1
27072   ac_status=$?
27073   grep -v '^ *+' conftest.er1 >conftest.err
27074   rm -f conftest.er1
27075   cat conftest.err >&5
27076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27077   (exit $ac_status); } && {
27078          test -z "$ac_c_werror_flag" ||
27079          test ! -s conftest.err
27080        } && test -s conftest.$ac_objext; then
27081   ac_cv_type_uint_least32_t=yes
27082 else
27083   echo "$as_me: failed program was:" >&5
27084 sed 's/^/| /' conftest.$ac_ext >&5
27085
27086         ac_cv_type_uint_least32_t=no
27087 fi
27088
27089 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27090 fi
27091 { echo "$as_me:$LINENO: result: $ac_cv_type_uint_least32_t" >&5
27092 echo "${ECHO_T}$ac_cv_type_uint_least32_t" >&6; }
27093 if test $ac_cv_type_uint_least32_t = yes; then
27094
27095 cat >>confdefs.h <<_ACEOF
27096 #define HAVE_UINT_LEAST32_T 1
27097 _ACEOF
27098
27099
27100 fi
27101
27102
27103 { echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
27104 echo $ECHO_N "checking for preprocessor stringizing operator... $ECHO_C" >&6; }
27105 if test "${ac_cv_c_stringize+set}" = set; then
27106   echo $ECHO_N "(cached) $ECHO_C" >&6
27107 else
27108   cat >conftest.$ac_ext <<_ACEOF
27109 /* confdefs.h.  */
27110 _ACEOF
27111 cat confdefs.h >>conftest.$ac_ext
27112 cat >>conftest.$ac_ext <<_ACEOF
27113 /* end confdefs.h.  */
27114 #define x(y) #y
27115
27116 char *s = x(teststring);
27117 _ACEOF
27118 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27119   $EGREP "#teststring" >/dev/null 2>&1; then
27120   ac_cv_c_stringize=no
27121 else
27122   ac_cv_c_stringize=yes
27123 fi
27124 rm -f conftest*
27125
27126 fi
27127 { echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
27128 echo "${ECHO_T}$ac_cv_c_stringize" >&6; }
27129 if test $ac_cv_c_stringize = yes; then
27130
27131 cat >>confdefs.h <<\_ACEOF
27132 #define HAVE_STRINGIZE 1
27133 _ACEOF
27134
27135 fi
27136
27137
27138 # FIXME: Really want #ifndef __cplusplus around the #define volatile
27139 # replacement autoconf gives, since volatile is always available in C++.
27140 # But we don't use it in C++ currently.
27141 { echo "$as_me:$LINENO: checking for working volatile" >&5
27142 echo $ECHO_N "checking for working volatile... $ECHO_C" >&6; }
27143 if test "${ac_cv_c_volatile+set}" = set; then
27144   echo $ECHO_N "(cached) $ECHO_C" >&6
27145 else
27146   cat >conftest.$ac_ext <<_ACEOF
27147 /* confdefs.h.  */
27148 _ACEOF
27149 cat confdefs.h >>conftest.$ac_ext
27150 cat >>conftest.$ac_ext <<_ACEOF
27151 /* end confdefs.h.  */
27152
27153 int
27154 main ()
27155 {
27156
27157 volatile int x;
27158 int * volatile y = (int *) 0;
27159 return !x && !y;
27160   ;
27161   return 0;
27162 }
27163 _ACEOF
27164 rm -f conftest.$ac_objext
27165 if { (ac_try="$ac_compile"
27166 case "(($ac_try" in
27167   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27168   *) ac_try_echo=$ac_try;;
27169 esac
27170 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27171   (eval "$ac_compile") 2>conftest.er1
27172   ac_status=$?
27173   grep -v '^ *+' conftest.er1 >conftest.err
27174   rm -f conftest.er1
27175   cat conftest.err >&5
27176   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27177   (exit $ac_status); } && {
27178          test -z "$ac_c_werror_flag" ||
27179          test ! -s conftest.err
27180        } && test -s conftest.$ac_objext; then
27181   ac_cv_c_volatile=yes
27182 else
27183   echo "$as_me: failed program was:" >&5
27184 sed 's/^/| /' conftest.$ac_ext >&5
27185
27186         ac_cv_c_volatile=no
27187 fi
27188
27189 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27190 fi
27191 { echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
27192 echo "${ECHO_T}$ac_cv_c_volatile" >&6; }
27193 if test $ac_cv_c_volatile = no; then
27194
27195 cat >>confdefs.h <<\_ACEOF
27196 #define volatile
27197 _ACEOF
27198
27199 fi
27200
27201
27202 { echo "$as_me:$LINENO: checking for C/C++ restrict keyword" >&5
27203 echo $ECHO_N "checking for C/C++ restrict keyword... $ECHO_C" >&6; }
27204 if test "${ac_cv_c_restrict+set}" = set; then
27205   echo $ECHO_N "(cached) $ECHO_C" >&6
27206 else
27207   ac_cv_c_restrict=no
27208    # Try the official restrict keyword, then gcc's __restrict, and
27209    # the less common variants.
27210    for ac_kw in restrict __restrict __restrict__ _Restrict; do
27211      cat >conftest.$ac_ext <<_ACEOF
27212 /* confdefs.h.  */
27213 _ACEOF
27214 cat confdefs.h >>conftest.$ac_ext
27215 cat >>conftest.$ac_ext <<_ACEOF
27216 /* end confdefs.h.  */
27217 typedef int * int_ptr;
27218         int foo (int_ptr $ac_kw ip) {
27219         return ip[0];
27220        }
27221 int
27222 main ()
27223 {
27224 int s[1];
27225         int * $ac_kw t = s;
27226         t[0] = 0;
27227         return foo(t)
27228   ;
27229   return 0;
27230 }
27231 _ACEOF
27232 rm -f conftest.$ac_objext
27233 if { (ac_try="$ac_compile"
27234 case "(($ac_try" in
27235   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27236   *) ac_try_echo=$ac_try;;
27237 esac
27238 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27239   (eval "$ac_compile") 2>conftest.er1
27240   ac_status=$?
27241   grep -v '^ *+' conftest.er1 >conftest.err
27242   rm -f conftest.er1
27243   cat conftest.err >&5
27244   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27245   (exit $ac_status); } && {
27246          test -z "$ac_c_werror_flag" ||
27247          test ! -s conftest.err
27248        } && test -s conftest.$ac_objext; then
27249   ac_cv_c_restrict=$ac_kw
27250 else
27251   echo "$as_me: failed program was:" >&5
27252 sed 's/^/| /' conftest.$ac_ext >&5
27253
27254
27255 fi
27256
27257 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27258      test "$ac_cv_c_restrict" != no && break
27259    done
27260
27261 fi
27262 { echo "$as_me:$LINENO: result: $ac_cv_c_restrict" >&5
27263 echo "${ECHO_T}$ac_cv_c_restrict" >&6; }
27264  case $ac_cv_c_restrict in
27265    restrict) ;;
27266    no)
27267 cat >>confdefs.h <<\_ACEOF
27268 #define restrict
27269 _ACEOF
27270  ;;
27271    *)  cat >>confdefs.h <<_ACEOF
27272 #define restrict $ac_cv_c_restrict
27273 _ACEOF
27274  ;;
27275  esac
27276
27277
27278 { echo "$as_me:$LINENO: checking whether <stdarg.h> exists and works" >&5
27279 echo $ECHO_N "checking whether <stdarg.h> exists and works... $ECHO_C" >&6; }
27280 if test "${gmp_cv_c_stdarg+set}" = set; then
27281   echo $ECHO_N "(cached) $ECHO_C" >&6
27282 else
27283   cat >conftest.$ac_ext <<_ACEOF
27284 /* confdefs.h.  */
27285 _ACEOF
27286 cat confdefs.h >>conftest.$ac_ext
27287 cat >>conftest.$ac_ext <<_ACEOF
27288 /* end confdefs.h.  */
27289 #include <stdarg.h>
27290 int foo (int x, ...)
27291 {
27292   va_list  ap;
27293   int      y;
27294   va_start (ap, x);
27295   y = va_arg (ap, int);
27296   va_end (ap);
27297   return y;
27298 }
27299 int
27300 main ()
27301 {
27302
27303   ;
27304   return 0;
27305 }
27306 _ACEOF
27307 rm -f conftest.$ac_objext
27308 if { (ac_try="$ac_compile"
27309 case "(($ac_try" in
27310   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27311   *) ac_try_echo=$ac_try;;
27312 esac
27313 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27314   (eval "$ac_compile") 2>conftest.er1
27315   ac_status=$?
27316   grep -v '^ *+' conftest.er1 >conftest.err
27317   rm -f conftest.er1
27318   cat conftest.err >&5
27319   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27320   (exit $ac_status); } && {
27321          test -z "$ac_c_werror_flag" ||
27322          test ! -s conftest.err
27323        } && test -s conftest.$ac_objext; then
27324   gmp_cv_c_stdarg=yes
27325 else
27326   echo "$as_me: failed program was:" >&5
27327 sed 's/^/| /' conftest.$ac_ext >&5
27328
27329         gmp_cv_c_stdarg=no
27330 fi
27331
27332 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27333
27334 fi
27335 { echo "$as_me:$LINENO: result: $gmp_cv_c_stdarg" >&5
27336 echo "${ECHO_T}$gmp_cv_c_stdarg" >&6; }
27337 if test $gmp_cv_c_stdarg = yes; then
27338
27339 cat >>confdefs.h <<\_ACEOF
27340 #define HAVE_STDARG 1
27341 _ACEOF
27342
27343 fi
27344
27345 { echo "$as_me:$LINENO: checking whether gcc __attribute__ ((const)) works" >&5
27346 echo $ECHO_N "checking whether gcc __attribute__ ((const)) works... $ECHO_C" >&6; }
27347 if test "${gmp_cv_c_attribute_const+set}" = set; then
27348   echo $ECHO_N "(cached) $ECHO_C" >&6
27349 else
27350   cat >conftest.$ac_ext <<_ACEOF
27351 /* confdefs.h.  */
27352 _ACEOF
27353 cat confdefs.h >>conftest.$ac_ext
27354 cat >>conftest.$ac_ext <<_ACEOF
27355 /* end confdefs.h.  */
27356 int foo (int x) __attribute__ ((const));
27357 int
27358 main ()
27359 {
27360
27361   ;
27362   return 0;
27363 }
27364 _ACEOF
27365 rm -f conftest.$ac_objext
27366 if { (ac_try="$ac_compile"
27367 case "(($ac_try" in
27368   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27369   *) ac_try_echo=$ac_try;;
27370 esac
27371 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27372   (eval "$ac_compile") 2>conftest.er1
27373   ac_status=$?
27374   grep -v '^ *+' conftest.er1 >conftest.err
27375   rm -f conftest.er1
27376   cat conftest.err >&5
27377   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27378   (exit $ac_status); } && {
27379          test -z "$ac_c_werror_flag" ||
27380          test ! -s conftest.err
27381        } && test -s conftest.$ac_objext; then
27382   gmp_cv_c_attribute_const=yes
27383 else
27384   echo "$as_me: failed program was:" >&5
27385 sed 's/^/| /' conftest.$ac_ext >&5
27386
27387         gmp_cv_c_attribute_const=no
27388 fi
27389
27390 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27391
27392 fi
27393 { echo "$as_me:$LINENO: result: $gmp_cv_c_attribute_const" >&5
27394 echo "${ECHO_T}$gmp_cv_c_attribute_const" >&6; }
27395 if test $gmp_cv_c_attribute_const = yes; then
27396
27397 cat >>confdefs.h <<\_ACEOF
27398 #define HAVE_ATTRIBUTE_CONST 1
27399 _ACEOF
27400
27401 fi
27402
27403 { echo "$as_me:$LINENO: checking whether gcc __attribute__ ((malloc)) works" >&5
27404 echo $ECHO_N "checking whether gcc __attribute__ ((malloc)) works... $ECHO_C" >&6; }
27405 if test "${gmp_cv_c_attribute_malloc+set}" = set; then
27406   echo $ECHO_N "(cached) $ECHO_C" >&6
27407 else
27408   cat >conftest.c <<EOF
27409 void *foo (int x) __attribute__ ((malloc));
27410 EOF
27411 gmp_compile="$CC $CFLAGS $CPPFLAGS -c conftest.c >conftest.out 2>&1"
27412 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
27413   (eval $gmp_compile) 2>&5
27414   ac_status=$?
27415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27416   (exit $ac_status); }; then
27417   if grep "attribute directive ignored" conftest.out >/dev/null; then
27418     gmp_cv_c_attribute_malloc=no
27419   else
27420     gmp_cv_c_attribute_malloc=yes
27421   fi
27422 else
27423   gmp_cv_c_attribute_malloc=no
27424 fi
27425 cat conftest.out >&5
27426 rm -f conftest*
27427
27428 fi
27429 { echo "$as_me:$LINENO: result: $gmp_cv_c_attribute_malloc" >&5
27430 echo "${ECHO_T}$gmp_cv_c_attribute_malloc" >&6; }
27431 if test $gmp_cv_c_attribute_malloc = yes; then
27432
27433 cat >>confdefs.h <<\_ACEOF
27434 #define HAVE_ATTRIBUTE_MALLOC 1
27435 _ACEOF
27436
27437 fi
27438
27439 { echo "$as_me:$LINENO: checking whether gcc __attribute__ ((mode (XX))) works" >&5
27440 echo $ECHO_N "checking whether gcc __attribute__ ((mode (XX))) works... $ECHO_C" >&6; }
27441 if test "${gmp_cv_c_attribute_mode+set}" = set; then
27442   echo $ECHO_N "(cached) $ECHO_C" >&6
27443 else
27444   cat >conftest.$ac_ext <<_ACEOF
27445 /* confdefs.h.  */
27446 _ACEOF
27447 cat confdefs.h >>conftest.$ac_ext
27448 cat >>conftest.$ac_ext <<_ACEOF
27449 /* end confdefs.h.  */
27450 typedef int SItype __attribute__ ((mode (SI)));
27451 int
27452 main ()
27453 {
27454
27455   ;
27456   return 0;
27457 }
27458 _ACEOF
27459 rm -f conftest.$ac_objext
27460 if { (ac_try="$ac_compile"
27461 case "(($ac_try" in
27462   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27463   *) ac_try_echo=$ac_try;;
27464 esac
27465 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27466   (eval "$ac_compile") 2>conftest.er1
27467   ac_status=$?
27468   grep -v '^ *+' conftest.er1 >conftest.err
27469   rm -f conftest.er1
27470   cat conftest.err >&5
27471   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27472   (exit $ac_status); } && {
27473          test -z "$ac_c_werror_flag" ||
27474          test ! -s conftest.err
27475        } && test -s conftest.$ac_objext; then
27476   gmp_cv_c_attribute_mode=yes
27477 else
27478   echo "$as_me: failed program was:" >&5
27479 sed 's/^/| /' conftest.$ac_ext >&5
27480
27481         gmp_cv_c_attribute_mode=no
27482 fi
27483
27484 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27485
27486 fi
27487 { echo "$as_me:$LINENO: result: $gmp_cv_c_attribute_mode" >&5
27488 echo "${ECHO_T}$gmp_cv_c_attribute_mode" >&6; }
27489 if test $gmp_cv_c_attribute_mode = yes; then
27490
27491 cat >>confdefs.h <<\_ACEOF
27492 #define HAVE_ATTRIBUTE_MODE 1
27493 _ACEOF
27494
27495 fi
27496
27497 { echo "$as_me:$LINENO: checking whether gcc __attribute__ ((noreturn)) works" >&5
27498 echo $ECHO_N "checking whether gcc __attribute__ ((noreturn)) works... $ECHO_C" >&6; }
27499 if test "${gmp_cv_c_attribute_noreturn+set}" = set; then
27500   echo $ECHO_N "(cached) $ECHO_C" >&6
27501 else
27502   cat >conftest.$ac_ext <<_ACEOF
27503 /* confdefs.h.  */
27504 _ACEOF
27505 cat confdefs.h >>conftest.$ac_ext
27506 cat >>conftest.$ac_ext <<_ACEOF
27507 /* end confdefs.h.  */
27508 void foo (int x) __attribute__ ((noreturn));
27509 int
27510 main ()
27511 {
27512
27513   ;
27514   return 0;
27515 }
27516 _ACEOF
27517 rm -f conftest.$ac_objext
27518 if { (ac_try="$ac_compile"
27519 case "(($ac_try" in
27520   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27521   *) ac_try_echo=$ac_try;;
27522 esac
27523 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27524   (eval "$ac_compile") 2>conftest.er1
27525   ac_status=$?
27526   grep -v '^ *+' conftest.er1 >conftest.err
27527   rm -f conftest.er1
27528   cat conftest.err >&5
27529   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27530   (exit $ac_status); } && {
27531          test -z "$ac_c_werror_flag" ||
27532          test ! -s conftest.err
27533        } && test -s conftest.$ac_objext; then
27534   gmp_cv_c_attribute_noreturn=yes
27535 else
27536   echo "$as_me: failed program was:" >&5
27537 sed 's/^/| /' conftest.$ac_ext >&5
27538
27539         gmp_cv_c_attribute_noreturn=no
27540 fi
27541
27542 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27543
27544 fi
27545 { echo "$as_me:$LINENO: result: $gmp_cv_c_attribute_noreturn" >&5
27546 echo "${ECHO_T}$gmp_cv_c_attribute_noreturn" >&6; }
27547 if test $gmp_cv_c_attribute_noreturn = yes; then
27548
27549 cat >>confdefs.h <<\_ACEOF
27550 #define HAVE_ATTRIBUTE_NORETURN 1
27551 _ACEOF
27552
27553 fi
27554
27555
27556 { echo "$as_me:$LINENO: checking for inline" >&5
27557 echo $ECHO_N "checking for inline... $ECHO_C" >&6; }
27558 if test "${ac_cv_c_inline+set}" = set; then
27559   echo $ECHO_N "(cached) $ECHO_C" >&6
27560 else
27561   ac_cv_c_inline=no
27562 for ac_kw in inline __inline__ __inline; do
27563   cat >conftest.$ac_ext <<_ACEOF
27564 /* confdefs.h.  */
27565 _ACEOF
27566 cat confdefs.h >>conftest.$ac_ext
27567 cat >>conftest.$ac_ext <<_ACEOF
27568 /* end confdefs.h.  */
27569 #ifndef __cplusplus
27570 typedef int foo_t;
27571 static $ac_kw foo_t static_foo () {return 0; }
27572 $ac_kw foo_t foo () {return 0; }
27573 #endif
27574
27575 _ACEOF
27576 rm -f conftest.$ac_objext
27577 if { (ac_try="$ac_compile"
27578 case "(($ac_try" in
27579   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27580   *) ac_try_echo=$ac_try;;
27581 esac
27582 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27583   (eval "$ac_compile") 2>conftest.er1
27584   ac_status=$?
27585   grep -v '^ *+' conftest.er1 >conftest.err
27586   rm -f conftest.er1
27587   cat conftest.err >&5
27588   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27589   (exit $ac_status); } && {
27590          test -z "$ac_c_werror_flag" ||
27591          test ! -s conftest.err
27592        } && test -s conftest.$ac_objext; then
27593   ac_cv_c_inline=$ac_kw
27594 else
27595   echo "$as_me: failed program was:" >&5
27596 sed 's/^/| /' conftest.$ac_ext >&5
27597
27598
27599 fi
27600
27601 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27602   test "$ac_cv_c_inline" != no && break
27603 done
27604
27605 fi
27606 { echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
27607 echo "${ECHO_T}$ac_cv_c_inline" >&6; }
27608
27609
27610 case $ac_cv_c_inline in
27611   inline | yes) ;;
27612   *)
27613     case $ac_cv_c_inline in
27614       no) ac_val=;;
27615       *) ac_val=$ac_cv_c_inline;;
27616     esac
27617     cat >>confdefs.h <<_ACEOF
27618 #ifndef __cplusplus
27619 #define inline $ac_val
27620 #endif
27621 _ACEOF
27622     ;;
27623 esac
27624
27625
27626 case $ac_cv_c_inline in
27627 no) ;;
27628 *)
27629   cat >conftest.$ac_ext <<_ACEOF
27630 /* confdefs.h.  */
27631 _ACEOF
27632 cat confdefs.h >>conftest.$ac_ext
27633 cat >>conftest.$ac_ext <<_ACEOF
27634 /* end confdefs.h.  */
27635 #define __GMP_WITHIN_CONFIGURE_INLINE 1
27636 #define __GMP_WITHIN_CONFIGURE 1   /* ignore template stuff */
27637 #define GMP_NAIL_BITS $GMP_NAIL_BITS
27638 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
27639 #define GMP_LIMB_BITS 123
27640 $DEFN_LONG_LONG_LIMB
27641 #include "$srcdir/gmp-h.in"
27642
27643 #ifndef __GMP_EXTERN_INLINE
27644 die die die
27645 #endif
27646
27647 int
27648 main ()
27649 {
27650
27651   ;
27652   return 0;
27653 }
27654 _ACEOF
27655 rm -f conftest.$ac_objext
27656 if { (ac_try="$ac_compile"
27657 case "(($ac_try" in
27658   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27659   *) ac_try_echo=$ac_try;;
27660 esac
27661 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27662   (eval "$ac_compile") 2>conftest.er1
27663   ac_status=$?
27664   grep -v '^ *+' conftest.er1 >conftest.err
27665   rm -f conftest.er1
27666   cat conftest.err >&5
27667   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27668   (exit $ac_status); } && {
27669          test -z "$ac_c_werror_flag" ||
27670          test ! -s conftest.err
27671        } && test -s conftest.$ac_objext; then
27672   :
27673 else
27674   echo "$as_me: failed program was:" >&5
27675 sed 's/^/| /' conftest.$ac_ext >&5
27676
27677         case $ac_cv_c_inline in
27678   yes) tmp_inline=inline ;;
27679   *)   tmp_inline=$ac_cv_c_inline ;;
27680   esac
27681   { echo "$as_me:$LINENO: WARNING: gmp.h doesnt recognise compiler \"$tmp_inline\", inlines will be unavailable" >&5
27682 echo "$as_me: WARNING: gmp.h doesnt recognise compiler \"$tmp_inline\", inlines will be unavailable" >&2;}
27683 fi
27684
27685 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27686   ;;
27687 esac
27688
27689
27690 # from libtool
27691 LIBM=
27692 case $host in
27693 *-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*)
27694   # These system don't have libm, or don't need it
27695   ;;
27696 *-ncr-sysv4.3*)
27697   { echo "$as_me:$LINENO: checking for _mwvalidcheckl in -lmw" >&5
27698 echo $ECHO_N "checking for _mwvalidcheckl in -lmw... $ECHO_C" >&6; }
27699 if test "${ac_cv_lib_mw__mwvalidcheckl+set}" = set; then
27700   echo $ECHO_N "(cached) $ECHO_C" >&6
27701 else
27702   ac_check_lib_save_LIBS=$LIBS
27703 LIBS="-lmw  $LIBS"
27704 cat >conftest.$ac_ext <<_ACEOF
27705 /* confdefs.h.  */
27706 _ACEOF
27707 cat confdefs.h >>conftest.$ac_ext
27708 cat >>conftest.$ac_ext <<_ACEOF
27709 /* end confdefs.h.  */
27710
27711 /* Override any GCC internal prototype to avoid an error.
27712    Use char because int might match the return type of a GCC
27713    builtin and then its argument prototype would still apply.  */
27714 #ifdef __cplusplus
27715 extern "C"
27716 #endif
27717 char _mwvalidcheckl ();
27718 int
27719 main ()
27720 {
27721 return _mwvalidcheckl ();
27722   ;
27723   return 0;
27724 }
27725 _ACEOF
27726 rm -f conftest.$ac_objext conftest$ac_exeext
27727 if { (ac_try="$ac_link"
27728 case "(($ac_try" in
27729   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27730   *) ac_try_echo=$ac_try;;
27731 esac
27732 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27733   (eval "$ac_link") 2>conftest.er1
27734   ac_status=$?
27735   grep -v '^ *+' conftest.er1 >conftest.err
27736   rm -f conftest.er1
27737   cat conftest.err >&5
27738   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27739   (exit $ac_status); } && {
27740          test -z "$ac_c_werror_flag" ||
27741          test ! -s conftest.err
27742        } && test -s conftest$ac_exeext &&
27743        $as_test_x conftest$ac_exeext; then
27744   ac_cv_lib_mw__mwvalidcheckl=yes
27745 else
27746   echo "$as_me: failed program was:" >&5
27747 sed 's/^/| /' conftest.$ac_ext >&5
27748
27749         ac_cv_lib_mw__mwvalidcheckl=no
27750 fi
27751
27752 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
27753       conftest$ac_exeext conftest.$ac_ext
27754 LIBS=$ac_check_lib_save_LIBS
27755 fi
27756 { echo "$as_me:$LINENO: result: $ac_cv_lib_mw__mwvalidcheckl" >&5
27757 echo "${ECHO_T}$ac_cv_lib_mw__mwvalidcheckl" >&6; }
27758 if test $ac_cv_lib_mw__mwvalidcheckl = yes; then
27759   LIBM="-lmw"
27760 fi
27761
27762   { echo "$as_me:$LINENO: checking for cos in -lm" >&5
27763 echo $ECHO_N "checking for cos in -lm... $ECHO_C" >&6; }
27764 if test "${ac_cv_lib_m_cos+set}" = set; then
27765   echo $ECHO_N "(cached) $ECHO_C" >&6
27766 else
27767   ac_check_lib_save_LIBS=$LIBS
27768 LIBS="-lm  $LIBS"
27769 cat >conftest.$ac_ext <<_ACEOF
27770 /* confdefs.h.  */
27771 _ACEOF
27772 cat confdefs.h >>conftest.$ac_ext
27773 cat >>conftest.$ac_ext <<_ACEOF
27774 /* end confdefs.h.  */
27775
27776 /* Override any GCC internal prototype to avoid an error.
27777    Use char because int might match the return type of a GCC
27778    builtin and then its argument prototype would still apply.  */
27779 #ifdef __cplusplus
27780 extern "C"
27781 #endif
27782 char cos ();
27783 int
27784 main ()
27785 {
27786 return cos ();
27787   ;
27788   return 0;
27789 }
27790 _ACEOF
27791 rm -f conftest.$ac_objext conftest$ac_exeext
27792 if { (ac_try="$ac_link"
27793 case "(($ac_try" in
27794   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27795   *) ac_try_echo=$ac_try;;
27796 esac
27797 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27798   (eval "$ac_link") 2>conftest.er1
27799   ac_status=$?
27800   grep -v '^ *+' conftest.er1 >conftest.err
27801   rm -f conftest.er1
27802   cat conftest.err >&5
27803   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27804   (exit $ac_status); } && {
27805          test -z "$ac_c_werror_flag" ||
27806          test ! -s conftest.err
27807        } && test -s conftest$ac_exeext &&
27808        $as_test_x conftest$ac_exeext; then
27809   ac_cv_lib_m_cos=yes
27810 else
27811   echo "$as_me: failed program was:" >&5
27812 sed 's/^/| /' conftest.$ac_ext >&5
27813
27814         ac_cv_lib_m_cos=no
27815 fi
27816
27817 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
27818       conftest$ac_exeext conftest.$ac_ext
27819 LIBS=$ac_check_lib_save_LIBS
27820 fi
27821 { echo "$as_me:$LINENO: result: $ac_cv_lib_m_cos" >&5
27822 echo "${ECHO_T}$ac_cv_lib_m_cos" >&6; }
27823 if test $ac_cv_lib_m_cos = yes; then
27824   LIBM="$LIBM -lm"
27825 fi
27826
27827   ;;
27828 *)
27829   { echo "$as_me:$LINENO: checking for cos in -lm" >&5
27830 echo $ECHO_N "checking for cos in -lm... $ECHO_C" >&6; }
27831 if test "${ac_cv_lib_m_cos+set}" = set; then
27832   echo $ECHO_N "(cached) $ECHO_C" >&6
27833 else
27834   ac_check_lib_save_LIBS=$LIBS
27835 LIBS="-lm  $LIBS"
27836 cat >conftest.$ac_ext <<_ACEOF
27837 /* confdefs.h.  */
27838 _ACEOF
27839 cat confdefs.h >>conftest.$ac_ext
27840 cat >>conftest.$ac_ext <<_ACEOF
27841 /* end confdefs.h.  */
27842
27843 /* Override any GCC internal prototype to avoid an error.
27844    Use char because int might match the return type of a GCC
27845    builtin and then its argument prototype would still apply.  */
27846 #ifdef __cplusplus
27847 extern "C"
27848 #endif
27849 char cos ();
27850 int
27851 main ()
27852 {
27853 return cos ();
27854   ;
27855   return 0;
27856 }
27857 _ACEOF
27858 rm -f conftest.$ac_objext conftest$ac_exeext
27859 if { (ac_try="$ac_link"
27860 case "(($ac_try" in
27861   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27862   *) ac_try_echo=$ac_try;;
27863 esac
27864 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27865   (eval "$ac_link") 2>conftest.er1
27866   ac_status=$?
27867   grep -v '^ *+' conftest.er1 >conftest.err
27868   rm -f conftest.er1
27869   cat conftest.err >&5
27870   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27871   (exit $ac_status); } && {
27872          test -z "$ac_c_werror_flag" ||
27873          test ! -s conftest.err
27874        } && test -s conftest$ac_exeext &&
27875        $as_test_x conftest$ac_exeext; then
27876   ac_cv_lib_m_cos=yes
27877 else
27878   echo "$as_me: failed program was:" >&5
27879 sed 's/^/| /' conftest.$ac_ext >&5
27880
27881         ac_cv_lib_m_cos=no
27882 fi
27883
27884 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
27885       conftest$ac_exeext conftest.$ac_ext
27886 LIBS=$ac_check_lib_save_LIBS
27887 fi
27888 { echo "$as_me:$LINENO: result: $ac_cv_lib_m_cos" >&5
27889 echo "${ECHO_T}$ac_cv_lib_m_cos" >&6; }
27890 if test $ac_cv_lib_m_cos = yes; then
27891   LIBM="-lm"
27892 fi
27893
27894   ;;
27895 esac
27896
27897
27898
27899 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
27900 # for constant arguments.  Useless!
27901 { echo "$as_me:$LINENO: checking for working alloca.h" >&5
27902 echo $ECHO_N "checking for working alloca.h... $ECHO_C" >&6; }
27903 if test "${gmp_cv_header_alloca+set}" = set; then
27904   echo $ECHO_N "(cached) $ECHO_C" >&6
27905 else
27906   cat >conftest.$ac_ext <<_ACEOF
27907 /* confdefs.h.  */
27908 _ACEOF
27909 cat confdefs.h >>conftest.$ac_ext
27910 cat >>conftest.$ac_ext <<_ACEOF
27911 /* end confdefs.h.  */
27912 #include <alloca.h>
27913 int
27914 main ()
27915 {
27916 char *p = (char *) alloca (2 * sizeof (int));
27917   ;
27918   return 0;
27919 }
27920 _ACEOF
27921 rm -f conftest.$ac_objext conftest$ac_exeext
27922 if { (ac_try="$ac_link"
27923 case "(($ac_try" in
27924   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27925   *) ac_try_echo=$ac_try;;
27926 esac
27927 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27928   (eval "$ac_link") 2>conftest.er1
27929   ac_status=$?
27930   grep -v '^ *+' conftest.er1 >conftest.err
27931   rm -f conftest.er1
27932   cat conftest.err >&5
27933   echo "$as_me:$LINENO: \$? = $ac_status" >&5
27934   (exit $ac_status); } && {
27935          test -z "$ac_c_werror_flag" ||
27936          test ! -s conftest.err
27937        } && test -s conftest$ac_exeext &&
27938        $as_test_x conftest$ac_exeext; then
27939   gmp_cv_header_alloca=yes
27940 else
27941   echo "$as_me: failed program was:" >&5
27942 sed 's/^/| /' conftest.$ac_ext >&5
27943
27944         gmp_cv_header_alloca=no
27945 fi
27946
27947 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
27948       conftest$ac_exeext conftest.$ac_ext
27949 fi
27950 { echo "$as_me:$LINENO: result: $gmp_cv_header_alloca" >&5
27951 echo "${ECHO_T}$gmp_cv_header_alloca" >&6; }
27952 if test $gmp_cv_header_alloca = yes; then
27953
27954 cat >>confdefs.h <<\_ACEOF
27955 #define HAVE_ALLOCA_H 1
27956 _ACEOF
27957
27958 fi
27959
27960
27961 { echo "$as_me:$LINENO: checking for alloca (via gmp-impl.h)" >&5
27962 echo $ECHO_N "checking for alloca (via gmp-impl.h)... $ECHO_C" >&6; }
27963 if test "${gmp_cv_func_alloca+set}" = set; then
27964   echo $ECHO_N "(cached) $ECHO_C" >&6
27965 else
27966   cat >conftest.$ac_ext <<_ACEOF
27967 /* confdefs.h.  */
27968 _ACEOF
27969 cat confdefs.h >>conftest.$ac_ext
27970 cat >>conftest.$ac_ext <<_ACEOF
27971 /* end confdefs.h.  */
27972 #define __GMP_WITHIN_CONFIGURE 1   /* ignore template stuff */
27973 #define GMP_NAIL_BITS $GMP_NAIL_BITS
27974 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
27975 #define GMP_LIMB_BITS 123
27976 $DEFN_LONG_LONG_LIMB
27977 #include "$srcdir/gmp-h.in"
27978
27979 #include "$srcdir/gmp-impl.h"
27980
27981 int
27982 main ()
27983 {
27984 char *p = (char *) alloca (1);
27985   ;
27986   return 0;
27987 }
27988 _ACEOF
27989 rm -f conftest.$ac_objext conftest$ac_exeext
27990 if { (ac_try="$ac_link"
27991 case "(($ac_try" in
27992   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27993   *) ac_try_echo=$ac_try;;
27994 esac
27995 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27996   (eval "$ac_link") 2>conftest.er1
27997   ac_status=$?
27998   grep -v '^ *+' conftest.er1 >conftest.err
27999   rm -f conftest.er1
28000   cat conftest.err >&5
28001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28002   (exit $ac_status); } && {
28003          test -z "$ac_c_werror_flag" ||
28004          test ! -s conftest.err
28005        } && test -s conftest$ac_exeext &&
28006        $as_test_x conftest$ac_exeext; then
28007   gmp_cv_func_alloca=yes
28008 else
28009   echo "$as_me: failed program was:" >&5
28010 sed 's/^/| /' conftest.$ac_ext >&5
28011
28012         gmp_cv_func_alloca=no
28013 fi
28014
28015 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
28016       conftest$ac_exeext conftest.$ac_ext
28017 fi
28018 { echo "$as_me:$LINENO: result: $gmp_cv_func_alloca" >&5
28019 echo "${ECHO_T}$gmp_cv_func_alloca" >&6; }
28020 if test $gmp_cv_func_alloca = yes; then
28021
28022 cat >>confdefs.h <<\_ACEOF
28023 #define HAVE_ALLOCA 1
28024 _ACEOF
28025
28026 fi
28027
28028
28029 { echo "$as_me:$LINENO: checking how to allocate temporary memory" >&5
28030 echo $ECHO_N "checking how to allocate temporary memory... $ECHO_C" >&6; }
28031 if test "${gmp_cv_option_alloca+set}" = set; then
28032   echo $ECHO_N "(cached) $ECHO_C" >&6
28033 else
28034   case $enable_alloca in
28035   yes)
28036     gmp_cv_option_alloca=alloca
28037     ;;
28038   no)
28039     gmp_cv_option_alloca=malloc-reentrant
28040     ;;
28041   reentrant | notreentrant)
28042     case $gmp_cv_func_alloca in
28043     yes)  gmp_cv_option_alloca=alloca ;;
28044     *)    gmp_cv_option_alloca=malloc-$enable_alloca ;;
28045     esac
28046     ;;
28047   *)
28048     gmp_cv_option_alloca=$enable_alloca
28049     ;;
28050 esac
28051
28052 fi
28053 { echo "$as_me:$LINENO: result: $gmp_cv_option_alloca" >&5
28054 echo "${ECHO_T}$gmp_cv_option_alloca" >&6; }
28055
28056
28057
28058
28059 case $gmp_cv_option_alloca in
28060   alloca)
28061     if test $gmp_cv_func_alloca = no; then
28062       { { echo "$as_me:$LINENO: error: --enable-alloca=alloca specified, but alloca not available" >&5
28063 echo "$as_me: error: --enable-alloca=alloca specified, but alloca not available" >&2;}
28064    { (exit 1); exit 1; }; }
28065     fi
28066     cat >>confdefs.h <<\_ACEOF
28067 #define WANT_TMP_ALLOCA 1
28068 _ACEOF
28069
28070     TAL_OBJECT=tal-reent$U.lo
28071     ;;
28072   malloc-reentrant)
28073     cat >>confdefs.h <<\_ACEOF
28074 #define WANT_TMP_REENTRANT 1
28075 _ACEOF
28076
28077     TAL_OBJECT=tal-reent$U.lo
28078     ;;
28079   malloc-notreentrant)
28080     cat >>confdefs.h <<\_ACEOF
28081 #define WANT_TMP_NOTREENTRANT 1
28082 _ACEOF
28083
28084     TAL_OBJECT=tal-notreent$U.lo
28085     ;;
28086   debug)
28087     cat >>confdefs.h <<\_ACEOF
28088 #define WANT_TMP_DEBUG 1
28089 _ACEOF
28090
28091     TAL_OBJECT=tal-debug$U.lo
28092     ;;
28093   *)
28094     # checks at the start of configure.in should protect us
28095     { { echo "$as_me:$LINENO: error: unrecognised --enable-alloca=$gmp_cv_option_alloca" >&5
28096 echo "$as_me: error: unrecognised --enable-alloca=$gmp_cv_option_alloca" >&2;}
28097    { (exit 1); exit 1; }; }
28098     ;;
28099 esac
28100
28101
28102
28103 cat >conftest.$ac_ext <<_ACEOF
28104 /* confdefs.h.  */
28105 _ACEOF
28106 cat confdefs.h >>conftest.$ac_ext
28107 cat >>conftest.$ac_ext <<_ACEOF
28108 /* end confdefs.h.  */
28109 #include <stdio.h>
28110 #define __GMP_WITHIN_CONFIGURE 1   /* ignore template stuff */
28111 #define GMP_NAIL_BITS $GMP_NAIL_BITS
28112 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
28113 #define GMP_LIMB_BITS 123
28114 $DEFN_LONG_LONG_LIMB
28115 #include "$srcdir/gmp-h.in"
28116
28117 #if ! _GMP_H_HAVE_FILE
28118 die die die
28119 #endif
28120
28121 int
28122 main ()
28123 {
28124
28125   ;
28126   return 0;
28127 }
28128 _ACEOF
28129 rm -f conftest.$ac_objext
28130 if { (ac_try="$ac_compile"
28131 case "(($ac_try" in
28132   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28133   *) ac_try_echo=$ac_try;;
28134 esac
28135 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28136   (eval "$ac_compile") 2>conftest.er1
28137   ac_status=$?
28138   grep -v '^ *+' conftest.er1 >conftest.err
28139   rm -f conftest.er1
28140   cat conftest.err >&5
28141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28142   (exit $ac_status); } && {
28143          test -z "$ac_c_werror_flag" ||
28144          test ! -s conftest.err
28145        } && test -s conftest.$ac_objext; then
28146   :
28147 else
28148   echo "$as_me: failed program was:" >&5
28149 sed 's/^/| /' conftest.$ac_ext >&5
28150
28151         { echo "$as_me:$LINENO: WARNING: gmp.h doesnt recognise <stdio.h>, FILE prototypes will be unavailable" >&5
28152 echo "$as_me: WARNING: gmp.h doesnt recognise <stdio.h>, FILE prototypes will be unavailable" >&2;}
28153 fi
28154
28155 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28156
28157
28158 { echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
28159 echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6; }
28160 if test "${ac_cv_c_bigendian+set}" = set; then
28161   echo $ECHO_N "(cached) $ECHO_C" >&6
28162 else
28163   # See if sys/param.h defines the BYTE_ORDER macro.
28164 cat >conftest.$ac_ext <<_ACEOF
28165 /* confdefs.h.  */
28166 _ACEOF
28167 cat confdefs.h >>conftest.$ac_ext
28168 cat >>conftest.$ac_ext <<_ACEOF
28169 /* end confdefs.h.  */
28170 #include <sys/types.h>
28171 #include <sys/param.h>
28172
28173 int
28174 main ()
28175 {
28176 #if  ! (defined BYTE_ORDER && defined BIG_ENDIAN && defined LITTLE_ENDIAN \
28177         && BYTE_ORDER && BIG_ENDIAN && LITTLE_ENDIAN)
28178  bogus endian macros
28179 #endif
28180
28181   ;
28182   return 0;
28183 }
28184 _ACEOF
28185 rm -f conftest.$ac_objext
28186 if { (ac_try="$ac_compile"
28187 case "(($ac_try" in
28188   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28189   *) ac_try_echo=$ac_try;;
28190 esac
28191 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28192   (eval "$ac_compile") 2>conftest.er1
28193   ac_status=$?
28194   grep -v '^ *+' conftest.er1 >conftest.err
28195   rm -f conftest.er1
28196   cat conftest.err >&5
28197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28198   (exit $ac_status); } && {
28199          test -z "$ac_c_werror_flag" ||
28200          test ! -s conftest.err
28201        } && test -s conftest.$ac_objext; then
28202   # It does; now see whether it defined to BIG_ENDIAN or not.
28203 cat >conftest.$ac_ext <<_ACEOF
28204 /* confdefs.h.  */
28205 _ACEOF
28206 cat confdefs.h >>conftest.$ac_ext
28207 cat >>conftest.$ac_ext <<_ACEOF
28208 /* end confdefs.h.  */
28209 #include <sys/types.h>
28210 #include <sys/param.h>
28211
28212 int
28213 main ()
28214 {
28215 #if BYTE_ORDER != BIG_ENDIAN
28216  not big endian
28217 #endif
28218
28219   ;
28220   return 0;
28221 }
28222 _ACEOF
28223 rm -f conftest.$ac_objext
28224 if { (ac_try="$ac_compile"
28225 case "(($ac_try" in
28226   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28227   *) ac_try_echo=$ac_try;;
28228 esac
28229 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28230   (eval "$ac_compile") 2>conftest.er1
28231   ac_status=$?
28232   grep -v '^ *+' conftest.er1 >conftest.err
28233   rm -f conftest.er1
28234   cat conftest.err >&5
28235   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28236   (exit $ac_status); } && {
28237          test -z "$ac_c_werror_flag" ||
28238          test ! -s conftest.err
28239        } && test -s conftest.$ac_objext; then
28240   ac_cv_c_bigendian=yes
28241 else
28242   echo "$as_me: failed program was:" >&5
28243 sed 's/^/| /' conftest.$ac_ext >&5
28244
28245         ac_cv_c_bigendian=no
28246 fi
28247
28248 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28249 else
28250   echo "$as_me: failed program was:" >&5
28251 sed 's/^/| /' conftest.$ac_ext >&5
28252
28253         # It does not; compile a test program.
28254 if test "$cross_compiling" = yes; then
28255   # try to guess the endianness by grepping values into an object file
28256   ac_cv_c_bigendian=unknown
28257   cat >conftest.$ac_ext <<_ACEOF
28258 /* confdefs.h.  */
28259 _ACEOF
28260 cat confdefs.h >>conftest.$ac_ext
28261 cat >>conftest.$ac_ext <<_ACEOF
28262 /* end confdefs.h.  */
28263 short int ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
28264 short int ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
28265 void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
28266 short int ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
28267 short int ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
28268 void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
28269 int
28270 main ()
28271 {
28272  _ascii (); _ebcdic ();
28273   ;
28274   return 0;
28275 }
28276 _ACEOF
28277 rm -f conftest.$ac_objext
28278 if { (ac_try="$ac_compile"
28279 case "(($ac_try" in
28280   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28281   *) ac_try_echo=$ac_try;;
28282 esac
28283 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28284   (eval "$ac_compile") 2>conftest.er1
28285   ac_status=$?
28286   grep -v '^ *+' conftest.er1 >conftest.err
28287   rm -f conftest.er1
28288   cat conftest.err >&5
28289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28290   (exit $ac_status); } && {
28291          test -z "$ac_c_werror_flag" ||
28292          test ! -s conftest.err
28293        } && test -s conftest.$ac_objext; then
28294   if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
28295   ac_cv_c_bigendian=yes
28296 fi
28297 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
28298   if test "$ac_cv_c_bigendian" = unknown; then
28299     ac_cv_c_bigendian=no
28300   else
28301     # finding both strings is unlikely to happen, but who knows?
28302     ac_cv_c_bigendian=unknown
28303   fi
28304 fi
28305 else
28306   echo "$as_me: failed program was:" >&5
28307 sed 's/^/| /' conftest.$ac_ext >&5
28308
28309
28310 fi
28311
28312 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28313 else
28314   cat >conftest.$ac_ext <<_ACEOF
28315 /* confdefs.h.  */
28316 _ACEOF
28317 cat confdefs.h >>conftest.$ac_ext
28318 cat >>conftest.$ac_ext <<_ACEOF
28319 /* end confdefs.h.  */
28320 $ac_includes_default
28321 int
28322 main ()
28323 {
28324
28325   /* Are we little or big endian?  From Harbison&Steele.  */
28326   union
28327   {
28328     long int l;
28329     char c[sizeof (long int)];
28330   } u;
28331   u.l = 1;
28332   return u.c[sizeof (long int) - 1] == 1;
28333
28334   ;
28335   return 0;
28336 }
28337 _ACEOF
28338 rm -f conftest$ac_exeext
28339 if { (ac_try="$ac_link"
28340 case "(($ac_try" in
28341   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28342   *) ac_try_echo=$ac_try;;
28343 esac
28344 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28345   (eval "$ac_link") 2>&5
28346   ac_status=$?
28347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28348   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28349   { (case "(($ac_try" in
28350   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28351   *) ac_try_echo=$ac_try;;
28352 esac
28353 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28354   (eval "$ac_try") 2>&5
28355   ac_status=$?
28356   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28357   (exit $ac_status); }; }; then
28358   ac_cv_c_bigendian=no
28359 else
28360   echo "$as_me: program exited with status $ac_status" >&5
28361 echo "$as_me: failed program was:" >&5
28362 sed 's/^/| /' conftest.$ac_ext >&5
28363
28364 ( exit $ac_status )
28365 ac_cv_c_bigendian=yes
28366 fi
28367 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28368 fi
28369
28370
28371 fi
28372
28373 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28374 fi
28375 { echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
28376 echo "${ECHO_T}$ac_cv_c_bigendian" >&6; }
28377 case $ac_cv_c_bigendian in
28378   yes)
28379     cat >>confdefs.h <<\_ACEOF
28380 #define HAVE_LIMB_BIG_ENDIAN 1
28381 _ACEOF
28382
28383
28384 echo "define_not_for_expansion(\`HAVE_LIMB_BIG_ENDIAN')" >> $gmp_tmpconfigm4p
28385  ;;
28386   no)
28387     cat >>confdefs.h <<\_ACEOF
28388 #define HAVE_LIMB_LITTLE_ENDIAN 1
28389 _ACEOF
28390
28391
28392 echo "define_not_for_expansion(\`HAVE_LIMB_LITTLE_ENDIAN')" >> $gmp_tmpconfigm4p
28393
28394    ;;
28395   *)
28396     : ;;
28397 esac
28398
28399
28400
28401
28402
28403
28404 { echo "$as_me:$LINENO: checking format of \`double' floating point" >&5
28405 echo $ECHO_N "checking format of \`double' floating point... $ECHO_C" >&6; }
28406 if test "${gmp_cv_c_double_format+set}" = set; then
28407   echo $ECHO_N "(cached) $ECHO_C" >&6
28408 else
28409   gmp_cv_c_double_format=unknown
28410 cat >conftest.c <<\EOF
28411 struct {
28412   char    before[8];
28413   double  x;
28414   char    after[8];
28415 } foo = {
28416   { '\001', '\043', '\105', '\147', '\211', '\253', '\315', '\357' },
28417   -123456789.0,
28418   { '\376', '\334', '\272', '\230', '\166', '\124', '\062', '\020' },
28419 };
28420 EOF
28421 gmp_compile="$CC $CFLAGS $CPPFLAGS -c conftest.c >&5 2>&1"
28422 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
28423   (eval $gmp_compile) 2>&5
28424   ac_status=$?
28425   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28426   (exit $ac_status); }; then
28427 cat >conftest.awk <<\EOF
28428
28429 BEGIN {
28430   found = 0
28431 }
28432
28433 {
28434   for (f = 2; f <= NF; f++)
28435     {
28436       for (i = 0; i < 23; i++)
28437         got[i] = got[i+1];
28438       got[23] = $f;
28439
28440       # match the special begin and end sequences
28441       if (got[0] != "001") continue
28442       if (got[1] != "043") continue
28443       if (got[2] != "105") continue
28444       if (got[3] != "147") continue
28445       if (got[4] != "211") continue
28446       if (got[5] != "253") continue
28447       if (got[6] != "315") continue
28448       if (got[7] != "357") continue
28449       if (got[16] != "376") continue
28450       if (got[17] != "334") continue
28451       if (got[18] != "272") continue
28452       if (got[19] != "230") continue
28453       if (got[20] != "166") continue
28454       if (got[21] != "124") continue
28455       if (got[22] != "062") continue
28456       if (got[23] != "020") continue
28457
28458       saw = " (" got[8] " " got[9] " " got[10] " " got[11] " " got[12] " " got[13] " " got[14] " " got[15] ")"
28459
28460       if (got[8]  == "000" &&  \
28461           got[9]  == "000" &&  \
28462           got[10] == "000" &&  \
28463           got[11] == "124" &&  \
28464           got[12] == "064" &&  \
28465           got[13] == "157" &&  \
28466           got[14] == "235" &&  \
28467           got[15] == "301")
28468         {
28469           print "IEEE little endian"
28470           found = 1
28471           exit
28472         }
28473
28474       # Little endian with the two 4-byte halves swapped, as used by ARM
28475       # when the chip is in little endian mode.
28476       #
28477       if (got[8]  == "064" &&  \
28478           got[9]  == "157" &&  \
28479           got[10] == "235" &&  \
28480           got[11] == "301" &&  \
28481           got[12] == "000" &&  \
28482           got[13] == "000" &&  \
28483           got[14] == "000" &&  \
28484           got[15] == "124")
28485         {
28486           print "IEEE little endian, swapped halves"
28487           found = 1
28488           exit
28489         }
28490
28491       # gcc 2.95.4 on one GNU/Linux ARM system was seen generating 000 in
28492       # the last byte, whereas 124 is correct.  Not sure where the bug
28493       # actually lies, but a running program didn't seem to get a full
28494       # mantissa worth of working bits.
28495       #
28496       # We match this case explicitly so we can give a nice result message,
28497       # but we deliberately exclude it from the normal IEEE double setups
28498       # since it's too broken.
28499       #
28500       if (got[8]  == "064" &&  \
28501           got[9]  == "157" &&  \
28502           got[10] == "235" &&  \
28503           got[11] == "301" &&  \
28504           got[12] == "000" &&  \
28505           got[13] == "000" &&  \
28506           got[14] == "000" &&  \
28507           got[15] == "000")
28508         {
28509           print "bad ARM software floats"
28510           found = 1
28511           exit
28512         }
28513
28514       if (got[8]  == "301" &&  \
28515           got[9]  == "235" &&  \
28516           got[10] == "157" &&  \
28517           got[11] == "064" &&  \
28518           got[12] == "124" &&  \
28519           got[13] == "000" &&  \
28520           got[14] == "000" &&  \
28521           got[15] == "000")
28522         {
28523           print "IEEE big endian"
28524           found = 1
28525           exit
28526         }
28527
28528       if (got[8]  == "353" &&  \
28529           got[9]  == "315" &&  \
28530           got[10] == "242" &&  \
28531           got[11] == "171" &&  \
28532           got[12] == "000" &&  \
28533           got[13] == "240" &&  \
28534           got[14] == "000" &&  \
28535           got[15] == "000")
28536         {
28537           print "VAX D"
28538           found = 1
28539           exit
28540         }
28541
28542       if (got[8]  == "275" &&  \
28543           got[9]  == "301" &&  \
28544           got[10] == "064" &&  \
28545           got[11] == "157" &&  \
28546           got[12] == "000" &&  \
28547           got[13] == "124" &&  \
28548           got[14] == "000" &&  \
28549           got[15] == "000")
28550         {
28551           print "VAX G"
28552           found = 1
28553           exit
28554         }
28555
28556       if (got[8]  == "300" &&  \
28557           got[9]  == "033" &&  \
28558           got[10] == "353" &&  \
28559           got[11] == "171" &&  \
28560           got[12] == "242" &&  \
28561           got[13] == "240" &&  \
28562           got[14] == "000" &&  \
28563           got[15] == "000")
28564         {
28565           print "Cray CFP"
28566           found = 1
28567           exit
28568         }
28569     }
28570 }
28571
28572 END {
28573   if (! found)
28574     print "unknown", saw
28575 }
28576
28577 EOF
28578   gmp_cv_c_double_format=`od -b conftest.$OBJEXT | $AWK -f conftest.awk`
28579   case $gmp_cv_c_double_format in
28580   unknown*)
28581     echo "cannot match anything, conftest.$OBJEXT contains" >&5
28582     od -b conftest.$OBJEXT >&5
28583     ;;
28584   esac
28585 else
28586   { echo "$as_me:$LINENO: WARNING: oops, cannot compile test program" >&5
28587 echo "$as_me: WARNING: oops, cannot compile test program" >&2;}
28588 fi
28589 rm -f conftest*
28590
28591 fi
28592 { echo "$as_me:$LINENO: result: $gmp_cv_c_double_format" >&5
28593 echo "${ECHO_T}$gmp_cv_c_double_format" >&6; }
28594
28595
28596
28597
28598 case $gmp_cv_c_double_format in
28599   "IEEE big endian")
28600     cat >>confdefs.h <<\_ACEOF
28601 #define HAVE_DOUBLE_IEEE_BIG_ENDIAN 1
28602 _ACEOF
28603
28604
28605 echo "define_not_for_expansion(\`HAVE_DOUBLE_IEEE_BIG_ENDIAN')" >> $gmp_tmpconfigm4p
28606
28607     ;;
28608   "IEEE little endian")
28609     cat >>confdefs.h <<\_ACEOF
28610 #define HAVE_DOUBLE_IEEE_LITTLE_ENDIAN 1
28611 _ACEOF
28612
28613
28614 echo "define_not_for_expansion(\`HAVE_DOUBLE_IEEE_LITTLE_ENDIAN')" >> $gmp_tmpconfigm4p
28615
28616     ;;
28617   "IEEE little endian, swapped halves")
28618     cat >>confdefs.h <<\_ACEOF
28619 #define HAVE_DOUBLE_IEEE_LITTLE_SWAPPED 1
28620 _ACEOF
28621  ;;
28622   "VAX D")
28623     cat >>confdefs.h <<\_ACEOF
28624 #define HAVE_DOUBLE_VAX_D 1
28625 _ACEOF
28626  ;;
28627   "VAX G")
28628     cat >>confdefs.h <<\_ACEOF
28629 #define HAVE_DOUBLE_VAX_G 1
28630 _ACEOF
28631  ;;
28632   "Cray CFP")
28633     cat >>confdefs.h <<\_ACEOF
28634 #define HAVE_DOUBLE_CRAY_CFP 1
28635 _ACEOF
28636  ;;
28637   "bad ARM software floats")
28638     ;;
28639   unknown*)
28640     { echo "$as_me:$LINENO: WARNING: Could not determine float format." >&5
28641 echo "$as_me: WARNING: Could not determine float format." >&2;}
28642     { echo "$as_me:$LINENO: WARNING: Conversions to and from \"double\" may be slow." >&5
28643 echo "$as_me: WARNING: Conversions to and from \"double\" may be slow." >&2;}
28644     ;;
28645   *)
28646     { echo "$as_me:$LINENO: WARNING: oops, unrecognised float format: $gmp_cv_c_double_format" >&5
28647 echo "$as_me: WARNING: oops, unrecognised float format: $gmp_cv_c_double_format" >&2;}
28648     ;;
28649 esac
28650
28651
28652
28653 # Reasons for testing:
28654 #   alarm - not in mingw
28655 #   attr_get - IRIX specific
28656 #   clock_gettime - not in glibc 2.2.4, only very recent systems
28657 #   cputime - not in glibc
28658 #   getsysinfo - OSF specific
28659 #   getrusage - not in mingw
28660 #   gettimeofday - not in mingw
28661 #   mmap - not in mingw, djgpp
28662 #   nl_langinfo - X/Open standard only, not in djgpp for instance
28663 #   obstack_vprintf - glibc specific
28664 #   processor_info - solaris specific
28665 #   pstat_getprocessor - HPUX specific (10.x and up)
28666 #   raise - an ANSI-ism, though probably almost universal by now
28667 #   read_real_time - AIX specific
28668 #   sigaction - not in mingw
28669 #   sigaltstack - not in mingw, or old AIX (reputedly)
28670 #   sigstack - not in mingw
28671 #   strerror - not in SunOS
28672 #   strnlen - glibc extension (some other systems too)
28673 #   syssgi - IRIX specific
28674 #   times - not in mingw
28675 #
28676 # clock_gettime is in librt on *-*-osf5.1.  We could look for it
28677 # there, but that's not worth bothering with unless it has a decent
28678 # resolution (in a quick test clock_getres said only 1 millisecond).
28679 #
28680 # AC_FUNC_STRNLEN is not used because we don't want the AC_LIBOBJ
28681 # replacement setups it gives.  It detects a faulty strnlen on AIX, but
28682 # missing out on that test is ok since our only use of strnlen is in
28683 # __gmp_replacement_vsnprintf which is not required on AIX since it has a
28684 # vsnprintf.
28685 #
28686
28687
28688
28689
28690
28691
28692
28693
28694
28695
28696
28697
28698
28699
28700
28701
28702
28703
28704
28705
28706
28707
28708
28709
28710
28711
28712
28713
28714
28715
28716
28717
28718
28719 for ac_func in alarm attr_get clock clock_gettime cputime getpagesize getrusage gettimeofday getsysinfo localeconv memset mmap mprotect nl_langinfo obstack_vprintf popen processor_info pstat_getprocessor raise read_real_time sigaction sigaltstack sigstack syssgi strchr strerror strnlen strtol strtoul sysconf sysctl sysctlbyname times
28720 do
28721 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
28722 { echo "$as_me:$LINENO: checking for $ac_func" >&5
28723 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
28724 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
28725   echo $ECHO_N "(cached) $ECHO_C" >&6
28726 else
28727   cat >conftest.$ac_ext <<_ACEOF
28728 /* confdefs.h.  */
28729 _ACEOF
28730 cat confdefs.h >>conftest.$ac_ext
28731 cat >>conftest.$ac_ext <<_ACEOF
28732 /* end confdefs.h.  */
28733 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
28734    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
28735 #define $ac_func innocuous_$ac_func
28736
28737 /* System header to define __stub macros and hopefully few prototypes,
28738     which can conflict with char $ac_func (); below.
28739     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
28740     <limits.h> exists even on freestanding compilers.  */
28741
28742 #ifdef __STDC__
28743 # include <limits.h>
28744 #else
28745 # include <assert.h>
28746 #endif
28747
28748 #undef $ac_func
28749
28750 /* Override any GCC internal prototype to avoid an error.
28751    Use char because int might match the return type of a GCC
28752    builtin and then its argument prototype would still apply.  */
28753 #ifdef __cplusplus
28754 extern "C"
28755 #endif
28756 char $ac_func ();
28757 /* The GNU C library defines this for functions which it implements
28758     to always fail with ENOSYS.  Some functions are actually named
28759     something starting with __ and the normal name is an alias.  */
28760 #if defined __stub_$ac_func || defined __stub___$ac_func
28761 choke me
28762 #endif
28763
28764 int
28765 main ()
28766 {
28767 return $ac_func ();
28768   ;
28769   return 0;
28770 }
28771 _ACEOF
28772 rm -f conftest.$ac_objext conftest$ac_exeext
28773 if { (ac_try="$ac_link"
28774 case "(($ac_try" in
28775   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28776   *) ac_try_echo=$ac_try;;
28777 esac
28778 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28779   (eval "$ac_link") 2>conftest.er1
28780   ac_status=$?
28781   grep -v '^ *+' conftest.er1 >conftest.err
28782   rm -f conftest.er1
28783   cat conftest.err >&5
28784   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28785   (exit $ac_status); } && {
28786          test -z "$ac_c_werror_flag" ||
28787          test ! -s conftest.err
28788        } && test -s conftest$ac_exeext &&
28789        $as_test_x conftest$ac_exeext; then
28790   eval "$as_ac_var=yes"
28791 else
28792   echo "$as_me: failed program was:" >&5
28793 sed 's/^/| /' conftest.$ac_ext >&5
28794
28795         eval "$as_ac_var=no"
28796 fi
28797
28798 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
28799       conftest$ac_exeext conftest.$ac_ext
28800 fi
28801 ac_res=`eval echo '${'$as_ac_var'}'`
28802                { echo "$as_me:$LINENO: result: $ac_res" >&5
28803 echo "${ECHO_T}$ac_res" >&6; }
28804 if test `eval echo '${'$as_ac_var'}'` = yes; then
28805   cat >>confdefs.h <<_ACEOF
28806 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
28807 _ACEOF
28808
28809 fi
28810 done
28811
28812
28813
28814 { echo "$as_me:$LINENO: checking for vsnprintf" >&5
28815 echo $ECHO_N "checking for vsnprintf... $ECHO_C" >&6; }
28816 if test "${ac_cv_func_vsnprintf+set}" = set; then
28817   echo $ECHO_N "(cached) $ECHO_C" >&6
28818 else
28819   cat >conftest.$ac_ext <<_ACEOF
28820 /* confdefs.h.  */
28821 _ACEOF
28822 cat confdefs.h >>conftest.$ac_ext
28823 cat >>conftest.$ac_ext <<_ACEOF
28824 /* end confdefs.h.  */
28825 /* Define vsnprintf to an innocuous variant, in case <limits.h> declares vsnprintf.
28826    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
28827 #define vsnprintf innocuous_vsnprintf
28828
28829 /* System header to define __stub macros and hopefully few prototypes,
28830     which can conflict with char vsnprintf (); below.
28831     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
28832     <limits.h> exists even on freestanding compilers.  */
28833
28834 #ifdef __STDC__
28835 # include <limits.h>
28836 #else
28837 # include <assert.h>
28838 #endif
28839
28840 #undef vsnprintf
28841
28842 /* Override any GCC internal prototype to avoid an error.
28843    Use char because int might match the return type of a GCC
28844    builtin and then its argument prototype would still apply.  */
28845 #ifdef __cplusplus
28846 extern "C"
28847 #endif
28848 char vsnprintf ();
28849 /* The GNU C library defines this for functions which it implements
28850     to always fail with ENOSYS.  Some functions are actually named
28851     something starting with __ and the normal name is an alias.  */
28852 #if defined __stub_vsnprintf || defined __stub___vsnprintf
28853 choke me
28854 #endif
28855
28856 int
28857 main ()
28858 {
28859 return vsnprintf ();
28860   ;
28861   return 0;
28862 }
28863 _ACEOF
28864 rm -f conftest.$ac_objext conftest$ac_exeext
28865 if { (ac_try="$ac_link"
28866 case "(($ac_try" in
28867   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28868   *) ac_try_echo=$ac_try;;
28869 esac
28870 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28871   (eval "$ac_link") 2>conftest.er1
28872   ac_status=$?
28873   grep -v '^ *+' conftest.er1 >conftest.err
28874   rm -f conftest.er1
28875   cat conftest.err >&5
28876   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28877   (exit $ac_status); } && {
28878          test -z "$ac_c_werror_flag" ||
28879          test ! -s conftest.err
28880        } && test -s conftest$ac_exeext &&
28881        $as_test_x conftest$ac_exeext; then
28882   ac_cv_func_vsnprintf=yes
28883 else
28884   echo "$as_me: failed program was:" >&5
28885 sed 's/^/| /' conftest.$ac_ext >&5
28886
28887         ac_cv_func_vsnprintf=no
28888 fi
28889
28890 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
28891       conftest$ac_exeext conftest.$ac_ext
28892 fi
28893 { echo "$as_me:$LINENO: result: $ac_cv_func_vsnprintf" >&5
28894 echo "${ECHO_T}$ac_cv_func_vsnprintf" >&6; }
28895 if test $ac_cv_func_vsnprintf = yes; then
28896   gmp_vsnprintf_exists=yes
28897 else
28898   gmp_vsnprintf_exists=no
28899 fi
28900
28901 if test "$gmp_vsnprintf_exists" = no; then
28902   gmp_cv_func_vsnprintf=no
28903 else
28904   { echo "$as_me:$LINENO: checking whether vsnprintf works" >&5
28905 echo $ECHO_N "checking whether vsnprintf works... $ECHO_C" >&6; }
28906 if test "${gmp_cv_func_vsnprintf+set}" = set; then
28907   echo $ECHO_N "(cached) $ECHO_C" >&6
28908 else
28909   gmp_cv_func_vsnprintf=yes
28910    for i in 'check ("hello world");' 'int n; check ("%nhello world", &n);'; do
28911      if test "$cross_compiling" = yes; then
28912   gmp_cv_func_vsnprintf=probably; break
28913 else
28914   cat >conftest.$ac_ext <<_ACEOF
28915 /* confdefs.h.  */
28916 _ACEOF
28917 cat confdefs.h >>conftest.$ac_ext
28918 cat >>conftest.$ac_ext <<_ACEOF
28919 /* end confdefs.h.  */
28920
28921 #include <string.h>  /* for strcmp */
28922 #include <stdio.h>   /* for vsnprintf */
28923
28924 #if HAVE_STDARG
28925 #include <stdarg.h>
28926 #else
28927 #include <varargs.h>
28928 #endif
28929
28930 int
28931 #if HAVE_STDARG
28932 check (const char *fmt, ...)
28933 #else
28934 check (va_alist)
28935      va_dcl
28936 #endif
28937 {
28938   static char  buf[128];
28939   va_list  ap;
28940   int      ret;
28941
28942 #if HAVE_STDARG
28943   va_start (ap, fmt);
28944 #else
28945   char *fmt;
28946   va_start (ap);
28947   fmt = va_arg (ap, char *);
28948 #endif
28949
28950   ret = vsnprintf (buf, 4, fmt, ap);
28951
28952   if (strcmp (buf, "hel") != 0)
28953     exit (1);
28954
28955   /* allowed return values */
28956   if (ret != -1 && ret != 3 && ret != 11)
28957     exit (2);
28958
28959   return 0;
28960 }
28961
28962 int
28963 main ()
28964 {
28965 $i
28966   exit (0);
28967 }
28968
28969 _ACEOF
28970 rm -f conftest$ac_exeext
28971 if { (ac_try="$ac_link"
28972 case "(($ac_try" in
28973   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28974   *) ac_try_echo=$ac_try;;
28975 esac
28976 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28977   (eval "$ac_link") 2>&5
28978   ac_status=$?
28979   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28980   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28981   { (case "(($ac_try" in
28982   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28983   *) ac_try_echo=$ac_try;;
28984 esac
28985 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28986   (eval "$ac_try") 2>&5
28987   ac_status=$?
28988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
28989   (exit $ac_status); }; }; then
28990   :
28991 else
28992   echo "$as_me: program exited with status $ac_status" >&5
28993 echo "$as_me: failed program was:" >&5
28994 sed 's/^/| /' conftest.$ac_ext >&5
28995
28996 ( exit $ac_status )
28997 gmp_cv_func_vsnprintf=no; break
28998 fi
28999 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29000 fi
29001
29002
29003   done
29004
29005 fi
29006 { echo "$as_me:$LINENO: result: $gmp_cv_func_vsnprintf" >&5
29007 echo "${ECHO_T}$gmp_cv_func_vsnprintf" >&6; }
29008   if test "$gmp_cv_func_vsnprintf" = probably; then
29009     { echo "$as_me:$LINENO: WARNING: cannot check for properly working vsnprintf when cross compiling, will assume it's ok" >&5
29010 echo "$as_me: WARNING: cannot check for properly working vsnprintf when cross compiling, will assume it's ok" >&2;}
29011   fi
29012   if test "$gmp_cv_func_vsnprintf" != no; then
29013
29014 cat >>confdefs.h <<\_ACEOF
29015 #define HAVE_VSNPRINTF 1
29016 _ACEOF
29017
29018   fi
29019 fi
29020
29021 { echo "$as_me:$LINENO: checking whether sscanf needs writable input" >&5
29022 echo $ECHO_N "checking whether sscanf needs writable input... $ECHO_C" >&6; }
29023 if test "${gmp_cv_func_sscanf_writable_input+set}" = set; then
29024   echo $ECHO_N "(cached) $ECHO_C" >&6
29025 else
29026   case $host in
29027   *-*-hpux9 | *-*-hpux9.*)
29028      gmp_cv_func_sscanf_writable_input=yes ;;
29029   *) gmp_cv_func_sscanf_writable_input=no  ;;
29030 esac
29031
29032 fi
29033 { echo "$as_me:$LINENO: result: $gmp_cv_func_sscanf_writable_input" >&5
29034 echo "${ECHO_T}$gmp_cv_func_sscanf_writable_input" >&6; }
29035 case $gmp_cv_func_sscanf_writable_input in
29036   yes)
29037 cat >>confdefs.h <<\_ACEOF
29038 #define SSCANF_WRITABLE_INPUT 1
29039 _ACEOF
29040  ;;
29041   no)  ;;
29042   *)   { { echo "$as_me:$LINENO: error: unrecognised \$gmp_cv_func_sscanf_writable_input" >&5
29043 echo "$as_me: error: unrecognised \$gmp_cv_func_sscanf_writable_input" >&2;}
29044    { (exit 1); exit 1; }; } ;;
29045 esac
29046
29047
29048 # Reasons for checking:
29049 #   pst_processor psp_iticksperclktick - not in hpux 9
29050 #
29051 { echo "$as_me:$LINENO: checking for struct pst_processor.psp_iticksperclktick" >&5
29052 echo $ECHO_N "checking for struct pst_processor.psp_iticksperclktick... $ECHO_C" >&6; }
29053 if test "${ac_cv_member_struct_pst_processor_psp_iticksperclktick+set}" = set; then
29054   echo $ECHO_N "(cached) $ECHO_C" >&6
29055 else
29056   cat >conftest.$ac_ext <<_ACEOF
29057 /* confdefs.h.  */
29058 _ACEOF
29059 cat confdefs.h >>conftest.$ac_ext
29060 cat >>conftest.$ac_ext <<_ACEOF
29061 /* end confdefs.h.  */
29062 #include <sys/pstat.h>
29063
29064 int
29065 main ()
29066 {
29067 static struct pst_processor ac_aggr;
29068 if (ac_aggr.psp_iticksperclktick)
29069 return 0;
29070   ;
29071   return 0;
29072 }
29073 _ACEOF
29074 rm -f conftest.$ac_objext
29075 if { (ac_try="$ac_compile"
29076 case "(($ac_try" in
29077   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29078   *) ac_try_echo=$ac_try;;
29079 esac
29080 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29081   (eval "$ac_compile") 2>conftest.er1
29082   ac_status=$?
29083   grep -v '^ *+' conftest.er1 >conftest.err
29084   rm -f conftest.er1
29085   cat conftest.err >&5
29086   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29087   (exit $ac_status); } && {
29088          test -z "$ac_c_werror_flag" ||
29089          test ! -s conftest.err
29090        } && test -s conftest.$ac_objext; then
29091   ac_cv_member_struct_pst_processor_psp_iticksperclktick=yes
29092 else
29093   echo "$as_me: failed program was:" >&5
29094 sed 's/^/| /' conftest.$ac_ext >&5
29095
29096         cat >conftest.$ac_ext <<_ACEOF
29097 /* confdefs.h.  */
29098 _ACEOF
29099 cat confdefs.h >>conftest.$ac_ext
29100 cat >>conftest.$ac_ext <<_ACEOF
29101 /* end confdefs.h.  */
29102 #include <sys/pstat.h>
29103
29104 int
29105 main ()
29106 {
29107 static struct pst_processor ac_aggr;
29108 if (sizeof ac_aggr.psp_iticksperclktick)
29109 return 0;
29110   ;
29111   return 0;
29112 }
29113 _ACEOF
29114 rm -f conftest.$ac_objext
29115 if { (ac_try="$ac_compile"
29116 case "(($ac_try" in
29117   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29118   *) ac_try_echo=$ac_try;;
29119 esac
29120 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29121   (eval "$ac_compile") 2>conftest.er1
29122   ac_status=$?
29123   grep -v '^ *+' conftest.er1 >conftest.err
29124   rm -f conftest.er1
29125   cat conftest.err >&5
29126   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29127   (exit $ac_status); } && {
29128          test -z "$ac_c_werror_flag" ||
29129          test ! -s conftest.err
29130        } && test -s conftest.$ac_objext; then
29131   ac_cv_member_struct_pst_processor_psp_iticksperclktick=yes
29132 else
29133   echo "$as_me: failed program was:" >&5
29134 sed 's/^/| /' conftest.$ac_ext >&5
29135
29136         ac_cv_member_struct_pst_processor_psp_iticksperclktick=no
29137 fi
29138
29139 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29140 fi
29141
29142 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29143 fi
29144 { echo "$as_me:$LINENO: result: $ac_cv_member_struct_pst_processor_psp_iticksperclktick" >&5
29145 echo "${ECHO_T}$ac_cv_member_struct_pst_processor_psp_iticksperclktick" >&6; }
29146 if test $ac_cv_member_struct_pst_processor_psp_iticksperclktick = yes; then
29147
29148 cat >>confdefs.h <<\_ACEOF
29149 #define HAVE_PSP_ITICKSPERCLKTICK 1
29150 _ACEOF
29151
29152 fi
29153
29154
29155 # C++ tests, when required
29156 #
29157 if test $enable_cxx = yes; then
29158   ac_ext=cpp
29159 ac_cpp='$CXXCPP $CPPFLAGS'
29160 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
29161 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
29162 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
29163
29164
29165   # Reasons for testing:
29166   #   <sstream> - not in g++ 2.95.2
29167   #   std::locale - not in g++ 2.95.4
29168   #
29169
29170
29171 for ac_header in sstream
29172 do
29173 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
29174 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
29175   { echo "$as_me:$LINENO: checking for $ac_header" >&5
29176 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
29177 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
29178   echo $ECHO_N "(cached) $ECHO_C" >&6
29179 fi
29180 ac_res=`eval echo '${'$as_ac_Header'}'`
29181                { echo "$as_me:$LINENO: result: $ac_res" >&5
29182 echo "${ECHO_T}$ac_res" >&6; }
29183 else
29184   # Is the header compilable?
29185 { echo "$as_me:$LINENO: checking $ac_header usability" >&5
29186 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
29187 cat >conftest.$ac_ext <<_ACEOF
29188 /* confdefs.h.  */
29189 _ACEOF
29190 cat confdefs.h >>conftest.$ac_ext
29191 cat >>conftest.$ac_ext <<_ACEOF
29192 /* end confdefs.h.  */
29193 $ac_includes_default
29194 #include <$ac_header>
29195 _ACEOF
29196 rm -f conftest.$ac_objext
29197 if { (ac_try="$ac_compile"
29198 case "(($ac_try" in
29199   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29200   *) ac_try_echo=$ac_try;;
29201 esac
29202 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29203   (eval "$ac_compile") 2>conftest.er1
29204   ac_status=$?
29205   grep -v '^ *+' conftest.er1 >conftest.err
29206   rm -f conftest.er1
29207   cat conftest.err >&5
29208   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29209   (exit $ac_status); } && {
29210          test -z "$ac_cxx_werror_flag" ||
29211          test ! -s conftest.err
29212        } && test -s conftest.$ac_objext; then
29213   ac_header_compiler=yes
29214 else
29215   echo "$as_me: failed program was:" >&5
29216 sed 's/^/| /' conftest.$ac_ext >&5
29217
29218         ac_header_compiler=no
29219 fi
29220
29221 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29222 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
29223 echo "${ECHO_T}$ac_header_compiler" >&6; }
29224
29225 # Is the header present?
29226 { echo "$as_me:$LINENO: checking $ac_header presence" >&5
29227 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
29228 cat >conftest.$ac_ext <<_ACEOF
29229 /* confdefs.h.  */
29230 _ACEOF
29231 cat confdefs.h >>conftest.$ac_ext
29232 cat >>conftest.$ac_ext <<_ACEOF
29233 /* end confdefs.h.  */
29234 #include <$ac_header>
29235 _ACEOF
29236 if { (ac_try="$ac_cpp conftest.$ac_ext"
29237 case "(($ac_try" in
29238   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29239   *) ac_try_echo=$ac_try;;
29240 esac
29241 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29242   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
29243   ac_status=$?
29244   grep -v '^ *+' conftest.er1 >conftest.err
29245   rm -f conftest.er1
29246   cat conftest.err >&5
29247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29248   (exit $ac_status); } >/dev/null && {
29249          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
29250          test ! -s conftest.err
29251        }; then
29252   ac_header_preproc=yes
29253 else
29254   echo "$as_me: failed program was:" >&5
29255 sed 's/^/| /' conftest.$ac_ext >&5
29256
29257   ac_header_preproc=no
29258 fi
29259
29260 rm -f conftest.err conftest.$ac_ext
29261 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
29262 echo "${ECHO_T}$ac_header_preproc" >&6; }
29263
29264 # So?  What about this header?
29265 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in
29266   yes:no: )
29267     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
29268 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
29269     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
29270 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
29271     ac_header_preproc=yes
29272     ;;
29273   no:yes:* )
29274     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
29275 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
29276     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
29277 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
29278     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
29279 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
29280     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
29281 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
29282     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
29283 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
29284     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
29285 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
29286     ( cat <<\_ASBOX
29287 ## ---------------------------------- ##
29288 ## Report this to gmp-bugs@gmplib.org ##
29289 ## ---------------------------------- ##
29290 _ASBOX
29291      ) | sed "s/^/$as_me: WARNING:     /" >&2
29292     ;;
29293 esac
29294 { echo "$as_me:$LINENO: checking for $ac_header" >&5
29295 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
29296 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
29297   echo $ECHO_N "(cached) $ECHO_C" >&6
29298 else
29299   eval "$as_ac_Header=\$ac_header_preproc"
29300 fi
29301 ac_res=`eval echo '${'$as_ac_Header'}'`
29302                { echo "$as_me:$LINENO: result: $ac_res" >&5
29303 echo "${ECHO_T}$ac_res" >&6; }
29304
29305 fi
29306 if test `eval echo '${'$as_ac_Header'}'` = yes; then
29307   cat >>confdefs.h <<_ACEOF
29308 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
29309 _ACEOF
29310
29311 fi
29312
29313 done
29314
29315   { echo "$as_me:$LINENO: checking for std::locale" >&5
29316 echo $ECHO_N "checking for std::locale... $ECHO_C" >&6; }
29317 if test "${ac_cv_type_std__locale+set}" = set; then
29318   echo $ECHO_N "(cached) $ECHO_C" >&6
29319 else
29320   cat >conftest.$ac_ext <<_ACEOF
29321 /* confdefs.h.  */
29322 _ACEOF
29323 cat confdefs.h >>conftest.$ac_ext
29324 cat >>conftest.$ac_ext <<_ACEOF
29325 /* end confdefs.h.  */
29326 #include <locale>
29327
29328 typedef std::locale ac__type_new_;
29329 int
29330 main ()
29331 {
29332 if ((ac__type_new_ *) 0)
29333   return 0;
29334 if (sizeof (ac__type_new_))
29335   return 0;
29336   ;
29337   return 0;
29338 }
29339 _ACEOF
29340 rm -f conftest.$ac_objext
29341 if { (ac_try="$ac_compile"
29342 case "(($ac_try" in
29343   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29344   *) ac_try_echo=$ac_try;;
29345 esac
29346 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29347   (eval "$ac_compile") 2>conftest.er1
29348   ac_status=$?
29349   grep -v '^ *+' conftest.er1 >conftest.err
29350   rm -f conftest.er1
29351   cat conftest.err >&5
29352   echo "$as_me:$LINENO: \$? = $ac_status" >&5
29353   (exit $ac_status); } && {
29354          test -z "$ac_cxx_werror_flag" ||
29355          test ! -s conftest.err
29356        } && test -s conftest.$ac_objext; then
29357   ac_cv_type_std__locale=yes
29358 else
29359   echo "$as_me: failed program was:" >&5
29360 sed 's/^/| /' conftest.$ac_ext >&5
29361
29362         ac_cv_type_std__locale=no
29363 fi
29364
29365 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29366 fi
29367 { echo "$as_me:$LINENO: result: $ac_cv_type_std__locale" >&5
29368 echo "${ECHO_T}$ac_cv_type_std__locale" >&6; }
29369 if test $ac_cv_type_std__locale = yes; then
29370
29371 cat >>confdefs.h <<_ACEOF
29372 #define HAVE_STD__LOCALE 1
29373 _ACEOF
29374
29375
29376 fi
29377
29378
29379   ac_ext=c
29380 ac_cpp='$CPP $CPPFLAGS'
29381 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
29382 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
29383 ac_compiler_gnu=$ac_cv_c_compiler_gnu
29384
29385 fi
29386
29387
29388 # Pick the correct source files in $path and link them to mpn/.
29389 # $gmp_mpn_functions lists all functions we need.
29390 #
29391 # The rule is to find a file with the function name and a .asm, .S,
29392 # .s, or .c extension.  Certain multi-function files with special names
29393 # can provide some functions too.  (mpn/Makefile.am passes
29394 # -DOPERATION_<func> to get them to generate the right code.)
29395
29396 # Note: The following lines defining $gmp_mpn_functions_optional
29397 #       and $gmp_mpn_functions are parsed by the "macos/configure"
29398 #       Perl script. So if you change the lines in a major way
29399 #       make sure to run and examine the output from
29400 #
29401 #           % (cd macos; perl configure)
29402 #
29403 # Note: $gmp_mpn_functions must have mod_1 before pre_mod_1 so the former
29404 #       can optionally provide the latter as an extra entrypoint.  Likewise
29405 #       divrem_1 and pre_divrem_1.
29406
29407 gmp_mpn_functions_optional="umul udiv copyi copyd com_n
29408   and_n andn_n nand_n ior_n iorn_n nior_n xor_n xnor_n                  \
29409   invert_limb sqr_diagonal                                              \
29410   mul_2 mul_3 mul_4                                                     \
29411   addmul_2 addmul_3 addmul_4 addmul_5 addmul_6 addmul_7 addmul_8        \
29412   addlsh1_n sublsh1_n rsh1add_n rsh1sub_n addsub_n addaddmul_1msb0 lshiftc"
29413
29414 gmp_mpn_functions="$extra_functions                                        \
29415   add add_1 add_n sub sub_1 sub_n neg_n mul_1 addmul_1                     \
29416   submul_1 lshift rshift dive_1 diveby3 divis divrem divrem_1 divrem_2     \
29417   fib2_ui mod_1 mod_34lsub1 mode1o pre_divrem_1 pre_mod_1 dump             \
29418   mod_1_1 mod_1_2 mod_1_3 mod_1_4                                          \
29419   mul mul_fft mul_n mul_basecase sqr_basecase random random2 pow_1         \
29420   rootrem sqrtrem get_str set_str scan0 scan1 popcount hamdist cmp perfsqr \
29421   bdivmod gcd_1 gcd gcdext_1 gcdext gcd_lehmer gcd_subdiv_step             \
29422   gcdext_lehmer gcdext_subdiv_step                                         \
29423   tdiv_qr dc_divrem_n sb_divrem_mn jacbase get_d                           \
29424   matrix22_mul hgcd2 hgcd mullow_n mullow_basecase                         \
29425   toom22_mul toom33_mul toom44_mul                                         \
29426   toom32_mul toom42_mul toom62_mul toom53_mul                              \
29427   toom2_sqr toom3_sqr toom4_sqr                                            \
29428   toom_interpolate_5pts toom_interpolate_7pts invert binvert               \
29429   sb_div_qr sb_divappr_q sb_div_q dc_div_qr dc_divappr_q dc_div_q          \
29430   mu_div_qr mu_divappr_q mu_div_q                                          \
29431   sb_bdiv_q sb_bdiv_qr dc_bdiv_q dc_bdiv_qr mu_bdiv_q mu_bdiv_qr           \
29432   divexact bdiv_dbm1c redc_1 redc_2 powm powlo powm_sec subcnd_n           \
29433   $gmp_mpn_functions_optional"
29434
29435
29436
29437 # the list of all object files used by mpn/Makefile.in and the
29438 # top-level Makefile.in, respectively
29439 mpn_objects=
29440 mpn_objs_in_libgmp=
29441
29442 # links from the sources, to be removed by "make distclean"
29443 gmp_srclinks=
29444
29445
29446 # mpn_relative_top_srcdir is $top_srcdir, but for use from within the mpn
29447 # build directory.  If $srcdir is relative then we use a relative path too,
29448 # so the two trees can be moved together.
29449 case $srcdir in
29450   [\\/]* | ?:[\\/]*)  # absolute, as per autoconf
29451     mpn_relative_top_srcdir=$srcdir ;;
29452   *)                    # relative
29453     mpn_relative_top_srcdir=../$srcdir ;;
29454 esac
29455
29456
29457
29458
29459
29460
29461 # Fat binary setups.
29462 #
29463 # We proceed through each $fat_path directory, and look for $fat_function
29464 # routines there.  Those found are incorporated in the build by generating a
29465 # little mpn/<foo>.asm or mpn/<foo>.c file in the build directory, with
29466 # suitable function renaming, and adding that to $mpn_objects (the same as a
29467 # normal mpn file).
29468 #
29469 # fat.h is generated with macros to let internal calls to each $fat_function
29470 # go directly through __gmpn_cpuvec, plus macros and declarations helping to
29471 # setup that structure, on a per-directory basis ready for
29472 # mpn/<cpu>/fat/fat.c.
29473 #
29474 # fat.h includes thesholds listed in $fat_thresholds, extracted from
29475 # gmp-mparam.h in each directory.  An overall maximum for each threshold is
29476 # established, for use in making fixed size arrays of temporary space.
29477 # (Eg. MUL_TOOM3_THRESHOLD_LIMIT used by mpn/generic/mul.c.)
29478 #
29479 # It'd be possible to do some of this manually, but when there's more than a
29480 # few functions and a few directories it becomes very tedious, and very
29481 # prone to having some routine accidentally omitted.  On that basis it seems
29482 # best to automate as much as possible, even if the code to do so is a bit
29483 # ugly.
29484 #
29485
29486 if test -n "$fat_path"; then
29487   # Usually the mpn build directory is created with mpn/Makefile
29488   # instantiation, but we want to write to it sooner.
29489   mkdir mpn 2>/dev/null
29490
29491   echo "/* fat.h - setups for fat binaries." >fat.h
29492   echo "   Generated by configure - DO NOT EDIT.  */" >>fat.h
29493
29494
29495 cat >>confdefs.h <<\_ACEOF
29496 #define WANT_FAT_BINARY 1
29497 _ACEOF
29498
29499
29500 echo 'define(<WANT_FAT_BINARY>, <yes>)' >>$gmp_tmpconfigm4
29501
29502
29503   # Don't want normal copies of fat functions
29504   for tmp_fn in $fat_functions; do
29505     remove_from_list_tmp=
29506 for remove_from_list_i in $gmp_mpn_functions; do
29507   if test $remove_from_list_i = $tmp_fn; then :;
29508   else
29509      remove_from_list_tmp="$remove_from_list_tmp $remove_from_list_i"
29510   fi
29511 done
29512 gmp_mpn_functions=$remove_from_list_tmp
29513
29514     remove_from_list_tmp=
29515 for remove_from_list_i in $gmp_mpn_functions_optional; do
29516   if test $remove_from_list_i = $tmp_fn; then :;
29517   else
29518      remove_from_list_tmp="$remove_from_list_tmp $remove_from_list_i"
29519   fi
29520 done
29521 gmp_mpn_functions_optional=$remove_from_list_tmp
29522
29523   done
29524
29525   for tmp_fn in $fat_functions; do
29526     case $tmp_fn in
29527   dive_1)       tmp_fbase=divexact_1 ;;
29528   diveby3)      tmp_fbase=divexact_by3c ;;
29529   pre_divrem_1) tmp_fbase=preinv_divrem_1 ;;
29530   mode1o)       tmp_fbase=modexact_1c_odd ;;
29531   pre_mod_1)    tmp_fbase=preinv_mod_1 ;;
29532   *)            tmp_fbase=$tmp_fn ;;
29533 esac
29534
29535     echo "
29536 #ifndef OPERATION_$tmp_fn
29537 #undef  mpn_$tmp_fbase
29538 #define mpn_$tmp_fbase  (*__gmpn_cpuvec.$tmp_fbase)
29539 #endif
29540 DECL_$tmp_fbase (__MPN(${tmp_fbase}_init));" >>fat.h
29541     # encourage various macros to use fat functions
29542     cat >>confdefs.h <<_ACEOF
29543 #define HAVE_NATIVE_$tmp_fbase 1
29544 _ACEOF
29545
29546   done
29547
29548   echo "" >>fat.h
29549   echo "/* variable thresholds */" >>fat.h
29550   for tmp_tn in $fat_thresholds; do
29551     echo "#undef  $tmp_tn" >>fat.h
29552     echo "#define $tmp_tn  CPUVEC_THRESHOLD (`echo $tmp_tn | tr A-Z a-z`)" >>fat.h
29553   done
29554
29555   echo "
29556 /* Copy all fields into __gmpn_cpuvec.
29557    memcpy is not used because it might operate byte-wise (depending on its
29558    implemenation), and we need the function pointer writes to be atomic.
29559    "volatile" discourages the compiler from trying to optimize this.  */
29560 #define CPUVEC_INSTALL(vec) \\
29561   do { \\
29562     volatile struct cpuvec_t *p = &__gmpn_cpuvec; \\" >>fat.h
29563   for tmp_fn in $fat_functions; do
29564     case $tmp_fn in
29565   dive_1)       tmp_fbase=divexact_1 ;;
29566   diveby3)      tmp_fbase=divexact_by3c ;;
29567   pre_divrem_1) tmp_fbase=preinv_divrem_1 ;;
29568   mode1o)       tmp_fbase=modexact_1c_odd ;;
29569   pre_mod_1)    tmp_fbase=preinv_mod_1 ;;
29570   *)            tmp_fbase=$tmp_fn ;;
29571 esac
29572
29573     echo "    p->$tmp_fbase = vec.$tmp_fbase; \\" >>fat.h
29574   done
29575   for tmp_tn in $fat_thresholds; do
29576     tmp_field_name=`echo $tmp_tn | tr A-Z a-z`
29577     echo "    p->$tmp_field_name = vec.$tmp_field_name; \\" >>fat.h
29578   done
29579   echo "  } while (0)" >>fat.h
29580
29581   echo "
29582 /* A helper to check all fields are filled. */
29583 #define ASSERT_CPUVEC(vec) \\
29584   do { \\" >>fat.h
29585   for tmp_fn in $fat_functions; do
29586     case $tmp_fn in
29587   dive_1)       tmp_fbase=divexact_1 ;;
29588   diveby3)      tmp_fbase=divexact_by3c ;;
29589   pre_divrem_1) tmp_fbase=preinv_divrem_1 ;;
29590   mode1o)       tmp_fbase=modexact_1c_odd ;;
29591   pre_mod_1)    tmp_fbase=preinv_mod_1 ;;
29592   *)            tmp_fbase=$tmp_fn ;;
29593 esac
29594
29595     echo "    ASSERT (vec.$tmp_fbase != NULL); \\" >>fat.h
29596   done
29597   for tmp_tn in $fat_thresholds; do
29598     tmp_field_name=`echo $tmp_tn | tr A-Z a-z`
29599     echo "    ASSERT (vec.$tmp_field_name != 0); \\" >>fat.h
29600   done
29601   echo "  } while (0)" >>fat.h
29602
29603   echo "
29604 /* Call ITERATE(field) for each fat threshold field. */
29605 #define ITERATE_FAT_THRESHOLDS() \\
29606   do { \\" >>fat.h
29607   for tmp_tn in $fat_thresholds; do
29608     tmp_field_name=`echo $tmp_tn | tr A-Z a-z`
29609     echo "    ITERATE ($tmp_tn, $tmp_field_name); \\" >>fat.h
29610   done
29611   echo "  } while (0)" >>fat.h
29612
29613   for tmp_dir in $fat_path; do
29614     CPUVEC_SETUP=
29615     THRESH_ASM_SETUP=
29616     echo "" >>fat.h
29617     tmp_suffix=`echo $tmp_dir | sed -e '/\//s:^[^/]*/::' -e 's:[\\/]:_:g'`
29618
29619     # In order to keep names unique on a DOS 8.3 filesystem, use a prefix
29620     # (rather than a suffix) for the generated file names, and abbreviate.
29621     case $tmp_suffix in
29622       pentium)       tmp_prefix=p   ;;
29623       pentium_mmx)   tmp_prefix=pm  ;;
29624       p6_mmx)        tmp_prefix=p2  ;;
29625       p6_p3mmx)      tmp_prefix=p3  ;;
29626       pentium4)      tmp_prefix=p4  ;;
29627       pentium4_mmx)  tmp_prefix=p4m ;;
29628       pentium4_sse2) tmp_prefix=p4s ;;
29629       k6_mmx)        tmp_prefix=k6m ;;
29630       k6_k62mmx)     tmp_prefix=k62 ;;
29631       k7_mmx)        tmp_prefix=k7m ;;
29632       *)             tmp_prefix=$tmp_suffix ;;
29633     esac
29634
29635     # Extract desired thresholds from gmp-mparam.h file in this directory,
29636     # if prsent.
29637     tmp_mparam=$srcdir/mpn/$tmp_dir/gmp-mparam.h
29638     if test -f $tmp_mparam; then
29639       for tmp_tn in $fat_thresholds; do
29640         tmp_thresh=`sed -n "s/^#define $tmp_tn[         ]*\\([0-9][0-9]*\\).*$/\\1/p" $tmp_mparam`
29641         if test -n "$tmp_thresh"; then
29642           THRESH_ASM_SETUP="${THRESH_ASM_SETUP}define($tmp_tn,$tmp_thresh)
29643 "
29644           CPUVEC_SETUP="$CPUVEC_SETUP    decided_cpuvec.`echo $tmp_tn | tr A-Z a-z` = $tmp_thresh; \\
29645 "
29646           eval tmp_limit=\$${tmp_tn}_LIMIT
29647           if test -z "$tmp_limit"; then
29648             tmp_limit=0
29649           fi
29650           if test $tmp_thresh -gt $tmp_limit; then
29651             eval ${tmp_tn}_LIMIT=$tmp_thresh
29652           fi
29653         fi
29654       done
29655     fi
29656
29657     for tmp_fn in $fat_functions; do
29658       # functions that can be provided by multi-function files
29659 tmp_mulfunc=
29660 case $tmp_fn in
29661   add_n|sub_n)       tmp_mulfunc="aors_n"    ;;
29662   addmul_1|submul_1) tmp_mulfunc="aorsmul_1" ;;
29663   popcount|hamdist)  tmp_mulfunc="popham"    ;;
29664   and_n|andn_n|nand_n | ior_n|iorn_n|nior_n | xor_n|xnor_n)
29665                      tmp_mulfunc="logops_n"  ;;
29666   lshift|rshift)     tmp_mulfunc="lorrshift";;
29667   addlsh1_n|sublsh1_n)
29668                      tmp_mulfunc="aorslsh1_n";;
29669   rsh1add_n|rsh1sub_n)
29670                      tmp_mulfunc="rsh1aors_n";;
29671 esac
29672
29673
29674       for tmp_base in $tmp_fn $tmp_mulfunc; do
29675         for tmp_ext in asm S s c; do
29676           tmp_file=$srcdir/mpn/$tmp_dir/$tmp_base.$tmp_ext
29677           if test -f $tmp_file; then
29678
29679             mpn_objects="$mpn_objects ${tmp_prefix}_$tmp_fn.lo"
29680             mpn_objs_in_libgmp="$mpn_objs_in_libgmp mpn/${tmp_prefix}_$tmp_fn.lo"
29681
29682             case $tmp_fn in
29683   dive_1)       tmp_fbase=divexact_1 ;;
29684   diveby3)      tmp_fbase=divexact_by3c ;;
29685   pre_divrem_1) tmp_fbase=preinv_divrem_1 ;;
29686   mode1o)       tmp_fbase=modexact_1c_odd ;;
29687   pre_mod_1)    tmp_fbase=preinv_mod_1 ;;
29688   *)            tmp_fbase=$tmp_fn ;;
29689 esac
29690
29691
29692             # carry-in variant, eg. divrem_1c or modexact_1c_odd
29693             case $tmp_fbase in
29694               *_1*) tmp_fbasec=`echo $tmp_fbase | sed 's/_1/_1c/'` ;;
29695               *)    tmp_fbasec=${tmp_fbase}c ;;
29696             esac
29697
29698             # Create a little file doing an include from srcdir.  The
29699             # OPERATION and renamings aren't all needed all the time, but
29700             # they don't hurt if unused.
29701             #
29702             # FIXME: Should generate these via config.status commands.
29703             # Would need them all in one AC_CONFIG_COMMANDS though, since
29704             # that macro doesn't accept a set of separate commands generated
29705             # by shell code.
29706             #
29707             case $tmp_ext in
29708               asm)
29709                 # hide the d-n-l from autoconf's error checking
29710                 tmp_d_n_l=d""nl
29711                 echo "$tmp_d_n_l  mpn_$tmp_fbase - from $tmp_dir directory for fat binary.
29712 $tmp_d_n_l  Generated by configure - DO NOT EDIT.
29713
29714 define(OPERATION_$tmp_fn)
29715 define(__gmpn_$tmp_fbase, __gmpn_${tmp_fbase}_$tmp_suffix)
29716 define(__gmpn_$tmp_fbasec,__gmpn_${tmp_fbasec}_${tmp_suffix})
29717 define(__gmpn_preinv_${tmp_fbase},__gmpn_preinv_${tmp_fbase}_${tmp_suffix})
29718
29719 $tmp_d_n_l  For k6 and k7 gcd_1 calling their corresponding mpn_modexact_1_odd
29720 ifdef(\`__gmpn_modexact_1_odd',,
29721 \`define(__gmpn_modexact_1_odd,__gmpn_modexact_1_odd_${tmp_suffix})')
29722
29723 $THRESH_ASM_SETUP
29724 include($mpn_relative_top_srcdir/mpn/$tmp_dir/$tmp_base.asm)
29725 " >mpn/${tmp_prefix}_$tmp_fn.asm
29726                 ;;
29727               c)
29728                 echo "/* mpn_$tmp_fbase - from $tmp_dir directory for fat binary.
29729    Generated by configure - DO NOT EDIT. */
29730
29731 #define OPERATION_$tmp_fn 1
29732 #define __gmpn_$tmp_fbase           __gmpn_${tmp_fbase}_$tmp_suffix
29733 #define __gmpn_$tmp_fbasec          __gmpn_${tmp_fbasec}_${tmp_suffix}
29734 #define __gmpn_preinv_${tmp_fbase}  __gmpn_preinv_${tmp_fbase}_${tmp_suffix}
29735
29736 #include \"$mpn_relative_top_srcdir/mpn/$tmp_dir/$tmp_base.c\"
29737 " >mpn/${tmp_prefix}_$tmp_fn.c
29738                 ;;
29739             esac
29740
29741             # Prototype, and append to CPUVEC_SETUP for this directory.
29742             echo "DECL_$tmp_fbase (__gmpn_${tmp_fbase}_$tmp_suffix);" >>fat.h
29743             CPUVEC_SETUP="$CPUVEC_SETUP    decided_cpuvec.$tmp_fbase = __gmpn_${tmp_fbase}_${tmp_suffix}; \\
29744 "
29745             # Ditto for any preinv variant (preinv_divrem_1, preinv_mod_1).
29746             if grep "^PROLOGUE(mpn_preinv_$tmp_fn)" $tmp_file >/dev/null; then
29747               echo "DECL_preinv_$tmp_fbase (__gmpn_preinv_${tmp_fbase}_$tmp_suffix);" >>fat.h
29748               CPUVEC_SETUP="$CPUVEC_SETUP    decided_cpuvec.preinv_$tmp_fbase = __gmpn_preinv_${tmp_fbase}_${tmp_suffix}; \\
29749 "
29750             fi
29751           fi
29752         done
29753       done
29754     done
29755
29756     # Emit CPUVEC_SETUP for this directory
29757     echo "" >>fat.h
29758     echo "#define CPUVEC_SETUP_$tmp_suffix \\" >>fat.h
29759     echo "  do { \\" >>fat.h
29760     echo "$CPUVEC_SETUP  } while (0)" >>fat.h
29761   done
29762
29763   # Emit threshold limits
29764   echo "" >>fat.h
29765   for tmp_tn in $fat_thresholds; do
29766     eval tmp_limit=\$${tmp_tn}_LIMIT
29767     echo "#define ${tmp_tn}_LIMIT  $tmp_limit" >>fat.h
29768   done
29769 fi
29770
29771
29772 # Normal binary setups.
29773 #
29774
29775 for tmp_ext in asm S s c; do
29776   eval found_$tmp_ext=no
29777 done
29778
29779 for tmp_fn in $gmp_mpn_functions; do
29780   for tmp_ext in asm S s c; do
29781     test "$no_create" = yes || rm -f mpn/$tmp_fn.$tmp_ext
29782   done
29783
29784   # mpn_preinv_divrem_1 might have been provided by divrem_1.asm, likewise
29785   # mpn_preinv_mod_1 by mod_1.asm.
29786   case $tmp_fn in
29787   pre_divrem_1)
29788     if test "$HAVE_NATIVE_mpn_preinv_divrem_1" = yes; then continue; fi ;;
29789   pre_mod_1)
29790     if test "$HAVE_NATIVE_mpn_preinv_mod_1" = yes; then continue; fi ;;
29791   esac
29792
29793   # functions that can be provided by multi-function files
29794 tmp_mulfunc=
29795 case $tmp_fn in
29796   add_n|sub_n)       tmp_mulfunc="aors_n"    ;;
29797   addmul_1|submul_1) tmp_mulfunc="aorsmul_1" ;;
29798   popcount|hamdist)  tmp_mulfunc="popham"    ;;
29799   and_n|andn_n|nand_n | ior_n|iorn_n|nior_n | xor_n|xnor_n)
29800                      tmp_mulfunc="logops_n"  ;;
29801   lshift|rshift)     tmp_mulfunc="lorrshift";;
29802   addlsh1_n|sublsh1_n)
29803                      tmp_mulfunc="aorslsh1_n";;
29804   rsh1add_n|rsh1sub_n)
29805                      tmp_mulfunc="rsh1aors_n";;
29806 esac
29807
29808
29809   found=no
29810   for tmp_dir in $path; do
29811     for tmp_base in $tmp_fn $tmp_mulfunc; do
29812       for tmp_ext in asm S s c; do
29813         tmp_file=$srcdir/mpn/$tmp_dir/$tmp_base.$tmp_ext
29814         if test -f $tmp_file; then
29815
29816           # For a nails build, check if the file supports our nail bits.
29817           # Generic code always supports all nails.
29818           #
29819           # FIXME: When a multi-function file is selected to provide one of
29820           # the nails-neutral routines, like logops_n for and_n, the
29821           # PROLOGUE grepping will create HAVE_NATIVE_mpn_<foo> defines for
29822           # all functions in that file, even if they haven't all been
29823           # nailified.  Not sure what to do about this, it's only really a
29824           # problem for logops_n, and it's not too terrible to insist those
29825           # get nailified always.
29826           #
29827           if test $GMP_NAIL_BITS != 0 && test $tmp_dir != generic; then
29828             case $tmp_fn in
29829               and_n | ior_n | xor_n | andn_n | \
29830               copyi | copyd | \
29831               popcount | hamdist | \
29832               udiv | udiv_w_sdiv | umul | \
29833               cntlz | invert_limb)
29834                 # these operations are either unaffected by nails or defined
29835                 # to operate on full limbs
29836                 ;;
29837               *)
29838                 nails=`sed -n 's/^[     ]*NAILS_SUPPORT(\(.*\))/\1/p' $tmp_file `
29839                 for n in $nails; do
29840                   case $n in
29841                   *-*)
29842                     n_start=`echo "$n" | sed -n 's/\(.*\)-.*/\1/p'`
29843                     n_end=`echo "$n" | sed -n 's/.*-\(.*\)/\1/p'`
29844                     ;;
29845                   *)
29846                     n_start=$n
29847                     n_end=$n
29848                     ;;
29849                   esac
29850                   if test $GMP_NAIL_BITS -ge $n_start && test $GMP_NAIL_BITS -le $n_end; then
29851                     found=yes
29852                     break
29853                   fi
29854                 done
29855                 if test $found != yes; then
29856                   continue
29857                 fi
29858                 ;;
29859             esac
29860           fi
29861
29862           found=yes
29863           eval found_$tmp_ext=yes
29864
29865           if test $tmp_ext = c; then
29866             tmp_u='$U'
29867           else
29868             tmp_u=
29869           fi
29870
29871           mpn_objects="$mpn_objects $tmp_fn$tmp_u.lo"
29872           mpn_objs_in_libgmp="$mpn_objs_in_libgmp mpn/$tmp_fn$tmp_u.lo"
29873           ac_config_links="$ac_config_links mpn/$tmp_fn.$tmp_ext:mpn/$tmp_dir/$tmp_base.$tmp_ext"
29874
29875           gmp_srclinks="$gmp_srclinks mpn/$tmp_fn.$tmp_ext"
29876
29877           # Duplicate AC_DEFINEs are harmless, so it doesn't matter
29878           # that multi-function files get grepped here repeatedly.
29879           # The PROLOGUE pattern excludes the optional second parameter.
29880           gmp_ep=`
29881             sed -n 's/^[        ]*MULFUNC_PROLOGUE(\(.*\))/\1/p' $tmp_file ;
29882             sed -n 's/^[        ]*PROLOGUE(\([^,]*\).*)/\1/p' $tmp_file
29883           `
29884           for gmp_tmp in $gmp_ep; do
29885             cat >>confdefs.h <<_ACEOF
29886 #define HAVE_NATIVE_$gmp_tmp 1
29887 _ACEOF
29888
29889             eval HAVE_NATIVE_$gmp_tmp=yes
29890           done
29891
29892           case $tmp_fn in
29893           sqr_basecase) sqr_basecase_source=$tmp_file ;;
29894           esac
29895
29896           break
29897         fi
29898       done
29899       if test $found = yes; then break ; fi
29900     done
29901     if test $found = yes; then break ; fi
29902   done
29903
29904   if test $found = no; then
29905     for tmp_optional in $gmp_mpn_functions_optional; do
29906       if test $tmp_optional = $tmp_fn; then
29907         found=yes
29908       fi
29909     done
29910     if test $found = no; then
29911       { { echo "$as_me:$LINENO: error: no version of $tmp_fn found in path: $path" >&5
29912 echo "$as_me: error: no version of $tmp_fn found in path: $path" >&2;}
29913    { (exit 1); exit 1; }; }
29914     fi
29915   fi
29916 done
29917
29918 # All cycle counters are .asm files currently
29919 if test -n "$SPEED_CYCLECOUNTER_OBJ"; then
29920   found_asm=yes
29921 fi
29922
29923
29924
29925
29926
29927
29928 # Don't demand an m4 unless it's actually needed.
29929 if test $found_asm = yes; then
29930
29931 { echo "$as_me:$LINENO: checking for suitable m4" >&5
29932 echo $ECHO_N "checking for suitable m4... $ECHO_C" >&6; }
29933 if test "${gmp_cv_prog_m4+set}" = set; then
29934   echo $ECHO_N "(cached) $ECHO_C" >&6
29935 else
29936   if test -n "$M4"; then
29937   gmp_cv_prog_m4="$M4"
29938 else
29939   cat >conftest.m4 <<\EOF
29940 define(dollarhash,``$#'')ifelse(dollarhash(x),1,`define(t1,Y)',
29941 ``bad: $# not supported (SunOS /usr/bin/m4)
29942 '')ifelse(eval(89),89,`define(t2,Y)',
29943 `bad: eval() doesnt support 8 or 9 in a constant (OpenBSD 2.6 m4)
29944 ')ifelse(t1`'t2,YY,`good
29945 ')
29946 EOF
29947   echo "trying m4" >&5
29948   gmp_tmp_val=`(m4 conftest.m4) 2>&5`
29949   echo "$gmp_tmp_val" >&5
29950   if test "$gmp_tmp_val" = good; then
29951     gmp_cv_prog_m4="m4"
29952   else
29953     IFS="${IFS=         }"; ac_save_ifs="$IFS"; IFS=":"
29954     ac_dummy="$PATH:/usr/5bin"
29955     for ac_dir in $ac_dummy; do
29956       test -z "$ac_dir" && ac_dir=.
29957       echo "trying $ac_dir/m4" >&5
29958       gmp_tmp_val=`($ac_dir/m4 conftest.m4) 2>&5`
29959       echo "$gmp_tmp_val" >&5
29960       if test "$gmp_tmp_val" = good; then
29961         gmp_cv_prog_m4="$ac_dir/m4"
29962         break
29963       fi
29964     done
29965     IFS="$ac_save_ifs"
29966     if test -z "$gmp_cv_prog_m4"; then
29967       { { echo "$as_me:$LINENO: error: No usable m4 in \$PATH or /usr/5bin (see config.log for reasons)." >&5
29968 echo "$as_me: error: No usable m4 in \$PATH or /usr/5bin (see config.log for reasons)." >&2;}
29969    { (exit 1); exit 1; }; }
29970     fi
29971   fi
29972   rm -f conftest.m4
29973 fi
29974 fi
29975 { echo "$as_me:$LINENO: result: $gmp_cv_prog_m4" >&5
29976 echo "${ECHO_T}$gmp_cv_prog_m4" >&6; }
29977 M4="$gmp_cv_prog_m4"
29978
29979
29980
29981 { echo "$as_me:$LINENO: checking if m4wrap produces spurious output" >&5
29982 echo $ECHO_N "checking if m4wrap produces spurious output... $ECHO_C" >&6; }
29983 if test "${gmp_cv_m4_m4wrap_spurious+set}" = set; then
29984   echo $ECHO_N "(cached) $ECHO_C" >&6
29985 else
29986   # hide the d-n-l from autoconf's error checking
29987 tmp_d_n_l=d""nl
29988 cat >conftest.m4 <<EOF
29989 changequote({,})define(x,)m4wrap({x})$tmp_d_n_l
29990 EOF
29991 echo test input is >&5
29992 cat conftest.m4 >&5
29993 tmp_chars=`$M4 conftest.m4 | wc -c`
29994 echo produces $tmp_chars chars output >&5
29995 rm -f conftest.m4
29996 if test $tmp_chars = 0; then
29997   gmp_cv_m4_m4wrap_spurious=no
29998 else
29999   gmp_cv_m4_m4wrap_spurious=yes
30000 fi
30001
30002 fi
30003 { echo "$as_me:$LINENO: result: $gmp_cv_m4_m4wrap_spurious" >&5
30004 echo "${ECHO_T}$gmp_cv_m4_m4wrap_spurious" >&6; }
30005
30006 echo "define(<M4WRAP_SPURIOUS>,<$gmp_cv_m4_m4wrap_spurious>)" >> $gmp_tmpconfigm4
30007
30008
30009 else
30010   M4=m4-not-needed
30011 fi
30012
30013 # Only do the GMP_ASM checks if there's a .S or .asm wanting them.
30014 if test $found_asm = no && test $found_S = no; then
30015   gmp_asm_syntax_testing=no
30016 fi
30017
30018 if test "$gmp_asm_syntax_testing" != no; then
30019   { echo "$as_me:$LINENO: checking how to switch to text section" >&5
30020 echo $ECHO_N "checking how to switch to text section... $ECHO_C" >&6; }
30021 if test "${gmp_cv_asm_text+set}" = set; then
30022   echo $ECHO_N "(cached) $ECHO_C" >&6
30023 else
30024   for i in ".text" ".code" ".csect .text[PR]"; do
30025   echo "trying $i" >&5
30026   cat >conftest.s <<EOF
30027         $i
30028 EOF
30029 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30030 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30031   (eval $gmp_assemble) 2>&5
30032   ac_status=$?
30033   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30034   (exit $ac_status); }; then
30035   cat conftest.out >&5
30036   gmp_cv_asm_text=$i
30037      rm -f conftest*
30038      break
30039 else
30040   cat conftest.out >&5
30041   echo "configure: failed program was:" >&5
30042   cat conftest.s >&5
30043   :
30044 fi
30045 rm -f conftest*
30046
30047 done
30048 if test -z "$gmp_cv_asm_text"; then
30049   { { echo "$as_me:$LINENO: error: Cannot determine text section directive" >&5
30050 echo "$as_me: error: Cannot determine text section directive" >&2;}
30051    { (exit 1); exit 1; }; }
30052 fi
30053
30054 fi
30055 { echo "$as_me:$LINENO: result: $gmp_cv_asm_text" >&5
30056 echo "${ECHO_T}$gmp_cv_asm_text" >&6; }
30057 echo "define(<TEXT>, <$gmp_cv_asm_text>)" >> $gmp_tmpconfigm4
30058
30059   { echo "$as_me:$LINENO: checking how to switch to data section" >&5
30060 echo $ECHO_N "checking how to switch to data section... $ECHO_C" >&6; }
30061 if test "${gmp_cv_asm_data+set}" = set; then
30062   echo $ECHO_N "(cached) $ECHO_C" >&6
30063 else
30064   case $host in
30065   *-*-aix*) gmp_cv_asm_data=".csect .data[RW]" ;;
30066   *)        gmp_cv_asm_data=".data" ;;
30067 esac
30068
30069 fi
30070 { echo "$as_me:$LINENO: result: $gmp_cv_asm_data" >&5
30071 echo "${ECHO_T}$gmp_cv_asm_data" >&6; }
30072 echo "define(<DATA>, <$gmp_cv_asm_data>)" >> $gmp_tmpconfigm4
30073
30074
30075 { echo "$as_me:$LINENO: checking for assembler label suffix" >&5
30076 echo $ECHO_N "checking for assembler label suffix... $ECHO_C" >&6; }
30077 if test "${gmp_cv_asm_label_suffix+set}" = set; then
30078   echo $ECHO_N "(cached) $ECHO_C" >&6
30079 else
30080   gmp_cv_asm_label_suffix=unknown
30081 for i in "" ":"; do
30082   echo "trying $i" >&5
30083   cat >conftest.s <<EOF
30084         $gmp_cv_asm_text
30085 somelabel$i
30086 EOF
30087 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30088 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30089   (eval $gmp_assemble) 2>&5
30090   ac_status=$?
30091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30092   (exit $ac_status); }; then
30093   cat conftest.out >&5
30094   gmp_cv_asm_label_suffix=$i
30095      rm -f conftest*
30096      break
30097 else
30098   cat conftest.out >&5
30099   echo "configure: failed program was:" >&5
30100   cat conftest.s >&5
30101   cat conftest.out >&5
30102 fi
30103 rm -f conftest*
30104
30105 done
30106 if test "$gmp_cv_asm_label_suffix" = "unknown"; then
30107   { { echo "$as_me:$LINENO: error: Cannot determine label suffix" >&5
30108 echo "$as_me: error: Cannot determine label suffix" >&2;}
30109    { (exit 1); exit 1; }; }
30110 fi
30111
30112 fi
30113 { echo "$as_me:$LINENO: result: $gmp_cv_asm_label_suffix" >&5
30114 echo "${ECHO_T}$gmp_cv_asm_label_suffix" >&6; }
30115 echo "define(<LABEL_SUFFIX>, <$gmp_cv_asm_label_suffix>)" >> $gmp_tmpconfigm4
30116
30117
30118 { echo "$as_me:$LINENO: checking for assembler global directive" >&5
30119 echo $ECHO_N "checking for assembler global directive... $ECHO_C" >&6; }
30120 if test "${gmp_cv_asm_globl+set}" = set; then
30121   echo $ECHO_N "(cached) $ECHO_C" >&6
30122 else
30123   case $host in
30124   hppa*-*-*)     gmp_cv_asm_globl=.export ;;
30125   ia64*-*-* | itanium-*-* | itanium2-*-*)  gmp_cv_asm_globl=.global ;;
30126   *)             gmp_cv_asm_globl=.globl  ;;
30127 esac
30128
30129 fi
30130 { echo "$as_me:$LINENO: result: $gmp_cv_asm_globl" >&5
30131 echo "${ECHO_T}$gmp_cv_asm_globl" >&6; }
30132 echo "define(<GLOBL>, <$gmp_cv_asm_globl>)" >> $gmp_tmpconfigm4
30133
30134
30135 { echo "$as_me:$LINENO: checking for assembler global directive attribute" >&5
30136 echo $ECHO_N "checking for assembler global directive attribute... $ECHO_C" >&6; }
30137 if test "${gmp_cv_asm_globl_attr+set}" = set; then
30138   echo $ECHO_N "(cached) $ECHO_C" >&6
30139 else
30140   case $gmp_cv_asm_globl in
30141   .export) gmp_cv_asm_globl_attr=",entry" ;;
30142   *)       gmp_cv_asm_globl_attr="" ;;
30143 esac
30144
30145 fi
30146 { echo "$as_me:$LINENO: result: $gmp_cv_asm_globl_attr" >&5
30147 echo "${ECHO_T}$gmp_cv_asm_globl_attr" >&6; }
30148 echo "define(<GLOBL_ATTR>, <$gmp_cv_asm_globl_attr>)" >> $gmp_tmpconfigm4
30149
30150
30151 { echo "$as_me:$LINENO: checking if globals are prefixed by underscore" >&5
30152 echo $ECHO_N "checking if globals are prefixed by underscore... $ECHO_C" >&6; }
30153 if test "${gmp_cv_asm_underscore+set}" = set; then
30154   echo $ECHO_N "(cached) $ECHO_C" >&6
30155 else
30156   gmp_cv_asm_underscore="unknown"
30157 cat >conftest.c <<EOF
30158 int gurkmacka;
30159 EOF
30160 gmp_compile="$CC $CFLAGS $CPPFLAGS -c conftest.c >&5"
30161 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
30162   (eval $gmp_compile) 2>&5
30163   ac_status=$?
30164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30165   (exit $ac_status); }; then
30166   $NM conftest.$OBJEXT >conftest.out
30167   if grep _gurkmacka conftest.out >/dev/null; then
30168     gmp_cv_asm_underscore=yes
30169   elif grep gurkmacka conftest.out >/dev/null; then
30170     gmp_cv_asm_underscore=no
30171   else
30172     echo "configure: $NM doesn't have gurkmacka:" >&5
30173     cat conftest.out >&5
30174   fi
30175 else
30176   echo "configure: failed program was:" >&5
30177   cat conftest.c >&5
30178 fi
30179 rm -f conftest*
30180
30181 fi
30182 { echo "$as_me:$LINENO: result: $gmp_cv_asm_underscore" >&5
30183 echo "${ECHO_T}$gmp_cv_asm_underscore" >&6; }
30184 case $gmp_cv_asm_underscore in
30185   yes)
30186
30187 echo 'define(<GSYM_PREFIX>, <_>)' >>$gmp_tmpconfigm4
30188  ;;
30189   no)
30190
30191 echo 'define(<GSYM_PREFIX>, <>)' >>$gmp_tmpconfigm4
30192  ;;
30193   *)
30194     { echo "$as_me:$LINENO: WARNING: +----------------------------------------------------------" >&5
30195 echo "$as_me: WARNING: +----------------------------------------------------------" >&2;}
30196     { echo "$as_me:$LINENO: WARNING: | Cannot determine global symbol prefix." >&5
30197 echo "$as_me: WARNING: | Cannot determine global symbol prefix." >&2;}
30198     { echo "$as_me:$LINENO: WARNING: | $NM output doesn't contain a global data symbol." >&5
30199 echo "$as_me: WARNING: | $NM output doesn't contain a global data symbol." >&2;}
30200     { echo "$as_me:$LINENO: WARNING: | Will proceed with no underscore." >&5
30201 echo "$as_me: WARNING: | Will proceed with no underscore." >&2;}
30202     { echo "$as_me:$LINENO: WARNING: | If this is wrong then you'll get link errors referring" >&5
30203 echo "$as_me: WARNING: | If this is wrong then you'll get link errors referring" >&2;}
30204     { echo "$as_me:$LINENO: WARNING: | to ___gmpn_add_n (note three underscores)." >&5
30205 echo "$as_me: WARNING: | to ___gmpn_add_n (note three underscores)." >&2;}
30206     { echo "$as_me:$LINENO: WARNING: | In this case do a fresh build with an override," >&5
30207 echo "$as_me: WARNING: | In this case do a fresh build with an override," >&2;}
30208     { echo "$as_me:$LINENO: WARNING: |     ./configure gmp_cv_asm_underscore=yes" >&5
30209 echo "$as_me: WARNING: |     ./configure gmp_cv_asm_underscore=yes" >&2;}
30210     { echo "$as_me:$LINENO: WARNING: +----------------------------------------------------------" >&5
30211 echo "$as_me: WARNING: +----------------------------------------------------------" >&2;}
30212
30213 echo 'define(<GSYM_PREFIX>, <>)' >>$gmp_tmpconfigm4
30214
30215     ;;
30216 esac
30217
30218
30219
30220
30221
30222 { echo "$as_me:$LINENO: checking how to switch to read-only data section" >&5
30223 echo $ECHO_N "checking how to switch to read-only data section... $ECHO_C" >&6; }
30224 if test "${gmp_cv_asm_rodata+set}" = set; then
30225   echo $ECHO_N "(cached) $ECHO_C" >&6
30226 else
30227
30228 case $host in
30229 i?86*-*-* | k[5-8]*-*-* | pentium*-*-* | athlon-*-* | viac3*-*-* | geode*-*-* | x86_64-*-*)
30230   gmp_cv_asm_rodata="$gmp_cv_asm_data" ;;
30231 *)
30232   gmp_cv_asm_rodata="$gmp_cv_asm_text" ;;
30233 esac
30234
30235 cat >conftest.c <<EOF
30236 const int foo = 123;
30237 EOF
30238 echo "Test program:" >&5
30239 cat conftest.c >&5
30240 gmp_compile="$CC $CFLAGS $CPPFLAGS -S conftest.c >&5"
30241 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
30242   (eval $gmp_compile) 2>&5
30243   ac_status=$?
30244   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30245   (exit $ac_status); }; then
30246   echo "Compiler output:" >&5
30247   cat conftest.s >&5
30248   if test $gmp_cv_asm_underscore = yes; then
30249     tmp_gsym_prefix=_
30250   else
30251     tmp_gsym_prefix=
30252   fi
30253   # must see our label
30254   if grep "^${tmp_gsym_prefix}foo$gmp_cv_asm_label_suffix" conftest.s >/dev/null 2>&5; then
30255     # take the last directive before our label (hence skipping segments
30256     # getting debugging info etc)
30257     tmp_match=`sed -n "/^${tmp_gsym_prefix}foo$gmp_cv_asm_label_suffix/q
30258                         /^[.    ]*data/p
30259                         /^[.    ]*rdata/p
30260                         /^[.    ]*text/p
30261                         /^[.    ]*section/p
30262                         /^[.    ]*csect/p
30263                         /^[.    ]*CSECT/p" conftest.s | sed -n '$p'`
30264     echo "Match: $tmp_match" >&5
30265     if test -n "$tmp_match"; then
30266       gmp_cv_asm_rodata=$tmp_match
30267     fi
30268   else
30269     echo "Couldn't find label: ^${tmp_gsym_prefix}foo$gmp_cv_asm_label_suffix" >&5
30270   fi
30271 fi
30272 rm -f conftest*
30273
30274 fi
30275 { echo "$as_me:$LINENO: result: $gmp_cv_asm_rodata" >&5
30276 echo "${ECHO_T}$gmp_cv_asm_rodata" >&6; }
30277 echo "define(<RODATA>, <$gmp_cv_asm_rodata>)" >> $gmp_tmpconfigm4
30278
30279   { echo "$as_me:$LINENO: checking for assembler .type directive" >&5
30280 echo $ECHO_N "checking for assembler .type directive... $ECHO_C" >&6; }
30281 if test "${gmp_cv_asm_type+set}" = set; then
30282   echo $ECHO_N "(cached) $ECHO_C" >&6
30283 else
30284   gmp_cv_asm_type=
30285 for gmp_tmp_prefix in @ \# %; do
30286   cat >conftest.s <<EOF
30287         .type   sym,${gmp_tmp_prefix}function
30288 EOF
30289 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30290 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30291   (eval $gmp_assemble) 2>&5
30292   ac_status=$?
30293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30294   (exit $ac_status); }; then
30295   cat conftest.out >&5
30296   if grep "\.type pseudo-op used outside of \.def/\.endef ignored" conftest.out >/dev/null; then : ;
30297     else
30298       gmp_cv_asm_type=".type    \$1,${gmp_tmp_prefix}\$2"
30299       break
30300     fi
30301 else
30302   cat conftest.out >&5
30303   echo "configure: failed program was:" >&5
30304   cat conftest.s >&5
30305   :
30306 fi
30307 rm -f conftest*
30308
30309 done
30310 rm -f conftest*
30311
30312 fi
30313 { echo "$as_me:$LINENO: result: $gmp_cv_asm_type" >&5
30314 echo "${ECHO_T}$gmp_cv_asm_type" >&6; }
30315 echo "define(<TYPE>, <$gmp_cv_asm_type>)" >> $gmp_tmpconfigm4
30316
30317   { echo "$as_me:$LINENO: checking for assembler .size directive" >&5
30318 echo $ECHO_N "checking for assembler .size directive... $ECHO_C" >&6; }
30319 if test "${gmp_cv_asm_size+set}" = set; then
30320   echo $ECHO_N "(cached) $ECHO_C" >&6
30321 else
30322   gmp_cv_asm_size=
30323 cat >conftest.s <<EOF
30324         .size   sym,1
30325 EOF
30326 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30327 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30328   (eval $gmp_assemble) 2>&5
30329   ac_status=$?
30330   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30331   (exit $ac_status); }; then
30332   cat conftest.out >&5
30333   if grep "\.size pseudo-op used outside of \.def/\.endef ignored" conftest.out >/dev/null; then : ;
30334   else
30335     gmp_cv_asm_size=".size      \$1,\$2"
30336   fi
30337 else
30338   cat conftest.out >&5
30339   echo "configure: failed program was:" >&5
30340   cat conftest.s >&5
30341   :
30342 fi
30343 rm -f conftest*
30344
30345
30346 fi
30347 { echo "$as_me:$LINENO: result: $gmp_cv_asm_size" >&5
30348 echo "${ECHO_T}$gmp_cv_asm_size" >&6; }
30349 echo "define(<SIZE>, <$gmp_cv_asm_size>)" >> $gmp_tmpconfigm4
30350
30351
30352
30353
30354 { echo "$as_me:$LINENO: checking for assembler local label prefix" >&5
30355 echo $ECHO_N "checking for assembler local label prefix... $ECHO_C" >&6; }
30356 if test "${gmp_cv_asm_lsym_prefix+set}" = set; then
30357   echo $ECHO_N "(cached) $ECHO_C" >&6
30358 else
30359   gmp_tmp_pre_appears=yes
30360 for gmp_tmp_pre in L .L $L $ L$; do
30361   echo "Trying $gmp_tmp_pre" >&5
30362   cat >conftest.s <<EOF
30363         $gmp_cv_asm_text
30364 dummy${gmp_cv_asm_label_suffix}
30365 ${gmp_tmp_pre}gurkmacka${gmp_cv_asm_label_suffix}
30366 EOF
30367 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30368 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30369   (eval $gmp_assemble) 2>&5
30370   ac_status=$?
30371   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30372   (exit $ac_status); }; then
30373   cat conftest.out >&5
30374   if $NM conftest.$OBJEXT >conftest.nm 2>&5; then : ; else
30375     cat conftest.nm >&5
30376     { echo "$as_me:$LINENO: WARNING: \"$NM\" failure" >&5
30377 echo "$as_me: WARNING: \"$NM\" failure" >&2;}
30378     break
30379   fi
30380   cat conftest.nm >&5
30381   if grep gurkmacka conftest.nm >/dev/null; then : ; else
30382     # no mention of the symbol, this is good
30383     echo "$gmp_tmp_pre label doesn't appear in object file at all (good)" >&5
30384     gmp_cv_asm_lsym_prefix="$gmp_tmp_pre"
30385     gmp_tmp_pre_appears=no
30386     break
30387   fi
30388   if grep ' [a-zN] .*gurkmacka' conftest.nm >/dev/null; then
30389     # symbol mentioned as a local, use this if nothing better
30390     echo "$gmp_tmp_pre label is local but still in object file" >&5
30391     if test -z "$gmp_cv_asm_lsym_prefix"; then
30392       gmp_cv_asm_lsym_prefix="$gmp_tmp_pre"
30393     fi
30394   else
30395     echo "$gmp_tmp_pre label is something unknown" >&5
30396   fi
30397
30398 else
30399   cat conftest.out >&5
30400   echo "configure: failed program was:" >&5
30401   cat conftest.s >&5
30402   :
30403 fi
30404 rm -f conftest*
30405
30406 done
30407 rm -f conftest*
30408 if test -z "$gmp_cv_asm_lsym_prefix"; then
30409   gmp_cv_asm_lsym_prefix=L
30410   { echo "$as_me:$LINENO: WARNING: cannot determine local label, using default $gmp_cv_asm_lsym_prefix" >&5
30411 echo "$as_me: WARNING: cannot determine local label, using default $gmp_cv_asm_lsym_prefix" >&2;}
30412 fi
30413 # for development purposes, note whether we got a purely temporary local label
30414 echo "Local label appears in object files: $gmp_tmp_pre_appears" >&5
30415
30416 fi
30417 { echo "$as_me:$LINENO: result: $gmp_cv_asm_lsym_prefix" >&5
30418 echo "${ECHO_T}$gmp_cv_asm_lsym_prefix" >&6; }
30419 echo "define(<LSYM_PREFIX>, <${gmp_cv_asm_lsym_prefix}>)" >> $gmp_tmpconfigm4
30420
30421 cat >>confdefs.h <<_ACEOF
30422 #define LSYM_PREFIX "$gmp_cv_asm_lsym_prefix"
30423 _ACEOF
30424
30425
30426
30427
30428 { echo "$as_me:$LINENO: checking for assembler byte directive" >&5
30429 echo $ECHO_N "checking for assembler byte directive... $ECHO_C" >&6; }
30430 if test "${gmp_cv_asm_byte+set}" = set; then
30431   echo $ECHO_N "(cached) $ECHO_C" >&6
30432 else
30433   for i in .byte data1; do
30434   echo "trying $i" >&5
30435   cat >conftest.s <<EOF
30436         $gmp_cv_asm_data
30437         $i      0
30438
30439 EOF
30440 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30441 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30442   (eval $gmp_assemble) 2>&5
30443   ac_status=$?
30444   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30445   (exit $ac_status); }; then
30446   cat conftest.out >&5
30447   gmp_cv_asm_byte=$i
30448      rm -f conftest*
30449      break
30450 else
30451   cat conftest.out >&5
30452   echo "configure: failed program was:" >&5
30453   cat conftest.s >&5
30454   cat conftest.out >&5
30455 fi
30456 rm -f conftest*
30457
30458 done
30459 if test -z "$gmp_cv_asm_byte"; then
30460   { { echo "$as_me:$LINENO: error: Cannot determine how to emit a data byte" >&5
30461 echo "$as_me: error: Cannot determine how to emit a data byte" >&2;}
30462    { (exit 1); exit 1; }; }
30463 fi
30464
30465 fi
30466 { echo "$as_me:$LINENO: result: $gmp_cv_asm_byte" >&5
30467 echo "${ECHO_T}$gmp_cv_asm_byte" >&6; }
30468
30469
30470
30471
30472
30473
30474 { echo "$as_me:$LINENO: checking how to define a 32-bit word" >&5
30475 echo $ECHO_N "checking how to define a 32-bit word... $ECHO_C" >&6; }
30476 if test "${gmp_cv_asm_w32+set}" = set; then
30477   echo $ECHO_N "(cached) $ECHO_C" >&6
30478 else
30479   case $host in
30480   *-*-hpux*)
30481     # FIXME: HPUX puts first symbol at 0x40000000, breaking our assumption
30482     # that it's at 0x0.  We'll have to declare another symbol before the
30483     # .long/.word and look at the distance between the two symbols.  The
30484     # only problem is that the sed expression(s) barfs (on Solaris, for
30485     # example) for the symbol with value 0.  For now, HPUX uses .word.
30486     gmp_cv_asm_w32=".word"
30487     ;;
30488   *-*-*)
30489     gmp_tmp_val=
30490     for gmp_tmp_op in .long .word data4; do
30491       cat >conftest.s <<EOF
30492         $gmp_cv_asm_data
30493         $gmp_cv_asm_globl       foo
30494         $gmp_tmp_op     0
30495 foo$gmp_cv_asm_label_suffix
30496         $gmp_cv_asm_byte        0
30497 EOF
30498 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30499 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30500   (eval $gmp_assemble) 2>&5
30501   ac_status=$?
30502   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30503   (exit $ac_status); }; then
30504   cat conftest.out >&5
30505   gmp_tmp_val=`$NM conftest.$OBJEXT | grep foo | \
30506           sed -e 's;[[][0-9][]]\(.*\);\1;' -e 's;[^1-9]*\([0-9]*\).*;\1;'`
30507         if test "$gmp_tmp_val" = 4; then
30508           gmp_cv_asm_w32="$gmp_tmp_op"
30509           break
30510         fi
30511 else
30512   cat conftest.out >&5
30513   echo "configure: failed program was:" >&5
30514   cat conftest.s >&5
30515   :
30516 fi
30517 rm -f conftest*
30518
30519     done
30520     rm -f conftest*
30521     ;;
30522 esac
30523 if test -z "$gmp_cv_asm_w32"; then
30524   { { echo "$as_me:$LINENO: error: cannot determine how to define a 32-bit word" >&5
30525 echo "$as_me: error: cannot determine how to define a 32-bit word" >&2;}
30526    { (exit 1); exit 1; }; }
30527 fi
30528
30529 fi
30530 { echo "$as_me:$LINENO: result: $gmp_cv_asm_w32" >&5
30531 echo "${ECHO_T}$gmp_cv_asm_w32" >&6; }
30532 echo "define(<W32>, <$gmp_cv_asm_w32>)" >> $gmp_tmpconfigm4
30533
30534
30535
30536
30537
30538
30539 { echo "$as_me:$LINENO: checking if .align assembly directive is logarithmic" >&5
30540 echo $ECHO_N "checking if .align assembly directive is logarithmic... $ECHO_C" >&6; }
30541 if test "${gmp_cv_asm_align_log+set}" = set; then
30542   echo $ECHO_N "(cached) $ECHO_C" >&6
30543 else
30544   cat >conftest.s <<EOF
30545         $gmp_cv_asm_data
30546         .align  4
30547         $gmp_cv_asm_globl       foo
30548         $gmp_cv_asm_byte        1
30549         .align  4
30550 foo$gmp_cv_asm_label_suffix
30551         $gmp_cv_asm_byte        2
30552 EOF
30553 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30554 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30555   (eval $gmp_assemble) 2>&5
30556   ac_status=$?
30557   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30558   (exit $ac_status); }; then
30559   cat conftest.out >&5
30560   gmp_tmp_val=`$NM conftest.$OBJEXT | grep foo | \
30561      sed -e 's;[[][0-9][]]\(.*\);\1;' -e 's;[^1-9]*\([0-9]*\).*;\1;'`
30562   if test "$gmp_tmp_val" = "10" || test "$gmp_tmp_val" = "16"; then
30563     gmp_cv_asm_align_log=yes
30564   else
30565     gmp_cv_asm_align_log=no
30566   fi
30567 else
30568   cat conftest.out >&5
30569   echo "configure: failed program was:" >&5
30570   cat conftest.s >&5
30571   { { echo "$as_me:$LINENO: error: cannot assemble alignment test" >&5
30572 echo "$as_me: error: cannot assemble alignment test" >&2;}
30573    { (exit 1); exit 1; }; }
30574 fi
30575 rm -f conftest*
30576
30577 fi
30578 { echo "$as_me:$LINENO: result: $gmp_cv_asm_align_log" >&5
30579 echo "${ECHO_T}$gmp_cv_asm_align_log" >&6; }
30580
30581
30582 echo "define(<ALIGN_LOGARITHMIC>,<$gmp_cv_asm_align_log>)" >> $gmp_tmpconfigm4
30583
30584
30585
30586   case $host in
30587     hppa*-*-*)
30588       # for both pa32 and pa64
30589
30590 echo "include_mpn(\`pa32/pa-defs.m4')" >> $gmp_tmpconfigm4i
30591
30592       ;;
30593     ia64*-*-* | itanium-*-* | itanium2-*-*)
30594       { echo "$as_me:$LINENO: checking whether assembler .align padding is good" >&5
30595 echo $ECHO_N "checking whether assembler .align padding is good... $ECHO_C" >&6; }
30596 if test "${gmp_cv_asm_ia64_align_ok+set}" = set; then
30597   echo $ECHO_N "(cached) $ECHO_C" >&6
30598 else
30599   cat >conftest.awk <<\EOF
30600 BEGIN {
30601   want[0]  = "011"
30602   want[1]  = "160"
30603   want[2]  = "074"
30604   want[3]  = "040"
30605   want[4]  = "000"
30606   want[5]  = "040"
30607   want[6]  = "020"
30608   want[7]  = "221"
30609   want[8]  = "114"
30610   want[9]  = "000"
30611   want[10] = "100"
30612   want[11] = "200"
30613   want[12] = "122"
30614   want[13] = "261"
30615   want[14] = "000"
30616   want[15] = "200"
30617
30618   want[16] = "000"
30619   want[17] = "004"
30620   want[18] = "000"
30621   want[19] = "000"
30622   want[20] = "000"
30623   want[21] = "000"
30624   want[22] = "002"
30625   want[23] = "000"
30626   want[24] = "000"
30627   want[25] = "000"
30628   want[26] = "000"
30629   want[27] = "001"
30630   want[28] = "000"
30631   want[29] = "000"
30632   want[30] = "000"
30633   want[31] = "014"
30634
30635   want[32] = "011"
30636   want[33] = "270"
30637   want[34] = "140"
30638   want[35] = "062"
30639   want[36] = "000"
30640   want[37] = "040"
30641   want[38] = "240"
30642   want[39] = "331"
30643   want[40] = "160"
30644   want[41] = "000"
30645   want[42] = "100"
30646   want[43] = "240"
30647   want[44] = "343"
30648   want[45] = "371"
30649   want[46] = "000"
30650   want[47] = "200"
30651
30652   result = "yes"
30653 }
30654 {
30655   for (f = 2; f <= NF; f++)
30656     {
30657       for (i = 0; i < 47; i++)
30658         got[i] = got[i+1];
30659       got[47] = $f;
30660
30661       found = 1
30662       for (i = 0; i < 48; i++)
30663         if (got[i] != want[i])
30664           {
30665             found = 0
30666             break
30667           }
30668       if (found)
30669         {
30670           result = "no"
30671           exit
30672         }
30673     }
30674 }
30675 END {
30676   print result
30677 }
30678 EOF
30679 cat >conftest.s <<EOF
30680         .text
30681         .align  32
30682 { .mmi; add     r14 = r15, r16
30683         add     r17 = r18, r19
30684         add     r20 = r21, r22 ;; }
30685         .align  32
30686 { .mmi; add     r23 = r24, r25
30687         add     r26 = r27, r28
30688         add     r29 = r30, r31 ;; }
30689
30690 EOF
30691 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30692 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30693   (eval $gmp_assemble) 2>&5
30694   ac_status=$?
30695   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30696   (exit $ac_status); }; then
30697   cat conftest.out >&5
30698   gmp_cv_asm_ia64_align_ok=`od -b conftest.$OBJEXT | $AWK -f conftest.awk`
30699 else
30700   cat conftest.out >&5
30701   echo "configure: failed program was:" >&5
30702   cat conftest.s >&5
30703   { echo "$as_me:$LINENO: WARNING: oops, cannot compile test program" >&5
30704 echo "$as_me: WARNING: oops, cannot compile test program" >&2;}
30705    gmp_cv_asm_ia64_align_ok=yes
30706 fi
30707 rm -f conftest*
30708
30709
30710 fi
30711 { echo "$as_me:$LINENO: result: $gmp_cv_asm_ia64_align_ok" >&5
30712 echo "${ECHO_T}$gmp_cv_asm_ia64_align_ok" >&6; }
30713
30714 echo "define(<IA64_ALIGN_OK>, <\`$gmp_cv_asm_ia64_align_ok'>)" >> $gmp_tmpconfigm4
30715
30716
30717       ;;
30718     m68k-*-* | m68[0-9][0-9][0-9]-*-*)
30719
30720 { echo "$as_me:$LINENO: checking assembler instruction and register style" >&5
30721 echo $ECHO_N "checking assembler instruction and register style... $ECHO_C" >&6; }
30722 if test "${gmp_cv_asm_m68k_instruction+set}" = set; then
30723   echo $ECHO_N "(cached) $ECHO_C" >&6
30724 else
30725   for i in "addl %d0,%d1" "add.l %d0,%d1" "addl d0,d1" "add.l d0,d1"; do
30726   cat >conftest.s <<EOF
30727         $gmp_cv_asm_text
30728         $i
30729 EOF
30730 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30731 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30732   (eval $gmp_assemble) 2>&5
30733   ac_status=$?
30734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30735   (exit $ac_status); }; then
30736   cat conftest.out >&5
30737   gmp_cv_asm_m68k_instruction=$i
30738     rm -f conftest*
30739     break
30740 else
30741   cat conftest.out >&5
30742   echo "configure: failed program was:" >&5
30743   cat conftest.s >&5
30744   :
30745 fi
30746 rm -f conftest*
30747
30748 done
30749 if test -z "$gmp_cv_asm_m68k_instruction"; then
30750   { { echo "$as_me:$LINENO: error: cannot determine assembler instruction and register style" >&5
30751 echo "$as_me: error: cannot determine assembler instruction and register style" >&2;}
30752    { (exit 1); exit 1; }; }
30753 fi
30754
30755 fi
30756 { echo "$as_me:$LINENO: result: $gmp_cv_asm_m68k_instruction" >&5
30757 echo "${ECHO_T}$gmp_cv_asm_m68k_instruction" >&6; }
30758 case $gmp_cv_asm_m68k_instruction in
30759 "addl d0,d1")    want_dot_size=no;  want_register_percent=no  ;;
30760 "addl %d0,%d1")  want_dot_size=no;  want_register_percent=yes ;;
30761 "add.l d0,d1")   want_dot_size=yes; want_register_percent=no  ;;
30762 "add.l %d0,%d1") want_dot_size=yes; want_register_percent=yes ;;
30763 *) { { echo "$as_me:$LINENO: error: oops, unrecognised instruction and register style" >&5
30764 echo "$as_me: error: oops, unrecognised instruction and register style" >&2;}
30765    { (exit 1); exit 1; }; } ;;
30766 esac
30767
30768 echo "define(<WANT_REGISTER_PERCENT>, <\`$want_register_percent'>)" >> $gmp_tmpconfigm4
30769
30770
30771 echo "define(<WANT_DOT_SIZE>, <\`$want_dot_size'>)" >> $gmp_tmpconfigm4
30772
30773
30774
30775
30776 { echo "$as_me:$LINENO: checking assembler addressing style" >&5
30777 echo $ECHO_N "checking assembler addressing style... $ECHO_C" >&6; }
30778 if test "${gmp_cv_asm_m68k_addressing+set}" = set; then
30779   echo $ECHO_N "(cached) $ECHO_C" >&6
30780 else
30781   case $gmp_cv_asm_m68k_instruction in
30782 addl*)  movel=movel ;;
30783 add.l*) movel=move.l ;;
30784 *) { { echo "$as_me:$LINENO: error: oops, unrecognised gmp_cv_asm_m68k_instruction" >&5
30785 echo "$as_me: error: oops, unrecognised gmp_cv_asm_m68k_instruction" >&2;}
30786    { (exit 1); exit 1; }; } ;;
30787 esac
30788 case $gmp_cv_asm_m68k_instruction in
30789 *"%d0,%d1") dreg=%d0; areg=%a0 ;;
30790 *"d0,d1")   dreg=d0;  areg=a0  ;;
30791 *) { { echo "$as_me:$LINENO: error: oops, unrecognised gmp_cv_asm_m68k_instruction" >&5
30792 echo "$as_me: error: oops, unrecognised gmp_cv_asm_m68k_instruction" >&2;}
30793    { (exit 1); exit 1; }; } ;;
30794 esac
30795 cat >conftest.s <<EOF
30796         $gmp_cv_asm_text
30797         $movel  $dreg, $areg@-
30798 EOF
30799 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30800 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30801   (eval $gmp_assemble) 2>&5
30802   ac_status=$?
30803   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30804   (exit $ac_status); }; then
30805   cat conftest.out >&5
30806   gmp_cv_asm_m68k_addressing=mit
30807 else
30808   cat conftest.out >&5
30809   echo "configure: failed program was:" >&5
30810   cat conftest.s >&5
30811   cat >conftest.s <<EOF
30812         $gmp_cv_asm_text
30813         $movel  $dreg, -($areg)
30814 EOF
30815 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30816 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30817   (eval $gmp_assemble) 2>&5
30818   ac_status=$?
30819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30820   (exit $ac_status); }; then
30821   cat conftest.out >&5
30822   gmp_cv_asm_m68k_addressing=motorola
30823 else
30824   cat conftest.out >&5
30825   echo "configure: failed program was:" >&5
30826   cat conftest.s >&5
30827   { { echo "$as_me:$LINENO: error: cannot determine assembler addressing style" >&5
30828 echo "$as_me: error: cannot determine assembler addressing style" >&2;}
30829    { (exit 1); exit 1; }; }
30830 fi
30831 rm -f conftest*
30832
30833 fi
30834 rm -f conftest*
30835
30836
30837 fi
30838 { echo "$as_me:$LINENO: result: $gmp_cv_asm_m68k_addressing" >&5
30839 echo "${ECHO_T}$gmp_cv_asm_m68k_addressing" >&6; }
30840
30841 echo "define(<WANT_ADDRESSING>, <\`$gmp_cv_asm_m68k_addressing'>)" >> $gmp_tmpconfigm4
30842
30843
30844
30845 { echo "$as_me:$LINENO: checking assembler shortest branches" >&5
30846 echo $ECHO_N "checking assembler shortest branches... $ECHO_C" >&6; }
30847 if test "${gmp_cv_asm_m68k_branches+set}" = set; then
30848   echo $ECHO_N "(cached) $ECHO_C" >&6
30849 else
30850   for i in jra jbra bra; do
30851   cat >conftest.s <<EOF
30852         $gmp_cv_asm_text
30853 foo$gmp_cv_asm_label_suffix
30854         $i      foo
30855 EOF
30856 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30857 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30858   (eval $gmp_assemble) 2>&5
30859   ac_status=$?
30860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30861   (exit $ac_status); }; then
30862   cat conftest.out >&5
30863   gmp_cv_asm_m68k_branches=$i
30864   rm -f conftest*
30865   break
30866 else
30867   cat conftest.out >&5
30868   echo "configure: failed program was:" >&5
30869   cat conftest.s >&5
30870   :
30871 fi
30872 rm -f conftest*
30873
30874 done
30875 if test -z "$gmp_cv_asm_m68k_branches"; then
30876   { { echo "$as_me:$LINENO: error: cannot determine assembler branching style" >&5
30877 echo "$as_me: error: cannot determine assembler branching style" >&2;}
30878    { (exit 1); exit 1; }; }
30879 fi
30880
30881 fi
30882 { echo "$as_me:$LINENO: result: $gmp_cv_asm_m68k_branches" >&5
30883 echo "${ECHO_T}$gmp_cv_asm_m68k_branches" >&6; }
30884
30885 echo "define(<WANT_BRANCHES>, <\`$gmp_cv_asm_m68k_branches'>)" >> $gmp_tmpconfigm4
30886
30887
30888       ;;
30889     powerpc*-*-* | power[3-9]-*-*)
30890
30891 { echo "$as_me:$LINENO: checking whether compiler output is PIC by default" >&5
30892 echo $ECHO_N "checking whether compiler output is PIC by default... $ECHO_C" >&6; }
30893 if test "${gmp_cv_asm_powerpc_pic+set}" = set; then
30894   echo $ECHO_N "(cached) $ECHO_C" >&6
30895 else
30896   gmp_cv_asm_powerpc_pic=yes
30897 cat >conftest.c <<EOF
30898 int foo;
30899 int *bar() { return &foo; }
30900 EOF
30901 echo "Test program:" >&5
30902 cat conftest.c >&5
30903 gmp_compile="$CC $CFLAGS $CPPFLAGS -S conftest.c >&5"
30904 if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
30905   (eval $gmp_compile) 2>&5
30906   ac_status=$?
30907   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30908   (exit $ac_status); }; then
30909   echo "Compiler output:" >&5
30910   cat conftest.s >&5
30911   if grep 'foo@ha' conftest.s >/dev/null 2>&5; then
30912     gmp_cv_asm_powerpc_pic=no
30913   fi
30914   if grep 'ha16(_foo)' conftest.s >/dev/null 2>&5; then
30915     gmp_cv_asm_powerpc_pic=no
30916   fi
30917 fi
30918 rm -f conftest*
30919
30920 fi
30921 { echo "$as_me:$LINENO: result: $gmp_cv_asm_powerpc_pic" >&5
30922 echo "${ECHO_T}$gmp_cv_asm_powerpc_pic" >&6; }
30923
30924 echo "define(<PIC_ALWAYS>,<$gmp_cv_asm_powerpc_pic>)" >> $gmp_tmpconfigm4
30925
30926
30927
30928 { echo "$as_me:$LINENO: checking if the assembler needs r on registers" >&5
30929 echo $ECHO_N "checking if the assembler needs r on registers... $ECHO_C" >&6; }
30930 if test "${gmp_cv_asm_powerpc_r_registers+set}" = set; then
30931   echo $ECHO_N "(cached) $ECHO_C" >&6
30932 else
30933   cat >conftest.s <<EOF
30934         $gmp_cv_asm_text
30935         mtctr   6
30936 EOF
30937 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30938 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30939   (eval $gmp_assemble) 2>&5
30940   ac_status=$?
30941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30942   (exit $ac_status); }; then
30943   cat conftest.out >&5
30944   gmp_cv_asm_powerpc_r_registers=no
30945 else
30946   cat conftest.out >&5
30947   echo "configure: failed program was:" >&5
30948   cat conftest.s >&5
30949   cat >conftest.s <<EOF
30950         $gmp_cv_asm_text
30951         mtctr   r6
30952 EOF
30953 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
30954 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
30955   (eval $gmp_assemble) 2>&5
30956   ac_status=$?
30957   echo "$as_me:$LINENO: \$? = $ac_status" >&5
30958   (exit $ac_status); }; then
30959   cat conftest.out >&5
30960   gmp_cv_asm_powerpc_r_registers=yes
30961 else
30962   cat conftest.out >&5
30963   echo "configure: failed program was:" >&5
30964   cat conftest.s >&5
30965   { { echo "$as_me:$LINENO: error: neither \"mtctr 6\" nor \"mtctr r6\" works" >&5
30966 echo "$as_me: error: neither \"mtctr 6\" nor \"mtctr r6\" works" >&2;}
30967    { (exit 1); exit 1; }; }
30968 fi
30969 rm -f conftest*
30970
30971 fi
30972 rm -f conftest*
30973
30974 fi
30975 { echo "$as_me:$LINENO: result: $gmp_cv_asm_powerpc_r_registers" >&5
30976 echo "${ECHO_T}$gmp_cv_asm_powerpc_r_registers" >&6; }
30977
30978
30979 echo "define(<WANT_R_REGISTERS>,<$gmp_cv_asm_powerpc_r_registers>)" >> $gmp_tmpconfigm4
30980
30981
30982
30983 echo "include_mpn(\`powerpc32/powerpc-defs.m4')" >> $gmp_tmpconfigm4i
30984
30985       case $host in
30986         *-*-aix*)
30987           case $ABI in
30988             64 | aix64)
30989 echo "include_mpn(\`powerpc64/aix.m4')" >> $gmp_tmpconfigm4i
30990  ;;
30991             *)
30992 echo "include_mpn(\`powerpc32/aix.m4')" >> $gmp_tmpconfigm4i
30993  ;;
30994           esac
30995           ;;
30996         *-*-linux* | *-*-*bsd*)
30997           case $ABI in
30998             mode64)
30999 echo "include_mpn(\`powerpc64/elf.m4')" >> $gmp_tmpconfigm4i
31000  ;;
31001             mode32 | 32)
31002 echo "include_mpn(\`powerpc32/elf.m4')" >> $gmp_tmpconfigm4i
31003  ;;
31004           esac
31005           ;;
31006         *-*-darwin*)
31007           case $ABI in
31008             mode64)
31009 echo "include_mpn(\`powerpc64/darwin.m4')" >> $gmp_tmpconfigm4i
31010  ;;
31011             mode32 | 32)
31012 echo "include_mpn(\`powerpc32/darwin.m4')" >> $gmp_tmpconfigm4i
31013  ;;
31014           esac
31015           ;;
31016         *)
31017           # Assume unrecognized operating system is the powerpc eABI
31018
31019 echo "include_mpn(\`powerpc32/eabi.m4')" >> $gmp_tmpconfigm4i
31020
31021           ;;
31022       esac
31023       ;;
31024     power*-*-aix*)
31025
31026 echo "include_mpn(\`powerpc32/aix.m4')" >> $gmp_tmpconfigm4i
31027
31028       ;;
31029     sparcv9*-*-* | ultrasparc*-*-* | sparc64-*-*)
31030       case $ABI in
31031         64)
31032
31033 { echo "$as_me:$LINENO: checking if the assembler accepts \".register\"" >&5
31034 echo $ECHO_N "checking if the assembler accepts \".register\"... $ECHO_C" >&6; }
31035 if test "${gmp_cv_asm_sparc_register+set}" = set; then
31036   echo $ECHO_N "(cached) $ECHO_C" >&6
31037 else
31038   cat >conftest.s <<EOF
31039         $gmp_cv_asm_text
31040         .register       %g2,#scratch
31041
31042 EOF
31043 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
31044 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
31045   (eval $gmp_assemble) 2>&5
31046   ac_status=$?
31047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31048   (exit $ac_status); }; then
31049   cat conftest.out >&5
31050   gmp_cv_asm_sparc_register=yes
31051 else
31052   cat conftest.out >&5
31053   echo "configure: failed program was:" >&5
31054   cat conftest.s >&5
31055   gmp_cv_asm_sparc_register=no
31056 fi
31057 rm -f conftest*
31058
31059 fi
31060 { echo "$as_me:$LINENO: result: $gmp_cv_asm_sparc_register" >&5
31061 echo "${ECHO_T}$gmp_cv_asm_sparc_register" >&6; }
31062
31063
31064 echo "define(<HAVE_REGISTER>,<$gmp_cv_asm_sparc_register>)" >> $gmp_tmpconfigm4
31065
31066
31067           ;;
31068       esac
31069       ;;
31070     i?86*-*-* | k[5-8]*-*-* | pentium*-*-* | athlon-*-* | viac3*-*-* | geode*-*-* | athlon64-*-* | atom-*-* | core2-*-* | x86_64-*-*)
31071
31072 { echo "$as_me:$LINENO: checking if the .align directive accepts an 0x90 fill in .text" >&5
31073 echo $ECHO_N "checking if the .align directive accepts an 0x90 fill in .text... $ECHO_C" >&6; }
31074 if test "${gmp_cv_asm_align_fill_0x90+set}" = set; then
31075   echo $ECHO_N "(cached) $ECHO_C" >&6
31076 else
31077   cat >conftest.s <<EOF
31078         $gmp_cv_asm_text
31079         .align  4, 0x90
31080         .byte   0
31081         .align  4, 0x90
31082 EOF
31083 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
31084 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
31085   (eval $gmp_assemble) 2>&5
31086   ac_status=$?
31087   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31088   (exit $ac_status); }; then
31089   cat conftest.out >&5
31090   if grep "Warning: Fill parameter ignored for executable section" conftest.out >/dev/null; then
31091   echo "Supressing this warning by omitting 0x90" 1>&5
31092   gmp_cv_asm_align_fill_0x90=no
31093 else
31094   gmp_cv_asm_align_fill_0x90=yes
31095 fi
31096 else
31097   cat conftest.out >&5
31098   echo "configure: failed program was:" >&5
31099   cat conftest.s >&5
31100   gmp_cv_asm_align_fill_0x90=no
31101 fi
31102 rm -f conftest*
31103
31104 fi
31105 { echo "$as_me:$LINENO: result: $gmp_cv_asm_align_fill_0x90" >&5
31106 echo "${ECHO_T}$gmp_cv_asm_align_fill_0x90" >&6; }
31107
31108
31109 echo "define(<ALIGN_FILL_0x90>,<$gmp_cv_asm_align_fill_0x90>)" >> $gmp_tmpconfigm4
31110
31111
31112       case $ABI in
31113         32)
31114
31115 echo "include_mpn(\`x86/x86-defs.m4')" >> $gmp_tmpconfigm4i
31116
31117           cat >>confdefs.h <<\_ACEOF
31118 #define HAVE_HOST_CPU_FAMILY_x86 1
31119 _ACEOF
31120
31121
31122
31123
31124
31125
31126 { echo "$as_me:$LINENO: checking for assembler COFF type directives" >&5
31127 echo $ECHO_N "checking for assembler COFF type directives... $ECHO_C" >&6; }
31128 if test "${gmp_cv_asm_x86_coff_type+set}" = set; then
31129   echo $ECHO_N "(cached) $ECHO_C" >&6
31130 else
31131   cat >conftest.s <<EOF
31132         $gmp_cv_asm_text
31133         $gmp_cv_asm_globl ${tmp_gsym_prefix}foo$gmp_cv_asm_globl_attr
31134         .def    ${tmp_gsym_prefix}foo
31135         .scl    2
31136         .type   32
31137         .endef
31138 ${tmp_gsym_prefix}foo$gmp_cv_asm_label_suffix
31139
31140 EOF
31141 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
31142 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
31143   (eval $gmp_assemble) 2>&5
31144   ac_status=$?
31145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31146   (exit $ac_status); }; then
31147   cat conftest.out >&5
31148   gmp_cv_asm_x86_coff_type=yes
31149 else
31150   cat conftest.out >&5
31151   echo "configure: failed program was:" >&5
31152   cat conftest.s >&5
31153   gmp_cv_asm_x86_coff_type=no
31154 fi
31155 rm -f conftest*
31156
31157
31158 fi
31159 { echo "$as_me:$LINENO: result: $gmp_cv_asm_x86_coff_type" >&5
31160 echo "${ECHO_T}$gmp_cv_asm_x86_coff_type" >&6; }
31161 echo "define(<HAVE_COFF_TYPE>, <$gmp_cv_asm_x86_coff_type>)" >> $gmp_tmpconfigm4
31162
31163
31164
31165
31166
31167
31168
31169 { echo "$as_me:$LINENO: checking if _GLOBAL_OFFSET_TABLE_ is prefixed by underscore" >&5
31170 echo $ECHO_N "checking if _GLOBAL_OFFSET_TABLE_ is prefixed by underscore... $ECHO_C" >&6; }
31171 if test "${gmp_cv_asm_x86_got_underscore+set}" = set; then
31172   echo $ECHO_N "(cached) $ECHO_C" >&6
31173 else
31174   gmp_cv_asm_x86_got_underscore="not applicable"
31175 if test $gmp_cv_asm_underscore = yes; then
31176   tmp_gsym_prefix=_
31177 else
31178   tmp_gsym_prefix=
31179 fi
31180 for tmp_underscore in "" "_"; do
31181   cat >conftest.s <<EOF
31182         $gmp_cv_asm_text
31183         $gmp_cv_asm_globl ${tmp_gsym_prefix}main$gmp_cv_asm_globl_attr
31184 ${tmp_gsym_prefix}main$gmp_cv_asm_label_suffix
31185         addl    $ ${tmp_underscore}_GLOBAL_OFFSET_TABLE_, %ebx
31186 EOF
31187   gmp_compile="$CCAS $CFLAGS $CPPFLAGS $lt_prog_compiler_pic conftest.s >&5 && $CC $CFLAGS $CPPFLAGS $lt_prog_compiler_pic conftest.$OBJEXT >&5"
31188   if { (eval echo "$as_me:$LINENO: \"$gmp_compile\"") >&5
31189   (eval $gmp_compile) 2>&5
31190   ac_status=$?
31191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31192   (exit $ac_status); }; then
31193     if test "$tmp_underscore" = "_"; then
31194       gmp_cv_asm_x86_got_underscore=yes
31195     else
31196       gmp_cv_asm_x86_got_underscore=no
31197     fi
31198     break
31199   fi
31200 done
31201 rm -f conftest* a.out b.out a.exe a_out.exe
31202
31203 fi
31204 { echo "$as_me:$LINENO: result: $gmp_cv_asm_x86_got_underscore" >&5
31205 echo "${ECHO_T}$gmp_cv_asm_x86_got_underscore" >&6; }
31206 if test "$gmp_cv_asm_x86_got_underscore" = "yes"; then
31207
31208 echo 'define(<GOT_GSYM_PREFIX>, <_>)' >>$gmp_tmpconfigm4
31209
31210 else
31211
31212 echo 'define(<GOT_GSYM_PREFIX>, <>)' >>$gmp_tmpconfigm4
31213
31214 fi
31215
31216
31217 { echo "$as_me:$LINENO: checking if the assembler takes cl with shldl" >&5
31218 echo $ECHO_N "checking if the assembler takes cl with shldl... $ECHO_C" >&6; }
31219 if test "${gmp_cv_asm_x86_shldl_cl+set}" = set; then
31220   echo $ECHO_N "(cached) $ECHO_C" >&6
31221 else
31222   cat >conftest.s <<EOF
31223         $gmp_cv_asm_text
31224         shldl   %cl, %eax, %ebx
31225 EOF
31226 gmp_assemble="$CCAS $CFLAGS $CPPFLAGS conftest.s >conftest.out 2>&1"
31227 if { (eval echo "$as_me:$LINENO: \"$gmp_assemble\"") >&5
31228   (eval $gmp_assemble) 2>&5
31229   ac_status=$?
31230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31231   (exit $ac_status); }; then
31232   cat conftest.out >&5
31233   gmp_cv_asm_x86_shldl_cl=yes
31234 else
31235   cat conftest.out >&5
31236   echo "configure: failed program was:" >&5
31237   cat conftest.s >&5
31238   gmp_cv_asm_x86_shldl_cl=no
31239 fi
31240 rm -f conftest*
31241
31242
31243 fi
31244 { echo "$as_me:$LINENO: result: $gmp_cv_asm_x86_shldl_cl" >&5
31245 echo "${ECHO_T}$gmp_cv_asm_x86_shldl_cl" >&6; }
31246 if test "$gmp_cv_asm_x86_shldl_cl" = "yes"; then
31247
31248 echo 'define(<WANT_SHLDL_CL>, <1>)' >>$gmp_tmpconfigm4
31249
31250 else
31251
31252 echo 'define(<WANT_SHLDL_CL>, <0>)' >>$gmp_tmpconfigm4
31253
31254 fi
31255
31256           case $enable_profiling in
31257             prof | gprof)
31258
31259 { echo "$as_me:$LINENO: checking how to call x86 mcount" >&5
31260 echo $ECHO_N "checking how to call x86 mcount... $ECHO_C" >&6; }
31261 cat >conftest.c <<EOF
31262 foo(){bar();}
31263 EOF
31264
31265 if test "$enable_static" = yes; then
31266   gmp_asmout_compile="$CC $CFLAGS $CPPFLAGS -S conftest.c 1>&5"
31267   if { (eval echo "$as_me:$LINENO: \"$gmp_asmout_compile\"") >&5
31268   (eval $gmp_asmout_compile) 2>&5
31269   ac_status=$?
31270   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31271   (exit $ac_status); }; then
31272     if grep '\.data' conftest.s >/dev/null; then
31273       mcount_nonpic_reg=`sed -n '/esp/!s/.*movl.*,\(%[a-z]*\).*$/\1/p' conftest.s`
31274     else
31275       mcount_nonpic_reg=
31276     fi
31277     mcount_nonpic_call=`grep 'call.*mcount' conftest.s`
31278     if test -z "$mcount_nonpic_call"; then
31279       { { echo "$as_me:$LINENO: error: Cannot find mcount call for non-PIC" >&5
31280 echo "$as_me: error: Cannot find mcount call for non-PIC" >&2;}
31281    { (exit 1); exit 1; }; }
31282     fi
31283   else
31284     { { echo "$as_me:$LINENO: error: Cannot compile test program for non-PIC" >&5
31285 echo "$as_me: error: Cannot compile test program for non-PIC" >&2;}
31286    { (exit 1); exit 1; }; }
31287   fi
31288 fi
31289
31290 if test "$enable_shared" = yes; then
31291   gmp_asmout_compile="$CC $CFLAGS $CPPFLAGS $lt_prog_compiler_pic -S conftest.c 1>&5"
31292   if { (eval echo "$as_me:$LINENO: \"$gmp_asmout_compile\"") >&5
31293   (eval $gmp_asmout_compile) 2>&5
31294   ac_status=$?
31295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31296   (exit $ac_status); }; then
31297     if grep '\.data' conftest.s >/dev/null; then
31298       case $lt_prog_compiler_pic in
31299         *-DDLL_EXPORT*)
31300           # Windows DLLs have non-PIC style mcount
31301           mcount_pic_reg=`sed -n '/esp/!s/.*movl.*,\(%[a-z]*\).*$/\1/p' conftest.s`
31302           ;;
31303         *)
31304           mcount_pic_reg=`sed -n 's/.*GOTOFF.*,\(%[a-z]*\).*$/\1/p' conftest.s`
31305           ;;
31306       esac
31307     else
31308       mcount_pic_reg=
31309     fi
31310     mcount_pic_call=`grep 'call.*mcount' conftest.s`
31311     if test -z "$mcount_pic_call"; then
31312       { { echo "$as_me:$LINENO: error: Cannot find mcount call for PIC" >&5
31313 echo "$as_me: error: Cannot find mcount call for PIC" >&2;}
31314    { (exit 1); exit 1; }; }
31315     fi
31316   else
31317     { { echo "$as_me:$LINENO: error: Cannot compile test program for PIC" >&5
31318 echo "$as_me: error: Cannot compile test program for PIC" >&2;}
31319    { (exit 1); exit 1; }; }
31320   fi
31321 fi
31322
31323
31324 echo "define(<MCOUNT_NONPIC_REG>, <\`$mcount_nonpic_reg'>)" >> $gmp_tmpconfigm4
31325
31326
31327 echo "define(<MCOUNT_NONPIC_CALL>,<\`$mcount_nonpic_call'>)" >> $gmp_tmpconfigm4
31328
31329
31330 echo "define(<MCOUNT_PIC_REG>,    <\`$mcount_pic_reg'>)" >> $gmp_tmpconfigm4
31331
31332
31333 echo "define(<MCOUNT_PIC_CALL>,   <\`$mcount_pic_call'>)" >> $gmp_tmpconfigm4
31334
31335
31336 rm -f conftest.*
31337 { echo "$as_me:$LINENO: result: determined" >&5
31338 echo "${ECHO_T}determined" >&6; }
31339  ;;
31340           esac
31341           case $host in
31342             *-*-darwin*)
31343
31344 echo "include_mpn(\`x86/darwin.m4')" >> $gmp_tmpconfigm4i
31345  ;;
31346           esac
31347           ;;
31348         64)
31349
31350 echo "include_mpn(\`x86_64/x86_64-defs.m4')" >> $gmp_tmpconfigm4i
31351
31352           case $host in
31353             *-*-darwin*)
31354
31355 echo "include_mpn(\`x86_64/darwin.m4')" >> $gmp_tmpconfigm4i
31356  ;;
31357           esac
31358           ;;
31359       esac
31360       ;;
31361   esac
31362 fi
31363
31364 # For --enable-minithres, prepend "minithres" to path so that its special
31365 # gmp-mparam.h will be used.
31366 if test $enable_minithres = yes; then
31367   path="minithres $path"
31368 fi
31369
31370 # Create link for gmp-mparam.h.
31371 gmp_mparam_source=
31372 for gmp_mparam_dir in $path; do
31373   test "$no_create" = yes || rm -f gmp-mparam.h
31374   tmp_file=$srcdir/mpn/$gmp_mparam_dir/gmp-mparam.h
31375   if test -f $tmp_file; then
31376     ac_config_links="$ac_config_links gmp-mparam.h:mpn/$gmp_mparam_dir/gmp-mparam.h"
31377
31378     gmp_srclinks="$gmp_srclinks gmp-mparam.h"
31379     gmp_mparam_source=$tmp_file
31380     break
31381   fi
31382 done
31383 if test -z "$gmp_mparam_source"; then
31384   { { echo "$as_me:$LINENO: error: no version of gmp-mparam.h found in path: $path" >&5
31385 echo "$as_me: error: no version of gmp-mparam.h found in path: $path" >&2;}
31386    { (exit 1); exit 1; }; }
31387 fi
31388
31389 # For a helpful message from tune/tuneup.c
31390 gmp_mparam_suggest=$gmp_mparam_source
31391 if test "$gmp_mparam_dir" = generic; then
31392   for i in $path; do break; done
31393   if test "$i" != generic; then
31394     gmp_mparam_suggest="new file $srcdir/mpn/$i/gmp-mparam.h"
31395   fi
31396 fi
31397
31398 cat >>confdefs.h <<_ACEOF
31399 #define GMP_MPARAM_H_SUGGEST "$gmp_mparam_source"
31400 _ACEOF
31401
31402
31403
31404 # Copy any SQR_KARATSUBA_THRESHOLD from gmp-mparam.h to config.m4.
31405 # Some versions of sqr_basecase.asm use this.
31406 # Fat binaries do this on a per-file basis, so skip in that case.
31407 #
31408 if test -z "$fat_path"; then
31409   tmp_gmp_karatsuba_sqr_threshold=`sed -n 's/^#define SQR_KARATSUBA_THRESHOLD[  ]*\([0-9][0-9]*\).*$/\1/p' $gmp_mparam_source`
31410   if test -n "$tmp_gmp_karatsuba_sqr_threshold"; then
31411
31412 echo "define(<SQR_KARATSUBA_THRESHOLD>,<$tmp_gmp_karatsuba_sqr_threshold>)" >> $gmp_tmpconfigm4
31413
31414   fi
31415 fi
31416
31417
31418 # Sizes of some types, needed at preprocessing time.
31419 #
31420 # FIXME: The assumption that BITS_PER_MP_LIMB is 8*sizeof(mp_limb_t) might
31421 # be slightly rash, but it's true everwhere we know of and ought to be true
31422 # of any sensible system.  In a generic C build, grepping LONG_BIT out of
31423 # <limits.h> might be an alternative, for maximum portability.
31424 #
31425 { echo "$as_me:$LINENO: checking for unsigned short" >&5
31426 echo $ECHO_N "checking for unsigned short... $ECHO_C" >&6; }
31427 if test "${ac_cv_type_unsigned_short+set}" = set; then
31428   echo $ECHO_N "(cached) $ECHO_C" >&6
31429 else
31430   cat >conftest.$ac_ext <<_ACEOF
31431 /* confdefs.h.  */
31432 _ACEOF
31433 cat confdefs.h >>conftest.$ac_ext
31434 cat >>conftest.$ac_ext <<_ACEOF
31435 /* end confdefs.h.  */
31436 $ac_includes_default
31437 typedef unsigned short ac__type_new_;
31438 int
31439 main ()
31440 {
31441 if ((ac__type_new_ *) 0)
31442   return 0;
31443 if (sizeof (ac__type_new_))
31444   return 0;
31445   ;
31446   return 0;
31447 }
31448 _ACEOF
31449 rm -f conftest.$ac_objext
31450 if { (ac_try="$ac_compile"
31451 case "(($ac_try" in
31452   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31453   *) ac_try_echo=$ac_try;;
31454 esac
31455 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31456   (eval "$ac_compile") 2>conftest.er1
31457   ac_status=$?
31458   grep -v '^ *+' conftest.er1 >conftest.err
31459   rm -f conftest.er1
31460   cat conftest.err >&5
31461   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31462   (exit $ac_status); } && {
31463          test -z "$ac_c_werror_flag" ||
31464          test ! -s conftest.err
31465        } && test -s conftest.$ac_objext; then
31466   ac_cv_type_unsigned_short=yes
31467 else
31468   echo "$as_me: failed program was:" >&5
31469 sed 's/^/| /' conftest.$ac_ext >&5
31470
31471         ac_cv_type_unsigned_short=no
31472 fi
31473
31474 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31475 fi
31476 { echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_short" >&5
31477 echo "${ECHO_T}$ac_cv_type_unsigned_short" >&6; }
31478
31479 # The cast to long int works around a bug in the HP C Compiler
31480 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
31481 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
31482 # This bug is HP SR number 8606223364.
31483 { echo "$as_me:$LINENO: checking size of unsigned short" >&5
31484 echo $ECHO_N "checking size of unsigned short... $ECHO_C" >&6; }
31485 if test "${ac_cv_sizeof_unsigned_short+set}" = set; then
31486   echo $ECHO_N "(cached) $ECHO_C" >&6
31487 else
31488   if test "$cross_compiling" = yes; then
31489   # Depending upon the size, compute the lo and hi bounds.
31490 cat >conftest.$ac_ext <<_ACEOF
31491 /* confdefs.h.  */
31492 _ACEOF
31493 cat confdefs.h >>conftest.$ac_ext
31494 cat >>conftest.$ac_ext <<_ACEOF
31495 /* end confdefs.h.  */
31496 $ac_includes_default
31497    typedef unsigned short ac__type_sizeof_;
31498 int
31499 main ()
31500 {
31501 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
31502 test_array [0] = 0
31503
31504   ;
31505   return 0;
31506 }
31507 _ACEOF
31508 rm -f conftest.$ac_objext
31509 if { (ac_try="$ac_compile"
31510 case "(($ac_try" in
31511   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31512   *) ac_try_echo=$ac_try;;
31513 esac
31514 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31515   (eval "$ac_compile") 2>conftest.er1
31516   ac_status=$?
31517   grep -v '^ *+' conftest.er1 >conftest.err
31518   rm -f conftest.er1
31519   cat conftest.err >&5
31520   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31521   (exit $ac_status); } && {
31522          test -z "$ac_c_werror_flag" ||
31523          test ! -s conftest.err
31524        } && test -s conftest.$ac_objext; then
31525   ac_lo=0 ac_mid=0
31526   while :; do
31527     cat >conftest.$ac_ext <<_ACEOF
31528 /* confdefs.h.  */
31529 _ACEOF
31530 cat confdefs.h >>conftest.$ac_ext
31531 cat >>conftest.$ac_ext <<_ACEOF
31532 /* end confdefs.h.  */
31533 $ac_includes_default
31534    typedef unsigned short ac__type_sizeof_;
31535 int
31536 main ()
31537 {
31538 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
31539 test_array [0] = 0
31540
31541   ;
31542   return 0;
31543 }
31544 _ACEOF
31545 rm -f conftest.$ac_objext
31546 if { (ac_try="$ac_compile"
31547 case "(($ac_try" in
31548   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31549   *) ac_try_echo=$ac_try;;
31550 esac
31551 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31552   (eval "$ac_compile") 2>conftest.er1
31553   ac_status=$?
31554   grep -v '^ *+' conftest.er1 >conftest.err
31555   rm -f conftest.er1
31556   cat conftest.err >&5
31557   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31558   (exit $ac_status); } && {
31559          test -z "$ac_c_werror_flag" ||
31560          test ! -s conftest.err
31561        } && test -s conftest.$ac_objext; then
31562   ac_hi=$ac_mid; break
31563 else
31564   echo "$as_me: failed program was:" >&5
31565 sed 's/^/| /' conftest.$ac_ext >&5
31566
31567         ac_lo=`expr $ac_mid + 1`
31568                         if test $ac_lo -le $ac_mid; then
31569                           ac_lo= ac_hi=
31570                           break
31571                         fi
31572                         ac_mid=`expr 2 '*' $ac_mid + 1`
31573 fi
31574
31575 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31576   done
31577 else
31578   echo "$as_me: failed program was:" >&5
31579 sed 's/^/| /' conftest.$ac_ext >&5
31580
31581         cat >conftest.$ac_ext <<_ACEOF
31582 /* confdefs.h.  */
31583 _ACEOF
31584 cat confdefs.h >>conftest.$ac_ext
31585 cat >>conftest.$ac_ext <<_ACEOF
31586 /* end confdefs.h.  */
31587 $ac_includes_default
31588    typedef unsigned short ac__type_sizeof_;
31589 int
31590 main ()
31591 {
31592 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
31593 test_array [0] = 0
31594
31595   ;
31596   return 0;
31597 }
31598 _ACEOF
31599 rm -f conftest.$ac_objext
31600 if { (ac_try="$ac_compile"
31601 case "(($ac_try" in
31602   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31603   *) ac_try_echo=$ac_try;;
31604 esac
31605 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31606   (eval "$ac_compile") 2>conftest.er1
31607   ac_status=$?
31608   grep -v '^ *+' conftest.er1 >conftest.err
31609   rm -f conftest.er1
31610   cat conftest.err >&5
31611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31612   (exit $ac_status); } && {
31613          test -z "$ac_c_werror_flag" ||
31614          test ! -s conftest.err
31615        } && test -s conftest.$ac_objext; then
31616   ac_hi=-1 ac_mid=-1
31617   while :; do
31618     cat >conftest.$ac_ext <<_ACEOF
31619 /* confdefs.h.  */
31620 _ACEOF
31621 cat confdefs.h >>conftest.$ac_ext
31622 cat >>conftest.$ac_ext <<_ACEOF
31623 /* end confdefs.h.  */
31624 $ac_includes_default
31625    typedef unsigned short ac__type_sizeof_;
31626 int
31627 main ()
31628 {
31629 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
31630 test_array [0] = 0
31631
31632   ;
31633   return 0;
31634 }
31635 _ACEOF
31636 rm -f conftest.$ac_objext
31637 if { (ac_try="$ac_compile"
31638 case "(($ac_try" in
31639   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31640   *) ac_try_echo=$ac_try;;
31641 esac
31642 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31643   (eval "$ac_compile") 2>conftest.er1
31644   ac_status=$?
31645   grep -v '^ *+' conftest.er1 >conftest.err
31646   rm -f conftest.er1
31647   cat conftest.err >&5
31648   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31649   (exit $ac_status); } && {
31650          test -z "$ac_c_werror_flag" ||
31651          test ! -s conftest.err
31652        } && test -s conftest.$ac_objext; then
31653   ac_lo=$ac_mid; break
31654 else
31655   echo "$as_me: failed program was:" >&5
31656 sed 's/^/| /' conftest.$ac_ext >&5
31657
31658         ac_hi=`expr '(' $ac_mid ')' - 1`
31659                         if test $ac_mid -le $ac_hi; then
31660                           ac_lo= ac_hi=
31661                           break
31662                         fi
31663                         ac_mid=`expr 2 '*' $ac_mid`
31664 fi
31665
31666 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31667   done
31668 else
31669   echo "$as_me: failed program was:" >&5
31670 sed 's/^/| /' conftest.$ac_ext >&5
31671
31672         ac_lo= ac_hi=
31673 fi
31674
31675 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31676 fi
31677
31678 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31679 # Binary search between lo and hi bounds.
31680 while test "x$ac_lo" != "x$ac_hi"; do
31681   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
31682   cat >conftest.$ac_ext <<_ACEOF
31683 /* confdefs.h.  */
31684 _ACEOF
31685 cat confdefs.h >>conftest.$ac_ext
31686 cat >>conftest.$ac_ext <<_ACEOF
31687 /* end confdefs.h.  */
31688 $ac_includes_default
31689    typedef unsigned short ac__type_sizeof_;
31690 int
31691 main ()
31692 {
31693 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
31694 test_array [0] = 0
31695
31696   ;
31697   return 0;
31698 }
31699 _ACEOF
31700 rm -f conftest.$ac_objext
31701 if { (ac_try="$ac_compile"
31702 case "(($ac_try" in
31703   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31704   *) ac_try_echo=$ac_try;;
31705 esac
31706 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31707   (eval "$ac_compile") 2>conftest.er1
31708   ac_status=$?
31709   grep -v '^ *+' conftest.er1 >conftest.err
31710   rm -f conftest.er1
31711   cat conftest.err >&5
31712   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31713   (exit $ac_status); } && {
31714          test -z "$ac_c_werror_flag" ||
31715          test ! -s conftest.err
31716        } && test -s conftest.$ac_objext; then
31717   ac_hi=$ac_mid
31718 else
31719   echo "$as_me: failed program was:" >&5
31720 sed 's/^/| /' conftest.$ac_ext >&5
31721
31722         ac_lo=`expr '(' $ac_mid ')' + 1`
31723 fi
31724
31725 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31726 done
31727 case $ac_lo in
31728 ?*) ac_cv_sizeof_unsigned_short=$ac_lo;;
31729 '') if test "$ac_cv_type_unsigned_short" = yes; then
31730      { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned short)
31731 See \`config.log' for more details." >&5
31732 echo "$as_me: error: cannot compute sizeof (unsigned short)
31733 See \`config.log' for more details." >&2;}
31734    { (exit 77); exit 77; }; }
31735    else
31736      ac_cv_sizeof_unsigned_short=0
31737    fi ;;
31738 esac
31739 else
31740   cat >conftest.$ac_ext <<_ACEOF
31741 /* confdefs.h.  */
31742 _ACEOF
31743 cat confdefs.h >>conftest.$ac_ext
31744 cat >>conftest.$ac_ext <<_ACEOF
31745 /* end confdefs.h.  */
31746 $ac_includes_default
31747    typedef unsigned short ac__type_sizeof_;
31748 static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
31749 static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
31750 #include <stdio.h>
31751 #include <stdlib.h>
31752 int
31753 main ()
31754 {
31755
31756   FILE *f = fopen ("conftest.val", "w");
31757   if (! f)
31758     return 1;
31759   if (((long int) (sizeof (ac__type_sizeof_))) < 0)
31760     {
31761       long int i = longval ();
31762       if (i != ((long int) (sizeof (ac__type_sizeof_))))
31763         return 1;
31764       fprintf (f, "%ld\n", i);
31765     }
31766   else
31767     {
31768       unsigned long int i = ulongval ();
31769       if (i != ((long int) (sizeof (ac__type_sizeof_))))
31770         return 1;
31771       fprintf (f, "%lu\n", i);
31772     }
31773   return ferror (f) || fclose (f) != 0;
31774
31775   ;
31776   return 0;
31777 }
31778 _ACEOF
31779 rm -f conftest$ac_exeext
31780 if { (ac_try="$ac_link"
31781 case "(($ac_try" in
31782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31783   *) ac_try_echo=$ac_try;;
31784 esac
31785 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31786   (eval "$ac_link") 2>&5
31787   ac_status=$?
31788   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31789   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
31790   { (case "(($ac_try" in
31791   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31792   *) ac_try_echo=$ac_try;;
31793 esac
31794 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31795   (eval "$ac_try") 2>&5
31796   ac_status=$?
31797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31798   (exit $ac_status); }; }; then
31799   ac_cv_sizeof_unsigned_short=`cat conftest.val`
31800 else
31801   echo "$as_me: program exited with status $ac_status" >&5
31802 echo "$as_me: failed program was:" >&5
31803 sed 's/^/| /' conftest.$ac_ext >&5
31804
31805 ( exit $ac_status )
31806 if test "$ac_cv_type_unsigned_short" = yes; then
31807      { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned short)
31808 See \`config.log' for more details." >&5
31809 echo "$as_me: error: cannot compute sizeof (unsigned short)
31810 See \`config.log' for more details." >&2;}
31811    { (exit 77); exit 77; }; }
31812    else
31813      ac_cv_sizeof_unsigned_short=0
31814    fi
31815 fi
31816 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
31817 fi
31818 rm -f conftest.val
31819 fi
31820 { echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_short" >&5
31821 echo "${ECHO_T}$ac_cv_sizeof_unsigned_short" >&6; }
31822
31823
31824
31825 cat >>confdefs.h <<_ACEOF
31826 #define SIZEOF_UNSIGNED_SHORT $ac_cv_sizeof_unsigned_short
31827 _ACEOF
31828
31829
31830 { echo "$as_me:$LINENO: checking for unsigned" >&5
31831 echo $ECHO_N "checking for unsigned... $ECHO_C" >&6; }
31832 if test "${ac_cv_type_unsigned+set}" = set; then
31833   echo $ECHO_N "(cached) $ECHO_C" >&6
31834 else
31835   cat >conftest.$ac_ext <<_ACEOF
31836 /* confdefs.h.  */
31837 _ACEOF
31838 cat confdefs.h >>conftest.$ac_ext
31839 cat >>conftest.$ac_ext <<_ACEOF
31840 /* end confdefs.h.  */
31841 $ac_includes_default
31842 typedef unsigned ac__type_new_;
31843 int
31844 main ()
31845 {
31846 if ((ac__type_new_ *) 0)
31847   return 0;
31848 if (sizeof (ac__type_new_))
31849   return 0;
31850   ;
31851   return 0;
31852 }
31853 _ACEOF
31854 rm -f conftest.$ac_objext
31855 if { (ac_try="$ac_compile"
31856 case "(($ac_try" in
31857   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31858   *) ac_try_echo=$ac_try;;
31859 esac
31860 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31861   (eval "$ac_compile") 2>conftest.er1
31862   ac_status=$?
31863   grep -v '^ *+' conftest.er1 >conftest.err
31864   rm -f conftest.er1
31865   cat conftest.err >&5
31866   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31867   (exit $ac_status); } && {
31868          test -z "$ac_c_werror_flag" ||
31869          test ! -s conftest.err
31870        } && test -s conftest.$ac_objext; then
31871   ac_cv_type_unsigned=yes
31872 else
31873   echo "$as_me: failed program was:" >&5
31874 sed 's/^/| /' conftest.$ac_ext >&5
31875
31876         ac_cv_type_unsigned=no
31877 fi
31878
31879 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31880 fi
31881 { echo "$as_me:$LINENO: result: $ac_cv_type_unsigned" >&5
31882 echo "${ECHO_T}$ac_cv_type_unsigned" >&6; }
31883
31884 # The cast to long int works around a bug in the HP C Compiler
31885 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
31886 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
31887 # This bug is HP SR number 8606223364.
31888 { echo "$as_me:$LINENO: checking size of unsigned" >&5
31889 echo $ECHO_N "checking size of unsigned... $ECHO_C" >&6; }
31890 if test "${ac_cv_sizeof_unsigned+set}" = set; then
31891   echo $ECHO_N "(cached) $ECHO_C" >&6
31892 else
31893   if test "$cross_compiling" = yes; then
31894   # Depending upon the size, compute the lo and hi bounds.
31895 cat >conftest.$ac_ext <<_ACEOF
31896 /* confdefs.h.  */
31897 _ACEOF
31898 cat confdefs.h >>conftest.$ac_ext
31899 cat >>conftest.$ac_ext <<_ACEOF
31900 /* end confdefs.h.  */
31901 $ac_includes_default
31902    typedef unsigned ac__type_sizeof_;
31903 int
31904 main ()
31905 {
31906 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
31907 test_array [0] = 0
31908
31909   ;
31910   return 0;
31911 }
31912 _ACEOF
31913 rm -f conftest.$ac_objext
31914 if { (ac_try="$ac_compile"
31915 case "(($ac_try" in
31916   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31917   *) ac_try_echo=$ac_try;;
31918 esac
31919 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31920   (eval "$ac_compile") 2>conftest.er1
31921   ac_status=$?
31922   grep -v '^ *+' conftest.er1 >conftest.err
31923   rm -f conftest.er1
31924   cat conftest.err >&5
31925   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31926   (exit $ac_status); } && {
31927          test -z "$ac_c_werror_flag" ||
31928          test ! -s conftest.err
31929        } && test -s conftest.$ac_objext; then
31930   ac_lo=0 ac_mid=0
31931   while :; do
31932     cat >conftest.$ac_ext <<_ACEOF
31933 /* confdefs.h.  */
31934 _ACEOF
31935 cat confdefs.h >>conftest.$ac_ext
31936 cat >>conftest.$ac_ext <<_ACEOF
31937 /* end confdefs.h.  */
31938 $ac_includes_default
31939    typedef unsigned ac__type_sizeof_;
31940 int
31941 main ()
31942 {
31943 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
31944 test_array [0] = 0
31945
31946   ;
31947   return 0;
31948 }
31949 _ACEOF
31950 rm -f conftest.$ac_objext
31951 if { (ac_try="$ac_compile"
31952 case "(($ac_try" in
31953   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31954   *) ac_try_echo=$ac_try;;
31955 esac
31956 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31957   (eval "$ac_compile") 2>conftest.er1
31958   ac_status=$?
31959   grep -v '^ *+' conftest.er1 >conftest.err
31960   rm -f conftest.er1
31961   cat conftest.err >&5
31962   echo "$as_me:$LINENO: \$? = $ac_status" >&5
31963   (exit $ac_status); } && {
31964          test -z "$ac_c_werror_flag" ||
31965          test ! -s conftest.err
31966        } && test -s conftest.$ac_objext; then
31967   ac_hi=$ac_mid; break
31968 else
31969   echo "$as_me: failed program was:" >&5
31970 sed 's/^/| /' conftest.$ac_ext >&5
31971
31972         ac_lo=`expr $ac_mid + 1`
31973                         if test $ac_lo -le $ac_mid; then
31974                           ac_lo= ac_hi=
31975                           break
31976                         fi
31977                         ac_mid=`expr 2 '*' $ac_mid + 1`
31978 fi
31979
31980 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31981   done
31982 else
31983   echo "$as_me: failed program was:" >&5
31984 sed 's/^/| /' conftest.$ac_ext >&5
31985
31986         cat >conftest.$ac_ext <<_ACEOF
31987 /* confdefs.h.  */
31988 _ACEOF
31989 cat confdefs.h >>conftest.$ac_ext
31990 cat >>conftest.$ac_ext <<_ACEOF
31991 /* end confdefs.h.  */
31992 $ac_includes_default
31993    typedef unsigned ac__type_sizeof_;
31994 int
31995 main ()
31996 {
31997 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
31998 test_array [0] = 0
31999
32000   ;
32001   return 0;
32002 }
32003 _ACEOF
32004 rm -f conftest.$ac_objext
32005 if { (ac_try="$ac_compile"
32006 case "(($ac_try" in
32007   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32008   *) ac_try_echo=$ac_try;;
32009 esac
32010 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32011   (eval "$ac_compile") 2>conftest.er1
32012   ac_status=$?
32013   grep -v '^ *+' conftest.er1 >conftest.err
32014   rm -f conftest.er1
32015   cat conftest.err >&5
32016   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32017   (exit $ac_status); } && {
32018          test -z "$ac_c_werror_flag" ||
32019          test ! -s conftest.err
32020        } && test -s conftest.$ac_objext; then
32021   ac_hi=-1 ac_mid=-1
32022   while :; do
32023     cat >conftest.$ac_ext <<_ACEOF
32024 /* confdefs.h.  */
32025 _ACEOF
32026 cat confdefs.h >>conftest.$ac_ext
32027 cat >>conftest.$ac_ext <<_ACEOF
32028 /* end confdefs.h.  */
32029 $ac_includes_default
32030    typedef unsigned ac__type_sizeof_;
32031 int
32032 main ()
32033 {
32034 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
32035 test_array [0] = 0
32036
32037   ;
32038   return 0;
32039 }
32040 _ACEOF
32041 rm -f conftest.$ac_objext
32042 if { (ac_try="$ac_compile"
32043 case "(($ac_try" in
32044   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32045   *) ac_try_echo=$ac_try;;
32046 esac
32047 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32048   (eval "$ac_compile") 2>conftest.er1
32049   ac_status=$?
32050   grep -v '^ *+' conftest.er1 >conftest.err
32051   rm -f conftest.er1
32052   cat conftest.err >&5
32053   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32054   (exit $ac_status); } && {
32055          test -z "$ac_c_werror_flag" ||
32056          test ! -s conftest.err
32057        } && test -s conftest.$ac_objext; then
32058   ac_lo=$ac_mid; break
32059 else
32060   echo "$as_me: failed program was:" >&5
32061 sed 's/^/| /' conftest.$ac_ext >&5
32062
32063         ac_hi=`expr '(' $ac_mid ')' - 1`
32064                         if test $ac_mid -le $ac_hi; then
32065                           ac_lo= ac_hi=
32066                           break
32067                         fi
32068                         ac_mid=`expr 2 '*' $ac_mid`
32069 fi
32070
32071 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32072   done
32073 else
32074   echo "$as_me: failed program was:" >&5
32075 sed 's/^/| /' conftest.$ac_ext >&5
32076
32077         ac_lo= ac_hi=
32078 fi
32079
32080 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32081 fi
32082
32083 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32084 # Binary search between lo and hi bounds.
32085 while test "x$ac_lo" != "x$ac_hi"; do
32086   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
32087   cat >conftest.$ac_ext <<_ACEOF
32088 /* confdefs.h.  */
32089 _ACEOF
32090 cat confdefs.h >>conftest.$ac_ext
32091 cat >>conftest.$ac_ext <<_ACEOF
32092 /* end confdefs.h.  */
32093 $ac_includes_default
32094    typedef unsigned ac__type_sizeof_;
32095 int
32096 main ()
32097 {
32098 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
32099 test_array [0] = 0
32100
32101   ;
32102   return 0;
32103 }
32104 _ACEOF
32105 rm -f conftest.$ac_objext
32106 if { (ac_try="$ac_compile"
32107 case "(($ac_try" in
32108   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32109   *) ac_try_echo=$ac_try;;
32110 esac
32111 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32112   (eval "$ac_compile") 2>conftest.er1
32113   ac_status=$?
32114   grep -v '^ *+' conftest.er1 >conftest.err
32115   rm -f conftest.er1
32116   cat conftest.err >&5
32117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32118   (exit $ac_status); } && {
32119          test -z "$ac_c_werror_flag" ||
32120          test ! -s conftest.err
32121        } && test -s conftest.$ac_objext; then
32122   ac_hi=$ac_mid
32123 else
32124   echo "$as_me: failed program was:" >&5
32125 sed 's/^/| /' conftest.$ac_ext >&5
32126
32127         ac_lo=`expr '(' $ac_mid ')' + 1`
32128 fi
32129
32130 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32131 done
32132 case $ac_lo in
32133 ?*) ac_cv_sizeof_unsigned=$ac_lo;;
32134 '') if test "$ac_cv_type_unsigned" = yes; then
32135      { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned)
32136 See \`config.log' for more details." >&5
32137 echo "$as_me: error: cannot compute sizeof (unsigned)
32138 See \`config.log' for more details." >&2;}
32139    { (exit 77); exit 77; }; }
32140    else
32141      ac_cv_sizeof_unsigned=0
32142    fi ;;
32143 esac
32144 else
32145   cat >conftest.$ac_ext <<_ACEOF
32146 /* confdefs.h.  */
32147 _ACEOF
32148 cat confdefs.h >>conftest.$ac_ext
32149 cat >>conftest.$ac_ext <<_ACEOF
32150 /* end confdefs.h.  */
32151 $ac_includes_default
32152    typedef unsigned ac__type_sizeof_;
32153 static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
32154 static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
32155 #include <stdio.h>
32156 #include <stdlib.h>
32157 int
32158 main ()
32159 {
32160
32161   FILE *f = fopen ("conftest.val", "w");
32162   if (! f)
32163     return 1;
32164   if (((long int) (sizeof (ac__type_sizeof_))) < 0)
32165     {
32166       long int i = longval ();
32167       if (i != ((long int) (sizeof (ac__type_sizeof_))))
32168         return 1;
32169       fprintf (f, "%ld\n", i);
32170     }
32171   else
32172     {
32173       unsigned long int i = ulongval ();
32174       if (i != ((long int) (sizeof (ac__type_sizeof_))))
32175         return 1;
32176       fprintf (f, "%lu\n", i);
32177     }
32178   return ferror (f) || fclose (f) != 0;
32179
32180   ;
32181   return 0;
32182 }
32183 _ACEOF
32184 rm -f conftest$ac_exeext
32185 if { (ac_try="$ac_link"
32186 case "(($ac_try" in
32187   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32188   *) ac_try_echo=$ac_try;;
32189 esac
32190 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32191   (eval "$ac_link") 2>&5
32192   ac_status=$?
32193   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32194   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
32195   { (case "(($ac_try" in
32196   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32197   *) ac_try_echo=$ac_try;;
32198 esac
32199 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32200   (eval "$ac_try") 2>&5
32201   ac_status=$?
32202   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32203   (exit $ac_status); }; }; then
32204   ac_cv_sizeof_unsigned=`cat conftest.val`
32205 else
32206   echo "$as_me: program exited with status $ac_status" >&5
32207 echo "$as_me: failed program was:" >&5
32208 sed 's/^/| /' conftest.$ac_ext >&5
32209
32210 ( exit $ac_status )
32211 if test "$ac_cv_type_unsigned" = yes; then
32212      { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned)
32213 See \`config.log' for more details." >&5
32214 echo "$as_me: error: cannot compute sizeof (unsigned)
32215 See \`config.log' for more details." >&2;}
32216    { (exit 77); exit 77; }; }
32217    else
32218      ac_cv_sizeof_unsigned=0
32219    fi
32220 fi
32221 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
32222 fi
32223 rm -f conftest.val
32224 fi
32225 { echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned" >&5
32226 echo "${ECHO_T}$ac_cv_sizeof_unsigned" >&6; }
32227
32228
32229
32230 cat >>confdefs.h <<_ACEOF
32231 #define SIZEOF_UNSIGNED $ac_cv_sizeof_unsigned
32232 _ACEOF
32233
32234
32235 { echo "$as_me:$LINENO: checking for unsigned long" >&5
32236 echo $ECHO_N "checking for unsigned long... $ECHO_C" >&6; }
32237 if test "${ac_cv_type_unsigned_long+set}" = set; then
32238   echo $ECHO_N "(cached) $ECHO_C" >&6
32239 else
32240   cat >conftest.$ac_ext <<_ACEOF
32241 /* confdefs.h.  */
32242 _ACEOF
32243 cat confdefs.h >>conftest.$ac_ext
32244 cat >>conftest.$ac_ext <<_ACEOF
32245 /* end confdefs.h.  */
32246 $ac_includes_default
32247 typedef unsigned long ac__type_new_;
32248 int
32249 main ()
32250 {
32251 if ((ac__type_new_ *) 0)
32252   return 0;
32253 if (sizeof (ac__type_new_))
32254   return 0;
32255   ;
32256   return 0;
32257 }
32258 _ACEOF
32259 rm -f conftest.$ac_objext
32260 if { (ac_try="$ac_compile"
32261 case "(($ac_try" in
32262   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32263   *) ac_try_echo=$ac_try;;
32264 esac
32265 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32266   (eval "$ac_compile") 2>conftest.er1
32267   ac_status=$?
32268   grep -v '^ *+' conftest.er1 >conftest.err
32269   rm -f conftest.er1
32270   cat conftest.err >&5
32271   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32272   (exit $ac_status); } && {
32273          test -z "$ac_c_werror_flag" ||
32274          test ! -s conftest.err
32275        } && test -s conftest.$ac_objext; then
32276   ac_cv_type_unsigned_long=yes
32277 else
32278   echo "$as_me: failed program was:" >&5
32279 sed 's/^/| /' conftest.$ac_ext >&5
32280
32281         ac_cv_type_unsigned_long=no
32282 fi
32283
32284 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32285 fi
32286 { echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long" >&5
32287 echo "${ECHO_T}$ac_cv_type_unsigned_long" >&6; }
32288
32289 # The cast to long int works around a bug in the HP C Compiler
32290 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
32291 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
32292 # This bug is HP SR number 8606223364.
32293 { echo "$as_me:$LINENO: checking size of unsigned long" >&5
32294 echo $ECHO_N "checking size of unsigned long... $ECHO_C" >&6; }
32295 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then
32296   echo $ECHO_N "(cached) $ECHO_C" >&6
32297 else
32298   if test "$cross_compiling" = yes; then
32299   # Depending upon the size, compute the lo and hi bounds.
32300 cat >conftest.$ac_ext <<_ACEOF
32301 /* confdefs.h.  */
32302 _ACEOF
32303 cat confdefs.h >>conftest.$ac_ext
32304 cat >>conftest.$ac_ext <<_ACEOF
32305 /* end confdefs.h.  */
32306 $ac_includes_default
32307    typedef unsigned long ac__type_sizeof_;
32308 int
32309 main ()
32310 {
32311 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
32312 test_array [0] = 0
32313
32314   ;
32315   return 0;
32316 }
32317 _ACEOF
32318 rm -f conftest.$ac_objext
32319 if { (ac_try="$ac_compile"
32320 case "(($ac_try" in
32321   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32322   *) ac_try_echo=$ac_try;;
32323 esac
32324 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32325   (eval "$ac_compile") 2>conftest.er1
32326   ac_status=$?
32327   grep -v '^ *+' conftest.er1 >conftest.err
32328   rm -f conftest.er1
32329   cat conftest.err >&5
32330   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32331   (exit $ac_status); } && {
32332          test -z "$ac_c_werror_flag" ||
32333          test ! -s conftest.err
32334        } && test -s conftest.$ac_objext; then
32335   ac_lo=0 ac_mid=0
32336   while :; do
32337     cat >conftest.$ac_ext <<_ACEOF
32338 /* confdefs.h.  */
32339 _ACEOF
32340 cat confdefs.h >>conftest.$ac_ext
32341 cat >>conftest.$ac_ext <<_ACEOF
32342 /* end confdefs.h.  */
32343 $ac_includes_default
32344    typedef unsigned long ac__type_sizeof_;
32345 int
32346 main ()
32347 {
32348 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
32349 test_array [0] = 0
32350
32351   ;
32352   return 0;
32353 }
32354 _ACEOF
32355 rm -f conftest.$ac_objext
32356 if { (ac_try="$ac_compile"
32357 case "(($ac_try" in
32358   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32359   *) ac_try_echo=$ac_try;;
32360 esac
32361 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32362   (eval "$ac_compile") 2>conftest.er1
32363   ac_status=$?
32364   grep -v '^ *+' conftest.er1 >conftest.err
32365   rm -f conftest.er1
32366   cat conftest.err >&5
32367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32368   (exit $ac_status); } && {
32369          test -z "$ac_c_werror_flag" ||
32370          test ! -s conftest.err
32371        } && test -s conftest.$ac_objext; then
32372   ac_hi=$ac_mid; break
32373 else
32374   echo "$as_me: failed program was:" >&5
32375 sed 's/^/| /' conftest.$ac_ext >&5
32376
32377         ac_lo=`expr $ac_mid + 1`
32378                         if test $ac_lo -le $ac_mid; then
32379                           ac_lo= ac_hi=
32380                           break
32381                         fi
32382                         ac_mid=`expr 2 '*' $ac_mid + 1`
32383 fi
32384
32385 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32386   done
32387 else
32388   echo "$as_me: failed program was:" >&5
32389 sed 's/^/| /' conftest.$ac_ext >&5
32390
32391         cat >conftest.$ac_ext <<_ACEOF
32392 /* confdefs.h.  */
32393 _ACEOF
32394 cat confdefs.h >>conftest.$ac_ext
32395 cat >>conftest.$ac_ext <<_ACEOF
32396 /* end confdefs.h.  */
32397 $ac_includes_default
32398    typedef unsigned long ac__type_sizeof_;
32399 int
32400 main ()
32401 {
32402 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
32403 test_array [0] = 0
32404
32405   ;
32406   return 0;
32407 }
32408 _ACEOF
32409 rm -f conftest.$ac_objext
32410 if { (ac_try="$ac_compile"
32411 case "(($ac_try" in
32412   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32413   *) ac_try_echo=$ac_try;;
32414 esac
32415 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32416   (eval "$ac_compile") 2>conftest.er1
32417   ac_status=$?
32418   grep -v '^ *+' conftest.er1 >conftest.err
32419   rm -f conftest.er1
32420   cat conftest.err >&5
32421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32422   (exit $ac_status); } && {
32423          test -z "$ac_c_werror_flag" ||
32424          test ! -s conftest.err
32425        } && test -s conftest.$ac_objext; then
32426   ac_hi=-1 ac_mid=-1
32427   while :; do
32428     cat >conftest.$ac_ext <<_ACEOF
32429 /* confdefs.h.  */
32430 _ACEOF
32431 cat confdefs.h >>conftest.$ac_ext
32432 cat >>conftest.$ac_ext <<_ACEOF
32433 /* end confdefs.h.  */
32434 $ac_includes_default
32435    typedef unsigned long ac__type_sizeof_;
32436 int
32437 main ()
32438 {
32439 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
32440 test_array [0] = 0
32441
32442   ;
32443   return 0;
32444 }
32445 _ACEOF
32446 rm -f conftest.$ac_objext
32447 if { (ac_try="$ac_compile"
32448 case "(($ac_try" in
32449   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32450   *) ac_try_echo=$ac_try;;
32451 esac
32452 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32453   (eval "$ac_compile") 2>conftest.er1
32454   ac_status=$?
32455   grep -v '^ *+' conftest.er1 >conftest.err
32456   rm -f conftest.er1
32457   cat conftest.err >&5
32458   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32459   (exit $ac_status); } && {
32460          test -z "$ac_c_werror_flag" ||
32461          test ! -s conftest.err
32462        } && test -s conftest.$ac_objext; then
32463   ac_lo=$ac_mid; break
32464 else
32465   echo "$as_me: failed program was:" >&5
32466 sed 's/^/| /' conftest.$ac_ext >&5
32467
32468         ac_hi=`expr '(' $ac_mid ')' - 1`
32469                         if test $ac_mid -le $ac_hi; then
32470                           ac_lo= ac_hi=
32471                           break
32472                         fi
32473                         ac_mid=`expr 2 '*' $ac_mid`
32474 fi
32475
32476 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32477   done
32478 else
32479   echo "$as_me: failed program was:" >&5
32480 sed 's/^/| /' conftest.$ac_ext >&5
32481
32482         ac_lo= ac_hi=
32483 fi
32484
32485 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32486 fi
32487
32488 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32489 # Binary search between lo and hi bounds.
32490 while test "x$ac_lo" != "x$ac_hi"; do
32491   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
32492   cat >conftest.$ac_ext <<_ACEOF
32493 /* confdefs.h.  */
32494 _ACEOF
32495 cat confdefs.h >>conftest.$ac_ext
32496 cat >>conftest.$ac_ext <<_ACEOF
32497 /* end confdefs.h.  */
32498 $ac_includes_default
32499    typedef unsigned long ac__type_sizeof_;
32500 int
32501 main ()
32502 {
32503 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
32504 test_array [0] = 0
32505
32506   ;
32507   return 0;
32508 }
32509 _ACEOF
32510 rm -f conftest.$ac_objext
32511 if { (ac_try="$ac_compile"
32512 case "(($ac_try" in
32513   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32514   *) ac_try_echo=$ac_try;;
32515 esac
32516 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32517   (eval "$ac_compile") 2>conftest.er1
32518   ac_status=$?
32519   grep -v '^ *+' conftest.er1 >conftest.err
32520   rm -f conftest.er1
32521   cat conftest.err >&5
32522   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32523   (exit $ac_status); } && {
32524          test -z "$ac_c_werror_flag" ||
32525          test ! -s conftest.err
32526        } && test -s conftest.$ac_objext; then
32527   ac_hi=$ac_mid
32528 else
32529   echo "$as_me: failed program was:" >&5
32530 sed 's/^/| /' conftest.$ac_ext >&5
32531
32532         ac_lo=`expr '(' $ac_mid ')' + 1`
32533 fi
32534
32535 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32536 done
32537 case $ac_lo in
32538 ?*) ac_cv_sizeof_unsigned_long=$ac_lo;;
32539 '') if test "$ac_cv_type_unsigned_long" = yes; then
32540      { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long)
32541 See \`config.log' for more details." >&5
32542 echo "$as_me: error: cannot compute sizeof (unsigned long)
32543 See \`config.log' for more details." >&2;}
32544    { (exit 77); exit 77; }; }
32545    else
32546      ac_cv_sizeof_unsigned_long=0
32547    fi ;;
32548 esac
32549 else
32550   cat >conftest.$ac_ext <<_ACEOF
32551 /* confdefs.h.  */
32552 _ACEOF
32553 cat confdefs.h >>conftest.$ac_ext
32554 cat >>conftest.$ac_ext <<_ACEOF
32555 /* end confdefs.h.  */
32556 $ac_includes_default
32557    typedef unsigned long ac__type_sizeof_;
32558 static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
32559 static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
32560 #include <stdio.h>
32561 #include <stdlib.h>
32562 int
32563 main ()
32564 {
32565
32566   FILE *f = fopen ("conftest.val", "w");
32567   if (! f)
32568     return 1;
32569   if (((long int) (sizeof (ac__type_sizeof_))) < 0)
32570     {
32571       long int i = longval ();
32572       if (i != ((long int) (sizeof (ac__type_sizeof_))))
32573         return 1;
32574       fprintf (f, "%ld\n", i);
32575     }
32576   else
32577     {
32578       unsigned long int i = ulongval ();
32579       if (i != ((long int) (sizeof (ac__type_sizeof_))))
32580         return 1;
32581       fprintf (f, "%lu\n", i);
32582     }
32583   return ferror (f) || fclose (f) != 0;
32584
32585   ;
32586   return 0;
32587 }
32588 _ACEOF
32589 rm -f conftest$ac_exeext
32590 if { (ac_try="$ac_link"
32591 case "(($ac_try" in
32592   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32593   *) ac_try_echo=$ac_try;;
32594 esac
32595 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32596   (eval "$ac_link") 2>&5
32597   ac_status=$?
32598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32599   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
32600   { (case "(($ac_try" in
32601   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32602   *) ac_try_echo=$ac_try;;
32603 esac
32604 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32605   (eval "$ac_try") 2>&5
32606   ac_status=$?
32607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32608   (exit $ac_status); }; }; then
32609   ac_cv_sizeof_unsigned_long=`cat conftest.val`
32610 else
32611   echo "$as_me: program exited with status $ac_status" >&5
32612 echo "$as_me: failed program was:" >&5
32613 sed 's/^/| /' conftest.$ac_ext >&5
32614
32615 ( exit $ac_status )
32616 if test "$ac_cv_type_unsigned_long" = yes; then
32617      { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long)
32618 See \`config.log' for more details." >&5
32619 echo "$as_me: error: cannot compute sizeof (unsigned long)
32620 See \`config.log' for more details." >&2;}
32621    { (exit 77); exit 77; }; }
32622    else
32623      ac_cv_sizeof_unsigned_long=0
32624    fi
32625 fi
32626 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
32627 fi
32628 rm -f conftest.val
32629 fi
32630 { echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long" >&5
32631 echo "${ECHO_T}$ac_cv_sizeof_unsigned_long" >&6; }
32632
32633
32634
32635 cat >>confdefs.h <<_ACEOF
32636 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
32637 _ACEOF
32638
32639
32640 { echo "$as_me:$LINENO: checking for mp_limb_t" >&5
32641 echo $ECHO_N "checking for mp_limb_t... $ECHO_C" >&6; }
32642 if test "${ac_cv_type_mp_limb_t+set}" = set; then
32643   echo $ECHO_N "(cached) $ECHO_C" >&6
32644 else
32645   cat >conftest.$ac_ext <<_ACEOF
32646 /* confdefs.h.  */
32647 _ACEOF
32648 cat confdefs.h >>conftest.$ac_ext
32649 cat >>conftest.$ac_ext <<_ACEOF
32650 /* end confdefs.h.  */
32651 #define __GMP_WITHIN_CONFIGURE 1   /* ignore template stuff */
32652 #define GMP_NAIL_BITS $GMP_NAIL_BITS
32653 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
32654 #define GMP_LIMB_BITS 123
32655 $DEFN_LONG_LONG_LIMB
32656 #include "$srcdir/gmp-h.in"
32657
32658
32659 typedef mp_limb_t ac__type_new_;
32660 int
32661 main ()
32662 {
32663 if ((ac__type_new_ *) 0)
32664   return 0;
32665 if (sizeof (ac__type_new_))
32666   return 0;
32667   ;
32668   return 0;
32669 }
32670 _ACEOF
32671 rm -f conftest.$ac_objext
32672 if { (ac_try="$ac_compile"
32673 case "(($ac_try" in
32674   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32675   *) ac_try_echo=$ac_try;;
32676 esac
32677 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32678   (eval "$ac_compile") 2>conftest.er1
32679   ac_status=$?
32680   grep -v '^ *+' conftest.er1 >conftest.err
32681   rm -f conftest.er1
32682   cat conftest.err >&5
32683   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32684   (exit $ac_status); } && {
32685          test -z "$ac_c_werror_flag" ||
32686          test ! -s conftest.err
32687        } && test -s conftest.$ac_objext; then
32688   ac_cv_type_mp_limb_t=yes
32689 else
32690   echo "$as_me: failed program was:" >&5
32691 sed 's/^/| /' conftest.$ac_ext >&5
32692
32693         ac_cv_type_mp_limb_t=no
32694 fi
32695
32696 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32697 fi
32698 { echo "$as_me:$LINENO: result: $ac_cv_type_mp_limb_t" >&5
32699 echo "${ECHO_T}$ac_cv_type_mp_limb_t" >&6; }
32700
32701 # The cast to long int works around a bug in the HP C Compiler
32702 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
32703 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
32704 # This bug is HP SR number 8606223364.
32705 { echo "$as_me:$LINENO: checking size of mp_limb_t" >&5
32706 echo $ECHO_N "checking size of mp_limb_t... $ECHO_C" >&6; }
32707 if test "${ac_cv_sizeof_mp_limb_t+set}" = set; then
32708   echo $ECHO_N "(cached) $ECHO_C" >&6
32709 else
32710   if test "$cross_compiling" = yes; then
32711   # Depending upon the size, compute the lo and hi bounds.
32712 cat >conftest.$ac_ext <<_ACEOF
32713 /* confdefs.h.  */
32714 _ACEOF
32715 cat confdefs.h >>conftest.$ac_ext
32716 cat >>conftest.$ac_ext <<_ACEOF
32717 /* end confdefs.h.  */
32718 #define __GMP_WITHIN_CONFIGURE 1   /* ignore template stuff */
32719 #define GMP_NAIL_BITS $GMP_NAIL_BITS
32720 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
32721 #define GMP_LIMB_BITS 123
32722 $DEFN_LONG_LONG_LIMB
32723 #include "$srcdir/gmp-h.in"
32724
32725
32726    typedef mp_limb_t ac__type_sizeof_;
32727 int
32728 main ()
32729 {
32730 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
32731 test_array [0] = 0
32732
32733   ;
32734   return 0;
32735 }
32736 _ACEOF
32737 rm -f conftest.$ac_objext
32738 if { (ac_try="$ac_compile"
32739 case "(($ac_try" in
32740   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32741   *) ac_try_echo=$ac_try;;
32742 esac
32743 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32744   (eval "$ac_compile") 2>conftest.er1
32745   ac_status=$?
32746   grep -v '^ *+' conftest.er1 >conftest.err
32747   rm -f conftest.er1
32748   cat conftest.err >&5
32749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32750   (exit $ac_status); } && {
32751          test -z "$ac_c_werror_flag" ||
32752          test ! -s conftest.err
32753        } && test -s conftest.$ac_objext; then
32754   ac_lo=0 ac_mid=0
32755   while :; do
32756     cat >conftest.$ac_ext <<_ACEOF
32757 /* confdefs.h.  */
32758 _ACEOF
32759 cat confdefs.h >>conftest.$ac_ext
32760 cat >>conftest.$ac_ext <<_ACEOF
32761 /* end confdefs.h.  */
32762 #define __GMP_WITHIN_CONFIGURE 1   /* ignore template stuff */
32763 #define GMP_NAIL_BITS $GMP_NAIL_BITS
32764 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
32765 #define GMP_LIMB_BITS 123
32766 $DEFN_LONG_LONG_LIMB
32767 #include "$srcdir/gmp-h.in"
32768
32769
32770    typedef mp_limb_t ac__type_sizeof_;
32771 int
32772 main ()
32773 {
32774 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
32775 test_array [0] = 0
32776
32777   ;
32778   return 0;
32779 }
32780 _ACEOF
32781 rm -f conftest.$ac_objext
32782 if { (ac_try="$ac_compile"
32783 case "(($ac_try" in
32784   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32785   *) ac_try_echo=$ac_try;;
32786 esac
32787 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32788   (eval "$ac_compile") 2>conftest.er1
32789   ac_status=$?
32790   grep -v '^ *+' conftest.er1 >conftest.err
32791   rm -f conftest.er1
32792   cat conftest.err >&5
32793   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32794   (exit $ac_status); } && {
32795          test -z "$ac_c_werror_flag" ||
32796          test ! -s conftest.err
32797        } && test -s conftest.$ac_objext; then
32798   ac_hi=$ac_mid; break
32799 else
32800   echo "$as_me: failed program was:" >&5
32801 sed 's/^/| /' conftest.$ac_ext >&5
32802
32803         ac_lo=`expr $ac_mid + 1`
32804                         if test $ac_lo -le $ac_mid; then
32805                           ac_lo= ac_hi=
32806                           break
32807                         fi
32808                         ac_mid=`expr 2 '*' $ac_mid + 1`
32809 fi
32810
32811 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32812   done
32813 else
32814   echo "$as_me: failed program was:" >&5
32815 sed 's/^/| /' conftest.$ac_ext >&5
32816
32817         cat >conftest.$ac_ext <<_ACEOF
32818 /* confdefs.h.  */
32819 _ACEOF
32820 cat confdefs.h >>conftest.$ac_ext
32821 cat >>conftest.$ac_ext <<_ACEOF
32822 /* end confdefs.h.  */
32823 #define __GMP_WITHIN_CONFIGURE 1   /* ignore template stuff */
32824 #define GMP_NAIL_BITS $GMP_NAIL_BITS
32825 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
32826 #define GMP_LIMB_BITS 123
32827 $DEFN_LONG_LONG_LIMB
32828 #include "$srcdir/gmp-h.in"
32829
32830
32831    typedef mp_limb_t ac__type_sizeof_;
32832 int
32833 main ()
32834 {
32835 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
32836 test_array [0] = 0
32837
32838   ;
32839   return 0;
32840 }
32841 _ACEOF
32842 rm -f conftest.$ac_objext
32843 if { (ac_try="$ac_compile"
32844 case "(($ac_try" in
32845   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32846   *) ac_try_echo=$ac_try;;
32847 esac
32848 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32849   (eval "$ac_compile") 2>conftest.er1
32850   ac_status=$?
32851   grep -v '^ *+' conftest.er1 >conftest.err
32852   rm -f conftest.er1
32853   cat conftest.err >&5
32854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32855   (exit $ac_status); } && {
32856          test -z "$ac_c_werror_flag" ||
32857          test ! -s conftest.err
32858        } && test -s conftest.$ac_objext; then
32859   ac_hi=-1 ac_mid=-1
32860   while :; do
32861     cat >conftest.$ac_ext <<_ACEOF
32862 /* confdefs.h.  */
32863 _ACEOF
32864 cat confdefs.h >>conftest.$ac_ext
32865 cat >>conftest.$ac_ext <<_ACEOF
32866 /* end confdefs.h.  */
32867 #define __GMP_WITHIN_CONFIGURE 1   /* ignore template stuff */
32868 #define GMP_NAIL_BITS $GMP_NAIL_BITS
32869 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
32870 #define GMP_LIMB_BITS 123
32871 $DEFN_LONG_LONG_LIMB
32872 #include "$srcdir/gmp-h.in"
32873
32874
32875    typedef mp_limb_t ac__type_sizeof_;
32876 int
32877 main ()
32878 {
32879 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
32880 test_array [0] = 0
32881
32882   ;
32883   return 0;
32884 }
32885 _ACEOF
32886 rm -f conftest.$ac_objext
32887 if { (ac_try="$ac_compile"
32888 case "(($ac_try" in
32889   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32890   *) ac_try_echo=$ac_try;;
32891 esac
32892 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32893   (eval "$ac_compile") 2>conftest.er1
32894   ac_status=$?
32895   grep -v '^ *+' conftest.er1 >conftest.err
32896   rm -f conftest.er1
32897   cat conftest.err >&5
32898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32899   (exit $ac_status); } && {
32900          test -z "$ac_c_werror_flag" ||
32901          test ! -s conftest.err
32902        } && test -s conftest.$ac_objext; then
32903   ac_lo=$ac_mid; break
32904 else
32905   echo "$as_me: failed program was:" >&5
32906 sed 's/^/| /' conftest.$ac_ext >&5
32907
32908         ac_hi=`expr '(' $ac_mid ')' - 1`
32909                         if test $ac_mid -le $ac_hi; then
32910                           ac_lo= ac_hi=
32911                           break
32912                         fi
32913                         ac_mid=`expr 2 '*' $ac_mid`
32914 fi
32915
32916 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32917   done
32918 else
32919   echo "$as_me: failed program was:" >&5
32920 sed 's/^/| /' conftest.$ac_ext >&5
32921
32922         ac_lo= ac_hi=
32923 fi
32924
32925 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32926 fi
32927
32928 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32929 # Binary search between lo and hi bounds.
32930 while test "x$ac_lo" != "x$ac_hi"; do
32931   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
32932   cat >conftest.$ac_ext <<_ACEOF
32933 /* confdefs.h.  */
32934 _ACEOF
32935 cat confdefs.h >>conftest.$ac_ext
32936 cat >>conftest.$ac_ext <<_ACEOF
32937 /* end confdefs.h.  */
32938 #define __GMP_WITHIN_CONFIGURE 1   /* ignore template stuff */
32939 #define GMP_NAIL_BITS $GMP_NAIL_BITS
32940 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
32941 #define GMP_LIMB_BITS 123
32942 $DEFN_LONG_LONG_LIMB
32943 #include "$srcdir/gmp-h.in"
32944
32945
32946    typedef mp_limb_t ac__type_sizeof_;
32947 int
32948 main ()
32949 {
32950 static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
32951 test_array [0] = 0
32952
32953   ;
32954   return 0;
32955 }
32956 _ACEOF
32957 rm -f conftest.$ac_objext
32958 if { (ac_try="$ac_compile"
32959 case "(($ac_try" in
32960   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32961   *) ac_try_echo=$ac_try;;
32962 esac
32963 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32964   (eval "$ac_compile") 2>conftest.er1
32965   ac_status=$?
32966   grep -v '^ *+' conftest.er1 >conftest.err
32967   rm -f conftest.er1
32968   cat conftest.err >&5
32969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
32970   (exit $ac_status); } && {
32971          test -z "$ac_c_werror_flag" ||
32972          test ! -s conftest.err
32973        } && test -s conftest.$ac_objext; then
32974   ac_hi=$ac_mid
32975 else
32976   echo "$as_me: failed program was:" >&5
32977 sed 's/^/| /' conftest.$ac_ext >&5
32978
32979         ac_lo=`expr '(' $ac_mid ')' + 1`
32980 fi
32981
32982 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32983 done
32984 case $ac_lo in
32985 ?*) ac_cv_sizeof_mp_limb_t=$ac_lo;;
32986 '') if test "$ac_cv_type_mp_limb_t" = yes; then
32987      { { echo "$as_me:$LINENO: error: cannot compute sizeof (mp_limb_t)
32988 See \`config.log' for more details." >&5
32989 echo "$as_me: error: cannot compute sizeof (mp_limb_t)
32990 See \`config.log' for more details." >&2;}
32991    { (exit 77); exit 77; }; }
32992    else
32993      ac_cv_sizeof_mp_limb_t=0
32994    fi ;;
32995 esac
32996 else
32997   cat >conftest.$ac_ext <<_ACEOF
32998 /* confdefs.h.  */
32999 _ACEOF
33000 cat confdefs.h >>conftest.$ac_ext
33001 cat >>conftest.$ac_ext <<_ACEOF
33002 /* end confdefs.h.  */
33003 #define __GMP_WITHIN_CONFIGURE 1   /* ignore template stuff */
33004 #define GMP_NAIL_BITS $GMP_NAIL_BITS
33005 #define __GMP_BITS_PER_MP_LIMB 123 /* dummy for GMP_NUMB_BITS etc */
33006 #define GMP_LIMB_BITS 123
33007 $DEFN_LONG_LONG_LIMB
33008 #include "$srcdir/gmp-h.in"
33009
33010
33011    typedef mp_limb_t ac__type_sizeof_;
33012 static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
33013 static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
33014 #include <stdio.h>
33015 #include <stdlib.h>
33016 int
33017 main ()
33018 {
33019
33020   FILE *f = fopen ("conftest.val", "w");
33021   if (! f)
33022     return 1;
33023   if (((long int) (sizeof (ac__type_sizeof_))) < 0)
33024     {
33025       long int i = longval ();
33026       if (i != ((long int) (sizeof (ac__type_sizeof_))))
33027         return 1;
33028       fprintf (f, "%ld\n", i);
33029     }
33030   else
33031     {
33032       unsigned long int i = ulongval ();
33033       if (i != ((long int) (sizeof (ac__type_sizeof_))))
33034         return 1;
33035       fprintf (f, "%lu\n", i);
33036     }
33037   return ferror (f) || fclose (f) != 0;
33038
33039   ;
33040   return 0;
33041 }
33042 _ACEOF
33043 rm -f conftest$ac_exeext
33044 if { (ac_try="$ac_link"
33045 case "(($ac_try" in
33046   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33047   *) ac_try_echo=$ac_try;;
33048 esac
33049 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33050   (eval "$ac_link") 2>&5
33051   ac_status=$?
33052   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33053   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
33054   { (case "(($ac_try" in
33055   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33056   *) ac_try_echo=$ac_try;;
33057 esac
33058 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33059   (eval "$ac_try") 2>&5
33060   ac_status=$?
33061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33062   (exit $ac_status); }; }; then
33063   ac_cv_sizeof_mp_limb_t=`cat conftest.val`
33064 else
33065   echo "$as_me: program exited with status $ac_status" >&5
33066 echo "$as_me: failed program was:" >&5
33067 sed 's/^/| /' conftest.$ac_ext >&5
33068
33069 ( exit $ac_status )
33070 if test "$ac_cv_type_mp_limb_t" = yes; then
33071      { { echo "$as_me:$LINENO: error: cannot compute sizeof (mp_limb_t)
33072 See \`config.log' for more details." >&5
33073 echo "$as_me: error: cannot compute sizeof (mp_limb_t)
33074 See \`config.log' for more details." >&2;}
33075    { (exit 77); exit 77; }; }
33076    else
33077      ac_cv_sizeof_mp_limb_t=0
33078    fi
33079 fi
33080 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
33081 fi
33082 rm -f conftest.val
33083 fi
33084 { echo "$as_me:$LINENO: result: $ac_cv_sizeof_mp_limb_t" >&5
33085 echo "${ECHO_T}$ac_cv_sizeof_mp_limb_t" >&6; }
33086
33087
33088
33089 cat >>confdefs.h <<_ACEOF
33090 #define SIZEOF_MP_LIMB_T $ac_cv_sizeof_mp_limb_t
33091 _ACEOF
33092
33093
33094 if test "$ac_cv_sizeof_mp_limb_t" = 0; then
33095   { { echo "$as_me:$LINENO: error: Oops, mp_limb_t doesn't seem to work" >&5
33096 echo "$as_me: error: Oops, mp_limb_t doesn't seem to work" >&2;}
33097    { (exit 1); exit 1; }; }
33098 fi
33099 BITS_PER_MP_LIMB=`expr 8 \* $ac_cv_sizeof_mp_limb_t`
33100
33101
33102 echo "define(<SIZEOF_UNSIGNED>,<$ac_cv_sizeof_unsigned>)" >> $gmp_tmpconfigm4
33103
33104
33105 # Check compiler limb size matches gmp-mparam.h
33106 #
33107 # FIXME: Some of the cycle counter objects in the tune directory depend on
33108 # the size of ulong, it'd be possible to check that here, though a mismatch
33109 # probably wouldn't want to be fatal, none of the libgmp assembler code
33110 # depends on ulong.
33111 #
33112 mparam_bits=`sed -n 's/^#define BITS_PER_MP_LIMB[       ][      ]*\([0-9]*\).*$/\1/p' $gmp_mparam_source`
33113 if test -n "$mparam_bits" && test "$mparam_bits" -ne $BITS_PER_MP_LIMB; then
33114   if test "$test_CFLAGS" = set; then
33115     { { echo "$as_me:$LINENO: error: Oops, mp_limb_t is $BITS_PER_MP_LIMB bits, but the assembler code
33116 in this configuration expects $mparam_bits bits.
33117 You appear to have set \$CFLAGS, perhaps you also need to tell GMP the
33118 intended ABI, see \"ABI and ISA\" in the manual." >&5
33119 echo "$as_me: error: Oops, mp_limb_t is $BITS_PER_MP_LIMB bits, but the assembler code
33120 in this configuration expects $mparam_bits bits.
33121 You appear to have set \$CFLAGS, perhaps you also need to tell GMP the
33122 intended ABI, see \"ABI and ISA\" in the manual." >&2;}
33123    { (exit 1); exit 1; }; }
33124   else
33125     { { echo "$as_me:$LINENO: error: Oops, mp_limb_t is $BITS_PER_MP_LIMB bits, but the assembler code
33126 in this configuration expects $mparam_bits bits." >&5
33127 echo "$as_me: error: Oops, mp_limb_t is $BITS_PER_MP_LIMB bits, but the assembler code
33128 in this configuration expects $mparam_bits bits." >&2;}
33129    { (exit 1); exit 1; }; }
33130   fi
33131 fi
33132
33133
33134 echo "define(<GMP_LIMB_BITS>,$BITS_PER_MP_LIMB)" >> $gmp_tmpconfigm4
33135
33136
33137 echo "define(<GMP_NAIL_BITS>,$GMP_NAIL_BITS)" >> $gmp_tmpconfigm4
33138
33139
33140 echo "define(<GMP_NUMB_BITS>,eval(GMP_LIMB_BITS-GMP_NAIL_BITS))" >> $gmp_tmpconfigm4
33141
33142
33143
33144 # Exclude the mpn random functions from mpbsd since that would drag in the
33145 # top-level rand things, all of which are unnecessary for libmp.  There's
33146 # other unnecessary objects too actually, if we could be bothered figuring
33147 # out exactly which they are.
33148 #
33149 mpn_objs_in_libmp=
33150 for i in $mpn_objs_in_libgmp; do
33151   case $i in
33152   *random*) ;;
33153   *) mpn_objs_in_libmp="$mpn_objs_in_libmp $i" ;;
33154   esac
33155 done
33156
33157
33158
33159
33160
33161
33162
33163 # A recompiled sqr_basecase for use in the tune program, if necessary.
33164 TUNE_SQR_OBJ=
33165 test -d tune || mkdir tune
33166 case $sqr_basecase_source in
33167   *.asm)
33168     sqr_max=`sed -n 's/^def...(SQR_KARATSUBA_THRESHOLD_MAX, *\([0-9]*\))/\1/p' $sqr_basecase_source`
33169     if test -n "$sqr_max"; then
33170       TUNE_SQR_OBJ=sqr_asm.o
33171
33172 cat >>confdefs.h <<_ACEOF
33173 #define TUNE_SQR_KARATSUBA_MAX $sqr_max
33174 _ACEOF
33175
33176     fi
33177     cat >tune/sqr_basecase.c <<EOF
33178 /* not sure that an empty file can compile, so put in a dummy */
33179 int sqr_basecase_dummy;
33180 EOF
33181     ;;
33182   *.c)
33183     TUNE_SQR_OBJ=
33184     cat >>confdefs.h <<\_ACEOF
33185 #define TUNE_SQR_KARATSUBA_MAX SQR_KARATSUBA_MAX_GENERIC
33186 _ACEOF
33187
33188     cat >tune/sqr_basecase.c <<EOF
33189 #define TUNE_PROGRAM_BUILD 1
33190 #define TUNE_PROGRAM_BUILD_SQR 1
33191 #include "mpn/sqr_basecase.c"
33192 EOF
33193     ;;
33194 esac
33195
33196
33197
33198 # Configs for demos/pexpr.c.
33199 #
33200 ac_config_files="$ac_config_files demos/pexpr-config.h:demos/pexpr-config-h.in"
33201
33202 case $ac_cv_func_clock in
33203 yes) HAVE_CLOCK_01=1
33204  ;;
33205 no)  HAVE_CLOCK_01=0 ;;
33206 esac
33207
33208 case $ac_cv_func_cputime in
33209 yes) HAVE_CPUTIME_01=1
33210  ;;
33211 no)  HAVE_CPUTIME_01=0 ;;
33212 esac
33213
33214 case $ac_cv_func_getrusage in
33215 yes) HAVE_GETRUSAGE_01=1
33216  ;;
33217 no)  HAVE_GETRUSAGE_01=0 ;;
33218 esac
33219
33220 case $ac_cv_func_gettimeofday in
33221 yes) HAVE_GETTIMEOFDAY_01=1
33222  ;;
33223 no)  HAVE_GETTIMEOFDAY_01=0 ;;
33224 esac
33225
33226 case $ac_cv_func_sigaction in
33227 yes) HAVE_SIGACTION_01=1
33228  ;;
33229 no)  HAVE_SIGACTION_01=0 ;;
33230 esac
33231
33232 case $ac_cv_func_sigaltstack in
33233 yes) HAVE_SIGALTSTACK_01=1
33234  ;;
33235 no)  HAVE_SIGALTSTACK_01=0 ;;
33236 esac
33237
33238 case $ac_cv_func_sigstack in
33239 yes) HAVE_SIGSTACK_01=1
33240  ;;
33241 no)  HAVE_SIGSTACK_01=0 ;;
33242 esac
33243
33244
33245 case $ac_cv_header_sys_resource_h in
33246 yes) HAVE_SYS_RESOURCE_H_01=1
33247  ;;
33248 no)  HAVE_SYS_RESOURCE_H_01=0 ;;
33249 esac
33250
33251
33252 { echo "$as_me:$LINENO: checking for stack_t" >&5
33253 echo $ECHO_N "checking for stack_t... $ECHO_C" >&6; }
33254 if test "${ac_cv_type_stack_t+set}" = set; then
33255   echo $ECHO_N "(cached) $ECHO_C" >&6
33256 else
33257   cat >conftest.$ac_ext <<_ACEOF
33258 /* confdefs.h.  */
33259 _ACEOF
33260 cat confdefs.h >>conftest.$ac_ext
33261 cat >>conftest.$ac_ext <<_ACEOF
33262 /* end confdefs.h.  */
33263 #include <signal.h>
33264
33265 typedef stack_t ac__type_new_;
33266 int
33267 main ()
33268 {
33269 if ((ac__type_new_ *) 0)
33270   return 0;
33271 if (sizeof (ac__type_new_))
33272   return 0;
33273   ;
33274   return 0;
33275 }
33276 _ACEOF
33277 rm -f conftest.$ac_objext
33278 if { (ac_try="$ac_compile"
33279 case "(($ac_try" in
33280   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33281   *) ac_try_echo=$ac_try;;
33282 esac
33283 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33284   (eval "$ac_compile") 2>conftest.er1
33285   ac_status=$?
33286   grep -v '^ *+' conftest.er1 >conftest.err
33287   rm -f conftest.er1
33288   cat conftest.err >&5
33289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33290   (exit $ac_status); } && {
33291          test -z "$ac_c_werror_flag" ||
33292          test ! -s conftest.err
33293        } && test -s conftest.$ac_objext; then
33294   ac_cv_type_stack_t=yes
33295 else
33296   echo "$as_me: failed program was:" >&5
33297 sed 's/^/| /' conftest.$ac_ext >&5
33298
33299         ac_cv_type_stack_t=no
33300 fi
33301
33302 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33303 fi
33304 { echo "$as_me:$LINENO: result: $ac_cv_type_stack_t" >&5
33305 echo "${ECHO_T}$ac_cv_type_stack_t" >&6; }
33306 if test $ac_cv_type_stack_t = yes; then
33307
33308 cat >>confdefs.h <<_ACEOF
33309 #define HAVE_STACK_T 1
33310 _ACEOF
33311
33312 HAVE_STACK_T_01=1
33313 else
33314   HAVE_STACK_T_01=0
33315 fi
33316
33317
33318
33319 # Configs for demos/calc directory
33320 #
33321 # AC_SUBST+AC_CONFIG_FILES is used for calc-config.h, rather than AC_DEFINE+
33322 # AC_CONFIG_HEADERS, since with the latter automake (1.8) will then put the
33323 # directory (ie. demos/calc) into $(DEFAULT_INCLUDES) for every Makefile.in,
33324 # which would look very strange.
33325 #
33326 # -lcurses is required by libreadline.  On a typical SVR4 style system this
33327 # normally doesn't have to be given explicitly, since libreadline.so will
33328 # have a NEEDED record for it.  But if someone for some reason is using only
33329 # a static libreadline.a then we must give -lcurses.  Readline (as of
33330 # version 4.3) doesn't use libtool, so we can't rely on a .la to cover
33331 # necessary dependencies.
33332 #
33333 # On a couple of systems we've seen libreadline available, but the headers
33334 # not in the default include path, so check for readline/readline.h.  We've
33335 # also seen readline/history.h missing, not sure if that's just a broken
33336 # install or a very old version, but check that too.
33337 #
33338 ac_config_files="$ac_config_files demos/calc/calc-config.h:demos/calc/calc-config-h.in"
33339
33340 LIBCURSES=
33341 if test $with_readline != no; then
33342   { echo "$as_me:$LINENO: checking for tputs in -lncurses" >&5
33343 echo $ECHO_N "checking for tputs in -lncurses... $ECHO_C" >&6; }
33344 if test "${ac_cv_lib_ncurses_tputs+set}" = set; then
33345   echo $ECHO_N "(cached) $ECHO_C" >&6
33346 else
33347   ac_check_lib_save_LIBS=$LIBS
33348 LIBS="-lncurses  $LIBS"
33349 cat >conftest.$ac_ext <<_ACEOF
33350 /* confdefs.h.  */
33351 _ACEOF
33352 cat confdefs.h >>conftest.$ac_ext
33353 cat >>conftest.$ac_ext <<_ACEOF
33354 /* end confdefs.h.  */
33355
33356 /* Override any GCC internal prototype to avoid an error.
33357    Use char because int might match the return type of a GCC
33358    builtin and then its argument prototype would still apply.  */
33359 #ifdef __cplusplus
33360 extern "C"
33361 #endif
33362 char tputs ();
33363 int
33364 main ()
33365 {
33366 return tputs ();
33367   ;
33368   return 0;
33369 }
33370 _ACEOF
33371 rm -f conftest.$ac_objext conftest$ac_exeext
33372 if { (ac_try="$ac_link"
33373 case "(($ac_try" in
33374   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33375   *) ac_try_echo=$ac_try;;
33376 esac
33377 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33378   (eval "$ac_link") 2>conftest.er1
33379   ac_status=$?
33380   grep -v '^ *+' conftest.er1 >conftest.err
33381   rm -f conftest.er1
33382   cat conftest.err >&5
33383   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33384   (exit $ac_status); } && {
33385          test -z "$ac_c_werror_flag" ||
33386          test ! -s conftest.err
33387        } && test -s conftest$ac_exeext &&
33388        $as_test_x conftest$ac_exeext; then
33389   ac_cv_lib_ncurses_tputs=yes
33390 else
33391   echo "$as_me: failed program was:" >&5
33392 sed 's/^/| /' conftest.$ac_ext >&5
33393
33394         ac_cv_lib_ncurses_tputs=no
33395 fi
33396
33397 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
33398       conftest$ac_exeext conftest.$ac_ext
33399 LIBS=$ac_check_lib_save_LIBS
33400 fi
33401 { echo "$as_me:$LINENO: result: $ac_cv_lib_ncurses_tputs" >&5
33402 echo "${ECHO_T}$ac_cv_lib_ncurses_tputs" >&6; }
33403 if test $ac_cv_lib_ncurses_tputs = yes; then
33404   LIBCURSES=-lncurses
33405 else
33406   { echo "$as_me:$LINENO: checking for tputs in -lcurses" >&5
33407 echo $ECHO_N "checking for tputs in -lcurses... $ECHO_C" >&6; }
33408 if test "${ac_cv_lib_curses_tputs+set}" = set; then
33409   echo $ECHO_N "(cached) $ECHO_C" >&6
33410 else
33411   ac_check_lib_save_LIBS=$LIBS
33412 LIBS="-lcurses  $LIBS"
33413 cat >conftest.$ac_ext <<_ACEOF
33414 /* confdefs.h.  */
33415 _ACEOF
33416 cat confdefs.h >>conftest.$ac_ext
33417 cat >>conftest.$ac_ext <<_ACEOF
33418 /* end confdefs.h.  */
33419
33420 /* Override any GCC internal prototype to avoid an error.
33421    Use char because int might match the return type of a GCC
33422    builtin and then its argument prototype would still apply.  */
33423 #ifdef __cplusplus
33424 extern "C"
33425 #endif
33426 char tputs ();
33427 int
33428 main ()
33429 {
33430 return tputs ();
33431   ;
33432   return 0;
33433 }
33434 _ACEOF
33435 rm -f conftest.$ac_objext conftest$ac_exeext
33436 if { (ac_try="$ac_link"
33437 case "(($ac_try" in
33438   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33439   *) ac_try_echo=$ac_try;;
33440 esac
33441 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33442   (eval "$ac_link") 2>conftest.er1
33443   ac_status=$?
33444   grep -v '^ *+' conftest.er1 >conftest.err
33445   rm -f conftest.er1
33446   cat conftest.err >&5
33447   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33448   (exit $ac_status); } && {
33449          test -z "$ac_c_werror_flag" ||
33450          test ! -s conftest.err
33451        } && test -s conftest$ac_exeext &&
33452        $as_test_x conftest$ac_exeext; then
33453   ac_cv_lib_curses_tputs=yes
33454 else
33455   echo "$as_me: failed program was:" >&5
33456 sed 's/^/| /' conftest.$ac_ext >&5
33457
33458         ac_cv_lib_curses_tputs=no
33459 fi
33460
33461 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
33462       conftest$ac_exeext conftest.$ac_ext
33463 LIBS=$ac_check_lib_save_LIBS
33464 fi
33465 { echo "$as_me:$LINENO: result: $ac_cv_lib_curses_tputs" >&5
33466 echo "${ECHO_T}$ac_cv_lib_curses_tputs" >&6; }
33467 if test $ac_cv_lib_curses_tputs = yes; then
33468   LIBCURSES=-lcurses
33469 fi
33470
33471 fi
33472
33473 fi
33474
33475 use_readline=$with_readline
33476 if test $with_readline = detect; then
33477   use_readline=no
33478   { echo "$as_me:$LINENO: checking for readline in -lreadline" >&5
33479 echo $ECHO_N "checking for readline in -lreadline... $ECHO_C" >&6; }
33480 if test "${ac_cv_lib_readline_readline+set}" = set; then
33481   echo $ECHO_N "(cached) $ECHO_C" >&6
33482 else
33483   ac_check_lib_save_LIBS=$LIBS
33484 LIBS="-lreadline $LIBCURSES $LIBS"
33485 cat >conftest.$ac_ext <<_ACEOF
33486 /* confdefs.h.  */
33487 _ACEOF
33488 cat confdefs.h >>conftest.$ac_ext
33489 cat >>conftest.$ac_ext <<_ACEOF
33490 /* end confdefs.h.  */
33491
33492 /* Override any GCC internal prototype to avoid an error.
33493    Use char because int might match the return type of a GCC
33494    builtin and then its argument prototype would still apply.  */
33495 #ifdef __cplusplus
33496 extern "C"
33497 #endif
33498 char readline ();
33499 int
33500 main ()
33501 {
33502 return readline ();
33503   ;
33504   return 0;
33505 }
33506 _ACEOF
33507 rm -f conftest.$ac_objext conftest$ac_exeext
33508 if { (ac_try="$ac_link"
33509 case "(($ac_try" in
33510   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33511   *) ac_try_echo=$ac_try;;
33512 esac
33513 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33514   (eval "$ac_link") 2>conftest.er1
33515   ac_status=$?
33516   grep -v '^ *+' conftest.er1 >conftest.err
33517   rm -f conftest.er1
33518   cat conftest.err >&5
33519   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33520   (exit $ac_status); } && {
33521          test -z "$ac_c_werror_flag" ||
33522          test ! -s conftest.err
33523        } && test -s conftest$ac_exeext &&
33524        $as_test_x conftest$ac_exeext; then
33525   ac_cv_lib_readline_readline=yes
33526 else
33527   echo "$as_me: failed program was:" >&5
33528 sed 's/^/| /' conftest.$ac_ext >&5
33529
33530         ac_cv_lib_readline_readline=no
33531 fi
33532
33533 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
33534       conftest$ac_exeext conftest.$ac_ext
33535 LIBS=$ac_check_lib_save_LIBS
33536 fi
33537 { echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5
33538 echo "${ECHO_T}$ac_cv_lib_readline_readline" >&6; }
33539 if test $ac_cv_lib_readline_readline = yes; then
33540   if test "${ac_cv_header_readline_readline_h+set}" = set; then
33541   { echo "$as_me:$LINENO: checking for readline/readline.h" >&5
33542 echo $ECHO_N "checking for readline/readline.h... $ECHO_C" >&6; }
33543 if test "${ac_cv_header_readline_readline_h+set}" = set; then
33544   echo $ECHO_N "(cached) $ECHO_C" >&6
33545 fi
33546 { echo "$as_me:$LINENO: result: $ac_cv_header_readline_readline_h" >&5
33547 echo "${ECHO_T}$ac_cv_header_readline_readline_h" >&6; }
33548 else
33549   # Is the header compilable?
33550 { echo "$as_me:$LINENO: checking readline/readline.h usability" >&5
33551 echo $ECHO_N "checking readline/readline.h usability... $ECHO_C" >&6; }
33552 cat >conftest.$ac_ext <<_ACEOF
33553 /* confdefs.h.  */
33554 _ACEOF
33555 cat confdefs.h >>conftest.$ac_ext
33556 cat >>conftest.$ac_ext <<_ACEOF
33557 /* end confdefs.h.  */
33558 $ac_includes_default
33559 #include <readline/readline.h>
33560 _ACEOF
33561 rm -f conftest.$ac_objext
33562 if { (ac_try="$ac_compile"
33563 case "(($ac_try" in
33564   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33565   *) ac_try_echo=$ac_try;;
33566 esac
33567 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33568   (eval "$ac_compile") 2>conftest.er1
33569   ac_status=$?
33570   grep -v '^ *+' conftest.er1 >conftest.err
33571   rm -f conftest.er1
33572   cat conftest.err >&5
33573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33574   (exit $ac_status); } && {
33575          test -z "$ac_c_werror_flag" ||
33576          test ! -s conftest.err
33577        } && test -s conftest.$ac_objext; then
33578   ac_header_compiler=yes
33579 else
33580   echo "$as_me: failed program was:" >&5
33581 sed 's/^/| /' conftest.$ac_ext >&5
33582
33583         ac_header_compiler=no
33584 fi
33585
33586 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33587 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
33588 echo "${ECHO_T}$ac_header_compiler" >&6; }
33589
33590 # Is the header present?
33591 { echo "$as_me:$LINENO: checking readline/readline.h presence" >&5
33592 echo $ECHO_N "checking readline/readline.h presence... $ECHO_C" >&6; }
33593 cat >conftest.$ac_ext <<_ACEOF
33594 /* confdefs.h.  */
33595 _ACEOF
33596 cat confdefs.h >>conftest.$ac_ext
33597 cat >>conftest.$ac_ext <<_ACEOF
33598 /* end confdefs.h.  */
33599 #include <readline/readline.h>
33600 _ACEOF
33601 if { (ac_try="$ac_cpp conftest.$ac_ext"
33602 case "(($ac_try" in
33603   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33604   *) ac_try_echo=$ac_try;;
33605 esac
33606 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33607   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
33608   ac_status=$?
33609   grep -v '^ *+' conftest.er1 >conftest.err
33610   rm -f conftest.er1
33611   cat conftest.err >&5
33612   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33613   (exit $ac_status); } >/dev/null && {
33614          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
33615          test ! -s conftest.err
33616        }; then
33617   ac_header_preproc=yes
33618 else
33619   echo "$as_me: failed program was:" >&5
33620 sed 's/^/| /' conftest.$ac_ext >&5
33621
33622   ac_header_preproc=no
33623 fi
33624
33625 rm -f conftest.err conftest.$ac_ext
33626 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
33627 echo "${ECHO_T}$ac_header_preproc" >&6; }
33628
33629 # So?  What about this header?
33630 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
33631   yes:no: )
33632     { echo "$as_me:$LINENO: WARNING: readline/readline.h: accepted by the compiler, rejected by the preprocessor!" >&5
33633 echo "$as_me: WARNING: readline/readline.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
33634     { echo "$as_me:$LINENO: WARNING: readline/readline.h: proceeding with the compiler's result" >&5
33635 echo "$as_me: WARNING: readline/readline.h: proceeding with the compiler's result" >&2;}
33636     ac_header_preproc=yes
33637     ;;
33638   no:yes:* )
33639     { echo "$as_me:$LINENO: WARNING: readline/readline.h: present but cannot be compiled" >&5
33640 echo "$as_me: WARNING: readline/readline.h: present but cannot be compiled" >&2;}
33641     { echo "$as_me:$LINENO: WARNING: readline/readline.h:     check for missing prerequisite headers?" >&5
33642 echo "$as_me: WARNING: readline/readline.h:     check for missing prerequisite headers?" >&2;}
33643     { echo "$as_me:$LINENO: WARNING: readline/readline.h: see the Autoconf documentation" >&5
33644 echo "$as_me: WARNING: readline/readline.h: see the Autoconf documentation" >&2;}
33645     { echo "$as_me:$LINENO: WARNING: readline/readline.h:     section \"Present But Cannot Be Compiled\"" >&5
33646 echo "$as_me: WARNING: readline/readline.h:     section \"Present But Cannot Be Compiled\"" >&2;}
33647     { echo "$as_me:$LINENO: WARNING: readline/readline.h: proceeding with the preprocessor's result" >&5
33648 echo "$as_me: WARNING: readline/readline.h: proceeding with the preprocessor's result" >&2;}
33649     { echo "$as_me:$LINENO: WARNING: readline/readline.h: in the future, the compiler will take precedence" >&5
33650 echo "$as_me: WARNING: readline/readline.h: in the future, the compiler will take precedence" >&2;}
33651     ( cat <<\_ASBOX
33652 ## ---------------------------------- ##
33653 ## Report this to gmp-bugs@gmplib.org ##
33654 ## ---------------------------------- ##
33655 _ASBOX
33656      ) | sed "s/^/$as_me: WARNING:     /" >&2
33657     ;;
33658 esac
33659 { echo "$as_me:$LINENO: checking for readline/readline.h" >&5
33660 echo $ECHO_N "checking for readline/readline.h... $ECHO_C" >&6; }
33661 if test "${ac_cv_header_readline_readline_h+set}" = set; then
33662   echo $ECHO_N "(cached) $ECHO_C" >&6
33663 else
33664   ac_cv_header_readline_readline_h=$ac_header_preproc
33665 fi
33666 { echo "$as_me:$LINENO: result: $ac_cv_header_readline_readline_h" >&5
33667 echo "${ECHO_T}$ac_cv_header_readline_readline_h" >&6; }
33668
33669 fi
33670 if test $ac_cv_header_readline_readline_h = yes; then
33671   if test "${ac_cv_header_readline_history_h+set}" = set; then
33672   { echo "$as_me:$LINENO: checking for readline/history.h" >&5
33673 echo $ECHO_N "checking for readline/history.h... $ECHO_C" >&6; }
33674 if test "${ac_cv_header_readline_history_h+set}" = set; then
33675   echo $ECHO_N "(cached) $ECHO_C" >&6
33676 fi
33677 { echo "$as_me:$LINENO: result: $ac_cv_header_readline_history_h" >&5
33678 echo "${ECHO_T}$ac_cv_header_readline_history_h" >&6; }
33679 else
33680   # Is the header compilable?
33681 { echo "$as_me:$LINENO: checking readline/history.h usability" >&5
33682 echo $ECHO_N "checking readline/history.h usability... $ECHO_C" >&6; }
33683 cat >conftest.$ac_ext <<_ACEOF
33684 /* confdefs.h.  */
33685 _ACEOF
33686 cat confdefs.h >>conftest.$ac_ext
33687 cat >>conftest.$ac_ext <<_ACEOF
33688 /* end confdefs.h.  */
33689 $ac_includes_default
33690 #include <readline/history.h>
33691 _ACEOF
33692 rm -f conftest.$ac_objext
33693 if { (ac_try="$ac_compile"
33694 case "(($ac_try" in
33695   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33696   *) ac_try_echo=$ac_try;;
33697 esac
33698 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33699   (eval "$ac_compile") 2>conftest.er1
33700   ac_status=$?
33701   grep -v '^ *+' conftest.er1 >conftest.err
33702   rm -f conftest.er1
33703   cat conftest.err >&5
33704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33705   (exit $ac_status); } && {
33706          test -z "$ac_c_werror_flag" ||
33707          test ! -s conftest.err
33708        } && test -s conftest.$ac_objext; then
33709   ac_header_compiler=yes
33710 else
33711   echo "$as_me: failed program was:" >&5
33712 sed 's/^/| /' conftest.$ac_ext >&5
33713
33714         ac_header_compiler=no
33715 fi
33716
33717 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33718 { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
33719 echo "${ECHO_T}$ac_header_compiler" >&6; }
33720
33721 # Is the header present?
33722 { echo "$as_me:$LINENO: checking readline/history.h presence" >&5
33723 echo $ECHO_N "checking readline/history.h presence... $ECHO_C" >&6; }
33724 cat >conftest.$ac_ext <<_ACEOF
33725 /* confdefs.h.  */
33726 _ACEOF
33727 cat confdefs.h >>conftest.$ac_ext
33728 cat >>conftest.$ac_ext <<_ACEOF
33729 /* end confdefs.h.  */
33730 #include <readline/history.h>
33731 _ACEOF
33732 if { (ac_try="$ac_cpp conftest.$ac_ext"
33733 case "(($ac_try" in
33734   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33735   *) ac_try_echo=$ac_try;;
33736 esac
33737 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33738   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
33739   ac_status=$?
33740   grep -v '^ *+' conftest.er1 >conftest.err
33741   rm -f conftest.er1
33742   cat conftest.err >&5
33743   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33744   (exit $ac_status); } >/dev/null && {
33745          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
33746          test ! -s conftest.err
33747        }; then
33748   ac_header_preproc=yes
33749 else
33750   echo "$as_me: failed program was:" >&5
33751 sed 's/^/| /' conftest.$ac_ext >&5
33752
33753   ac_header_preproc=no
33754 fi
33755
33756 rm -f conftest.err conftest.$ac_ext
33757 { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
33758 echo "${ECHO_T}$ac_header_preproc" >&6; }
33759
33760 # So?  What about this header?
33761 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
33762   yes:no: )
33763     { echo "$as_me:$LINENO: WARNING: readline/history.h: accepted by the compiler, rejected by the preprocessor!" >&5
33764 echo "$as_me: WARNING: readline/history.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
33765     { echo "$as_me:$LINENO: WARNING: readline/history.h: proceeding with the compiler's result" >&5
33766 echo "$as_me: WARNING: readline/history.h: proceeding with the compiler's result" >&2;}
33767     ac_header_preproc=yes
33768     ;;
33769   no:yes:* )
33770     { echo "$as_me:$LINENO: WARNING: readline/history.h: present but cannot be compiled" >&5
33771 echo "$as_me: WARNING: readline/history.h: present but cannot be compiled" >&2;}
33772     { echo "$as_me:$LINENO: WARNING: readline/history.h:     check for missing prerequisite headers?" >&5
33773 echo "$as_me: WARNING: readline/history.h:     check for missing prerequisite headers?" >&2;}
33774     { echo "$as_me:$LINENO: WARNING: readline/history.h: see the Autoconf documentation" >&5
33775 echo "$as_me: WARNING: readline/history.h: see the Autoconf documentation" >&2;}
33776     { echo "$as_me:$LINENO: WARNING: readline/history.h:     section \"Present But Cannot Be Compiled\"" >&5
33777 echo "$as_me: WARNING: readline/history.h:     section \"Present But Cannot Be Compiled\"" >&2;}
33778     { echo "$as_me:$LINENO: WARNING: readline/history.h: proceeding with the preprocessor's result" >&5
33779 echo "$as_me: WARNING: readline/history.h: proceeding with the preprocessor's result" >&2;}
33780     { echo "$as_me:$LINENO: WARNING: readline/history.h: in the future, the compiler will take precedence" >&5
33781 echo "$as_me: WARNING: readline/history.h: in the future, the compiler will take precedence" >&2;}
33782     ( cat <<\_ASBOX
33783 ## ---------------------------------- ##
33784 ## Report this to gmp-bugs@gmplib.org ##
33785 ## ---------------------------------- ##
33786 _ASBOX
33787      ) | sed "s/^/$as_me: WARNING:     /" >&2
33788     ;;
33789 esac
33790 { echo "$as_me:$LINENO: checking for readline/history.h" >&5
33791 echo $ECHO_N "checking for readline/history.h... $ECHO_C" >&6; }
33792 if test "${ac_cv_header_readline_history_h+set}" = set; then
33793   echo $ECHO_N "(cached) $ECHO_C" >&6
33794 else
33795   ac_cv_header_readline_history_h=$ac_header_preproc
33796 fi
33797 { echo "$as_me:$LINENO: result: $ac_cv_header_readline_history_h" >&5
33798 echo "${ECHO_T}$ac_cv_header_readline_history_h" >&6; }
33799
33800 fi
33801 if test $ac_cv_header_readline_history_h = yes; then
33802   use_readline=yes
33803 fi
33804
33805
33806 fi
33807
33808
33809 fi
33810
33811   { echo "$as_me:$LINENO: checking readline detected" >&5
33812 echo $ECHO_N "checking readline detected... $ECHO_C" >&6; }
33813   { echo "$as_me:$LINENO: result: $use_readline" >&5
33814 echo "${ECHO_T}$use_readline" >&6; }
33815 fi
33816 if test $use_readline = yes; then
33817   WITH_READLINE_01=1
33818
33819   LIBREADLINE=-lreadline
33820
33821 else
33822   WITH_READLINE_01=0
33823 fi
33824 for ac_prog in 'bison -y' byacc
33825 do
33826   # Extract the first word of "$ac_prog", so it can be a program name with args.
33827 set dummy $ac_prog; ac_word=$2
33828 { echo "$as_me:$LINENO: checking for $ac_word" >&5
33829 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
33830 if test "${ac_cv_prog_YACC+set}" = set; then
33831   echo $ECHO_N "(cached) $ECHO_C" >&6
33832 else
33833   if test -n "$YACC"; then
33834   ac_cv_prog_YACC="$YACC" # Let the user override the test.
33835 else
33836 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33837 for as_dir in $PATH
33838 do
33839   IFS=$as_save_IFS
33840   test -z "$as_dir" && as_dir=.
33841   for ac_exec_ext in '' $ac_executable_extensions; do
33842   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
33843     ac_cv_prog_YACC="$ac_prog"
33844     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
33845     break 2
33846   fi
33847 done
33848 done
33849 IFS=$as_save_IFS
33850
33851 fi
33852 fi
33853 YACC=$ac_cv_prog_YACC
33854 if test -n "$YACC"; then
33855   { echo "$as_me:$LINENO: result: $YACC" >&5
33856 echo "${ECHO_T}$YACC" >&6; }
33857 else
33858   { echo "$as_me:$LINENO: result: no" >&5
33859 echo "${ECHO_T}no" >&6; }
33860 fi
33861
33862
33863   test -n "$YACC" && break
33864 done
33865 test -n "$YACC" || YACC="yacc"
33866
33867 for ac_prog in flex lex
33868 do
33869   # Extract the first word of "$ac_prog", so it can be a program name with args.
33870 set dummy $ac_prog; ac_word=$2
33871 { echo "$as_me:$LINENO: checking for $ac_word" >&5
33872 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
33873 if test "${ac_cv_prog_LEX+set}" = set; then
33874   echo $ECHO_N "(cached) $ECHO_C" >&6
33875 else
33876   if test -n "$LEX"; then
33877   ac_cv_prog_LEX="$LEX" # Let the user override the test.
33878 else
33879 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33880 for as_dir in $PATH
33881 do
33882   IFS=$as_save_IFS
33883   test -z "$as_dir" && as_dir=.
33884   for ac_exec_ext in '' $ac_executable_extensions; do
33885   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
33886     ac_cv_prog_LEX="$ac_prog"
33887     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
33888     break 2
33889   fi
33890 done
33891 done
33892 IFS=$as_save_IFS
33893
33894 fi
33895 fi
33896 LEX=$ac_cv_prog_LEX
33897 if test -n "$LEX"; then
33898   { echo "$as_me:$LINENO: result: $LEX" >&5
33899 echo "${ECHO_T}$LEX" >&6; }
33900 else
33901   { echo "$as_me:$LINENO: result: no" >&5
33902 echo "${ECHO_T}no" >&6; }
33903 fi
33904
33905
33906   test -n "$LEX" && break
33907 done
33908 test -n "$LEX" || LEX=":"
33909
33910 if test "x$LEX" != "x:"; then
33911   cat >conftest.l <<_ACEOF
33912 %%
33913 a { ECHO; }
33914 b { REJECT; }
33915 c { yymore (); }
33916 d { yyless (1); }
33917 e { yyless (input () != 0); }
33918 f { unput (yytext[0]); }
33919 . { BEGIN INITIAL; }
33920 %%
33921 #ifdef YYTEXT_POINTER
33922 extern char *yytext;
33923 #endif
33924 int
33925 main (void)
33926 {
33927   return ! yylex () + ! yywrap ();
33928 }
33929 _ACEOF
33930 { (ac_try="$LEX conftest.l"
33931 case "(($ac_try" in
33932   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33933   *) ac_try_echo=$ac_try;;
33934 esac
33935 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33936   (eval "$LEX conftest.l") 2>&5
33937   ac_status=$?
33938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33939   (exit $ac_status); }
33940 { echo "$as_me:$LINENO: checking lex output file root" >&5
33941 echo $ECHO_N "checking lex output file root... $ECHO_C" >&6; }
33942 if test "${ac_cv_prog_lex_root+set}" = set; then
33943   echo $ECHO_N "(cached) $ECHO_C" >&6
33944 else
33945
33946 if test -f lex.yy.c; then
33947   ac_cv_prog_lex_root=lex.yy
33948 elif test -f lexyy.c; then
33949   ac_cv_prog_lex_root=lexyy
33950 else
33951   { { echo "$as_me:$LINENO: error: cannot find output from $LEX; giving up" >&5
33952 echo "$as_me: error: cannot find output from $LEX; giving up" >&2;}
33953    { (exit 1); exit 1; }; }
33954 fi
33955 fi
33956 { echo "$as_me:$LINENO: result: $ac_cv_prog_lex_root" >&5
33957 echo "${ECHO_T}$ac_cv_prog_lex_root" >&6; }
33958 LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
33959
33960 if test -z "${LEXLIB+set}"; then
33961   { echo "$as_me:$LINENO: checking lex library" >&5
33962 echo $ECHO_N "checking lex library... $ECHO_C" >&6; }
33963 if test "${ac_cv_lib_lex+set}" = set; then
33964   echo $ECHO_N "(cached) $ECHO_C" >&6
33965 else
33966
33967     ac_save_LIBS=$LIBS
33968     ac_cv_lib_lex='none needed'
33969     for ac_lib in '' -lfl -ll; do
33970       LIBS="$ac_lib $ac_save_LIBS"
33971       cat >conftest.$ac_ext <<_ACEOF
33972 `cat $LEX_OUTPUT_ROOT.c`
33973 _ACEOF
33974 rm -f conftest.$ac_objext conftest$ac_exeext
33975 if { (ac_try="$ac_link"
33976 case "(($ac_try" in
33977   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33978   *) ac_try_echo=$ac_try;;
33979 esac
33980 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33981   (eval "$ac_link") 2>conftest.er1
33982   ac_status=$?
33983   grep -v '^ *+' conftest.er1 >conftest.err
33984   rm -f conftest.er1
33985   cat conftest.err >&5
33986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
33987   (exit $ac_status); } && {
33988          test -z "$ac_c_werror_flag" ||
33989          test ! -s conftest.err
33990        } && test -s conftest$ac_exeext &&
33991        $as_test_x conftest$ac_exeext; then
33992   ac_cv_lib_lex=$ac_lib
33993 else
33994   echo "$as_me: failed program was:" >&5
33995 sed 's/^/| /' conftest.$ac_ext >&5
33996
33997
33998 fi
33999
34000 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
34001       conftest$ac_exeext conftest.$ac_ext
34002       test "$ac_cv_lib_lex" != 'none needed' && break
34003     done
34004     LIBS=$ac_save_LIBS
34005
34006 fi
34007 { echo "$as_me:$LINENO: result: $ac_cv_lib_lex" >&5
34008 echo "${ECHO_T}$ac_cv_lib_lex" >&6; }
34009   test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex
34010 fi
34011
34012
34013 { echo "$as_me:$LINENO: checking whether yytext is a pointer" >&5
34014 echo $ECHO_N "checking whether yytext is a pointer... $ECHO_C" >&6; }
34015 if test "${ac_cv_prog_lex_yytext_pointer+set}" = set; then
34016   echo $ECHO_N "(cached) $ECHO_C" >&6
34017 else
34018   # POSIX says lex can declare yytext either as a pointer or an array; the
34019 # default is implementation-dependent.  Figure out which it is, since
34020 # not all implementations provide the %pointer and %array declarations.
34021 ac_cv_prog_lex_yytext_pointer=no
34022 ac_save_LIBS=$LIBS
34023 LIBS="$LEXLIB $ac_save_LIBS"
34024 cat >conftest.$ac_ext <<_ACEOF
34025 #define YYTEXT_POINTER 1
34026 `cat $LEX_OUTPUT_ROOT.c`
34027 _ACEOF
34028 rm -f conftest.$ac_objext conftest$ac_exeext
34029 if { (ac_try="$ac_link"
34030 case "(($ac_try" in
34031   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
34032   *) ac_try_echo=$ac_try;;
34033 esac
34034 eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
34035   (eval "$ac_link") 2>conftest.er1
34036   ac_status=$?
34037   grep -v '^ *+' conftest.er1 >conftest.err
34038   rm -f conftest.er1
34039   cat conftest.err >&5
34040   echo "$as_me:$LINENO: \$? = $ac_status" >&5
34041   (exit $ac_status); } && {
34042          test -z "$ac_c_werror_flag" ||
34043          test ! -s conftest.err
34044        } && test -s conftest$ac_exeext &&
34045        $as_test_x conftest$ac_exeext; then
34046   ac_cv_prog_lex_yytext_pointer=yes
34047 else
34048   echo "$as_me: failed program was:" >&5
34049 sed 's/^/| /' conftest.$ac_ext >&5
34050
34051
34052 fi
34053
34054 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
34055       conftest$ac_exeext conftest.$ac_ext
34056 LIBS=$ac_save_LIBS
34057
34058 fi
34059 { echo "$as_me:$LINENO: result: $ac_cv_prog_lex_yytext_pointer" >&5
34060 echo "${ECHO_T}$ac_cv_prog_lex_yytext_pointer" >&6; }
34061 if test $ac_cv_prog_lex_yytext_pointer = yes; then
34062
34063 cat >>confdefs.h <<\_ACEOF
34064 #define YYTEXT_POINTER 1
34065 _ACEOF
34066
34067 fi
34068 rm -f conftest.l $LEX_OUTPUT_ROOT.c
34069
34070 fi
34071 if test "$LEX" = :; then
34072   LEX=${am_missing_run}flex
34073 fi
34074
34075 # Configs for demos/expr directory
34076 #
34077 # Libtool already runs an AC_CHECK_TOOL for ranlib, but we give
34078 # AC_PROG_RANLIB anyway since automake is supposed to complain if it's not
34079 # called.  (Automake 1.8.4 doesn't, at least not when the only library is in
34080 # an EXTRA_LIBRARIES.)
34081 #
34082 if test -n "$ac_tool_prefix"; then
34083   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
34084 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
34085 { echo "$as_me:$LINENO: checking for $ac_word" >&5
34086 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
34087 if test "${ac_cv_prog_RANLIB+set}" = set; then
34088   echo $ECHO_N "(cached) $ECHO_C" >&6
34089 else
34090   if test -n "$RANLIB"; then
34091   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
34092 else
34093 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34094 for as_dir in $PATH
34095 do
34096   IFS=$as_save_IFS
34097   test -z "$as_dir" && as_dir=.
34098   for ac_exec_ext in '' $ac_executable_extensions; do
34099   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
34100     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
34101     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
34102     break 2
34103   fi
34104 done
34105 done
34106 IFS=$as_save_IFS
34107
34108 fi
34109 fi
34110 RANLIB=$ac_cv_prog_RANLIB
34111 if test -n "$RANLIB"; then
34112   { echo "$as_me:$LINENO: result: $RANLIB" >&5
34113 echo "${ECHO_T}$RANLIB" >&6; }
34114 else
34115   { echo "$as_me:$LINENO: result: no" >&5
34116 echo "${ECHO_T}no" >&6; }
34117 fi
34118
34119
34120 fi
34121 if test -z "$ac_cv_prog_RANLIB"; then
34122   ac_ct_RANLIB=$RANLIB
34123   # Extract the first word of "ranlib", so it can be a program name with args.
34124 set dummy ranlib; ac_word=$2
34125 { echo "$as_me:$LINENO: checking for $ac_word" >&5
34126 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
34127 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
34128   echo $ECHO_N "(cached) $ECHO_C" >&6
34129 else
34130   if test -n "$ac_ct_RANLIB"; then
34131   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
34132 else
34133 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34134 for as_dir in $PATH
34135 do
34136   IFS=$as_save_IFS
34137   test -z "$as_dir" && as_dir=.
34138   for ac_exec_ext in '' $ac_executable_extensions; do
34139   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
34140     ac_cv_prog_ac_ct_RANLIB="ranlib"
34141     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
34142     break 2
34143   fi
34144 done
34145 done
34146 IFS=$as_save_IFS
34147
34148 fi
34149 fi
34150 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
34151 if test -n "$ac_ct_RANLIB"; then
34152   { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
34153 echo "${ECHO_T}$ac_ct_RANLIB" >&6; }
34154 else
34155   { echo "$as_me:$LINENO: result: no" >&5
34156 echo "${ECHO_T}no" >&6; }
34157 fi
34158
34159   if test "x$ac_ct_RANLIB" = x; then
34160     RANLIB=":"
34161   else
34162     case $cross_compiling:$ac_tool_warned in
34163 yes:)
34164 { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
34165 whose name does not start with the host triplet.  If you think this
34166 configuration is useful to you, please write to autoconf@gnu.org." >&5
34167 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
34168 whose name does not start with the host triplet.  If you think this
34169 configuration is useful to you, please write to autoconf@gnu.org." >&2;}
34170 ac_tool_warned=yes ;;
34171 esac
34172     RANLIB=$ac_ct_RANLIB
34173   fi
34174 else
34175   RANLIB="$ac_cv_prog_RANLIB"
34176 fi
34177
34178
34179
34180 # Create config.m4.
34181
34182 echo "creating $gmp_configm4"
34183 echo "d""nl $gmp_configm4.  Generated automatically by configure." > $gmp_configm4
34184 if test -f $gmp_tmpconfigm4; then
34185   echo "changequote(<,>)" >> $gmp_configm4
34186   echo "ifdef(<__CONFIG_M4_INCLUDED__>,,<" >> $gmp_configm4
34187   cat $gmp_tmpconfigm4 >> $gmp_configm4
34188   echo ">)" >> $gmp_configm4
34189   echo "changequote(\`,')" >> $gmp_configm4
34190   rm $gmp_tmpconfigm4
34191 fi
34192 echo "ifdef(\`__CONFIG_M4_INCLUDED__',,\`" >> $gmp_configm4
34193 if test -f $gmp_tmpconfigm4i; then
34194   cat $gmp_tmpconfigm4i >> $gmp_configm4
34195   rm $gmp_tmpconfigm4i
34196 fi
34197 if test -f $gmp_tmpconfigm4p; then
34198   cat $gmp_tmpconfigm4p >> $gmp_configm4
34199   rm $gmp_tmpconfigm4p
34200 fi
34201 echo "')" >> $gmp_configm4
34202 echo "define(\`__CONFIG_M4_INCLUDED__')" >> $gmp_configm4
34203
34204
34205 # Create Makefiles
34206 # FIXME: Upcoming version of autoconf/automake may not like broken lines.
34207 #        Right now automake isn't accepting the new AC_CONFIG_FILES scheme.
34208
34209 ac_config_files="$ac_config_files Makefile mpbsd/Makefile mpf/Makefile mpn/Makefile mpq/Makefile mpz/Makefile printf/Makefile scanf/Makefile cxx/Makefile tests/Makefile tests/devel/Makefile tests/mpbsd/Makefile tests/mpf/Makefile tests/mpn/Makefile tests/mpq/Makefile tests/mpz/Makefile tests/rand/Makefile tests/misc/Makefile tests/cxx/Makefile doc/Makefile tune/Makefile demos/Makefile demos/calc/Makefile demos/expr/Makefile gmp.h:gmp-h.in mp.h:mp-h.in"
34210
34211 cat >confcache <<\_ACEOF
34212 # This file is a shell script that caches the results of configure
34213 # tests run on this system so they can be shared between configure
34214 # scripts and configure runs, see configure's option --config-cache.
34215 # It is not useful on other systems.  If it contains results you don't
34216 # want to keep, you may remove or edit it.
34217 #
34218 # config.status only pays attention to the cache file if you give it
34219 # the --recheck option to rerun configure.
34220 #
34221 # `ac_cv_env_foo' variables (set or unset) will be overridden when
34222 # loading this file, other *unset* `ac_cv_foo' will be assigned the
34223 # following values.
34224
34225 _ACEOF
34226
34227 # The following way of writing the cache mishandles newlines in values,
34228 # but we know of no workaround that is simple, portable, and efficient.
34229 # So, we kill variables containing newlines.
34230 # Ultrix sh set writes to stderr and can't be redirected directly,
34231 # and sets the high bit in the cache file unless we assign to the vars.
34232 (
34233   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
34234     eval ac_val=\$$ac_var
34235     case $ac_val in #(
34236     *${as_nl}*)
34237       case $ac_var in #(
34238       *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
34239 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
34240       esac
34241       case $ac_var in #(
34242       _ | IFS | as_nl) ;; #(
34243       *) $as_unset $ac_var ;;
34244       esac ;;
34245     esac
34246   done
34247
34248   (set) 2>&1 |
34249     case $as_nl`(ac_space=' '; set) 2>&1` in #(
34250     *${as_nl}ac_space=\ *)
34251       # `set' does not quote correctly, so add quotes (double-quote
34252       # substitution turns \\\\ into \\, and sed turns \\ into \).
34253       sed -n \
34254         "s/'/'\\\\''/g;
34255           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
34256       ;; #(
34257     *)
34258       # `set' quotes correctly as required by POSIX, so do not add quotes.
34259       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
34260       ;;
34261     esac |
34262     sort
34263 ) |
34264   sed '
34265      /^ac_cv_env_/b end
34266      t clear
34267      :clear
34268      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
34269      t end
34270      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
34271      :end' >>confcache
34272 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
34273   if test -w "$cache_file"; then
34274     test "x$cache_file" != "x/dev/null" &&
34275       { echo "$as_me:$LINENO: updating cache $cache_file" >&5
34276 echo "$as_me: updating cache $cache_file" >&6;}
34277     cat confcache >$cache_file
34278   else
34279     { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
34280 echo "$as_me: not updating unwritable cache $cache_file" >&6;}
34281   fi
34282 fi
34283 rm -f confcache
34284
34285 test "x$prefix" = xNONE && prefix=$ac_default_prefix
34286 # Let make expand exec_prefix.
34287 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
34288
34289 DEFS=-DHAVE_CONFIG_H
34290
34291 ac_libobjs=
34292 ac_ltlibobjs=
34293 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
34294   # 1. Remove the extension, and $U if already installed.
34295   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
34296   ac_i=`echo "$ac_i" | sed "$ac_script"`
34297   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
34298   #    will be set to the directory where LIBOBJS objects are built.
34299   ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
34300   ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
34301 done
34302 LIBOBJS=$ac_libobjs
34303
34304 LTLIBOBJS=$ac_ltlibobjs
34305
34306
34307 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
34308   { { echo "$as_me:$LINENO: error: conditional \"MAINTAINER_MODE\" was never defined.
34309 Usually this means the macro was only invoked conditionally." >&5
34310 echo "$as_me: error: conditional \"MAINTAINER_MODE\" was never defined.
34311 Usually this means the macro was only invoked conditionally." >&2;}
34312    { (exit 1); exit 1; }; }
34313 fi
34314 if test -z "${WANT_MPBSD_TRUE}" && test -z "${WANT_MPBSD_FALSE}"; then
34315   { { echo "$as_me:$LINENO: error: conditional \"WANT_MPBSD\" was never defined.
34316 Usually this means the macro was only invoked conditionally." >&5
34317 echo "$as_me: error: conditional \"WANT_MPBSD\" was never defined.
34318 Usually this means the macro was only invoked conditionally." >&2;}
34319    { (exit 1); exit 1; }; }
34320 fi
34321 if test -z "${WANT_CXX_TRUE}" && test -z "${WANT_CXX_FALSE}"; then
34322   { { echo "$as_me:$LINENO: error: conditional \"WANT_CXX\" was never defined.
34323 Usually this means the macro was only invoked conditionally." >&5
34324 echo "$as_me: error: conditional \"WANT_CXX\" was never defined.
34325 Usually this means the macro was only invoked conditionally." >&2;}
34326    { (exit 1); exit 1; }; }
34327 fi
34328 if test -z "${ENABLE_STATIC_TRUE}" && test -z "${ENABLE_STATIC_FALSE}"; then
34329   { { echo "$as_me:$LINENO: error: conditional \"ENABLE_STATIC\" was never defined.
34330 Usually this means the macro was only invoked conditionally." >&5
34331 echo "$as_me: error: conditional \"ENABLE_STATIC\" was never defined.
34332 Usually this means the macro was only invoked conditionally." >&2;}
34333    { (exit 1); exit 1; }; }
34334 fi
34335
34336 : ${CONFIG_STATUS=./config.status}
34337 ac_clean_files_save=$ac_clean_files
34338 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
34339 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
34340 echo "$as_me: creating $CONFIG_STATUS" >&6;}
34341 cat >$CONFIG_STATUS <<_ACEOF
34342 #! $SHELL
34343 # Generated by $as_me.
34344 # Run this file to recreate the current configuration.
34345 # Compiler output produced by configure, useful for debugging
34346 # configure, is in config.log if it exists.
34347
34348 debug=false
34349 ac_cs_recheck=false
34350 ac_cs_silent=false
34351 SHELL=\${CONFIG_SHELL-$SHELL}
34352 _ACEOF
34353
34354 cat >>$CONFIG_STATUS <<\_ACEOF
34355 ## --------------------- ##
34356 ## M4sh Initialization.  ##
34357 ## --------------------- ##
34358
34359 # Be more Bourne compatible
34360 DUALCASE=1; export DUALCASE # for MKS sh
34361 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
34362   emulate sh
34363   NULLCMD=:
34364   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
34365   # is contrary to our usage.  Disable this feature.
34366   alias -g '${1+"$@"}'='"$@"'
34367   setopt NO_GLOB_SUBST
34368 else
34369   case `(set -o) 2>/dev/null` in
34370   *posix*) set -o posix ;;
34371 esac
34372
34373 fi
34374
34375
34376
34377
34378 # PATH needs CR
34379 # Avoid depending upon Character Ranges.
34380 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
34381 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
34382 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
34383 as_cr_digits='0123456789'
34384 as_cr_alnum=$as_cr_Letters$as_cr_digits
34385
34386 # The user is always right.
34387 if test "${PATH_SEPARATOR+set}" != set; then
34388   echo "#! /bin/sh" >conf$$.sh
34389   echo  "exit 0"   >>conf$$.sh
34390   chmod +x conf$$.sh
34391   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
34392     PATH_SEPARATOR=';'
34393   else
34394     PATH_SEPARATOR=:
34395   fi
34396   rm -f conf$$.sh
34397 fi
34398
34399 # Support unset when possible.
34400 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
34401   as_unset=unset
34402 else
34403   as_unset=false
34404 fi
34405
34406
34407 # IFS
34408 # We need space, tab and new line, in precisely that order.  Quoting is
34409 # there to prevent editors from complaining about space-tab.
34410 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
34411 # splitting by setting IFS to empty value.)
34412 as_nl='
34413 '
34414 IFS=" ""        $as_nl"
34415
34416 # Find who we are.  Look in the path if we contain no directory separator.
34417 case $0 in
34418   *[\\/]* ) as_myself=$0 ;;
34419   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
34420 for as_dir in $PATH
34421 do
34422   IFS=$as_save_IFS
34423   test -z "$as_dir" && as_dir=.
34424   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
34425 done
34426 IFS=$as_save_IFS
34427
34428      ;;
34429 esac
34430 # We did not find ourselves, most probably we were run as `sh COMMAND'
34431 # in which case we are not to be found in the path.
34432 if test "x$as_myself" = x; then
34433   as_myself=$0
34434 fi
34435 if test ! -f "$as_myself"; then
34436   echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
34437   { (exit 1); exit 1; }
34438 fi
34439
34440 # Work around bugs in pre-3.0 UWIN ksh.
34441 for as_var in ENV MAIL MAILPATH
34442 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
34443 done
34444 PS1='$ '
34445 PS2='> '
34446 PS4='+ '
34447
34448 # NLS nuisances.
34449 for as_var in \
34450   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
34451   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
34452   LC_TELEPHONE LC_TIME
34453 do
34454   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
34455     eval $as_var=C; export $as_var
34456   else
34457     ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
34458   fi
34459 done
34460
34461 # Required to use basename.
34462 if expr a : '\(a\)' >/dev/null 2>&1 &&
34463    test "X`expr 00001 : '.*\(...\)'`" = X001; then
34464   as_expr=expr
34465 else
34466   as_expr=false
34467 fi
34468
34469 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
34470   as_basename=basename
34471 else
34472   as_basename=false
34473 fi
34474
34475
34476 # Name of the executable.
34477 as_me=`$as_basename -- "$0" ||
34478 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
34479          X"$0" : 'X\(//\)$' \| \
34480          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
34481 echo X/"$0" |
34482     sed '/^.*\/\([^/][^/]*\)\/*$/{
34483             s//\1/
34484             q
34485           }
34486           /^X\/\(\/\/\)$/{
34487             s//\1/
34488             q
34489           }
34490           /^X\/\(\/\).*/{
34491             s//\1/
34492             q
34493           }
34494           s/.*/./; q'`
34495
34496 # CDPATH.
34497 $as_unset CDPATH
34498
34499
34500
34501   as_lineno_1=$LINENO
34502   as_lineno_2=$LINENO
34503   test "x$as_lineno_1" != "x$as_lineno_2" &&
34504   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
34505
34506   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
34507   # uniformly replaced by the line number.  The first 'sed' inserts a
34508   # line-number line after each line using $LINENO; the second 'sed'
34509   # does the real work.  The second script uses 'N' to pair each
34510   # line-number line with the line containing $LINENO, and appends
34511   # trailing '-' during substitution so that $LINENO is not a special
34512   # case at line end.
34513   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
34514   # scripts with optimization help from Paolo Bonzini.  Blame Lee
34515   # E. McMahon (1931-1989) for sed's syntax.  :-)
34516   sed -n '
34517     p
34518     /[$]LINENO/=
34519   ' <$as_myself |
34520     sed '
34521       s/[$]LINENO.*/&-/
34522       t lineno
34523       b
34524       :lineno
34525       N
34526       :loop
34527       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
34528       t loop
34529       s/-\n.*//
34530     ' >$as_me.lineno &&
34531   chmod +x "$as_me.lineno" ||
34532     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
34533    { (exit 1); exit 1; }; }
34534
34535   # Don't try to exec as it changes $[0], causing all sort of problems
34536   # (the dirname of $[0] is not the place where we might find the
34537   # original and so on.  Autoconf is especially sensitive to this).
34538   . "./$as_me.lineno"
34539   # Exit status is that of the last command.
34540   exit
34541 }
34542
34543
34544 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
34545   as_dirname=dirname
34546 else
34547   as_dirname=false
34548 fi
34549
34550 ECHO_C= ECHO_N= ECHO_T=
34551 case `echo -n x` in
34552 -n*)
34553   case `echo 'x\c'` in
34554   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
34555   *)   ECHO_C='\c';;
34556   esac;;
34557 *)
34558   ECHO_N='-n';;
34559 esac
34560
34561 if expr a : '\(a\)' >/dev/null 2>&1 &&
34562    test "X`expr 00001 : '.*\(...\)'`" = X001; then
34563   as_expr=expr
34564 else
34565   as_expr=false
34566 fi
34567
34568 rm -f conf$$ conf$$.exe conf$$.file
34569 if test -d conf$$.dir; then
34570   rm -f conf$$.dir/conf$$.file
34571 else
34572   rm -f conf$$.dir
34573   mkdir conf$$.dir
34574 fi
34575 echo >conf$$.file
34576 if ln -s conf$$.file conf$$ 2>/dev/null; then
34577   as_ln_s='ln -s'
34578   # ... but there are two gotchas:
34579   # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
34580   # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
34581   # In both cases, we have to default to `cp -p'.
34582   ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
34583     as_ln_s='cp -p'
34584 elif ln conf$$.file conf$$ 2>/dev/null; then
34585   as_ln_s=ln
34586 else
34587   as_ln_s='cp -p'
34588 fi
34589 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
34590 rmdir conf$$.dir 2>/dev/null
34591
34592 if mkdir -p . 2>/dev/null; then
34593   as_mkdir_p=:
34594 else
34595   test -d ./-p && rmdir ./-p
34596   as_mkdir_p=false
34597 fi
34598
34599 if test -x / >/dev/null 2>&1; then
34600   as_test_x='test -x'
34601 else
34602   if ls -dL / >/dev/null 2>&1; then
34603     as_ls_L_option=L
34604   else
34605     as_ls_L_option=
34606   fi
34607   as_test_x='
34608     eval sh -c '\''
34609       if test -d "$1"; then
34610         test -d "$1/.";
34611       else
34612         case $1 in
34613         -*)set "./$1";;
34614         esac;
34615         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
34616         ???[sx]*):;;*)false;;esac;fi
34617     '\'' sh
34618   '
34619 fi
34620 as_executable_p=$as_test_x
34621
34622 # Sed expression to map a string onto a valid CPP name.
34623 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
34624
34625 # Sed expression to map a string onto a valid variable name.
34626 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
34627
34628
34629 exec 6>&1
34630
34631 # Save the log message, to keep $[0] and so on meaningful, and to
34632 # report actual input values of CONFIG_FILES etc. instead of their
34633 # values after options handling.
34634 ac_log="
34635 This file was extended by GNU MP $as_me 4.3.2, which was
34636 generated by GNU Autoconf 2.61.  Invocation command line was
34637
34638   CONFIG_FILES    = $CONFIG_FILES
34639   CONFIG_HEADERS  = $CONFIG_HEADERS
34640   CONFIG_LINKS    = $CONFIG_LINKS
34641   CONFIG_COMMANDS = $CONFIG_COMMANDS
34642   $ $0 $@
34643
34644 on `(hostname || uname -n) 2>/dev/null | sed 1q`
34645 "
34646
34647 _ACEOF
34648
34649 cat >>$CONFIG_STATUS <<_ACEOF
34650 # Files that config.status was made for.
34651 config_files="$ac_config_files"
34652 config_headers="$ac_config_headers"
34653 config_links="$ac_config_links"
34654
34655 _ACEOF
34656
34657 cat >>$CONFIG_STATUS <<\_ACEOF
34658 ac_cs_usage="\
34659 \`$as_me' instantiates files from templates according to the
34660 current configuration.
34661
34662 Usage: $0 [OPTIONS] [FILE]...
34663
34664   -h, --help       print this help, then exit
34665   -V, --version    print version number and configuration settings, then exit
34666   -q, --quiet      do not print progress messages
34667   -d, --debug      don't remove temporary files
34668       --recheck    update $as_me by reconfiguring in the same conditions
34669   --file=FILE[:TEMPLATE]
34670                    instantiate the configuration file FILE
34671   --header=FILE[:TEMPLATE]
34672                    instantiate the configuration header FILE
34673
34674 Configuration files:
34675 $config_files
34676
34677 Configuration headers:
34678 $config_headers
34679
34680 Configuration links:
34681 $config_links
34682
34683 Report bugs to <bug-autoconf@gnu.org>."
34684
34685 _ACEOF
34686 cat >>$CONFIG_STATUS <<_ACEOF
34687 ac_cs_version="\\
34688 GNU MP config.status 4.3.2
34689 configured by $0, generated by GNU Autoconf 2.61,
34690   with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
34691
34692 Copyright (C) 2006 Free Software Foundation, Inc.
34693 This config.status script is free software; the Free Software Foundation
34694 gives unlimited permission to copy, distribute and modify it."
34695
34696 ac_pwd='$ac_pwd'
34697 srcdir='$srcdir'
34698 INSTALL='$INSTALL'
34699 _ACEOF
34700
34701 cat >>$CONFIG_STATUS <<\_ACEOF
34702 # If no file are specified by the user, then we need to provide default
34703 # value.  By we need to know if files were specified by the user.
34704 ac_need_defaults=:
34705 while test $# != 0
34706 do
34707   case $1 in
34708   --*=*)
34709     ac_option=`expr "X$1" : 'X\([^=]*\)='`
34710     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
34711     ac_shift=:
34712     ;;
34713   *)
34714     ac_option=$1
34715     ac_optarg=$2
34716     ac_shift=shift
34717     ;;
34718   esac
34719
34720   case $ac_option in
34721   # Handling of the options.
34722   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
34723     ac_cs_recheck=: ;;
34724   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
34725     echo "$ac_cs_version"; exit ;;
34726   --debug | --debu | --deb | --de | --d | -d )
34727     debug=: ;;
34728   --file | --fil | --fi | --f )
34729     $ac_shift
34730     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
34731     ac_need_defaults=false;;
34732   --header | --heade | --head | --hea )
34733     $ac_shift
34734     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
34735     ac_need_defaults=false;;
34736   --he | --h)
34737     # Conflict between --help and --header
34738     { echo "$as_me: error: ambiguous option: $1
34739 Try \`$0 --help' for more information." >&2
34740    { (exit 1); exit 1; }; };;
34741   --help | --hel | -h )
34742     echo "$ac_cs_usage"; exit ;;
34743   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
34744   | -silent | --silent | --silen | --sile | --sil | --si | --s)
34745     ac_cs_silent=: ;;
34746
34747   # This is an error.
34748   -*) { echo "$as_me: error: unrecognized option: $1
34749 Try \`$0 --help' for more information." >&2
34750    { (exit 1); exit 1; }; } ;;
34751
34752   *) ac_config_targets="$ac_config_targets $1"
34753      ac_need_defaults=false ;;
34754
34755   esac
34756   shift
34757 done
34758
34759 ac_configure_extra_args=
34760
34761 if $ac_cs_silent; then
34762   exec 6>/dev/null
34763   ac_configure_extra_args="$ac_configure_extra_args --silent"
34764 fi
34765
34766 _ACEOF
34767 cat >>$CONFIG_STATUS <<_ACEOF
34768 if \$ac_cs_recheck; then
34769   echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
34770   CONFIG_SHELL=$SHELL
34771   export CONFIG_SHELL
34772   exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
34773 fi
34774
34775 _ACEOF
34776 cat >>$CONFIG_STATUS <<\_ACEOF
34777 exec 5>>config.log
34778 {
34779   echo
34780   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
34781 ## Running $as_me. ##
34782 _ASBOX
34783   echo "$ac_log"
34784 } >&5
34785
34786 _ACEOF
34787 cat >>$CONFIG_STATUS <<_ACEOF
34788 _ACEOF
34789
34790 cat >>$CONFIG_STATUS <<\_ACEOF
34791
34792 # Handling of arguments.
34793 for ac_config_target in $ac_config_targets
34794 do
34795   case $ac_config_target in
34796     "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
34797     "mpn/$tmp_fn.$tmp_ext") CONFIG_LINKS="$CONFIG_LINKS mpn/$tmp_fn.$tmp_ext:mpn/$tmp_dir/$tmp_base.$tmp_ext" ;;
34798     "gmp-mparam.h") CONFIG_LINKS="$CONFIG_LINKS gmp-mparam.h:mpn/$gmp_mparam_dir/gmp-mparam.h" ;;
34799     "demos/pexpr-config.h") CONFIG_FILES="$CONFIG_FILES demos/pexpr-config.h:demos/pexpr-config-h.in" ;;
34800     "demos/calc/calc-config.h") CONFIG_FILES="$CONFIG_FILES demos/calc/calc-config.h:demos/calc/calc-config-h.in" ;;
34801     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
34802     "mpbsd/Makefile") CONFIG_FILES="$CONFIG_FILES mpbsd/Makefile" ;;
34803     "mpf/Makefile") CONFIG_FILES="$CONFIG_FILES mpf/Makefile" ;;
34804     "mpn/Makefile") CONFIG_FILES="$CONFIG_FILES mpn/Makefile" ;;
34805     "mpq/Makefile") CONFIG_FILES="$CONFIG_FILES mpq/Makefile" ;;
34806     "mpz/Makefile") CONFIG_FILES="$CONFIG_FILES mpz/Makefile" ;;
34807     "printf/Makefile") CONFIG_FILES="$CONFIG_FILES printf/Makefile" ;;
34808     "scanf/Makefile") CONFIG_FILES="$CONFIG_FILES scanf/Makefile" ;;
34809     "cxx/Makefile") CONFIG_FILES="$CONFIG_FILES cxx/Makefile" ;;
34810     "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
34811     "tests/devel/Makefile") CONFIG_FILES="$CONFIG_FILES tests/devel/Makefile" ;;
34812     "tests/mpbsd/Makefile") CONFIG_FILES="$CONFIG_FILES tests/mpbsd/Makefile" ;;
34813     "tests/mpf/Makefile") CONFIG_FILES="$CONFIG_FILES tests/mpf/Makefile" ;;
34814     "tests/mpn/Makefile") CONFIG_FILES="$CONFIG_FILES tests/mpn/Makefile" ;;
34815     "tests/mpq/Makefile") CONFIG_FILES="$CONFIG_FILES tests/mpq/Makefile" ;;
34816     "tests/mpz/Makefile") CONFIG_FILES="$CONFIG_FILES tests/mpz/Makefile" ;;
34817     "tests/rand/Makefile") CONFIG_FILES="$CONFIG_FILES tests/rand/Makefile" ;;
34818     "tests/misc/Makefile") CONFIG_FILES="$CONFIG_FILES tests/misc/Makefile" ;;
34819     "tests/cxx/Makefile") CONFIG_FILES="$CONFIG_FILES tests/cxx/Makefile" ;;
34820     "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
34821     "tune/Makefile") CONFIG_FILES="$CONFIG_FILES tune/Makefile" ;;
34822     "demos/Makefile") CONFIG_FILES="$CONFIG_FILES demos/Makefile" ;;
34823     "demos/calc/Makefile") CONFIG_FILES="$CONFIG_FILES demos/calc/Makefile" ;;
34824     "demos/expr/Makefile") CONFIG_FILES="$CONFIG_FILES demos/expr/Makefile" ;;
34825     "gmp.h") CONFIG_FILES="$CONFIG_FILES gmp.h:gmp-h.in" ;;
34826     "mp.h") CONFIG_FILES="$CONFIG_FILES mp.h:mp-h.in" ;;
34827
34828   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
34829 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
34830    { (exit 1); exit 1; }; };;
34831   esac
34832 done
34833
34834
34835 # If the user did not use the arguments to specify the items to instantiate,
34836 # then the envvar interface is used.  Set only those that are not.
34837 # We use the long form for the default assignment because of an extremely
34838 # bizarre bug on SunOS 4.1.3.
34839 if $ac_need_defaults; then
34840   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
34841   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
34842   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
34843 fi
34844
34845 # Have a temporary directory for convenience.  Make it in the build tree
34846 # simply because there is no reason against having it here, and in addition,
34847 # creating and moving files from /tmp can sometimes cause problems.
34848 # Hook for its removal unless debugging.
34849 # Note that there is a small window in which the directory will not be cleaned:
34850 # after its creation but before its name has been assigned to `$tmp'.
34851 $debug ||
34852 {
34853   tmp=
34854   trap 'exit_status=$?
34855   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
34856 ' 0
34857   trap '{ (exit 1); exit 1; }' 1 2 13 15
34858 }
34859 # Create a (secure) tmp directory for tmp files.
34860
34861 {
34862   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
34863   test -n "$tmp" && test -d "$tmp"
34864 }  ||
34865 {
34866   tmp=./conf$$-$RANDOM
34867   (umask 077 && mkdir "$tmp")
34868 } ||
34869 {
34870    echo "$me: cannot create a temporary directory in ." >&2
34871    { (exit 1); exit 1; }
34872 }
34873
34874 #
34875 # Set up the sed scripts for CONFIG_FILES section.
34876 #
34877
34878 # No need to generate the scripts if there are no CONFIG_FILES.
34879 # This happens for instance when ./config.status config.h
34880 if test -n "$CONFIG_FILES"; then
34881
34882 _ACEOF
34883
34884
34885
34886 ac_delim='%!_!# '
34887 for ac_last_try in false false false false false :; do
34888   cat >conf$$subs.sed <<_ACEOF
34889 SHELL!$SHELL$ac_delim
34890 PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim
34891 PACKAGE_NAME!$PACKAGE_NAME$ac_delim
34892 PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim
34893 PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim
34894 PACKAGE_STRING!$PACKAGE_STRING$ac_delim
34895 PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim
34896 exec_prefix!$exec_prefix$ac_delim
34897 prefix!$prefix$ac_delim
34898 program_transform_name!$program_transform_name$ac_delim
34899 bindir!$bindir$ac_delim
34900 sbindir!$sbindir$ac_delim
34901 libexecdir!$libexecdir$ac_delim
34902 datarootdir!$datarootdir$ac_delim
34903 datadir!$datadir$ac_delim
34904 sysconfdir!$sysconfdir$ac_delim
34905 sharedstatedir!$sharedstatedir$ac_delim
34906 localstatedir!$localstatedir$ac_delim
34907 includedir!$includedir$ac_delim
34908 oldincludedir!$oldincludedir$ac_delim
34909 docdir!$docdir$ac_delim
34910 infodir!$infodir$ac_delim
34911 htmldir!$htmldir$ac_delim
34912 dvidir!$dvidir$ac_delim
34913 pdfdir!$pdfdir$ac_delim
34914 psdir!$psdir$ac_delim
34915 libdir!$libdir$ac_delim
34916 localedir!$localedir$ac_delim
34917 mandir!$mandir$ac_delim
34918 DEFS!$DEFS$ac_delim
34919 ECHO_C!$ECHO_C$ac_delim
34920 ECHO_N!$ECHO_N$ac_delim
34921 ECHO_T!$ECHO_T$ac_delim
34922 LIBS!$LIBS$ac_delim
34923 build_alias!$build_alias$ac_delim
34924 host_alias!$host_alias$ac_delim
34925 target_alias!$target_alias$ac_delim
34926 build!$build$ac_delim
34927 build_cpu!$build_cpu$ac_delim
34928 build_vendor!$build_vendor$ac_delim
34929 build_os!$build_os$ac_delim
34930 host!$host$ac_delim
34931 host_cpu!$host_cpu$ac_delim
34932 host_vendor!$host_vendor$ac_delim
34933 host_os!$host_os$ac_delim
34934 INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim
34935 INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim
34936 INSTALL_DATA!$INSTALL_DATA$ac_delim
34937 CYGPATH_W!$CYGPATH_W$ac_delim
34938 PACKAGE!$PACKAGE$ac_delim
34939 VERSION!$VERSION$ac_delim
34940 ACLOCAL!$ACLOCAL$ac_delim
34941 AUTOCONF!$AUTOCONF$ac_delim
34942 AUTOMAKE!$AUTOMAKE$ac_delim
34943 AUTOHEADER!$AUTOHEADER$ac_delim
34944 MAKEINFO!$MAKEINFO$ac_delim
34945 AMTAR!$AMTAR$ac_delim
34946 install_sh!$install_sh$ac_delim
34947 STRIP!$STRIP$ac_delim
34948 INSTALL_STRIP_PROGRAM!$INSTALL_STRIP_PROGRAM$ac_delim
34949 mkdir_p!$mkdir_p$ac_delim
34950 AWK!$AWK$ac_delim
34951 SET_MAKE!$SET_MAKE$ac_delim
34952 am__leading_dot!$am__leading_dot$ac_delim
34953 MAINTAINER_MODE_TRUE!$MAINTAINER_MODE_TRUE$ac_delim
34954 MAINTAINER_MODE_FALSE!$MAINTAINER_MODE_FALSE$ac_delim
34955 MAINT!$MAINT$ac_delim
34956 WANT_MPBSD_TRUE!$WANT_MPBSD_TRUE$ac_delim
34957 WANT_MPBSD_FALSE!$WANT_MPBSD_FALSE$ac_delim
34958 GMP_NAIL_BITS!$GMP_NAIL_BITS$ac_delim
34959 ABI!$ABI$ac_delim
34960 HAVE_HOST_CPU_FAMILY_power!$HAVE_HOST_CPU_FAMILY_power$ac_delim
34961 HAVE_HOST_CPU_FAMILY_powerpc!$HAVE_HOST_CPU_FAMILY_powerpc$ac_delim
34962 GMP_LDFLAGS!$GMP_LDFLAGS$ac_delim
34963 LIBGMP_LDFLAGS!$LIBGMP_LDFLAGS$ac_delim
34964 LIBGMPXX_LDFLAGS!$LIBGMPXX_LDFLAGS$ac_delim
34965 SPEED_CYCLECOUNTER_OBJ!$SPEED_CYCLECOUNTER_OBJ$ac_delim
34966 CALLING_CONVENTIONS_OBJS!$CALLING_CONVENTIONS_OBJS$ac_delim
34967 DEFN_LONG_LONG_LIMB!$DEFN_LONG_LONG_LIMB$ac_delim
34968 CC!$CC$ac_delim
34969 CFLAGS!$CFLAGS$ac_delim
34970 LDFLAGS!$LDFLAGS$ac_delim
34971 CPPFLAGS!$CPPFLAGS$ac_delim
34972 ac_ct_CC!$ac_ct_CC$ac_delim
34973 EXEEXT!$EXEEXT$ac_delim
34974 OBJEXT!$OBJEXT$ac_delim
34975 CPP!$CPP$ac_delim
34976 CC_FOR_BUILD!$CC_FOR_BUILD$ac_delim
34977 CPP_FOR_BUILD!$CPP_FOR_BUILD$ac_delim
34978 EXEEXT_FOR_BUILD!$EXEEXT_FOR_BUILD$ac_delim
34979 U_FOR_BUILD!$U_FOR_BUILD$ac_delim
34980 LIBM_FOR_BUILD!$LIBM_FOR_BUILD$ac_delim
34981 CCAS!$CCAS$ac_delim
34982 CXX!$CXX$ac_delim
34983 CXXFLAGS!$CXXFLAGS$ac_delim
34984 ac_ct_CXX!$ac_ct_CXX$ac_delim
34985 WANT_CXX_TRUE!$WANT_CXX_TRUE$ac_delim
34986 _ACEOF
34987
34988   if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
34989     break
34990   elif $ac_last_try; then
34991     { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
34992 echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
34993    { (exit 1); exit 1; }; }
34994   else
34995     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
34996   fi
34997 done
34998
34999 ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
35000 if test -n "$ac_eof"; then
35001   ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
35002   ac_eof=`expr $ac_eof + 1`
35003 fi
35004
35005 cat >>$CONFIG_STATUS <<_ACEOF
35006 cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof
35007 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
35008 _ACEOF
35009 sed '
35010 s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
35011 s/^/s,@/; s/!/@,|#_!!_#|/
35012 :n
35013 t n
35014 s/'"$ac_delim"'$/,g/; t
35015 s/$/\\/; p
35016 N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
35017 ' >>$CONFIG_STATUS <conf$$subs.sed
35018 rm -f conf$$subs.sed
35019 cat >>$CONFIG_STATUS <<_ACEOF
35020 CEOF$ac_eof
35021 _ACEOF
35022
35023
35024 ac_delim='%!_!# '
35025 for ac_last_try in false false false false false :; do
35026   cat >conf$$subs.sed <<_ACEOF
35027 WANT_CXX_FALSE!$WANT_CXX_FALSE$ac_delim
35028 CXXCPP!$CXXCPP$ac_delim
35029 GREP!$GREP$ac_delim
35030 EGREP!$EGREP$ac_delim
35031 U!$U$ac_delim
35032 ANSI2KNR!$ANSI2KNR$ac_delim
35033 ASMFLAGS!$ASMFLAGS$ac_delim
35034 AR!$AR$ac_delim
35035 LIBGMP_DLL!$LIBGMP_DLL$ac_delim
35036 SED!$SED$ac_delim
35037 LN_S!$LN_S$ac_delim
35038 ECHO!$ECHO$ac_delim
35039 RANLIB!$RANLIB$ac_delim
35040 DLLTOOL!$DLLTOOL$ac_delim
35041 AS!$AS$ac_delim
35042 OBJDUMP!$OBJDUMP$ac_delim
35043 LIBTOOL!$LIBTOOL$ac_delim
35044 ENABLE_STATIC_TRUE!$ENABLE_STATIC_TRUE$ac_delim
35045 ENABLE_STATIC_FALSE!$ENABLE_STATIC_FALSE$ac_delim
35046 LIBM!$LIBM$ac_delim
35047 TAL_OBJECT!$TAL_OBJECT$ac_delim
35048 M4!$M4$ac_delim
35049 BITS_PER_MP_LIMB!$BITS_PER_MP_LIMB$ac_delim
35050 mpn_objs_in_libmp!$mpn_objs_in_libmp$ac_delim
35051 mpn_objects!$mpn_objects$ac_delim
35052 mpn_objs_in_libgmp!$mpn_objs_in_libgmp$ac_delim
35053 gmp_srclinks!$gmp_srclinks$ac_delim
35054 TUNE_SQR_OBJ!$TUNE_SQR_OBJ$ac_delim
35055 HAVE_CLOCK_01!$HAVE_CLOCK_01$ac_delim
35056 HAVE_CPUTIME_01!$HAVE_CPUTIME_01$ac_delim
35057 HAVE_GETRUSAGE_01!$HAVE_GETRUSAGE_01$ac_delim
35058 HAVE_GETTIMEOFDAY_01!$HAVE_GETTIMEOFDAY_01$ac_delim
35059 HAVE_SIGACTION_01!$HAVE_SIGACTION_01$ac_delim
35060 HAVE_SIGALTSTACK_01!$HAVE_SIGALTSTACK_01$ac_delim
35061 HAVE_SIGSTACK_01!$HAVE_SIGSTACK_01$ac_delim
35062 HAVE_SYS_RESOURCE_H_01!$HAVE_SYS_RESOURCE_H_01$ac_delim
35063 HAVE_STACK_T_01!$HAVE_STACK_T_01$ac_delim
35064 LIBCURSES!$LIBCURSES$ac_delim
35065 WITH_READLINE_01!$WITH_READLINE_01$ac_delim
35066 LIBREADLINE!$LIBREADLINE$ac_delim
35067 YACC!$YACC$ac_delim
35068 YFLAGS!$YFLAGS$ac_delim
35069 LEX!$LEX$ac_delim
35070 LEX_OUTPUT_ROOT!$LEX_OUTPUT_ROOT$ac_delim
35071 LEXLIB!$LEXLIB$ac_delim
35072 LIBOBJS!$LIBOBJS$ac_delim
35073 LTLIBOBJS!$LTLIBOBJS$ac_delim
35074 _ACEOF
35075
35076   if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 47; then
35077     break
35078   elif $ac_last_try; then
35079     { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
35080 echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
35081    { (exit 1); exit 1; }; }
35082   else
35083     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
35084   fi
35085 done
35086
35087 ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
35088 if test -n "$ac_eof"; then
35089   ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
35090   ac_eof=`expr $ac_eof + 1`
35091 fi
35092
35093 cat >>$CONFIG_STATUS <<_ACEOF
35094 cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
35095 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
35096 _ACEOF
35097 sed '
35098 s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
35099 s/^/s,@/; s/!/@,|#_!!_#|/
35100 :n
35101 t n
35102 s/'"$ac_delim"'$/,g/; t
35103 s/$/\\/; p
35104 N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
35105 ' >>$CONFIG_STATUS <conf$$subs.sed
35106 rm -f conf$$subs.sed
35107 cat >>$CONFIG_STATUS <<_ACEOF
35108 :end
35109 s/|#_!!_#|//g
35110 CEOF$ac_eof
35111 _ACEOF
35112
35113
35114 # VPATH may cause trouble with some makes, so we remove $(srcdir),
35115 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
35116 # trailing colons and then remove the whole line if VPATH becomes empty
35117 # (actually we leave an empty line to preserve line numbers).
35118 if test "x$srcdir" = x.; then
35119   ac_vpsub='/^[  ]*VPATH[        ]*=/{
35120 s/:*\$(srcdir):*/:/
35121 s/:*\${srcdir}:*/:/
35122 s/:*@srcdir@:*/:/
35123 s/^\([^=]*=[     ]*\):*/\1/
35124 s/:*$//
35125 s/^[^=]*=[       ]*$//
35126 }'
35127 fi
35128
35129 cat >>$CONFIG_STATUS <<\_ACEOF
35130 fi # test -n "$CONFIG_FILES"
35131
35132
35133 for ac_tag in  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS
35134 do
35135   case $ac_tag in
35136   :[FHLC]) ac_mode=$ac_tag; continue;;
35137   esac
35138   case $ac_mode$ac_tag in
35139   :[FHL]*:*);;
35140   :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5
35141 echo "$as_me: error: Invalid tag $ac_tag." >&2;}
35142    { (exit 1); exit 1; }; };;
35143   :[FH]-) ac_tag=-:-;;
35144   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
35145   esac
35146   ac_save_IFS=$IFS
35147   IFS=:
35148   set x $ac_tag
35149   IFS=$ac_save_IFS
35150   shift
35151   ac_file=$1
35152   shift
35153
35154   case $ac_mode in
35155   :L) ac_source=$1;;
35156   :[FH])
35157     ac_file_inputs=
35158     for ac_f
35159     do
35160       case $ac_f in
35161       -) ac_f="$tmp/stdin";;
35162       *) # Look for the file first in the build tree, then in the source tree
35163          # (if the path is not absolute).  The absolute path cannot be DOS-style,
35164          # because $ac_f cannot contain `:'.
35165          test -f "$ac_f" ||
35166            case $ac_f in
35167            [\\/$]*) false;;
35168            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
35169            esac ||
35170            { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
35171 echo "$as_me: error: cannot find input file: $ac_f" >&2;}
35172    { (exit 1); exit 1; }; };;
35173       esac
35174       ac_file_inputs="$ac_file_inputs $ac_f"
35175     done
35176
35177     # Let's still pretend it is `configure' which instantiates (i.e., don't
35178     # use $as_me), people would be surprised to read:
35179     #    /* config.h.  Generated by config.status.  */
35180     configure_input="Generated from "`IFS=:
35181           echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure."
35182     if test x"$ac_file" != x-; then
35183       configure_input="$ac_file.  $configure_input"
35184       { echo "$as_me:$LINENO: creating $ac_file" >&5
35185 echo "$as_me: creating $ac_file" >&6;}
35186     fi
35187
35188     case $ac_tag in
35189     *:-:* | *:-) cat >"$tmp/stdin";;
35190     esac
35191     ;;
35192   esac
35193
35194   ac_dir=`$as_dirname -- "$ac_file" ||
35195 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35196          X"$ac_file" : 'X\(//\)[^/]' \| \
35197          X"$ac_file" : 'X\(//\)$' \| \
35198          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
35199 echo X"$ac_file" |
35200     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
35201             s//\1/
35202             q
35203           }
35204           /^X\(\/\/\)[^/].*/{
35205             s//\1/
35206             q
35207           }
35208           /^X\(\/\/\)$/{
35209             s//\1/
35210             q
35211           }
35212           /^X\(\/\).*/{
35213             s//\1/
35214             q
35215           }
35216           s/.*/./; q'`
35217   { as_dir="$ac_dir"
35218   case $as_dir in #(
35219   -*) as_dir=./$as_dir;;
35220   esac
35221   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
35222     as_dirs=
35223     while :; do
35224       case $as_dir in #(
35225       *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
35226       *) as_qdir=$as_dir;;
35227       esac
35228       as_dirs="'$as_qdir' $as_dirs"
35229       as_dir=`$as_dirname -- "$as_dir" ||
35230 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35231          X"$as_dir" : 'X\(//\)[^/]' \| \
35232          X"$as_dir" : 'X\(//\)$' \| \
35233          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
35234 echo X"$as_dir" |
35235     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
35236             s//\1/
35237             q
35238           }
35239           /^X\(\/\/\)[^/].*/{
35240             s//\1/
35241             q
35242           }
35243           /^X\(\/\/\)$/{
35244             s//\1/
35245             q
35246           }
35247           /^X\(\/\).*/{
35248             s//\1/
35249             q
35250           }
35251           s/.*/./; q'`
35252       test -d "$as_dir" && break
35253     done
35254     test -z "$as_dirs" || eval "mkdir $as_dirs"
35255   } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
35256 echo "$as_me: error: cannot create directory $as_dir" >&2;}
35257    { (exit 1); exit 1; }; }; }
35258   ac_builddir=.
35259
35260 case "$ac_dir" in
35261 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
35262 *)
35263   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
35264   # A ".." for each directory in $ac_dir_suffix.
35265   ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
35266   case $ac_top_builddir_sub in
35267   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
35268   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
35269   esac ;;
35270 esac
35271 ac_abs_top_builddir=$ac_pwd
35272 ac_abs_builddir=$ac_pwd$ac_dir_suffix
35273 # for backward compatibility:
35274 ac_top_builddir=$ac_top_build_prefix
35275
35276 case $srcdir in
35277   .)  # We are building in place.
35278     ac_srcdir=.
35279     ac_top_srcdir=$ac_top_builddir_sub
35280     ac_abs_top_srcdir=$ac_pwd ;;
35281   [\\/]* | ?:[\\/]* )  # Absolute name.
35282     ac_srcdir=$srcdir$ac_dir_suffix;
35283     ac_top_srcdir=$srcdir
35284     ac_abs_top_srcdir=$srcdir ;;
35285   *) # Relative name.
35286     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
35287     ac_top_srcdir=$ac_top_build_prefix$srcdir
35288     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
35289 esac
35290 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
35291
35292
35293   case $ac_mode in
35294   :F)
35295   #
35296   # CONFIG_FILE
35297   #
35298
35299   case $INSTALL in
35300   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
35301   *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
35302   esac
35303 _ACEOF
35304
35305 cat >>$CONFIG_STATUS <<\_ACEOF
35306 # If the template does not know about datarootdir, expand it.
35307 # FIXME: This hack should be removed a few years after 2.60.
35308 ac_datarootdir_hack=; ac_datarootdir_seen=
35309
35310 case `sed -n '/datarootdir/ {
35311   p
35312   q
35313 }
35314 /@datadir@/p
35315 /@docdir@/p
35316 /@infodir@/p
35317 /@localedir@/p
35318 /@mandir@/p
35319 ' $ac_file_inputs` in
35320 *datarootdir*) ac_datarootdir_seen=yes;;
35321 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
35322   { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
35323 echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
35324 _ACEOF
35325 cat >>$CONFIG_STATUS <<_ACEOF
35326   ac_datarootdir_hack='
35327   s&@datadir@&$datadir&g
35328   s&@docdir@&$docdir&g
35329   s&@infodir@&$infodir&g
35330   s&@localedir@&$localedir&g
35331   s&@mandir@&$mandir&g
35332     s&\\\${datarootdir}&$datarootdir&g' ;;
35333 esac
35334 _ACEOF
35335
35336 # Neutralize VPATH when `$srcdir' = `.'.
35337 # Shell code in configure.ac might set extrasub.
35338 # FIXME: do we really want to maintain this feature?
35339 cat >>$CONFIG_STATUS <<_ACEOF
35340   sed "$ac_vpsub
35341 $extrasub
35342 _ACEOF
35343 cat >>$CONFIG_STATUS <<\_ACEOF
35344 :t
35345 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
35346 s&@configure_input@&$configure_input&;t t
35347 s&@top_builddir@&$ac_top_builddir_sub&;t t
35348 s&@srcdir@&$ac_srcdir&;t t
35349 s&@abs_srcdir@&$ac_abs_srcdir&;t t
35350 s&@top_srcdir@&$ac_top_srcdir&;t t
35351 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
35352 s&@builddir@&$ac_builddir&;t t
35353 s&@abs_builddir@&$ac_abs_builddir&;t t
35354 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
35355 s&@INSTALL@&$ac_INSTALL&;t t
35356 $ac_datarootdir_hack
35357 " $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
35358
35359 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
35360   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
35361   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
35362   { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
35363 which seems to be undefined.  Please make sure it is defined." >&5
35364 echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
35365 which seems to be undefined.  Please make sure it is defined." >&2;}
35366
35367   rm -f "$tmp/stdin"
35368   case $ac_file in
35369   -) cat "$tmp/out"; rm -f "$tmp/out";;
35370   *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;;
35371   esac
35372  ;;
35373   :H)
35374   #
35375   # CONFIG_HEADER
35376   #
35377 _ACEOF
35378
35379 # Transform confdefs.h into a sed script `conftest.defines', that
35380 # substitutes the proper values into config.h.in to produce config.h.
35381 rm -f conftest.defines conftest.tail
35382 # First, append a space to every undef/define line, to ease matching.
35383 echo 's/$/ /' >conftest.defines
35384 # Then, protect against being on the right side of a sed subst, or in
35385 # an unquoted here document, in config.status.  If some macros were
35386 # called several times there might be several #defines for the same
35387 # symbol, which is useless.  But do not sort them, since the last
35388 # AC_DEFINE must be honored.
35389 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
35390 # These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where
35391 # NAME is the cpp macro being defined, VALUE is the value it is being given.
35392 # PARAMS is the parameter list in the macro definition--in most cases, it's
35393 # just an empty string.
35394 ac_dA='s,^\\([   #]*\\)[^        ]*\\([  ]*'
35395 ac_dB='\\)[      (].*,\\1define\\2'
35396 ac_dC=' '
35397 ac_dD=' ,'
35398
35399 uniq confdefs.h |
35400   sed -n '
35401         t rset
35402         :rset
35403         s/^[     ]*#[    ]*define[       ][      ]*//
35404         t ok
35405         d
35406         :ok
35407         s/[\\&,]/\\&/g
35408         s/^\('"$ac_word_re"'\)\(([^()]*)\)[      ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p
35409         s/^\('"$ac_word_re"'\)[  ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p
35410   ' >>conftest.defines
35411
35412 # Remove the space that was appended to ease matching.
35413 # Then replace #undef with comments.  This is necessary, for
35414 # example, in the case of _POSIX_SOURCE, which is predefined and required
35415 # on some systems where configure will not decide to define it.
35416 # (The regexp can be short, since the line contains either #define or #undef.)
35417 echo 's/ $//
35418 s,^[     #]*u.*,/* & */,' >>conftest.defines
35419
35420 # Break up conftest.defines:
35421 ac_max_sed_lines=50
35422
35423 # First sed command is:  sed -f defines.sed $ac_file_inputs >"$tmp/out1"
35424 # Second one is:         sed -f defines.sed "$tmp/out1" >"$tmp/out2"
35425 # Third one will be:     sed -f defines.sed "$tmp/out2" >"$tmp/out1"
35426 # et cetera.
35427 ac_in='$ac_file_inputs'
35428 ac_out='"$tmp/out1"'
35429 ac_nxt='"$tmp/out2"'
35430
35431 while :
35432 do
35433   # Write a here document:
35434     cat >>$CONFIG_STATUS <<_ACEOF
35435     # First, check the format of the line:
35436     cat >"\$tmp/defines.sed" <<\\CEOF
35437 /^[      ]*#[    ]*undef[        ][      ]*$ac_word_re[  ]*\$/b def
35438 /^[      ]*#[    ]*define[       ][      ]*$ac_word_re[(         ]/b def
35439 b
35440 :def
35441 _ACEOF
35442   sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS
35443   echo 'CEOF
35444     sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS
35445   ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in
35446   sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail
35447   grep . conftest.tail >/dev/null || break
35448   rm -f conftest.defines
35449   mv conftest.tail conftest.defines
35450 done
35451 rm -f conftest.defines conftest.tail
35452
35453 echo "ac_result=$ac_in" >>$CONFIG_STATUS
35454 cat >>$CONFIG_STATUS <<\_ACEOF
35455   if test x"$ac_file" != x-; then
35456     echo "/* $configure_input  */" >"$tmp/config.h"
35457     cat "$ac_result" >>"$tmp/config.h"
35458     if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then
35459       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
35460 echo "$as_me: $ac_file is unchanged" >&6;}
35461     else
35462       rm -f $ac_file
35463       mv "$tmp/config.h" $ac_file
35464     fi
35465   else
35466     echo "/* $configure_input  */"
35467     cat "$ac_result"
35468   fi
35469   rm -f "$tmp/out12"
35470 # Compute $ac_file's index in $config_headers.
35471 _am_stamp_count=1
35472 for _am_header in $config_headers :; do
35473   case $_am_header in
35474     $ac_file | $ac_file:* )
35475       break ;;
35476     * )
35477       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
35478   esac
35479 done
35480 echo "timestamp for $ac_file" >`$as_dirname -- $ac_file ||
35481 $as_expr X$ac_file : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
35482          X$ac_file : 'X\(//\)[^/]' \| \
35483          X$ac_file : 'X\(//\)$' \| \
35484          X$ac_file : 'X\(/\)' \| . 2>/dev/null ||
35485 echo X$ac_file |
35486     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
35487             s//\1/
35488             q
35489           }
35490           /^X\(\/\/\)[^/].*/{
35491             s//\1/
35492             q
35493           }
35494           /^X\(\/\/\)$/{
35495             s//\1/
35496             q
35497           }
35498           /^X\(\/\).*/{
35499             s//\1/
35500             q
35501           }
35502           s/.*/./; q'`/stamp-h$_am_stamp_count
35503  ;;
35504   :L)
35505   #
35506   # CONFIG_LINK
35507   #
35508
35509   { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_file" >&5
35510 echo "$as_me: linking $srcdir/$ac_source to $ac_file" >&6;}
35511
35512   if test ! -r "$srcdir/$ac_source"; then
35513     { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
35514 echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
35515    { (exit 1); exit 1; }; }
35516   fi
35517   rm -f "$ac_file"
35518
35519   # Try a relative symlink, then a hard link, then a copy.
35520   case $srcdir in
35521   [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
35522       *) ac_rel_source=$ac_top_build_prefix$srcdir/$ac_source ;;
35523   esac
35524   ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
35525     ln "$srcdir/$ac_source" "$ac_file" 2>/dev/null ||
35526     cp -p "$srcdir/$ac_source" "$ac_file" ||
35527     { { echo "$as_me:$LINENO: error: cannot link or copy $srcdir/$ac_source to $ac_file" >&5
35528 echo "$as_me: error: cannot link or copy $srcdir/$ac_source to $ac_file" >&2;}
35529    { (exit 1); exit 1; }; }
35530  ;;
35531
35532   esac
35533
35534 done # for ac_tag
35535
35536
35537 { (exit 0); exit 0; }
35538 _ACEOF
35539 chmod +x $CONFIG_STATUS
35540 ac_clean_files=$ac_clean_files_save
35541
35542
35543 # configure is writing to config.log, and then calls config.status.
35544 # config.status does its own redirection, appending to config.log.
35545 # Unfortunately, on DOS this fails, as config.log is still kept open
35546 # by configure, so config.status won't be able to write to it; its
35547 # output is simply discarded.  So we exec the FD to /dev/null,
35548 # effectively closing config.log, so it can be properly (re)opened and
35549 # appended to by config.status.  When coming back to configure, we
35550 # need to make the FD available again.
35551 if test "$no_create" != yes; then
35552   ac_cs_success=:
35553   ac_config_status_args=
35554   test "$silent" = yes &&
35555     ac_config_status_args="$ac_config_status_args --quiet"
35556   exec 5>/dev/null
35557   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
35558   exec 5>>config.log
35559   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
35560   # would make configure fail if this is the last instruction.
35561   $ac_cs_success || { (exit 1); exit 1; }
35562 fi
35563