Set zvol discard_granularity to the volblocksize.
[zfs.git] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.63.
4 #
5 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
6 # 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
7 # This configure script is free software; the Free Software Foundation
8 # gives unlimited permission to copy, distribute and modify it.
9 ## --------------------- ##
10 ## M4sh Initialization.  ##
11 ## --------------------- ##
12
13 # Be more Bourne compatible
14 DUALCASE=1; export DUALCASE # for MKS sh
15 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
16   emulate sh
17   NULLCMD=:
18   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
19   # is contrary to our usage.  Disable this feature.
20   alias -g '${1+"$@"}'='"$@"'
21   setopt NO_GLOB_SUBST
22 else
23   case `(set -o) 2>/dev/null` in
24   *posix*) set -o posix ;;
25 esac
26
27 fi
28
29
30
31
32 # PATH needs CR
33 # Avoid depending upon Character Ranges.
34 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
35 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
36 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
37 as_cr_digits='0123456789'
38 as_cr_alnum=$as_cr_Letters$as_cr_digits
39
40 as_nl='
41 '
42 export as_nl
43 # Printing a long string crashes Solaris 7 /usr/bin/printf.
44 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
45 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
46 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
47 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
48   as_echo='printf %s\n'
49   as_echo_n='printf %s'
50 else
51   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
52     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
53     as_echo_n='/usr/ucb/echo -n'
54   else
55     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
56     as_echo_n_body='eval
57       arg=$1;
58       case $arg in
59       *"$as_nl"*)
60         expr "X$arg" : "X\\(.*\\)$as_nl";
61         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
62       esac;
63       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
64     '
65     export as_echo_n_body
66     as_echo_n='sh -c $as_echo_n_body as_echo'
67   fi
68   export as_echo_body
69   as_echo='sh -c $as_echo_body as_echo'
70 fi
71
72 # The user is always right.
73 if test "${PATH_SEPARATOR+set}" != set; then
74   PATH_SEPARATOR=:
75   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
76     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
77       PATH_SEPARATOR=';'
78   }
79 fi
80
81 # Support unset when possible.
82 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
83   as_unset=unset
84 else
85   as_unset=false
86 fi
87
88
89 # IFS
90 # We need space, tab and new line, in precisely that order.  Quoting is
91 # there to prevent editors from complaining about space-tab.
92 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
93 # splitting by setting IFS to empty value.)
94 IFS=" ""        $as_nl"
95
96 # Find who we are.  Look in the path if we contain no directory separator.
97 case $0 in
98   *[\\/]* ) as_myself=$0 ;;
99   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
100 for as_dir in $PATH
101 do
102   IFS=$as_save_IFS
103   test -z "$as_dir" && as_dir=.
104   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
105 done
106 IFS=$as_save_IFS
107
108      ;;
109 esac
110 # We did not find ourselves, most probably we were run as `sh COMMAND'
111 # in which case we are not to be found in the path.
112 if test "x$as_myself" = x; then
113   as_myself=$0
114 fi
115 if test ! -f "$as_myself"; then
116   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
117   { (exit 1); exit 1; }
118 fi
119
120 # Work around bugs in pre-3.0 UWIN ksh.
121 for as_var in ENV MAIL MAILPATH
122 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
123 done
124 PS1='$ '
125 PS2='> '
126 PS4='+ '
127
128 # NLS nuisances.
129 LC_ALL=C
130 export LC_ALL
131 LANGUAGE=C
132 export LANGUAGE
133
134 # Required to use basename.
135 if expr a : '\(a\)' >/dev/null 2>&1 &&
136    test "X`expr 00001 : '.*\(...\)'`" = X001; then
137   as_expr=expr
138 else
139   as_expr=false
140 fi
141
142 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
143   as_basename=basename
144 else
145   as_basename=false
146 fi
147
148
149 # Name of the executable.
150 as_me=`$as_basename -- "$0" ||
151 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
152          X"$0" : 'X\(//\)$' \| \
153          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
154 $as_echo X/"$0" |
155     sed '/^.*\/\([^/][^/]*\)\/*$/{
156             s//\1/
157             q
158           }
159           /^X\/\(\/\/\)$/{
160             s//\1/
161             q
162           }
163           /^X\/\(\/\).*/{
164             s//\1/
165             q
166           }
167           s/.*/./; q'`
168
169 # CDPATH.
170 $as_unset CDPATH
171
172
173 if test "x$CONFIG_SHELL" = x; then
174   if (eval ":") 2>/dev/null; then
175   as_have_required=yes
176 else
177   as_have_required=no
178 fi
179
180   if test $as_have_required = yes &&     (eval ":
181 (as_func_return () {
182   (exit \$1)
183 }
184 as_func_success () {
185   as_func_return 0
186 }
187 as_func_failure () {
188   as_func_return 1
189 }
190 as_func_ret_success () {
191   return 0
192 }
193 as_func_ret_failure () {
194   return 1
195 }
196
197 exitcode=0
198 if as_func_success; then
199   :
200 else
201   exitcode=1
202   echo as_func_success failed.
203 fi
204
205 if as_func_failure; then
206   exitcode=1
207   echo as_func_failure succeeded.
208 fi
209
210 if as_func_ret_success; then
211   :
212 else
213   exitcode=1
214   echo as_func_ret_success failed.
215 fi
216
217 if as_func_ret_failure; then
218   exitcode=1
219   echo as_func_ret_failure succeeded.
220 fi
221
222 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
223   :
224 else
225   exitcode=1
226   echo positional parameters were not saved.
227 fi
228
229 test \$exitcode = 0) || { (exit 1); exit 1; }
230
231 (
232   as_lineno_1=\$LINENO
233   as_lineno_2=\$LINENO
234   test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
235   test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
236 ") 2> /dev/null; then
237   :
238 else
239   as_candidate_shells=
240     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
241 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
242 do
243   IFS=$as_save_IFS
244   test -z "$as_dir" && as_dir=.
245   case $as_dir in
246          /*)
247            for as_base in sh bash ksh sh5; do
248              as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
249            done;;
250        esac
251 done
252 IFS=$as_save_IFS
253
254
255       for as_shell in $as_candidate_shells $SHELL; do
256          # Try only shells that exist, to save several forks.
257          if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
258                 { ("$as_shell") 2> /dev/null <<\_ASEOF
259 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
260   emulate sh
261   NULLCMD=:
262   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
263   # is contrary to our usage.  Disable this feature.
264   alias -g '${1+"$@"}'='"$@"'
265   setopt NO_GLOB_SUBST
266 else
267   case `(set -o) 2>/dev/null` in
268   *posix*) set -o posix ;;
269 esac
270
271 fi
272
273
274 :
275 _ASEOF
276 }; then
277   CONFIG_SHELL=$as_shell
278                as_have_required=yes
279                if { "$as_shell" 2> /dev/null <<\_ASEOF
280 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
281   emulate sh
282   NULLCMD=:
283   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
284   # is contrary to our usage.  Disable this feature.
285   alias -g '${1+"$@"}'='"$@"'
286   setopt NO_GLOB_SUBST
287 else
288   case `(set -o) 2>/dev/null` in
289   *posix*) set -o posix ;;
290 esac
291
292 fi
293
294
295 :
296 (as_func_return () {
297   (exit $1)
298 }
299 as_func_success () {
300   as_func_return 0
301 }
302 as_func_failure () {
303   as_func_return 1
304 }
305 as_func_ret_success () {
306   return 0
307 }
308 as_func_ret_failure () {
309   return 1
310 }
311
312 exitcode=0
313 if as_func_success; then
314   :
315 else
316   exitcode=1
317   echo as_func_success failed.
318 fi
319
320 if as_func_failure; then
321   exitcode=1
322   echo as_func_failure succeeded.
323 fi
324
325 if as_func_ret_success; then
326   :
327 else
328   exitcode=1
329   echo as_func_ret_success failed.
330 fi
331
332 if as_func_ret_failure; then
333   exitcode=1
334   echo as_func_ret_failure succeeded.
335 fi
336
337 if ( set x; as_func_ret_success y && test x = "$1" ); then
338   :
339 else
340   exitcode=1
341   echo positional parameters were not saved.
342 fi
343
344 test $exitcode = 0) || { (exit 1); exit 1; }
345
346 (
347   as_lineno_1=$LINENO
348   as_lineno_2=$LINENO
349   test "x$as_lineno_1" != "x$as_lineno_2" &&
350   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
351
352 _ASEOF
353 }; then
354   break
355 fi
356
357 fi
358
359       done
360
361       if test "x$CONFIG_SHELL" != x; then
362   for as_var in BASH_ENV ENV
363         do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
364         done
365         export CONFIG_SHELL
366         exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
367 fi
368
369
370     if test $as_have_required = no; then
371   echo This script requires a shell more modern than all the
372       echo shells that I found on your system.  Please install a
373       echo modern shell, or manually run the script under such a
374       echo shell if you do have one.
375       { (exit 1); exit 1; }
376 fi
377
378
379 fi
380
381 fi
382
383
384
385 (eval "as_func_return () {
386   (exit \$1)
387 }
388 as_func_success () {
389   as_func_return 0
390 }
391 as_func_failure () {
392   as_func_return 1
393 }
394 as_func_ret_success () {
395   return 0
396 }
397 as_func_ret_failure () {
398   return 1
399 }
400
401 exitcode=0
402 if as_func_success; then
403   :
404 else
405   exitcode=1
406   echo as_func_success failed.
407 fi
408
409 if as_func_failure; then
410   exitcode=1
411   echo as_func_failure succeeded.
412 fi
413
414 if as_func_ret_success; then
415   :
416 else
417   exitcode=1
418   echo as_func_ret_success failed.
419 fi
420
421 if as_func_ret_failure; then
422   exitcode=1
423   echo as_func_ret_failure succeeded.
424 fi
425
426 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
427   :
428 else
429   exitcode=1
430   echo positional parameters were not saved.
431 fi
432
433 test \$exitcode = 0") || {
434   echo No shell found that supports shell functions.
435   echo Please tell bug-autoconf@gnu.org about your system,
436   echo including any error possibly output before this message.
437   echo This can help us improve future autoconf versions.
438   echo Configuration will now proceed without shell functions.
439 }
440
441
442
443   as_lineno_1=$LINENO
444   as_lineno_2=$LINENO
445   test "x$as_lineno_1" != "x$as_lineno_2" &&
446   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
447
448   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
449   # uniformly replaced by the line number.  The first 'sed' inserts a
450   # line-number line after each line using $LINENO; the second 'sed'
451   # does the real work.  The second script uses 'N' to pair each
452   # line-number line with the line containing $LINENO, and appends
453   # trailing '-' during substitution so that $LINENO is not a special
454   # case at line end.
455   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
456   # scripts with optimization help from Paolo Bonzini.  Blame Lee
457   # E. McMahon (1931-1989) for sed's syntax.  :-)
458   sed -n '
459     p
460     /[$]LINENO/=
461   ' <$as_myself |
462     sed '
463       s/[$]LINENO.*/&-/
464       t lineno
465       b
466       :lineno
467       N
468       :loop
469       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
470       t loop
471       s/-\n.*//
472     ' >$as_me.lineno &&
473   chmod +x "$as_me.lineno" ||
474     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
475    { (exit 1); exit 1; }; }
476
477   # Don't try to exec as it changes $[0], causing all sort of problems
478   # (the dirname of $[0] is not the place where we might find the
479   # original and so on.  Autoconf is especially sensitive to this).
480   . "./$as_me.lineno"
481   # Exit status is that of the last command.
482   exit
483 }
484
485
486 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
487   as_dirname=dirname
488 else
489   as_dirname=false
490 fi
491
492 ECHO_C= ECHO_N= ECHO_T=
493 case `echo -n x` in
494 -n*)
495   case `echo 'x\c'` in
496   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
497   *)   ECHO_C='\c';;
498   esac;;
499 *)
500   ECHO_N='-n';;
501 esac
502 if expr a : '\(a\)' >/dev/null 2>&1 &&
503    test "X`expr 00001 : '.*\(...\)'`" = X001; then
504   as_expr=expr
505 else
506   as_expr=false
507 fi
508
509 rm -f conf$$ conf$$.exe conf$$.file
510 if test -d conf$$.dir; then
511   rm -f conf$$.dir/conf$$.file
512 else
513   rm -f conf$$.dir
514   mkdir conf$$.dir 2>/dev/null
515 fi
516 if (echo >conf$$.file) 2>/dev/null; then
517   if ln -s conf$$.file conf$$ 2>/dev/null; then
518     as_ln_s='ln -s'
519     # ... but there are two gotchas:
520     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
521     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
522     # In both cases, we have to default to `cp -p'.
523     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
524       as_ln_s='cp -p'
525   elif ln conf$$.file conf$$ 2>/dev/null; then
526     as_ln_s=ln
527   else
528     as_ln_s='cp -p'
529   fi
530 else
531   as_ln_s='cp -p'
532 fi
533 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
534 rmdir conf$$.dir 2>/dev/null
535
536 if mkdir -p . 2>/dev/null; then
537   as_mkdir_p=:
538 else
539   test -d ./-p && rmdir ./-p
540   as_mkdir_p=false
541 fi
542
543 if test -x / >/dev/null 2>&1; then
544   as_test_x='test -x'
545 else
546   if ls -dL / >/dev/null 2>&1; then
547     as_ls_L_option=L
548   else
549     as_ls_L_option=
550   fi
551   as_test_x='
552     eval sh -c '\''
553       if test -d "$1"; then
554         test -d "$1/.";
555       else
556         case $1 in
557         -*)set "./$1";;
558         esac;
559         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
560         ???[sx]*):;;*)false;;esac;fi
561     '\'' sh
562   '
563 fi
564 as_executable_p=$as_test_x
565
566 # Sed expression to map a string onto a valid CPP name.
567 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
568
569 # Sed expression to map a string onto a valid variable name.
570 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
571
572
573
574
575 # Check that we are running under the correct shell.
576 SHELL=${CONFIG_SHELL-/bin/sh}
577
578 case X$lt_ECHO in
579 X*--fallback-echo)
580   # Remove one level of quotation (which was required for Make).
581   ECHO=`echo "$lt_ECHO" | sed 's,\\\\\$\\$0,'$0','`
582   ;;
583 esac
584
585 ECHO=${lt_ECHO-echo}
586 if test "X$1" = X--no-reexec; then
587   # Discard the --no-reexec flag, and continue.
588   shift
589 elif test "X$1" = X--fallback-echo; then
590   # Avoid inline document here, it may be left over
591   :
592 elif test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' ; then
593   # Yippee, $ECHO works!
594   :
595 else
596   # Restart under the correct shell.
597   exec $SHELL "$0" --no-reexec ${1+"$@"}
598 fi
599
600 if test "X$1" = X--fallback-echo; then
601   # used as fallback echo
602   shift
603   cat <<_LT_EOF
604 $*
605 _LT_EOF
606   exit 0
607 fi
608
609 # The HP-UX ksh and POSIX shell print the target directory to stdout
610 # if CDPATH is set.
611 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
612
613 if test -z "$lt_ECHO"; then
614   if test "X${echo_test_string+set}" != Xset; then
615     # find a string as large as possible, as long as the shell can cope with it
616     for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do
617       # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ...
618       if { echo_test_string=`eval $cmd`; } 2>/dev/null &&
619          { test "X$echo_test_string" = "X$echo_test_string"; } 2>/dev/null
620       then
621         break
622       fi
623     done
624   fi
625
626   if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
627      echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
628      test "X$echo_testing_string" = "X$echo_test_string"; then
629     :
630   else
631     # The Solaris, AIX, and Digital Unix default echo programs unquote
632     # backslashes.  This makes it impossible to quote backslashes using
633     #   echo "$something" | sed 's/\\/\\\\/g'
634     #
635     # So, first we look for a working echo in the user's PATH.
636
637     lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
638     for dir in $PATH /usr/ucb; do
639       IFS="$lt_save_ifs"
640       if (test -f $dir/echo || test -f $dir/echo$ac_exeext) &&
641          test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' &&
642          echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` &&
643          test "X$echo_testing_string" = "X$echo_test_string"; then
644         ECHO="$dir/echo"
645         break
646       fi
647     done
648     IFS="$lt_save_ifs"
649
650     if test "X$ECHO" = Xecho; then
651       # We didn't find a better echo, so look for alternatives.
652       if test "X`{ print -r '\t'; } 2>/dev/null`" = 'X\t' &&
653          echo_testing_string=`{ print -r "$echo_test_string"; } 2>/dev/null` &&
654          test "X$echo_testing_string" = "X$echo_test_string"; then
655         # This shell has a builtin print -r that does the trick.
656         ECHO='print -r'
657       elif { test -f /bin/ksh || test -f /bin/ksh$ac_exeext; } &&
658            test "X$CONFIG_SHELL" != X/bin/ksh; then
659         # If we have ksh, try running configure again with it.
660         ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
661         export ORIGINAL_CONFIG_SHELL
662         CONFIG_SHELL=/bin/ksh
663         export CONFIG_SHELL
664         exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"}
665       else
666         # Try using printf.
667         ECHO='printf %s\n'
668         if test "X`{ $ECHO '\t'; } 2>/dev/null`" = 'X\t' &&
669            echo_testing_string=`{ $ECHO "$echo_test_string"; } 2>/dev/null` &&
670            test "X$echo_testing_string" = "X$echo_test_string"; then
671           # Cool, printf works
672           :
673         elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
674              test "X$echo_testing_string" = 'X\t' &&
675              echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
676              test "X$echo_testing_string" = "X$echo_test_string"; then
677           CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL
678           export CONFIG_SHELL
679           SHELL="$CONFIG_SHELL"
680           export SHELL
681           ECHO="$CONFIG_SHELL $0 --fallback-echo"
682         elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` &&
683              test "X$echo_testing_string" = 'X\t' &&
684              echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` &&
685              test "X$echo_testing_string" = "X$echo_test_string"; then
686           ECHO="$CONFIG_SHELL $0 --fallback-echo"
687         else
688           # maybe with a smaller string...
689           prev=:
690
691           for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do
692             if { test "X$echo_test_string" = "X`eval $cmd`"; } 2>/dev/null
693             then
694               break
695             fi
696             prev="$cmd"
697           done
698
699           if test "$prev" != 'sed 50q "$0"'; then
700             echo_test_string=`eval $prev`
701             export echo_test_string
702             exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"}
703           else
704             # Oops.  We lost completely, so just stick with echo.
705             ECHO=echo
706           fi
707         fi
708       fi
709     fi
710   fi
711 fi
712
713 # Copy echo and quote the copy suitably for passing to libtool from
714 # the Makefile, instead of quoting the original, which is used later.
715 lt_ECHO=$ECHO
716 if test "X$lt_ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then
717    lt_ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo"
718 fi
719
720
721
722
723 exec 7<&0 </dev/null 6>&1
724
725 # Name of the host.
726 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
727 # so uname gets run too.
728 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
729
730 #
731 # Initializations.
732 #
733 ac_default_prefix=/usr/local
734 ac_clean_files=
735 ac_config_libobj_dir=.
736 LIBOBJS=
737 cross_compiling=no
738 subdirs=
739 MFLAGS=
740 MAKEFLAGS=
741 SHELL=${CONFIG_SHELL-/bin/sh}
742
743 # Identity of this package.
744 PACKAGE_NAME=
745 PACKAGE_TARNAME=
746 PACKAGE_VERSION=
747 PACKAGE_STRING=
748 PACKAGE_BUGREPORT=
749
750 # Factoring default headers for most tests.
751 ac_includes_default="\
752 #include <stdio.h>
753 #ifdef HAVE_SYS_TYPES_H
754 # include <sys/types.h>
755 #endif
756 #ifdef HAVE_SYS_STAT_H
757 # include <sys/stat.h>
758 #endif
759 #ifdef STDC_HEADERS
760 # include <stdlib.h>
761 # include <stddef.h>
762 #else
763 # ifdef HAVE_STDLIB_H
764 #  include <stdlib.h>
765 # endif
766 #endif
767 #ifdef HAVE_STRING_H
768 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
769 #  include <memory.h>
770 # endif
771 # include <string.h>
772 #endif
773 #ifdef HAVE_STRINGS_H
774 # include <strings.h>
775 #endif
776 #ifdef HAVE_INTTYPES_H
777 # include <inttypes.h>
778 #endif
779 #ifdef HAVE_STDINT_H
780 # include <stdint.h>
781 #endif
782 #ifdef HAVE_UNISTD_H
783 # include <unistd.h>
784 #endif"
785
786 ac_subst_vars='am__EXEEXT_FALSE
787 am__EXEEXT_TRUE
788 LTLIBOBJS
789 LIBOBJS
790 DEBUG_DMU_TX
791 DEBUG_ZFS
792 DEBUG_STACKFLAGS
793 DEBUG_CFLAGS
794 CONFIG_KERNEL_FALSE
795 CONFIG_KERNEL_TRUE
796 CONFIG_USER_FALSE
797 CONFIG_USER_TRUE
798 FRAME_LARGER_THAN
799 LIBSELINUX
800 LIBBLKID
801 LIBUUID
802 ZLIB
803 udevruledir
804 udevdir
805 KERNELCPPFLAGS
806 KERNELMAKE_PARAMS
807 SPL_SYMBOLS
808 SPL_VERSION
809 SPL_OBJ
810 SPL
811 LINUX_SYMBOLS
812 LINUX_VERSION
813 LINUX_OBJ
814 LINUX
815 NO_UNUSED_BUT_SET_VARIABLE
816 ZFS_CONFIG
817 TARGET_ASM_DIR
818 MAKEPKG_VERSION
819 MAKEPKG
820 HAVE_MAKEPKG
821 PACMAN_VERSION
822 PACMAN
823 HAVE_PACMAN
824 ALIEN_VERSION
825 ALIEN
826 HAVE_ALIEN
827 DPKGBUILD_VERSION
828 DPKGBUILD
829 HAVE_DPKGBUILD
830 DPKG_VERSION
831 DPKG
832 HAVE_DPKG
833 RPMBUILD_VERSION
834 RPMBUILD
835 HAVE_RPMBUILD
836 RPM_VERSION
837 RPM
838 HAVE_RPM
839 DEFAULT_INIT_SCRIPT
840 DEFAULT_INIT_DIR
841 DEFAULT_PACKAGE
842 VENDOR
843 am__fastdepCCAS_FALSE
844 am__fastdepCCAS_TRUE
845 CCASDEPMODE
846 CCASFLAGS
847 CCAS
848 CPP
849 OTOOL64
850 OTOOL
851 LIPO
852 NMEDIT
853 DSYMUTIL
854 lt_ECHO
855 RANLIB
856 AR
857 OBJDUMP
858 LN_S
859 NM
860 ac_ct_DUMPBIN
861 DUMPBIN
862 LD
863 FGREP
864 EGREP
865 GREP
866 SED
867 LIBTOOL
868 am__fastdepCC_FALSE
869 am__fastdepCC_TRUE
870 CCDEPMODE
871 AMDEPBACKSLASH
872 AMDEP_FALSE
873 AMDEP_TRUE
874 am__quote
875 am__include
876 DEPDIR
877 OBJEXT
878 EXEEXT
879 ac_ct_CC
880 CPPFLAGS
881 LDFLAGS
882 CFLAGS
883 CC
884 am__untar
885 am__tar
886 AMTAR
887 am__leading_dot
888 SET_MAKE
889 AWK
890 mkdir_p
891 MKDIR_P
892 INSTALL_STRIP_PROGRAM
893 STRIP
894 install_sh
895 MAKEINFO
896 AUTOHEADER
897 AUTOMAKE
898 AUTOCONF
899 ACLOCAL
900 VERSION
901 PACKAGE
902 CYGPATH_W
903 am__isrc
904 INSTALL_DATA
905 INSTALL_SCRIPT
906 INSTALL_PROGRAM
907 AM_BACKSLASH
908 AM_DEFAULT_VERBOSITY
909 MAINT
910 MAINTAINER_MODE_FALSE
911 MAINTAINER_MODE_TRUE
912 target_os
913 target_vendor
914 target_cpu
915 target
916 host_os
917 host_vendor
918 host_cpu
919 host
920 build_os
921 build_vendor
922 build_cpu
923 build
924 ZFS_META_LT_AGE
925 ZFS_META_LT_REVISION
926 ZFS_META_LT_CURRENT
927 ZFS_META_AUTHOR
928 ZFS_META_DATA
929 ZFS_META_ALIAS
930 ZFS_META_LICENSE
931 ZFS_META_RELEASE
932 ZFS_META_VERSION
933 ZFS_META_NAME
934 target_alias
935 host_alias
936 build_alias
937 LIBS
938 ECHO_T
939 ECHO_N
940 ECHO_C
941 DEFS
942 mandir
943 localedir
944 libdir
945 psdir
946 pdfdir
947 dvidir
948 htmldir
949 infodir
950 docdir
951 oldincludedir
952 includedir
953 localstatedir
954 sharedstatedir
955 sysconfdir
956 datadir
957 datarootdir
958 libexecdir
959 sbindir
960 bindir
961 program_transform_name
962 prefix
963 exec_prefix
964 PACKAGE_BUGREPORT
965 PACKAGE_STRING
966 PACKAGE_VERSION
967 PACKAGE_TARNAME
968 PACKAGE_NAME
969 PATH_SEPARATOR
970 SHELL'
971 ac_subst_files=''
972 ac_user_opts='
973 enable_option_checking
974 enable_maintainer_mode
975 enable_silent_rules
976 enable_dependency_tracking
977 enable_shared
978 enable_static
979 with_pic
980 enable_fast_install
981 with_gnu_ld
982 enable_libtool_lock
983 with_config
984 enable_linux_builtin
985 with_linux
986 with_linux_obj
987 with_spl
988 with_spl_obj
989 with_udevdir
990 with_udevruledir
991 with_blkid
992 with_selinux
993 enable_debug
994 enable_debug_dmu_tx
995 '
996       ac_precious_vars='build_alias
997 host_alias
998 target_alias
999 CC
1000 CFLAGS
1001 LDFLAGS
1002 LIBS
1003 CPPFLAGS
1004 CPP
1005 CCAS
1006 CCASFLAGS'
1007
1008
1009 # Initialize some variables set by options.
1010 ac_init_help=
1011 ac_init_version=false
1012 ac_unrecognized_opts=
1013 ac_unrecognized_sep=
1014 # The variables have the same names as the options, with
1015 # dashes changed to underlines.
1016 cache_file=/dev/null
1017 exec_prefix=NONE
1018 no_create=
1019 no_recursion=
1020 prefix=NONE
1021 program_prefix=NONE
1022 program_suffix=NONE
1023 program_transform_name=s,x,x,
1024 silent=
1025 site=
1026 srcdir=
1027 verbose=
1028 x_includes=NONE
1029 x_libraries=NONE
1030
1031 # Installation directory options.
1032 # These are left unexpanded so users can "make install exec_prefix=/foo"
1033 # and all the variables that are supposed to be based on exec_prefix
1034 # by default will actually change.
1035 # Use braces instead of parens because sh, perl, etc. also accept them.
1036 # (The list follows the same order as the GNU Coding Standards.)
1037 bindir='${exec_prefix}/bin'
1038 sbindir='${exec_prefix}/sbin'
1039 libexecdir='${exec_prefix}/libexec'
1040 datarootdir='${prefix}/share'
1041 datadir='${datarootdir}'
1042 sysconfdir='${prefix}/etc'
1043 sharedstatedir='${prefix}/com'
1044 localstatedir='${prefix}/var'
1045 includedir='${prefix}/include'
1046 oldincludedir='/usr/include'
1047 docdir='${datarootdir}/doc/${PACKAGE}'
1048 infodir='${datarootdir}/info'
1049 htmldir='${docdir}'
1050 dvidir='${docdir}'
1051 pdfdir='${docdir}'
1052 psdir='${docdir}'
1053 libdir='${exec_prefix}/lib'
1054 localedir='${datarootdir}/locale'
1055 mandir='${datarootdir}/man'
1056
1057 ac_prev=
1058 ac_dashdash=
1059 for ac_option
1060 do
1061   # If the previous option needs an argument, assign it.
1062   if test -n "$ac_prev"; then
1063     eval $ac_prev=\$ac_option
1064     ac_prev=
1065     continue
1066   fi
1067
1068   case $ac_option in
1069   *=*)  ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1070   *)    ac_optarg=yes ;;
1071   esac
1072
1073   # Accept the important Cygnus configure options, so we can diagnose typos.
1074
1075   case $ac_dashdash$ac_option in
1076   --)
1077     ac_dashdash=yes ;;
1078
1079   -bindir | --bindir | --bindi | --bind | --bin | --bi)
1080     ac_prev=bindir ;;
1081   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1082     bindir=$ac_optarg ;;
1083
1084   -build | --build | --buil | --bui | --bu)
1085     ac_prev=build_alias ;;
1086   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1087     build_alias=$ac_optarg ;;
1088
1089   -cache-file | --cache-file | --cache-fil | --cache-fi \
1090   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1091     ac_prev=cache_file ;;
1092   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1093   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1094     cache_file=$ac_optarg ;;
1095
1096   --config-cache | -C)
1097     cache_file=config.cache ;;
1098
1099   -datadir | --datadir | --datadi | --datad)
1100     ac_prev=datadir ;;
1101   -datadir=* | --datadir=* | --datadi=* | --datad=*)
1102     datadir=$ac_optarg ;;
1103
1104   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1105   | --dataroo | --dataro | --datar)
1106     ac_prev=datarootdir ;;
1107   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1108   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1109     datarootdir=$ac_optarg ;;
1110
1111   -disable-* | --disable-*)
1112     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1113     # Reject names that are not valid shell variable names.
1114     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1115       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
1116    { (exit 1); exit 1; }; }
1117     ac_useropt_orig=$ac_useropt
1118     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1119     case $ac_user_opts in
1120       *"
1121 "enable_$ac_useropt"
1122 "*) ;;
1123       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1124          ac_unrecognized_sep=', ';;
1125     esac
1126     eval enable_$ac_useropt=no ;;
1127
1128   -docdir | --docdir | --docdi | --doc | --do)
1129     ac_prev=docdir ;;
1130   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1131     docdir=$ac_optarg ;;
1132
1133   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1134     ac_prev=dvidir ;;
1135   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1136     dvidir=$ac_optarg ;;
1137
1138   -enable-* | --enable-*)
1139     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1140     # Reject names that are not valid shell variable names.
1141     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1142       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
1143    { (exit 1); exit 1; }; }
1144     ac_useropt_orig=$ac_useropt
1145     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1146     case $ac_user_opts in
1147       *"
1148 "enable_$ac_useropt"
1149 "*) ;;
1150       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1151          ac_unrecognized_sep=', ';;
1152     esac
1153     eval enable_$ac_useropt=\$ac_optarg ;;
1154
1155   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1156   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1157   | --exec | --exe | --ex)
1158     ac_prev=exec_prefix ;;
1159   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1160   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1161   | --exec=* | --exe=* | --ex=*)
1162     exec_prefix=$ac_optarg ;;
1163
1164   -gas | --gas | --ga | --g)
1165     # Obsolete; use --with-gas.
1166     with_gas=yes ;;
1167
1168   -help | --help | --hel | --he | -h)
1169     ac_init_help=long ;;
1170   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1171     ac_init_help=recursive ;;
1172   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1173     ac_init_help=short ;;
1174
1175   -host | --host | --hos | --ho)
1176     ac_prev=host_alias ;;
1177   -host=* | --host=* | --hos=* | --ho=*)
1178     host_alias=$ac_optarg ;;
1179
1180   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1181     ac_prev=htmldir ;;
1182   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1183   | --ht=*)
1184     htmldir=$ac_optarg ;;
1185
1186   -includedir | --includedir | --includedi | --included | --include \
1187   | --includ | --inclu | --incl | --inc)
1188     ac_prev=includedir ;;
1189   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1190   | --includ=* | --inclu=* | --incl=* | --inc=*)
1191     includedir=$ac_optarg ;;
1192
1193   -infodir | --infodir | --infodi | --infod | --info | --inf)
1194     ac_prev=infodir ;;
1195   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1196     infodir=$ac_optarg ;;
1197
1198   -libdir | --libdir | --libdi | --libd)
1199     ac_prev=libdir ;;
1200   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1201     libdir=$ac_optarg ;;
1202
1203   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1204   | --libexe | --libex | --libe)
1205     ac_prev=libexecdir ;;
1206   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1207   | --libexe=* | --libex=* | --libe=*)
1208     libexecdir=$ac_optarg ;;
1209
1210   -localedir | --localedir | --localedi | --localed | --locale)
1211     ac_prev=localedir ;;
1212   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1213     localedir=$ac_optarg ;;
1214
1215   -localstatedir | --localstatedir | --localstatedi | --localstated \
1216   | --localstate | --localstat | --localsta | --localst | --locals)
1217     ac_prev=localstatedir ;;
1218   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1219   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1220     localstatedir=$ac_optarg ;;
1221
1222   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1223     ac_prev=mandir ;;
1224   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1225     mandir=$ac_optarg ;;
1226
1227   -nfp | --nfp | --nf)
1228     # Obsolete; use --without-fp.
1229     with_fp=no ;;
1230
1231   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1232   | --no-cr | --no-c | -n)
1233     no_create=yes ;;
1234
1235   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1236   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1237     no_recursion=yes ;;
1238
1239   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1240   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1241   | --oldin | --oldi | --old | --ol | --o)
1242     ac_prev=oldincludedir ;;
1243   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1244   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1245   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1246     oldincludedir=$ac_optarg ;;
1247
1248   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1249     ac_prev=prefix ;;
1250   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1251     prefix=$ac_optarg ;;
1252
1253   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1254   | --program-pre | --program-pr | --program-p)
1255     ac_prev=program_prefix ;;
1256   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1257   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1258     program_prefix=$ac_optarg ;;
1259
1260   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1261   | --program-suf | --program-su | --program-s)
1262     ac_prev=program_suffix ;;
1263   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1264   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1265     program_suffix=$ac_optarg ;;
1266
1267   -program-transform-name | --program-transform-name \
1268   | --program-transform-nam | --program-transform-na \
1269   | --program-transform-n | --program-transform- \
1270   | --program-transform | --program-transfor \
1271   | --program-transfo | --program-transf \
1272   | --program-trans | --program-tran \
1273   | --progr-tra | --program-tr | --program-t)
1274     ac_prev=program_transform_name ;;
1275   -program-transform-name=* | --program-transform-name=* \
1276   | --program-transform-nam=* | --program-transform-na=* \
1277   | --program-transform-n=* | --program-transform-=* \
1278   | --program-transform=* | --program-transfor=* \
1279   | --program-transfo=* | --program-transf=* \
1280   | --program-trans=* | --program-tran=* \
1281   | --progr-tra=* | --program-tr=* | --program-t=*)
1282     program_transform_name=$ac_optarg ;;
1283
1284   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1285     ac_prev=pdfdir ;;
1286   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1287     pdfdir=$ac_optarg ;;
1288
1289   -psdir | --psdir | --psdi | --psd | --ps)
1290     ac_prev=psdir ;;
1291   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1292     psdir=$ac_optarg ;;
1293
1294   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1295   | -silent | --silent | --silen | --sile | --sil)
1296     silent=yes ;;
1297
1298   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1299     ac_prev=sbindir ;;
1300   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1301   | --sbi=* | --sb=*)
1302     sbindir=$ac_optarg ;;
1303
1304   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1305   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1306   | --sharedst | --shareds | --shared | --share | --shar \
1307   | --sha | --sh)
1308     ac_prev=sharedstatedir ;;
1309   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1310   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1311   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1312   | --sha=* | --sh=*)
1313     sharedstatedir=$ac_optarg ;;
1314
1315   -site | --site | --sit)
1316     ac_prev=site ;;
1317   -site=* | --site=* | --sit=*)
1318     site=$ac_optarg ;;
1319
1320   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1321     ac_prev=srcdir ;;
1322   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1323     srcdir=$ac_optarg ;;
1324
1325   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1326   | --syscon | --sysco | --sysc | --sys | --sy)
1327     ac_prev=sysconfdir ;;
1328   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1329   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1330     sysconfdir=$ac_optarg ;;
1331
1332   -target | --target | --targe | --targ | --tar | --ta | --t)
1333     ac_prev=target_alias ;;
1334   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1335     target_alias=$ac_optarg ;;
1336
1337   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1338     verbose=yes ;;
1339
1340   -version | --version | --versio | --versi | --vers | -V)
1341     ac_init_version=: ;;
1342
1343   -with-* | --with-*)
1344     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1345     # Reject names that are not valid shell variable names.
1346     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1347       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1348    { (exit 1); exit 1; }; }
1349     ac_useropt_orig=$ac_useropt
1350     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1351     case $ac_user_opts in
1352       *"
1353 "with_$ac_useropt"
1354 "*) ;;
1355       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1356          ac_unrecognized_sep=', ';;
1357     esac
1358     eval with_$ac_useropt=\$ac_optarg ;;
1359
1360   -without-* | --without-*)
1361     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1362     # Reject names that are not valid shell variable names.
1363     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1364       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1365    { (exit 1); exit 1; }; }
1366     ac_useropt_orig=$ac_useropt
1367     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1368     case $ac_user_opts in
1369       *"
1370 "with_$ac_useropt"
1371 "*) ;;
1372       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1373          ac_unrecognized_sep=', ';;
1374     esac
1375     eval with_$ac_useropt=no ;;
1376
1377   --x)
1378     # Obsolete; use --with-x.
1379     with_x=yes ;;
1380
1381   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1382   | --x-incl | --x-inc | --x-in | --x-i)
1383     ac_prev=x_includes ;;
1384   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1385   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1386     x_includes=$ac_optarg ;;
1387
1388   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1389   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1390     ac_prev=x_libraries ;;
1391   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1392   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1393     x_libraries=$ac_optarg ;;
1394
1395   -*) { $as_echo "$as_me: error: unrecognized option: $ac_option
1396 Try \`$0 --help' for more information." >&2
1397    { (exit 1); exit 1; }; }
1398     ;;
1399
1400   *=*)
1401     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1402     # Reject names that are not valid shell variable names.
1403     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1404       { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1405    { (exit 1); exit 1; }; }
1406     eval $ac_envvar=\$ac_optarg
1407     export $ac_envvar ;;
1408
1409   *)
1410     # FIXME: should be removed in autoconf 3.0.
1411     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1412     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1413       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1414     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1415     ;;
1416
1417   esac
1418 done
1419
1420 if test -n "$ac_prev"; then
1421   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1422   { $as_echo "$as_me: error: missing argument to $ac_option" >&2
1423    { (exit 1); exit 1; }; }
1424 fi
1425
1426 if test -n "$ac_unrecognized_opts"; then
1427   case $enable_option_checking in
1428     no) ;;
1429     fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2
1430    { (exit 1); exit 1; }; } ;;
1431     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1432   esac
1433 fi
1434
1435 # Check all directory arguments for consistency.
1436 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1437                 datadir sysconfdir sharedstatedir localstatedir includedir \
1438                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1439                 libdir localedir mandir
1440 do
1441   eval ac_val=\$$ac_var
1442   # Remove trailing slashes.
1443   case $ac_val in
1444     */ )
1445       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1446       eval $ac_var=\$ac_val;;
1447   esac
1448   # Be sure to have absolute directory names.
1449   case $ac_val in
1450     [\\/$]* | ?:[\\/]* )  continue;;
1451     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1452   esac
1453   { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1454    { (exit 1); exit 1; }; }
1455 done
1456
1457 # There might be people who depend on the old broken behavior: `$host'
1458 # used to hold the argument of --host etc.
1459 # FIXME: To remove some day.
1460 build=$build_alias
1461 host=$host_alias
1462 target=$target_alias
1463
1464 # FIXME: To remove some day.
1465 if test "x$host_alias" != x; then
1466   if test "x$build_alias" = x; then
1467     cross_compiling=maybe
1468     $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1469     If a cross compiler is detected then cross compile mode will be used." >&2
1470   elif test "x$build_alias" != "x$host_alias"; then
1471     cross_compiling=yes
1472   fi
1473 fi
1474
1475 ac_tool_prefix=
1476 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1477
1478 test "$silent" = yes && exec 6>/dev/null
1479
1480
1481 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1482 ac_ls_di=`ls -di .` &&
1483 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1484   { $as_echo "$as_me: error: working directory cannot be determined" >&2
1485    { (exit 1); exit 1; }; }
1486 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1487   { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
1488    { (exit 1); exit 1; }; }
1489
1490
1491 # Find the source files, if location was not specified.
1492 if test -z "$srcdir"; then
1493   ac_srcdir_defaulted=yes
1494   # Try the directory containing this script, then the parent directory.
1495   ac_confdir=`$as_dirname -- "$as_myself" ||
1496 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1497          X"$as_myself" : 'X\(//\)[^/]' \| \
1498          X"$as_myself" : 'X\(//\)$' \| \
1499          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1500 $as_echo X"$as_myself" |
1501     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1502             s//\1/
1503             q
1504           }
1505           /^X\(\/\/\)[^/].*/{
1506             s//\1/
1507             q
1508           }
1509           /^X\(\/\/\)$/{
1510             s//\1/
1511             q
1512           }
1513           /^X\(\/\).*/{
1514             s//\1/
1515             q
1516           }
1517           s/.*/./; q'`
1518   srcdir=$ac_confdir
1519   if test ! -r "$srcdir/$ac_unique_file"; then
1520     srcdir=..
1521   fi
1522 else
1523   ac_srcdir_defaulted=no
1524 fi
1525 if test ! -r "$srcdir/$ac_unique_file"; then
1526   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1527   { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1528    { (exit 1); exit 1; }; }
1529 fi
1530 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1531 ac_abs_confdir=`(
1532         cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2
1533    { (exit 1); exit 1; }; }
1534         pwd)`
1535 # When building in place, set srcdir=.
1536 if test "$ac_abs_confdir" = "$ac_pwd"; then
1537   srcdir=.
1538 fi
1539 # Remove unnecessary trailing slashes from srcdir.
1540 # Double slashes in file names in object file debugging info
1541 # mess up M-x gdb in Emacs.
1542 case $srcdir in
1543 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1544 esac
1545 for ac_var in $ac_precious_vars; do
1546   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1547   eval ac_env_${ac_var}_value=\$${ac_var}
1548   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1549   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1550 done
1551
1552 #
1553 # Report the --help message.
1554 #
1555 if test "$ac_init_help" = "long"; then
1556   # Omit some internal or obsolete options to make the list less imposing.
1557   # This message is too long to be a string in the A/UX 3.1 sh.
1558   cat <<_ACEOF
1559 \`configure' configures this package to adapt to many kinds of systems.
1560
1561 Usage: $0 [OPTION]... [VAR=VALUE]...
1562
1563 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1564 VAR=VALUE.  See below for descriptions of some of the useful variables.
1565
1566 Defaults for the options are specified in brackets.
1567
1568 Configuration:
1569   -h, --help              display this help and exit
1570       --help=short        display options specific to this package
1571       --help=recursive    display the short help of all the included packages
1572   -V, --version           display version information and exit
1573   -q, --quiet, --silent   do not print \`checking...' messages
1574       --cache-file=FILE   cache test results in FILE [disabled]
1575   -C, --config-cache      alias for \`--cache-file=config.cache'
1576   -n, --no-create         do not create output files
1577       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1578
1579 Installation directories:
1580   --prefix=PREFIX         install architecture-independent files in PREFIX
1581                           [$ac_default_prefix]
1582   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1583                           [PREFIX]
1584
1585 By default, \`make install' will install all the files in
1586 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1587 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1588 for instance \`--prefix=\$HOME'.
1589
1590 For better control, use the options below.
1591
1592 Fine tuning of the installation directories:
1593   --bindir=DIR            user executables [EPREFIX/bin]
1594   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1595   --libexecdir=DIR        program executables [EPREFIX/libexec]
1596   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1597   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1598   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1599   --libdir=DIR            object code libraries [EPREFIX/lib]
1600   --includedir=DIR        C header files [PREFIX/include]
1601   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1602   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1603   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1604   --infodir=DIR           info documentation [DATAROOTDIR/info]
1605   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1606   --mandir=DIR            man documentation [DATAROOTDIR/man]
1607   --docdir=DIR            documentation root [DATAROOTDIR/doc/PACKAGE]
1608   --htmldir=DIR           html documentation [DOCDIR]
1609   --dvidir=DIR            dvi documentation [DOCDIR]
1610   --pdfdir=DIR            pdf documentation [DOCDIR]
1611   --psdir=DIR             ps documentation [DOCDIR]
1612 _ACEOF
1613
1614   cat <<\_ACEOF
1615
1616 Program names:
1617   --program-prefix=PREFIX            prepend PREFIX to installed program names
1618   --program-suffix=SUFFIX            append SUFFIX to installed program names
1619   --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
1620
1621 System types:
1622   --build=BUILD     configure for building on BUILD [guessed]
1623   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1624   --target=TARGET   configure for building compilers for TARGET [HOST]
1625 _ACEOF
1626 fi
1627
1628 if test -n "$ac_init_help"; then
1629
1630   cat <<\_ACEOF
1631
1632 Optional Features:
1633   --disable-option-checking  ignore unrecognized --enable/--with options
1634   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1635   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1636   --enable-maintainer-mode  enable make rules and dependencies not useful
1637                           (and sometimes confusing) to the casual installer
1638   --enable-silent-rules          less verbose build output (undo: `make V=1')
1639   --disable-silent-rules         verbose build output (undo: `make V=0')
1640   --disable-dependency-tracking  speeds up one-time build
1641   --enable-dependency-tracking   do not reject slow dependency extractors
1642   --enable-shared[=PKGS]  build shared libraries [default=yes]
1643   --enable-static[=PKGS]  build static libraries [default=yes]
1644   --enable-fast-install[=PKGS]
1645                           optimize for fast installation [default=yes]
1646   --disable-libtool-lock  avoid locking (might break parallel builds)
1647   --enable-linux-builtin  Configure for builtin in-tree kernel modules
1648                           [default=no]
1649   --enable-debug          Enable generic debug support [default=no]
1650   --enable-debug-dmu-tx   Enable dmu tx validation [default=no]
1651
1652 Optional Packages:
1653   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1654   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1655   --with-pic              try to use only PIC/non-PIC objects [default=use
1656                           both]
1657   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1658   --with-config=CONFIG    Config file 'kernel|user|all|srpm'
1659   --with-linux=PATH       Path to kernel source
1660   --with-linux-obj=PATH   Path to kernel build objects
1661   --with-spl=PATH         Path to spl source
1662   --with-spl-obj=PATH     Path to spl build objects
1663   --with-udevdir=DIR      install udev helpers [EPREFIX/lib/udev]
1664   --with-udevruledir=DIR  install udev rules [UDEVDIR/rules.d]
1665   --with-blkid            support blkid caching [default=check]
1666   --with-selinux          support selinux [default=check]
1667
1668 Some influential environment variables:
1669   CC          C compiler command
1670   CFLAGS      C compiler flags
1671   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1672               nonstandard directory <lib dir>
1673   LIBS        libraries to pass to the linker, e.g. -l<library>
1674   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1675               you have headers in a nonstandard directory <include dir>
1676   CPP         C preprocessor
1677   CCAS        assembler compiler command (defaults to CC)
1678   CCASFLAGS   assembler compiler flags (defaults to CFLAGS)
1679
1680 Use these variables to override the choices made by `configure' or to help
1681 it to find libraries and programs with nonstandard names/locations.
1682
1683 _ACEOF
1684 ac_status=$?
1685 fi
1686
1687 if test "$ac_init_help" = "recursive"; then
1688   # If there are subdirs, report their specific --help.
1689   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1690     test -d "$ac_dir" ||
1691       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1692       continue
1693     ac_builddir=.
1694
1695 case "$ac_dir" in
1696 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1697 *)
1698   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1699   # A ".." for each directory in $ac_dir_suffix.
1700   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1701   case $ac_top_builddir_sub in
1702   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1703   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1704   esac ;;
1705 esac
1706 ac_abs_top_builddir=$ac_pwd
1707 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1708 # for backward compatibility:
1709 ac_top_builddir=$ac_top_build_prefix
1710
1711 case $srcdir in
1712   .)  # We are building in place.
1713     ac_srcdir=.
1714     ac_top_srcdir=$ac_top_builddir_sub
1715     ac_abs_top_srcdir=$ac_pwd ;;
1716   [\\/]* | ?:[\\/]* )  # Absolute name.
1717     ac_srcdir=$srcdir$ac_dir_suffix;
1718     ac_top_srcdir=$srcdir
1719     ac_abs_top_srcdir=$srcdir ;;
1720   *) # Relative name.
1721     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1722     ac_top_srcdir=$ac_top_build_prefix$srcdir
1723     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1724 esac
1725 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1726
1727     cd "$ac_dir" || { ac_status=$?; continue; }
1728     # Check for guested configure.
1729     if test -f "$ac_srcdir/configure.gnu"; then
1730       echo &&
1731       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1732     elif test -f "$ac_srcdir/configure"; then
1733       echo &&
1734       $SHELL "$ac_srcdir/configure" --help=recursive
1735     else
1736       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1737     fi || ac_status=$?
1738     cd "$ac_pwd" || { ac_status=$?; break; }
1739   done
1740 fi
1741
1742 test -n "$ac_init_help" && exit $ac_status
1743 if $ac_init_version; then
1744   cat <<\_ACEOF
1745 configure
1746 generated by GNU Autoconf 2.63
1747
1748 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1749 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
1750 This configure script is free software; the Free Software Foundation
1751 gives unlimited permission to copy, distribute and modify it.
1752 _ACEOF
1753   exit
1754 fi
1755 cat >config.log <<_ACEOF
1756 This file contains any messages produced by compilers while
1757 running configure, to aid debugging if configure makes a mistake.
1758
1759 It was created by $as_me, which was
1760 generated by GNU Autoconf 2.63.  Invocation command line was
1761
1762   $ $0 $@
1763
1764 _ACEOF
1765 exec 5>>config.log
1766 {
1767 cat <<_ASUNAME
1768 ## --------- ##
1769 ## Platform. ##
1770 ## --------- ##
1771
1772 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1773 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1774 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1775 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1776 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1777
1778 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1779 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1780
1781 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1782 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1783 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1784 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1785 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1786 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1787 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1788
1789 _ASUNAME
1790
1791 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1792 for as_dir in $PATH
1793 do
1794   IFS=$as_save_IFS
1795   test -z "$as_dir" && as_dir=.
1796   $as_echo "PATH: $as_dir"
1797 done
1798 IFS=$as_save_IFS
1799
1800 } >&5
1801
1802 cat >&5 <<_ACEOF
1803
1804
1805 ## ----------- ##
1806 ## Core tests. ##
1807 ## ----------- ##
1808
1809 _ACEOF
1810
1811
1812 # Keep a trace of the command line.
1813 # Strip out --no-create and --no-recursion so they do not pile up.
1814 # Strip out --silent because we don't want to record it for future runs.
1815 # Also quote any args containing shell meta-characters.
1816 # Make two passes to allow for proper duplicate-argument suppression.
1817 ac_configure_args=
1818 ac_configure_args0=
1819 ac_configure_args1=
1820 ac_must_keep_next=false
1821 for ac_pass in 1 2
1822 do
1823   for ac_arg
1824   do
1825     case $ac_arg in
1826     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1827     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1828     | -silent | --silent | --silen | --sile | --sil)
1829       continue ;;
1830     *\'*)
1831       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1832     esac
1833     case $ac_pass in
1834     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1835     2)
1836       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1837       if test $ac_must_keep_next = true; then
1838         ac_must_keep_next=false # Got value, back to normal.
1839       else
1840         case $ac_arg in
1841           *=* | --config-cache | -C | -disable-* | --disable-* \
1842           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1843           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1844           | -with-* | --with-* | -without-* | --without-* | --x)
1845             case "$ac_configure_args0 " in
1846               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1847             esac
1848             ;;
1849           -* ) ac_must_keep_next=true ;;
1850         esac
1851       fi
1852       ac_configure_args="$ac_configure_args '$ac_arg'"
1853       ;;
1854     esac
1855   done
1856 done
1857 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1858 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1859
1860 # When interrupted or exit'd, cleanup temporary files, and complete
1861 # config.log.  We remove comments because anyway the quotes in there
1862 # would cause problems or look ugly.
1863 # WARNING: Use '\'' to represent an apostrophe within the trap.
1864 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1865 trap 'exit_status=$?
1866   # Save into config.log some information that might help in debugging.
1867   {
1868     echo
1869
1870     cat <<\_ASBOX
1871 ## ---------------- ##
1872 ## Cache variables. ##
1873 ## ---------------- ##
1874 _ASBOX
1875     echo
1876     # The following way of writing the cache mishandles newlines in values,
1877 (
1878   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1879     eval ac_val=\$$ac_var
1880     case $ac_val in #(
1881     *${as_nl}*)
1882       case $ac_var in #(
1883       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
1884 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
1885       esac
1886       case $ac_var in #(
1887       _ | IFS | as_nl) ;; #(
1888       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
1889       *) $as_unset $ac_var ;;
1890       esac ;;
1891     esac
1892   done
1893   (set) 2>&1 |
1894     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1895     *${as_nl}ac_space=\ *)
1896       sed -n \
1897         "s/'\''/'\''\\\\'\'''\''/g;
1898           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1899       ;; #(
1900     *)
1901       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1902       ;;
1903     esac |
1904     sort
1905 )
1906     echo
1907
1908     cat <<\_ASBOX
1909 ## ----------------- ##
1910 ## Output variables. ##
1911 ## ----------------- ##
1912 _ASBOX
1913     echo
1914     for ac_var in $ac_subst_vars
1915     do
1916       eval ac_val=\$$ac_var
1917       case $ac_val in
1918       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1919       esac
1920       $as_echo "$ac_var='\''$ac_val'\''"
1921     done | sort
1922     echo
1923
1924     if test -n "$ac_subst_files"; then
1925       cat <<\_ASBOX
1926 ## ------------------- ##
1927 ## File substitutions. ##
1928 ## ------------------- ##
1929 _ASBOX
1930       echo
1931       for ac_var in $ac_subst_files
1932       do
1933         eval ac_val=\$$ac_var
1934         case $ac_val in
1935         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1936         esac
1937         $as_echo "$ac_var='\''$ac_val'\''"
1938       done | sort
1939       echo
1940     fi
1941
1942     if test -s confdefs.h; then
1943       cat <<\_ASBOX
1944 ## ----------- ##
1945 ## confdefs.h. ##
1946 ## ----------- ##
1947 _ASBOX
1948       echo
1949       cat confdefs.h
1950       echo
1951     fi
1952     test "$ac_signal" != 0 &&
1953       $as_echo "$as_me: caught signal $ac_signal"
1954     $as_echo "$as_me: exit $exit_status"
1955   } >&5
1956   rm -f core *.core core.conftest.* &&
1957     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1958     exit $exit_status
1959 ' 0
1960 for ac_signal in 1 2 13 15; do
1961   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1962 done
1963 ac_signal=0
1964
1965 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1966 rm -f -r conftest* confdefs.h
1967
1968 # Predefined preprocessor variables.
1969
1970 cat >>confdefs.h <<_ACEOF
1971 #define PACKAGE_NAME "$PACKAGE_NAME"
1972 _ACEOF
1973
1974
1975 cat >>confdefs.h <<_ACEOF
1976 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1977 _ACEOF
1978
1979
1980 cat >>confdefs.h <<_ACEOF
1981 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1982 _ACEOF
1983
1984
1985 cat >>confdefs.h <<_ACEOF
1986 #define PACKAGE_STRING "$PACKAGE_STRING"
1987 _ACEOF
1988
1989
1990 cat >>confdefs.h <<_ACEOF
1991 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1992 _ACEOF
1993
1994
1995 # Let the site file select an alternate cache file if it wants to.
1996 # Prefer an explicitly selected file to automatically selected ones.
1997 ac_site_file1=NONE
1998 ac_site_file2=NONE
1999 if test -n "$CONFIG_SITE"; then
2000   ac_site_file1=$CONFIG_SITE
2001 elif test "x$prefix" != xNONE; then
2002   ac_site_file1=$prefix/share/config.site
2003   ac_site_file2=$prefix/etc/config.site
2004 else
2005   ac_site_file1=$ac_default_prefix/share/config.site
2006   ac_site_file2=$ac_default_prefix/etc/config.site
2007 fi
2008 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2009 do
2010   test "x$ac_site_file" = xNONE && continue
2011   if test -r "$ac_site_file"; then
2012     { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
2013 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2014     sed 's/^/| /' "$ac_site_file" >&5
2015     . "$ac_site_file"
2016   fi
2017 done
2018
2019 if test -r "$cache_file"; then
2020   # Some versions of bash will fail to source /dev/null (special
2021   # files actually), so we avoid doing that.
2022   if test -f "$cache_file"; then
2023     { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
2024 $as_echo "$as_me: loading cache $cache_file" >&6;}
2025     case $cache_file in
2026       [\\/]* | ?:[\\/]* ) . "$cache_file";;
2027       *)                      . "./$cache_file";;
2028     esac
2029   fi
2030 else
2031   { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
2032 $as_echo "$as_me: creating cache $cache_file" >&6;}
2033   >$cache_file
2034 fi
2035
2036 # Check that the precious variables saved in the cache have kept the same
2037 # value.
2038 ac_cache_corrupted=false
2039 for ac_var in $ac_precious_vars; do
2040   eval ac_old_set=\$ac_cv_env_${ac_var}_set
2041   eval ac_new_set=\$ac_env_${ac_var}_set
2042   eval ac_old_val=\$ac_cv_env_${ac_var}_value
2043   eval ac_new_val=\$ac_env_${ac_var}_value
2044   case $ac_old_set,$ac_new_set in
2045     set,)
2046       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2047 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2048       ac_cache_corrupted=: ;;
2049     ,set)
2050       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
2051 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2052       ac_cache_corrupted=: ;;
2053     ,);;
2054     *)
2055       if test "x$ac_old_val" != "x$ac_new_val"; then
2056         # differences in whitespace do not lead to failure.
2057         ac_old_val_w=`echo x $ac_old_val`
2058         ac_new_val_w=`echo x $ac_new_val`
2059         if test "$ac_old_val_w" != "$ac_new_val_w"; then
2060           { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
2061 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2062           ac_cache_corrupted=:
2063         else
2064           { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2065 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2066           eval $ac_var=\$ac_old_val
2067         fi
2068         { $as_echo "$as_me:$LINENO:   former value:  \`$ac_old_val'" >&5
2069 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2070         { $as_echo "$as_me:$LINENO:   current value: \`$ac_new_val'" >&5
2071 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2072       fi;;
2073   esac
2074   # Pass precious variables to config.status.
2075   if test "$ac_new_set" = set; then
2076     case $ac_new_val in
2077     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2078     *) ac_arg=$ac_var=$ac_new_val ;;
2079     esac
2080     case " $ac_configure_args " in
2081       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2082       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
2083     esac
2084   fi
2085 done
2086 if $ac_cache_corrupted; then
2087   { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
2088 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2089   { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
2090 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2091   { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
2092 $as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
2093    { (exit 1); exit 1; }; }
2094 fi
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112 ac_ext=c
2113 ac_cpp='$CPP $CPPFLAGS'
2114 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2115 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2116 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2117
2118
2119 ac_ext=c
2120 ac_cpp='$CPP $CPPFLAGS'
2121 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2122 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2123 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2124
2125
2126
2127
2128
2129
2130         { $as_echo "$as_me:$LINENO: checking metadata" >&5
2131 $as_echo_n "checking metadata... " >&6; }
2132
2133         META="$srcdir/META"
2134         _zfs_ac_meta_got_file=no
2135         if test -f "$META"; then
2136                 _zfs_ac_meta_got_file=yes
2137
2138                 ZFS_META_NAME=`perl -n\
2139                 -e "BEGIN { \\$key=shift @ARGV; }"\
2140                 -e "next unless s/^\s*\\$key[:=]//i;"\
2141                 -e "s/^((?:[^'\"#]*(?:(['\"])[^\2]*\2)*)*)#.*/\\$1/;"\
2142                 -e "s/^\s+//;"\
2143                 -e "s/\s+$//;"\
2144                 -e "s/^(['\"])(.*)\1/\\$2/;"\
2145                 -e "\\$val=\\$_;"\
2146                 -e "END { print \\$val if defined \\$val; }"\
2147                 '(?:NAME|PROJECT|PACKAGE)' $META`;
2148                 if test -n "$ZFS_META_NAME"; then
2149
2150 cat >>confdefs.h <<_ACEOF
2151 #define ZFS_META_NAME "$ZFS_META_NAME"
2152 _ACEOF
2153
2154
2155                 fi
2156
2157                 ZFS_META_VERSION=`perl -n\
2158                 -e "BEGIN { \\$key=shift @ARGV; }"\
2159                 -e "next unless s/^\s*\\$key[:=]//i;"\
2160                 -e "s/^((?:[^'\"#]*(?:(['\"])[^\2]*\2)*)*)#.*/\\$1/;"\
2161                 -e "s/^\s+//;"\
2162                 -e "s/\s+$//;"\
2163                 -e "s/^(['\"])(.*)\1/\\$2/;"\
2164                 -e "\\$val=\\$_;"\
2165                 -e "END { print \\$val if defined \\$val; }"\
2166                 'VERSION' $META`;
2167                 if test -n "$ZFS_META_VERSION"; then
2168
2169 cat >>confdefs.h <<_ACEOF
2170 #define ZFS_META_VERSION "$ZFS_META_VERSION"
2171 _ACEOF
2172
2173
2174                 fi
2175
2176                 ZFS_META_RELEASE=`perl -n\
2177                 -e "BEGIN { \\$key=shift @ARGV; }"\
2178                 -e "next unless s/^\s*\\$key[:=]//i;"\
2179                 -e "s/^((?:[^'\"#]*(?:(['\"])[^\2]*\2)*)*)#.*/\\$1/;"\
2180                 -e "s/^\s+//;"\
2181                 -e "s/\s+$//;"\
2182                 -e "s/^(['\"])(.*)\1/\\$2/;"\
2183                 -e "\\$val=\\$_;"\
2184                 -e "END { print \\$val if defined \\$val; }"\
2185                 'RELEASE' $META`;
2186                 if test -n "$ZFS_META_RELEASE"; then
2187
2188 cat >>confdefs.h <<_ACEOF
2189 #define ZFS_META_RELEASE "$ZFS_META_RELEASE"
2190 _ACEOF
2191
2192
2193                 fi
2194
2195                 ZFS_META_LICENSE=`perl -n\
2196                 -e "BEGIN { \\$key=shift @ARGV; }"\
2197                 -e "next unless s/^\s*\\$key[:=]//i;"\
2198                 -e "s/^((?:[^'\"#]*(?:(['\"])[^\2]*\2)*)*)#.*/\\$1/;"\
2199                 -e "s/^\s+//;"\
2200                 -e "s/\s+$//;"\
2201                 -e "s/^(['\"])(.*)\1/\\$2/;"\
2202                 -e "\\$val=\\$_;"\
2203                 -e "END { print \\$val if defined \\$val; }"\
2204                 'LICENSE' $META`;
2205                 if test -n "$ZFS_META_LICENSE"; then
2206
2207 cat >>confdefs.h <<_ACEOF
2208 #define ZFS_META_LICENSE "$ZFS_META_LICENSE"
2209 _ACEOF
2210
2211
2212                 fi
2213
2214                 if test -n "$ZFS_META_NAME" -a -n "$ZFS_META_VERSION"; then
2215                                 ZFS_META_ALIAS="$ZFS_META_NAME-$ZFS_META_VERSION"
2216                                 test -n "$ZFS_META_RELEASE" &&
2217                                         ZFS_META_ALIAS="$ZFS_META_ALIAS-$ZFS_META_RELEASE"
2218
2219 cat >>confdefs.h <<_ACEOF
2220 #define ZFS_META_ALIAS "$ZFS_META_ALIAS"
2221 _ACEOF
2222
2223
2224                 fi
2225
2226                 ZFS_META_DATA=`perl -n\
2227                 -e "BEGIN { \\$key=shift @ARGV; }"\
2228                 -e "next unless s/^\s*\\$key[:=]//i;"\
2229                 -e "s/^((?:[^'\"#]*(?:(['\"])[^\2]*\2)*)*)#.*/\\$1/;"\
2230                 -e "s/^\s+//;"\
2231                 -e "s/\s+$//;"\
2232                 -e "s/^(['\"])(.*)\1/\\$2/;"\
2233                 -e "\\$val=\\$_;"\
2234                 -e "END { print \\$val if defined \\$val; }"\
2235                 'DATE' $META`;
2236                 if test -n "$ZFS_META_DATA"; then
2237
2238 cat >>confdefs.h <<_ACEOF
2239 #define ZFS_META_DATA "$ZFS_META_DATA"
2240 _ACEOF
2241
2242
2243                 fi
2244
2245                 ZFS_META_AUTHOR=`perl -n\
2246                 -e "BEGIN { \\$key=shift @ARGV; }"\
2247                 -e "next unless s/^\s*\\$key[:=]//i;"\
2248                 -e "s/^((?:[^'\"#]*(?:(['\"])[^\2]*\2)*)*)#.*/\\$1/;"\
2249                 -e "s/^\s+//;"\
2250                 -e "s/\s+$//;"\
2251                 -e "s/^(['\"])(.*)\1/\\$2/;"\
2252                 -e "\\$val=\\$_;"\
2253                 -e "END { print \\$val if defined \\$val; }"\
2254                 'AUTHOR' $META`;
2255                 if test -n "$ZFS_META_AUTHOR"; then
2256
2257 cat >>confdefs.h <<_ACEOF
2258 #define ZFS_META_AUTHOR "$ZFS_META_AUTHOR"
2259 _ACEOF
2260
2261
2262                 fi
2263
2264
2265                 ZFS_META_LT_CURRENT=`perl -n\
2266                 -e "BEGIN { \\$key=shift @ARGV; }"\
2267                 -e "next unless s/^\s*\\$key[:=]//i;"\
2268                 -e "s/^((?:[^'\"#]*(?:(['\"])[^\2]*\2)*)*)#.*/\\$1/;"\
2269                 -e "s/^\s+//;"\
2270                 -e "s/\s+$//;"\
2271                 -e "s/^(['\"])(.*)\1/\\$2/;"\
2272                 -e "\\$val=\\$_;"\
2273                 -e "END { print \\$val if defined \\$val; }"\
2274                 'LT_CURRENT' $META`;
2275                 ZFS_META_LT_REVISION=`perl -n\
2276                 -e "BEGIN { \\$key=shift @ARGV; }"\
2277                 -e "next unless s/^\s*\\$key[:=]//i;"\
2278                 -e "s/^((?:[^'\"#]*(?:(['\"])[^\2]*\2)*)*)#.*/\\$1/;"\
2279                 -e "s/^\s+//;"\
2280                 -e "s/\s+$//;"\
2281                 -e "s/^(['\"])(.*)\1/\\$2/;"\
2282                 -e "\\$val=\\$_;"\
2283                 -e "END { print \\$val if defined \\$val; }"\
2284                 'LT_REVISION' $META`;
2285                 ZFS_META_LT_AGE=`perl -n\
2286                 -e "BEGIN { \\$key=shift @ARGV; }"\
2287                 -e "next unless s/^\s*\\$key[:=]//i;"\
2288                 -e "s/^((?:[^'\"#]*(?:(['\"])[^\2]*\2)*)*)#.*/\\$1/;"\
2289                 -e "s/^\s+//;"\
2290                 -e "s/\s+$//;"\
2291                 -e "s/^(['\"])(.*)\1/\\$2/;"\
2292                 -e "\\$val=\\$_;"\
2293                 -e "END { print \\$val if defined \\$val; }"\
2294                 'LT_AGE' $META`;
2295                 if test -n "$ZFS_META_LT_CURRENT" \
2296                                  -o -n "$ZFS_META_LT_REVISION" \
2297                                  -o -n "$ZFS_META_LT_AGE"; then
2298                         test -n "$ZFS_META_LT_CURRENT" || ZFS_META_LT_CURRENT="0"
2299                         test -n "$ZFS_META_LT_REVISION" || ZFS_META_LT_REVISION="0"
2300                         test -n "$ZFS_META_LT_AGE" || ZFS_META_LT_AGE="0"
2301
2302 cat >>confdefs.h <<_ACEOF
2303 #define ZFS_META_LT_CURRENT "$ZFS_META_LT_CURRENT"
2304 _ACEOF
2305
2306
2307 cat >>confdefs.h <<_ACEOF
2308 #define ZFS_META_LT_REVISION "$ZFS_META_LT_REVISION"
2309 _ACEOF
2310
2311
2312 cat >>confdefs.h <<_ACEOF
2313 #define ZFS_META_LT_AGE "$ZFS_META_LT_AGE"
2314 _ACEOF
2315
2316
2317
2318
2319                 fi
2320         fi
2321
2322         { $as_echo "$as_me:$LINENO: result: $_zfs_ac_meta_got_file" >&5
2323 $as_echo "$_zfs_ac_meta_got_file" >&6; }
2324
2325
2326 ac_aux_dir=
2327 for ac_dir in config "$srcdir"/config; do
2328   if test -f "$ac_dir/install-sh"; then
2329     ac_aux_dir=$ac_dir
2330     ac_install_sh="$ac_aux_dir/install-sh -c"
2331     break
2332   elif test -f "$ac_dir/install.sh"; then
2333     ac_aux_dir=$ac_dir
2334     ac_install_sh="$ac_aux_dir/install.sh -c"
2335     break
2336   elif test -f "$ac_dir/shtool"; then
2337     ac_aux_dir=$ac_dir
2338     ac_install_sh="$ac_aux_dir/shtool install -c"
2339     break
2340   fi
2341 done
2342 if test -z "$ac_aux_dir"; then
2343   { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5
2344 $as_echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;}
2345    { (exit 1); exit 1; }; }
2346 fi
2347
2348 # These three variables are undocumented and unsupported,
2349 # and are intended to be withdrawn in a future Autoconf release.
2350 # They can cause serious problems if a builder's source tree is in a directory
2351 # whose full name contains unusual characters.
2352 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2353 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2354 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2355
2356
2357 # Make sure we can run config.sub.
2358 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2359   { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
2360 $as_echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
2361    { (exit 1); exit 1; }; }
2362
2363 { $as_echo "$as_me:$LINENO: checking build system type" >&5
2364 $as_echo_n "checking build system type... " >&6; }
2365 if test "${ac_cv_build+set}" = set; then
2366   $as_echo_n "(cached) " >&6
2367 else
2368   ac_build_alias=$build_alias
2369 test "x$ac_build_alias" = x &&
2370   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2371 test "x$ac_build_alias" = x &&
2372   { { $as_echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
2373 $as_echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2374    { (exit 1); exit 1; }; }
2375 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2376   { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
2377 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
2378    { (exit 1); exit 1; }; }
2379
2380 fi
2381 { $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5
2382 $as_echo "$ac_cv_build" >&6; }
2383 case $ac_cv_build in
2384 *-*-*) ;;
2385 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
2386 $as_echo "$as_me: error: invalid value of canonical build" >&2;}
2387    { (exit 1); exit 1; }; };;
2388 esac
2389 build=$ac_cv_build
2390 ac_save_IFS=$IFS; IFS='-'
2391 set x $ac_cv_build
2392 shift
2393 build_cpu=$1
2394 build_vendor=$2
2395 shift; shift
2396 # Remember, the first character of IFS is used to create $*,
2397 # except with old shells:
2398 build_os=$*
2399 IFS=$ac_save_IFS
2400 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2401
2402
2403 { $as_echo "$as_me:$LINENO: checking host system type" >&5
2404 $as_echo_n "checking host system type... " >&6; }
2405 if test "${ac_cv_host+set}" = set; then
2406   $as_echo_n "(cached) " >&6
2407 else
2408   if test "x$host_alias" = x; then
2409   ac_cv_host=$ac_cv_build
2410 else
2411   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2412     { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
2413 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
2414    { (exit 1); exit 1; }; }
2415 fi
2416
2417 fi
2418 { $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5
2419 $as_echo "$ac_cv_host" >&6; }
2420 case $ac_cv_host in
2421 *-*-*) ;;
2422 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
2423 $as_echo "$as_me: error: invalid value of canonical host" >&2;}
2424    { (exit 1); exit 1; }; };;
2425 esac
2426 host=$ac_cv_host
2427 ac_save_IFS=$IFS; IFS='-'
2428 set x $ac_cv_host
2429 shift
2430 host_cpu=$1
2431 host_vendor=$2
2432 shift; shift
2433 # Remember, the first character of IFS is used to create $*,
2434 # except with old shells:
2435 host_os=$*
2436 IFS=$ac_save_IFS
2437 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2438
2439
2440 { $as_echo "$as_me:$LINENO: checking target system type" >&5
2441 $as_echo_n "checking target system type... " >&6; }
2442 if test "${ac_cv_target+set}" = set; then
2443   $as_echo_n "(cached) " >&6
2444 else
2445   if test "x$target_alias" = x; then
2446   ac_cv_target=$ac_cv_host
2447 else
2448   ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
2449     { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $target_alias failed" >&5
2450 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $target_alias failed" >&2;}
2451    { (exit 1); exit 1; }; }
2452 fi
2453
2454 fi
2455 { $as_echo "$as_me:$LINENO: result: $ac_cv_target" >&5
2456 $as_echo "$ac_cv_target" >&6; }
2457 case $ac_cv_target in
2458 *-*-*) ;;
2459 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical target" >&5
2460 $as_echo "$as_me: error: invalid value of canonical target" >&2;}
2461    { (exit 1); exit 1; }; };;
2462 esac
2463 target=$ac_cv_target
2464 ac_save_IFS=$IFS; IFS='-'
2465 set x $ac_cv_target
2466 shift
2467 target_cpu=$1
2468 target_vendor=$2
2469 shift; shift
2470 # Remember, the first character of IFS is used to create $*,
2471 # except with old shells:
2472 target_os=$*
2473 IFS=$ac_save_IFS
2474 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
2475
2476
2477 # The aliases save the names the user supplied, while $host etc.
2478 # will get canonicalized.
2479 test -n "$target_alias" &&
2480   test "$program_prefix$program_suffix$program_transform_name" = \
2481     NONENONEs,x,x, &&
2482   program_prefix=${target_alias}-
2483
2484 { $as_echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5
2485 $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
2486     # Check whether --enable-maintainer-mode was given.
2487 if test "${enable_maintainer_mode+set}" = set; then
2488   enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
2489 else
2490   USE_MAINTAINER_MODE=no
2491 fi
2492
2493   { $as_echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5
2494 $as_echo "$USE_MAINTAINER_MODE" >&6; }
2495    if test $USE_MAINTAINER_MODE = yes; then
2496   MAINTAINER_MODE_TRUE=
2497   MAINTAINER_MODE_FALSE='#'
2498 else
2499   MAINTAINER_MODE_TRUE='#'
2500   MAINTAINER_MODE_FALSE=
2501 fi
2502
2503   MAINT=$MAINTAINER_MODE_TRUE
2504
2505
2506 # Check whether --enable-silent-rules was given.
2507 if test "${enable_silent_rules+set}" = set; then
2508   enableval=$enable_silent_rules;
2509 fi
2510
2511 case $enable_silent_rules in
2512 yes) AM_DEFAULT_VERBOSITY=0;;
2513 no)  AM_DEFAULT_VERBOSITY=1;;
2514 *)   AM_DEFAULT_VERBOSITY=1;;
2515 esac
2516 AM_BACKSLASH='\'
2517
2518 am__api_version='1.11'
2519
2520 # Find a good install program.  We prefer a C program (faster),
2521 # so one script is as good as another.  But avoid the broken or
2522 # incompatible versions:
2523 # SysV /etc/install, /usr/sbin/install
2524 # SunOS /usr/etc/install
2525 # IRIX /sbin/install
2526 # AIX /bin/install
2527 # AmigaOS /C/install, which installs bootblocks on floppy discs
2528 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
2529 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
2530 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
2531 # OS/2's system install, which has a completely different semantic
2532 # ./install, which can be erroneously created by make from ./install.sh.
2533 # Reject install programs that cannot install multiple files.
2534 { $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
2535 $as_echo_n "checking for a BSD-compatible install... " >&6; }
2536 if test -z "$INSTALL"; then
2537 if test "${ac_cv_path_install+set}" = set; then
2538   $as_echo_n "(cached) " >&6
2539 else
2540   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2541 for as_dir in $PATH
2542 do
2543   IFS=$as_save_IFS
2544   test -z "$as_dir" && as_dir=.
2545   # Account for people who put trailing slashes in PATH elements.
2546 case $as_dir/ in
2547   ./ | .// | /cC/* | \
2548   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
2549   ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
2550   /usr/ucb/* ) ;;
2551   *)
2552     # OSF1 and SCO ODT 3.0 have their own names for install.
2553     # Don't use installbsd from OSF since it installs stuff as root
2554     # by default.
2555     for ac_prog in ginstall scoinst install; do
2556       for ac_exec_ext in '' $ac_executable_extensions; do
2557         if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
2558           if test $ac_prog = install &&
2559             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2560             # AIX install.  It has an incompatible calling convention.
2561             :
2562           elif test $ac_prog = install &&
2563             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
2564             # program-specific install script used by HP pwplus--don't use.
2565             :
2566           else
2567             rm -rf conftest.one conftest.two conftest.dir
2568             echo one > conftest.one
2569             echo two > conftest.two
2570             mkdir conftest.dir
2571             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
2572               test -s conftest.one && test -s conftest.two &&
2573               test -s conftest.dir/conftest.one &&
2574               test -s conftest.dir/conftest.two
2575             then
2576               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
2577               break 3
2578             fi
2579           fi
2580         fi
2581       done
2582     done
2583     ;;
2584 esac
2585
2586 done
2587 IFS=$as_save_IFS
2588
2589 rm -rf conftest.one conftest.two conftest.dir
2590
2591 fi
2592   if test "${ac_cv_path_install+set}" = set; then
2593     INSTALL=$ac_cv_path_install
2594   else
2595     # As a last resort, use the slow shell script.  Don't cache a
2596     # value for INSTALL within a source directory, because that will
2597     # break other packages using the cache if that directory is
2598     # removed, or if the value is a relative name.
2599     INSTALL=$ac_install_sh
2600   fi
2601 fi
2602 { $as_echo "$as_me:$LINENO: result: $INSTALL" >&5
2603 $as_echo "$INSTALL" >&6; }
2604
2605 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
2606 # It thinks the first close brace ends the variable substitution.
2607 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
2608
2609 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
2610
2611 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
2612
2613 { $as_echo "$as_me:$LINENO: checking whether build environment is sane" >&5
2614 $as_echo_n "checking whether build environment is sane... " >&6; }
2615 # Just in case
2616 sleep 1
2617 echo timestamp > conftest.file
2618 # Reject unsafe characters in $srcdir or the absolute working directory
2619 # name.  Accept space and tab only in the latter.
2620 am_lf='
2621 '
2622 case `pwd` in
2623   *[\\\"\#\$\&\'\`$am_lf]*)
2624     { { $as_echo "$as_me:$LINENO: error: unsafe absolute working directory name" >&5
2625 $as_echo "$as_me: error: unsafe absolute working directory name" >&2;}
2626    { (exit 1); exit 1; }; };;
2627 esac
2628 case $srcdir in
2629   *[\\\"\#\$\&\'\`$am_lf\ \     ]*)
2630     { { $as_echo "$as_me:$LINENO: error: unsafe srcdir value: \`$srcdir'" >&5
2631 $as_echo "$as_me: error: unsafe srcdir value: \`$srcdir'" >&2;}
2632    { (exit 1); exit 1; }; };;
2633 esac
2634
2635 # Do `set' in a subshell so we don't clobber the current shell's
2636 # arguments.  Must try -L first in case configure is actually a
2637 # symlink; some systems play weird games with the mod time of symlinks
2638 # (eg FreeBSD returns the mod time of the symlink's containing
2639 # directory).
2640 if (
2641    set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
2642    if test "$*" = "X"; then
2643       # -L didn't work.
2644       set X `ls -t "$srcdir/configure" conftest.file`
2645    fi
2646    rm -f conftest.file
2647    if test "$*" != "X $srcdir/configure conftest.file" \
2648       && test "$*" != "X conftest.file $srcdir/configure"; then
2649
2650       # If neither matched, then we have a broken ls.  This can happen
2651       # if, for instance, CONFIG_SHELL is bash and it inherits a
2652       # broken ls alias from the environment.  This has actually
2653       # happened.  Such a system could not be considered "sane".
2654       { { $as_echo "$as_me:$LINENO: error: ls -t appears to fail.  Make sure there is not a broken
2655 alias in your environment" >&5
2656 $as_echo "$as_me: error: ls -t appears to fail.  Make sure there is not a broken
2657 alias in your environment" >&2;}
2658    { (exit 1); exit 1; }; }
2659    fi
2660
2661    test "$2" = conftest.file
2662    )
2663 then
2664    # Ok.
2665    :
2666 else
2667    { { $as_echo "$as_me:$LINENO: error: newly created file is older than distributed files!
2668 Check your system clock" >&5
2669 $as_echo "$as_me: error: newly created file is older than distributed files!
2670 Check your system clock" >&2;}
2671    { (exit 1); exit 1; }; }
2672 fi
2673 { $as_echo "$as_me:$LINENO: result: yes" >&5
2674 $as_echo "yes" >&6; }
2675 test "$program_prefix" != NONE &&
2676   program_transform_name="s&^&$program_prefix&;$program_transform_name"
2677 # Use a double $ so make ignores it.
2678 test "$program_suffix" != NONE &&
2679   program_transform_name="s&\$&$program_suffix&;$program_transform_name"
2680 # Double any \ or $.
2681 # By default was `s,x,x', remove it if useless.
2682 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
2683 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
2684
2685 # expand $ac_aux_dir to an absolute path
2686 am_aux_dir=`cd $ac_aux_dir && pwd`
2687
2688 if test x"${MISSING+set}" != xset; then
2689   case $am_aux_dir in
2690   *\ * | *\     *)
2691     MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
2692   *)
2693     MISSING="\${SHELL} $am_aux_dir/missing" ;;
2694   esac
2695 fi
2696 # Use eval to expand $SHELL
2697 if eval "$MISSING --run true"; then
2698   am_missing_run="$MISSING --run "
2699 else
2700   am_missing_run=
2701   { $as_echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5
2702 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
2703 fi
2704
2705 if test x"${install_sh}" != xset; then
2706   case $am_aux_dir in
2707   *\ * | *\     *)
2708     install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
2709   *)
2710     install_sh="\${SHELL} $am_aux_dir/install-sh"
2711   esac
2712 fi
2713
2714 # Installed binaries are usually stripped using `strip' when the user
2715 # run `make install-strip'.  However `strip' might not be the right
2716 # tool to use in cross-compilation environments, therefore Automake
2717 # will honor the `STRIP' environment variable to overrule this program.
2718 if test "$cross_compiling" != no; then
2719   if test -n "$ac_tool_prefix"; then
2720   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
2721 set dummy ${ac_tool_prefix}strip; ac_word=$2
2722 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2723 $as_echo_n "checking for $ac_word... " >&6; }
2724 if test "${ac_cv_prog_STRIP+set}" = set; then
2725   $as_echo_n "(cached) " >&6
2726 else
2727   if test -n "$STRIP"; then
2728   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
2729 else
2730 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2731 for as_dir in $PATH
2732 do
2733   IFS=$as_save_IFS
2734   test -z "$as_dir" && as_dir=.
2735   for ac_exec_ext in '' $ac_executable_extensions; do
2736   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2737     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
2738     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2739     break 2
2740   fi
2741 done
2742 done
2743 IFS=$as_save_IFS
2744
2745 fi
2746 fi
2747 STRIP=$ac_cv_prog_STRIP
2748 if test -n "$STRIP"; then
2749   { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
2750 $as_echo "$STRIP" >&6; }
2751 else
2752   { $as_echo "$as_me:$LINENO: result: no" >&5
2753 $as_echo "no" >&6; }
2754 fi
2755
2756
2757 fi
2758 if test -z "$ac_cv_prog_STRIP"; then
2759   ac_ct_STRIP=$STRIP
2760   # Extract the first word of "strip", so it can be a program name with args.
2761 set dummy strip; ac_word=$2
2762 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2763 $as_echo_n "checking for $ac_word... " >&6; }
2764 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
2765   $as_echo_n "(cached) " >&6
2766 else
2767   if test -n "$ac_ct_STRIP"; then
2768   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
2769 else
2770 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2771 for as_dir in $PATH
2772 do
2773   IFS=$as_save_IFS
2774   test -z "$as_dir" && as_dir=.
2775   for ac_exec_ext in '' $ac_executable_extensions; do
2776   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2777     ac_cv_prog_ac_ct_STRIP="strip"
2778     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2779     break 2
2780   fi
2781 done
2782 done
2783 IFS=$as_save_IFS
2784
2785 fi
2786 fi
2787 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
2788 if test -n "$ac_ct_STRIP"; then
2789   { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
2790 $as_echo "$ac_ct_STRIP" >&6; }
2791 else
2792   { $as_echo "$as_me:$LINENO: result: no" >&5
2793 $as_echo "no" >&6; }
2794 fi
2795
2796   if test "x$ac_ct_STRIP" = x; then
2797     STRIP=":"
2798   else
2799     case $cross_compiling:$ac_tool_warned in
2800 yes:)
2801 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
2802 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2803 ac_tool_warned=yes ;;
2804 esac
2805     STRIP=$ac_ct_STRIP
2806   fi
2807 else
2808   STRIP="$ac_cv_prog_STRIP"
2809 fi
2810
2811 fi
2812 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
2813
2814 { $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5
2815 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
2816 if test -z "$MKDIR_P"; then
2817   if test "${ac_cv_path_mkdir+set}" = set; then
2818   $as_echo_n "(cached) " >&6
2819 else
2820   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2821 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
2822 do
2823   IFS=$as_save_IFS
2824   test -z "$as_dir" && as_dir=.
2825   for ac_prog in mkdir gmkdir; do
2826          for ac_exec_ext in '' $ac_executable_extensions; do
2827            { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
2828            case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
2829              'mkdir (GNU coreutils) '* | \
2830              'mkdir (coreutils) '* | \
2831              'mkdir (fileutils) '4.1*)
2832                ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
2833                break 3;;
2834            esac
2835          done
2836        done
2837 done
2838 IFS=$as_save_IFS
2839
2840 fi
2841
2842   if test "${ac_cv_path_mkdir+set}" = set; then
2843     MKDIR_P="$ac_cv_path_mkdir -p"
2844   else
2845     # As a last resort, use the slow shell script.  Don't cache a
2846     # value for MKDIR_P within a source directory, because that will
2847     # break other packages using the cache if that directory is
2848     # removed, or if the value is a relative name.
2849     test -d ./--version && rmdir ./--version
2850     MKDIR_P="$ac_install_sh -d"
2851   fi
2852 fi
2853 { $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5
2854 $as_echo "$MKDIR_P" >&6; }
2855
2856 mkdir_p="$MKDIR_P"
2857 case $mkdir_p in
2858   [\\/$]* | ?:[\\/]*) ;;
2859   */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
2860 esac
2861
2862 for ac_prog in gawk mawk nawk awk
2863 do
2864   # Extract the first word of "$ac_prog", so it can be a program name with args.
2865 set dummy $ac_prog; ac_word=$2
2866 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2867 $as_echo_n "checking for $ac_word... " >&6; }
2868 if test "${ac_cv_prog_AWK+set}" = set; then
2869   $as_echo_n "(cached) " >&6
2870 else
2871   if test -n "$AWK"; then
2872   ac_cv_prog_AWK="$AWK" # Let the user override the test.
2873 else
2874 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2875 for as_dir in $PATH
2876 do
2877   IFS=$as_save_IFS
2878   test -z "$as_dir" && as_dir=.
2879   for ac_exec_ext in '' $ac_executable_extensions; do
2880   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2881     ac_cv_prog_AWK="$ac_prog"
2882     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2883     break 2
2884   fi
2885 done
2886 done
2887 IFS=$as_save_IFS
2888
2889 fi
2890 fi
2891 AWK=$ac_cv_prog_AWK
2892 if test -n "$AWK"; then
2893   { $as_echo "$as_me:$LINENO: result: $AWK" >&5
2894 $as_echo "$AWK" >&6; }
2895 else
2896   { $as_echo "$as_me:$LINENO: result: no" >&5
2897 $as_echo "no" >&6; }
2898 fi
2899
2900
2901   test -n "$AWK" && break
2902 done
2903
2904 { $as_echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
2905 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
2906 set x ${MAKE-make}
2907 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
2908 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then
2909   $as_echo_n "(cached) " >&6
2910 else
2911   cat >conftest.make <<\_ACEOF
2912 SHELL = /bin/sh
2913 all:
2914         @echo '@@@%%%=$(MAKE)=@@@%%%'
2915 _ACEOF
2916 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
2917 case `${MAKE-make} -f conftest.make 2>/dev/null` in
2918   *@@@%%%=?*=@@@%%%*)
2919     eval ac_cv_prog_make_${ac_make}_set=yes;;
2920   *)
2921     eval ac_cv_prog_make_${ac_make}_set=no;;
2922 esac
2923 rm -f conftest.make
2924 fi
2925 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
2926   { $as_echo "$as_me:$LINENO: result: yes" >&5
2927 $as_echo "yes" >&6; }
2928   SET_MAKE=
2929 else
2930   { $as_echo "$as_me:$LINENO: result: no" >&5
2931 $as_echo "no" >&6; }
2932   SET_MAKE="MAKE=${MAKE-make}"
2933 fi
2934
2935 rm -rf .tst 2>/dev/null
2936 mkdir .tst 2>/dev/null
2937 if test -d .tst; then
2938   am__leading_dot=.
2939 else
2940   am__leading_dot=_
2941 fi
2942 rmdir .tst 2>/dev/null
2943
2944 if test "`cd $srcdir && pwd`" != "`pwd`"; then
2945   # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
2946   # is not polluted with repeated "-I."
2947   am__isrc=' -I$(srcdir)'
2948   # test to see if srcdir already configured
2949   if test -f $srcdir/config.status; then
2950     { { $as_echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
2951 $as_echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
2952    { (exit 1); exit 1; }; }
2953   fi
2954 fi
2955
2956 # test whether we have cygpath
2957 if test -z "$CYGPATH_W"; then
2958   if (cygpath --version) >/dev/null 2>/dev/null; then
2959     CYGPATH_W='cygpath -w'
2960   else
2961     CYGPATH_W=echo
2962   fi
2963 fi
2964
2965
2966 # Define the identity of the package.
2967  PACKAGE=$ZFS_META_NAME
2968  VERSION=$ZFS_META_VERSION
2969
2970
2971 cat >>confdefs.h <<_ACEOF
2972 #define PACKAGE "$PACKAGE"
2973 _ACEOF
2974
2975
2976 cat >>confdefs.h <<_ACEOF
2977 #define VERSION "$VERSION"
2978 _ACEOF
2979
2980 # Some tools Automake needs.
2981
2982 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
2983
2984
2985 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
2986
2987
2988 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
2989
2990
2991 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
2992
2993
2994 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
2995
2996 # We need awk for the "check" target.  The system "awk" is bad on
2997 # some platforms.
2998 # Always define AMTAR for backward compatibility.
2999
3000 AMTAR=${AMTAR-"${am_missing_run}tar"}
3001
3002 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3003
3004
3005
3006
3007
3008 ac_config_headers="$ac_config_headers zfs_config.h"
3009
3010
3011 # Find a good install program.  We prefer a C program (faster),
3012 # so one script is as good as another.  But avoid the broken or
3013 # incompatible versions:
3014 # SysV /etc/install, /usr/sbin/install
3015 # SunOS /usr/etc/install
3016 # IRIX /sbin/install
3017 # AIX /bin/install
3018 # AmigaOS /C/install, which installs bootblocks on floppy discs
3019 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3020 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3021 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3022 # OS/2's system install, which has a completely different semantic
3023 # ./install, which can be erroneously created by make from ./install.sh.
3024 # Reject install programs that cannot install multiple files.
3025 { $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
3026 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3027 if test -z "$INSTALL"; then
3028 if test "${ac_cv_path_install+set}" = set; then
3029   $as_echo_n "(cached) " >&6
3030 else
3031   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3032 for as_dir in $PATH
3033 do
3034   IFS=$as_save_IFS
3035   test -z "$as_dir" && as_dir=.
3036   # Account for people who put trailing slashes in PATH elements.
3037 case $as_dir/ in
3038   ./ | .// | /cC/* | \
3039   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3040   ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
3041   /usr/ucb/* ) ;;
3042   *)
3043     # OSF1 and SCO ODT 3.0 have their own names for install.
3044     # Don't use installbsd from OSF since it installs stuff as root
3045     # by default.
3046     for ac_prog in ginstall scoinst install; do
3047       for ac_exec_ext in '' $ac_executable_extensions; do
3048         if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3049           if test $ac_prog = install &&
3050             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3051             # AIX install.  It has an incompatible calling convention.
3052             :
3053           elif test $ac_prog = install &&
3054             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3055             # program-specific install script used by HP pwplus--don't use.
3056             :
3057           else
3058             rm -rf conftest.one conftest.two conftest.dir
3059             echo one > conftest.one
3060             echo two > conftest.two
3061             mkdir conftest.dir
3062             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3063               test -s conftest.one && test -s conftest.two &&
3064               test -s conftest.dir/conftest.one &&
3065               test -s conftest.dir/conftest.two
3066             then
3067               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3068               break 3
3069             fi
3070           fi
3071         fi
3072       done
3073     done
3074     ;;
3075 esac
3076
3077 done
3078 IFS=$as_save_IFS
3079
3080 rm -rf conftest.one conftest.two conftest.dir
3081
3082 fi
3083   if test "${ac_cv_path_install+set}" = set; then
3084     INSTALL=$ac_cv_path_install
3085   else
3086     # As a last resort, use the slow shell script.  Don't cache a
3087     # value for INSTALL within a source directory, because that will
3088     # break other packages using the cache if that directory is
3089     # removed, or if the value is a relative name.
3090     INSTALL=$ac_install_sh
3091   fi
3092 fi
3093 { $as_echo "$as_me:$LINENO: result: $INSTALL" >&5
3094 $as_echo "$INSTALL" >&6; }
3095
3096 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3097 # It thinks the first close brace ends the variable substitution.
3098 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3099
3100 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3101
3102 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3103
3104 ac_ext=c
3105 ac_cpp='$CPP $CPPFLAGS'
3106 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3107 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3108 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3109 if test -n "$ac_tool_prefix"; then
3110   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3111 set dummy ${ac_tool_prefix}gcc; ac_word=$2
3112 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3113 $as_echo_n "checking for $ac_word... " >&6; }
3114 if test "${ac_cv_prog_CC+set}" = set; then
3115   $as_echo_n "(cached) " >&6
3116 else
3117   if test -n "$CC"; then
3118   ac_cv_prog_CC="$CC" # Let the user override the test.
3119 else
3120 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3121 for as_dir in $PATH
3122 do
3123   IFS=$as_save_IFS
3124   test -z "$as_dir" && as_dir=.
3125   for ac_exec_ext in '' $ac_executable_extensions; do
3126   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3127     ac_cv_prog_CC="${ac_tool_prefix}gcc"
3128     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3129     break 2
3130   fi
3131 done
3132 done
3133 IFS=$as_save_IFS
3134
3135 fi
3136 fi
3137 CC=$ac_cv_prog_CC
3138 if test -n "$CC"; then
3139   { $as_echo "$as_me:$LINENO: result: $CC" >&5
3140 $as_echo "$CC" >&6; }
3141 else
3142   { $as_echo "$as_me:$LINENO: result: no" >&5
3143 $as_echo "no" >&6; }
3144 fi
3145
3146
3147 fi
3148 if test -z "$ac_cv_prog_CC"; then
3149   ac_ct_CC=$CC
3150   # Extract the first word of "gcc", so it can be a program name with args.
3151 set dummy gcc; ac_word=$2
3152 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3153 $as_echo_n "checking for $ac_word... " >&6; }
3154 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3155   $as_echo_n "(cached) " >&6
3156 else
3157   if test -n "$ac_ct_CC"; then
3158   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3159 else
3160 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3161 for as_dir in $PATH
3162 do
3163   IFS=$as_save_IFS
3164   test -z "$as_dir" && as_dir=.
3165   for ac_exec_ext in '' $ac_executable_extensions; do
3166   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3167     ac_cv_prog_ac_ct_CC="gcc"
3168     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3169     break 2
3170   fi
3171 done
3172 done
3173 IFS=$as_save_IFS
3174
3175 fi
3176 fi
3177 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3178 if test -n "$ac_ct_CC"; then
3179   { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3180 $as_echo "$ac_ct_CC" >&6; }
3181 else
3182   { $as_echo "$as_me:$LINENO: result: no" >&5
3183 $as_echo "no" >&6; }
3184 fi
3185
3186   if test "x$ac_ct_CC" = x; then
3187     CC=""
3188   else
3189     case $cross_compiling:$ac_tool_warned in
3190 yes:)
3191 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
3192 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3193 ac_tool_warned=yes ;;
3194 esac
3195     CC=$ac_ct_CC
3196   fi
3197 else
3198   CC="$ac_cv_prog_CC"
3199 fi
3200
3201 if test -z "$CC"; then
3202           if test -n "$ac_tool_prefix"; then
3203     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3204 set dummy ${ac_tool_prefix}cc; ac_word=$2
3205 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3206 $as_echo_n "checking for $ac_word... " >&6; }
3207 if test "${ac_cv_prog_CC+set}" = set; then
3208   $as_echo_n "(cached) " >&6
3209 else
3210   if test -n "$CC"; then
3211   ac_cv_prog_CC="$CC" # Let the user override the test.
3212 else
3213 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3214 for as_dir in $PATH
3215 do
3216   IFS=$as_save_IFS
3217   test -z "$as_dir" && as_dir=.
3218   for ac_exec_ext in '' $ac_executable_extensions; do
3219   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3220     ac_cv_prog_CC="${ac_tool_prefix}cc"
3221     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3222     break 2
3223   fi
3224 done
3225 done
3226 IFS=$as_save_IFS
3227
3228 fi
3229 fi
3230 CC=$ac_cv_prog_CC
3231 if test -n "$CC"; then
3232   { $as_echo "$as_me:$LINENO: result: $CC" >&5
3233 $as_echo "$CC" >&6; }
3234 else
3235   { $as_echo "$as_me:$LINENO: result: no" >&5
3236 $as_echo "no" >&6; }
3237 fi
3238
3239
3240   fi
3241 fi
3242 if test -z "$CC"; then
3243   # Extract the first word of "cc", so it can be a program name with args.
3244 set dummy cc; ac_word=$2
3245 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3246 $as_echo_n "checking for $ac_word... " >&6; }
3247 if test "${ac_cv_prog_CC+set}" = set; then
3248   $as_echo_n "(cached) " >&6
3249 else
3250   if test -n "$CC"; then
3251   ac_cv_prog_CC="$CC" # Let the user override the test.
3252 else
3253   ac_prog_rejected=no
3254 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3255 for as_dir in $PATH
3256 do
3257   IFS=$as_save_IFS
3258   test -z "$as_dir" && as_dir=.
3259   for ac_exec_ext in '' $ac_executable_extensions; do
3260   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3261     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3262        ac_prog_rejected=yes
3263        continue
3264      fi
3265     ac_cv_prog_CC="cc"
3266     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3267     break 2
3268   fi
3269 done
3270 done
3271 IFS=$as_save_IFS
3272
3273 if test $ac_prog_rejected = yes; then
3274   # We found a bogon in the path, so make sure we never use it.
3275   set dummy $ac_cv_prog_CC
3276   shift
3277   if test $# != 0; then
3278     # We chose a different compiler from the bogus one.
3279     # However, it has the same basename, so the bogon will be chosen
3280     # first if we set CC to just the basename; use the full file name.
3281     shift
3282     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3283   fi
3284 fi
3285 fi
3286 fi
3287 CC=$ac_cv_prog_CC
3288 if test -n "$CC"; then
3289   { $as_echo "$as_me:$LINENO: result: $CC" >&5
3290 $as_echo "$CC" >&6; }
3291 else
3292   { $as_echo "$as_me:$LINENO: result: no" >&5
3293 $as_echo "no" >&6; }
3294 fi
3295
3296
3297 fi
3298 if test -z "$CC"; then
3299   if test -n "$ac_tool_prefix"; then
3300   for ac_prog in cl.exe
3301   do
3302     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3303 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3304 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3305 $as_echo_n "checking for $ac_word... " >&6; }
3306 if test "${ac_cv_prog_CC+set}" = set; then
3307   $as_echo_n "(cached) " >&6
3308 else
3309   if test -n "$CC"; then
3310   ac_cv_prog_CC="$CC" # Let the user override the test.
3311 else
3312 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3313 for as_dir in $PATH
3314 do
3315   IFS=$as_save_IFS
3316   test -z "$as_dir" && as_dir=.
3317   for ac_exec_ext in '' $ac_executable_extensions; do
3318   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3319     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3320     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3321     break 2
3322   fi
3323 done
3324 done
3325 IFS=$as_save_IFS
3326
3327 fi
3328 fi
3329 CC=$ac_cv_prog_CC
3330 if test -n "$CC"; then
3331   { $as_echo "$as_me:$LINENO: result: $CC" >&5
3332 $as_echo "$CC" >&6; }
3333 else
3334   { $as_echo "$as_me:$LINENO: result: no" >&5
3335 $as_echo "no" >&6; }
3336 fi
3337
3338
3339     test -n "$CC" && break
3340   done
3341 fi
3342 if test -z "$CC"; then
3343   ac_ct_CC=$CC
3344   for ac_prog in cl.exe
3345 do
3346   # Extract the first word of "$ac_prog", so it can be a program name with args.
3347 set dummy $ac_prog; ac_word=$2
3348 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3349 $as_echo_n "checking for $ac_word... " >&6; }
3350 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3351   $as_echo_n "(cached) " >&6
3352 else
3353   if test -n "$ac_ct_CC"; then
3354   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3355 else
3356 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3357 for as_dir in $PATH
3358 do
3359   IFS=$as_save_IFS
3360   test -z "$as_dir" && as_dir=.
3361   for ac_exec_ext in '' $ac_executable_extensions; do
3362   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3363     ac_cv_prog_ac_ct_CC="$ac_prog"
3364     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3365     break 2
3366   fi
3367 done
3368 done
3369 IFS=$as_save_IFS
3370
3371 fi
3372 fi
3373 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3374 if test -n "$ac_ct_CC"; then
3375   { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3376 $as_echo "$ac_ct_CC" >&6; }
3377 else
3378   { $as_echo "$as_me:$LINENO: result: no" >&5
3379 $as_echo "no" >&6; }
3380 fi
3381
3382
3383   test -n "$ac_ct_CC" && break
3384 done
3385
3386   if test "x$ac_ct_CC" = x; then
3387     CC=""
3388   else
3389     case $cross_compiling:$ac_tool_warned in
3390 yes:)
3391 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
3392 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3393 ac_tool_warned=yes ;;
3394 esac
3395     CC=$ac_ct_CC
3396   fi
3397 fi
3398
3399 fi
3400
3401
3402 test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3403 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3404 { { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
3405 See \`config.log' for more details." >&5
3406 $as_echo "$as_me: error: no acceptable C compiler found in \$PATH
3407 See \`config.log' for more details." >&2;}
3408    { (exit 1); exit 1; }; }; }
3409
3410 # Provide some information about the compiler.
3411 $as_echo "$as_me:$LINENO: checking for C compiler version" >&5
3412 set X $ac_compile
3413 ac_compiler=$2
3414 { (ac_try="$ac_compiler --version >&5"
3415 case "(($ac_try" in
3416   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3417   *) ac_try_echo=$ac_try;;
3418 esac
3419 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3420 $as_echo "$ac_try_echo") >&5
3421   (eval "$ac_compiler --version >&5") 2>&5
3422   ac_status=$?
3423   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3424   (exit $ac_status); }
3425 { (ac_try="$ac_compiler -v >&5"
3426 case "(($ac_try" in
3427   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3428   *) ac_try_echo=$ac_try;;
3429 esac
3430 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3431 $as_echo "$ac_try_echo") >&5
3432   (eval "$ac_compiler -v >&5") 2>&5
3433   ac_status=$?
3434   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3435   (exit $ac_status); }
3436 { (ac_try="$ac_compiler -V >&5"
3437 case "(($ac_try" in
3438   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3439   *) ac_try_echo=$ac_try;;
3440 esac
3441 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3442 $as_echo "$ac_try_echo") >&5
3443   (eval "$ac_compiler -V >&5") 2>&5
3444   ac_status=$?
3445   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3446   (exit $ac_status); }
3447
3448 cat >conftest.$ac_ext <<_ACEOF
3449 /* confdefs.h.  */
3450 _ACEOF
3451 cat confdefs.h >>conftest.$ac_ext
3452 cat >>conftest.$ac_ext <<_ACEOF
3453 /* end confdefs.h.  */
3454
3455 int
3456 main ()
3457 {
3458
3459   ;
3460   return 0;
3461 }
3462 _ACEOF
3463 ac_clean_files_save=$ac_clean_files
3464 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3465 # Try to create an executable without -o first, disregard a.out.
3466 # It will help us diagnose broken compilers, and finding out an intuition
3467 # of exeext.
3468 { $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3469 $as_echo_n "checking for C compiler default output file name... " >&6; }
3470 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3471
3472 # The possible output files:
3473 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3474
3475 ac_rmfiles=
3476 for ac_file in $ac_files
3477 do
3478   case $ac_file in
3479     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3480     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3481   esac
3482 done
3483 rm -f $ac_rmfiles
3484
3485 if { (ac_try="$ac_link_default"
3486 case "(($ac_try" in
3487   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3488   *) ac_try_echo=$ac_try;;
3489 esac
3490 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3491 $as_echo "$ac_try_echo") >&5
3492   (eval "$ac_link_default") 2>&5
3493   ac_status=$?
3494   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3495   (exit $ac_status); }; then
3496   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3497 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3498 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3499 # so that the user can short-circuit this test for compilers unknown to
3500 # Autoconf.
3501 for ac_file in $ac_files ''
3502 do
3503   test -f "$ac_file" || continue
3504   case $ac_file in
3505     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3506         ;;
3507     [ab].out )
3508         # We found the default executable, but exeext='' is most
3509         # certainly right.
3510         break;;
3511     *.* )
3512         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3513         then :; else
3514            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3515         fi
3516         # We set ac_cv_exeext here because the later test for it is not
3517         # safe: cross compilers may not add the suffix if given an `-o'
3518         # argument, so we may need to know it at that point already.
3519         # Even if this section looks crufty: it has the advantage of
3520         # actually working.
3521         break;;
3522     * )
3523         break;;
3524   esac
3525 done
3526 test "$ac_cv_exeext" = no && ac_cv_exeext=
3527
3528 else
3529   ac_file=''
3530 fi
3531
3532 { $as_echo "$as_me:$LINENO: result: $ac_file" >&5
3533 $as_echo "$ac_file" >&6; }
3534 if test -z "$ac_file"; then
3535   $as_echo "$as_me: failed program was:" >&5
3536 sed 's/^/| /' conftest.$ac_ext >&5
3537
3538 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3539 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3540 { { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables
3541 See \`config.log' for more details." >&5
3542 $as_echo "$as_me: error: C compiler cannot create executables
3543 See \`config.log' for more details." >&2;}
3544    { (exit 77); exit 77; }; }; }
3545 fi
3546
3547 ac_exeext=$ac_cv_exeext
3548
3549 # Check that the compiler produces executables we can run.  If not, either
3550 # the compiler is broken, or we cross compile.
3551 { $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5
3552 $as_echo_n "checking whether the C compiler works... " >&6; }
3553 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3554 # If not cross compiling, check that we can run a simple program.
3555 if test "$cross_compiling" != yes; then
3556   if { ac_try='./$ac_file'
3557   { (case "(($ac_try" in
3558   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3559   *) ac_try_echo=$ac_try;;
3560 esac
3561 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3562 $as_echo "$ac_try_echo") >&5
3563   (eval "$ac_try") 2>&5
3564   ac_status=$?
3565   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3566   (exit $ac_status); }; }; then
3567     cross_compiling=no
3568   else
3569     if test "$cross_compiling" = maybe; then
3570         cross_compiling=yes
3571     else
3572         { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3573 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3574 { { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs.
3575 If you meant to cross compile, use \`--host'.
3576 See \`config.log' for more details." >&5
3577 $as_echo "$as_me: error: cannot run C compiled programs.
3578 If you meant to cross compile, use \`--host'.
3579 See \`config.log' for more details." >&2;}
3580    { (exit 1); exit 1; }; }; }
3581     fi
3582   fi
3583 fi
3584 { $as_echo "$as_me:$LINENO: result: yes" >&5
3585 $as_echo "yes" >&6; }
3586
3587 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3588 ac_clean_files=$ac_clean_files_save
3589 # Check that the compiler produces executables we can run.  If not, either
3590 # the compiler is broken, or we cross compile.
3591 { $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
3592 $as_echo_n "checking whether we are cross compiling... " >&6; }
3593 { $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5
3594 $as_echo "$cross_compiling" >&6; }
3595
3596 { $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5
3597 $as_echo_n "checking for suffix of executables... " >&6; }
3598 if { (ac_try="$ac_link"
3599 case "(($ac_try" in
3600   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3601   *) ac_try_echo=$ac_try;;
3602 esac
3603 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3604 $as_echo "$ac_try_echo") >&5
3605   (eval "$ac_link") 2>&5
3606   ac_status=$?
3607   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3608   (exit $ac_status); }; then
3609   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3610 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3611 # work properly (i.e., refer to `conftest.exe'), while it won't with
3612 # `rm'.
3613 for ac_file in conftest.exe conftest conftest.*; do
3614   test -f "$ac_file" || continue
3615   case $ac_file in
3616     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3617     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3618           break;;
3619     * ) break;;
3620   esac
3621 done
3622 else
3623   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3624 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3625 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3626 See \`config.log' for more details." >&5
3627 $as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3628 See \`config.log' for more details." >&2;}
3629    { (exit 1); exit 1; }; }; }
3630 fi
3631
3632 rm -f conftest$ac_cv_exeext
3633 { $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
3634 $as_echo "$ac_cv_exeext" >&6; }
3635
3636 rm -f conftest.$ac_ext
3637 EXEEXT=$ac_cv_exeext
3638 ac_exeext=$EXEEXT
3639 { $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5
3640 $as_echo_n "checking for suffix of object files... " >&6; }
3641 if test "${ac_cv_objext+set}" = set; then
3642   $as_echo_n "(cached) " >&6
3643 else
3644   cat >conftest.$ac_ext <<_ACEOF
3645 /* confdefs.h.  */
3646 _ACEOF
3647 cat confdefs.h >>conftest.$ac_ext
3648 cat >>conftest.$ac_ext <<_ACEOF
3649 /* end confdefs.h.  */
3650
3651 int
3652 main ()
3653 {
3654
3655   ;
3656   return 0;
3657 }
3658 _ACEOF
3659 rm -f conftest.o conftest.obj
3660 if { (ac_try="$ac_compile"
3661 case "(($ac_try" in
3662   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3663   *) ac_try_echo=$ac_try;;
3664 esac
3665 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3666 $as_echo "$ac_try_echo") >&5
3667   (eval "$ac_compile") 2>&5
3668   ac_status=$?
3669   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3670   (exit $ac_status); }; then
3671   for ac_file in conftest.o conftest.obj conftest.*; do
3672   test -f "$ac_file" || continue;
3673   case $ac_file in
3674     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3675     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3676        break;;
3677   esac
3678 done
3679 else
3680   $as_echo "$as_me: failed program was:" >&5
3681 sed 's/^/| /' conftest.$ac_ext >&5
3682
3683 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3684 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3685 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3686 See \`config.log' for more details." >&5
3687 $as_echo "$as_me: error: cannot compute suffix of object files: cannot compile
3688 See \`config.log' for more details." >&2;}
3689    { (exit 1); exit 1; }; }; }
3690 fi
3691
3692 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3693 fi
3694 { $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3695 $as_echo "$ac_cv_objext" >&6; }
3696 OBJEXT=$ac_cv_objext
3697 ac_objext=$OBJEXT
3698 { $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3699 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3700 if test "${ac_cv_c_compiler_gnu+set}" = set; then
3701   $as_echo_n "(cached) " >&6
3702 else
3703   cat >conftest.$ac_ext <<_ACEOF
3704 /* confdefs.h.  */
3705 _ACEOF
3706 cat confdefs.h >>conftest.$ac_ext
3707 cat >>conftest.$ac_ext <<_ACEOF
3708 /* end confdefs.h.  */
3709
3710 int
3711 main ()
3712 {
3713 #ifndef __GNUC__
3714        choke me
3715 #endif
3716
3717   ;
3718   return 0;
3719 }
3720 _ACEOF
3721 rm -f conftest.$ac_objext
3722 if { (ac_try="$ac_compile"
3723 case "(($ac_try" in
3724   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3725   *) ac_try_echo=$ac_try;;
3726 esac
3727 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3728 $as_echo "$ac_try_echo") >&5
3729   (eval "$ac_compile") 2>conftest.er1
3730   ac_status=$?
3731   grep -v '^ *+' conftest.er1 >conftest.err
3732   rm -f conftest.er1
3733   cat conftest.err >&5
3734   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3735   (exit $ac_status); } && {
3736          test -z "$ac_c_werror_flag" ||
3737          test ! -s conftest.err
3738        } && test -s conftest.$ac_objext; then
3739   ac_compiler_gnu=yes
3740 else
3741   $as_echo "$as_me: failed program was:" >&5
3742 sed 's/^/| /' conftest.$ac_ext >&5
3743
3744         ac_compiler_gnu=no
3745 fi
3746
3747 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3748 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3749
3750 fi
3751 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3752 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3753 if test $ac_compiler_gnu = yes; then
3754   GCC=yes
3755 else
3756   GCC=
3757 fi
3758 ac_test_CFLAGS=${CFLAGS+set}
3759 ac_save_CFLAGS=$CFLAGS
3760 { $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3761 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3762 if test "${ac_cv_prog_cc_g+set}" = set; then
3763   $as_echo_n "(cached) " >&6
3764 else
3765   ac_save_c_werror_flag=$ac_c_werror_flag
3766    ac_c_werror_flag=yes
3767    ac_cv_prog_cc_g=no
3768    CFLAGS="-g"
3769    cat >conftest.$ac_ext <<_ACEOF
3770 /* confdefs.h.  */
3771 _ACEOF
3772 cat confdefs.h >>conftest.$ac_ext
3773 cat >>conftest.$ac_ext <<_ACEOF
3774 /* end confdefs.h.  */
3775
3776 int
3777 main ()
3778 {
3779
3780   ;
3781   return 0;
3782 }
3783 _ACEOF
3784 rm -f conftest.$ac_objext
3785 if { (ac_try="$ac_compile"
3786 case "(($ac_try" in
3787   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3788   *) ac_try_echo=$ac_try;;
3789 esac
3790 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3791 $as_echo "$ac_try_echo") >&5
3792   (eval "$ac_compile") 2>conftest.er1
3793   ac_status=$?
3794   grep -v '^ *+' conftest.er1 >conftest.err
3795   rm -f conftest.er1
3796   cat conftest.err >&5
3797   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3798   (exit $ac_status); } && {
3799          test -z "$ac_c_werror_flag" ||
3800          test ! -s conftest.err
3801        } && test -s conftest.$ac_objext; then
3802   ac_cv_prog_cc_g=yes
3803 else
3804   $as_echo "$as_me: failed program was:" >&5
3805 sed 's/^/| /' conftest.$ac_ext >&5
3806
3807         CFLAGS=""
3808       cat >conftest.$ac_ext <<_ACEOF
3809 /* confdefs.h.  */
3810 _ACEOF
3811 cat confdefs.h >>conftest.$ac_ext
3812 cat >>conftest.$ac_ext <<_ACEOF
3813 /* end confdefs.h.  */
3814
3815 int
3816 main ()
3817 {
3818
3819   ;
3820   return 0;
3821 }
3822 _ACEOF
3823 rm -f conftest.$ac_objext
3824 if { (ac_try="$ac_compile"
3825 case "(($ac_try" in
3826   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3827   *) ac_try_echo=$ac_try;;
3828 esac
3829 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3830 $as_echo "$ac_try_echo") >&5
3831   (eval "$ac_compile") 2>conftest.er1
3832   ac_status=$?
3833   grep -v '^ *+' conftest.er1 >conftest.err
3834   rm -f conftest.er1
3835   cat conftest.err >&5
3836   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3837   (exit $ac_status); } && {
3838          test -z "$ac_c_werror_flag" ||
3839          test ! -s conftest.err
3840        } && test -s conftest.$ac_objext; then
3841   :
3842 else
3843   $as_echo "$as_me: failed program was:" >&5
3844 sed 's/^/| /' conftest.$ac_ext >&5
3845
3846         ac_c_werror_flag=$ac_save_c_werror_flag
3847          CFLAGS="-g"
3848          cat >conftest.$ac_ext <<_ACEOF
3849 /* confdefs.h.  */
3850 _ACEOF
3851 cat confdefs.h >>conftest.$ac_ext
3852 cat >>conftest.$ac_ext <<_ACEOF
3853 /* end confdefs.h.  */
3854
3855 int
3856 main ()
3857 {
3858
3859   ;
3860   return 0;
3861 }
3862 _ACEOF
3863 rm -f conftest.$ac_objext
3864 if { (ac_try="$ac_compile"
3865 case "(($ac_try" in
3866   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3867   *) ac_try_echo=$ac_try;;
3868 esac
3869 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3870 $as_echo "$ac_try_echo") >&5
3871   (eval "$ac_compile") 2>conftest.er1
3872   ac_status=$?
3873   grep -v '^ *+' conftest.er1 >conftest.err
3874   rm -f conftest.er1
3875   cat conftest.err >&5
3876   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3877   (exit $ac_status); } && {
3878          test -z "$ac_c_werror_flag" ||
3879          test ! -s conftest.err
3880        } && test -s conftest.$ac_objext; then
3881   ac_cv_prog_cc_g=yes
3882 else
3883   $as_echo "$as_me: failed program was:" >&5
3884 sed 's/^/| /' conftest.$ac_ext >&5
3885
3886
3887 fi
3888
3889 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3890 fi
3891
3892 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3893 fi
3894
3895 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3896    ac_c_werror_flag=$ac_save_c_werror_flag
3897 fi
3898 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3899 $as_echo "$ac_cv_prog_cc_g" >&6; }
3900 if test "$ac_test_CFLAGS" = set; then
3901   CFLAGS=$ac_save_CFLAGS
3902 elif test $ac_cv_prog_cc_g = yes; then
3903   if test "$GCC" = yes; then
3904     CFLAGS="-g -O2"
3905   else
3906     CFLAGS="-g"
3907   fi
3908 else
3909   if test "$GCC" = yes; then
3910     CFLAGS="-O2"
3911   else
3912     CFLAGS=
3913   fi
3914 fi
3915 { $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3916 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3917 if test "${ac_cv_prog_cc_c89+set}" = set; then
3918   $as_echo_n "(cached) " >&6
3919 else
3920   ac_cv_prog_cc_c89=no
3921 ac_save_CC=$CC
3922 cat >conftest.$ac_ext <<_ACEOF
3923 /* confdefs.h.  */
3924 _ACEOF
3925 cat confdefs.h >>conftest.$ac_ext
3926 cat >>conftest.$ac_ext <<_ACEOF
3927 /* end confdefs.h.  */
3928 #include <stdarg.h>
3929 #include <stdio.h>
3930 #include <sys/types.h>
3931 #include <sys/stat.h>
3932 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3933 struct buf { int x; };
3934 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3935 static char *e (p, i)
3936      char **p;
3937      int i;
3938 {
3939   return p[i];
3940 }
3941 static char *f (char * (*g) (char **, int), char **p, ...)
3942 {
3943   char *s;
3944   va_list v;
3945   va_start (v,p);
3946   s = g (p, va_arg (v,int));
3947   va_end (v);
3948   return s;
3949 }
3950
3951 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3952    function prototypes and stuff, but not '\xHH' hex character constants.
3953    These don't provoke an error unfortunately, instead are silently treated
3954    as 'x'.  The following induces an error, until -std is added to get
3955    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3956    array size at least.  It's necessary to write '\x00'==0 to get something
3957    that's true only with -std.  */
3958 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3959
3960 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3961    inside strings and character constants.  */
3962 #define FOO(x) 'x'
3963 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3964
3965 int test (int i, double x);
3966 struct s1 {int (*f) (int a);};
3967 struct s2 {int (*f) (double a);};
3968 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3969 int argc;
3970 char **argv;
3971 int
3972 main ()
3973 {
3974 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3975   ;
3976   return 0;
3977 }
3978 _ACEOF
3979 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3980         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3981 do
3982   CC="$ac_save_CC $ac_arg"
3983   rm -f conftest.$ac_objext
3984 if { (ac_try="$ac_compile"
3985 case "(($ac_try" in
3986   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3987   *) ac_try_echo=$ac_try;;
3988 esac
3989 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3990 $as_echo "$ac_try_echo") >&5
3991   (eval "$ac_compile") 2>conftest.er1
3992   ac_status=$?
3993   grep -v '^ *+' conftest.er1 >conftest.err
3994   rm -f conftest.er1
3995   cat conftest.err >&5
3996   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3997   (exit $ac_status); } && {
3998          test -z "$ac_c_werror_flag" ||
3999          test ! -s conftest.err
4000        } && test -s conftest.$ac_objext; then
4001   ac_cv_prog_cc_c89=$ac_arg
4002 else
4003   $as_echo "$as_me: failed program was:" >&5
4004 sed 's/^/| /' conftest.$ac_ext >&5
4005
4006
4007 fi
4008
4009 rm -f core conftest.err conftest.$ac_objext
4010   test "x$ac_cv_prog_cc_c89" != "xno" && break
4011 done
4012 rm -f conftest.$ac_ext
4013 CC=$ac_save_CC
4014
4015 fi
4016 # AC_CACHE_VAL
4017 case "x$ac_cv_prog_cc_c89" in
4018   x)
4019     { $as_echo "$as_me:$LINENO: result: none needed" >&5
4020 $as_echo "none needed" >&6; } ;;
4021   xno)
4022     { $as_echo "$as_me:$LINENO: result: unsupported" >&5
4023 $as_echo "unsupported" >&6; } ;;
4024   *)
4025     CC="$CC $ac_cv_prog_cc_c89"
4026     { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
4027 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4028 esac
4029
4030
4031 ac_ext=c
4032 ac_cpp='$CPP $CPPFLAGS'
4033 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4034 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4035 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4036 DEPDIR="${am__leading_dot}deps"
4037
4038 ac_config_commands="$ac_config_commands depfiles"
4039
4040
4041 am_make=${MAKE-make}
4042 cat > confinc << 'END'
4043 am__doit:
4044         @echo this is the am__doit target
4045 .PHONY: am__doit
4046 END
4047 # If we don't find an include directive, just comment out the code.
4048 { $as_echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
4049 $as_echo_n "checking for style of include used by $am_make... " >&6; }
4050 am__include="#"
4051 am__quote=
4052 _am_result=none
4053 # First try GNU make style include.
4054 echo "include confinc" > confmf
4055 # Ignore all kinds of additional output from `make'.
4056 case `$am_make -s -f confmf 2> /dev/null` in #(
4057 *the\ am__doit\ target*)
4058   am__include=include
4059   am__quote=
4060   _am_result=GNU
4061   ;;
4062 esac
4063 # Now try BSD make style include.
4064 if test "$am__include" = "#"; then
4065    echo '.include "confinc"' > confmf
4066    case `$am_make -s -f confmf 2> /dev/null` in #(
4067    *the\ am__doit\ target*)
4068      am__include=.include
4069      am__quote="\""
4070      _am_result=BSD
4071      ;;
4072    esac
4073 fi
4074
4075
4076 { $as_echo "$as_me:$LINENO: result: $_am_result" >&5
4077 $as_echo "$_am_result" >&6; }
4078 rm -f confinc confmf
4079
4080 # Check whether --enable-dependency-tracking was given.
4081 if test "${enable_dependency_tracking+set}" = set; then
4082   enableval=$enable_dependency_tracking;
4083 fi
4084
4085 if test "x$enable_dependency_tracking" != xno; then
4086   am_depcomp="$ac_aux_dir/depcomp"
4087   AMDEPBACKSLASH='\'
4088 fi
4089  if test "x$enable_dependency_tracking" != xno; then
4090   AMDEP_TRUE=
4091   AMDEP_FALSE='#'
4092 else
4093   AMDEP_TRUE='#'
4094   AMDEP_FALSE=
4095 fi
4096
4097
4098
4099 depcc="$CC"   am_compiler_list=
4100
4101 { $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
4102 $as_echo_n "checking dependency style of $depcc... " >&6; }
4103 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
4104   $as_echo_n "(cached) " >&6
4105 else
4106   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
4107   # We make a subdir and do the tests there.  Otherwise we can end up
4108   # making bogus files that we don't know about and never remove.  For
4109   # instance it was reported that on HP-UX the gcc test will end up
4110   # making a dummy file named `D' -- because `-MD' means `put the output
4111   # in D'.
4112   mkdir conftest.dir
4113   # Copy depcomp to subdir because otherwise we won't find it if we're
4114   # using a relative directory.
4115   cp "$am_depcomp" conftest.dir
4116   cd conftest.dir
4117   # We will build objects and dependencies in a subdirectory because
4118   # it helps to detect inapplicable dependency modes.  For instance
4119   # both Tru64's cc and ICC support -MD to output dependencies as a
4120   # side effect of compilation, but ICC will put the dependencies in
4121   # the current directory while Tru64 will put them in the object
4122   # directory.
4123   mkdir sub
4124
4125   am_cv_CC_dependencies_compiler_type=none
4126   if test "$am_compiler_list" = ""; then
4127      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
4128   fi
4129   am__universal=false
4130   case " $depcc " in #(
4131      *\ -arch\ *\ -arch\ *) am__universal=true ;;
4132      esac
4133
4134   for depmode in $am_compiler_list; do
4135     # Setup a source with many dependencies, because some compilers
4136     # like to wrap large dependency lists on column 80 (with \), and
4137     # we should not choose a depcomp mode which is confused by this.
4138     #
4139     # We need to recreate these files for each test, as the compiler may
4140     # overwrite some of them when testing with obscure command lines.
4141     # This happens at least with the AIX C compiler.
4142     : > sub/conftest.c
4143     for i in 1 2 3 4 5 6; do
4144       echo '#include "conftst'$i'.h"' >> sub/conftest.c
4145       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
4146       # Solaris 8's {/usr,}/bin/sh.
4147       touch sub/conftst$i.h
4148     done
4149     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
4150
4151     # We check with `-c' and `-o' for the sake of the "dashmstdout"
4152     # mode.  It turns out that the SunPro C++ compiler does not properly
4153     # handle `-M -o', and we need to detect this.  Also, some Intel
4154     # versions had trouble with output in subdirs
4155     am__obj=sub/conftest.${OBJEXT-o}
4156     am__minus_obj="-o $am__obj"
4157     case $depmode in
4158     gcc)
4159       # This depmode causes a compiler race in universal mode.
4160       test "$am__universal" = false || continue
4161       ;;
4162     nosideeffect)
4163       # after this tag, mechanisms are not by side-effect, so they'll
4164       # only be used when explicitly requested
4165       if test "x$enable_dependency_tracking" = xyes; then
4166         continue
4167       else
4168         break
4169       fi
4170       ;;
4171     msvisualcpp | msvcmsys)
4172       # This compiler won't grok `-c -o', but also, the minuso test has
4173       # not run yet.  These depmodes are late enough in the game, and
4174       # so weak that their functioning should not be impacted.
4175       am__obj=conftest.${OBJEXT-o}
4176       am__minus_obj=
4177       ;;
4178     none) break ;;
4179     esac
4180     if depmode=$depmode \
4181        source=sub/conftest.c object=$am__obj \
4182        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
4183        $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
4184          >/dev/null 2>conftest.err &&
4185        grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
4186        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
4187        grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
4188        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
4189       # icc doesn't choke on unknown options, it will just issue warnings
4190       # or remarks (even with -Werror).  So we grep stderr for any message
4191       # that says an option was ignored or not supported.
4192       # When given -MP, icc 7.0 and 7.1 complain thusly:
4193       #   icc: Command line warning: ignoring option '-M'; no argument required
4194       # The diagnosis changed in icc 8.0:
4195       #   icc: Command line remark: option '-MP' not supported
4196       if (grep 'ignoring option' conftest.err ||
4197           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
4198         am_cv_CC_dependencies_compiler_type=$depmode
4199         break
4200       fi
4201     fi
4202   done
4203
4204   cd ..
4205   rm -rf conftest.dir
4206 else
4207   am_cv_CC_dependencies_compiler_type=none
4208 fi
4209
4210 fi
4211 { $as_echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
4212 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
4213 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
4214
4215  if
4216   test "x$enable_dependency_tracking" != xno \
4217   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
4218   am__fastdepCC_TRUE=
4219   am__fastdepCC_FALSE='#'
4220 else
4221   am__fastdepCC_TRUE='#'
4222   am__fastdepCC_FALSE=
4223 fi
4224
4225
4226 case `pwd` in
4227   *\ * | *\     *)
4228     { $as_echo "$as_me:$LINENO: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
4229 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
4230 esac
4231
4232
4233
4234 macro_version='2.2.6b'
4235 macro_revision='1.3017'
4236
4237
4238
4239
4240
4241
4242
4243
4244
4245
4246
4247
4248
4249 ltmain="$ac_aux_dir/ltmain.sh"
4250
4251 { $as_echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5
4252 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
4253 if test "${ac_cv_path_SED+set}" = set; then
4254   $as_echo_n "(cached) " >&6
4255 else
4256             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
4257      for ac_i in 1 2 3 4 5 6 7; do
4258        ac_script="$ac_script$as_nl$ac_script"
4259      done
4260      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
4261      $as_unset ac_script || ac_script=
4262      if test -z "$SED"; then
4263   ac_path_SED_found=false
4264   # Loop through the user's path and test for each of PROGNAME-LIST
4265   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4266 for as_dir in $PATH
4267 do
4268   IFS=$as_save_IFS
4269   test -z "$as_dir" && as_dir=.
4270   for ac_prog in sed gsed; do
4271     for ac_exec_ext in '' $ac_executable_extensions; do
4272       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
4273       { test -f "$ac_path_SED" && $as_test_x "$ac_path_SED"; } || continue
4274 # Check for GNU ac_path_SED and select it if it is found.
4275   # Check for GNU $ac_path_SED
4276 case `"$ac_path_SED" --version 2>&1` in
4277 *GNU*)
4278   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
4279 *)
4280   ac_count=0
4281   $as_echo_n 0123456789 >"conftest.in"
4282   while :
4283   do
4284     cat "conftest.in" "conftest.in" >"conftest.tmp"
4285     mv "conftest.tmp" "conftest.in"
4286     cp "conftest.in" "conftest.nl"
4287     $as_echo '' >> "conftest.nl"
4288     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
4289     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4290     ac_count=`expr $ac_count + 1`
4291     if test $ac_count -gt ${ac_path_SED_max-0}; then
4292       # Best one so far, save it but keep looking for a better one
4293       ac_cv_path_SED="$ac_path_SED"
4294       ac_path_SED_max=$ac_count
4295     fi
4296     # 10*(2^10) chars as input seems more than enough
4297     test $ac_count -gt 10 && break
4298   done
4299   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4300 esac
4301
4302       $ac_path_SED_found && break 3
4303     done
4304   done
4305 done
4306 IFS=$as_save_IFS
4307   if test -z "$ac_cv_path_SED"; then
4308     { { $as_echo "$as_me:$LINENO: error: no acceptable sed could be found in \$PATH" >&5
4309 $as_echo "$as_me: error: no acceptable sed could be found in \$PATH" >&2;}
4310    { (exit 1); exit 1; }; }
4311   fi
4312 else
4313   ac_cv_path_SED=$SED
4314 fi
4315
4316 fi
4317 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_SED" >&5
4318 $as_echo "$ac_cv_path_SED" >&6; }
4319  SED="$ac_cv_path_SED"
4320   rm -f conftest.sed
4321
4322 test -z "$SED" && SED=sed
4323 Xsed="$SED -e 1s/^X//"
4324
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335 { $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
4336 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4337 if test "${ac_cv_path_GREP+set}" = set; then
4338   $as_echo_n "(cached) " >&6
4339 else
4340   if test -z "$GREP"; then
4341   ac_path_GREP_found=false
4342   # Loop through the user's path and test for each of PROGNAME-LIST
4343   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4344 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4345 do
4346   IFS=$as_save_IFS
4347   test -z "$as_dir" && as_dir=.
4348   for ac_prog in grep ggrep; do
4349     for ac_exec_ext in '' $ac_executable_extensions; do
4350       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4351       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
4352 # Check for GNU ac_path_GREP and select it if it is found.
4353   # Check for GNU $ac_path_GREP
4354 case `"$ac_path_GREP" --version 2>&1` in
4355 *GNU*)
4356   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4357 *)
4358   ac_count=0
4359   $as_echo_n 0123456789 >"conftest.in"
4360   while :
4361   do
4362     cat "conftest.in" "conftest.in" >"conftest.tmp"
4363     mv "conftest.tmp" "conftest.in"
4364     cp "conftest.in" "conftest.nl"
4365     $as_echo 'GREP' >> "conftest.nl"
4366     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4367     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4368     ac_count=`expr $ac_count + 1`
4369     if test $ac_count -gt ${ac_path_GREP_max-0}; then
4370       # Best one so far, save it but keep looking for a better one
4371       ac_cv_path_GREP="$ac_path_GREP"
4372       ac_path_GREP_max=$ac_count
4373     fi
4374     # 10*(2^10) chars as input seems more than enough
4375     test $ac_count -gt 10 && break
4376   done
4377   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4378 esac
4379
4380       $ac_path_GREP_found && break 3
4381     done
4382   done
4383 done
4384 IFS=$as_save_IFS
4385   if test -z "$ac_cv_path_GREP"; then
4386     { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
4387 $as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
4388    { (exit 1); exit 1; }; }
4389   fi
4390 else
4391   ac_cv_path_GREP=$GREP
4392 fi
4393
4394 fi
4395 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
4396 $as_echo "$ac_cv_path_GREP" >&6; }
4397  GREP="$ac_cv_path_GREP"
4398
4399
4400 { $as_echo "$as_me:$LINENO: checking for egrep" >&5
4401 $as_echo_n "checking for egrep... " >&6; }
4402 if test "${ac_cv_path_EGREP+set}" = set; then
4403   $as_echo_n "(cached) " >&6
4404 else
4405   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4406    then ac_cv_path_EGREP="$GREP -E"
4407    else
4408      if test -z "$EGREP"; then
4409   ac_path_EGREP_found=false
4410   # Loop through the user's path and test for each of PROGNAME-LIST
4411   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4412 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4413 do
4414   IFS=$as_save_IFS
4415   test -z "$as_dir" && as_dir=.
4416   for ac_prog in egrep; do
4417     for ac_exec_ext in '' $ac_executable_extensions; do
4418       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4419       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
4420 # Check for GNU ac_path_EGREP and select it if it is found.
4421   # Check for GNU $ac_path_EGREP
4422 case `"$ac_path_EGREP" --version 2>&1` in
4423 *GNU*)
4424   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4425 *)
4426   ac_count=0
4427   $as_echo_n 0123456789 >"conftest.in"
4428   while :
4429   do
4430     cat "conftest.in" "conftest.in" >"conftest.tmp"
4431     mv "conftest.tmp" "conftest.in"
4432     cp "conftest.in" "conftest.nl"
4433     $as_echo 'EGREP' >> "conftest.nl"
4434     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4435     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4436     ac_count=`expr $ac_count + 1`
4437     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4438       # Best one so far, save it but keep looking for a better one
4439       ac_cv_path_EGREP="$ac_path_EGREP"
4440       ac_path_EGREP_max=$ac_count
4441     fi
4442     # 10*(2^10) chars as input seems more than enough
4443     test $ac_count -gt 10 && break
4444   done
4445   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4446 esac
4447
4448       $ac_path_EGREP_found && break 3
4449     done
4450   done
4451 done
4452 IFS=$as_save_IFS
4453   if test -z "$ac_cv_path_EGREP"; then
4454     { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
4455 $as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
4456    { (exit 1); exit 1; }; }
4457   fi
4458 else
4459   ac_cv_path_EGREP=$EGREP
4460 fi
4461
4462    fi
4463 fi
4464 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
4465 $as_echo "$ac_cv_path_EGREP" >&6; }
4466  EGREP="$ac_cv_path_EGREP"
4467
4468
4469 { $as_echo "$as_me:$LINENO: checking for fgrep" >&5
4470 $as_echo_n "checking for fgrep... " >&6; }
4471 if test "${ac_cv_path_FGREP+set}" = set; then
4472   $as_echo_n "(cached) " >&6
4473 else
4474   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
4475    then ac_cv_path_FGREP="$GREP -F"
4476    else
4477      if test -z "$FGREP"; then
4478   ac_path_FGREP_found=false
4479   # Loop through the user's path and test for each of PROGNAME-LIST
4480   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4481 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4482 do
4483   IFS=$as_save_IFS
4484   test -z "$as_dir" && as_dir=.
4485   for ac_prog in fgrep; do
4486     for ac_exec_ext in '' $ac_executable_extensions; do
4487       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
4488       { test -f "$ac_path_FGREP" && $as_test_x "$ac_path_FGREP"; } || continue
4489 # Check for GNU ac_path_FGREP and select it if it is found.
4490   # Check for GNU $ac_path_FGREP
4491 case `"$ac_path_FGREP" --version 2>&1` in
4492 *GNU*)
4493   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
4494 *)
4495   ac_count=0
4496   $as_echo_n 0123456789 >"conftest.in"
4497   while :
4498   do
4499     cat "conftest.in" "conftest.in" >"conftest.tmp"
4500     mv "conftest.tmp" "conftest.in"
4501     cp "conftest.in" "conftest.nl"
4502     $as_echo 'FGREP' >> "conftest.nl"
4503     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
4504     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4505     ac_count=`expr $ac_count + 1`
4506     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
4507       # Best one so far, save it but keep looking for a better one
4508       ac_cv_path_FGREP="$ac_path_FGREP"
4509       ac_path_FGREP_max=$ac_count
4510     fi
4511     # 10*(2^10) chars as input seems more than enough
4512     test $ac_count -gt 10 && break
4513   done
4514   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4515 esac
4516
4517       $ac_path_FGREP_found && break 3
4518     done
4519   done
4520 done
4521 IFS=$as_save_IFS
4522   if test -z "$ac_cv_path_FGREP"; then
4523     { { $as_echo "$as_me:$LINENO: error: no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
4524 $as_echo "$as_me: error: no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
4525    { (exit 1); exit 1; }; }
4526   fi
4527 else
4528   ac_cv_path_FGREP=$FGREP
4529 fi
4530
4531    fi
4532 fi
4533 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_FGREP" >&5
4534 $as_echo "$ac_cv_path_FGREP" >&6; }
4535  FGREP="$ac_cv_path_FGREP"
4536
4537
4538 test -z "$GREP" && GREP=grep
4539
4540
4541
4542
4543
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556
4557
4558 # Check whether --with-gnu-ld was given.
4559 if test "${with_gnu_ld+set}" = set; then
4560   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
4561 else
4562   with_gnu_ld=no
4563 fi
4564
4565 ac_prog=ld
4566 if test "$GCC" = yes; then
4567   # Check if gcc -print-prog-name=ld gives a path.
4568   { $as_echo "$as_me:$LINENO: checking for ld used by $CC" >&5
4569 $as_echo_n "checking for ld used by $CC... " >&6; }
4570   case $host in
4571   *-*-mingw*)
4572     # gcc leaves a trailing carriage return which upsets mingw
4573     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4574   *)
4575     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4576   esac
4577   case $ac_prog in
4578     # Accept absolute paths.
4579     [\\/]* | ?:[\\/]*)
4580       re_direlt='/[^/][^/]*/\.\./'
4581       # Canonicalize the pathname of ld
4582       ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
4583       while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
4584         ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
4585       done
4586       test -z "$LD" && LD="$ac_prog"
4587       ;;
4588   "")
4589     # If it fails, then pretend we aren't using GCC.
4590     ac_prog=ld
4591     ;;
4592   *)
4593     # If it is relative, then search for the first ld in PATH.
4594     with_gnu_ld=unknown
4595     ;;
4596   esac
4597 elif test "$with_gnu_ld" = yes; then
4598   { $as_echo "$as_me:$LINENO: checking for GNU ld" >&5
4599 $as_echo_n "checking for GNU ld... " >&6; }
4600 else
4601   { $as_echo "$as_me:$LINENO: checking for non-GNU ld" >&5
4602 $as_echo_n "checking for non-GNU ld... " >&6; }
4603 fi
4604 if test "${lt_cv_path_LD+set}" = set; then
4605   $as_echo_n "(cached) " >&6
4606 else
4607   if test -z "$LD"; then
4608   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4609   for ac_dir in $PATH; do
4610     IFS="$lt_save_ifs"
4611     test -z "$ac_dir" && ac_dir=.
4612     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4613       lt_cv_path_LD="$ac_dir/$ac_prog"
4614       # Check to see if the program is GNU ld.  I'd rather use --version,
4615       # but apparently some variants of GNU ld only accept -v.
4616       # Break only if it was the GNU/non-GNU ld that we prefer.
4617       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
4618       *GNU* | *'with BFD'*)
4619         test "$with_gnu_ld" != no && break
4620         ;;
4621       *)
4622         test "$with_gnu_ld" != yes && break
4623         ;;
4624       esac
4625     fi
4626   done
4627   IFS="$lt_save_ifs"
4628 else
4629   lt_cv_path_LD="$LD" # Let the user override the test with a path.
4630 fi
4631 fi
4632
4633 LD="$lt_cv_path_LD"
4634 if test -n "$LD"; then
4635   { $as_echo "$as_me:$LINENO: result: $LD" >&5
4636 $as_echo "$LD" >&6; }
4637 else
4638   { $as_echo "$as_me:$LINENO: result: no" >&5
4639 $as_echo "no" >&6; }
4640 fi
4641 test -z "$LD" && { { $as_echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
4642 $as_echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
4643    { (exit 1); exit 1; }; }
4644 { $as_echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
4645 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
4646 if test "${lt_cv_prog_gnu_ld+set}" = set; then
4647   $as_echo_n "(cached) " >&6
4648 else
4649   # I'd rather use --version here, but apparently some GNU lds only accept -v.
4650 case `$LD -v 2>&1 </dev/null` in
4651 *GNU* | *'with BFD'*)
4652   lt_cv_prog_gnu_ld=yes
4653   ;;
4654 *)
4655   lt_cv_prog_gnu_ld=no
4656   ;;
4657 esac
4658 fi
4659 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_gnu_ld" >&5
4660 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
4661 with_gnu_ld=$lt_cv_prog_gnu_ld
4662
4663
4664
4665
4666
4667
4668
4669
4670
4671 { $as_echo "$as_me:$LINENO: checking for BSD- or MS-compatible name lister (nm)" >&5
4672 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
4673 if test "${lt_cv_path_NM+set}" = set; then
4674   $as_echo_n "(cached) " >&6
4675 else
4676   if test -n "$NM"; then
4677   # Let the user override the test.
4678   lt_cv_path_NM="$NM"
4679 else
4680   lt_nm_to_check="${ac_tool_prefix}nm"
4681   if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
4682     lt_nm_to_check="$lt_nm_to_check nm"
4683   fi
4684   for lt_tmp_nm in $lt_nm_to_check; do
4685     lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
4686     for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
4687       IFS="$lt_save_ifs"
4688       test -z "$ac_dir" && ac_dir=.
4689       tmp_nm="$ac_dir/$lt_tmp_nm"
4690       if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
4691         # Check to see if the nm accepts a BSD-compat flag.
4692         # Adding the `sed 1q' prevents false positives on HP-UX, which says:
4693         #   nm: unknown option "B" ignored
4694         # Tru64's nm complains that /dev/null is an invalid object file
4695         case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
4696         */dev/null* | *'Invalid file or object type'*)
4697           lt_cv_path_NM="$tmp_nm -B"
4698           break
4699           ;;
4700         *)
4701           case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
4702           */dev/null*)
4703             lt_cv_path_NM="$tmp_nm -p"
4704             break
4705             ;;
4706           *)
4707             lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
4708             continue # so that we can try to find one that supports BSD flags
4709             ;;
4710           esac
4711           ;;
4712         esac
4713       fi
4714     done
4715     IFS="$lt_save_ifs"
4716   done
4717   : ${lt_cv_path_NM=no}
4718 fi
4719 fi
4720 { $as_echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5
4721 $as_echo "$lt_cv_path_NM" >&6; }
4722 if test "$lt_cv_path_NM" != "no"; then
4723   NM="$lt_cv_path_NM"
4724 else
4725   # Didn't find any BSD compatible name lister, look for dumpbin.
4726   if test -n "$ac_tool_prefix"; then
4727   for ac_prog in "dumpbin -symbols" "link -dump -symbols"
4728   do
4729     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4730 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4731 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
4732 $as_echo_n "checking for $ac_word... " >&6; }
4733 if test "${ac_cv_prog_DUMPBIN+set}" = set; then
4734   $as_echo_n "(cached) " >&6
4735 else
4736   if test -n "$DUMPBIN"; then
4737   ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
4738 else
4739 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4740 for as_dir in $PATH
4741 do
4742   IFS=$as_save_IFS
4743   test -z "$as_dir" && as_dir=.
4744   for ac_exec_ext in '' $ac_executable_extensions; do
4745   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4746     ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
4747     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4748     break 2
4749   fi
4750 done
4751 done
4752 IFS=$as_save_IFS
4753
4754 fi
4755 fi
4756 DUMPBIN=$ac_cv_prog_DUMPBIN
4757 if test -n "$DUMPBIN"; then
4758   { $as_echo "$as_me:$LINENO: result: $DUMPBIN" >&5
4759 $as_echo "$DUMPBIN" >&6; }
4760 else
4761   { $as_echo "$as_me:$LINENO: result: no" >&5
4762 $as_echo "no" >&6; }
4763 fi
4764
4765
4766     test -n "$DUMPBIN" && break
4767   done
4768 fi
4769 if test -z "$DUMPBIN"; then
4770   ac_ct_DUMPBIN=$DUMPBIN
4771   for ac_prog in "dumpbin -symbols" "link -dump -symbols"
4772 do
4773   # Extract the first word of "$ac_prog", so it can be a program name with args.
4774 set dummy $ac_prog; ac_word=$2
4775 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
4776 $as_echo_n "checking for $ac_word... " >&6; }
4777 if test "${ac_cv_prog_ac_ct_DUMPBIN+set}" = set; then
4778   $as_echo_n "(cached) " >&6
4779 else
4780   if test -n "$ac_ct_DUMPBIN"; then
4781   ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
4782 else
4783 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4784 for as_dir in $PATH
4785 do
4786   IFS=$as_save_IFS
4787   test -z "$as_dir" && as_dir=.
4788   for ac_exec_ext in '' $ac_executable_extensions; do
4789   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4790     ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
4791     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4792     break 2
4793   fi
4794 done
4795 done
4796 IFS=$as_save_IFS
4797
4798 fi
4799 fi
4800 ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
4801 if test -n "$ac_ct_DUMPBIN"; then
4802   { $as_echo "$as_me:$LINENO: result: $ac_ct_DUMPBIN" >&5
4803 $as_echo "$ac_ct_DUMPBIN" >&6; }
4804 else
4805   { $as_echo "$as_me:$LINENO: result: no" >&5
4806 $as_echo "no" >&6; }
4807 fi
4808
4809
4810   test -n "$ac_ct_DUMPBIN" && break
4811 done
4812
4813   if test "x$ac_ct_DUMPBIN" = x; then
4814     DUMPBIN=":"
4815   else
4816     case $cross_compiling:$ac_tool_warned in
4817 yes:)
4818 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
4819 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4820 ac_tool_warned=yes ;;
4821 esac
4822     DUMPBIN=$ac_ct_DUMPBIN
4823   fi
4824 fi
4825
4826
4827   if test "$DUMPBIN" != ":"; then
4828     NM="$DUMPBIN"
4829   fi
4830 fi
4831 test -z "$NM" && NM=nm
4832
4833
4834
4835
4836
4837
4838 { $as_echo "$as_me:$LINENO: checking the name lister ($NM) interface" >&5
4839 $as_echo_n "checking the name lister ($NM) interface... " >&6; }
4840 if test "${lt_cv_nm_interface+set}" = set; then
4841   $as_echo_n "(cached) " >&6
4842 else
4843   lt_cv_nm_interface="BSD nm"
4844   echo "int some_variable = 0;" > conftest.$ac_ext
4845   (eval echo "\"\$as_me:4845: $ac_compile\"" >&5)
4846   (eval "$ac_compile" 2>conftest.err)
4847   cat conftest.err >&5
4848   (eval echo "\"\$as_me:4848: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
4849   (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
4850   cat conftest.err >&5
4851   (eval echo "\"\$as_me:4851: output\"" >&5)
4852   cat conftest.out >&5
4853   if $GREP 'External.*some_variable' conftest.out > /dev/null; then
4854     lt_cv_nm_interface="MS dumpbin"
4855   fi
4856   rm -f conftest*
4857 fi
4858 { $as_echo "$as_me:$LINENO: result: $lt_cv_nm_interface" >&5
4859 $as_echo "$lt_cv_nm_interface" >&6; }
4860
4861 { $as_echo "$as_me:$LINENO: checking whether ln -s works" >&5
4862 $as_echo_n "checking whether ln -s works... " >&6; }
4863 LN_S=$as_ln_s
4864 if test "$LN_S" = "ln -s"; then
4865   { $as_echo "$as_me:$LINENO: result: yes" >&5
4866 $as_echo "yes" >&6; }
4867 else
4868   { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5
4869 $as_echo "no, using $LN_S" >&6; }
4870 fi
4871
4872 # find the maximum length of command line arguments
4873 { $as_echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5
4874 $as_echo_n "checking the maximum length of command line arguments... " >&6; }
4875 if test "${lt_cv_sys_max_cmd_len+set}" = set; then
4876   $as_echo_n "(cached) " >&6
4877 else
4878     i=0
4879   teststring="ABCD"
4880
4881   case $build_os in
4882   msdosdjgpp*)
4883     # On DJGPP, this test can blow up pretty badly due to problems in libc
4884     # (any single argument exceeding 2000 bytes causes a buffer overrun
4885     # during glob expansion).  Even if it were fixed, the result of this
4886     # check would be larger than it should be.
4887     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
4888     ;;
4889
4890   gnu*)
4891     # Under GNU Hurd, this test is not required because there is
4892     # no limit to the length of command line arguments.
4893     # Libtool will interpret -1 as no limit whatsoever
4894     lt_cv_sys_max_cmd_len=-1;
4895     ;;
4896
4897   cygwin* | mingw* | cegcc*)
4898     # On Win9x/ME, this test blows up -- it succeeds, but takes
4899     # about 5 minutes as the teststring grows exponentially.
4900     # Worse, since 9x/ME are not pre-emptively multitasking,
4901     # you end up with a "frozen" computer, even though with patience
4902     # the test eventually succeeds (with a max line length of 256k).
4903     # Instead, let's just punt: use the minimum linelength reported by
4904     # all of the supported platforms: 8192 (on NT/2K/XP).
4905     lt_cv_sys_max_cmd_len=8192;
4906     ;;
4907
4908   amigaos*)
4909     # On AmigaOS with pdksh, this test takes hours, literally.
4910     # So we just punt and use a minimum line length of 8192.
4911     lt_cv_sys_max_cmd_len=8192;
4912     ;;
4913
4914   netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
4915     # This has been around since 386BSD, at least.  Likely further.
4916     if test -x /sbin/sysctl; then
4917       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
4918     elif test -x /usr/sbin/sysctl; then
4919       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
4920     else
4921       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
4922     fi
4923     # And add a safety zone
4924     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
4925     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
4926     ;;
4927
4928   interix*)
4929     # We know the value 262144 and hardcode it with a safety zone (like BSD)
4930     lt_cv_sys_max_cmd_len=196608
4931     ;;
4932
4933   osf*)
4934     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
4935     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
4936     # nice to cause kernel panics so lets avoid the loop below.
4937     # First set a reasonable default.
4938     lt_cv_sys_max_cmd_len=16384
4939     #
4940     if test -x /sbin/sysconfig; then
4941       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
4942         *1*) lt_cv_sys_max_cmd_len=-1 ;;
4943       esac
4944     fi
4945     ;;
4946   sco3.2v5*)
4947     lt_cv_sys_max_cmd_len=102400
4948     ;;
4949   sysv5* | sco5v6* | sysv4.2uw2*)
4950     kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
4951     if test -n "$kargmax"; then
4952       lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[  ]//'`
4953     else
4954       lt_cv_sys_max_cmd_len=32768
4955     fi
4956     ;;
4957   *)
4958     lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
4959     if test -n "$lt_cv_sys_max_cmd_len"; then
4960       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
4961       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
4962     else
4963       # Make teststring a little bigger before we do anything with it.
4964       # a 1K string should be a reasonable start.
4965       for i in 1 2 3 4 5 6 7 8 ; do
4966         teststring=$teststring$teststring
4967       done
4968       SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
4969       # If test is not a shell built-in, we'll probably end up computing a
4970       # maximum length that is only half of the actual maximum length, but
4971       # we can't tell.
4972       while { test "X"`$SHELL $0 --fallback-echo "X$teststring$teststring" 2>/dev/null` \
4973                  = "XX$teststring$teststring"; } >/dev/null 2>&1 &&
4974               test $i != 17 # 1/2 MB should be enough
4975       do
4976         i=`expr $i + 1`
4977         teststring=$teststring$teststring
4978       done
4979       # Only check the string length outside the loop.
4980       lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
4981       teststring=
4982       # Add a significant safety factor because C++ compilers can tack on
4983       # massive amounts of additional arguments before passing them to the
4984       # linker.  It appears as though 1/2 is a usable value.
4985       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
4986     fi
4987     ;;
4988   esac
4989
4990 fi
4991
4992 if test -n $lt_cv_sys_max_cmd_len ; then
4993   { $as_echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5
4994 $as_echo "$lt_cv_sys_max_cmd_len" >&6; }
4995 else
4996   { $as_echo "$as_me:$LINENO: result: none" >&5
4997 $as_echo "none" >&6; }
4998 fi
4999 max_cmd_len=$lt_cv_sys_max_cmd_len
5000
5001
5002
5003
5004
5005
5006 : ${CP="cp -f"}
5007 : ${MV="mv -f"}
5008 : ${RM="rm -f"}
5009
5010 { $as_echo "$as_me:$LINENO: checking whether the shell understands some XSI constructs" >&5
5011 $as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
5012 # Try some XSI features
5013 xsi_shell=no
5014 ( _lt_dummy="a/b/c"
5015   test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
5016       = c,a/b,, \
5017     && eval 'test $(( 1 + 1 )) -eq 2 \
5018     && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
5019   && xsi_shell=yes
5020 { $as_echo "$as_me:$LINENO: result: $xsi_shell" >&5
5021 $as_echo "$xsi_shell" >&6; }
5022
5023
5024 { $as_echo "$as_me:$LINENO: checking whether the shell understands \"+=\"" >&5
5025 $as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
5026 lt_shell_append=no
5027 ( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
5028     >/dev/null 2>&1 \
5029   && lt_shell_append=yes
5030 { $as_echo "$as_me:$LINENO: result: $lt_shell_append" >&5
5031 $as_echo "$lt_shell_append" >&6; }
5032
5033
5034 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
5035   lt_unset=unset
5036 else
5037   lt_unset=false
5038 fi
5039
5040
5041
5042
5043
5044 # test EBCDIC or ASCII
5045 case `echo X|tr X '\101'` in
5046  A) # ASCII based system
5047     # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
5048   lt_SP2NL='tr \040 \012'
5049   lt_NL2SP='tr \015\012 \040\040'
5050   ;;
5051  *) # EBCDIC based system
5052   lt_SP2NL='tr \100 \n'
5053   lt_NL2SP='tr \r\n \100\100'
5054   ;;
5055 esac
5056
5057
5058
5059
5060
5061
5062
5063
5064
5065 { $as_echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5
5066 $as_echo_n "checking for $LD option to reload object files... " >&6; }
5067 if test "${lt_cv_ld_reload_flag+set}" = set; then
5068   $as_echo_n "(cached) " >&6
5069 else
5070   lt_cv_ld_reload_flag='-r'
5071 fi
5072 { $as_echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5
5073 $as_echo "$lt_cv_ld_reload_flag" >&6; }
5074 reload_flag=$lt_cv_ld_reload_flag
5075 case $reload_flag in
5076 "" | " "*) ;;
5077 *) reload_flag=" $reload_flag" ;;
5078 esac
5079 reload_cmds='$LD$reload_flag -o $output$reload_objs'
5080 case $host_os in
5081   darwin*)
5082     if test "$GCC" = yes; then
5083       reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
5084     else
5085       reload_cmds='$LD$reload_flag -o $output$reload_objs'
5086     fi
5087     ;;
5088 esac
5089
5090
5091
5092
5093
5094
5095
5096
5097
5098 if test -n "$ac_tool_prefix"; then
5099   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
5100 set dummy ${ac_tool_prefix}objdump; ac_word=$2
5101 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5102 $as_echo_n "checking for $ac_word... " >&6; }
5103 if test "${ac_cv_prog_OBJDUMP+set}" = set; then
5104   $as_echo_n "(cached) " >&6
5105 else
5106   if test -n "$OBJDUMP"; then
5107   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
5108 else
5109 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5110 for as_dir in $PATH
5111 do
5112   IFS=$as_save_IFS
5113   test -z "$as_dir" && as_dir=.
5114   for ac_exec_ext in '' $ac_executable_extensions; do
5115   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5116     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
5117     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5118     break 2
5119   fi
5120 done
5121 done
5122 IFS=$as_save_IFS
5123
5124 fi
5125 fi
5126 OBJDUMP=$ac_cv_prog_OBJDUMP
5127 if test -n "$OBJDUMP"; then
5128   { $as_echo "$as_me:$LINENO: result: $OBJDUMP" >&5
5129 $as_echo "$OBJDUMP" >&6; }
5130 else
5131   { $as_echo "$as_me:$LINENO: result: no" >&5
5132 $as_echo "no" >&6; }
5133 fi
5134
5135
5136 fi
5137 if test -z "$ac_cv_prog_OBJDUMP"; then
5138   ac_ct_OBJDUMP=$OBJDUMP
5139   # Extract the first word of "objdump", so it can be a program name with args.
5140 set dummy objdump; ac_word=$2
5141 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5142 $as_echo_n "checking for $ac_word... " >&6; }
5143 if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then
5144   $as_echo_n "(cached) " >&6
5145 else
5146   if test -n "$ac_ct_OBJDUMP"; then
5147   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
5148 else
5149 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5150 for as_dir in $PATH
5151 do
5152   IFS=$as_save_IFS
5153   test -z "$as_dir" && as_dir=.
5154   for ac_exec_ext in '' $ac_executable_extensions; do
5155   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5156     ac_cv_prog_ac_ct_OBJDUMP="objdump"
5157     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5158     break 2
5159   fi
5160 done
5161 done
5162 IFS=$as_save_IFS
5163
5164 fi
5165 fi
5166 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
5167 if test -n "$ac_ct_OBJDUMP"; then
5168   { $as_echo "$as_me:$LINENO: result: $ac_ct_OBJDUMP" >&5
5169 $as_echo "$ac_ct_OBJDUMP" >&6; }
5170 else
5171   { $as_echo "$as_me:$LINENO: result: no" >&5
5172 $as_echo "no" >&6; }
5173 fi
5174
5175   if test "x$ac_ct_OBJDUMP" = x; then
5176     OBJDUMP="false"
5177   else
5178     case $cross_compiling:$ac_tool_warned in
5179 yes:)
5180 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
5181 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5182 ac_tool_warned=yes ;;
5183 esac
5184     OBJDUMP=$ac_ct_OBJDUMP
5185   fi
5186 else
5187   OBJDUMP="$ac_cv_prog_OBJDUMP"
5188 fi
5189
5190 test -z "$OBJDUMP" && OBJDUMP=objdump
5191
5192
5193
5194
5195
5196
5197
5198
5199
5200 { $as_echo "$as_me:$LINENO: checking how to recognize dependent libraries" >&5
5201 $as_echo_n "checking how to recognize dependent libraries... " >&6; }
5202 if test "${lt_cv_deplibs_check_method+set}" = set; then
5203   $as_echo_n "(cached) " >&6
5204 else
5205   lt_cv_file_magic_cmd='$MAGIC_CMD'
5206 lt_cv_file_magic_test_file=
5207 lt_cv_deplibs_check_method='unknown'
5208 # Need to set the preceding variable on all platforms that support
5209 # interlibrary dependencies.
5210 # 'none' -- dependencies not supported.
5211 # `unknown' -- same as none, but documents that we really don't know.
5212 # 'pass_all' -- all dependencies passed with no checks.
5213 # 'test_compile' -- check by making test program.
5214 # 'file_magic [[regex]]' -- check by looking for files in library path
5215 # which responds to the $file_magic_cmd with a given extended regex.
5216 # If you have `file' or equivalent on your system and you're not sure
5217 # whether `pass_all' will *always* work, you probably want this one.
5218
5219 case $host_os in
5220 aix[4-9]*)
5221   lt_cv_deplibs_check_method=pass_all
5222   ;;
5223
5224 beos*)
5225   lt_cv_deplibs_check_method=pass_all
5226   ;;
5227
5228 bsdi[45]*)
5229   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
5230   lt_cv_file_magic_cmd='/usr/bin/file -L'
5231   lt_cv_file_magic_test_file=/shlib/libc.so
5232   ;;
5233
5234 cygwin*)
5235   # func_win32_libid is a shell function defined in ltmain.sh
5236   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5237   lt_cv_file_magic_cmd='func_win32_libid'
5238   ;;
5239
5240 mingw* | pw32*)
5241   # Base MSYS/MinGW do not provide the 'file' command needed by
5242   # func_win32_libid shell function, so use a weaker test based on 'objdump',
5243   # unless we find 'file', for example because we are cross-compiling.
5244   if ( file / ) >/dev/null 2>&1; then
5245     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
5246     lt_cv_file_magic_cmd='func_win32_libid'
5247   else
5248     lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
5249     lt_cv_file_magic_cmd='$OBJDUMP -f'
5250   fi
5251   ;;
5252
5253 cegcc)
5254   # use the weaker test based on 'objdump'. See mingw*.
5255   lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
5256   lt_cv_file_magic_cmd='$OBJDUMP -f'
5257   ;;
5258
5259 darwin* | rhapsody*)
5260   lt_cv_deplibs_check_method=pass_all
5261   ;;
5262
5263 freebsd* | dragonfly*)
5264   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
5265     case $host_cpu in
5266     i*86 )
5267       # Not sure whether the presence of OpenBSD here was a mistake.
5268       # Let's accept both of them until this is cleared up.
5269       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
5270       lt_cv_file_magic_cmd=/usr/bin/file
5271       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
5272       ;;
5273     esac
5274   else
5275     lt_cv_deplibs_check_method=pass_all
5276   fi
5277   ;;
5278
5279 gnu*)
5280   lt_cv_deplibs_check_method=pass_all
5281   ;;
5282
5283 hpux10.20* | hpux11*)
5284   lt_cv_file_magic_cmd=/usr/bin/file
5285   case $host_cpu in
5286   ia64*)
5287     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
5288     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
5289     ;;
5290   hppa*64*)
5291     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]'
5292     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
5293     ;;
5294   *)
5295     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library'
5296     lt_cv_file_magic_test_file=/usr/lib/libc.sl
5297     ;;
5298   esac
5299   ;;
5300
5301 interix[3-9]*)
5302   # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
5303   lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
5304   ;;
5305
5306 irix5* | irix6* | nonstopux*)
5307   case $LD in
5308   *-32|*"-32 ") libmagic=32-bit;;
5309   *-n32|*"-n32 ") libmagic=N32;;
5310   *-64|*"-64 ") libmagic=64-bit;;
5311   *) libmagic=never-match;;
5312   esac
5313   lt_cv_deplibs_check_method=pass_all
5314   ;;
5315
5316 # This must be Linux ELF.
5317 linux* | k*bsd*-gnu)
5318   lt_cv_deplibs_check_method=pass_all
5319   ;;
5320
5321 netbsd*)
5322   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
5323     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5324   else
5325     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
5326   fi
5327   ;;
5328
5329 newos6*)
5330   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
5331   lt_cv_file_magic_cmd=/usr/bin/file
5332   lt_cv_file_magic_test_file=/usr/lib/libnls.so
5333   ;;
5334
5335 *nto* | *qnx*)
5336   lt_cv_deplibs_check_method=pass_all
5337   ;;
5338
5339 openbsd*)
5340   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
5341     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
5342   else
5343     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
5344   fi
5345   ;;
5346
5347 osf3* | osf4* | osf5*)
5348   lt_cv_deplibs_check_method=pass_all
5349   ;;
5350
5351 rdos*)
5352   lt_cv_deplibs_check_method=pass_all
5353   ;;
5354
5355 solaris*)
5356   lt_cv_deplibs_check_method=pass_all
5357   ;;
5358
5359 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
5360   lt_cv_deplibs_check_method=pass_all
5361   ;;
5362
5363 sysv4 | sysv4.3*)
5364   case $host_vendor in
5365   motorola)
5366     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]'
5367     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
5368     ;;
5369   ncr)
5370     lt_cv_deplibs_check_method=pass_all
5371     ;;
5372   sequent)
5373     lt_cv_file_magic_cmd='/bin/file'
5374     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
5375     ;;
5376   sni)
5377     lt_cv_file_magic_cmd='/bin/file'
5378     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
5379     lt_cv_file_magic_test_file=/lib/libc.so
5380     ;;
5381   siemens)
5382     lt_cv_deplibs_check_method=pass_all
5383     ;;
5384   pc)
5385     lt_cv_deplibs_check_method=pass_all
5386     ;;
5387   esac
5388   ;;
5389
5390 tpf*)
5391   lt_cv_deplibs_check_method=pass_all
5392   ;;
5393 esac
5394
5395 fi
5396 { $as_echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5
5397 $as_echo "$lt_cv_deplibs_check_method" >&6; }
5398 file_magic_cmd=$lt_cv_file_magic_cmd
5399 deplibs_check_method=$lt_cv_deplibs_check_method
5400 test -z "$deplibs_check_method" && deplibs_check_method=unknown
5401
5402
5403
5404
5405
5406
5407
5408
5409
5410
5411
5412
5413 if test -n "$ac_tool_prefix"; then
5414   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
5415 set dummy ${ac_tool_prefix}ar; ac_word=$2
5416 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5417 $as_echo_n "checking for $ac_word... " >&6; }
5418 if test "${ac_cv_prog_AR+set}" = set; then
5419   $as_echo_n "(cached) " >&6
5420 else
5421   if test -n "$AR"; then
5422   ac_cv_prog_AR="$AR" # Let the user override the test.
5423 else
5424 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5425 for as_dir in $PATH
5426 do
5427   IFS=$as_save_IFS
5428   test -z "$as_dir" && as_dir=.
5429   for ac_exec_ext in '' $ac_executable_extensions; do
5430   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5431     ac_cv_prog_AR="${ac_tool_prefix}ar"
5432     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5433     break 2
5434   fi
5435 done
5436 done
5437 IFS=$as_save_IFS
5438
5439 fi
5440 fi
5441 AR=$ac_cv_prog_AR
5442 if test -n "$AR"; then
5443   { $as_echo "$as_me:$LINENO: result: $AR" >&5
5444 $as_echo "$AR" >&6; }
5445 else
5446   { $as_echo "$as_me:$LINENO: result: no" >&5
5447 $as_echo "no" >&6; }
5448 fi
5449
5450
5451 fi
5452 if test -z "$ac_cv_prog_AR"; then
5453   ac_ct_AR=$AR
5454   # Extract the first word of "ar", so it can be a program name with args.
5455 set dummy ar; ac_word=$2
5456 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5457 $as_echo_n "checking for $ac_word... " >&6; }
5458 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
5459   $as_echo_n "(cached) " >&6
5460 else
5461   if test -n "$ac_ct_AR"; then
5462   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
5463 else
5464 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5465 for as_dir in $PATH
5466 do
5467   IFS=$as_save_IFS
5468   test -z "$as_dir" && as_dir=.
5469   for ac_exec_ext in '' $ac_executable_extensions; do
5470   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5471     ac_cv_prog_ac_ct_AR="ar"
5472     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5473     break 2
5474   fi
5475 done
5476 done
5477 IFS=$as_save_IFS
5478
5479 fi
5480 fi
5481 ac_ct_AR=$ac_cv_prog_ac_ct_AR
5482 if test -n "$ac_ct_AR"; then
5483   { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
5484 $as_echo "$ac_ct_AR" >&6; }
5485 else
5486   { $as_echo "$as_me:$LINENO: result: no" >&5
5487 $as_echo "no" >&6; }
5488 fi
5489
5490   if test "x$ac_ct_AR" = x; then
5491     AR="false"
5492   else
5493     case $cross_compiling:$ac_tool_warned in
5494 yes:)
5495 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
5496 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5497 ac_tool_warned=yes ;;
5498 esac
5499     AR=$ac_ct_AR
5500   fi
5501 else
5502   AR="$ac_cv_prog_AR"
5503 fi
5504
5505 test -z "$AR" && AR=ar
5506 test -z "$AR_FLAGS" && AR_FLAGS=cru
5507
5508
5509
5510
5511
5512
5513
5514
5515
5516
5517
5518 if test -n "$ac_tool_prefix"; then
5519   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
5520 set dummy ${ac_tool_prefix}strip; ac_word=$2
5521 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5522 $as_echo_n "checking for $ac_word... " >&6; }
5523 if test "${ac_cv_prog_STRIP+set}" = set; then
5524   $as_echo_n "(cached) " >&6
5525 else
5526   if test -n "$STRIP"; then
5527   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
5528 else
5529 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5530 for as_dir in $PATH
5531 do
5532   IFS=$as_save_IFS
5533   test -z "$as_dir" && as_dir=.
5534   for ac_exec_ext in '' $ac_executable_extensions; do
5535   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5536     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
5537     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5538     break 2
5539   fi
5540 done
5541 done
5542 IFS=$as_save_IFS
5543
5544 fi
5545 fi
5546 STRIP=$ac_cv_prog_STRIP
5547 if test -n "$STRIP"; then
5548   { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
5549 $as_echo "$STRIP" >&6; }
5550 else
5551   { $as_echo "$as_me:$LINENO: result: no" >&5
5552 $as_echo "no" >&6; }
5553 fi
5554
5555
5556 fi
5557 if test -z "$ac_cv_prog_STRIP"; then
5558   ac_ct_STRIP=$STRIP
5559   # Extract the first word of "strip", so it can be a program name with args.
5560 set dummy strip; ac_word=$2
5561 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5562 $as_echo_n "checking for $ac_word... " >&6; }
5563 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
5564   $as_echo_n "(cached) " >&6
5565 else
5566   if test -n "$ac_ct_STRIP"; then
5567   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
5568 else
5569 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5570 for as_dir in $PATH
5571 do
5572   IFS=$as_save_IFS
5573   test -z "$as_dir" && as_dir=.
5574   for ac_exec_ext in '' $ac_executable_extensions; do
5575   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5576     ac_cv_prog_ac_ct_STRIP="strip"
5577     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5578     break 2
5579   fi
5580 done
5581 done
5582 IFS=$as_save_IFS
5583
5584 fi
5585 fi
5586 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
5587 if test -n "$ac_ct_STRIP"; then
5588   { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
5589 $as_echo "$ac_ct_STRIP" >&6; }
5590 else
5591   { $as_echo "$as_me:$LINENO: result: no" >&5
5592 $as_echo "no" >&6; }
5593 fi
5594
5595   if test "x$ac_ct_STRIP" = x; then
5596     STRIP=":"
5597   else
5598     case $cross_compiling:$ac_tool_warned in
5599 yes:)
5600 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
5601 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5602 ac_tool_warned=yes ;;
5603 esac
5604     STRIP=$ac_ct_STRIP
5605   fi
5606 else
5607   STRIP="$ac_cv_prog_STRIP"
5608 fi
5609
5610 test -z "$STRIP" && STRIP=:
5611
5612
5613
5614
5615
5616
5617 if test -n "$ac_tool_prefix"; then
5618   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5619 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5620 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5621 $as_echo_n "checking for $ac_word... " >&6; }
5622 if test "${ac_cv_prog_RANLIB+set}" = set; then
5623   $as_echo_n "(cached) " >&6
5624 else
5625   if test -n "$RANLIB"; then
5626   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5627 else
5628 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5629 for as_dir in $PATH
5630 do
5631   IFS=$as_save_IFS
5632   test -z "$as_dir" && as_dir=.
5633   for ac_exec_ext in '' $ac_executable_extensions; do
5634   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5635     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5636     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5637     break 2
5638   fi
5639 done
5640 done
5641 IFS=$as_save_IFS
5642
5643 fi
5644 fi
5645 RANLIB=$ac_cv_prog_RANLIB
5646 if test -n "$RANLIB"; then
5647   { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
5648 $as_echo "$RANLIB" >&6; }
5649 else
5650   { $as_echo "$as_me:$LINENO: result: no" >&5
5651 $as_echo "no" >&6; }
5652 fi
5653
5654
5655 fi
5656 if test -z "$ac_cv_prog_RANLIB"; then
5657   ac_ct_RANLIB=$RANLIB
5658   # Extract the first word of "ranlib", so it can be a program name with args.
5659 set dummy ranlib; ac_word=$2
5660 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5661 $as_echo_n "checking for $ac_word... " >&6; }
5662 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
5663   $as_echo_n "(cached) " >&6
5664 else
5665   if test -n "$ac_ct_RANLIB"; then
5666   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5667 else
5668 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5669 for as_dir in $PATH
5670 do
5671   IFS=$as_save_IFS
5672   test -z "$as_dir" && as_dir=.
5673   for ac_exec_ext in '' $ac_executable_extensions; do
5674   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5675     ac_cv_prog_ac_ct_RANLIB="ranlib"
5676     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5677     break 2
5678   fi
5679 done
5680 done
5681 IFS=$as_save_IFS
5682
5683 fi
5684 fi
5685 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5686 if test -n "$ac_ct_RANLIB"; then
5687   { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
5688 $as_echo "$ac_ct_RANLIB" >&6; }
5689 else
5690   { $as_echo "$as_me:$LINENO: result: no" >&5
5691 $as_echo "no" >&6; }
5692 fi
5693
5694   if test "x$ac_ct_RANLIB" = x; then
5695     RANLIB=":"
5696   else
5697     case $cross_compiling:$ac_tool_warned in
5698 yes:)
5699 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
5700 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5701 ac_tool_warned=yes ;;
5702 esac
5703     RANLIB=$ac_ct_RANLIB
5704   fi
5705 else
5706   RANLIB="$ac_cv_prog_RANLIB"
5707 fi
5708
5709 test -z "$RANLIB" && RANLIB=:
5710
5711
5712
5713
5714
5715
5716 # Determine commands to create old-style static archives.
5717 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
5718 old_postinstall_cmds='chmod 644 $oldlib'
5719 old_postuninstall_cmds=
5720
5721 if test -n "$RANLIB"; then
5722   case $host_os in
5723   openbsd*)
5724     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
5725     ;;
5726   *)
5727     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
5728     ;;
5729   esac
5730   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
5731 fi
5732
5733
5734
5735
5736
5737
5738
5739
5740
5741
5742
5743
5744
5745
5746
5747
5748
5749
5750
5751
5752
5753
5754
5755
5756
5757
5758
5759
5760
5761
5762
5763
5764
5765
5766 # If no C compiler was specified, use CC.
5767 LTCC=${LTCC-"$CC"}
5768
5769 # If no C compiler flags were specified, use CFLAGS.
5770 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
5771
5772 # Allow CC to be a program name with arguments.
5773 compiler=$CC
5774
5775
5776 # Check for command to grab the raw symbol name followed by C symbol from nm.
5777 { $as_echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5
5778 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
5779 if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then
5780   $as_echo_n "(cached) " >&6
5781 else
5782
5783 # These are sane defaults that work on at least a few old systems.
5784 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
5785
5786 # Character class describing NM global symbol codes.
5787 symcode='[BCDEGRST]'
5788
5789 # Regexp to match symbols that can be accessed directly from C.
5790 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
5791
5792 # Define system-specific variables.
5793 case $host_os in
5794 aix*)
5795   symcode='[BCDT]'
5796   ;;
5797 cygwin* | mingw* | pw32* | cegcc*)
5798   symcode='[ABCDGISTW]'
5799   ;;
5800 hpux*)
5801   if test "$host_cpu" = ia64; then
5802     symcode='[ABCDEGRST]'
5803   fi
5804   ;;
5805 irix* | nonstopux*)
5806   symcode='[BCDEGRST]'
5807   ;;
5808 osf*)
5809   symcode='[BCDEGQRST]'
5810   ;;
5811 solaris*)
5812   symcode='[BDRT]'
5813   ;;
5814 sco3.2v5*)
5815   symcode='[DT]'
5816   ;;
5817 sysv4.2uw2*)
5818   symcode='[DT]'
5819   ;;
5820 sysv5* | sco5v6* | unixware* | OpenUNIX*)
5821   symcode='[ABDT]'
5822   ;;
5823 sysv4)
5824   symcode='[DFNSTU]'
5825   ;;
5826 esac
5827
5828 # If we're using GNU nm, then use its standard symbol codes.
5829 case `$NM -V 2>&1` in
5830 *GNU* | *'with BFD'*)
5831   symcode='[ABCDGIRSTW]' ;;
5832 esac
5833
5834 # Transform an extracted symbol line into a proper C declaration.
5835 # Some systems (esp. on ia64) link data and code symbols differently,
5836 # so use this general approach.
5837 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
5838
5839 # Transform an extracted symbol line into symbol name and symbol address
5840 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (void *) \&\2},/p'"
5841 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
5842
5843 # Handle CRLF in mingw tool chain
5844 opt_cr=
5845 case $build_os in
5846 mingw*)
5847   opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
5848   ;;
5849 esac
5850
5851 # Try without a prefix underscore, then with it.
5852 for ac_symprfx in "" "_"; do
5853
5854   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
5855   symxfrm="\\1 $ac_symprfx\\2 \\2"
5856
5857   # Write the raw and C identifiers.
5858   if test "$lt_cv_nm_interface" = "MS dumpbin"; then
5859     # Fake it for dumpbin and say T for any non-static function
5860     # and D for any global variable.
5861     # Also find C++ and __fastcall symbols from MSVC++,
5862     # which start with @ or ?.
5863     lt_cv_sys_global_symbol_pipe="$AWK '"\
5864 "     {last_section=section; section=\$ 3};"\
5865 "     /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
5866 "     \$ 0!~/External *\|/{next};"\
5867 "     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
5868 "     {if(hide[section]) next};"\
5869 "     {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
5870 "     {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
5871 "     s[1]~/^[@?]/{print s[1], s[1]; next};"\
5872 "     s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
5873 "     ' prfx=^$ac_symprfx"
5874   else
5875     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[      ]\($symcode$symcode*\)[         ][      ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
5876   fi
5877
5878   # Check to see that the pipe works correctly.
5879   pipe_works=no
5880
5881   rm -f conftest*
5882   cat > conftest.$ac_ext <<_LT_EOF
5883 #ifdef __cplusplus
5884 extern "C" {
5885 #endif
5886 char nm_test_var;
5887 void nm_test_func(void);
5888 void nm_test_func(void){}
5889 #ifdef __cplusplus
5890 }
5891 #endif
5892 int main(){nm_test_var='a';nm_test_func();return(0);}
5893 _LT_EOF
5894
5895   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
5896   (eval $ac_compile) 2>&5
5897   ac_status=$?
5898   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5899   (exit $ac_status); }; then
5900     # Now try to grab the symbols.
5901     nlist=conftest.nm
5902     if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5
5903   (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5
5904   ac_status=$?
5905   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5906   (exit $ac_status); } && test -s "$nlist"; then
5907       # Try sorting and uniquifying the output.
5908       if sort "$nlist" | uniq > "$nlist"T; then
5909         mv -f "$nlist"T "$nlist"
5910       else
5911         rm -f "$nlist"T
5912       fi
5913
5914       # Make sure that we snagged all the symbols we need.
5915       if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
5916         if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
5917           cat <<_LT_EOF > conftest.$ac_ext
5918 #ifdef __cplusplus
5919 extern "C" {
5920 #endif
5921
5922 _LT_EOF
5923           # Now generate the symbol file.
5924           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
5925
5926           cat <<_LT_EOF >> conftest.$ac_ext
5927
5928 /* The mapping between symbol names and symbols.  */
5929 const struct {
5930   const char *name;
5931   void       *address;
5932 }
5933 lt__PROGRAM__LTX_preloaded_symbols[] =
5934 {
5935   { "@PROGRAM@", (void *) 0 },
5936 _LT_EOF
5937           $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
5938           cat <<\_LT_EOF >> conftest.$ac_ext
5939   {0, (void *) 0}
5940 };
5941
5942 /* This works around a problem in FreeBSD linker */
5943 #ifdef FREEBSD_WORKAROUND
5944 static const void *lt_preloaded_setup() {
5945   return lt__PROGRAM__LTX_preloaded_symbols;
5946 }
5947 #endif
5948
5949 #ifdef __cplusplus
5950 }
5951 #endif
5952 _LT_EOF
5953           # Now try linking the two files.
5954           mv conftest.$ac_objext conftstm.$ac_objext
5955           lt_save_LIBS="$LIBS"
5956           lt_save_CFLAGS="$CFLAGS"
5957           LIBS="conftstm.$ac_objext"
5958           CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
5959           if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5960   (eval $ac_link) 2>&5
5961   ac_status=$?
5962   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5963   (exit $ac_status); } && test -s conftest${ac_exeext}; then
5964             pipe_works=yes
5965           fi
5966           LIBS="$lt_save_LIBS"
5967           CFLAGS="$lt_save_CFLAGS"
5968         else
5969           echo "cannot find nm_test_func in $nlist" >&5
5970         fi
5971       else
5972         echo "cannot find nm_test_var in $nlist" >&5
5973       fi
5974     else
5975       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
5976     fi
5977   else
5978     echo "$progname: failed program was:" >&5
5979     cat conftest.$ac_ext >&5
5980   fi
5981   rm -rf conftest* conftst*
5982
5983   # Do not use the global_symbol_pipe unless it works.
5984   if test "$pipe_works" = yes; then
5985     break
5986   else
5987     lt_cv_sys_global_symbol_pipe=
5988   fi
5989 done
5990
5991 fi
5992
5993 if test -z "$lt_cv_sys_global_symbol_pipe"; then
5994   lt_cv_sys_global_symbol_to_cdecl=
5995 fi
5996 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
5997   { $as_echo "$as_me:$LINENO: result: failed" >&5
5998 $as_echo "failed" >&6; }
5999 else
6000   { $as_echo "$as_me:$LINENO: result: ok" >&5
6001 $as_echo "ok" >&6; }
6002 fi
6003
6004
6005
6006
6007
6008
6009
6010
6011
6012
6013
6014
6015
6016
6017
6018
6019
6020
6021
6022
6023
6024
6025
6026 # Check whether --enable-libtool-lock was given.
6027 if test "${enable_libtool_lock+set}" = set; then
6028   enableval=$enable_libtool_lock;
6029 fi
6030
6031 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
6032
6033 # Some flags need to be propagated to the compiler or linker for good
6034 # libtool support.
6035 case $host in
6036 ia64-*-hpux*)
6037   # Find out which ABI we are using.
6038   echo 'int i;' > conftest.$ac_ext
6039   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6040   (eval $ac_compile) 2>&5
6041   ac_status=$?
6042   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6043   (exit $ac_status); }; then
6044     case `/usr/bin/file conftest.$ac_objext` in
6045       *ELF-32*)
6046         HPUX_IA64_MODE="32"
6047         ;;
6048       *ELF-64*)
6049         HPUX_IA64_MODE="64"
6050         ;;
6051     esac
6052   fi
6053   rm -rf conftest*
6054   ;;
6055 *-*-irix6*)
6056   # Find out which ABI we are using.
6057   echo '#line 6057 "configure"' > conftest.$ac_ext
6058   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6059   (eval $ac_compile) 2>&5
6060   ac_status=$?
6061   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6062   (exit $ac_status); }; then
6063     if test "$lt_cv_prog_gnu_ld" = yes; then
6064       case `/usr/bin/file conftest.$ac_objext` in
6065         *32-bit*)
6066           LD="${LD-ld} -melf32bsmip"
6067           ;;
6068         *N32*)
6069           LD="${LD-ld} -melf32bmipn32"
6070           ;;
6071         *64-bit*)
6072           LD="${LD-ld} -melf64bmip"
6073         ;;
6074       esac
6075     else
6076       case `/usr/bin/file conftest.$ac_objext` in
6077         *32-bit*)
6078           LD="${LD-ld} -32"
6079           ;;
6080         *N32*)
6081           LD="${LD-ld} -n32"
6082           ;;
6083         *64-bit*)
6084           LD="${LD-ld} -64"
6085           ;;
6086       esac
6087     fi
6088   fi
6089   rm -rf conftest*
6090   ;;
6091
6092 x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
6093 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
6094   # Find out which ABI we are using.
6095   echo 'int i;' > conftest.$ac_ext
6096   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6097   (eval $ac_compile) 2>&5
6098   ac_status=$?
6099   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6100   (exit $ac_status); }; then
6101     case `/usr/bin/file conftest.o` in
6102       *32-bit*)
6103         case $host in
6104           x86_64-*kfreebsd*-gnu)
6105             LD="${LD-ld} -m elf_i386_fbsd"
6106             ;;
6107           x86_64-*linux*)
6108             LD="${LD-ld} -m elf_i386"
6109             ;;
6110           ppc64-*linux*|powerpc64-*linux*)
6111             LD="${LD-ld} -m elf32ppclinux"
6112             ;;
6113           s390x-*linux*)
6114             LD="${LD-ld} -m elf_s390"
6115             ;;
6116           sparc64-*linux*)
6117             LD="${LD-ld} -m elf32_sparc"
6118             ;;
6119         esac
6120         ;;
6121       *64-bit*)
6122         case $host in
6123           x86_64-*kfreebsd*-gnu)
6124             LD="${LD-ld} -m elf_x86_64_fbsd"
6125             ;;
6126           x86_64-*linux*)
6127             LD="${LD-ld} -m elf_x86_64"
6128             ;;
6129           ppc*-*linux*|powerpc*-*linux*)
6130             LD="${LD-ld} -m elf64ppc"
6131             ;;
6132           s390*-*linux*|s390*-*tpf*)
6133             LD="${LD-ld} -m elf64_s390"
6134             ;;
6135           sparc*-*linux*)
6136             LD="${LD-ld} -m elf64_sparc"
6137             ;;
6138         esac
6139         ;;
6140     esac
6141   fi
6142   rm -rf conftest*
6143   ;;
6144
6145 *-*-sco3.2v5*)
6146   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
6147   SAVE_CFLAGS="$CFLAGS"
6148   CFLAGS="$CFLAGS -belf"
6149   { $as_echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5
6150 $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
6151 if test "${lt_cv_cc_needs_belf+set}" = set; then
6152   $as_echo_n "(cached) " >&6
6153 else
6154   ac_ext=c
6155 ac_cpp='$CPP $CPPFLAGS'
6156 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6157 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6158 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6159
6160      cat >conftest.$ac_ext <<_ACEOF
6161 /* confdefs.h.  */
6162 _ACEOF
6163 cat confdefs.h >>conftest.$ac_ext
6164 cat >>conftest.$ac_ext <<_ACEOF
6165 /* end confdefs.h.  */
6166
6167 int
6168 main ()
6169 {
6170
6171   ;
6172   return 0;
6173 }
6174 _ACEOF
6175 rm -f conftest.$ac_objext conftest$ac_exeext
6176 if { (ac_try="$ac_link"
6177 case "(($ac_try" in
6178   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6179   *) ac_try_echo=$ac_try;;
6180 esac
6181 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6182 $as_echo "$ac_try_echo") >&5
6183   (eval "$ac_link") 2>conftest.er1
6184   ac_status=$?
6185   grep -v '^ *+' conftest.er1 >conftest.err
6186   rm -f conftest.er1
6187   cat conftest.err >&5
6188   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6189   (exit $ac_status); } && {
6190          test -z "$ac_c_werror_flag" ||
6191          test ! -s conftest.err
6192        } && test -s conftest$ac_exeext && {
6193          test "$cross_compiling" = yes ||
6194          $as_test_x conftest$ac_exeext
6195        }; then
6196   lt_cv_cc_needs_belf=yes
6197 else
6198   $as_echo "$as_me: failed program was:" >&5
6199 sed 's/^/| /' conftest.$ac_ext >&5
6200
6201         lt_cv_cc_needs_belf=no
6202 fi
6203
6204 rm -rf conftest.dSYM
6205 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6206       conftest$ac_exeext conftest.$ac_ext
6207      ac_ext=c
6208 ac_cpp='$CPP $CPPFLAGS'
6209 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6210 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6211 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6212
6213 fi
6214 { $as_echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5
6215 $as_echo "$lt_cv_cc_needs_belf" >&6; }
6216   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
6217     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
6218     CFLAGS="$SAVE_CFLAGS"
6219   fi
6220   ;;
6221 sparc*-*solaris*)
6222   # Find out which ABI we are using.
6223   echo 'int i;' > conftest.$ac_ext
6224   if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
6225   (eval $ac_compile) 2>&5
6226   ac_status=$?
6227   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6228   (exit $ac_status); }; then
6229     case `/usr/bin/file conftest.o` in
6230     *64-bit*)
6231       case $lt_cv_prog_gnu_ld in
6232       yes*) LD="${LD-ld} -m elf64_sparc" ;;
6233       *)
6234         if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
6235           LD="${LD-ld} -64"
6236         fi
6237         ;;
6238       esac
6239       ;;
6240     esac
6241   fi
6242   rm -rf conftest*
6243   ;;
6244 esac
6245
6246 need_locks="$enable_libtool_lock"
6247
6248
6249   case $host_os in
6250     rhapsody* | darwin*)
6251     if test -n "$ac_tool_prefix"; then
6252   # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
6253 set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
6254 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6255 $as_echo_n "checking for $ac_word... " >&6; }
6256 if test "${ac_cv_prog_DSYMUTIL+set}" = set; then
6257   $as_echo_n "(cached) " >&6
6258 else
6259   if test -n "$DSYMUTIL"; then
6260   ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
6261 else
6262 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6263 for as_dir in $PATH
6264 do
6265   IFS=$as_save_IFS
6266   test -z "$as_dir" && as_dir=.
6267   for ac_exec_ext in '' $ac_executable_extensions; do
6268   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6269     ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
6270     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6271     break 2
6272   fi
6273 done
6274 done
6275 IFS=$as_save_IFS
6276
6277 fi
6278 fi
6279 DSYMUTIL=$ac_cv_prog_DSYMUTIL
6280 if test -n "$DSYMUTIL"; then
6281   { $as_echo "$as_me:$LINENO: result: $DSYMUTIL" >&5
6282 $as_echo "$DSYMUTIL" >&6; }
6283 else
6284   { $as_echo "$as_me:$LINENO: result: no" >&5
6285 $as_echo "no" >&6; }
6286 fi
6287
6288
6289 fi
6290 if test -z "$ac_cv_prog_DSYMUTIL"; then
6291   ac_ct_DSYMUTIL=$DSYMUTIL
6292   # Extract the first word of "dsymutil", so it can be a program name with args.
6293 set dummy dsymutil; ac_word=$2
6294 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6295 $as_echo_n "checking for $ac_word... " >&6; }
6296 if test "${ac_cv_prog_ac_ct_DSYMUTIL+set}" = set; then
6297   $as_echo_n "(cached) " >&6
6298 else
6299   if test -n "$ac_ct_DSYMUTIL"; then
6300   ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
6301 else
6302 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6303 for as_dir in $PATH
6304 do
6305   IFS=$as_save_IFS
6306   test -z "$as_dir" && as_dir=.
6307   for ac_exec_ext in '' $ac_executable_extensions; do
6308   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6309     ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
6310     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6311     break 2
6312   fi
6313 done
6314 done
6315 IFS=$as_save_IFS
6316
6317 fi
6318 fi
6319 ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
6320 if test -n "$ac_ct_DSYMUTIL"; then
6321   { $as_echo "$as_me:$LINENO: result: $ac_ct_DSYMUTIL" >&5
6322 $as_echo "$ac_ct_DSYMUTIL" >&6; }
6323 else
6324   { $as_echo "$as_me:$LINENO: result: no" >&5
6325 $as_echo "no" >&6; }
6326 fi
6327
6328   if test "x$ac_ct_DSYMUTIL" = x; then
6329     DSYMUTIL=":"
6330   else
6331     case $cross_compiling:$ac_tool_warned in
6332 yes:)
6333 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6334 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6335 ac_tool_warned=yes ;;
6336 esac
6337     DSYMUTIL=$ac_ct_DSYMUTIL
6338   fi
6339 else
6340   DSYMUTIL="$ac_cv_prog_DSYMUTIL"
6341 fi
6342
6343     if test -n "$ac_tool_prefix"; then
6344   # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
6345 set dummy ${ac_tool_prefix}nmedit; ac_word=$2
6346 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6347 $as_echo_n "checking for $ac_word... " >&6; }
6348 if test "${ac_cv_prog_NMEDIT+set}" = set; then
6349   $as_echo_n "(cached) " >&6
6350 else
6351   if test -n "$NMEDIT"; then
6352   ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
6353 else
6354 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6355 for as_dir in $PATH
6356 do
6357   IFS=$as_save_IFS
6358   test -z "$as_dir" && as_dir=.
6359   for ac_exec_ext in '' $ac_executable_extensions; do
6360   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6361     ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
6362     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6363     break 2
6364   fi
6365 done
6366 done
6367 IFS=$as_save_IFS
6368
6369 fi
6370 fi
6371 NMEDIT=$ac_cv_prog_NMEDIT
6372 if test -n "$NMEDIT"; then
6373   { $as_echo "$as_me:$LINENO: result: $NMEDIT" >&5
6374 $as_echo "$NMEDIT" >&6; }
6375 else
6376   { $as_echo "$as_me:$LINENO: result: no" >&5
6377 $as_echo "no" >&6; }
6378 fi
6379
6380
6381 fi
6382 if test -z "$ac_cv_prog_NMEDIT"; then
6383   ac_ct_NMEDIT=$NMEDIT
6384   # Extract the first word of "nmedit", so it can be a program name with args.
6385 set dummy nmedit; ac_word=$2
6386 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6387 $as_echo_n "checking for $ac_word... " >&6; }
6388 if test "${ac_cv_prog_ac_ct_NMEDIT+set}" = set; then
6389   $as_echo_n "(cached) " >&6
6390 else
6391   if test -n "$ac_ct_NMEDIT"; then
6392   ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
6393 else
6394 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6395 for as_dir in $PATH
6396 do
6397   IFS=$as_save_IFS
6398   test -z "$as_dir" && as_dir=.
6399   for ac_exec_ext in '' $ac_executable_extensions; do
6400   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6401     ac_cv_prog_ac_ct_NMEDIT="nmedit"
6402     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6403     break 2
6404   fi
6405 done
6406 done
6407 IFS=$as_save_IFS
6408
6409 fi
6410 fi
6411 ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
6412 if test -n "$ac_ct_NMEDIT"; then
6413   { $as_echo "$as_me:$LINENO: result: $ac_ct_NMEDIT" >&5
6414 $as_echo "$ac_ct_NMEDIT" >&6; }
6415 else
6416   { $as_echo "$as_me:$LINENO: result: no" >&5
6417 $as_echo "no" >&6; }
6418 fi
6419
6420   if test "x$ac_ct_NMEDIT" = x; then
6421     NMEDIT=":"
6422   else
6423     case $cross_compiling:$ac_tool_warned in
6424 yes:)
6425 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6426 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6427 ac_tool_warned=yes ;;
6428 esac
6429     NMEDIT=$ac_ct_NMEDIT
6430   fi
6431 else
6432   NMEDIT="$ac_cv_prog_NMEDIT"
6433 fi
6434
6435     if test -n "$ac_tool_prefix"; then
6436   # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
6437 set dummy ${ac_tool_prefix}lipo; ac_word=$2
6438 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6439 $as_echo_n "checking for $ac_word... " >&6; }
6440 if test "${ac_cv_prog_LIPO+set}" = set; then
6441   $as_echo_n "(cached) " >&6
6442 else
6443   if test -n "$LIPO"; then
6444   ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
6445 else
6446 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6447 for as_dir in $PATH
6448 do
6449   IFS=$as_save_IFS
6450   test -z "$as_dir" && as_dir=.
6451   for ac_exec_ext in '' $ac_executable_extensions; do
6452   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6453     ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
6454     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6455     break 2
6456   fi
6457 done
6458 done
6459 IFS=$as_save_IFS
6460
6461 fi
6462 fi
6463 LIPO=$ac_cv_prog_LIPO
6464 if test -n "$LIPO"; then
6465   { $as_echo "$as_me:$LINENO: result: $LIPO" >&5
6466 $as_echo "$LIPO" >&6; }
6467 else
6468   { $as_echo "$as_me:$LINENO: result: no" >&5
6469 $as_echo "no" >&6; }
6470 fi
6471
6472
6473 fi
6474 if test -z "$ac_cv_prog_LIPO"; then
6475   ac_ct_LIPO=$LIPO
6476   # Extract the first word of "lipo", so it can be a program name with args.
6477 set dummy lipo; ac_word=$2
6478 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6479 $as_echo_n "checking for $ac_word... " >&6; }
6480 if test "${ac_cv_prog_ac_ct_LIPO+set}" = set; then
6481   $as_echo_n "(cached) " >&6
6482 else
6483   if test -n "$ac_ct_LIPO"; then
6484   ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
6485 else
6486 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6487 for as_dir in $PATH
6488 do
6489   IFS=$as_save_IFS
6490   test -z "$as_dir" && as_dir=.
6491   for ac_exec_ext in '' $ac_executable_extensions; do
6492   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6493     ac_cv_prog_ac_ct_LIPO="lipo"
6494     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6495     break 2
6496   fi
6497 done
6498 done
6499 IFS=$as_save_IFS
6500
6501 fi
6502 fi
6503 ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
6504 if test -n "$ac_ct_LIPO"; then
6505   { $as_echo "$as_me:$LINENO: result: $ac_ct_LIPO" >&5
6506 $as_echo "$ac_ct_LIPO" >&6; }
6507 else
6508   { $as_echo "$as_me:$LINENO: result: no" >&5
6509 $as_echo "no" >&6; }
6510 fi
6511
6512   if test "x$ac_ct_LIPO" = x; then
6513     LIPO=":"
6514   else
6515     case $cross_compiling:$ac_tool_warned in
6516 yes:)
6517 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6518 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6519 ac_tool_warned=yes ;;
6520 esac
6521     LIPO=$ac_ct_LIPO
6522   fi
6523 else
6524   LIPO="$ac_cv_prog_LIPO"
6525 fi
6526
6527     if test -n "$ac_tool_prefix"; then
6528   # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
6529 set dummy ${ac_tool_prefix}otool; ac_word=$2
6530 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6531 $as_echo_n "checking for $ac_word... " >&6; }
6532 if test "${ac_cv_prog_OTOOL+set}" = set; then
6533   $as_echo_n "(cached) " >&6
6534 else
6535   if test -n "$OTOOL"; then
6536   ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
6537 else
6538 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6539 for as_dir in $PATH
6540 do
6541   IFS=$as_save_IFS
6542   test -z "$as_dir" && as_dir=.
6543   for ac_exec_ext in '' $ac_executable_extensions; do
6544   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6545     ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
6546     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6547     break 2
6548   fi
6549 done
6550 done
6551 IFS=$as_save_IFS
6552
6553 fi
6554 fi
6555 OTOOL=$ac_cv_prog_OTOOL
6556 if test -n "$OTOOL"; then
6557   { $as_echo "$as_me:$LINENO: result: $OTOOL" >&5
6558 $as_echo "$OTOOL" >&6; }
6559 else
6560   { $as_echo "$as_me:$LINENO: result: no" >&5
6561 $as_echo "no" >&6; }
6562 fi
6563
6564
6565 fi
6566 if test -z "$ac_cv_prog_OTOOL"; then
6567   ac_ct_OTOOL=$OTOOL
6568   # Extract the first word of "otool", so it can be a program name with args.
6569 set dummy otool; ac_word=$2
6570 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6571 $as_echo_n "checking for $ac_word... " >&6; }
6572 if test "${ac_cv_prog_ac_ct_OTOOL+set}" = set; then
6573   $as_echo_n "(cached) " >&6
6574 else
6575   if test -n "$ac_ct_OTOOL"; then
6576   ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
6577 else
6578 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6579 for as_dir in $PATH
6580 do
6581   IFS=$as_save_IFS
6582   test -z "$as_dir" && as_dir=.
6583   for ac_exec_ext in '' $ac_executable_extensions; do
6584   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6585     ac_cv_prog_ac_ct_OTOOL="otool"
6586     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6587     break 2
6588   fi
6589 done
6590 done
6591 IFS=$as_save_IFS
6592
6593 fi
6594 fi
6595 ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
6596 if test -n "$ac_ct_OTOOL"; then
6597   { $as_echo "$as_me:$LINENO: result: $ac_ct_OTOOL" >&5
6598 $as_echo "$ac_ct_OTOOL" >&6; }
6599 else
6600   { $as_echo "$as_me:$LINENO: result: no" >&5
6601 $as_echo "no" >&6; }
6602 fi
6603
6604   if test "x$ac_ct_OTOOL" = x; then
6605     OTOOL=":"
6606   else
6607     case $cross_compiling:$ac_tool_warned in
6608 yes:)
6609 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6610 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6611 ac_tool_warned=yes ;;
6612 esac
6613     OTOOL=$ac_ct_OTOOL
6614   fi
6615 else
6616   OTOOL="$ac_cv_prog_OTOOL"
6617 fi
6618
6619     if test -n "$ac_tool_prefix"; then
6620   # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
6621 set dummy ${ac_tool_prefix}otool64; ac_word=$2
6622 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6623 $as_echo_n "checking for $ac_word... " >&6; }
6624 if test "${ac_cv_prog_OTOOL64+set}" = set; then
6625   $as_echo_n "(cached) " >&6
6626 else
6627   if test -n "$OTOOL64"; then
6628   ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
6629 else
6630 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6631 for as_dir in $PATH
6632 do
6633   IFS=$as_save_IFS
6634   test -z "$as_dir" && as_dir=.
6635   for ac_exec_ext in '' $ac_executable_extensions; do
6636   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6637     ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
6638     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6639     break 2
6640   fi
6641 done
6642 done
6643 IFS=$as_save_IFS
6644
6645 fi
6646 fi
6647 OTOOL64=$ac_cv_prog_OTOOL64
6648 if test -n "$OTOOL64"; then
6649   { $as_echo "$as_me:$LINENO: result: $OTOOL64" >&5
6650 $as_echo "$OTOOL64" >&6; }
6651 else
6652   { $as_echo "$as_me:$LINENO: result: no" >&5
6653 $as_echo "no" >&6; }
6654 fi
6655
6656
6657 fi
6658 if test -z "$ac_cv_prog_OTOOL64"; then
6659   ac_ct_OTOOL64=$OTOOL64
6660   # Extract the first word of "otool64", so it can be a program name with args.
6661 set dummy otool64; ac_word=$2
6662 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6663 $as_echo_n "checking for $ac_word... " >&6; }
6664 if test "${ac_cv_prog_ac_ct_OTOOL64+set}" = set; then
6665   $as_echo_n "(cached) " >&6
6666 else
6667   if test -n "$ac_ct_OTOOL64"; then
6668   ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
6669 else
6670 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6671 for as_dir in $PATH
6672 do
6673   IFS=$as_save_IFS
6674   test -z "$as_dir" && as_dir=.
6675   for ac_exec_ext in '' $ac_executable_extensions; do
6676   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6677     ac_cv_prog_ac_ct_OTOOL64="otool64"
6678     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6679     break 2
6680   fi
6681 done
6682 done
6683 IFS=$as_save_IFS
6684
6685 fi
6686 fi
6687 ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
6688 if test -n "$ac_ct_OTOOL64"; then
6689   { $as_echo "$as_me:$LINENO: result: $ac_ct_OTOOL64" >&5
6690 $as_echo "$ac_ct_OTOOL64" >&6; }
6691 else
6692   { $as_echo "$as_me:$LINENO: result: no" >&5
6693 $as_echo "no" >&6; }
6694 fi
6695
6696   if test "x$ac_ct_OTOOL64" = x; then
6697     OTOOL64=":"
6698   else
6699     case $cross_compiling:$ac_tool_warned in
6700 yes:)
6701 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6702 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6703 ac_tool_warned=yes ;;
6704 esac
6705     OTOOL64=$ac_ct_OTOOL64
6706   fi
6707 else
6708   OTOOL64="$ac_cv_prog_OTOOL64"
6709 fi
6710
6711
6712
6713
6714
6715
6716
6717
6718
6719
6720
6721
6722
6723
6724
6725
6726
6727
6728
6729
6730
6731
6732
6733
6734
6735
6736
6737     { $as_echo "$as_me:$LINENO: checking for -single_module linker flag" >&5
6738 $as_echo_n "checking for -single_module linker flag... " >&6; }
6739 if test "${lt_cv_apple_cc_single_mod+set}" = set; then
6740   $as_echo_n "(cached) " >&6
6741 else
6742   lt_cv_apple_cc_single_mod=no
6743       if test -z "${LT_MULTI_MODULE}"; then
6744         # By default we will add the -single_module flag. You can override
6745         # by either setting the environment variable LT_MULTI_MODULE
6746         # non-empty at configure time, or by adding -multi_module to the
6747         # link flags.
6748         rm -rf libconftest.dylib*
6749         echo "int foo(void){return 1;}" > conftest.c
6750         echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
6751 -dynamiclib -Wl,-single_module conftest.c" >&5
6752         $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
6753           -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
6754         _lt_result=$?
6755         if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
6756           lt_cv_apple_cc_single_mod=yes
6757         else
6758           cat conftest.err >&5
6759         fi
6760         rm -rf libconftest.dylib*
6761         rm -f conftest.*
6762       fi
6763 fi
6764 { $as_echo "$as_me:$LINENO: result: $lt_cv_apple_cc_single_mod" >&5
6765 $as_echo "$lt_cv_apple_cc_single_mod" >&6; }
6766     { $as_echo "$as_me:$LINENO: checking for -exported_symbols_list linker flag" >&5
6767 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
6768 if test "${lt_cv_ld_exported_symbols_list+set}" = set; then
6769   $as_echo_n "(cached) " >&6
6770 else
6771   lt_cv_ld_exported_symbols_list=no
6772       save_LDFLAGS=$LDFLAGS
6773       echo "_main" > conftest.sym
6774       LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
6775       cat >conftest.$ac_ext <<_ACEOF
6776 /* confdefs.h.  */
6777 _ACEOF
6778 cat confdefs.h >>conftest.$ac_ext
6779 cat >>conftest.$ac_ext <<_ACEOF
6780 /* end confdefs.h.  */
6781
6782 int
6783 main ()
6784 {
6785
6786   ;
6787   return 0;
6788 }
6789 _ACEOF
6790 rm -f conftest.$ac_objext conftest$ac_exeext
6791 if { (ac_try="$ac_link"
6792 case "(($ac_try" in
6793   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6794   *) ac_try_echo=$ac_try;;
6795 esac
6796 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6797 $as_echo "$ac_try_echo") >&5
6798   (eval "$ac_link") 2>conftest.er1
6799   ac_status=$?
6800   grep -v '^ *+' conftest.er1 >conftest.err
6801   rm -f conftest.er1
6802   cat conftest.err >&5
6803   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6804   (exit $ac_status); } && {
6805          test -z "$ac_c_werror_flag" ||
6806          test ! -s conftest.err
6807        } && test -s conftest$ac_exeext && {
6808          test "$cross_compiling" = yes ||
6809          $as_test_x conftest$ac_exeext
6810        }; then
6811   lt_cv_ld_exported_symbols_list=yes
6812 else
6813   $as_echo "$as_me: failed program was:" >&5
6814 sed 's/^/| /' conftest.$ac_ext >&5
6815
6816         lt_cv_ld_exported_symbols_list=no
6817 fi
6818
6819 rm -rf conftest.dSYM
6820 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6821       conftest$ac_exeext conftest.$ac_ext
6822         LDFLAGS="$save_LDFLAGS"
6823
6824 fi
6825 { $as_echo "$as_me:$LINENO: result: $lt_cv_ld_exported_symbols_list" >&5
6826 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
6827     case $host_os in
6828     rhapsody* | darwin1.[012])
6829       _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
6830     darwin1.*)
6831       _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
6832     darwin*) # darwin 5.x on
6833       # if running on 10.5 or later, the deployment target defaults
6834       # to the OS version, if on x86, and 10.4, the deployment
6835       # target defaults to 10.4. Don't you love it?
6836       case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
6837         10.0,*86*-darwin8*|10.0,*-darwin[91]*)
6838           _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
6839         10.[012]*)
6840           _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
6841         10.*)
6842           _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
6843       esac
6844     ;;
6845   esac
6846     if test "$lt_cv_apple_cc_single_mod" = "yes"; then
6847       _lt_dar_single_mod='$single_module'
6848     fi
6849     if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
6850       _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
6851     else
6852       _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
6853     fi
6854     if test "$DSYMUTIL" != ":"; then
6855       _lt_dsymutil='~$DSYMUTIL $lib || :'
6856     else
6857       _lt_dsymutil=
6858     fi
6859     ;;
6860   esac
6861
6862 ac_ext=c
6863 ac_cpp='$CPP $CPPFLAGS'
6864 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6865 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6866 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6867 { $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
6868 $as_echo_n "checking how to run the C preprocessor... " >&6; }
6869 # On Suns, sometimes $CPP names a directory.
6870 if test -n "$CPP" && test -d "$CPP"; then
6871   CPP=
6872 fi
6873 if test -z "$CPP"; then
6874   if test "${ac_cv_prog_CPP+set}" = set; then
6875   $as_echo_n "(cached) " >&6
6876 else
6877       # Double quotes because CPP needs to be expanded
6878     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6879     do
6880       ac_preproc_ok=false
6881 for ac_c_preproc_warn_flag in '' yes
6882 do
6883   # Use a header file that comes with gcc, so configuring glibc
6884   # with a fresh cross-compiler works.
6885   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6886   # <limits.h> exists even on freestanding compilers.
6887   # On the NeXT, cc -E runs the code through the compiler's parser,
6888   # not just through cpp. "Syntax error" is here to catch this case.
6889   cat >conftest.$ac_ext <<_ACEOF
6890 /* confdefs.h.  */
6891 _ACEOF
6892 cat confdefs.h >>conftest.$ac_ext
6893 cat >>conftest.$ac_ext <<_ACEOF
6894 /* end confdefs.h.  */
6895 #ifdef __STDC__
6896 # include <limits.h>
6897 #else
6898 # include <assert.h>
6899 #endif
6900                      Syntax error
6901 _ACEOF
6902 if { (ac_try="$ac_cpp conftest.$ac_ext"
6903 case "(($ac_try" in
6904   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6905   *) ac_try_echo=$ac_try;;
6906 esac
6907 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6908 $as_echo "$ac_try_echo") >&5
6909   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
6910   ac_status=$?
6911   grep -v '^ *+' conftest.er1 >conftest.err
6912   rm -f conftest.er1
6913   cat conftest.err >&5
6914   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6915   (exit $ac_status); } >/dev/null && {
6916          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
6917          test ! -s conftest.err
6918        }; then
6919   :
6920 else
6921   $as_echo "$as_me: failed program was:" >&5
6922 sed 's/^/| /' conftest.$ac_ext >&5
6923
6924   # Broken: fails on valid input.
6925 continue
6926 fi
6927
6928 rm -f conftest.err conftest.$ac_ext
6929
6930   # OK, works on sane cases.  Now check whether nonexistent headers
6931   # can be detected and how.
6932   cat >conftest.$ac_ext <<_ACEOF
6933 /* confdefs.h.  */
6934 _ACEOF
6935 cat confdefs.h >>conftest.$ac_ext
6936 cat >>conftest.$ac_ext <<_ACEOF
6937 /* end confdefs.h.  */
6938 #include <ac_nonexistent.h>
6939 _ACEOF
6940 if { (ac_try="$ac_cpp conftest.$ac_ext"
6941 case "(($ac_try" in
6942   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6943   *) ac_try_echo=$ac_try;;
6944 esac
6945 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6946 $as_echo "$ac_try_echo") >&5
6947   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
6948   ac_status=$?
6949   grep -v '^ *+' conftest.er1 >conftest.err
6950   rm -f conftest.er1
6951   cat conftest.err >&5
6952   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6953   (exit $ac_status); } >/dev/null && {
6954          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
6955          test ! -s conftest.err
6956        }; then
6957   # Broken: success on invalid input.
6958 continue
6959 else
6960   $as_echo "$as_me: failed program was:" >&5
6961 sed 's/^/| /' conftest.$ac_ext >&5
6962
6963   # Passes both tests.
6964 ac_preproc_ok=:
6965 break
6966 fi
6967
6968 rm -f conftest.err conftest.$ac_ext
6969
6970 done
6971 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6972 rm -f conftest.err conftest.$ac_ext
6973 if $ac_preproc_ok; then
6974   break
6975 fi
6976
6977     done
6978     ac_cv_prog_CPP=$CPP
6979
6980 fi
6981   CPP=$ac_cv_prog_CPP
6982 else
6983   ac_cv_prog_CPP=$CPP
6984 fi
6985 { $as_echo "$as_me:$LINENO: result: $CPP" >&5
6986 $as_echo "$CPP" >&6; }
6987 ac_preproc_ok=false
6988 for ac_c_preproc_warn_flag in '' yes
6989 do
6990   # Use a header file that comes with gcc, so configuring glibc
6991   # with a fresh cross-compiler works.
6992   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6993   # <limits.h> exists even on freestanding compilers.
6994   # On the NeXT, cc -E runs the code through the compiler's parser,
6995   # not just through cpp. "Syntax error" is here to catch this case.
6996   cat >conftest.$ac_ext <<_ACEOF
6997 /* confdefs.h.  */
6998 _ACEOF
6999 cat confdefs.h >>conftest.$ac_ext
7000 cat >>conftest.$ac_ext <<_ACEOF
7001 /* end confdefs.h.  */
7002 #ifdef __STDC__
7003 # include <limits.h>
7004 #else
7005 # include <assert.h>
7006 #endif
7007                      Syntax error
7008 _ACEOF
7009 if { (ac_try="$ac_cpp conftest.$ac_ext"
7010 case "(($ac_try" in
7011   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7012   *) ac_try_echo=$ac_try;;
7013 esac
7014 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7015 $as_echo "$ac_try_echo") >&5
7016   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
7017   ac_status=$?
7018   grep -v '^ *+' conftest.er1 >conftest.err
7019   rm -f conftest.er1
7020   cat conftest.err >&5
7021   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7022   (exit $ac_status); } >/dev/null && {
7023          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
7024          test ! -s conftest.err
7025        }; then
7026   :
7027 else
7028   $as_echo "$as_me: failed program was:" >&5
7029 sed 's/^/| /' conftest.$ac_ext >&5
7030
7031   # Broken: fails on valid input.
7032 continue
7033 fi
7034
7035 rm -f conftest.err conftest.$ac_ext
7036
7037   # OK, works on sane cases.  Now check whether nonexistent headers
7038   # can be detected and how.
7039   cat >conftest.$ac_ext <<_ACEOF
7040 /* confdefs.h.  */
7041 _ACEOF
7042 cat confdefs.h >>conftest.$ac_ext
7043 cat >>conftest.$ac_ext <<_ACEOF
7044 /* end confdefs.h.  */
7045 #include <ac_nonexistent.h>
7046 _ACEOF
7047 if { (ac_try="$ac_cpp conftest.$ac_ext"
7048 case "(($ac_try" in
7049   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7050   *) ac_try_echo=$ac_try;;
7051 esac
7052 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7053 $as_echo "$ac_try_echo") >&5
7054   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
7055   ac_status=$?
7056   grep -v '^ *+' conftest.er1 >conftest.err
7057   rm -f conftest.er1
7058   cat conftest.err >&5
7059   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7060   (exit $ac_status); } >/dev/null && {
7061          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
7062          test ! -s conftest.err
7063        }; then
7064   # Broken: success on invalid input.
7065 continue
7066 else
7067   $as_echo "$as_me: failed program was:" >&5
7068 sed 's/^/| /' conftest.$ac_ext >&5
7069
7070   # Passes both tests.
7071 ac_preproc_ok=:
7072 break
7073 fi
7074
7075 rm -f conftest.err conftest.$ac_ext
7076
7077 done
7078 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7079 rm -f conftest.err conftest.$ac_ext
7080 if $ac_preproc_ok; then
7081   :
7082 else
7083   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
7084 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7085 { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
7086 See \`config.log' for more details." >&5
7087 $as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
7088 See \`config.log' for more details." >&2;}
7089    { (exit 1); exit 1; }; }; }
7090 fi
7091
7092 ac_ext=c
7093 ac_cpp='$CPP $CPPFLAGS'
7094 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7095 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7096 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7097
7098
7099 { $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
7100 $as_echo_n "checking for ANSI C header files... " >&6; }
7101 if test "${ac_cv_header_stdc+set}" = set; then
7102   $as_echo_n "(cached) " >&6
7103 else
7104   cat >conftest.$ac_ext <<_ACEOF
7105 /* confdefs.h.  */
7106 _ACEOF
7107 cat confdefs.h >>conftest.$ac_ext
7108 cat >>conftest.$ac_ext <<_ACEOF
7109 /* end confdefs.h.  */
7110 #include <stdlib.h>
7111 #include <stdarg.h>
7112 #include <string.h>
7113 #include <float.h>
7114
7115 int
7116 main ()
7117 {
7118
7119   ;
7120   return 0;
7121 }
7122 _ACEOF
7123 rm -f conftest.$ac_objext
7124 if { (ac_try="$ac_compile"
7125 case "(($ac_try" in
7126   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7127   *) ac_try_echo=$ac_try;;
7128 esac
7129 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7130 $as_echo "$ac_try_echo") >&5
7131   (eval "$ac_compile") 2>conftest.er1
7132   ac_status=$?
7133   grep -v '^ *+' conftest.er1 >conftest.err
7134   rm -f conftest.er1
7135   cat conftest.err >&5
7136   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7137   (exit $ac_status); } && {
7138          test -z "$ac_c_werror_flag" ||
7139          test ! -s conftest.err
7140        } && test -s conftest.$ac_objext; then
7141   ac_cv_header_stdc=yes
7142 else
7143   $as_echo "$as_me: failed program was:" >&5
7144 sed 's/^/| /' conftest.$ac_ext >&5
7145
7146         ac_cv_header_stdc=no
7147 fi
7148
7149 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7150
7151 if test $ac_cv_header_stdc = yes; then
7152   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7153   cat >conftest.$ac_ext <<_ACEOF
7154 /* confdefs.h.  */
7155 _ACEOF
7156 cat confdefs.h >>conftest.$ac_ext
7157 cat >>conftest.$ac_ext <<_ACEOF
7158 /* end confdefs.h.  */
7159 #include <string.h>
7160
7161 _ACEOF
7162 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7163   $EGREP "memchr" >/dev/null 2>&1; then
7164   :
7165 else
7166   ac_cv_header_stdc=no
7167 fi
7168 rm -f conftest*
7169
7170 fi
7171
7172 if test $ac_cv_header_stdc = yes; then
7173   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7174   cat >conftest.$ac_ext <<_ACEOF
7175 /* confdefs.h.  */
7176 _ACEOF
7177 cat confdefs.h >>conftest.$ac_ext
7178 cat >>conftest.$ac_ext <<_ACEOF
7179 /* end confdefs.h.  */
7180 #include <stdlib.h>
7181
7182 _ACEOF
7183 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7184   $EGREP "free" >/dev/null 2>&1; then
7185   :
7186 else
7187   ac_cv_header_stdc=no
7188 fi
7189 rm -f conftest*
7190
7191 fi
7192
7193 if test $ac_cv_header_stdc = yes; then
7194   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7195   if test "$cross_compiling" = yes; then
7196   :
7197 else
7198   cat >conftest.$ac_ext <<_ACEOF
7199 /* confdefs.h.  */
7200 _ACEOF
7201 cat confdefs.h >>conftest.$ac_ext
7202 cat >>conftest.$ac_ext <<_ACEOF
7203 /* end confdefs.h.  */
7204 #include <ctype.h>
7205 #include <stdlib.h>
7206 #if ((' ' & 0x0FF) == 0x020)
7207 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7208 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7209 #else
7210 # define ISLOWER(c) \
7211                    (('a' <= (c) && (c) <= 'i') \
7212                      || ('j' <= (c) && (c) <= 'r') \
7213                      || ('s' <= (c) && (c) <= 'z'))
7214 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7215 #endif
7216
7217 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7218 int
7219 main ()
7220 {
7221   int i;
7222   for (i = 0; i < 256; i++)
7223     if (XOR (islower (i), ISLOWER (i))
7224         || toupper (i) != TOUPPER (i))
7225       return 2;
7226   return 0;
7227 }
7228 _ACEOF
7229 rm -f conftest$ac_exeext
7230 if { (ac_try="$ac_link"
7231 case "(($ac_try" in
7232   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7233   *) ac_try_echo=$ac_try;;
7234 esac
7235 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7236 $as_echo "$ac_try_echo") >&5
7237   (eval "$ac_link") 2>&5
7238   ac_status=$?
7239   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7240   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7241   { (case "(($ac_try" in
7242   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7243   *) ac_try_echo=$ac_try;;
7244 esac
7245 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7246 $as_echo "$ac_try_echo") >&5
7247   (eval "$ac_try") 2>&5
7248   ac_status=$?
7249   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7250   (exit $ac_status); }; }; then
7251   :
7252 else
7253   $as_echo "$as_me: program exited with status $ac_status" >&5
7254 $as_echo "$as_me: failed program was:" >&5
7255 sed 's/^/| /' conftest.$ac_ext >&5
7256
7257 ( exit $ac_status )
7258 ac_cv_header_stdc=no
7259 fi
7260 rm -rf conftest.dSYM
7261 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7262 fi
7263
7264
7265 fi
7266 fi
7267 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
7268 $as_echo "$ac_cv_header_stdc" >&6; }
7269 if test $ac_cv_header_stdc = yes; then
7270
7271 cat >>confdefs.h <<\_ACEOF
7272 #define STDC_HEADERS 1
7273 _ACEOF
7274
7275 fi
7276
7277 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
7278
7279
7280
7281
7282
7283
7284
7285
7286
7287 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7288                   inttypes.h stdint.h unistd.h
7289 do
7290 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7291 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
7292 $as_echo_n "checking for $ac_header... " >&6; }
7293 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7294   $as_echo_n "(cached) " >&6
7295 else
7296   cat >conftest.$ac_ext <<_ACEOF
7297 /* confdefs.h.  */
7298 _ACEOF
7299 cat confdefs.h >>conftest.$ac_ext
7300 cat >>conftest.$ac_ext <<_ACEOF
7301 /* end confdefs.h.  */
7302 $ac_includes_default
7303
7304 #include <$ac_header>
7305 _ACEOF
7306 rm -f conftest.$ac_objext
7307 if { (ac_try="$ac_compile"
7308 case "(($ac_try" in
7309   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7310   *) ac_try_echo=$ac_try;;
7311 esac
7312 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7313 $as_echo "$ac_try_echo") >&5
7314   (eval "$ac_compile") 2>conftest.er1
7315   ac_status=$?
7316   grep -v '^ *+' conftest.er1 >conftest.err
7317   rm -f conftest.er1
7318   cat conftest.err >&5
7319   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7320   (exit $ac_status); } && {
7321          test -z "$ac_c_werror_flag" ||
7322          test ! -s conftest.err
7323        } && test -s conftest.$ac_objext; then
7324   eval "$as_ac_Header=yes"
7325 else
7326   $as_echo "$as_me: failed program was:" >&5
7327 sed 's/^/| /' conftest.$ac_ext >&5
7328
7329         eval "$as_ac_Header=no"
7330 fi
7331
7332 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7333 fi
7334 ac_res=`eval 'as_val=${'$as_ac_Header'}
7335                  $as_echo "$as_val"'`
7336                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
7337 $as_echo "$ac_res" >&6; }
7338 as_val=`eval 'as_val=${'$as_ac_Header'}
7339                  $as_echo "$as_val"'`
7340    if test "x$as_val" = x""yes; then
7341   cat >>confdefs.h <<_ACEOF
7342 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7343 _ACEOF
7344
7345 fi
7346
7347 done
7348
7349
7350
7351 for ac_header in dlfcn.h
7352 do
7353 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7354 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
7355 $as_echo_n "checking for $ac_header... " >&6; }
7356 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7357   $as_echo_n "(cached) " >&6
7358 else
7359   cat >conftest.$ac_ext <<_ACEOF
7360 /* confdefs.h.  */
7361 _ACEOF
7362 cat confdefs.h >>conftest.$ac_ext
7363 cat >>conftest.$ac_ext <<_ACEOF
7364 /* end confdefs.h.  */
7365 $ac_includes_default
7366
7367 #include <$ac_header>
7368 _ACEOF
7369 rm -f conftest.$ac_objext
7370 if { (ac_try="$ac_compile"
7371 case "(($ac_try" in
7372   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7373   *) ac_try_echo=$ac_try;;
7374 esac
7375 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7376 $as_echo "$ac_try_echo") >&5
7377   (eval "$ac_compile") 2>conftest.er1
7378   ac_status=$?
7379   grep -v '^ *+' conftest.er1 >conftest.err
7380   rm -f conftest.er1
7381   cat conftest.err >&5
7382   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7383   (exit $ac_status); } && {
7384          test -z "$ac_c_werror_flag" ||
7385          test ! -s conftest.err
7386        } && test -s conftest.$ac_objext; then
7387   eval "$as_ac_Header=yes"
7388 else
7389   $as_echo "$as_me: failed program was:" >&5
7390 sed 's/^/| /' conftest.$ac_ext >&5
7391
7392         eval "$as_ac_Header=no"
7393 fi
7394
7395 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7396 fi
7397 ac_res=`eval 'as_val=${'$as_ac_Header'}
7398                  $as_echo "$as_val"'`
7399                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
7400 $as_echo "$ac_res" >&6; }
7401 as_val=`eval 'as_val=${'$as_ac_Header'}
7402                  $as_echo "$as_val"'`
7403    if test "x$as_val" = x""yes; then
7404   cat >>confdefs.h <<_ACEOF
7405 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7406 _ACEOF
7407
7408 fi
7409
7410 done
7411
7412
7413
7414 # Set options
7415
7416
7417
7418         enable_dlopen=no
7419
7420
7421   enable_win32_dll=no
7422
7423
7424             # Check whether --enable-shared was given.
7425 if test "${enable_shared+set}" = set; then
7426   enableval=$enable_shared; p=${PACKAGE-default}
7427     case $enableval in
7428     yes) enable_shared=yes ;;
7429     no) enable_shared=no ;;
7430     *)
7431       enable_shared=no
7432       # Look at the argument we got.  We use all the common list separators.
7433       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
7434       for pkg in $enableval; do
7435         IFS="$lt_save_ifs"
7436         if test "X$pkg" = "X$p"; then
7437           enable_shared=yes
7438         fi
7439       done
7440       IFS="$lt_save_ifs"
7441       ;;
7442     esac
7443 else
7444   enable_shared=yes
7445 fi
7446
7447
7448
7449
7450
7451
7452
7453
7454
7455   # Check whether --enable-static was given.
7456 if test "${enable_static+set}" = set; then
7457   enableval=$enable_static; p=${PACKAGE-default}
7458     case $enableval in
7459     yes) enable_static=yes ;;
7460     no) enable_static=no ;;
7461     *)
7462      enable_static=no
7463       # Look at the argument we got.  We use all the common list separators.
7464       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
7465       for pkg in $enableval; do
7466         IFS="$lt_save_ifs"
7467         if test "X$pkg" = "X$p"; then
7468           enable_static=yes
7469         fi
7470       done
7471       IFS="$lt_save_ifs"
7472       ;;
7473     esac
7474 else
7475   enable_static=yes
7476 fi
7477
7478
7479
7480
7481
7482
7483
7484
7485
7486
7487 # Check whether --with-pic was given.
7488 if test "${with_pic+set}" = set; then
7489   withval=$with_pic; pic_mode="$withval"
7490 else
7491   pic_mode=default
7492 fi
7493
7494
7495 test -z "$pic_mode" && pic_mode=default
7496
7497
7498
7499
7500
7501
7502
7503   # Check whether --enable-fast-install was given.
7504 if test "${enable_fast_install+set}" = set; then
7505   enableval=$enable_fast_install; p=${PACKAGE-default}
7506     case $enableval in
7507     yes) enable_fast_install=yes ;;
7508     no) enable_fast_install=no ;;
7509     *)
7510       enable_fast_install=no
7511       # Look at the argument we got.  We use all the common list separators.
7512       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
7513       for pkg in $enableval; do
7514         IFS="$lt_save_ifs"
7515         if test "X$pkg" = "X$p"; then
7516           enable_fast_install=yes
7517         fi
7518       done
7519       IFS="$lt_save_ifs"
7520       ;;
7521     esac
7522 else
7523   enable_fast_install=yes
7524 fi
7525
7526
7527
7528
7529
7530
7531
7532
7533
7534
7535
7536 # This can be used to rebuild libtool when needed
7537 LIBTOOL_DEPS="$ltmain"
7538
7539 # Always use our own libtool.
7540 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
7541
7542
7543
7544
7545
7546
7547
7548
7549
7550
7551
7552
7553
7554
7555
7556
7557
7558
7559
7560
7561
7562
7563
7564
7565
7566 test -z "$LN_S" && LN_S="ln -s"
7567
7568
7569
7570
7571
7572
7573
7574
7575
7576
7577
7578
7579
7580
7581 if test -n "${ZSH_VERSION+set}" ; then
7582    setopt NO_GLOB_SUBST
7583 fi
7584
7585 { $as_echo "$as_me:$LINENO: checking for objdir" >&5
7586 $as_echo_n "checking for objdir... " >&6; }
7587 if test "${lt_cv_objdir+set}" = set; then
7588   $as_echo_n "(cached) " >&6
7589 else
7590   rm -f .libs 2>/dev/null
7591 mkdir .libs 2>/dev/null
7592 if test -d .libs; then
7593   lt_cv_objdir=.libs
7594 else
7595   # MS-DOS does not allow filenames that begin with a dot.
7596   lt_cv_objdir=_libs
7597 fi
7598 rmdir .libs 2>/dev/null
7599 fi
7600 { $as_echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5
7601 $as_echo "$lt_cv_objdir" >&6; }
7602 objdir=$lt_cv_objdir
7603
7604
7605
7606
7607
7608 cat >>confdefs.h <<_ACEOF
7609 #define LT_OBJDIR "$lt_cv_objdir/"
7610 _ACEOF
7611
7612
7613
7614
7615
7616
7617
7618
7619
7620
7621
7622
7623
7624
7625
7626
7627
7628 case $host_os in
7629 aix3*)
7630   # AIX sometimes has problems with the GCC collect2 program.  For some
7631   # reason, if we set the COLLECT_NAMES environment variable, the problems
7632   # vanish in a puff of smoke.
7633   if test "X${COLLECT_NAMES+set}" != Xset; then
7634     COLLECT_NAMES=
7635     export COLLECT_NAMES
7636   fi
7637   ;;
7638 esac
7639
7640 # Sed substitution that helps us do robust quoting.  It backslashifies
7641 # metacharacters that are still active within double-quoted strings.
7642 sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
7643
7644 # Same as above, but do not quote variable references.
7645 double_quote_subst='s/\(["`\\]\)/\\\1/g'
7646
7647 # Sed substitution to delay expansion of an escaped shell variable in a
7648 # double_quote_subst'ed string.
7649 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
7650
7651 # Sed substitution to delay expansion of an escaped single quote.
7652 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
7653
7654 # Sed substitution to avoid accidental globbing in evaled expressions
7655 no_glob_subst='s/\*/\\\*/g'
7656
7657 # Global variables:
7658 ofile=libtool
7659 can_build_shared=yes
7660
7661 # All known linkers require a `.a' archive for static linking (except MSVC,
7662 # which needs '.lib').
7663 libext=a
7664
7665 with_gnu_ld="$lt_cv_prog_gnu_ld"
7666
7667 old_CC="$CC"
7668 old_CFLAGS="$CFLAGS"
7669
7670 # Set sane defaults for various variables
7671 test -z "$CC" && CC=cc
7672 test -z "$LTCC" && LTCC=$CC
7673 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
7674 test -z "$LD" && LD=ld
7675 test -z "$ac_objext" && ac_objext=o
7676
7677 for cc_temp in $compiler""; do
7678   case $cc_temp in
7679     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
7680     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
7681     \-*) ;;
7682     *) break;;
7683   esac
7684 done
7685 cc_basename=`$ECHO "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
7686
7687
7688 # Only perform the check for file, if the check method requires it
7689 test -z "$MAGIC_CMD" && MAGIC_CMD=file
7690 case $deplibs_check_method in
7691 file_magic*)
7692   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
7693     { $as_echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5
7694 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
7695 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7696   $as_echo_n "(cached) " >&6
7697 else
7698   case $MAGIC_CMD in
7699 [\\/*] |  ?:[\\/]*)
7700   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7701   ;;
7702 *)
7703   lt_save_MAGIC_CMD="$MAGIC_CMD"
7704   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7705   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7706   for ac_dir in $ac_dummy; do
7707     IFS="$lt_save_ifs"
7708     test -z "$ac_dir" && ac_dir=.
7709     if test -f $ac_dir/${ac_tool_prefix}file; then
7710       lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
7711       if test -n "$file_magic_test_file"; then
7712         case $deplibs_check_method in
7713         "file_magic "*)
7714           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7715           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7716           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7717             $EGREP "$file_magic_regex" > /dev/null; then
7718             :
7719           else
7720             cat <<_LT_EOF 1>&2
7721
7722 *** Warning: the command libtool uses to detect shared libraries,
7723 *** $file_magic_cmd, produces output that libtool cannot recognize.
7724 *** The result is that libtool may fail to recognize shared libraries
7725 *** as such.  This will affect the creation of libtool libraries that
7726 *** depend on shared libraries, but programs linked with such libtool
7727 *** libraries will work regardless of this problem.  Nevertheless, you
7728 *** may want to report the problem to your system manager and/or to
7729 *** bug-libtool@gnu.org
7730
7731 _LT_EOF
7732           fi ;;
7733         esac
7734       fi
7735       break
7736     fi
7737   done
7738   IFS="$lt_save_ifs"
7739   MAGIC_CMD="$lt_save_MAGIC_CMD"
7740   ;;
7741 esac
7742 fi
7743
7744 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7745 if test -n "$MAGIC_CMD"; then
7746   { $as_echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7747 $as_echo "$MAGIC_CMD" >&6; }
7748 else
7749   { $as_echo "$as_me:$LINENO: result: no" >&5
7750 $as_echo "no" >&6; }
7751 fi
7752
7753
7754
7755
7756
7757 if test -z "$lt_cv_path_MAGIC_CMD"; then
7758   if test -n "$ac_tool_prefix"; then
7759     { $as_echo "$as_me:$LINENO: checking for file" >&5
7760 $as_echo_n "checking for file... " >&6; }
7761 if test "${lt_cv_path_MAGIC_CMD+set}" = set; then
7762   $as_echo_n "(cached) " >&6
7763 else
7764   case $MAGIC_CMD in
7765 [\\/*] |  ?:[\\/]*)
7766   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
7767   ;;
7768 *)
7769   lt_save_MAGIC_CMD="$MAGIC_CMD"
7770   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
7771   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
7772   for ac_dir in $ac_dummy; do
7773     IFS="$lt_save_ifs"
7774     test -z "$ac_dir" && ac_dir=.
7775     if test -f $ac_dir/file; then
7776       lt_cv_path_MAGIC_CMD="$ac_dir/file"
7777       if test -n "$file_magic_test_file"; then
7778         case $deplibs_check_method in
7779         "file_magic "*)
7780           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
7781           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7782           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
7783             $EGREP "$file_magic_regex" > /dev/null; then
7784             :
7785           else
7786             cat <<_LT_EOF 1>&2
7787
7788 *** Warning: the command libtool uses to detect shared libraries,
7789 *** $file_magic_cmd, produces output that libtool cannot recognize.
7790 *** The result is that libtool may fail to recognize shared libraries
7791 *** as such.  This will affect the creation of libtool libraries that
7792 *** depend on shared libraries, but programs linked with such libtool
7793 *** libraries will work regardless of this problem.  Nevertheless, you
7794 *** may want to report the problem to your system manager and/or to
7795 *** bug-libtool@gnu.org
7796
7797 _LT_EOF
7798           fi ;;
7799         esac
7800       fi
7801       break
7802     fi
7803   done
7804   IFS="$lt_save_ifs"
7805   MAGIC_CMD="$lt_save_MAGIC_CMD"
7806   ;;
7807 esac
7808 fi
7809
7810 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
7811 if test -n "$MAGIC_CMD"; then
7812   { $as_echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5
7813 $as_echo "$MAGIC_CMD" >&6; }
7814 else
7815   { $as_echo "$as_me:$LINENO: result: no" >&5
7816 $as_echo "no" >&6; }
7817 fi
7818
7819
7820   else
7821     MAGIC_CMD=:
7822   fi
7823 fi
7824
7825   fi
7826   ;;
7827 esac
7828
7829 # Use C for the default configuration in the libtool script
7830
7831 lt_save_CC="$CC"
7832 ac_ext=c
7833 ac_cpp='$CPP $CPPFLAGS'
7834 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7835 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7836 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7837
7838
7839 # Source file extension for C test sources.
7840 ac_ext=c
7841
7842 # Object file extension for compiled C test sources.
7843 objext=o
7844 objext=$objext
7845
7846 # Code to be used in simple compile tests
7847 lt_simple_compile_test_code="int some_variable = 0;"
7848
7849 # Code to be used in simple link tests
7850 lt_simple_link_test_code='int main(){return(0);}'
7851
7852
7853
7854
7855
7856
7857
7858 # If no C compiler was specified, use CC.
7859 LTCC=${LTCC-"$CC"}
7860
7861 # If no C compiler flags were specified, use CFLAGS.
7862 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
7863
7864 # Allow CC to be a program name with arguments.
7865 compiler=$CC
7866
7867 # Save the default compiler, since it gets overwritten when the other
7868 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
7869 compiler_DEFAULT=$CC
7870
7871 # save warnings/boilerplate of simple test code
7872 ac_outfile=conftest.$ac_objext
7873 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
7874 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
7875 _lt_compiler_boilerplate=`cat conftest.err`
7876 $RM conftest*
7877
7878 ac_outfile=conftest.$ac_objext
7879 echo "$lt_simple_link_test_code" >conftest.$ac_ext
7880 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
7881 _lt_linker_boilerplate=`cat conftest.err`
7882 $RM -r conftest*
7883
7884
7885 if test -n "$compiler"; then
7886
7887 lt_prog_compiler_no_builtin_flag=
7888
7889 if test "$GCC" = yes; then
7890   lt_prog_compiler_no_builtin_flag=' -fno-builtin'
7891
7892   { $as_echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
7893 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
7894 if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then
7895   $as_echo_n "(cached) " >&6
7896 else
7897   lt_cv_prog_compiler_rtti_exceptions=no
7898    ac_outfile=conftest.$ac_objext
7899    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
7900    lt_compiler_flag="-fno-rtti -fno-exceptions"
7901    # Insert the option either (1) after the last *FLAGS variable, or
7902    # (2) before a word containing "conftest.", or (3) at the end.
7903    # Note that $ac_compile itself does not contain backslashes and begins
7904    # with a dollar sign (not a hyphen), so the echo should work correctly.
7905    # The option is referenced via a variable to avoid confusing sed.
7906    lt_compile=`echo "$ac_compile" | $SED \
7907    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
7908    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
7909    -e 's:$: $lt_compiler_flag:'`
7910    (eval echo "\"\$as_me:7910: $lt_compile\"" >&5)
7911    (eval "$lt_compile" 2>conftest.err)
7912    ac_status=$?
7913    cat conftest.err >&5
7914    echo "$as_me:7914: \$? = $ac_status" >&5
7915    if (exit $ac_status) && test -s "$ac_outfile"; then
7916      # The compiler can only warn and ignore the option if not recognized
7917      # So say no if there are warnings other than the usual output.
7918      $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
7919      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
7920      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
7921        lt_cv_prog_compiler_rtti_exceptions=yes
7922      fi
7923    fi
7924    $RM conftest*
7925
7926 fi
7927 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
7928 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
7929
7930 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
7931     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
7932 else
7933     :
7934 fi
7935
7936 fi
7937
7938
7939
7940
7941
7942
7943   lt_prog_compiler_wl=
7944 lt_prog_compiler_pic=
7945 lt_prog_compiler_static=
7946
7947 { $as_echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5
7948 $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
7949
7950   if test "$GCC" = yes; then
7951     lt_prog_compiler_wl='-Wl,'
7952     lt_prog_compiler_static='-static'
7953
7954     case $host_os in
7955       aix*)
7956       # All AIX code is PIC.
7957       if test "$host_cpu" = ia64; then
7958         # AIX 5 now supports IA64 processor
7959         lt_prog_compiler_static='-Bstatic'
7960       fi
7961       ;;
7962
7963     amigaos*)
7964       case $host_cpu in
7965       powerpc)
7966             # see comment about AmigaOS4 .so support
7967             lt_prog_compiler_pic='-fPIC'
7968         ;;
7969       m68k)
7970             # FIXME: we need at least 68020 code to build shared libraries, but
7971             # adding the `-m68020' flag to GCC prevents building anything better,
7972             # like `-m68040'.
7973             lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
7974         ;;
7975       esac
7976       ;;
7977
7978     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
7979       # PIC is the default for these OSes.
7980       ;;
7981
7982     mingw* | cygwin* | pw32* | os2* | cegcc*)
7983       # This hack is so that the source file can tell whether it is being
7984       # built for inclusion in a dll (and should export symbols for example).
7985       # Although the cygwin gcc ignores -fPIC, still need this for old-style
7986       # (--disable-auto-import) libraries
7987       lt_prog_compiler_pic='-DDLL_EXPORT'
7988       ;;
7989
7990     darwin* | rhapsody*)
7991       # PIC is the default on this platform
7992       # Common symbols not allowed in MH_DYLIB files
7993       lt_prog_compiler_pic='-fno-common'
7994       ;;
7995
7996     hpux*)
7997       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
7998       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
7999       # sets the default TLS model and affects inlining.
8000       case $host_cpu in
8001       hppa*64*)
8002         # +Z the default
8003         ;;
8004       *)
8005         lt_prog_compiler_pic='-fPIC'
8006         ;;
8007       esac
8008       ;;
8009
8010     interix[3-9]*)
8011       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
8012       # Instead, we relocate shared libraries at runtime.
8013       ;;
8014
8015     msdosdjgpp*)
8016       # Just because we use GCC doesn't mean we suddenly get shared libraries
8017       # on systems that don't support them.
8018       lt_prog_compiler_can_build_shared=no
8019       enable_shared=no
8020       ;;
8021
8022     *nto* | *qnx*)
8023       # QNX uses GNU C++, but need to define -shared option too, otherwise
8024       # it will coredump.
8025       lt_prog_compiler_pic='-fPIC -shared'
8026       ;;
8027
8028     sysv4*MP*)
8029       if test -d /usr/nec; then
8030         lt_prog_compiler_pic=-Kconform_pic
8031       fi
8032       ;;
8033
8034     *)
8035       lt_prog_compiler_pic='-fPIC'
8036       ;;
8037     esac
8038   else
8039     # PORTME Check for flag to pass linker flags through the system compiler.
8040     case $host_os in
8041     aix*)
8042       lt_prog_compiler_wl='-Wl,'
8043       if test "$host_cpu" = ia64; then
8044         # AIX 5 now supports IA64 processor
8045         lt_prog_compiler_static='-Bstatic'
8046       else
8047         lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
8048       fi
8049       ;;
8050
8051     mingw* | cygwin* | pw32* | os2* | cegcc*)
8052       # This hack is so that the source file can tell whether it is being
8053       # built for inclusion in a dll (and should export symbols for example).
8054       lt_prog_compiler_pic='-DDLL_EXPORT'
8055       ;;
8056
8057     hpux9* | hpux10* | hpux11*)
8058       lt_prog_compiler_wl='-Wl,'
8059       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
8060       # not for PA HP-UX.
8061       case $host_cpu in
8062       hppa*64*|ia64*)
8063         # +Z the default
8064         ;;
8065       *)
8066         lt_prog_compiler_pic='+Z'
8067         ;;
8068       esac
8069       # Is there a better lt_prog_compiler_static that works with the bundled CC?
8070       lt_prog_compiler_static='${wl}-a ${wl}archive'
8071       ;;
8072
8073     irix5* | irix6* | nonstopux*)
8074       lt_prog_compiler_wl='-Wl,'
8075       # PIC (with -KPIC) is the default.
8076       lt_prog_compiler_static='-non_shared'
8077       ;;
8078
8079     linux* | k*bsd*-gnu)
8080       case $cc_basename in
8081       # old Intel for x86_64 which still supported -KPIC.
8082       ecc*)
8083         lt_prog_compiler_wl='-Wl,'
8084         lt_prog_compiler_pic='-KPIC'
8085         lt_prog_compiler_static='-static'
8086         ;;
8087       # icc used to be incompatible with GCC.
8088       # ICC 10 doesn't accept -KPIC any more.
8089       icc* | ifort*)
8090         lt_prog_compiler_wl='-Wl,'
8091         lt_prog_compiler_pic='-fPIC'
8092         lt_prog_compiler_static='-static'
8093         ;;
8094       # Lahey Fortran 8.1.
8095       lf95*)
8096         lt_prog_compiler_wl='-Wl,'
8097         lt_prog_compiler_pic='--shared'
8098         lt_prog_compiler_static='--static'
8099         ;;
8100       pgcc* | pgf77* | pgf90* | pgf95*)
8101         # Portland Group compilers (*not* the Pentium gcc compiler,
8102         # which looks to be a dead project)
8103         lt_prog_compiler_wl='-Wl,'
8104         lt_prog_compiler_pic='-fpic'
8105         lt_prog_compiler_static='-Bstatic'
8106         ;;
8107       ccc*)
8108         lt_prog_compiler_wl='-Wl,'
8109         # All Alpha code is PIC.
8110         lt_prog_compiler_static='-non_shared'
8111         ;;
8112       xl*)
8113         # IBM XL C 8.0/Fortran 10.1 on PPC
8114         lt_prog_compiler_wl='-Wl,'
8115         lt_prog_compiler_pic='-qpic'
8116         lt_prog_compiler_static='-qstaticlink'
8117         ;;
8118       *)
8119         case `$CC -V 2>&1 | sed 5q` in
8120         *Sun\ C*)
8121           # Sun C 5.9
8122           lt_prog_compiler_pic='-KPIC'
8123           lt_prog_compiler_static='-Bstatic'
8124           lt_prog_compiler_wl='-Wl,'
8125           ;;
8126         *Sun\ F*)
8127           # Sun Fortran 8.3 passes all unrecognized flags to the linker
8128           lt_prog_compiler_pic='-KPIC'
8129           lt_prog_compiler_static='-Bstatic'
8130           lt_prog_compiler_wl=''
8131           ;;
8132         esac
8133         ;;
8134       esac
8135       ;;
8136
8137     newsos6)
8138       lt_prog_compiler_pic='-KPIC'
8139       lt_prog_compiler_static='-Bstatic'
8140       ;;
8141
8142     *nto* | *qnx*)
8143       # QNX uses GNU C++, but need to define -shared option too, otherwise
8144       # it will coredump.
8145       lt_prog_compiler_pic='-fPIC -shared'
8146       ;;
8147
8148     osf3* | osf4* | osf5*)
8149       lt_prog_compiler_wl='-Wl,'
8150       # All OSF/1 code is PIC.
8151       lt_prog_compiler_static='-non_shared'
8152       ;;
8153
8154     rdos*)
8155       lt_prog_compiler_static='-non_shared'
8156       ;;
8157
8158     solaris*)
8159       lt_prog_compiler_pic='-KPIC'
8160       lt_prog_compiler_static='-Bstatic'
8161       case $cc_basename in
8162       f77* | f90* | f95*)
8163         lt_prog_compiler_wl='-Qoption ld ';;
8164       *)
8165         lt_prog_compiler_wl='-Wl,';;
8166       esac
8167       ;;
8168
8169     sunos4*)
8170       lt_prog_compiler_wl='-Qoption ld '
8171       lt_prog_compiler_pic='-PIC'
8172       lt_prog_compiler_static='-Bstatic'
8173       ;;
8174
8175     sysv4 | sysv4.2uw2* | sysv4.3*)
8176       lt_prog_compiler_wl='-Wl,'
8177       lt_prog_compiler_pic='-KPIC'
8178       lt_prog_compiler_static='-Bstatic'
8179       ;;
8180
8181     sysv4*MP*)
8182       if test -d /usr/nec ;then
8183         lt_prog_compiler_pic='-Kconform_pic'
8184         lt_prog_compiler_static='-Bstatic'
8185       fi
8186       ;;
8187
8188     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
8189       lt_prog_compiler_wl='-Wl,'
8190       lt_prog_compiler_pic='-KPIC'
8191       lt_prog_compiler_static='-Bstatic'
8192       ;;
8193
8194     unicos*)
8195       lt_prog_compiler_wl='-Wl,'
8196       lt_prog_compiler_can_build_shared=no
8197       ;;
8198
8199     uts4*)
8200       lt_prog_compiler_pic='-pic'
8201       lt_prog_compiler_static='-Bstatic'
8202       ;;
8203
8204     *)
8205       lt_prog_compiler_can_build_shared=no
8206       ;;
8207     esac
8208   fi
8209
8210 case $host_os in
8211   # For platforms which do not support PIC, -DPIC is meaningless:
8212   *djgpp*)
8213     lt_prog_compiler_pic=
8214     ;;
8215   *)
8216     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
8217     ;;
8218 esac
8219 { $as_echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5
8220 $as_echo "$lt_prog_compiler_pic" >&6; }
8221
8222
8223
8224
8225
8226
8227 #
8228 # Check to make sure the PIC flag actually works.
8229 #
8230 if test -n "$lt_prog_compiler_pic"; then
8231   { $as_echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
8232 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
8233 if test "${lt_cv_prog_compiler_pic_works+set}" = set; then
8234   $as_echo_n "(cached) " >&6
8235 else
8236   lt_cv_prog_compiler_pic_works=no
8237    ac_outfile=conftest.$ac_objext
8238    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
8239    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
8240    # Insert the option either (1) after the last *FLAGS variable, or
8241    # (2) before a word containing "conftest.", or (3) at the end.
8242    # Note that $ac_compile itself does not contain backslashes and begins
8243    # with a dollar sign (not a hyphen), so the echo should work correctly.
8244    # The option is referenced via a variable to avoid confusing sed.
8245    lt_compile=`echo "$ac_compile" | $SED \
8246    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
8247    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
8248    -e 's:$: $lt_compiler_flag:'`
8249    (eval echo "\"\$as_me:8249: $lt_compile\"" >&5)
8250    (eval "$lt_compile" 2>conftest.err)
8251    ac_status=$?
8252    cat conftest.err >&5
8253    echo "$as_me:8253: \$? = $ac_status" >&5
8254    if (exit $ac_status) && test -s "$ac_outfile"; then
8255      # The compiler can only warn and ignore the option if not recognized
8256      # So say no if there are warnings other than the usual output.
8257      $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
8258      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
8259      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
8260        lt_cv_prog_compiler_pic_works=yes
8261      fi
8262    fi
8263    $RM conftest*
8264
8265 fi
8266 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works" >&5
8267 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
8268
8269 if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
8270     case $lt_prog_compiler_pic in
8271      "" | " "*) ;;
8272      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
8273      esac
8274 else
8275     lt_prog_compiler_pic=
8276      lt_prog_compiler_can_build_shared=no
8277 fi
8278
8279 fi
8280
8281
8282
8283
8284
8285
8286 #
8287 # Check to make sure the static flag actually works.
8288 #
8289 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
8290 { $as_echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5
8291 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
8292 if test "${lt_cv_prog_compiler_static_works+set}" = set; then
8293   $as_echo_n "(cached) " >&6
8294 else
8295   lt_cv_prog_compiler_static_works=no
8296    save_LDFLAGS="$LDFLAGS"
8297    LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
8298    echo "$lt_simple_link_test_code" > conftest.$ac_ext
8299    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
8300      # The linker can only warn and ignore the option if not recognized
8301      # So say no if there are warnings
8302      if test -s conftest.err; then
8303        # Append any errors to the config.log.
8304        cat conftest.err 1>&5
8305        $ECHO "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
8306        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
8307        if diff conftest.exp conftest.er2 >/dev/null; then
8308          lt_cv_prog_compiler_static_works=yes
8309        fi
8310      else
8311        lt_cv_prog_compiler_static_works=yes
8312      fi
8313    fi
8314    $RM -r conftest*
8315    LDFLAGS="$save_LDFLAGS"
8316
8317 fi
8318 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works" >&5
8319 $as_echo "$lt_cv_prog_compiler_static_works" >&6; }
8320
8321 if test x"$lt_cv_prog_compiler_static_works" = xyes; then
8322     :
8323 else
8324     lt_prog_compiler_static=
8325 fi
8326
8327
8328
8329
8330
8331
8332
8333   { $as_echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
8334 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
8335 if test "${lt_cv_prog_compiler_c_o+set}" = set; then
8336   $as_echo_n "(cached) " >&6
8337 else
8338   lt_cv_prog_compiler_c_o=no
8339    $RM -r conftest 2>/dev/null
8340    mkdir conftest
8341    cd conftest
8342    mkdir out
8343    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
8344
8345    lt_compiler_flag="-o out/conftest2.$ac_objext"
8346    # Insert the option either (1) after the last *FLAGS variable, or
8347    # (2) before a word containing "conftest.", or (3) at the end.
8348    # Note that $ac_compile itself does not contain backslashes and begins
8349    # with a dollar sign (not a hyphen), so the echo should work correctly.
8350    lt_compile=`echo "$ac_compile" | $SED \
8351    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
8352    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
8353    -e 's:$: $lt_compiler_flag:'`
8354    (eval echo "\"\$as_me:8354: $lt_compile\"" >&5)
8355    (eval "$lt_compile" 2>out/conftest.err)
8356    ac_status=$?
8357    cat out/conftest.err >&5
8358    echo "$as_me:8358: \$? = $ac_status" >&5
8359    if (exit $ac_status) && test -s out/conftest2.$ac_objext
8360    then
8361      # The compiler can only warn and ignore the option if not recognized
8362      # So say no if there are warnings
8363      $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
8364      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
8365      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
8366        lt_cv_prog_compiler_c_o=yes
8367      fi
8368    fi
8369    chmod u+w . 2>&5
8370    $RM conftest*
8371    # SGI C++ compiler will create directory out/ii_files/ for
8372    # template instantiation
8373    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
8374    $RM out/* && rmdir out
8375    cd ..
8376    $RM -r conftest
8377    $RM conftest*
8378
8379 fi
8380 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
8381 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
8382
8383
8384
8385
8386
8387
8388   { $as_echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5
8389 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
8390 if test "${lt_cv_prog_compiler_c_o+set}" = set; then
8391   $as_echo_n "(cached) " >&6
8392 else
8393   lt_cv_prog_compiler_c_o=no
8394    $RM -r conftest 2>/dev/null
8395    mkdir conftest
8396    cd conftest
8397    mkdir out
8398    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
8399
8400    lt_compiler_flag="-o out/conftest2.$ac_objext"
8401    # Insert the option either (1) after the last *FLAGS variable, or
8402    # (2) before a word containing "conftest.", or (3) at the end.
8403    # Note that $ac_compile itself does not contain backslashes and begins
8404    # with a dollar sign (not a hyphen), so the echo should work correctly.
8405    lt_compile=`echo "$ac_compile" | $SED \
8406    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
8407    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
8408    -e 's:$: $lt_compiler_flag:'`
8409    (eval echo "\"\$as_me:8409: $lt_compile\"" >&5)
8410    (eval "$lt_compile" 2>out/conftest.err)
8411    ac_status=$?
8412    cat out/conftest.err >&5
8413    echo "$as_me:8413: \$? = $ac_status" >&5
8414    if (exit $ac_status) && test -s out/conftest2.$ac_objext
8415    then
8416      # The compiler can only warn and ignore the option if not recognized
8417      # So say no if there are warnings
8418      $ECHO "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
8419      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
8420      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
8421        lt_cv_prog_compiler_c_o=yes
8422      fi
8423    fi
8424    chmod u+w . 2>&5
8425    $RM conftest*
8426    # SGI C++ compiler will create directory out/ii_files/ for
8427    # template instantiation
8428    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
8429    $RM out/* && rmdir out
8430    cd ..
8431    $RM -r conftest
8432    $RM conftest*
8433
8434 fi
8435 { $as_echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5
8436 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
8437
8438
8439
8440
8441 hard_links="nottested"
8442 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
8443   # do not overwrite the value of need_locks provided by the user
8444   { $as_echo "$as_me:$LINENO: checking if we can lock with hard links" >&5
8445 $as_echo_n "checking if we can lock with hard links... " >&6; }
8446   hard_links=yes
8447   $RM conftest*
8448   ln conftest.a conftest.b 2>/dev/null && hard_links=no
8449   touch conftest.a
8450   ln conftest.a conftest.b 2>&5 || hard_links=no
8451   ln conftest.a conftest.b 2>/dev/null && hard_links=no
8452   { $as_echo "$as_me:$LINENO: result: $hard_links" >&5
8453 $as_echo "$hard_links" >&6; }
8454   if test "$hard_links" = no; then
8455     { $as_echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
8456 $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
8457     need_locks=warn
8458   fi
8459 else
8460   need_locks=no
8461 fi
8462
8463
8464
8465
8466
8467
8468   { $as_echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5
8469 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
8470
8471   runpath_var=
8472   allow_undefined_flag=
8473   always_export_symbols=no
8474   archive_cmds=
8475   archive_expsym_cmds=
8476   compiler_needs_object=no
8477   enable_shared_with_static_runtimes=no
8478   export_dynamic_flag_spec=
8479   export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
8480   hardcode_automatic=no
8481   hardcode_direct=no
8482   hardcode_direct_absolute=no
8483   hardcode_libdir_flag_spec=
8484   hardcode_libdir_flag_spec_ld=
8485   hardcode_libdir_separator=
8486   hardcode_minus_L=no
8487   hardcode_shlibpath_var=unsupported
8488   inherit_rpath=no
8489   link_all_deplibs=unknown
8490   module_cmds=
8491   module_expsym_cmds=
8492   old_archive_from_new_cmds=
8493   old_archive_from_expsyms_cmds=
8494   thread_safe_flag_spec=
8495   whole_archive_flag_spec=
8496   # include_expsyms should be a list of space-separated symbols to be *always*
8497   # included in the symbol list
8498   include_expsyms=
8499   # exclude_expsyms can be an extended regexp of symbols to exclude
8500   # it will be wrapped by ` (' and `)$', so one must not match beginning or
8501   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
8502   # as well as any symbol that contains `d'.
8503   exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
8504   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
8505   # platforms (ab)use it in PIC code, but their linkers get confused if
8506   # the symbol is explicitly referenced.  Since portable code cannot
8507   # rely on this symbol name, it's probably fine to never include it in
8508   # preloaded symbol tables.
8509   # Exclude shared library initialization/finalization symbols.
8510   extract_expsyms_cmds=
8511
8512   case $host_os in
8513   cygwin* | mingw* | pw32* | cegcc*)
8514     # FIXME: the MSVC++ port hasn't been tested in a loooong time
8515     # When not using gcc, we currently assume that we are using
8516     # Microsoft Visual C++.
8517     if test "$GCC" != yes; then
8518       with_gnu_ld=no
8519     fi
8520     ;;
8521   interix*)
8522     # we just hope/assume this is gcc and not c89 (= MSVC++)
8523     with_gnu_ld=yes
8524     ;;
8525   openbsd*)
8526     with_gnu_ld=no
8527     ;;
8528   esac
8529
8530   ld_shlibs=yes
8531   if test "$with_gnu_ld" = yes; then
8532     # If archive_cmds runs LD, not CC, wlarc should be empty
8533     wlarc='${wl}'
8534
8535     # Set some defaults for GNU ld with shared library support. These
8536     # are reset later if shared libraries are not supported. Putting them
8537     # here allows them to be overridden if necessary.
8538     runpath_var=LD_RUN_PATH
8539     hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8540     export_dynamic_flag_spec='${wl}--export-dynamic'
8541     # ancient GNU ld didn't support --whole-archive et. al.
8542     if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
8543       whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
8544     else
8545       whole_archive_flag_spec=
8546     fi
8547     supports_anon_versioning=no
8548     case `$LD -v 2>&1` in
8549       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
8550       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
8551       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
8552       *\ 2.11.*) ;; # other 2.11 versions
8553       *) supports_anon_versioning=yes ;;
8554     esac
8555
8556     # See if GNU ld supports shared libraries.
8557     case $host_os in
8558     aix[3-9]*)
8559       # On AIX/PPC, the GNU linker is very broken
8560       if test "$host_cpu" != ia64; then
8561         ld_shlibs=no
8562         cat <<_LT_EOF 1>&2
8563
8564 *** Warning: the GNU linker, at least up to release 2.9.1, is reported
8565 *** to be unable to reliably create shared libraries on AIX.
8566 *** Therefore, libtool is disabling shared libraries support.  If you
8567 *** really care for shared libraries, you may want to modify your PATH
8568 *** so that a non-GNU linker is found, and then restart.
8569
8570 _LT_EOF
8571       fi
8572       ;;
8573
8574     amigaos*)
8575       case $host_cpu in
8576       powerpc)
8577             # see comment about AmigaOS4 .so support
8578             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8579             archive_expsym_cmds=''
8580         ;;
8581       m68k)
8582             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)'
8583             hardcode_libdir_flag_spec='-L$libdir'
8584             hardcode_minus_L=yes
8585         ;;
8586       esac
8587       ;;
8588
8589     beos*)
8590       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
8591         allow_undefined_flag=unsupported
8592         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
8593         # support --undefined.  This deserves some investigation.  FIXME
8594         archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8595       else
8596         ld_shlibs=no
8597       fi
8598       ;;
8599
8600     cygwin* | mingw* | pw32* | cegcc*)
8601       # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
8602       # as there is no search path for DLLs.
8603       hardcode_libdir_flag_spec='-L$libdir'
8604       allow_undefined_flag=unsupported
8605       always_export_symbols=no
8606       enable_shared_with_static_runtimes=yes
8607       export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
8608
8609       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
8610         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
8611         # If the export-symbols file already is a .def file (1st line
8612         # is EXPORTS), use it as is; otherwise, prepend...
8613         archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
8614           cp $export_symbols $output_objdir/$soname.def;
8615         else
8616           echo EXPORTS > $output_objdir/$soname.def;
8617           cat $export_symbols >> $output_objdir/$soname.def;
8618         fi~
8619         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
8620       else
8621         ld_shlibs=no
8622       fi
8623       ;;
8624
8625     interix[3-9]*)
8626       hardcode_direct=no
8627       hardcode_shlibpath_var=no
8628       hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
8629       export_dynamic_flag_spec='${wl}-E'
8630       # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
8631       # Instead, shared libraries are loaded at an image base (0x10000000 by
8632       # default) and relocated if they conflict, which is a slow very memory
8633       # consuming and fragmenting process.  To avoid this, we pick a random,
8634       # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
8635       # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
8636       archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
8637       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'
8638       ;;
8639
8640     gnu* | linux* | tpf* | k*bsd*-gnu)
8641       tmp_diet=no
8642       if test "$host_os" = linux-dietlibc; then
8643         case $cc_basename in
8644           diet\ *) tmp_diet=yes;;       # linux-dietlibc with static linking (!diet-dyn)
8645         esac
8646       fi
8647       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
8648          && test "$tmp_diet" = no
8649       then
8650         tmp_addflag=
8651         tmp_sharedflag='-shared'
8652         case $cc_basename,$host_cpu in
8653         pgcc*)                          # Portland Group C compiler
8654           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'
8655           tmp_addflag=' $pic_flag'
8656           ;;
8657         pgf77* | pgf90* | pgf95*)       # Portland Group f77 and f90 compilers
8658           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'
8659           tmp_addflag=' $pic_flag -Mnomain' ;;
8660         ecc*,ia64* | icc*,ia64*)        # Intel C compiler on ia64
8661           tmp_addflag=' -i_dynamic' ;;
8662         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
8663           tmp_addflag=' -i_dynamic -nofor_main' ;;
8664         ifc* | ifort*)                  # Intel Fortran compiler
8665           tmp_addflag=' -nofor_main' ;;
8666         lf95*)                          # Lahey Fortran 8.1
8667           whole_archive_flag_spec=
8668           tmp_sharedflag='--shared' ;;
8669         xl[cC]*)                        # IBM XL C 8.0 on PPC (deal with xlf below)
8670           tmp_sharedflag='-qmkshrobj'
8671           tmp_addflag= ;;
8672         esac
8673         case `$CC -V 2>&1 | sed 5q` in
8674         *Sun\ C*)                       # Sun C 5.9
8675           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'
8676           compiler_needs_object=yes
8677           tmp_sharedflag='-G' ;;
8678         *Sun\ F*)                       # Sun Fortran 8.3
8679           tmp_sharedflag='-G' ;;
8680         esac
8681         archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8682
8683         if test "x$supports_anon_versioning" = xyes; then
8684           archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
8685             cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
8686             echo "local: *; };" >> $output_objdir/$libname.ver~
8687             $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
8688         fi
8689
8690         case $cc_basename in
8691         xlf*)
8692           # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
8693           whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
8694           hardcode_libdir_flag_spec=
8695           hardcode_libdir_flag_spec_ld='-rpath $libdir'
8696           archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
8697           if test "x$supports_anon_versioning" = xyes; then
8698             archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
8699               cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
8700               echo "local: *; };" >> $output_objdir/$libname.ver~
8701               $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
8702           fi
8703           ;;
8704         esac
8705       else
8706         ld_shlibs=no
8707       fi
8708       ;;
8709
8710     netbsd*)
8711       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
8712         archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
8713         wlarc=
8714       else
8715         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8716         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8717       fi
8718       ;;
8719
8720     solaris*)
8721       if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
8722         ld_shlibs=no
8723         cat <<_LT_EOF 1>&2
8724
8725 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
8726 *** create shared libraries on Solaris systems.  Therefore, libtool
8727 *** is disabling shared libraries support.  We urge you to upgrade GNU
8728 *** binutils to release 2.9.1 or newer.  Another option is to modify
8729 *** your PATH or compiler configuration so that the native linker is
8730 *** used, and then restart.
8731
8732 _LT_EOF
8733       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
8734         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8735         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8736       else
8737         ld_shlibs=no
8738       fi
8739       ;;
8740
8741     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
8742       case `$LD -v 2>&1` in
8743         *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
8744         ld_shlibs=no
8745         cat <<_LT_EOF 1>&2
8746
8747 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
8748 *** reliably create shared libraries on SCO systems.  Therefore, libtool
8749 *** is disabling shared libraries support.  We urge you to upgrade GNU
8750 *** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
8751 *** your PATH or compiler configuration so that the native linker is
8752 *** used, and then restart.
8753
8754 _LT_EOF
8755         ;;
8756         *)
8757           # For security reasons, it is highly recommended that you always
8758           # use absolute paths for naming shared libraries, and exclude the
8759           # DT_RUNPATH tag from executables and libraries.  But doing so
8760           # requires that you compile everything twice, which is a pain.
8761           if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
8762             hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
8763             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8764             archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8765           else
8766             ld_shlibs=no
8767           fi
8768         ;;
8769       esac
8770       ;;
8771
8772     sunos4*)
8773       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
8774       wlarc=
8775       hardcode_direct=yes
8776       hardcode_shlibpath_var=no
8777       ;;
8778
8779     *)
8780       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
8781         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
8782         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
8783       else
8784         ld_shlibs=no
8785       fi
8786       ;;
8787     esac
8788
8789     if test "$ld_shlibs" = no; then
8790       runpath_var=
8791       hardcode_libdir_flag_spec=
8792       export_dynamic_flag_spec=
8793       whole_archive_flag_spec=
8794     fi
8795   else
8796     # PORTME fill in a description of your system's linker (not GNU ld)
8797     case $host_os in
8798     aix3*)
8799       allow_undefined_flag=unsupported
8800       always_export_symbols=yes
8801       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'
8802       # Note: this linker hardcodes the directories in LIBPATH if there
8803       # are no directories specified by -L.
8804       hardcode_minus_L=yes
8805       if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
8806         # Neither direct hardcoding nor static linking is supported with a
8807         # broken collect2.
8808         hardcode_direct=unsupported
8809       fi
8810       ;;
8811
8812     aix[4-9]*)
8813       if test "$host_cpu" = ia64; then
8814         # On IA64, the linker does run time linking by default, so we don't
8815         # have to do anything special.
8816         aix_use_runtimelinking=no
8817         exp_sym_flag='-Bexport'
8818         no_entry_flag=""
8819       else
8820         # If we're using GNU nm, then we don't want the "-C" option.
8821         # -C means demangle to AIX nm, but means don't demangle with GNU nm
8822         if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
8823           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'
8824         else
8825           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'
8826         fi
8827         aix_use_runtimelinking=no
8828
8829         # Test if we are trying to use run time linking or normal
8830         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
8831         # need to do runtime linking.
8832         case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
8833           for ld_flag in $LDFLAGS; do
8834           if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
8835             aix_use_runtimelinking=yes
8836             break
8837           fi
8838           done
8839           ;;
8840         esac
8841
8842         exp_sym_flag='-bexport'
8843         no_entry_flag='-bnoentry'
8844       fi
8845
8846       # When large executables or shared objects are built, AIX ld can
8847       # have problems creating the table of contents.  If linking a library
8848       # or program results in "error TOC overflow" add -mminimal-toc to
8849       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
8850       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
8851
8852       archive_cmds=''
8853       hardcode_direct=yes
8854       hardcode_direct_absolute=yes
8855       hardcode_libdir_separator=':'
8856       link_all_deplibs=yes
8857       file_list_spec='${wl}-f,'
8858
8859       if test "$GCC" = yes; then
8860         case $host_os in aix4.[012]|aix4.[012].*)
8861         # We only want to do this on AIX 4.2 and lower, the check
8862         # below for broken collect2 doesn't work under 4.3+
8863           collect2name=`${CC} -print-prog-name=collect2`
8864           if test -f "$collect2name" &&
8865            strings "$collect2name" | $GREP resolve_lib_name >/dev/null
8866           then
8867           # We have reworked collect2
8868           :
8869           else
8870           # We have old collect2
8871           hardcode_direct=unsupported
8872           # It fails to find uninstalled libraries when the uninstalled
8873           # path is not listed in the libpath.  Setting hardcode_minus_L
8874           # to unsupported forces relinking
8875           hardcode_minus_L=yes
8876           hardcode_libdir_flag_spec='-L$libdir'
8877           hardcode_libdir_separator=
8878           fi
8879           ;;
8880         esac
8881         shared_flag='-shared'
8882         if test "$aix_use_runtimelinking" = yes; then
8883           shared_flag="$shared_flag "'${wl}-G'
8884         fi
8885       else
8886         # not using gcc
8887         if test "$host_cpu" = ia64; then
8888         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
8889         # chokes on -Wl,-G. The following line is correct:
8890           shared_flag='-G'
8891         else
8892           if test "$aix_use_runtimelinking" = yes; then
8893             shared_flag='${wl}-G'
8894           else
8895             shared_flag='${wl}-bM:SRE'
8896           fi
8897         fi
8898       fi
8899
8900       export_dynamic_flag_spec='${wl}-bexpall'
8901       # It seems that -bexpall does not export symbols beginning with
8902       # underscore (_), so it is better to generate a list of symbols to export.
8903       always_export_symbols=yes
8904       if test "$aix_use_runtimelinking" = yes; then
8905         # Warning - without using the other runtime loading flags (-brtl),
8906         # -berok will link without error, but may produce a broken library.
8907         allow_undefined_flag='-berok'
8908         # Determine the default libpath from the value encoded in an
8909         # empty executable.
8910         cat >conftest.$ac_ext <<_ACEOF
8911 /* confdefs.h.  */
8912 _ACEOF
8913 cat confdefs.h >>conftest.$ac_ext
8914 cat >>conftest.$ac_ext <<_ACEOF
8915 /* end confdefs.h.  */
8916
8917 int
8918 main ()
8919 {
8920
8921   ;
8922   return 0;
8923 }
8924 _ACEOF
8925 rm -f conftest.$ac_objext conftest$ac_exeext
8926 if { (ac_try="$ac_link"
8927 case "(($ac_try" in
8928   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8929   *) ac_try_echo=$ac_try;;
8930 esac
8931 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8932 $as_echo "$ac_try_echo") >&5
8933   (eval "$ac_link") 2>conftest.er1
8934   ac_status=$?
8935   grep -v '^ *+' conftest.er1 >conftest.err
8936   rm -f conftest.er1
8937   cat conftest.err >&5
8938   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8939   (exit $ac_status); } && {
8940          test -z "$ac_c_werror_flag" ||
8941          test ! -s conftest.err
8942        } && test -s conftest$ac_exeext && {
8943          test "$cross_compiling" = yes ||
8944          $as_test_x conftest$ac_exeext
8945        }; then
8946
8947 lt_aix_libpath_sed='
8948     /Import File Strings/,/^$/ {
8949         /^0/ {
8950             s/^0  *\(.*\)$/\1/
8951             p
8952         }
8953     }'
8954 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8955 # Check for a 64-bit object if we didn't find anything.
8956 if test -z "$aix_libpath"; then
8957   aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
8958 fi
8959 else
8960   $as_echo "$as_me: failed program was:" >&5
8961 sed 's/^/| /' conftest.$ac_ext >&5
8962
8963
8964 fi
8965
8966 rm -rf conftest.dSYM
8967 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8968       conftest$ac_exeext conftest.$ac_ext
8969 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
8970
8971         hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
8972         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 "X${wl}${allow_undefined_flag}" | $Xsed; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
8973       else
8974         if test "$host_cpu" = ia64; then
8975           hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
8976           allow_undefined_flag="-z nodefs"
8977           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"
8978         else
8979          # Determine the default libpath from the value encoded in an
8980          # empty executable.
8981          cat >conftest.$ac_ext <<_ACEOF
8982 /* confdefs.h.  */
8983 _ACEOF
8984 cat confdefs.h >>conftest.$ac_ext
8985 cat >>conftest.$ac_ext <<_ACEOF
8986 /* end confdefs.h.  */
8987
8988 int
8989 main ()
8990 {
8991
8992   ;
8993   return 0;
8994 }
8995 _ACEOF
8996 rm -f conftest.$ac_objext conftest$ac_exeext
8997 if { (ac_try="$ac_link"
8998 case "(($ac_try" in
8999   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9000   *) ac_try_echo=$ac_try;;
9001 esac
9002 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9003 $as_echo "$ac_try_echo") >&5
9004   (eval "$ac_link") 2>conftest.er1
9005   ac_status=$?
9006   grep -v '^ *+' conftest.er1 >conftest.err
9007   rm -f conftest.er1
9008   cat conftest.err >&5
9009   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9010   (exit $ac_status); } && {
9011          test -z "$ac_c_werror_flag" ||
9012          test ! -s conftest.err
9013        } && test -s conftest$ac_exeext && {
9014          test "$cross_compiling" = yes ||
9015          $as_test_x conftest$ac_exeext
9016        }; then
9017
9018 lt_aix_libpath_sed='
9019     /Import File Strings/,/^$/ {
9020         /^0/ {
9021             s/^0  *\(.*\)$/\1/
9022             p
9023         }
9024     }'
9025 aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9026 # Check for a 64-bit object if we didn't find anything.
9027 if test -z "$aix_libpath"; then
9028   aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
9029 fi
9030 else
9031   $as_echo "$as_me: failed program was:" >&5
9032 sed 's/^/| /' conftest.$ac_ext >&5
9033
9034
9035 fi
9036
9037 rm -rf conftest.dSYM
9038 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9039       conftest$ac_exeext conftest.$ac_ext
9040 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
9041
9042          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
9043           # Warning - without using the other run time loading flags,
9044           # -berok will link without error, but may produce a broken library.
9045           no_undefined_flag=' ${wl}-bernotok'
9046           allow_undefined_flag=' ${wl}-berok'
9047           # Exported symbols can be pulled into shared objects from archives
9048           whole_archive_flag_spec='$convenience'
9049           archive_cmds_need_lc=yes
9050           # This is similar to how AIX traditionally builds its shared libraries.
9051           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'
9052         fi
9053       fi
9054       ;;
9055
9056     amigaos*)
9057       case $host_cpu in
9058       powerpc)
9059             # see comment about AmigaOS4 .so support
9060             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
9061             archive_expsym_cmds=''
9062         ;;
9063       m68k)
9064             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)'
9065             hardcode_libdir_flag_spec='-L$libdir'
9066             hardcode_minus_L=yes
9067         ;;
9068       esac
9069       ;;
9070
9071     bsdi[45]*)
9072       export_dynamic_flag_spec=-rdynamic
9073       ;;
9074
9075     cygwin* | mingw* | pw32* | cegcc*)
9076       # When not using gcc, we currently assume that we are using
9077       # Microsoft Visual C++.
9078       # hardcode_libdir_flag_spec is actually meaningless, as there is
9079       # no search path for DLLs.
9080       hardcode_libdir_flag_spec=' '
9081       allow_undefined_flag=unsupported
9082       # Tell ltmain to make .lib files, not .a files.
9083       libext=lib
9084       # Tell ltmain to make .dll files, not .so files.
9085       shrext_cmds=".dll"
9086       # FIXME: Setting linknames here is a bad hack.
9087       archive_cmds='$CC -o $lib $libobjs $compiler_flags `$ECHO "X$deplibs" | $Xsed -e '\''s/ -lc$//'\''` -link -dll~linknames='
9088       # The linker will automatically build a .lib file if we build a DLL.
9089       old_archive_from_new_cmds='true'
9090       # FIXME: Should let the user specify the lib program.
9091       old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
9092       fix_srcfile_path='`cygpath -w "$srcfile"`'
9093       enable_shared_with_static_runtimes=yes
9094       ;;
9095
9096     darwin* | rhapsody*)
9097
9098
9099   archive_cmds_need_lc=no
9100   hardcode_direct=no
9101   hardcode_automatic=yes
9102   hardcode_shlibpath_var=unsupported
9103   whole_archive_flag_spec=''
9104   link_all_deplibs=yes
9105   allow_undefined_flag="$_lt_dar_allow_undefined"
9106   case $cc_basename in
9107      ifort*) _lt_dar_can_shared=yes ;;
9108      *) _lt_dar_can_shared=$GCC ;;
9109   esac
9110   if test "$_lt_dar_can_shared" = "yes"; then
9111     output_verbose_link_cmd=echo
9112     archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
9113     module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
9114     archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
9115     module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
9116
9117   else
9118   ld_shlibs=no
9119   fi
9120
9121       ;;
9122
9123     dgux*)
9124       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9125       hardcode_libdir_flag_spec='-L$libdir'
9126       hardcode_shlibpath_var=no
9127       ;;
9128
9129     freebsd1*)
9130       ld_shlibs=no
9131       ;;
9132
9133     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
9134     # support.  Future versions do this automatically, but an explicit c++rt0.o
9135     # does not break anything, and helps significantly (at the cost of a little
9136     # extra space).
9137     freebsd2.2*)
9138       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
9139       hardcode_libdir_flag_spec='-R$libdir'
9140       hardcode_direct=yes
9141       hardcode_shlibpath_var=no
9142       ;;
9143
9144     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
9145     freebsd2*)
9146       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
9147       hardcode_direct=yes
9148       hardcode_minus_L=yes
9149       hardcode_shlibpath_var=no
9150       ;;
9151
9152     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
9153     freebsd* | dragonfly*)
9154       archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
9155       hardcode_libdir_flag_spec='-R$libdir'
9156       hardcode_direct=yes
9157       hardcode_shlibpath_var=no
9158       ;;
9159
9160     hpux9*)
9161       if test "$GCC" = yes; then
9162         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'
9163       else
9164         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'
9165       fi
9166       hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
9167       hardcode_libdir_separator=:
9168       hardcode_direct=yes
9169
9170       # hardcode_minus_L: Not really in the search PATH,
9171       # but as the default location of the library.
9172       hardcode_minus_L=yes
9173       export_dynamic_flag_spec='${wl}-E'
9174       ;;
9175
9176     hpux10*)
9177       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
9178         archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
9179       else
9180         archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
9181       fi
9182       if test "$with_gnu_ld" = no; then
9183         hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
9184         hardcode_libdir_flag_spec_ld='+b $libdir'
9185         hardcode_libdir_separator=:
9186         hardcode_direct=yes
9187         hardcode_direct_absolute=yes
9188         export_dynamic_flag_spec='${wl}-E'
9189         # hardcode_minus_L: Not really in the search PATH,
9190         # but as the default location of the library.
9191         hardcode_minus_L=yes
9192       fi
9193       ;;
9194
9195     hpux11*)
9196       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
9197         case $host_cpu in
9198         hppa*64*)
9199           archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
9200           ;;
9201         ia64*)
9202           archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
9203           ;;
9204         *)
9205           archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
9206           ;;
9207         esac
9208       else
9209         case $host_cpu in
9210         hppa*64*)
9211           archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
9212           ;;
9213         ia64*)
9214           archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
9215           ;;
9216         *)
9217           archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
9218           ;;
9219         esac
9220       fi
9221       if test "$with_gnu_ld" = no; then
9222         hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
9223         hardcode_libdir_separator=:
9224
9225         case $host_cpu in
9226         hppa*64*|ia64*)
9227           hardcode_direct=no
9228           hardcode_shlibpath_var=no
9229           ;;
9230         *)
9231           hardcode_direct=yes
9232           hardcode_direct_absolute=yes
9233           export_dynamic_flag_spec='${wl}-E'
9234
9235           # hardcode_minus_L: Not really in the search PATH,
9236           # but as the default location of the library.
9237           hardcode_minus_L=yes
9238           ;;
9239         esac
9240       fi
9241       ;;
9242
9243     irix5* | irix6* | nonstopux*)
9244       if test "$GCC" = yes; then
9245         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
9246         # Try to use the -exported_symbol ld option, if it does not
9247         # work, assume that -exports_file does not work either and
9248         # implicitly export all symbols.
9249         save_LDFLAGS="$LDFLAGS"
9250         LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
9251         cat >conftest.$ac_ext <<_ACEOF
9252 int foo(void) {}
9253 _ACEOF
9254 rm -f conftest.$ac_objext conftest$ac_exeext
9255 if { (ac_try="$ac_link"
9256 case "(($ac_try" in
9257   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9258   *) ac_try_echo=$ac_try;;
9259 esac
9260 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9261 $as_echo "$ac_try_echo") >&5
9262   (eval "$ac_link") 2>conftest.er1
9263   ac_status=$?
9264   grep -v '^ *+' conftest.er1 >conftest.err
9265   rm -f conftest.er1
9266   cat conftest.err >&5
9267   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9268   (exit $ac_status); } && {
9269          test -z "$ac_c_werror_flag" ||
9270          test ! -s conftest.err
9271        } && test -s conftest$ac_exeext && {
9272          test "$cross_compiling" = yes ||
9273          $as_test_x conftest$ac_exeext
9274        }; then
9275   archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
9276
9277 else
9278   $as_echo "$as_me: failed program was:" >&5
9279 sed 's/^/| /' conftest.$ac_ext >&5
9280
9281
9282 fi
9283
9284 rm -rf conftest.dSYM
9285 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9286       conftest$ac_exeext conftest.$ac_ext
9287         LDFLAGS="$save_LDFLAGS"
9288       else
9289         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
9290         archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
9291       fi
9292       archive_cmds_need_lc='no'
9293       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9294       hardcode_libdir_separator=:
9295       inherit_rpath=yes
9296       link_all_deplibs=yes
9297       ;;
9298
9299     netbsd*)
9300       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
9301         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
9302       else
9303         archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
9304       fi
9305       hardcode_libdir_flag_spec='-R$libdir'
9306       hardcode_direct=yes
9307       hardcode_shlibpath_var=no
9308       ;;
9309
9310     newsos6)
9311       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9312       hardcode_direct=yes
9313       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9314       hardcode_libdir_separator=:
9315       hardcode_shlibpath_var=no
9316       ;;
9317
9318     *nto* | *qnx*)
9319       ;;
9320
9321     openbsd*)
9322       if test -f /usr/libexec/ld.so; then
9323         hardcode_direct=yes
9324         hardcode_shlibpath_var=no
9325         hardcode_direct_absolute=yes
9326         if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
9327           archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
9328           archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
9329           hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
9330           export_dynamic_flag_spec='${wl}-E'
9331         else
9332           case $host_os in
9333            openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
9334              archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
9335              hardcode_libdir_flag_spec='-R$libdir'
9336              ;;
9337            *)
9338              archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
9339              hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
9340              ;;
9341           esac
9342         fi
9343       else
9344         ld_shlibs=no
9345       fi
9346       ;;
9347
9348     os2*)
9349       hardcode_libdir_flag_spec='-L$libdir'
9350       hardcode_minus_L=yes
9351       allow_undefined_flag=unsupported
9352       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'
9353       old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
9354       ;;
9355
9356     osf3*)
9357       if test "$GCC" = yes; then
9358         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
9359         archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
9360       else
9361         allow_undefined_flag=' -expect_unresolved \*'
9362         archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
9363       fi
9364       archive_cmds_need_lc='no'
9365       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9366       hardcode_libdir_separator=:
9367       ;;
9368
9369     osf4* | osf5*)      # as osf3* with the addition of -msym flag
9370       if test "$GCC" = yes; then
9371         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
9372         archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && $ECHO "X${wl}-set_version ${wl}$verstring" | $Xsed` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
9373         hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
9374       else
9375         allow_undefined_flag=' -expect_unresolved \*'
9376         archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib'
9377         archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
9378         $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "X-set_version $verstring" | $Xsed` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
9379
9380         # Both c and cxx compiler support -rpath directly
9381         hardcode_libdir_flag_spec='-rpath $libdir'
9382       fi
9383       archive_cmds_need_lc='no'
9384       hardcode_libdir_separator=:
9385       ;;
9386
9387     solaris*)
9388       no_undefined_flag=' -z defs'
9389       if test "$GCC" = yes; then
9390         wlarc='${wl}'
9391         archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
9392         archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
9393           $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
9394       else
9395         case `$CC -V 2>&1` in
9396         *"Compilers 5.0"*)
9397           wlarc=''
9398           archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
9399           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
9400           $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
9401           ;;
9402         *)
9403           wlarc='${wl}'
9404           archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
9405           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
9406           $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
9407           ;;
9408         esac
9409       fi
9410       hardcode_libdir_flag_spec='-R$libdir'
9411       hardcode_shlibpath_var=no
9412       case $host_os in
9413       solaris2.[0-5] | solaris2.[0-5].*) ;;
9414       *)
9415         # The compiler driver will combine and reorder linker options,
9416         # but understands `-z linker_flag'.  GCC discards it without `$wl',
9417         # but is careful enough not to reorder.
9418         # Supported since Solaris 2.6 (maybe 2.5.1?)
9419         if test "$GCC" = yes; then
9420           whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
9421         else
9422           whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
9423         fi
9424         ;;
9425       esac
9426       link_all_deplibs=yes
9427       ;;
9428
9429     sunos4*)
9430       if test "x$host_vendor" = xsequent; then
9431         # Use $CC to link under sequent, because it throws in some extra .o
9432         # files that make .init and .fini sections work.
9433         archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
9434       else
9435         archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
9436       fi
9437       hardcode_libdir_flag_spec='-L$libdir'
9438       hardcode_direct=yes
9439       hardcode_minus_L=yes
9440       hardcode_shlibpath_var=no
9441       ;;
9442
9443     sysv4)
9444       case $host_vendor in
9445         sni)
9446           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9447           hardcode_direct=yes # is this really true???
9448         ;;
9449         siemens)
9450           ## LD is ld it makes a PLAMLIB
9451           ## CC just makes a GrossModule.
9452           archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
9453           reload_cmds='$CC -r -o $output$reload_objs'
9454           hardcode_direct=no
9455         ;;
9456         motorola)
9457           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9458           hardcode_direct=no #Motorola manual says yes, but my tests say they lie
9459         ;;
9460       esac
9461       runpath_var='LD_RUN_PATH'
9462       hardcode_shlibpath_var=no
9463       ;;
9464
9465     sysv4.3*)
9466       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9467       hardcode_shlibpath_var=no
9468       export_dynamic_flag_spec='-Bexport'
9469       ;;
9470
9471     sysv4*MP*)
9472       if test -d /usr/nec; then
9473         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9474         hardcode_shlibpath_var=no
9475         runpath_var=LD_RUN_PATH
9476         hardcode_runpath_var=yes
9477         ld_shlibs=yes
9478       fi
9479       ;;
9480
9481     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
9482       no_undefined_flag='${wl}-z,text'
9483       archive_cmds_need_lc=no
9484       hardcode_shlibpath_var=no
9485       runpath_var='LD_RUN_PATH'
9486
9487       if test "$GCC" = yes; then
9488         archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9489         archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9490       else
9491         archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9492         archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9493       fi
9494       ;;
9495
9496     sysv5* | sco3.2v5* | sco5v6*)
9497       # Note: We can NOT use -z defs as we might desire, because we do not
9498       # link with -lc, and that would cause any symbols used from libc to
9499       # always be unresolved, which means just about no library would
9500       # ever link correctly.  If we're not using GNU ld we use -z text
9501       # though, which does catch some bad symbols but isn't as heavy-handed
9502       # as -z defs.
9503       no_undefined_flag='${wl}-z,text'
9504       allow_undefined_flag='${wl}-z,nodefs'
9505       archive_cmds_need_lc=no
9506       hardcode_shlibpath_var=no
9507       hardcode_libdir_flag_spec='${wl}-R,$libdir'
9508       hardcode_libdir_separator=':'
9509       link_all_deplibs=yes
9510       export_dynamic_flag_spec='${wl}-Bexport'
9511       runpath_var='LD_RUN_PATH'
9512
9513       if test "$GCC" = yes; then
9514         archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9515         archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9516       else
9517         archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9518         archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
9519       fi
9520       ;;
9521
9522     uts4*)
9523       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
9524       hardcode_libdir_flag_spec='-L$libdir'
9525       hardcode_shlibpath_var=no
9526       ;;
9527
9528     *)
9529       ld_shlibs=no
9530       ;;
9531     esac
9532
9533     if test x$host_vendor = xsni; then
9534       case $host in
9535       sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
9536         export_dynamic_flag_spec='${wl}-Blargedynsym'
9537         ;;
9538       esac
9539     fi
9540   fi
9541
9542 { $as_echo "$as_me:$LINENO: result: $ld_shlibs" >&5
9543 $as_echo "$ld_shlibs" >&6; }
9544 test "$ld_shlibs" = no && can_build_shared=no
9545
9546 with_gnu_ld=$with_gnu_ld
9547
9548
9549
9550
9551
9552
9553
9554
9555
9556
9557
9558
9559
9560
9561
9562 #
9563 # Do we need to explicitly link libc?
9564 #
9565 case "x$archive_cmds_need_lc" in
9566 x|xyes)
9567   # Assume -lc should be added
9568   archive_cmds_need_lc=yes
9569
9570   if test "$enable_shared" = yes && test "$GCC" = yes; then
9571     case $archive_cmds in
9572     *'~'*)
9573       # FIXME: we may have to deal with multi-command sequences.
9574       ;;
9575     '$CC '*)
9576       # Test whether the compiler implicitly links with -lc since on some
9577       # systems, -lgcc has to come before -lc. If gcc already passes -lc
9578       # to ld, don't add -lc before -lgcc.
9579       { $as_echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5
9580 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
9581       $RM conftest*
9582       echo "$lt_simple_compile_test_code" > conftest.$ac_ext
9583
9584       if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9585   (eval $ac_compile) 2>&5
9586   ac_status=$?
9587   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9588   (exit $ac_status); } 2>conftest.err; then
9589         soname=conftest
9590         lib=conftest
9591         libobjs=conftest.$ac_objext
9592         deplibs=
9593         wl=$lt_prog_compiler_wl
9594         pic_flag=$lt_prog_compiler_pic
9595         compiler_flags=-v
9596         linker_flags=-v
9597         verstring=
9598         output_objdir=.
9599         libname=conftest
9600         lt_save_allow_undefined_flag=$allow_undefined_flag
9601         allow_undefined_flag=
9602         if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\"") >&5
9603   (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
9604   ac_status=$?
9605   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9606   (exit $ac_status); }
9607         then
9608           archive_cmds_need_lc=no
9609         else
9610           archive_cmds_need_lc=yes
9611         fi
9612         allow_undefined_flag=$lt_save_allow_undefined_flag
9613       else
9614         cat conftest.err 1>&5
9615       fi
9616       $RM conftest*
9617       { $as_echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5
9618 $as_echo "$archive_cmds_need_lc" >&6; }
9619       ;;
9620     esac
9621   fi
9622   ;;
9623 esac
9624
9625
9626
9627
9628
9629
9630
9631
9632
9633
9634
9635
9636
9637
9638
9639
9640
9641
9642
9643
9644
9645
9646
9647
9648
9649
9650
9651
9652
9653
9654
9655
9656
9657
9658
9659
9660
9661
9662
9663
9664
9665
9666
9667
9668
9669
9670
9671
9672
9673
9674
9675
9676
9677
9678
9679
9680
9681
9682
9683
9684
9685
9686
9687
9688
9689
9690
9691
9692
9693
9694
9695
9696
9697
9698
9699
9700
9701
9702
9703
9704
9705
9706
9707
9708
9709
9710
9711
9712
9713
9714
9715
9716
9717
9718
9719
9720
9721
9722
9723
9724
9725
9726
9727
9728
9729
9730
9731
9732
9733
9734
9735
9736
9737
9738
9739
9740
9741
9742
9743
9744
9745
9746
9747
9748
9749
9750
9751
9752
9753
9754
9755
9756
9757
9758
9759
9760
9761
9762
9763
9764
9765
9766
9767
9768
9769
9770
9771
9772
9773
9774
9775
9776
9777
9778
9779
9780
9781   { $as_echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5
9782 $as_echo_n "checking dynamic linker characteristics... " >&6; }
9783
9784 if test "$GCC" = yes; then
9785   case $host_os in
9786     darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
9787     *) lt_awk_arg="/^libraries:/" ;;
9788   esac
9789   lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
9790   if $ECHO "$lt_search_path_spec" | $GREP ';' >/dev/null ; then
9791     # if the path contains ";" then we assume it to be the separator
9792     # otherwise default to the standard path separator (i.e. ":") - it is
9793     # assumed that no part of a normal pathname contains ";" but that should
9794     # okay in the real world where ";" in dirpaths is itself problematic.
9795     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED -e 's/;/ /g'`
9796   else
9797     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
9798   fi
9799   # Ok, now we have the path, separated by spaces, we can step through it
9800   # and add multilib dir if necessary.
9801   lt_tmp_lt_search_path_spec=
9802   lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
9803   for lt_sys_path in $lt_search_path_spec; do
9804     if test -d "$lt_sys_path/$lt_multi_os_dir"; then
9805       lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
9806     else
9807       test -d "$lt_sys_path" && \
9808         lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
9809     fi
9810   done
9811   lt_search_path_spec=`$ECHO $lt_tmp_lt_search_path_spec | awk '
9812 BEGIN {RS=" "; FS="/|\n";} {
9813   lt_foo="";
9814   lt_count=0;
9815   for (lt_i = NF; lt_i > 0; lt_i--) {
9816     if ($lt_i != "" && $lt_i != ".") {
9817       if ($lt_i == "..") {
9818         lt_count++;
9819       } else {
9820         if (lt_count == 0) {
9821           lt_foo="/" $lt_i lt_foo;
9822         } else {
9823           lt_count--;
9824         }
9825       }
9826     }
9827   }
9828   if (lt_foo != "") { lt_freq[lt_foo]++; }
9829   if (lt_freq[lt_foo] == 1) { print lt_foo; }
9830 }'`
9831   sys_lib_search_path_spec=`$ECHO $lt_search_path_spec`
9832 else
9833   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
9834 fi
9835 library_names_spec=
9836 libname_spec='lib$name'
9837 soname_spec=
9838 shrext_cmds=".so"
9839 postinstall_cmds=
9840 postuninstall_cmds=
9841 finish_cmds=
9842 finish_eval=
9843 shlibpath_var=
9844 shlibpath_overrides_runpath=unknown
9845 version_type=none
9846 dynamic_linker="$host_os ld.so"
9847 sys_lib_dlsearch_path_spec="/lib /usr/lib"
9848 need_lib_prefix=unknown
9849 hardcode_into_libs=no
9850
9851 # when you set need_version to no, make sure it does not cause -set_version
9852 # flags to be left without arguments
9853 need_version=unknown
9854
9855 case $host_os in
9856 aix3*)
9857   version_type=linux
9858   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
9859   shlibpath_var=LIBPATH
9860
9861   # AIX 3 has no versioning support, so we append a major version to the name.
9862   soname_spec='${libname}${release}${shared_ext}$major'
9863   ;;
9864
9865 aix[4-9]*)
9866   version_type=linux
9867   need_lib_prefix=no
9868   need_version=no
9869   hardcode_into_libs=yes
9870   if test "$host_cpu" = ia64; then
9871     # AIX 5 supports IA64
9872     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
9873     shlibpath_var=LD_LIBRARY_PATH
9874   else
9875     # With GCC up to 2.95.x, collect2 would create an import file
9876     # for dependence libraries.  The import file would start with
9877     # the line `#! .'.  This would cause the generated library to
9878     # depend on `.', always an invalid library.  This was fixed in
9879     # development snapshots of GCC prior to 3.0.
9880     case $host_os in
9881       aix4 | aix4.[01] | aix4.[01].*)
9882       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
9883            echo ' yes '
9884            echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
9885         :
9886       else
9887         can_build_shared=no
9888       fi
9889       ;;
9890     esac
9891     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
9892     # soname into executable. Probably we can add versioning support to
9893     # collect2, so additional links can be useful in future.
9894     if test "$aix_use_runtimelinking" = yes; then
9895       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
9896       # instead of lib<name>.a to let people know that these are not
9897       # typical AIX shared libraries.
9898       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9899     else
9900       # We preserve .a as extension for shared libraries through AIX4.2
9901       # and later when we are not doing run time linking.
9902       library_names_spec='${libname}${release}.a $libname.a'
9903       soname_spec='${libname}${release}${shared_ext}$major'
9904     fi
9905     shlibpath_var=LIBPATH
9906   fi
9907   ;;
9908
9909 amigaos*)
9910   case $host_cpu in
9911   powerpc)
9912     # Since July 2007 AmigaOS4 officially supports .so libraries.
9913     # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
9914     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9915     ;;
9916   m68k)
9917     library_names_spec='$libname.ixlibrary $libname.a'
9918     # Create ${libname}_ixlibrary.a entries in /sys/libs.
9919     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'
9920     ;;
9921   esac
9922   ;;
9923
9924 beos*)
9925   library_names_spec='${libname}${shared_ext}'
9926   dynamic_linker="$host_os ld.so"
9927   shlibpath_var=LIBRARY_PATH
9928   ;;
9929
9930 bsdi[45]*)
9931   version_type=linux
9932   need_version=no
9933   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
9934   soname_spec='${libname}${release}${shared_ext}$major'
9935   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
9936   shlibpath_var=LD_LIBRARY_PATH
9937   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
9938   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
9939   # the default ld.so.conf also contains /usr/contrib/lib and
9940   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
9941   # libtool to hard-code these into programs
9942   ;;
9943
9944 cygwin* | mingw* | pw32* | cegcc*)
9945   version_type=windows
9946   shrext_cmds=".dll"
9947   need_version=no
9948   need_lib_prefix=no
9949
9950   case $GCC,$host_os in
9951   yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
9952     library_names_spec='$libname.dll.a'
9953     # DLL is installed to $(libdir)/../bin by postinstall_cmds
9954     postinstall_cmds='base_file=`basename \${file}`~
9955       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
9956       dldir=$destdir/`dirname \$dlpath`~
9957       test -d \$dldir || mkdir -p \$dldir~
9958       $install_prog $dir/$dlname \$dldir/$dlname~
9959       chmod a+x \$dldir/$dlname~
9960       if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
9961         eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
9962       fi'
9963     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
9964       dlpath=$dir/\$dldll~
9965        $RM \$dlpath'
9966     shlibpath_overrides_runpath=yes
9967
9968     case $host_os in
9969     cygwin*)
9970       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
9971       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9972       sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib"
9973       ;;
9974     mingw* | cegcc*)
9975       # MinGW DLLs use traditional 'lib' prefix
9976       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9977       sys_lib_search_path_spec=`$CC -print-search-dirs | $GREP "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
9978       if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
9979         # It is most probably a Windows format PATH printed by
9980         # mingw gcc, but we are running on Cygwin. Gcc prints its search
9981         # path with ; separators, and with drive letters. We can handle the
9982         # drive letters (cygwin fileutils understands them), so leave them,
9983         # especially as we might pass files found there to a mingw objdump,
9984         # which wouldn't understand a cygwinified path. Ahh.
9985         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
9986       else
9987         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
9988       fi
9989       ;;
9990     pw32*)
9991       # pw32 DLLs use 'pw' prefix rather than 'lib'
9992       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
9993       ;;
9994     esac
9995     ;;
9996
9997   *)
9998     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
9999     ;;
10000   esac
10001   dynamic_linker='Win32 ld.exe'
10002   # FIXME: first we should search . and the directory the executable is in
10003   shlibpath_var=PATH
10004   ;;
10005
10006 darwin* | rhapsody*)
10007   dynamic_linker="$host_os dyld"
10008   version_type=darwin
10009   need_lib_prefix=no
10010   need_version=no
10011   library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
10012   soname_spec='${libname}${release}${major}$shared_ext'
10013   shlibpath_overrides_runpath=yes
10014   shlibpath_var=DYLD_LIBRARY_PATH
10015   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
10016
10017   sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
10018   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
10019   ;;
10020
10021 dgux*)
10022   version_type=linux
10023   need_lib_prefix=no
10024   need_version=no
10025   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
10026   soname_spec='${libname}${release}${shared_ext}$major'
10027   shlibpath_var=LD_LIBRARY_PATH
10028   ;;
10029
10030 freebsd1*)
10031   dynamic_linker=no
10032   ;;
10033
10034 freebsd* | dragonfly*)
10035   # DragonFly does not have aout.  When/if they implement a new
10036   # versioning mechanism, adjust this.
10037   if test -x /usr/bin/objformat; then
10038     objformat=`/usr/bin/objformat`
10039   else
10040     case $host_os in
10041     freebsd[123]*) objformat=aout ;;
10042     *) objformat=elf ;;
10043     esac
10044   fi
10045   version_type=freebsd-$objformat
10046   case $version_type in
10047     freebsd-elf*)
10048       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
10049       need_version=no
10050       need_lib_prefix=no
10051       ;;
10052     freebsd-*)
10053       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
10054       need_version=yes
10055       ;;
10056   esac
10057   shlibpath_var=LD_LIBRARY_PATH
10058   case $host_os in
10059   freebsd2*)
10060     shlibpath_overrides_runpath=yes
10061     ;;
10062   freebsd3.[01]* | freebsdelf3.[01]*)
10063     shlibpath_overrides_runpath=yes
10064     hardcode_into_libs=yes
10065     ;;
10066   freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
10067   freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
10068     shlibpath_overrides_runpath=no
10069     hardcode_into_libs=yes
10070     ;;
10071   *) # from 4.6 on, and DragonFly
10072     shlibpath_overrides_runpath=yes
10073     hardcode_into_libs=yes
10074     ;;
10075   esac
10076   ;;
10077
10078 gnu*)
10079   version_type=linux
10080   need_lib_prefix=no
10081   need_version=no
10082   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
10083   soname_spec='${libname}${release}${shared_ext}$major'
10084   shlibpath_var=LD_LIBRARY_PATH
10085   hardcode_into_libs=yes
10086   ;;
10087
10088 hpux9* | hpux10* | hpux11*)
10089   # Give a soname corresponding to the major version so that dld.sl refuses to
10090   # link against other versions.
10091   version_type=sunos
10092   need_lib_prefix=no
10093   need_version=no
10094   case $host_cpu in
10095   ia64*)
10096     shrext_cmds='.so'
10097     hardcode_into_libs=yes
10098     dynamic_linker="$host_os dld.so"
10099     shlibpath_var=LD_LIBRARY_PATH
10100     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
10101     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10102     soname_spec='${libname}${release}${shared_ext}$major'
10103     if test "X$HPUX_IA64_MODE" = X32; then
10104       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
10105     else
10106       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
10107     fi
10108     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
10109     ;;
10110   hppa*64*)
10111     shrext_cmds='.sl'
10112     hardcode_into_libs=yes
10113     dynamic_linker="$host_os dld.sl"
10114     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
10115     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
10116     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10117     soname_spec='${libname}${release}${shared_ext}$major'
10118     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
10119     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
10120     ;;
10121   *)
10122     shrext_cmds='.sl'
10123     dynamic_linker="$host_os dld.sl"
10124     shlibpath_var=SHLIB_PATH
10125     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
10126     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10127     soname_spec='${libname}${release}${shared_ext}$major'
10128     ;;
10129   esac
10130   # HP-UX runs *really* slowly unless shared libraries are mode 555.
10131   postinstall_cmds='chmod 555 $lib'
10132   ;;
10133
10134 interix[3-9]*)
10135   version_type=linux
10136   need_lib_prefix=no
10137   need_version=no
10138   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
10139   soname_spec='${libname}${release}${shared_ext}$major'
10140   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
10141   shlibpath_var=LD_LIBRARY_PATH
10142   shlibpath_overrides_runpath=no
10143   hardcode_into_libs=yes
10144   ;;
10145
10146 irix5* | irix6* | nonstopux*)
10147   case $host_os in
10148     nonstopux*) version_type=nonstopux ;;
10149     *)
10150         if test "$lt_cv_prog_gnu_ld" = yes; then
10151                 version_type=linux
10152         else
10153                 version_type=irix
10154         fi ;;
10155   esac
10156   need_lib_prefix=no
10157   need_version=no
10158   soname_spec='${libname}${release}${shared_ext}$major'
10159   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
10160   case $host_os in
10161   irix5* | nonstopux*)
10162     libsuff= shlibsuff=
10163     ;;
10164   *)
10165     case $LD in # libtool.m4 will add one of these switches to LD
10166     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
10167       libsuff= shlibsuff= libmagic=32-bit;;
10168     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
10169       libsuff=32 shlibsuff=N32 libmagic=N32;;
10170     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
10171       libsuff=64 shlibsuff=64 libmagic=64-bit;;
10172     *) libsuff= shlibsuff= libmagic=never-match;;
10173     esac
10174     ;;
10175   esac
10176   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
10177   shlibpath_overrides_runpath=no
10178   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
10179   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
10180   hardcode_into_libs=yes
10181   ;;
10182
10183 # No shared lib support for Linux oldld, aout, or coff.
10184 linux*oldld* | linux*aout* | linux*coff*)
10185   dynamic_linker=no
10186   ;;
10187
10188 # This must be Linux ELF.
10189 linux* | k*bsd*-gnu)
10190   version_type=linux
10191   need_lib_prefix=no
10192   need_version=no
10193   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10194   soname_spec='${libname}${release}${shared_ext}$major'
10195   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
10196   shlibpath_var=LD_LIBRARY_PATH
10197   shlibpath_overrides_runpath=no
10198   # Some binutils ld are patched to set DT_RUNPATH
10199   save_LDFLAGS=$LDFLAGS
10200   save_libdir=$libdir
10201   eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
10202        LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
10203   cat >conftest.$ac_ext <<_ACEOF
10204 /* confdefs.h.  */
10205 _ACEOF
10206 cat confdefs.h >>conftest.$ac_ext
10207 cat >>conftest.$ac_ext <<_ACEOF
10208 /* end confdefs.h.  */
10209
10210 int
10211 main ()
10212 {
10213
10214   ;
10215   return 0;
10216 }
10217 _ACEOF
10218 rm -f conftest.$ac_objext conftest$ac_exeext
10219 if { (ac_try="$ac_link"
10220 case "(($ac_try" in
10221   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10222   *) ac_try_echo=$ac_try;;
10223 esac
10224 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10225 $as_echo "$ac_try_echo") >&5
10226   (eval "$ac_link") 2>conftest.er1
10227   ac_status=$?
10228   grep -v '^ *+' conftest.er1 >conftest.err
10229   rm -f conftest.er1
10230   cat conftest.err >&5
10231   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10232   (exit $ac_status); } && {
10233          test -z "$ac_c_werror_flag" ||
10234          test ! -s conftest.err
10235        } && test -s conftest$ac_exeext && {
10236          test "$cross_compiling" = yes ||
10237          $as_test_x conftest$ac_exeext
10238        }; then
10239   if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then
10240   shlibpath_overrides_runpath=yes
10241 fi
10242
10243 else
10244   $as_echo "$as_me: failed program was:" >&5
10245 sed 's/^/| /' conftest.$ac_ext >&5
10246
10247
10248 fi
10249
10250 rm -rf conftest.dSYM
10251 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10252       conftest$ac_exeext conftest.$ac_ext
10253   LDFLAGS=$save_LDFLAGS
10254   libdir=$save_libdir
10255
10256   # This implies no fast_install, which is unacceptable.
10257   # Some rework will be needed to allow for fast_install
10258   # before this can be enabled.
10259   hardcode_into_libs=yes
10260
10261   # Add ABI-specific directories to the system library path.
10262   sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib"
10263
10264   # Append ld.so.conf contents to the search path
10265   if test -f /etc/ld.so.conf; then
10266     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' ' '`
10267     sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
10268   fi
10269
10270   # We used to test for /lib/ld.so.1 and disable shared libraries on
10271   # powerpc, because MkLinux only supported shared libraries with the
10272   # GNU dynamic linker.  Since this was broken with cross compilers,
10273   # most powerpc-linux boxes support dynamic linking these days and
10274   # people can always --disable-shared, the test was removed, and we
10275   # assume the GNU/Linux dynamic linker is in use.
10276   dynamic_linker='GNU/Linux ld.so'
10277   ;;
10278
10279 netbsd*)
10280   version_type=sunos
10281   need_lib_prefix=no
10282   need_version=no
10283   if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
10284     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
10285     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
10286     dynamic_linker='NetBSD (a.out) ld.so'
10287   else
10288     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
10289     soname_spec='${libname}${release}${shared_ext}$major'
10290     dynamic_linker='NetBSD ld.elf_so'
10291   fi
10292   shlibpath_var=LD_LIBRARY_PATH
10293   shlibpath_overrides_runpath=yes
10294   hardcode_into_libs=yes
10295   ;;
10296
10297 newsos6)
10298   version_type=linux
10299   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10300   shlibpath_var=LD_LIBRARY_PATH
10301   shlibpath_overrides_runpath=yes
10302   ;;
10303
10304 *nto* | *qnx*)
10305   version_type=qnx
10306   need_lib_prefix=no
10307   need_version=no
10308   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10309   soname_spec='${libname}${release}${shared_ext}$major'
10310   shlibpath_var=LD_LIBRARY_PATH
10311   shlibpath_overrides_runpath=no
10312   hardcode_into_libs=yes
10313   dynamic_linker='ldqnx.so'
10314   ;;
10315
10316 openbsd*)
10317   version_type=sunos
10318   sys_lib_dlsearch_path_spec="/usr/lib"
10319   need_lib_prefix=no
10320   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
10321   case $host_os in
10322     openbsd3.3 | openbsd3.3.*)  need_version=yes ;;
10323     *)                          need_version=no  ;;
10324   esac
10325   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
10326   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
10327   shlibpath_var=LD_LIBRARY_PATH
10328   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
10329     case $host_os in
10330       openbsd2.[89] | openbsd2.[89].*)
10331         shlibpath_overrides_runpath=no
10332         ;;
10333       *)
10334         shlibpath_overrides_runpath=yes
10335         ;;
10336       esac
10337   else
10338     shlibpath_overrides_runpath=yes
10339   fi
10340   ;;
10341
10342 os2*)
10343   libname_spec='$name'
10344   shrext_cmds=".dll"
10345   need_lib_prefix=no
10346   library_names_spec='$libname${shared_ext} $libname.a'
10347   dynamic_linker='OS/2 ld.exe'
10348   shlibpath_var=LIBPATH
10349   ;;
10350
10351 osf3* | osf4* | osf5*)
10352   version_type=osf
10353   need_lib_prefix=no
10354   need_version=no
10355   soname_spec='${libname}${release}${shared_ext}$major'
10356   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10357   shlibpath_var=LD_LIBRARY_PATH
10358   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
10359   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
10360   ;;
10361
10362 rdos*)
10363   dynamic_linker=no
10364   ;;
10365
10366 solaris*)
10367   version_type=linux
10368   need_lib_prefix=no
10369   need_version=no
10370   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10371   soname_spec='${libname}${release}${shared_ext}$major'
10372   shlibpath_var=LD_LIBRARY_PATH
10373   shlibpath_overrides_runpath=yes
10374   hardcode_into_libs=yes
10375   # ldd complains unless libraries are executable
10376   postinstall_cmds='chmod +x $lib'
10377   ;;
10378
10379 sunos4*)
10380   version_type=sunos
10381   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
10382   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
10383   shlibpath_var=LD_LIBRARY_PATH
10384   shlibpath_overrides_runpath=yes
10385   if test "$with_gnu_ld" = yes; then
10386     need_lib_prefix=no
10387   fi
10388   need_version=yes
10389   ;;
10390
10391 sysv4 | sysv4.3*)
10392   version_type=linux
10393   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10394   soname_spec='${libname}${release}${shared_ext}$major'
10395   shlibpath_var=LD_LIBRARY_PATH
10396   case $host_vendor in
10397     sni)
10398       shlibpath_overrides_runpath=no
10399       need_lib_prefix=no
10400       runpath_var=LD_RUN_PATH
10401       ;;
10402     siemens)
10403       need_lib_prefix=no
10404       ;;
10405     motorola)
10406       need_lib_prefix=no
10407       need_version=no
10408       shlibpath_overrides_runpath=no
10409       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
10410       ;;
10411   esac
10412   ;;
10413
10414 sysv4*MP*)
10415   if test -d /usr/nec ;then
10416     version_type=linux
10417     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
10418     soname_spec='$libname${shared_ext}.$major'
10419     shlibpath_var=LD_LIBRARY_PATH
10420   fi
10421   ;;
10422
10423 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
10424   version_type=freebsd-elf
10425   need_lib_prefix=no
10426   need_version=no
10427   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
10428   soname_spec='${libname}${release}${shared_ext}$major'
10429   shlibpath_var=LD_LIBRARY_PATH
10430   shlibpath_overrides_runpath=yes
10431   hardcode_into_libs=yes
10432   if test "$with_gnu_ld" = yes; then
10433     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
10434   else
10435     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
10436     case $host_os in
10437       sco3.2v5*)
10438         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
10439         ;;
10440     esac
10441   fi
10442   sys_lib_dlsearch_path_spec='/usr/lib'
10443   ;;
10444
10445 tpf*)
10446   # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
10447   version_type=linux
10448   need_lib_prefix=no
10449   need_version=no
10450   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10451   shlibpath_var=LD_LIBRARY_PATH
10452   shlibpath_overrides_runpath=no
10453   hardcode_into_libs=yes
10454   ;;
10455
10456 uts4*)
10457   version_type=linux
10458   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
10459   soname_spec='${libname}${release}${shared_ext}$major'
10460   shlibpath_var=LD_LIBRARY_PATH
10461   ;;
10462
10463 *)
10464   dynamic_linker=no
10465   ;;
10466 esac
10467 { $as_echo "$as_me:$LINENO: result: $dynamic_linker" >&5
10468 $as_echo "$dynamic_linker" >&6; }
10469 test "$dynamic_linker" = no && can_build_shared=no
10470
10471 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
10472 if test "$GCC" = yes; then
10473   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
10474 fi
10475
10476 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
10477   sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
10478 fi
10479 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
10480   sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
10481 fi
10482
10483
10484
10485
10486
10487
10488
10489
10490
10491
10492
10493
10494
10495
10496
10497
10498
10499
10500
10501
10502
10503
10504
10505
10506
10507
10508
10509
10510
10511
10512
10513
10514
10515
10516
10517
10518
10519
10520
10521
10522
10523
10524
10525
10526
10527
10528
10529
10530
10531
10532
10533
10534
10535
10536
10537
10538
10539
10540
10541
10542
10543
10544
10545
10546
10547
10548
10549
10550
10551
10552
10553
10554
10555
10556
10557
10558
10559
10560
10561
10562
10563
10564
10565
10566
10567
10568
10569   { $as_echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5
10570 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
10571 hardcode_action=
10572 if test -n "$hardcode_libdir_flag_spec" ||
10573    test -n "$runpath_var" ||
10574    test "X$hardcode_automatic" = "Xyes" ; then
10575
10576   # We can hardcode non-existent directories.
10577   if test "$hardcode_direct" != no &&
10578      # If the only mechanism to avoid hardcoding is shlibpath_var, we
10579      # have to relink, otherwise we might link with an installed library
10580      # when we should be linking with a yet-to-be-installed one
10581      ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
10582      test "$hardcode_minus_L" != no; then
10583     # Linking always hardcodes the temporary library directory.
10584     hardcode_action=relink
10585   else
10586     # We can link without hardcoding, and we can hardcode nonexisting dirs.
10587     hardcode_action=immediate
10588   fi
10589 else
10590   # We cannot hardcode anything, or else we can only hardcode existing
10591   # directories.
10592   hardcode_action=unsupported
10593 fi
10594 { $as_echo "$as_me:$LINENO: result: $hardcode_action" >&5
10595 $as_echo "$hardcode_action" >&6; }
10596
10597 if test "$hardcode_action" = relink ||
10598    test "$inherit_rpath" = yes; then
10599   # Fast installation is not supported
10600   enable_fast_install=no
10601 elif test "$shlibpath_overrides_runpath" = yes ||
10602      test "$enable_shared" = no; then
10603   # Fast installation is not necessary
10604   enable_fast_install=needless
10605 fi
10606
10607
10608
10609
10610
10611
10612   if test "x$enable_dlopen" != xyes; then
10613   enable_dlopen=unknown
10614   enable_dlopen_self=unknown
10615   enable_dlopen_self_static=unknown
10616 else
10617   lt_cv_dlopen=no
10618   lt_cv_dlopen_libs=
10619
10620   case $host_os in
10621   beos*)
10622     lt_cv_dlopen="load_add_on"
10623     lt_cv_dlopen_libs=
10624     lt_cv_dlopen_self=yes
10625     ;;
10626
10627   mingw* | pw32* | cegcc*)
10628     lt_cv_dlopen="LoadLibrary"
10629     lt_cv_dlopen_libs=
10630     ;;
10631
10632   cygwin*)
10633     lt_cv_dlopen="dlopen"
10634     lt_cv_dlopen_libs=
10635     ;;
10636
10637   darwin*)
10638   # if libdl is installed we need to link against it
10639     { $as_echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
10640 $as_echo_n "checking for dlopen in -ldl... " >&6; }
10641 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
10642   $as_echo_n "(cached) " >&6
10643 else
10644   ac_check_lib_save_LIBS=$LIBS
10645 LIBS="-ldl  $LIBS"
10646 cat >conftest.$ac_ext <<_ACEOF
10647 /* confdefs.h.  */
10648 _ACEOF
10649 cat confdefs.h >>conftest.$ac_ext
10650 cat >>conftest.$ac_ext <<_ACEOF
10651 /* end confdefs.h.  */
10652
10653 /* Override any GCC internal prototype to avoid an error.
10654    Use char because int might match the return type of a GCC
10655    builtin and then its argument prototype would still apply.  */
10656 #ifdef __cplusplus
10657 extern "C"
10658 #endif
10659 char dlopen ();
10660 int
10661 main ()
10662 {
10663 return dlopen ();
10664   ;
10665   return 0;
10666 }
10667 _ACEOF
10668 rm -f conftest.$ac_objext conftest$ac_exeext
10669 if { (ac_try="$ac_link"
10670 case "(($ac_try" in
10671   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10672   *) ac_try_echo=$ac_try;;
10673 esac
10674 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10675 $as_echo "$ac_try_echo") >&5
10676   (eval "$ac_link") 2>conftest.er1
10677   ac_status=$?
10678   grep -v '^ *+' conftest.er1 >conftest.err
10679   rm -f conftest.er1
10680   cat conftest.err >&5
10681   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10682   (exit $ac_status); } && {
10683          test -z "$ac_c_werror_flag" ||
10684          test ! -s conftest.err
10685        } && test -s conftest$ac_exeext && {
10686          test "$cross_compiling" = yes ||
10687          $as_test_x conftest$ac_exeext
10688        }; then
10689   ac_cv_lib_dl_dlopen=yes
10690 else
10691   $as_echo "$as_me: failed program was:" >&5
10692 sed 's/^/| /' conftest.$ac_ext >&5
10693
10694         ac_cv_lib_dl_dlopen=no
10695 fi
10696
10697 rm -rf conftest.dSYM
10698 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10699       conftest$ac_exeext conftest.$ac_ext
10700 LIBS=$ac_check_lib_save_LIBS
10701 fi
10702 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
10703 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
10704 if test "x$ac_cv_lib_dl_dlopen" = x""yes; then
10705   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
10706 else
10707
10708     lt_cv_dlopen="dyld"
10709     lt_cv_dlopen_libs=
10710     lt_cv_dlopen_self=yes
10711
10712 fi
10713
10714     ;;
10715
10716   *)
10717     { $as_echo "$as_me:$LINENO: checking for shl_load" >&5
10718 $as_echo_n "checking for shl_load... " >&6; }
10719 if test "${ac_cv_func_shl_load+set}" = set; then
10720   $as_echo_n "(cached) " >&6
10721 else
10722   cat >conftest.$ac_ext <<_ACEOF
10723 /* confdefs.h.  */
10724 _ACEOF
10725 cat confdefs.h >>conftest.$ac_ext
10726 cat >>conftest.$ac_ext <<_ACEOF
10727 /* end confdefs.h.  */
10728 /* Define shl_load to an innocuous variant, in case <limits.h> declares shl_load.
10729    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
10730 #define shl_load innocuous_shl_load
10731
10732 /* System header to define __stub macros and hopefully few prototypes,
10733     which can conflict with char shl_load (); below.
10734     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10735     <limits.h> exists even on freestanding compilers.  */
10736
10737 #ifdef __STDC__
10738 # include <limits.h>
10739 #else
10740 # include <assert.h>
10741 #endif
10742
10743 #undef shl_load
10744
10745 /* Override any GCC internal prototype to avoid an error.
10746    Use char because int might match the return type of a GCC
10747    builtin and then its argument prototype would still apply.  */
10748 #ifdef __cplusplus
10749 extern "C"
10750 #endif
10751 char shl_load ();
10752 /* The GNU C library defines this for functions which it implements
10753     to always fail with ENOSYS.  Some functions are actually named
10754     something starting with __ and the normal name is an alias.  */
10755 #if defined __stub_shl_load || defined __stub___shl_load
10756 choke me
10757 #endif
10758
10759 int
10760 main ()
10761 {
10762 return shl_load ();
10763   ;
10764   return 0;
10765 }
10766 _ACEOF
10767 rm -f conftest.$ac_objext conftest$ac_exeext
10768 if { (ac_try="$ac_link"
10769 case "(($ac_try" in
10770   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10771   *) ac_try_echo=$ac_try;;
10772 esac
10773 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10774 $as_echo "$ac_try_echo") >&5
10775   (eval "$ac_link") 2>conftest.er1
10776   ac_status=$?
10777   grep -v '^ *+' conftest.er1 >conftest.err
10778   rm -f conftest.er1
10779   cat conftest.err >&5
10780   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10781   (exit $ac_status); } && {
10782          test -z "$ac_c_werror_flag" ||
10783          test ! -s conftest.err
10784        } && test -s conftest$ac_exeext && {
10785          test "$cross_compiling" = yes ||
10786          $as_test_x conftest$ac_exeext
10787        }; then
10788   ac_cv_func_shl_load=yes
10789 else
10790   $as_echo "$as_me: failed program was:" >&5
10791 sed 's/^/| /' conftest.$ac_ext >&5
10792
10793         ac_cv_func_shl_load=no
10794 fi
10795
10796 rm -rf conftest.dSYM
10797 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10798       conftest$ac_exeext conftest.$ac_ext
10799 fi
10800 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5
10801 $as_echo "$ac_cv_func_shl_load" >&6; }
10802 if test "x$ac_cv_func_shl_load" = x""yes; then
10803   lt_cv_dlopen="shl_load"
10804 else
10805   { $as_echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5
10806 $as_echo_n "checking for shl_load in -ldld... " >&6; }
10807 if test "${ac_cv_lib_dld_shl_load+set}" = set; then
10808   $as_echo_n "(cached) " >&6
10809 else
10810   ac_check_lib_save_LIBS=$LIBS
10811 LIBS="-ldld  $LIBS"
10812 cat >conftest.$ac_ext <<_ACEOF
10813 /* confdefs.h.  */
10814 _ACEOF
10815 cat confdefs.h >>conftest.$ac_ext
10816 cat >>conftest.$ac_ext <<_ACEOF
10817 /* end confdefs.h.  */
10818
10819 /* Override any GCC internal prototype to avoid an error.
10820    Use char because int might match the return type of a GCC
10821    builtin and then its argument prototype would still apply.  */
10822 #ifdef __cplusplus
10823 extern "C"
10824 #endif
10825 char shl_load ();
10826 int
10827 main ()
10828 {
10829 return shl_load ();
10830   ;
10831   return 0;
10832 }
10833 _ACEOF
10834 rm -f conftest.$ac_objext conftest$ac_exeext
10835 if { (ac_try="$ac_link"
10836 case "(($ac_try" in
10837   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10838   *) ac_try_echo=$ac_try;;
10839 esac
10840 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10841 $as_echo "$ac_try_echo") >&5
10842   (eval "$ac_link") 2>conftest.er1
10843   ac_status=$?
10844   grep -v '^ *+' conftest.er1 >conftest.err
10845   rm -f conftest.er1
10846   cat conftest.err >&5
10847   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10848   (exit $ac_status); } && {
10849          test -z "$ac_c_werror_flag" ||
10850          test ! -s conftest.err
10851        } && test -s conftest$ac_exeext && {
10852          test "$cross_compiling" = yes ||
10853          $as_test_x conftest$ac_exeext
10854        }; then
10855   ac_cv_lib_dld_shl_load=yes
10856 else
10857   $as_echo "$as_me: failed program was:" >&5
10858 sed 's/^/| /' conftest.$ac_ext >&5
10859
10860         ac_cv_lib_dld_shl_load=no
10861 fi
10862
10863 rm -rf conftest.dSYM
10864 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10865       conftest$ac_exeext conftest.$ac_ext
10866 LIBS=$ac_check_lib_save_LIBS
10867 fi
10868 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5
10869 $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
10870 if test "x$ac_cv_lib_dld_shl_load" = x""yes; then
10871   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
10872 else
10873   { $as_echo "$as_me:$LINENO: checking for dlopen" >&5
10874 $as_echo_n "checking for dlopen... " >&6; }
10875 if test "${ac_cv_func_dlopen+set}" = set; then
10876   $as_echo_n "(cached) " >&6
10877 else
10878   cat >conftest.$ac_ext <<_ACEOF
10879 /* confdefs.h.  */
10880 _ACEOF
10881 cat confdefs.h >>conftest.$ac_ext
10882 cat >>conftest.$ac_ext <<_ACEOF
10883 /* end confdefs.h.  */
10884 /* Define dlopen to an innocuous variant, in case <limits.h> declares dlopen.
10885    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
10886 #define dlopen innocuous_dlopen
10887
10888 /* System header to define __stub macros and hopefully few prototypes,
10889     which can conflict with char dlopen (); below.
10890     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10891     <limits.h> exists even on freestanding compilers.  */
10892
10893 #ifdef __STDC__
10894 # include <limits.h>
10895 #else
10896 # include <assert.h>
10897 #endif
10898
10899 #undef dlopen
10900
10901 /* Override any GCC internal prototype to avoid an error.
10902    Use char because int might match the return type of a GCC
10903    builtin and then its argument prototype would still apply.  */
10904 #ifdef __cplusplus
10905 extern "C"
10906 #endif
10907 char dlopen ();
10908 /* The GNU C library defines this for functions which it implements
10909     to always fail with ENOSYS.  Some functions are actually named
10910     something starting with __ and the normal name is an alias.  */
10911 #if defined __stub_dlopen || defined __stub___dlopen
10912 choke me
10913 #endif
10914
10915 int
10916 main ()
10917 {
10918 return dlopen ();
10919   ;
10920   return 0;
10921 }
10922 _ACEOF
10923 rm -f conftest.$ac_objext conftest$ac_exeext
10924 if { (ac_try="$ac_link"
10925 case "(($ac_try" in
10926   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10927   *) ac_try_echo=$ac_try;;
10928 esac
10929 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10930 $as_echo "$ac_try_echo") >&5
10931   (eval "$ac_link") 2>conftest.er1
10932   ac_status=$?
10933   grep -v '^ *+' conftest.er1 >conftest.err
10934   rm -f conftest.er1
10935   cat conftest.err >&5
10936   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10937   (exit $ac_status); } && {
10938          test -z "$ac_c_werror_flag" ||
10939          test ! -s conftest.err
10940        } && test -s conftest$ac_exeext && {
10941          test "$cross_compiling" = yes ||
10942          $as_test_x conftest$ac_exeext
10943        }; then
10944   ac_cv_func_dlopen=yes
10945 else
10946   $as_echo "$as_me: failed program was:" >&5
10947 sed 's/^/| /' conftest.$ac_ext >&5
10948
10949         ac_cv_func_dlopen=no
10950 fi
10951
10952 rm -rf conftest.dSYM
10953 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10954       conftest$ac_exeext conftest.$ac_ext
10955 fi
10956 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
10957 $as_echo "$ac_cv_func_dlopen" >&6; }
10958 if test "x$ac_cv_func_dlopen" = x""yes; then
10959   lt_cv_dlopen="dlopen"
10960 else
10961   { $as_echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
10962 $as_echo_n "checking for dlopen in -ldl... " >&6; }
10963 if test "${ac_cv_lib_dl_dlopen+set}" = set; then
10964   $as_echo_n "(cached) " >&6
10965 else
10966   ac_check_lib_save_LIBS=$LIBS
10967 LIBS="-ldl  $LIBS"
10968 cat >conftest.$ac_ext <<_ACEOF
10969 /* confdefs.h.  */
10970 _ACEOF
10971 cat confdefs.h >>conftest.$ac_ext
10972 cat >>conftest.$ac_ext <<_ACEOF
10973 /* end confdefs.h.  */
10974
10975 /* Override any GCC internal prototype to avoid an error.
10976    Use char because int might match the return type of a GCC
10977    builtin and then its argument prototype would still apply.  */
10978 #ifdef __cplusplus
10979 extern "C"
10980 #endif
10981 char dlopen ();
10982 int
10983 main ()
10984 {
10985 return dlopen ();
10986   ;
10987   return 0;
10988 }
10989 _ACEOF
10990 rm -f conftest.$ac_objext conftest$ac_exeext
10991 if { (ac_try="$ac_link"
10992 case "(($ac_try" in
10993   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10994   *) ac_try_echo=$ac_try;;
10995 esac
10996 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10997 $as_echo "$ac_try_echo") >&5
10998   (eval "$ac_link") 2>conftest.er1
10999   ac_status=$?
11000   grep -v '^ *+' conftest.er1 >conftest.err
11001   rm -f conftest.er1
11002   cat conftest.err >&5
11003   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11004   (exit $ac_status); } && {
11005          test -z "$ac_c_werror_flag" ||
11006          test ! -s conftest.err
11007        } && test -s conftest$ac_exeext && {
11008          test "$cross_compiling" = yes ||
11009          $as_test_x conftest$ac_exeext
11010        }; then
11011   ac_cv_lib_dl_dlopen=yes
11012 else
11013   $as_echo "$as_me: failed program was:" >&5
11014 sed 's/^/| /' conftest.$ac_ext >&5
11015
11016         ac_cv_lib_dl_dlopen=no
11017 fi
11018
11019 rm -rf conftest.dSYM
11020 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11021       conftest$ac_exeext conftest.$ac_ext
11022 LIBS=$ac_check_lib_save_LIBS
11023 fi
11024 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
11025 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
11026 if test "x$ac_cv_lib_dl_dlopen" = x""yes; then
11027   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
11028 else
11029   { $as_echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5
11030 $as_echo_n "checking for dlopen in -lsvld... " >&6; }
11031 if test "${ac_cv_lib_svld_dlopen+set}" = set; then
11032   $as_echo_n "(cached) " >&6
11033 else
11034   ac_check_lib_save_LIBS=$LIBS
11035 LIBS="-lsvld  $LIBS"
11036 cat >conftest.$ac_ext <<_ACEOF
11037 /* confdefs.h.  */
11038 _ACEOF
11039 cat confdefs.h >>conftest.$ac_ext
11040 cat >>conftest.$ac_ext <<_ACEOF
11041 /* end confdefs.h.  */
11042
11043 /* Override any GCC internal prototype to avoid an error.
11044    Use char because int might match the return type of a GCC
11045    builtin and then its argument prototype would still apply.  */
11046 #ifdef __cplusplus
11047 extern "C"
11048 #endif
11049 char dlopen ();
11050 int
11051 main ()
11052 {
11053 return dlopen ();
11054   ;
11055   return 0;
11056 }
11057 _ACEOF
11058 rm -f conftest.$ac_objext conftest$ac_exeext
11059 if { (ac_try="$ac_link"
11060 case "(($ac_try" in
11061   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11062   *) ac_try_echo=$ac_try;;
11063 esac
11064 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11065 $as_echo "$ac_try_echo") >&5
11066   (eval "$ac_link") 2>conftest.er1
11067   ac_status=$?
11068   grep -v '^ *+' conftest.er1 >conftest.err
11069   rm -f conftest.er1
11070   cat conftest.err >&5
11071   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11072   (exit $ac_status); } && {
11073          test -z "$ac_c_werror_flag" ||
11074          test ! -s conftest.err
11075        } && test -s conftest$ac_exeext && {
11076          test "$cross_compiling" = yes ||
11077          $as_test_x conftest$ac_exeext
11078        }; then
11079   ac_cv_lib_svld_dlopen=yes
11080 else
11081   $as_echo "$as_me: failed program was:" >&5
11082 sed 's/^/| /' conftest.$ac_ext >&5
11083
11084         ac_cv_lib_svld_dlopen=no
11085 fi
11086
11087 rm -rf conftest.dSYM
11088 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11089       conftest$ac_exeext conftest.$ac_ext
11090 LIBS=$ac_check_lib_save_LIBS
11091 fi
11092 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5
11093 $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
11094 if test "x$ac_cv_lib_svld_dlopen" = x""yes; then
11095   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
11096 else
11097   { $as_echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5
11098 $as_echo_n "checking for dld_link in -ldld... " >&6; }
11099 if test "${ac_cv_lib_dld_dld_link+set}" = set; then
11100   $as_echo_n "(cached) " >&6
11101 else
11102   ac_check_lib_save_LIBS=$LIBS
11103 LIBS="-ldld  $LIBS"
11104 cat >conftest.$ac_ext <<_ACEOF
11105 /* confdefs.h.  */
11106 _ACEOF
11107 cat confdefs.h >>conftest.$ac_ext
11108 cat >>conftest.$ac_ext <<_ACEOF
11109 /* end confdefs.h.  */
11110
11111 /* Override any GCC internal prototype to avoid an error.
11112    Use char because int might match the return type of a GCC
11113    builtin and then its argument prototype would still apply.  */
11114 #ifdef __cplusplus
11115 extern "C"
11116 #endif
11117 char dld_link ();
11118 int
11119 main ()
11120 {
11121 return dld_link ();
11122   ;
11123   return 0;
11124 }
11125 _ACEOF
11126 rm -f conftest.$ac_objext conftest$ac_exeext
11127 if { (ac_try="$ac_link"
11128 case "(($ac_try" in
11129   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11130   *) ac_try_echo=$ac_try;;
11131 esac
11132 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11133 $as_echo "$ac_try_echo") >&5
11134   (eval "$ac_link") 2>conftest.er1
11135   ac_status=$?
11136   grep -v '^ *+' conftest.er1 >conftest.err
11137   rm -f conftest.er1
11138   cat conftest.err >&5
11139   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11140   (exit $ac_status); } && {
11141          test -z "$ac_c_werror_flag" ||
11142          test ! -s conftest.err
11143        } && test -s conftest$ac_exeext && {
11144          test "$cross_compiling" = yes ||
11145          $as_test_x conftest$ac_exeext
11146        }; then
11147   ac_cv_lib_dld_dld_link=yes
11148 else
11149   $as_echo "$as_me: failed program was:" >&5
11150 sed 's/^/| /' conftest.$ac_ext >&5
11151
11152         ac_cv_lib_dld_dld_link=no
11153 fi
11154
11155 rm -rf conftest.dSYM
11156 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11157       conftest$ac_exeext conftest.$ac_ext
11158 LIBS=$ac_check_lib_save_LIBS
11159 fi
11160 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5
11161 $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
11162 if test "x$ac_cv_lib_dld_dld_link" = x""yes; then
11163   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
11164 fi
11165
11166
11167 fi
11168
11169
11170 fi
11171
11172
11173 fi
11174
11175
11176 fi
11177
11178
11179 fi
11180
11181     ;;
11182   esac
11183
11184   if test "x$lt_cv_dlopen" != xno; then
11185     enable_dlopen=yes
11186   else
11187     enable_dlopen=no
11188   fi
11189
11190   case $lt_cv_dlopen in
11191   dlopen)
11192     save_CPPFLAGS="$CPPFLAGS"
11193     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
11194
11195     save_LDFLAGS="$LDFLAGS"
11196     wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
11197
11198     save_LIBS="$LIBS"
11199     LIBS="$lt_cv_dlopen_libs $LIBS"
11200
11201     { $as_echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5
11202 $as_echo_n "checking whether a program can dlopen itself... " >&6; }
11203 if test "${lt_cv_dlopen_self+set}" = set; then
11204   $as_echo_n "(cached) " >&6
11205 else
11206           if test "$cross_compiling" = yes; then :
11207   lt_cv_dlopen_self=cross
11208 else
11209   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
11210   lt_status=$lt_dlunknown
11211   cat > conftest.$ac_ext <<_LT_EOF
11212 #line 11212 "configure"
11213 #include "confdefs.h"
11214
11215 #if HAVE_DLFCN_H
11216 #include <dlfcn.h>
11217 #endif
11218
11219 #include <stdio.h>
11220
11221 #ifdef RTLD_GLOBAL
11222 #  define LT_DLGLOBAL           RTLD_GLOBAL
11223 #else
11224 #  ifdef DL_GLOBAL
11225 #    define LT_DLGLOBAL         DL_GLOBAL
11226 #  else
11227 #    define LT_DLGLOBAL         0
11228 #  endif
11229 #endif
11230
11231 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
11232    find out it does not work in some platform. */
11233 #ifndef LT_DLLAZY_OR_NOW
11234 #  ifdef RTLD_LAZY
11235 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
11236 #  else
11237 #    ifdef DL_LAZY
11238 #      define LT_DLLAZY_OR_NOW          DL_LAZY
11239 #    else
11240 #      ifdef RTLD_NOW
11241 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
11242 #      else
11243 #        ifdef DL_NOW
11244 #          define LT_DLLAZY_OR_NOW      DL_NOW
11245 #        else
11246 #          define LT_DLLAZY_OR_NOW      0
11247 #        endif
11248 #      endif
11249 #    endif
11250 #  endif
11251 #endif
11252
11253 void fnord() { int i=42;}
11254 int main ()
11255 {
11256   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
11257   int status = $lt_dlunknown;
11258
11259   if (self)
11260     {
11261       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
11262       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
11263       /* dlclose (self); */
11264     }
11265   else
11266     puts (dlerror ());
11267
11268   return status;
11269 }
11270 _LT_EOF
11271   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11272   (eval $ac_link) 2>&5
11273   ac_status=$?
11274   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11275   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
11276     (./conftest; exit; ) >&5 2>/dev/null
11277     lt_status=$?
11278     case x$lt_status in
11279       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
11280       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
11281       x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
11282     esac
11283   else :
11284     # compilation failed
11285     lt_cv_dlopen_self=no
11286   fi
11287 fi
11288 rm -fr conftest*
11289
11290
11291 fi
11292 { $as_echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5
11293 $as_echo "$lt_cv_dlopen_self" >&6; }
11294
11295     if test "x$lt_cv_dlopen_self" = xyes; then
11296       wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
11297       { $as_echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5
11298 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
11299 if test "${lt_cv_dlopen_self_static+set}" = set; then
11300   $as_echo_n "(cached) " >&6
11301 else
11302           if test "$cross_compiling" = yes; then :
11303   lt_cv_dlopen_self_static=cross
11304 else
11305   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
11306   lt_status=$lt_dlunknown
11307   cat > conftest.$ac_ext <<_LT_EOF
11308 #line 11308 "configure"
11309 #include "confdefs.h"
11310
11311 #if HAVE_DLFCN_H
11312 #include <dlfcn.h>
11313 #endif
11314
11315 #include <stdio.h>
11316
11317 #ifdef RTLD_GLOBAL
11318 #  define LT_DLGLOBAL           RTLD_GLOBAL
11319 #else
11320 #  ifdef DL_GLOBAL
11321 #    define LT_DLGLOBAL         DL_GLOBAL
11322 #  else
11323 #    define LT_DLGLOBAL         0
11324 #  endif
11325 #endif
11326
11327 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
11328    find out it does not work in some platform. */
11329 #ifndef LT_DLLAZY_OR_NOW
11330 #  ifdef RTLD_LAZY
11331 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
11332 #  else
11333 #    ifdef DL_LAZY
11334 #      define LT_DLLAZY_OR_NOW          DL_LAZY
11335 #    else
11336 #      ifdef RTLD_NOW
11337 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
11338 #      else
11339 #        ifdef DL_NOW
11340 #          define LT_DLLAZY_OR_NOW      DL_NOW
11341 #        else
11342 #          define LT_DLLAZY_OR_NOW      0
11343 #        endif
11344 #      endif
11345 #    endif
11346 #  endif
11347 #endif
11348
11349 void fnord() { int i=42;}
11350 int main ()
11351 {
11352   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
11353   int status = $lt_dlunknown;
11354
11355   if (self)
11356     {
11357       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
11358       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
11359       /* dlclose (self); */
11360     }
11361   else
11362     puts (dlerror ());
11363
11364   return status;
11365 }
11366 _LT_EOF
11367   if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11368   (eval $ac_link) 2>&5
11369   ac_status=$?
11370   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11371   (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then
11372     (./conftest; exit; ) >&5 2>/dev/null
11373     lt_status=$?
11374     case x$lt_status in
11375       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
11376       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
11377       x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
11378     esac
11379   else :
11380     # compilation failed
11381     lt_cv_dlopen_self_static=no
11382   fi
11383 fi
11384 rm -fr conftest*
11385
11386
11387 fi
11388 { $as_echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5
11389 $as_echo "$lt_cv_dlopen_self_static" >&6; }
11390     fi
11391
11392     CPPFLAGS="$save_CPPFLAGS"
11393     LDFLAGS="$save_LDFLAGS"
11394     LIBS="$save_LIBS"
11395     ;;
11396   esac
11397
11398   case $lt_cv_dlopen_self in
11399   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
11400   *) enable_dlopen_self=unknown ;;
11401   esac
11402
11403   case $lt_cv_dlopen_self_static in
11404   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
11405   *) enable_dlopen_self_static=unknown ;;
11406   esac
11407 fi
11408
11409
11410
11411
11412
11413
11414
11415
11416
11417
11418
11419
11420
11421
11422
11423
11424
11425 striplib=
11426 old_striplib=
11427 { $as_echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5
11428 $as_echo_n "checking whether stripping libraries is possible... " >&6; }
11429 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
11430   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
11431   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
11432   { $as_echo "$as_me:$LINENO: result: yes" >&5
11433 $as_echo "yes" >&6; }
11434 else
11435 # FIXME - insert some real tests, host_os isn't really good enough
11436   case $host_os in
11437   darwin*)
11438     if test -n "$STRIP" ; then
11439       striplib="$STRIP -x"
11440       old_striplib="$STRIP -S"
11441       { $as_echo "$as_me:$LINENO: result: yes" >&5
11442 $as_echo "yes" >&6; }
11443     else
11444       { $as_echo "$as_me:$LINENO: result: no" >&5
11445 $as_echo "no" >&6; }
11446     fi
11447     ;;
11448   *)
11449     { $as_echo "$as_me:$LINENO: result: no" >&5
11450 $as_echo "no" >&6; }
11451     ;;
11452   esac
11453 fi
11454
11455
11456
11457
11458
11459
11460
11461
11462
11463
11464
11465
11466   # Report which library types will actually be built
11467   { $as_echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5
11468 $as_echo_n "checking if libtool supports shared libraries... " >&6; }
11469   { $as_echo "$as_me:$LINENO: result: $can_build_shared" >&5
11470 $as_echo "$can_build_shared" >&6; }
11471
11472   { $as_echo "$as_me:$LINENO: checking whether to build shared libraries" >&5
11473 $as_echo_n "checking whether to build shared libraries... " >&6; }
11474   test "$can_build_shared" = "no" && enable_shared=no
11475
11476   # On AIX, shared libraries and static libraries use the same namespace, and
11477   # are all built from PIC.
11478   case $host_os in
11479   aix3*)
11480     test "$enable_shared" = yes && enable_static=no
11481     if test -n "$RANLIB"; then
11482       archive_cmds="$archive_cmds~\$RANLIB \$lib"
11483       postinstall_cmds='$RANLIB $lib'
11484     fi
11485     ;;
11486
11487   aix[4-9]*)
11488     if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
11489       test "$enable_shared" = yes && enable_static=no
11490     fi
11491     ;;
11492   esac
11493   { $as_echo "$as_me:$LINENO: result: $enable_shared" >&5
11494 $as_echo "$enable_shared" >&6; }
11495
11496   { $as_echo "$as_me:$LINENO: checking whether to build static libraries" >&5
11497 $as_echo_n "checking whether to build static libraries... " >&6; }
11498   # Make sure either enable_shared or enable_static is yes.
11499   test "$enable_shared" = yes || enable_static=yes
11500   { $as_echo "$as_me:$LINENO: result: $enable_static" >&5
11501 $as_echo "$enable_static" >&6; }
11502
11503
11504
11505
11506 fi
11507 ac_ext=c
11508 ac_cpp='$CPP $CPPFLAGS'
11509 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11510 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11511 ac_compiler_gnu=$ac_cv_c_compiler_gnu
11512
11513 CC="$lt_save_CC"
11514
11515
11516
11517
11518
11519
11520
11521
11522
11523
11524
11525
11526
11527         ac_config_commands="$ac_config_commands libtool"
11528
11529
11530
11531
11532 # Only expand once:
11533
11534
11535 # By default we simply use the C compiler to build assembly code.
11536
11537 test "${CCAS+set}" = set || CCAS=$CC
11538 test "${CCASFLAGS+set}" = set || CCASFLAGS=$CFLAGS
11539
11540
11541
11542 depcc="$CCAS"   am_compiler_list=
11543
11544 { $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
11545 $as_echo_n "checking dependency style of $depcc... " >&6; }
11546 if test "${am_cv_CCAS_dependencies_compiler_type+set}" = set; then
11547   $as_echo_n "(cached) " >&6
11548 else
11549   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
11550   # We make a subdir and do the tests there.  Otherwise we can end up
11551   # making bogus files that we don't know about and never remove.  For
11552   # instance it was reported that on HP-UX the gcc test will end up
11553   # making a dummy file named `D' -- because `-MD' means `put the output
11554   # in D'.
11555   mkdir conftest.dir
11556   # Copy depcomp to subdir because otherwise we won't find it if we're
11557   # using a relative directory.
11558   cp "$am_depcomp" conftest.dir
11559   cd conftest.dir
11560   # We will build objects and dependencies in a subdirectory because
11561   # it helps to detect inapplicable dependency modes.  For instance
11562   # both Tru64's cc and ICC support -MD to output dependencies as a
11563   # side effect of compilation, but ICC will put the dependencies in
11564   # the current directory while Tru64 will put them in the object
11565   # directory.
11566   mkdir sub
11567
11568   am_cv_CCAS_dependencies_compiler_type=none
11569   if test "$am_compiler_list" = ""; then
11570      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
11571   fi
11572   am__universal=false
11573
11574
11575   for depmode in $am_compiler_list; do
11576     # Setup a source with many dependencies, because some compilers
11577     # like to wrap large dependency lists on column 80 (with \), and
11578     # we should not choose a depcomp mode which is confused by this.
11579     #
11580     # We need to recreate these files for each test, as the compiler may
11581     # overwrite some of them when testing with obscure command lines.
11582     # This happens at least with the AIX C compiler.
11583     : > sub/conftest.c
11584     for i in 1 2 3 4 5 6; do
11585       echo '#include "conftst'$i'.h"' >> sub/conftest.c
11586       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
11587       # Solaris 8's {/usr,}/bin/sh.
11588       touch sub/conftst$i.h
11589     done
11590     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
11591
11592     # We check with `-c' and `-o' for the sake of the "dashmstdout"
11593     # mode.  It turns out that the SunPro C++ compiler does not properly
11594     # handle `-M -o', and we need to detect this.  Also, some Intel
11595     # versions had trouble with output in subdirs
11596     am__obj=sub/conftest.${OBJEXT-o}
11597     am__minus_obj="-o $am__obj"
11598     case $depmode in
11599     gcc)
11600       # This depmode causes a compiler race in universal mode.
11601       test "$am__universal" = false || continue
11602       ;;
11603     nosideeffect)
11604       # after this tag, mechanisms are not by side-effect, so they'll
11605       # only be used when explicitly requested
11606       if test "x$enable_dependency_tracking" = xyes; then
11607         continue
11608       else
11609         break
11610       fi
11611       ;;
11612     msvisualcpp | msvcmsys)
11613       # This compiler won't grok `-c -o', but also, the minuso test has
11614       # not run yet.  These depmodes are late enough in the game, and
11615       # so weak that their functioning should not be impacted.
11616       am__obj=conftest.${OBJEXT-o}
11617       am__minus_obj=
11618       ;;
11619     none) break ;;
11620     esac
11621     if depmode=$depmode \
11622        source=sub/conftest.c object=$am__obj \
11623        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
11624        $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
11625          >/dev/null 2>conftest.err &&
11626        grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
11627        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
11628        grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
11629        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
11630       # icc doesn't choke on unknown options, it will just issue warnings
11631       # or remarks (even with -Werror).  So we grep stderr for any message
11632       # that says an option was ignored or not supported.
11633       # When given -MP, icc 7.0 and 7.1 complain thusly:
11634       #   icc: Command line warning: ignoring option '-M'; no argument required
11635       # The diagnosis changed in icc 8.0:
11636       #   icc: Command line remark: option '-MP' not supported
11637       if (grep 'ignoring option' conftest.err ||
11638           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
11639         am_cv_CCAS_dependencies_compiler_type=$depmode
11640         break
11641       fi
11642     fi
11643   done
11644
11645   cd ..
11646   rm -rf conftest.dir
11647 else
11648   am_cv_CCAS_dependencies_compiler_type=none
11649 fi
11650
11651 fi
11652 { $as_echo "$as_me:$LINENO: result: $am_cv_CCAS_dependencies_compiler_type" >&5
11653 $as_echo "$am_cv_CCAS_dependencies_compiler_type" >&6; }
11654 CCASDEPMODE=depmode=$am_cv_CCAS_dependencies_compiler_type
11655
11656  if
11657   test "x$enable_dependency_tracking" != xno \
11658   && test "$am_cv_CCAS_dependencies_compiler_type" = gcc3; then
11659   am__fastdepCCAS_TRUE=
11660   am__fastdepCCAS_FALSE='#'
11661 else
11662   am__fastdepCCAS_TRUE='#'
11663   am__fastdepCCAS_FALSE=
11664 fi
11665
11666
11667
11668
11669         { $as_echo "$as_me:$LINENO: checking zfs author" >&5
11670 $as_echo_n "checking zfs author... " >&6; }
11671         { $as_echo "$as_me:$LINENO: result: $ZFS_META_AUTHOR" >&5
11672 $as_echo "$ZFS_META_AUTHOR" >&6; }
11673
11674         { $as_echo "$as_me:$LINENO: checking zfs license" >&5
11675 $as_echo_n "checking zfs license... " >&6; }
11676         { $as_echo "$as_me:$LINENO: result: $ZFS_META_LICENSE" >&5
11677 $as_echo "$ZFS_META_LICENSE" >&6; }
11678
11679
11680
11681         { $as_echo "$as_me:$LINENO: checking linux distribution" >&5
11682 $as_echo_n "checking linux distribution... " >&6; }
11683         if test -f /etc/toss-release ; then
11684                 VENDOR=toss ;
11685         elif test -f /etc/fedora-release ; then
11686                 VENDOR=fedora ;
11687         elif test -f /etc/redhat-release ; then
11688                 VENDOR=redhat ;
11689         elif test -f /etc/gentoo-release ; then
11690                 VENDOR=gentoo ;
11691         elif test -f /etc/arch-release ; then
11692                 VENDOR=arch ;
11693         elif test -f /etc/SuSE-release ; then
11694                 VENDOR=sles ;
11695         elif test -f /etc/slackware-version ; then
11696                 VENDOR=slackware ;
11697         elif test -f /etc/lunar.release ; then
11698                 VENDOR=lunar ;
11699         elif test -f /etc/lsb-release ; then
11700                 VENDOR=ubuntu ;
11701         elif test -f /etc/debian_version ; then
11702                 VENDOR=debian ;
11703         else
11704                 VENDOR= ;
11705         fi
11706         { $as_echo "$as_me:$LINENO: result: $VENDOR" >&5
11707 $as_echo "$VENDOR" >&6; }
11708
11709
11710         { $as_echo "$as_me:$LINENO: checking default package type" >&5
11711 $as_echo_n "checking default package type... " >&6; }
11712         case "$VENDOR" in
11713                 toss)       DEFAULT_PACKAGE=rpm  ;;
11714                 redhat)     DEFAULT_PACKAGE=rpm  ;;
11715                 fedora)     DEFAULT_PACKAGE=rpm  ;;
11716                 gentoo)     DEFAULT_PACKAGE=tgz  ;;
11717                 arch)       DEFAULT_PACKAGE=arch ;;
11718                 sles)       DEFAULT_PACKAGE=rpm  ;;
11719                 slackware)  DEFAULT_PACKAGE=tgz  ;;
11720                 lunar)      DEFAULT_PACKAGE=tgz  ;;
11721                 ubuntu)     DEFAULT_PACKAGE=deb  ;;
11722                 debian)     DEFAULT_PACKAGE=deb  ;;
11723                 *)          DEFAULT_PACKAGE=rpm  ;;
11724         esac
11725
11726         { $as_echo "$as_me:$LINENO: result: $DEFAULT_PACKAGE" >&5
11727 $as_echo "$DEFAULT_PACKAGE" >&6; }
11728
11729
11730         { $as_echo "$as_me:$LINENO: checking default init directory" >&5
11731 $as_echo_n "checking default init directory... " >&6; }
11732         case "$VENDOR" in
11733                 arch)       DEFAULT_INIT_DIR=$sysconfdir/rc.d ;;
11734                 *)          DEFAULT_INIT_DIR=$sysconfdir/init.d ;;
11735         esac
11736
11737         { $as_echo "$as_me:$LINENO: result: $DEFAULT_INIT_DIR" >&5
11738 $as_echo "$DEFAULT_INIT_DIR" >&6; }
11739
11740
11741         { $as_echo "$as_me:$LINENO: checking default init script type" >&5
11742 $as_echo_n "checking default init script type... " >&6; }
11743         case "$VENDOR" in
11744                 toss)       DEFAULT_INIT_SCRIPT=redhat ;;
11745                 redhat)     DEFAULT_INIT_SCRIPT=redhat ;;
11746                 fedora)     DEFAULT_INIT_SCRIPT=fedora ;;
11747                 gentoo)     DEFAULT_INIT_SCRIPT=gentoo ;;
11748                 arch)       DEFAULT_INIT_SCRIPT=arch   ;;
11749                 sles)       DEFAULT_INIT_SCRIPT=lsb    ;;
11750                 slackware)  DEFAULT_INIT_SCRIPT=lsb    ;;
11751                 lunar)      DEFAULT_INIT_SCRIPT=lunar  ;;
11752                 ubuntu)     DEFAULT_INIT_SCRIPT=lsb    ;;
11753                 debian)     DEFAULT_INIT_SCRIPT=lsb    ;;
11754                 *)          DEFAULT_INIT_SCRIPT=lsb    ;;
11755         esac
11756
11757         { $as_echo "$as_me:$LINENO: result: $DEFAULT_INIT_SCRIPT" >&5
11758 $as_echo "$DEFAULT_INIT_SCRIPT" >&6; }
11759
11760
11761
11762         RPM=rpm
11763         RPMBUILD=rpmbuild
11764
11765         { $as_echo "$as_me:$LINENO: checking whether $RPM is available" >&5
11766 $as_echo_n "checking whether $RPM is available... " >&6; }
11767         if tmp=$($RPM --version 2>/dev/null); then
11768
11769                 RPM_VERSION=$(echo $tmp | $AWK '/RPM/ { print $3 }')
11770                 HAVE_RPM=yes
11771                 { $as_echo "$as_me:$LINENO: result: $HAVE_RPM ($RPM_VERSION)" >&5
11772 $as_echo "$HAVE_RPM ($RPM_VERSION)" >&6; }
11773
11774 else
11775
11776                 HAVE_RPM=no
11777                 { $as_echo "$as_me:$LINENO: result: $HAVE_RPM" >&5
11778 $as_echo "$HAVE_RPM" >&6; }
11779
11780 fi
11781
11782
11783         { $as_echo "$as_me:$LINENO: checking whether $RPMBUILD is available" >&5
11784 $as_echo_n "checking whether $RPMBUILD is available... " >&6; }
11785         if tmp=$($RPMBUILD --version 2>/dev/null); then
11786
11787                 RPMBUILD_VERSION=$(echo $tmp | $AWK '/RPM/ { print $3 }')
11788                 HAVE_RPMBUILD=yes
11789                 { $as_echo "$as_me:$LINENO: result: $HAVE_RPMBUILD ($RPMBUILD_VERSION)" >&5
11790 $as_echo "$HAVE_RPMBUILD ($RPMBUILD_VERSION)" >&6; }
11791
11792 else
11793
11794                 HAVE_RPMBUILD=no
11795                 { $as_echo "$as_me:$LINENO: result: $HAVE_RPMBUILD" >&5
11796 $as_echo "$HAVE_RPMBUILD" >&6; }
11797
11798 fi
11799
11800
11801
11802
11803
11804
11805
11806
11807
11808
11809
11810         DPKG=dpkg
11811         DPKGBUILD=dpkg-buildpackage
11812
11813         { $as_echo "$as_me:$LINENO: checking whether $DPKG is available" >&5
11814 $as_echo_n "checking whether $DPKG is available... " >&6; }
11815         if tmp=$($DPKG --version 2>/dev/null); then
11816
11817                 DPKG_VERSION=$(echo $tmp | $AWK '/Debian/ { print $7 }')
11818                 HAVE_DPKG=yes
11819                 { $as_echo "$as_me:$LINENO: result: $HAVE_DPKG ($DPKG_VERSION)" >&5
11820 $as_echo "$HAVE_DPKG ($DPKG_VERSION)" >&6; }
11821
11822 else
11823
11824                 HAVE_DPKG=no
11825                 { $as_echo "$as_me:$LINENO: result: $HAVE_DPKG" >&5
11826 $as_echo "$HAVE_DPKG" >&6; }
11827
11828 fi
11829
11830
11831         { $as_echo "$as_me:$LINENO: checking whether $DPKGBUILD is available" >&5
11832 $as_echo_n "checking whether $DPKGBUILD is available... " >&6; }
11833         if tmp=$($DPKGBUILD --version 2>/dev/null); then
11834
11835                 DPKGBUILD_VERSION=$(echo $tmp | \
11836                     $AWK '/Debian/ { print $4 }' | cut -f-4 -d'.')
11837                 HAVE_DPKGBUILD=yes
11838                 { $as_echo "$as_me:$LINENO: result: $HAVE_DPKGBUILD ($DPKGBUILD_VERSION)" >&5
11839 $as_echo "$HAVE_DPKGBUILD ($DPKGBUILD_VERSION)" >&6; }
11840
11841 else
11842
11843                 HAVE_DPKGBUILD=no
11844                 { $as_echo "$as_me:$LINENO: result: $HAVE_DPKGBUILD" >&5
11845 $as_echo "$HAVE_DPKGBUILD" >&6; }
11846
11847 fi
11848
11849
11850
11851
11852
11853
11854
11855
11856
11857
11858
11859         ALIEN=alien
11860
11861         { $as_echo "$as_me:$LINENO: checking whether $ALIEN is available" >&5
11862 $as_echo_n "checking whether $ALIEN is available... " >&6; }
11863         if tmp=$($ALIEN --version 2>/dev/null); then
11864
11865                 ALIEN_VERSION=$(echo $tmp | $AWK '{ print $3 }')
11866                 HAVE_ALIEN=yes
11867                 { $as_echo "$as_me:$LINENO: result: $HAVE_ALIEN ($ALIEN_VERSION)" >&5
11868 $as_echo "$HAVE_ALIEN ($ALIEN_VERSION)" >&6; }
11869
11870 else
11871
11872                 HAVE_ALIEN=no
11873                 { $as_echo "$as_me:$LINENO: result: $HAVE_ALIEN" >&5
11874 $as_echo "$HAVE_ALIEN" >&6; }
11875
11876 fi
11877
11878
11879
11880
11881
11882
11883
11884         if test "$VENDOR" = "arch"; then
11885
11886         PACMAN=pacman
11887         MAKEPKG=makepkg
11888
11889         { $as_echo "$as_me:$LINENO: checking whether $PACMAN is available" >&5
11890 $as_echo_n "checking whether $PACMAN is available... " >&6; }
11891         tmp=$($PACMAN --version 2>/dev/null)
11892         if test -n "$tmp"; then
11893
11894                 PACMAN_VERSION=$(echo $tmp |
11895                                  $AWK '/Pacman/ { print $3 }' |
11896                                  $SED 's/^v//')
11897                 HAVE_PACMAN=yes
11898                 { $as_echo "$as_me:$LINENO: result: $HAVE_PACMAN ($PACMAN_VERSION)" >&5
11899 $as_echo "$HAVE_PACMAN ($PACMAN_VERSION)" >&6; }
11900
11901 else
11902
11903                 HAVE_PACMAN=no
11904                 { $as_echo "$as_me:$LINENO: result: $HAVE_PACMAN" >&5
11905 $as_echo "$HAVE_PACMAN" >&6; }
11906
11907 fi
11908
11909
11910         { $as_echo "$as_me:$LINENO: checking whether $MAKEPKG is available" >&5
11911 $as_echo_n "checking whether $MAKEPKG is available... " >&6; }
11912         tmp=$($MAKEPKG --version 2>/dev/null)
11913         if test -n "$tmp"; then
11914
11915                 MAKEPKG_VERSION=$(echo $tmp | $AWK '/makepkg/ { print $3 }')
11916                 HAVE_MAKEPKG=yes
11917                 { $as_echo "$as_me:$LINENO: result: $HAVE_MAKEPKG ($MAKEPKG_VERSION)" >&5
11918 $as_echo "$HAVE_MAKEPKG ($MAKEPKG_VERSION)" >&6; }
11919
11920 else
11921
11922                 HAVE_MAKEPKG=no
11923                 { $as_echo "$as_me:$LINENO: result: $HAVE_MAKEPKG" >&5
11924 $as_echo "$HAVE_MAKEPKG" >&6; }
11925
11926 fi
11927
11928
11929
11930
11931
11932
11933
11934
11935
11936
11937 fi
11938
11939
11940
11941         TARGET_ASM_DIR=asm-generic
11942
11943
11944         ZFS_CONFIG=all
11945
11946 # Check whether --with-config was given.
11947 if test "${with_config+set}" = set; then
11948   withval=$with_config; ZFS_CONFIG="$withval"
11949 fi
11950
11951         # Check whether --enable-linux-builtin was given.
11952 if test "${enable_linux_builtin+set}" = set; then
11953   enableval=$enable_linux_builtin;
11954 else
11955   enable_linux_builtin=no
11956 fi
11957
11958
11959         { $as_echo "$as_me:$LINENO: checking zfs config" >&5
11960 $as_echo_n "checking zfs config... " >&6; }
11961         { $as_echo "$as_me:$LINENO: result: $ZFS_CONFIG" >&5
11962 $as_echo "$ZFS_CONFIG" >&6; };
11963
11964
11965
11966
11967         { $as_echo "$as_me:$LINENO: checking for -Wno-unused-but-set-variable support" >&5
11968 $as_echo_n "checking for -Wno-unused-but-set-variable support... " >&6; }
11969
11970         saved_flags="$CFLAGS"
11971         CFLAGS="$CFLAGS -Wunused-but-set-variable"
11972
11973         if test "$cross_compiling" = yes; then
11974   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
11975 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11976 { { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling
11977 See \`config.log' for more details." >&5
11978 $as_echo "$as_me: error: cannot run test program while cross compiling
11979 See \`config.log' for more details." >&2;}
11980    { (exit 1); exit 1; }; }; }
11981 else
11982   cat >conftest.$ac_ext <<_ACEOF
11983 /* confdefs.h.  */
11984 _ACEOF
11985 cat confdefs.h >>conftest.$ac_ext
11986 cat >>conftest.$ac_ext <<_ACEOF
11987 /* end confdefs.h.  */
11988
11989 int
11990 main ()
11991 {
11992
11993   ;
11994   return 0;
11995 }
11996 _ACEOF
11997 rm -f conftest$ac_exeext
11998 if { (ac_try="$ac_link"
11999 case "(($ac_try" in
12000   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12001   *) ac_try_echo=$ac_try;;
12002 esac
12003 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12004 $as_echo "$ac_try_echo") >&5
12005   (eval "$ac_link") 2>&5
12006   ac_status=$?
12007   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12008   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12009   { (case "(($ac_try" in
12010   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12011   *) ac_try_echo=$ac_try;;
12012 esac
12013 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12014 $as_echo "$ac_try_echo") >&5
12015   (eval "$ac_try") 2>&5
12016   ac_status=$?
12017   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12018   (exit $ac_status); }; }; then
12019
12020                 NO_UNUSED_BUT_SET_VARIABLE=-Wno-unused-but-set-variable
12021                 { $as_echo "$as_me:$LINENO: result: yes" >&5
12022 $as_echo "yes" >&6; }
12023
12024 else
12025   $as_echo "$as_me: program exited with status $ac_status" >&5
12026 $as_echo "$as_me: failed program was:" >&5
12027 sed 's/^/| /' conftest.$ac_ext >&5
12028
12029 ( exit $ac_status )
12030
12031                 NO_UNUSED_BUT_SET_VARIABLE=
12032                 { $as_echo "$as_me:$LINENO: result: no" >&5
12033 $as_echo "no" >&6; }
12034
12035 fi
12036 rm -rf conftest.dSYM
12037 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12038 fi
12039
12040
12041
12042         CFLAGS="$saved_flags"
12043
12044
12045
12046
12047         case "$ZFS_CONFIG" in
12048                 kernel)
12049
12050
12051 # Check whether --with-linux was given.
12052 if test "${with_linux+set}" = set; then
12053   withval=$with_linux; kernelsrc="$withval"
12054 fi
12055
12056
12057
12058 # Check whether --with-linux-obj was given.
12059 if test "${with_linux_obj+set}" = set; then
12060   withval=$with_linux_obj; kernelbuild="$withval"
12061 fi
12062
12063
12064         { $as_echo "$as_me:$LINENO: checking kernel source directory" >&5
12065 $as_echo_n "checking kernel source directory... " >&6; }
12066         if test -z "$kernelsrc"; then
12067
12068                 if test -e "/lib/modules/$(uname -r)/source"; then
12069
12070                         headersdir="/lib/modules/$(uname -r)/source"
12071                         sourcelink=$(readlink -f "$headersdir")
12072
12073 elif test -e "/lib/modules/$(uname -r)/build"; then
12074
12075                         headersdir="/lib/modules/$(uname -r)/build"
12076                         sourcelink=$(readlink -f "$headersdir")
12077
12078 else
12079
12080                         sourcelink=$(ls -1d /usr/src/kernels/* \
12081                                      /usr/src/linux-* \
12082                                      2>/dev/null | grep -v obj | tail -1)
12083
12084 fi
12085
12086
12087                 if test -n "$sourcelink" && test -e ${sourcelink}; then
12088
12089                         kernelsrc=`readlink -f ${sourcelink}`
12090
12091 else
12092
12093                         { $as_echo "$as_me:$LINENO: result: Not found" >&5
12094 $as_echo "Not found" >&6; }
12095                         { { $as_echo "$as_me:$LINENO: error:
12096         *** Please make sure the kernel devel package for your distribution
12097         *** is installed then try again.  If that fails you can specify the
12098         *** location of the kernel source with the '--with-linux=PATH' option." >&5
12099 $as_echo "$as_me: error:
12100         *** Please make sure the kernel devel package for your distribution
12101         *** is installed then try again.  If that fails you can specify the
12102         *** location of the kernel source with the '--with-linux=PATH' option." >&2;}
12103    { (exit 1); exit 1; }; }
12104
12105 fi
12106
12107
12108 else
12109
12110                 if test "$kernelsrc" = "NONE"; then
12111
12112                         kernsrcver=NONE
12113
12114 fi
12115
12116
12117 fi
12118
12119
12120         { $as_echo "$as_me:$LINENO: result: $kernelsrc" >&5
12121 $as_echo "$kernelsrc" >&6; }
12122         { $as_echo "$as_me:$LINENO: checking kernel build directory" >&5
12123 $as_echo_n "checking kernel build directory... " >&6; }
12124         if test -z "$kernelbuild"; then
12125
12126                 if test -e "/lib/modules/$(uname -r)/build"; then
12127
12128                         kernelbuild=`readlink -f /lib/modules/$(uname -r)/build`
12129
12130 elif test -d ${kernelsrc}-obj/${target_cpu}/${target_cpu}; then
12131
12132                         kernelbuild=${kernelsrc}-obj/${target_cpu}/${target_cpu}
12133
12134 elif test -d ${kernelsrc}-obj/${target_cpu}/default; then
12135
12136                         kernelbuild=${kernelsrc}-obj/${target_cpu}/default
12137
12138 elif test -d `dirname ${kernelsrc}`/build-${target_cpu}; then
12139
12140                         kernelbuild=`dirname ${kernelsrc}`/build-${target_cpu}
12141
12142 else
12143
12144                         kernelbuild=${kernelsrc}
12145
12146 fi
12147
12148
12149 fi
12150
12151         { $as_echo "$as_me:$LINENO: result: $kernelbuild" >&5
12152 $as_echo "$kernelbuild" >&6; }
12153
12154         { $as_echo "$as_me:$LINENO: checking kernel source version" >&5
12155 $as_echo_n "checking kernel source version... " >&6; }
12156         utsrelease1=$kernelbuild/include/linux/version.h
12157         utsrelease2=$kernelbuild/include/linux/utsrelease.h
12158         utsrelease3=$kernelbuild/include/generated/utsrelease.h
12159         if test -r $utsrelease1 && fgrep -q UTS_RELEASE $utsrelease1; then
12160
12161                 utsrelease=linux/version.h
12162
12163 elif test -r $utsrelease2 && fgrep -q UTS_RELEASE $utsrelease2; then
12164
12165                 utsrelease=linux/utsrelease.h
12166
12167 elif test -r $utsrelease3 && fgrep -q UTS_RELEASE $utsrelease3; then
12168
12169                 utsrelease=generated/utsrelease.h
12170
12171 fi
12172
12173
12174         if test "$utsrelease"; then
12175
12176                 kernsrcver=`(echo "#include <$utsrelease>";
12177                              echo "kernsrcver=UTS_RELEASE") |
12178                              cpp -I $kernelbuild/include |
12179                              grep "^kernsrcver=" | cut -d \" -f 2`
12180
12181                 if test -z "$kernsrcver"; then
12182
12183                         { $as_echo "$as_me:$LINENO: result: Not found" >&5
12184 $as_echo "Not found" >&6; }
12185                         { { $as_echo "$as_me:$LINENO: error: *** Cannot determine kernel version." >&5
12186 $as_echo "$as_me: error: *** Cannot determine kernel version." >&2;}
12187    { (exit 1); exit 1; }; }
12188
12189 fi
12190
12191
12192 else
12193
12194                 { $as_echo "$as_me:$LINENO: result: Not found" >&5
12195 $as_echo "Not found" >&6; }
12196                 if test "x$enable_linux_builtin" != xyes; then
12197                         { { $as_echo "$as_me:$LINENO: error: *** Cannot find UTS_RELEASE definition." >&5
12198 $as_echo "$as_me: error: *** Cannot find UTS_RELEASE definition." >&2;}
12199    { (exit 1); exit 1; }; }
12200                 else
12201                         { { $as_echo "$as_me:$LINENO: error:
12202         *** Cannot find UTS_RELEASE definition.
12203         *** Please run 'make prepare' inside the kernel source tree." >&5
12204 $as_echo "$as_me: error:
12205         *** Cannot find UTS_RELEASE definition.
12206         *** Please run 'make prepare' inside the kernel source tree." >&2;}
12207    { (exit 1); exit 1; }; }
12208                 fi
12209
12210 fi
12211
12212
12213         { $as_echo "$as_me:$LINENO: result: $kernsrcver" >&5
12214 $as_echo "$kernsrcver" >&6; }
12215
12216         LINUX=${kernelsrc}
12217         LINUX_OBJ=${kernelbuild}
12218         LINUX_VERSION=${kernsrcver}
12219
12220
12221
12222
12223
12224
12225         modpost=$LINUX/scripts/Makefile.modpost
12226         { $as_echo "$as_me:$LINENO: checking kernel file name for module symbols" >&5
12227 $as_echo_n "checking kernel file name for module symbols... " >&6; }
12228         if test "x$enable_linux_builtin" != xyes -a -f "$modpost"; then
12229
12230                 if grep -q Modules.symvers $modpost; then
12231
12232                         LINUX_SYMBOLS=Modules.symvers
12233
12234 else
12235
12236                         LINUX_SYMBOLS=Module.symvers
12237
12238 fi
12239
12240
12241                 if test ! -f "$LINUX_OBJ/$LINUX_SYMBOLS"; then
12242
12243                         { { $as_echo "$as_me:$LINENO: error:
12244         *** Please make sure the kernel devel package for your distribution
12245         *** is installed.  If your building with a custom kernel make sure the
12246         *** kernel is configured, built, and the '--with-linux=PATH' configure
12247         *** option refers to the location of the kernel source." >&5
12248 $as_echo "$as_me: error:
12249         *** Please make sure the kernel devel package for your distribution
12250         *** is installed.  If your building with a custom kernel make sure the
12251         *** kernel is configured, built, and the '--with-linux=PATH' configure
12252         *** option refers to the location of the kernel source." >&2;}
12253    { (exit 1); exit 1; }; }
12254
12255 fi
12256
12257
12258 else
12259
12260                 LINUX_SYMBOLS=NONE
12261
12262 fi
12263
12264         { $as_echo "$as_me:$LINENO: result: $LINUX_SYMBOLS" >&5
12265 $as_echo "$LINUX_SYMBOLS" >&6; }
12266
12267
12268
12269
12270
12271 # Check whether --with-spl was given.
12272 if test "${with_spl+set}" = set; then
12273   withval=$with_spl; splsrc="$withval"
12274 fi
12275
12276
12277
12278 # Check whether --with-spl-obj was given.
12279 if test "${with_spl_obj+set}" = set; then
12280   withval=$with_spl_obj; splbuild="$withval"
12281 fi
12282
12283
12284
12285         { $as_echo "$as_me:$LINENO: checking spl source directory" >&5
12286 $as_echo_n "checking spl source directory... " >&6; }
12287         if test -z "$splsrc"; then
12288
12289                 sourcelink=`ls -1d /usr/src/spl-*/${LINUX_VERSION} \
12290                             2>/dev/null | tail -1`
12291
12292                 if test -z "$sourcelink" || test ! -e $sourcelink; then
12293
12294                         sourcelink=../spl
12295
12296 fi
12297
12298
12299                 if test -e $sourcelink; then
12300
12301                         splsrc=`readlink -f ${sourcelink}`
12302
12303 else
12304
12305                         { $as_echo "$as_me:$LINENO: result: Not found" >&5
12306 $as_echo "Not found" >&6; }
12307                         { { $as_echo "$as_me:$LINENO: error:
12308         *** Please make sure the spl devel package for your distribution
12309         *** is installed then try again.  If that fails you can specify the
12310         *** location of the spl source with the '--with-spl=PATH' option." >&5
12311 $as_echo "$as_me: error:
12312         *** Please make sure the spl devel package for your distribution
12313         *** is installed then try again.  If that fails you can specify the
12314         *** location of the spl source with the '--with-spl=PATH' option." >&2;}
12315    { (exit 1); exit 1; }; }
12316
12317 fi
12318
12319
12320 else
12321
12322                 if test "$splsrc" = "NONE"; then
12323
12324                         splbuild=NONE
12325                         splsrcver=NONE
12326
12327 fi
12328
12329
12330 fi
12331
12332
12333         { $as_echo "$as_me:$LINENO: result: $splsrc" >&5
12334 $as_echo "$splsrc" >&6; }
12335         { $as_echo "$as_me:$LINENO: checking spl build directory" >&5
12336 $as_echo_n "checking spl build directory... " >&6; }
12337         if test -z "$splbuild"; then
12338
12339                 splbuild=${splsrc}
12340
12341 fi
12342
12343         { $as_echo "$as_me:$LINENO: result: $splbuild" >&5
12344 $as_echo "$splbuild" >&6; }
12345
12346         { $as_echo "$as_me:$LINENO: checking spl source version" >&5
12347 $as_echo_n "checking spl source version... " >&6; }
12348         if test -r $splbuild/spl_config.h &&
12349                 fgrep -q SPL_META_VERSION $splbuild/spl_config.h; then
12350
12351
12352                 splsrcver=`(echo "#include <spl_config.h>";
12353                             echo "splsrcver=SPL_META_VERSION-SPL_META_RELEASE") |
12354                             cpp -I $splbuild |
12355                             grep "^splsrcver=" | tr -d \" | cut -d= -f2`
12356
12357 fi
12358
12359
12360         if test -z "$splsrcver"; then
12361
12362                 { $as_echo "$as_me:$LINENO: result: Not found" >&5
12363 $as_echo "Not found" >&6; }
12364                 { { $as_echo "$as_me:$LINENO: error:
12365         *** Cannot determine the version of the spl source.
12366         *** Please prepare the spl source before running this script" >&5
12367 $as_echo "$as_me: error:
12368         *** Cannot determine the version of the spl source.
12369         *** Please prepare the spl source before running this script" >&2;}
12370    { (exit 1); exit 1; }; }
12371
12372 fi
12373
12374
12375         { $as_echo "$as_me:$LINENO: result: $splsrcver" >&5
12376 $as_echo "$splsrcver" >&6; }
12377
12378         SPL=${splsrc}
12379         SPL_OBJ=${splbuild}
12380         SPL_VERSION=${splsrcver}
12381
12382
12383
12384
12385
12386
12387         { $as_echo "$as_me:$LINENO: checking spl file name for module symbols" >&5
12388 $as_echo_n "checking spl file name for module symbols... " >&6; }
12389         if test -r $SPL_OBJ/Module.symvers; then
12390
12391                 SPL_SYMBOLS=Module.symvers
12392
12393 elif test -r $SPL_OBJ/Modules.symvers; then
12394
12395                 SPL_SYMBOLS=Modules.symvers
12396
12397 elif test -r $SPL_OBJ/module/Module.symvers; then
12398
12399                 SPL_SYMBOLS=Module.symvers
12400
12401 elif test -r $SPL_OBJ/module/Modules.symvers; then
12402
12403                 SPL_SYMBOLS=Modules.symvers
12404
12405 else
12406
12407                 SPL_SYMBOLS=$LINUX_SYMBOLS
12408
12409 fi
12410
12411
12412         { $as_echo "$as_me:$LINENO: result: $SPL_SYMBOLS" >&5
12413 $as_echo "$SPL_SYMBOLS" >&6; }
12414
12415
12416
12417         { $as_echo "$as_me:$LINENO: checking whether modules can be built" >&5
12418 $as_echo_n "checking whether modules can be built... " >&6; }
12419
12420
12421 cat confdefs.h - <<_ACEOF >conftest.c
12422 /* confdefs.h.  */
12423 _ACEOF
12424 cat confdefs.h >>conftest.$ac_ext
12425 cat >>conftest.$ac_ext <<_ACEOF
12426 /* end confdefs.h.  */
12427
12428
12429 int
12430 main (void)
12431 {
12432
12433   ;
12434   return 0;
12435 }
12436
12437 _ACEOF
12438
12439
12440         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
12441         echo "obj-m := conftest.o" >build/Makefile
12442         modpost_flag=''
12443         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
12444         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
12445   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12446   (eval $ac_try) 2>&5
12447   ac_status=$?
12448   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12449   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
12450   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12451   (eval $ac_try) 2>&5
12452   ac_status=$?
12453   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12454   (exit $ac_status); }; }; then
12455
12456                 { $as_echo "$as_me:$LINENO: result: yes" >&5
12457 $as_echo "yes" >&6; }
12458
12459 else
12460   $as_echo "$as_me: failed program was:" >&5
12461 sed 's/^/| /' conftest.$ac_ext >&5
12462
12463                 { $as_echo "$as_me:$LINENO: result: no" >&5
12464 $as_echo "no" >&6; }
12465                 if test "x$enable_linux_builtin" != xyes; then
12466                         { { $as_echo "$as_me:$LINENO: error: *** Unable to build an empty module." >&5
12467 $as_echo "$as_me: error: *** Unable to build an empty module." >&2;}
12468    { (exit 1); exit 1; }; }
12469                 else
12470                         { { $as_echo "$as_me:$LINENO: error:
12471         *** Unable to build an empty module.
12472         *** Please run 'make scripts' inside the kernel source tree." >&5
12473 $as_echo "$as_me: error:
12474         *** Unable to build an empty module.
12475         *** Please run 'make scripts' inside the kernel source tree." >&2;}
12476    { (exit 1); exit 1; }; }
12477                 fi
12478
12479
12480
12481 fi
12482
12483         rm -Rf build
12484
12485
12486
12487
12488
12489         if test "$ZFS_META_LICENSE" = GPL; then
12490
12491
12492 cat >>confdefs.h <<\_ACEOF
12493 #define HAVE_GPL_ONLY_SYMBOLS 1
12494 _ACEOF
12495
12496
12497 fi
12498
12499
12500
12501
12502         { $as_echo "$as_me:$LINENO: checking whether Linux was built with CONFIG_PREEMPT" >&5
12503 $as_echo_n "checking whether Linux was built with CONFIG_PREEMPT... " >&6; }
12504
12505
12506 cat confdefs.h - <<_ACEOF >conftest.c
12507 /* confdefs.h.  */
12508 _ACEOF
12509 cat confdefs.h >>conftest.$ac_ext
12510 cat >>conftest.$ac_ext <<_ACEOF
12511 /* end confdefs.h.  */
12512
12513
12514                 #include <linux/module.h>
12515
12516 int
12517 main (void)
12518 {
12519
12520                 #ifndef CONFIG_PREEMPT
12521                 #error CONFIG_PREEMPT not #defined
12522                 #endif
12523
12524   ;
12525   return 0;
12526 }
12527
12528 _ACEOF
12529
12530
12531         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
12532         echo "obj-m := conftest.o" >build/Makefile
12533         modpost_flag=''
12534         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
12535         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
12536   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12537   (eval $ac_try) 2>&5
12538   ac_status=$?
12539   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12540   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
12541   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12542   (eval $ac_try) 2>&5
12543   ac_status=$?
12544   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12545   (exit $ac_status); }; }; then
12546
12547                 { $as_echo "$as_me:$LINENO: result: yes" >&5
12548 $as_echo "yes" >&6; }
12549                 { { $as_echo "$as_me:$LINENO: error:
12550         *** Kernel built with CONFIG_PREEMPT which is not supported.
12551         *** You must rebuild your kernel without this option." >&5
12552 $as_echo "$as_me: error:
12553         *** Kernel built with CONFIG_PREEMPT which is not supported.
12554         *** You must rebuild your kernel without this option." >&2;}
12555    { (exit 1); exit 1; }; }
12556
12557 else
12558   $as_echo "$as_me: failed program was:" >&5
12559 sed 's/^/| /' conftest.$ac_ext >&5
12560
12561                 { $as_echo "$as_me:$LINENO: result: no" >&5
12562 $as_echo "no" >&6; }
12563
12564
12565
12566
12567 fi
12568
12569         rm -Rf build
12570
12571
12572
12573
12574
12575
12576         { $as_echo "$as_me:$LINENO: checking whether Linux was built with CONFIG_DEBUG_LOCK_ALLOC" >&5
12577 $as_echo_n "checking whether Linux was built with CONFIG_DEBUG_LOCK_ALLOC... " >&6; }
12578
12579
12580 cat confdefs.h - <<_ACEOF >conftest.c
12581 /* confdefs.h.  */
12582 _ACEOF
12583 cat confdefs.h >>conftest.$ac_ext
12584 cat >>conftest.$ac_ext <<_ACEOF
12585 /* end confdefs.h.  */
12586
12587
12588                 #include <linux/module.h>
12589
12590 int
12591 main (void)
12592 {
12593
12594                 #ifndef CONFIG_DEBUG_LOCK_ALLOC
12595                 #error CONFIG_DEBUG_LOCK_ALLOC not #defined
12596                 #endif
12597
12598   ;
12599   return 0;
12600 }
12601
12602 _ACEOF
12603
12604
12605         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
12606         echo "obj-m := conftest.o" >build/Makefile
12607         modpost_flag=''
12608         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
12609         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
12610   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12611   (eval $ac_try) 2>&5
12612   ac_status=$?
12613   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12614   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
12615   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12616   (eval $ac_try) 2>&5
12617   ac_status=$?
12618   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12619   (exit $ac_status); }; }; then
12620
12621                 { $as_echo "$as_me:$LINENO: result: yes" >&5
12622 $as_echo "yes" >&6; }
12623
12624                 { $as_echo "$as_me:$LINENO: checking whether mutex_lock() is GPL-only" >&5
12625 $as_echo_n "checking whether mutex_lock() is GPL-only... " >&6; }
12626                 tmp_flags="$EXTRA_KCFLAGS"
12627
12628
12629 cat confdefs.h - <<_ACEOF >conftest.c
12630 /* confdefs.h.  */
12631 _ACEOF
12632 cat confdefs.h >>conftest.$ac_ext
12633 cat >>conftest.$ac_ext <<_ACEOF
12634 /* end confdefs.h.  */
12635
12636
12637                         #include <linux/module.h>
12638                         #include <linux/mutex.h>
12639
12640                         MODULE_LICENSE("$ZFS_META_LICENSE");
12641
12642 int
12643 main (void)
12644 {
12645
12646                         struct mutex lock;
12647
12648                         mutex_init(&lock);
12649                         mutex_lock(&lock);
12650                         mutex_unlock(&lock);
12651
12652   ;
12653   return 0;
12654 }
12655
12656 _ACEOF
12657
12658
12659         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
12660         echo "obj-m := conftest.o" >build/Makefile
12661         modpost_flag=''
12662         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
12663         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
12664   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12665   (eval $ac_try) 2>&5
12666   ac_status=$?
12667   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12668   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
12669   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12670   (eval $ac_try) 2>&5
12671   ac_status=$?
12672   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12673   (exit $ac_status); }; }; then
12674
12675                         { $as_echo "$as_me:$LINENO: result: no" >&5
12676 $as_echo "no" >&6; }
12677
12678 else
12679   $as_echo "$as_me: failed program was:" >&5
12680 sed 's/^/| /' conftest.$ac_ext >&5
12681
12682                         { $as_echo "$as_me:$LINENO: result: yes" >&5
12683 $as_echo "yes" >&6; }
12684                         { { $as_echo "$as_me:$LINENO: error:
12685         *** Kernel built with CONFIG_DEBUG_LOCK_ALLOC which is incompatible
12686         *** with the CDDL license and will prevent the module linking stage
12687         *** from succeeding.  You must rebuild your kernel without this
12688         *** option enabled." >&5
12689 $as_echo "$as_me: error:
12690         *** Kernel built with CONFIG_DEBUG_LOCK_ALLOC which is incompatible
12691         *** with the CDDL license and will prevent the module linking stage
12692         *** from succeeding.  You must rebuild your kernel without this
12693         *** option enabled." >&2;}
12694    { (exit 1); exit 1; }; }
12695
12696
12697
12698 fi
12699
12700         rm -Rf build
12701
12702
12703                 EXTRA_KCFLAGS="$tmp_flags"
12704
12705
12706 else
12707   $as_echo "$as_me: failed program was:" >&5
12708 sed 's/^/| /' conftest.$ac_ext >&5
12709
12710                 { $as_echo "$as_me:$LINENO: result: no" >&5
12711 $as_echo "no" >&6; }
12712
12713
12714
12715
12716 fi
12717
12718         rm -Rf build
12719
12720
12721
12722
12723
12724
12725         { $as_echo "$as_me:$LINENO: checking block device operation prototypes" >&5
12726 $as_echo_n "checking block device operation prototypes... " >&6; }
12727         tmp_flags="$EXTRA_KCFLAGS"
12728         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
12729
12730
12731 cat confdefs.h - <<_ACEOF >conftest.c
12732 /* confdefs.h.  */
12733 _ACEOF
12734 cat confdefs.h >>conftest.$ac_ext
12735 cat >>conftest.$ac_ext <<_ACEOF
12736 /* end confdefs.h.  */
12737
12738
12739                 #include <linux/blkdev.h>
12740
12741 int
12742 main (void)
12743 {
12744
12745                 int (*blk_open) (struct block_device *, fmode_t) = NULL;
12746                 int (*blk_release) (struct gendisk *, fmode_t) = NULL;
12747                 int (*blk_ioctl) (struct block_device *, fmode_t,
12748                                   unsigned, unsigned long) = NULL;
12749                 int (*blk_compat_ioctl) (struct block_device *, fmode_t,
12750                                          unsigned, unsigned long) = NULL;
12751                 struct block_device_operations blk_ops = {
12752                         .open           = blk_open,
12753                         .release        = blk_release,
12754                         .ioctl          = blk_ioctl,
12755                         .compat_ioctl   = blk_compat_ioctl,
12756                 };
12757
12758                 blk_ops.open(NULL, 0);
12759                 blk_ops.release(NULL, 0);
12760                 blk_ops.ioctl(NULL, 0, 0, 0);
12761                 blk_ops.compat_ioctl(NULL, 0, 0, 0);
12762
12763   ;
12764   return 0;
12765 }
12766
12767 _ACEOF
12768
12769
12770         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
12771         echo "obj-m := conftest.o" >build/Makefile
12772         modpost_flag=''
12773         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
12774         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
12775   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12776   (eval $ac_try) 2>&5
12777   ac_status=$?
12778   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12779   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
12780   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12781   (eval $ac_try) 2>&5
12782   ac_status=$?
12783   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12784   (exit $ac_status); }; }; then
12785
12786                 { $as_echo "$as_me:$LINENO: result: struct block_device" >&5
12787 $as_echo "struct block_device" >&6; }
12788
12789 cat >>confdefs.h <<\_ACEOF
12790 #define HAVE_BDEV_BLOCK_DEVICE_OPERATIONS 1
12791 _ACEOF
12792
12793
12794 else
12795   $as_echo "$as_me: failed program was:" >&5
12796 sed 's/^/| /' conftest.$ac_ext >&5
12797
12798                 { $as_echo "$as_me:$LINENO: result: struct inode" >&5
12799 $as_echo "struct inode" >&6; }
12800
12801
12802
12803 fi
12804
12805         rm -Rf build
12806
12807
12808         EXTRA_KCFLAGS="$tmp_flags"
12809
12810         { $as_echo "$as_me:$LINENO: checking whether kernel defines fmode_t" >&5
12811 $as_echo_n "checking whether kernel defines fmode_t... " >&6; }
12812
12813
12814 cat confdefs.h - <<_ACEOF >conftest.c
12815 /* confdefs.h.  */
12816 _ACEOF
12817 cat confdefs.h >>conftest.$ac_ext
12818 cat >>conftest.$ac_ext <<_ACEOF
12819 /* end confdefs.h.  */
12820
12821
12822                 #include <linux/types.h>
12823
12824 int
12825 main (void)
12826 {
12827
12828                 fmode_t *ptr __attribute__ ((unused));
12829
12830   ;
12831   return 0;
12832 }
12833
12834 _ACEOF
12835
12836
12837         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
12838         echo "obj-m := conftest.o" >build/Makefile
12839         modpost_flag=''
12840         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
12841         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
12842   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12843   (eval $ac_try) 2>&5
12844   ac_status=$?
12845   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12846   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
12847   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12848   (eval $ac_try) 2>&5
12849   ac_status=$?
12850   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12851   (exit $ac_status); }; }; then
12852
12853                 { $as_echo "$as_me:$LINENO: result: yes" >&5
12854 $as_echo "yes" >&6; }
12855
12856 cat >>confdefs.h <<\_ACEOF
12857 #define HAVE_FMODE_T 1
12858 _ACEOF
12859
12860
12861 else
12862   $as_echo "$as_me: failed program was:" >&5
12863 sed 's/^/| /' conftest.$ac_ext >&5
12864
12865                 { $as_echo "$as_me:$LINENO: result: no" >&5
12866 $as_echo "no" >&6; }
12867
12868
12869
12870 fi
12871
12872         rm -Rf build
12873
12874
12875
12876
12877         { $as_echo "$as_me:$LINENO: checking whether kernel defines KOBJ_NAME_LEN" >&5
12878 $as_echo_n "checking whether kernel defines KOBJ_NAME_LEN... " >&6; }
12879
12880
12881 cat confdefs.h - <<_ACEOF >conftest.c
12882 /* confdefs.h.  */
12883 _ACEOF
12884 cat confdefs.h >>conftest.$ac_ext
12885 cat >>conftest.$ac_ext <<_ACEOF
12886 /* end confdefs.h.  */
12887
12888
12889                 #include <linux/kobject.h>
12890
12891 int
12892 main (void)
12893 {
12894
12895                 int val __attribute__ ((unused));
12896                 val = KOBJ_NAME_LEN;
12897
12898   ;
12899   return 0;
12900 }
12901
12902 _ACEOF
12903
12904
12905         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
12906         echo "obj-m := conftest.o" >build/Makefile
12907         modpost_flag=''
12908         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
12909         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
12910   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12911   (eval $ac_try) 2>&5
12912   ac_status=$?
12913   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12914   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
12915   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12916   (eval $ac_try) 2>&5
12917   ac_status=$?
12918   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12919   (exit $ac_status); }; }; then
12920
12921                 { $as_echo "$as_me:$LINENO: result: yes" >&5
12922 $as_echo "yes" >&6; }
12923
12924 cat >>confdefs.h <<\_ACEOF
12925 #define HAVE_KOBJ_NAME_LEN 1
12926 _ACEOF
12927
12928
12929 else
12930   $as_echo "$as_me: failed program was:" >&5
12931 sed 's/^/| /' conftest.$ac_ext >&5
12932
12933                 { $as_echo "$as_me:$LINENO: result: no" >&5
12934 $as_echo "no" >&6; }
12935
12936
12937
12938 fi
12939
12940         rm -Rf build
12941
12942
12943
12944
12945         { $as_echo "$as_me:$LINENO: checking whether blkdev_get() wants 3 args" >&5
12946 $as_echo_n "checking whether blkdev_get() wants 3 args... " >&6; }
12947
12948
12949 cat confdefs.h - <<_ACEOF >conftest.c
12950 /* confdefs.h.  */
12951 _ACEOF
12952 cat confdefs.h >>conftest.$ac_ext
12953 cat >>conftest.$ac_ext <<_ACEOF
12954 /* end confdefs.h.  */
12955
12956
12957                 #include <linux/fs.h>
12958
12959 int
12960 main (void)
12961 {
12962
12963                 struct block_device *bdev = NULL;
12964                 (void) blkdev_get(bdev, 0, NULL);
12965
12966   ;
12967   return 0;
12968 }
12969
12970 _ACEOF
12971
12972
12973         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
12974         echo "obj-m := conftest.o" >build/Makefile
12975         modpost_flag=''
12976         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
12977         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
12978   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12979   (eval $ac_try) 2>&5
12980   ac_status=$?
12981   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12982   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
12983   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12984   (eval $ac_try) 2>&5
12985   ac_status=$?
12986   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12987   (exit $ac_status); }; }; then
12988
12989                 { $as_echo "$as_me:$LINENO: result: yes" >&5
12990 $as_echo "yes" >&6; }
12991
12992 cat >>confdefs.h <<\_ACEOF
12993 #define HAVE_3ARG_BLKDEV_GET 1
12994 _ACEOF
12995
12996
12997 else
12998   $as_echo "$as_me: failed program was:" >&5
12999 sed 's/^/| /' conftest.$ac_ext >&5
13000
13001                 { $as_echo "$as_me:$LINENO: result: no" >&5
13002 $as_echo "no" >&6; }
13003
13004
13005
13006 fi
13007
13008         rm -Rf build
13009
13010
13011
13012         { $as_echo "$as_me:$LINENO: checking whether blkdev_get_by_path() is available" >&5
13013 $as_echo_n "checking whether blkdev_get_by_path() is available... " >&6; }
13014
13015
13016
13017 cat confdefs.h - <<_ACEOF >conftest.c
13018 /* confdefs.h.  */
13019 _ACEOF
13020 cat confdefs.h >>conftest.$ac_ext
13021 cat >>conftest.$ac_ext <<_ACEOF
13022 /* end confdefs.h.  */
13023
13024
13025                 #include <linux/fs.h>
13026
13027 int
13028 main (void)
13029 {
13030
13031                 blkdev_get_by_path(NULL, 0, NULL);
13032
13033   ;
13034   return 0;
13035 }
13036
13037 _ACEOF
13038
13039
13040         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13041         echo "obj-m := conftest.o" >build/Makefile
13042         modpost_flag=''
13043         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13044         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13045   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13046   (eval $ac_try) 2>&5
13047   ac_status=$?
13048   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13049   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13050   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13051   (eval $ac_try) 2>&5
13052   ac_status=$?
13053   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13054   (exit $ac_status); }; }; then
13055   rc=0
13056 else
13057   $as_echo "$as_me: failed program was:" >&5
13058 sed 's/^/| /' conftest.$ac_ext >&5
13059  rc=1
13060
13061
13062 fi
13063
13064         rm -Rf build
13065
13066
13067         if test $rc -ne 0; then :
13068
13069                 { $as_echo "$as_me:$LINENO: result: no" >&5
13070 $as_echo "no" >&6; }
13071
13072         else
13073                 if test "x$enable_linux_builtin" != xyes; then
13074
13075         grep -q -E '[[:space:]]blkdev_get_by_path[[:space:]]' \
13076                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
13077         rc=$?
13078         if test $rc -ne 0; then
13079                 export=0
13080                 for file in fs/block_dev.c; do
13081                         grep -q -E "EXPORT_SYMBOL.*(blkdev_get_by_path)" \
13082                                 "$LINUX/$file" 2>/dev/null
13083                         rc=$?
13084                         if test $rc -eq 0; then
13085                                 export=1
13086                                 break;
13087                         fi
13088                 done
13089                 if test $export -eq 0; then :
13090                         rc=1
13091                 else :
13092                         rc=0
13093                 fi
13094         else :
13095                 rc=0
13096         fi
13097
13098                 fi
13099                 if test $rc -ne 0; then :
13100
13101                 { $as_echo "$as_me:$LINENO: result: no" >&5
13102 $as_echo "no" >&6; }
13103
13104                 else :
13105
13106                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13107 $as_echo "yes" >&6; }
13108
13109 cat >>confdefs.h <<\_ACEOF
13110 #define HAVE_BLKDEV_GET_BY_PATH 1
13111 _ACEOF
13112
13113
13114                 fi
13115         fi
13116
13117
13118         { $as_echo "$as_me:$LINENO: checking whether open_bdev_exclusive() is available" >&5
13119 $as_echo_n "checking whether open_bdev_exclusive() is available... " >&6; }
13120
13121
13122
13123 cat confdefs.h - <<_ACEOF >conftest.c
13124 /* confdefs.h.  */
13125 _ACEOF
13126 cat confdefs.h >>conftest.$ac_ext
13127 cat >>conftest.$ac_ext <<_ACEOF
13128 /* end confdefs.h.  */
13129
13130
13131                 #include <linux/fs.h>
13132
13133 int
13134 main (void)
13135 {
13136
13137                 open_bdev_exclusive(NULL, 0, NULL);
13138
13139   ;
13140   return 0;
13141 }
13142
13143 _ACEOF
13144
13145
13146         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13147         echo "obj-m := conftest.o" >build/Makefile
13148         modpost_flag=''
13149         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13150         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13151   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13152   (eval $ac_try) 2>&5
13153   ac_status=$?
13154   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13155   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13156   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13157   (eval $ac_try) 2>&5
13158   ac_status=$?
13159   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13160   (exit $ac_status); }; }; then
13161   rc=0
13162 else
13163   $as_echo "$as_me: failed program was:" >&5
13164 sed 's/^/| /' conftest.$ac_ext >&5
13165  rc=1
13166
13167
13168 fi
13169
13170         rm -Rf build
13171
13172
13173         if test $rc -ne 0; then :
13174
13175                 { $as_echo "$as_me:$LINENO: result: no" >&5
13176 $as_echo "no" >&6; }
13177
13178         else
13179                 if test "x$enable_linux_builtin" != xyes; then
13180
13181         grep -q -E '[[:space:]]open_bdev_exclusive[[:space:]]' \
13182                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
13183         rc=$?
13184         if test $rc -ne 0; then
13185                 export=0
13186                 for file in fs/block_dev.c; do
13187                         grep -q -E "EXPORT_SYMBOL.*(open_bdev_exclusive)" \
13188                                 "$LINUX/$file" 2>/dev/null
13189                         rc=$?
13190                         if test $rc -eq 0; then
13191                                 export=1
13192                                 break;
13193                         fi
13194                 done
13195                 if test $export -eq 0; then :
13196                         rc=1
13197                 else :
13198                         rc=0
13199                 fi
13200         else :
13201                 rc=0
13202         fi
13203
13204                 fi
13205                 if test $rc -ne 0; then :
13206
13207                 { $as_echo "$as_me:$LINENO: result: no" >&5
13208 $as_echo "no" >&6; }
13209
13210                 else :
13211
13212                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13213 $as_echo "yes" >&6; }
13214
13215 cat >>confdefs.h <<\_ACEOF
13216 #define HAVE_OPEN_BDEV_EXCLUSIVE 1
13217 _ACEOF
13218
13219
13220                 fi
13221         fi
13222
13223
13224
13225         { $as_echo "$as_me:$LINENO: checking whether invalidate_bdev() wants 1 arg" >&5
13226 $as_echo_n "checking whether invalidate_bdev() wants 1 arg... " >&6; }
13227
13228
13229 cat confdefs.h - <<_ACEOF >conftest.c
13230 /* confdefs.h.  */
13231 _ACEOF
13232 cat confdefs.h >>conftest.$ac_ext
13233 cat >>conftest.$ac_ext <<_ACEOF
13234 /* end confdefs.h.  */
13235
13236
13237                 #include <linux/buffer_head.h>
13238
13239 int
13240 main (void)
13241 {
13242
13243                 struct block_device *bdev = NULL;
13244                 invalidate_bdev(bdev);
13245
13246   ;
13247   return 0;
13248 }
13249
13250 _ACEOF
13251
13252
13253         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13254         echo "obj-m := conftest.o" >build/Makefile
13255         modpost_flag=''
13256         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13257         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13258   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13259   (eval $ac_try) 2>&5
13260   ac_status=$?
13261   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13262   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13263   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13264   (eval $ac_try) 2>&5
13265   ac_status=$?
13266   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13267   (exit $ac_status); }; }; then
13268
13269                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13270 $as_echo "yes" >&6; }
13271
13272 cat >>confdefs.h <<\_ACEOF
13273 #define HAVE_1ARG_INVALIDATE_BDEV 1
13274 _ACEOF
13275
13276
13277 else
13278   $as_echo "$as_me: failed program was:" >&5
13279 sed 's/^/| /' conftest.$ac_ext >&5
13280
13281                 { $as_echo "$as_me:$LINENO: result: no" >&5
13282 $as_echo "no" >&6; }
13283
13284
13285
13286 fi
13287
13288         rm -Rf build
13289
13290
13291
13292
13293         { $as_echo "$as_me:$LINENO: checking whether bdev_logical_block_size() is available" >&5
13294 $as_echo_n "checking whether bdev_logical_block_size() is available... " >&6; }
13295         tmp_flags="$EXTRA_KCFLAGS"
13296         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
13297
13298
13299 cat confdefs.h - <<_ACEOF >conftest.c
13300 /* confdefs.h.  */
13301 _ACEOF
13302 cat confdefs.h >>conftest.$ac_ext
13303 cat >>conftest.$ac_ext <<_ACEOF
13304 /* end confdefs.h.  */
13305
13306
13307                 #include <linux/blkdev.h>
13308
13309 int
13310 main (void)
13311 {
13312
13313                 struct block_device *bdev = NULL;
13314                 bdev_logical_block_size(bdev);
13315
13316   ;
13317   return 0;
13318 }
13319
13320 _ACEOF
13321
13322
13323         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13324         echo "obj-m := conftest.o" >build/Makefile
13325         modpost_flag=''
13326         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13327         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13328   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13329   (eval $ac_try) 2>&5
13330   ac_status=$?
13331   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13332   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13333   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13334   (eval $ac_try) 2>&5
13335   ac_status=$?
13336   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13337   (exit $ac_status); }; }; then
13338
13339                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13340 $as_echo "yes" >&6; }
13341
13342 cat >>confdefs.h <<\_ACEOF
13343 #define HAVE_BDEV_LOGICAL_BLOCK_SIZE 1
13344 _ACEOF
13345
13346
13347 else
13348   $as_echo "$as_me: failed program was:" >&5
13349 sed 's/^/| /' conftest.$ac_ext >&5
13350
13351                 { $as_echo "$as_me:$LINENO: result: no" >&5
13352 $as_echo "no" >&6; }
13353
13354
13355
13356 fi
13357
13358         rm -Rf build
13359
13360
13361         EXTRA_KCFLAGS="$tmp_flags"
13362
13363
13364         { $as_echo "$as_me:$LINENO: checking whether bio_empty_barrier() is defined" >&5
13365 $as_echo_n "checking whether bio_empty_barrier() is defined... " >&6; }
13366         EXTRA_KCFLAGS="-Werror"
13367
13368
13369 cat confdefs.h - <<_ACEOF >conftest.c
13370 /* confdefs.h.  */
13371 _ACEOF
13372 cat confdefs.h >>conftest.$ac_ext
13373 cat >>conftest.$ac_ext <<_ACEOF
13374 /* end confdefs.h.  */
13375
13376
13377                 #include <linux/bio.h>
13378
13379 int
13380 main (void)
13381 {
13382
13383                 struct bio bio;
13384                 (void)bio_empty_barrier(&bio);
13385
13386   ;
13387   return 0;
13388 }
13389
13390 _ACEOF
13391
13392
13393         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13394         echo "obj-m := conftest.o" >build/Makefile
13395         modpost_flag=''
13396         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13397         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13398   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13399   (eval $ac_try) 2>&5
13400   ac_status=$?
13401   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13402   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13403   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13404   (eval $ac_try) 2>&5
13405   ac_status=$?
13406   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13407   (exit $ac_status); }; }; then
13408
13409                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13410 $as_echo "yes" >&6; }
13411
13412 cat >>confdefs.h <<\_ACEOF
13413 #define HAVE_BIO_EMPTY_BARRIER 1
13414 _ACEOF
13415
13416
13417 else
13418   $as_echo "$as_me: failed program was:" >&5
13419 sed 's/^/| /' conftest.$ac_ext >&5
13420
13421                 { $as_echo "$as_me:$LINENO: result: no" >&5
13422 $as_echo "no" >&6; }
13423
13424
13425
13426 fi
13427
13428         rm -Rf build
13429
13430
13431
13432
13433         { $as_echo "$as_me:$LINENO: checking whether BIO_RW_FAILFAST is defined" >&5
13434 $as_echo_n "checking whether BIO_RW_FAILFAST is defined... " >&6; }
13435
13436
13437 cat confdefs.h - <<_ACEOF >conftest.c
13438 /* confdefs.h.  */
13439 _ACEOF
13440 cat confdefs.h >>conftest.$ac_ext
13441 cat >>conftest.$ac_ext <<_ACEOF
13442 /* end confdefs.h.  */
13443
13444
13445                 #include <linux/bio.h>
13446
13447 int
13448 main (void)
13449 {
13450
13451                 int flags __attribute__ ((unused));
13452                 flags = (1 << BIO_RW_FAILFAST);
13453
13454   ;
13455   return 0;
13456 }
13457
13458 _ACEOF
13459
13460
13461         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13462         echo "obj-m := conftest.o" >build/Makefile
13463         modpost_flag=''
13464         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13465         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13466   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13467   (eval $ac_try) 2>&5
13468   ac_status=$?
13469   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13470   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13471   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13472   (eval $ac_try) 2>&5
13473   ac_status=$?
13474   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13475   (exit $ac_status); }; }; then
13476
13477                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13478 $as_echo "yes" >&6; }
13479
13480 cat >>confdefs.h <<\_ACEOF
13481 #define HAVE_BIO_RW_FAILFAST 1
13482 _ACEOF
13483
13484
13485 else
13486   $as_echo "$as_me: failed program was:" >&5
13487 sed 's/^/| /' conftest.$ac_ext >&5
13488
13489                 { $as_echo "$as_me:$LINENO: result: no" >&5
13490 $as_echo "no" >&6; }
13491
13492
13493
13494 fi
13495
13496         rm -Rf build
13497
13498
13499
13500
13501         { $as_echo "$as_me:$LINENO: checking whether BIO_RW_FAILFAST_* are defined" >&5
13502 $as_echo_n "checking whether BIO_RW_FAILFAST_* are defined... " >&6; }
13503
13504
13505 cat confdefs.h - <<_ACEOF >conftest.c
13506 /* confdefs.h.  */
13507 _ACEOF
13508 cat confdefs.h >>conftest.$ac_ext
13509 cat >>conftest.$ac_ext <<_ACEOF
13510 /* end confdefs.h.  */
13511
13512
13513                 #include <linux/bio.h>
13514
13515 int
13516 main (void)
13517 {
13518
13519                 int flags __attribute__ ((unused));
13520                 flags = ((1 << BIO_RW_FAILFAST_DEV) |
13521                          (1 << BIO_RW_FAILFAST_TRANSPORT) |
13522                          (1 << BIO_RW_FAILFAST_DRIVER));
13523
13524   ;
13525   return 0;
13526 }
13527
13528 _ACEOF
13529
13530
13531         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13532         echo "obj-m := conftest.o" >build/Makefile
13533         modpost_flag=''
13534         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13535         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13536   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13537   (eval $ac_try) 2>&5
13538   ac_status=$?
13539   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13540   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13541   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13542   (eval $ac_try) 2>&5
13543   ac_status=$?
13544   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13545   (exit $ac_status); }; }; then
13546
13547                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13548 $as_echo "yes" >&6; }
13549
13550 cat >>confdefs.h <<\_ACEOF
13551 #define HAVE_BIO_RW_FAILFAST_DTD 1
13552 _ACEOF
13553
13554
13555 else
13556   $as_echo "$as_me: failed program was:" >&5
13557 sed 's/^/| /' conftest.$ac_ext >&5
13558
13559                 { $as_echo "$as_me:$LINENO: result: no" >&5
13560 $as_echo "no" >&6; }
13561
13562
13563
13564 fi
13565
13566         rm -Rf build
13567
13568
13569
13570
13571         { $as_echo "$as_me:$LINENO: checking whether REQ_FAILFAST_MASK is defined" >&5
13572 $as_echo_n "checking whether REQ_FAILFAST_MASK is defined... " >&6; }
13573
13574
13575 cat confdefs.h - <<_ACEOF >conftest.c
13576 /* confdefs.h.  */
13577 _ACEOF
13578 cat confdefs.h >>conftest.$ac_ext
13579 cat >>conftest.$ac_ext <<_ACEOF
13580 /* end confdefs.h.  */
13581
13582
13583                 #include <linux/bio.h>
13584
13585 int
13586 main (void)
13587 {
13588
13589                 int flags __attribute__ ((unused));
13590                 flags = REQ_FAILFAST_MASK;
13591
13592   ;
13593   return 0;
13594 }
13595
13596 _ACEOF
13597
13598
13599         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13600         echo "obj-m := conftest.o" >build/Makefile
13601         modpost_flag=''
13602         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13603         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13604   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13605   (eval $ac_try) 2>&5
13606   ac_status=$?
13607   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13608   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13609   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13610   (eval $ac_try) 2>&5
13611   ac_status=$?
13612   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13613   (exit $ac_status); }; }; then
13614
13615                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13616 $as_echo "yes" >&6; }
13617
13618 cat >>confdefs.h <<\_ACEOF
13619 #define HAVE_BIO_REQ_FAILFAST_MASK 1
13620 _ACEOF
13621
13622
13623 else
13624   $as_echo "$as_me: failed program was:" >&5
13625 sed 's/^/| /' conftest.$ac_ext >&5
13626
13627                 { $as_echo "$as_me:$LINENO: result: no" >&5
13628 $as_echo "no" >&6; }
13629
13630
13631
13632 fi
13633
13634         rm -Rf build
13635
13636
13637
13638
13639         { $as_echo "$as_me:$LINENO: checking whether bio_end_io_t wants 2 args" >&5
13640 $as_echo_n "checking whether bio_end_io_t wants 2 args... " >&6; }
13641         tmp_flags="$EXTRA_KCFLAGS"
13642         EXTRA_KCFLAGS="-Werror"
13643
13644
13645 cat confdefs.h - <<_ACEOF >conftest.c
13646 /* confdefs.h.  */
13647 _ACEOF
13648 cat confdefs.h >>conftest.$ac_ext
13649 cat >>conftest.$ac_ext <<_ACEOF
13650 /* end confdefs.h.  */
13651
13652
13653                 #include <linux/bio.h>
13654
13655 int
13656 main (void)
13657 {
13658
13659                 void (*wanted_end_io)(struct bio *, int) = NULL;
13660                 bio_end_io_t *local_end_io __attribute__ ((unused));
13661
13662                 local_end_io = wanted_end_io;
13663
13664   ;
13665   return 0;
13666 }
13667
13668 _ACEOF
13669
13670
13671         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13672         echo "obj-m := conftest.o" >build/Makefile
13673         modpost_flag=''
13674         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13675         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13676   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13677   (eval $ac_try) 2>&5
13678   ac_status=$?
13679   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13680   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13681   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13682   (eval $ac_try) 2>&5
13683   ac_status=$?
13684   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13685   (exit $ac_status); }; }; then
13686
13687                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13688 $as_echo "yes" >&6; }
13689
13690 cat >>confdefs.h <<\_ACEOF
13691 #define HAVE_2ARGS_BIO_END_IO_T 1
13692 _ACEOF
13693
13694
13695 else
13696   $as_echo "$as_me: failed program was:" >&5
13697 sed 's/^/| /' conftest.$ac_ext >&5
13698
13699                 { $as_echo "$as_me:$LINENO: result: no" >&5
13700 $as_echo "no" >&6; }
13701
13702
13703
13704 fi
13705
13706         rm -Rf build
13707
13708
13709         EXTRA_KCFLAGS="$tmp_flags"
13710
13711
13712         { $as_echo "$as_me:$LINENO: checking whether BIO_RW_SYNC is defined" >&5
13713 $as_echo_n "checking whether BIO_RW_SYNC is defined... " >&6; }
13714
13715
13716 cat confdefs.h - <<_ACEOF >conftest.c
13717 /* confdefs.h.  */
13718 _ACEOF
13719 cat confdefs.h >>conftest.$ac_ext
13720 cat >>conftest.$ac_ext <<_ACEOF
13721 /* end confdefs.h.  */
13722
13723
13724                 #include <linux/bio.h>
13725
13726 int
13727 main (void)
13728 {
13729
13730                 int flags __attribute__ ((unused));
13731                 flags = BIO_RW_SYNC;
13732
13733   ;
13734   return 0;
13735 }
13736
13737 _ACEOF
13738
13739
13740         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13741         echo "obj-m := conftest.o" >build/Makefile
13742         modpost_flag=''
13743         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13744         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13745   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13746   (eval $ac_try) 2>&5
13747   ac_status=$?
13748   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13749   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13750   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13751   (eval $ac_try) 2>&5
13752   ac_status=$?
13753   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13754   (exit $ac_status); }; }; then
13755
13756                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13757 $as_echo "yes" >&6; }
13758
13759 cat >>confdefs.h <<\_ACEOF
13760 #define HAVE_BIO_RW_SYNC 1
13761 _ACEOF
13762
13763
13764 else
13765   $as_echo "$as_me: failed program was:" >&5
13766 sed 's/^/| /' conftest.$ac_ext >&5
13767
13768                 { $as_echo "$as_me:$LINENO: result: no" >&5
13769 $as_echo "no" >&6; }
13770
13771
13772
13773 fi
13774
13775         rm -Rf build
13776
13777
13778
13779
13780         { $as_echo "$as_me:$LINENO: checking whether BIO_RW_SYNCIO is defined" >&5
13781 $as_echo_n "checking whether BIO_RW_SYNCIO is defined... " >&6; }
13782
13783
13784 cat confdefs.h - <<_ACEOF >conftest.c
13785 /* confdefs.h.  */
13786 _ACEOF
13787 cat confdefs.h >>conftest.$ac_ext
13788 cat >>conftest.$ac_ext <<_ACEOF
13789 /* end confdefs.h.  */
13790
13791
13792                 #include <linux/bio.h>
13793
13794 int
13795 main (void)
13796 {
13797
13798                 int flags __attribute__ ((unused));
13799                 flags = BIO_RW_SYNCIO;
13800
13801   ;
13802   return 0;
13803 }
13804
13805 _ACEOF
13806
13807
13808         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13809         echo "obj-m := conftest.o" >build/Makefile
13810         modpost_flag=''
13811         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13812         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13813   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13814   (eval $ac_try) 2>&5
13815   ac_status=$?
13816   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13817   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13818   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13819   (eval $ac_try) 2>&5
13820   ac_status=$?
13821   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13822   (exit $ac_status); }; }; then
13823
13824                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13825 $as_echo "yes" >&6; }
13826
13827 cat >>confdefs.h <<\_ACEOF
13828 #define HAVE_BIO_RW_SYNCIO 1
13829 _ACEOF
13830
13831
13832 else
13833   $as_echo "$as_me: failed program was:" >&5
13834 sed 's/^/| /' conftest.$ac_ext >&5
13835
13836                 { $as_echo "$as_me:$LINENO: result: no" >&5
13837 $as_echo "no" >&6; }
13838
13839
13840
13841 fi
13842
13843         rm -Rf build
13844
13845
13846
13847
13848         { $as_echo "$as_me:$LINENO: checking whether REQ_SYNC is defined" >&5
13849 $as_echo_n "checking whether REQ_SYNC is defined... " >&6; }
13850
13851
13852 cat confdefs.h - <<_ACEOF >conftest.c
13853 /* confdefs.h.  */
13854 _ACEOF
13855 cat confdefs.h >>conftest.$ac_ext
13856 cat >>conftest.$ac_ext <<_ACEOF
13857 /* end confdefs.h.  */
13858
13859
13860                 #include <linux/bio.h>
13861
13862 int
13863 main (void)
13864 {
13865
13866                 int flags __attribute__ ((unused));
13867                 flags = REQ_SYNC;
13868
13869   ;
13870   return 0;
13871 }
13872
13873 _ACEOF
13874
13875
13876         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13877         echo "obj-m := conftest.o" >build/Makefile
13878         modpost_flag=''
13879         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13880         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13881   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13882   (eval $ac_try) 2>&5
13883   ac_status=$?
13884   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13885   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13886   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13887   (eval $ac_try) 2>&5
13888   ac_status=$?
13889   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13890   (exit $ac_status); }; }; then
13891
13892                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13893 $as_echo "yes" >&6; }
13894
13895 cat >>confdefs.h <<\_ACEOF
13896 #define HAVE_REQ_SYNC 1
13897 _ACEOF
13898
13899
13900 else
13901   $as_echo "$as_me: failed program was:" >&5
13902 sed 's/^/| /' conftest.$ac_ext >&5
13903
13904                 { $as_echo "$as_me:$LINENO: result: no" >&5
13905 $as_echo "no" >&6; }
13906
13907
13908
13909 fi
13910
13911         rm -Rf build
13912
13913
13914
13915
13916         { $as_echo "$as_me:$LINENO: checking whether blk_end_request() is available" >&5
13917 $as_echo_n "checking whether blk_end_request() is available... " >&6; }
13918         tmp_flags="$EXTRA_KCFLAGS"
13919         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
13920
13921
13922 cat confdefs.h - <<_ACEOF >conftest.c
13923 /* confdefs.h.  */
13924 _ACEOF
13925 cat confdefs.h >>conftest.$ac_ext
13926 cat >>conftest.$ac_ext <<_ACEOF
13927 /* end confdefs.h.  */
13928
13929
13930                 #include <linux/blkdev.h>
13931
13932 int
13933 main (void)
13934 {
13935
13936                 struct request *req = NULL;
13937                 (void) blk_end_request(req, 0, 0);
13938
13939   ;
13940   return 0;
13941 }
13942
13943 _ACEOF
13944
13945
13946         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
13947         echo "obj-m := conftest.o" >build/Makefile
13948         modpost_flag=''
13949         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
13950         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
13951   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13952   (eval $ac_try) 2>&5
13953   ac_status=$?
13954   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13955   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
13956   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13957   (eval $ac_try) 2>&5
13958   ac_status=$?
13959   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13960   (exit $ac_status); }; }; then
13961
13962                 { $as_echo "$as_me:$LINENO: result: yes" >&5
13963 $as_echo "yes" >&6; }
13964
13965 cat >>confdefs.h <<\_ACEOF
13966 #define HAVE_BLK_END_REQUEST 1
13967 _ACEOF
13968
13969
13970 else
13971   $as_echo "$as_me: failed program was:" >&5
13972 sed 's/^/| /' conftest.$ac_ext >&5
13973
13974                 { $as_echo "$as_me:$LINENO: result: no" >&5
13975 $as_echo "no" >&6; }
13976
13977
13978
13979 fi
13980
13981         rm -Rf build
13982
13983
13984
13985         { $as_echo "$as_me:$LINENO: checking whether blk_end_request() is GPL-only" >&5
13986 $as_echo_n "checking whether blk_end_request() is GPL-only... " >&6; }
13987
13988
13989 cat confdefs.h - <<_ACEOF >conftest.c
13990 /* confdefs.h.  */
13991 _ACEOF
13992 cat confdefs.h >>conftest.$ac_ext
13993 cat >>conftest.$ac_ext <<_ACEOF
13994 /* end confdefs.h.  */
13995
13996
13997                 #include <linux/module.h>
13998                 #include <linux/blkdev.h>
13999
14000                 MODULE_LICENSE("CDDL");
14001
14002 int
14003 main (void)
14004 {
14005
14006                 struct request *req = NULL;
14007                 (void) blk_end_request(req, 0, 0);
14008
14009   ;
14010   return 0;
14011 }
14012
14013 _ACEOF
14014
14015
14016         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14017         echo "obj-m := conftest.o" >build/Makefile
14018         modpost_flag=''
14019         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14020         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14021   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14022   (eval $ac_try) 2>&5
14023   ac_status=$?
14024   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14025   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14026   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14027   (eval $ac_try) 2>&5
14028   ac_status=$?
14029   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14030   (exit $ac_status); }; }; then
14031
14032                 { $as_echo "$as_me:$LINENO: result: no" >&5
14033 $as_echo "no" >&6; }
14034
14035 else
14036   $as_echo "$as_me: failed program was:" >&5
14037 sed 's/^/| /' conftest.$ac_ext >&5
14038
14039                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14040 $as_echo "yes" >&6; }
14041
14042 cat >>confdefs.h <<\_ACEOF
14043 #define HAVE_BLK_END_REQUEST_GPL_ONLY 1
14044 _ACEOF
14045
14046
14047
14048
14049 fi
14050
14051         rm -Rf build
14052
14053
14054         EXTRA_KCFLAGS="$tmp_flags"
14055
14056
14057         { $as_echo "$as_me:$LINENO: checking whether blk_queue_flush() is available" >&5
14058 $as_echo_n "checking whether blk_queue_flush() is available... " >&6; }
14059         tmp_flags="$EXTRA_KCFLAGS"
14060         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14061
14062
14063 cat confdefs.h - <<_ACEOF >conftest.c
14064 /* confdefs.h.  */
14065 _ACEOF
14066 cat confdefs.h >>conftest.$ac_ext
14067 cat >>conftest.$ac_ext <<_ACEOF
14068 /* end confdefs.h.  */
14069
14070
14071                 #include <linux/blkdev.h>
14072
14073 int
14074 main (void)
14075 {
14076
14077                 struct request_queue *q = NULL;
14078                 (void) blk_queue_flush(q, REQ_FLUSH);
14079
14080   ;
14081   return 0;
14082 }
14083
14084 _ACEOF
14085
14086
14087         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14088         echo "obj-m := conftest.o" >build/Makefile
14089         modpost_flag=''
14090         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14091         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14092   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14093   (eval $ac_try) 2>&5
14094   ac_status=$?
14095   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14096   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14097   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14098   (eval $ac_try) 2>&5
14099   ac_status=$?
14100   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14101   (exit $ac_status); }; }; then
14102
14103                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14104 $as_echo "yes" >&6; }
14105
14106 cat >>confdefs.h <<\_ACEOF
14107 #define HAVE_BLK_QUEUE_FLUSH 1
14108 _ACEOF
14109
14110
14111 else
14112   $as_echo "$as_me: failed program was:" >&5
14113 sed 's/^/| /' conftest.$ac_ext >&5
14114
14115                 { $as_echo "$as_me:$LINENO: result: no" >&5
14116 $as_echo "no" >&6; }
14117
14118
14119
14120 fi
14121
14122         rm -Rf build
14123
14124
14125
14126         { $as_echo "$as_me:$LINENO: checking whether blk_queue_flush() is GPL-only" >&5
14127 $as_echo_n "checking whether blk_queue_flush() is GPL-only... " >&6; }
14128
14129
14130 cat confdefs.h - <<_ACEOF >conftest.c
14131 /* confdefs.h.  */
14132 _ACEOF
14133 cat confdefs.h >>conftest.$ac_ext
14134 cat >>conftest.$ac_ext <<_ACEOF
14135 /* end confdefs.h.  */
14136
14137
14138                 #include <linux/module.h>
14139                 #include <linux/blkdev.h>
14140
14141                 MODULE_LICENSE("CDDL");
14142
14143 int
14144 main (void)
14145 {
14146
14147                 struct request_queue *q = NULL;
14148                 (void) blk_queue_flush(q, REQ_FLUSH);
14149
14150   ;
14151   return 0;
14152 }
14153
14154 _ACEOF
14155
14156
14157         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14158         echo "obj-m := conftest.o" >build/Makefile
14159         modpost_flag=''
14160         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14161         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14162   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14163   (eval $ac_try) 2>&5
14164   ac_status=$?
14165   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14166   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14167   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14168   (eval $ac_try) 2>&5
14169   ac_status=$?
14170   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14171   (exit $ac_status); }; }; then
14172
14173                 { $as_echo "$as_me:$LINENO: result: no" >&5
14174 $as_echo "no" >&6; }
14175
14176 else
14177   $as_echo "$as_me: failed program was:" >&5
14178 sed 's/^/| /' conftest.$ac_ext >&5
14179
14180                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14181 $as_echo "yes" >&6; }
14182
14183 cat >>confdefs.h <<\_ACEOF
14184 #define HAVE_BLK_QUEUE_FLUSH_GPL_ONLY 1
14185 _ACEOF
14186
14187
14188
14189
14190 fi
14191
14192         rm -Rf build
14193
14194
14195         EXTRA_KCFLAGS="$tmp_flags"
14196
14197
14198         { $as_echo "$as_me:$LINENO: checking whether blk_queue_max_hw_sectors() is available" >&5
14199 $as_echo_n "checking whether blk_queue_max_hw_sectors() is available... " >&6; }
14200         tmp_flags="$EXTRA_KCFLAGS"
14201         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14202
14203
14204 cat confdefs.h - <<_ACEOF >conftest.c
14205 /* confdefs.h.  */
14206 _ACEOF
14207 cat confdefs.h >>conftest.$ac_ext
14208 cat >>conftest.$ac_ext <<_ACEOF
14209 /* end confdefs.h.  */
14210
14211
14212                 #include <linux/blkdev.h>
14213
14214 int
14215 main (void)
14216 {
14217
14218                 struct request_queue *q = NULL;
14219                 (void) blk_queue_max_hw_sectors(q, BLK_SAFE_MAX_SECTORS);
14220
14221   ;
14222   return 0;
14223 }
14224
14225 _ACEOF
14226
14227
14228         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14229         echo "obj-m := conftest.o" >build/Makefile
14230         modpost_flag=''
14231         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14232         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14233   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14234   (eval $ac_try) 2>&5
14235   ac_status=$?
14236   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14237   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14238   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14239   (eval $ac_try) 2>&5
14240   ac_status=$?
14241   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14242   (exit $ac_status); }; }; then
14243
14244                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14245 $as_echo "yes" >&6; }
14246
14247 cat >>confdefs.h <<\_ACEOF
14248 #define HAVE_BLK_QUEUE_MAX_HW_SECTORS 1
14249 _ACEOF
14250
14251
14252 else
14253   $as_echo "$as_me: failed program was:" >&5
14254 sed 's/^/| /' conftest.$ac_ext >&5
14255
14256                 { $as_echo "$as_me:$LINENO: result: no" >&5
14257 $as_echo "no" >&6; }
14258
14259
14260
14261 fi
14262
14263         rm -Rf build
14264
14265
14266         EXTRA_KCFLAGS="$tmp_flags"
14267
14268
14269         { $as_echo "$as_me:$LINENO: checking whether blk_queue_max_segments() is available" >&5
14270 $as_echo_n "checking whether blk_queue_max_segments() is available... " >&6; }
14271         tmp_flags="$EXTRA_KCFLAGS"
14272         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14273
14274
14275 cat confdefs.h - <<_ACEOF >conftest.c
14276 /* confdefs.h.  */
14277 _ACEOF
14278 cat confdefs.h >>conftest.$ac_ext
14279 cat >>conftest.$ac_ext <<_ACEOF
14280 /* end confdefs.h.  */
14281
14282
14283                 #include <linux/blkdev.h>
14284
14285 int
14286 main (void)
14287 {
14288
14289                 struct request_queue *q = NULL;
14290                 (void) blk_queue_max_segments(q, BLK_MAX_SEGMENTS);
14291
14292   ;
14293   return 0;
14294 }
14295
14296 _ACEOF
14297
14298
14299         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14300         echo "obj-m := conftest.o" >build/Makefile
14301         modpost_flag=''
14302         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14303         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14304   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14305   (eval $ac_try) 2>&5
14306   ac_status=$?
14307   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14308   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14309   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14310   (eval $ac_try) 2>&5
14311   ac_status=$?
14312   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14313   (exit $ac_status); }; }; then
14314
14315                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14316 $as_echo "yes" >&6; }
14317
14318 cat >>confdefs.h <<\_ACEOF
14319 #define HAVE_BLK_QUEUE_MAX_SEGMENTS 1
14320 _ACEOF
14321
14322
14323 else
14324   $as_echo "$as_me: failed program was:" >&5
14325 sed 's/^/| /' conftest.$ac_ext >&5
14326
14327                 { $as_echo "$as_me:$LINENO: result: no" >&5
14328 $as_echo "no" >&6; }
14329
14330
14331
14332 fi
14333
14334         rm -Rf build
14335
14336
14337         EXTRA_KCFLAGS="$tmp_flags"
14338
14339
14340         { $as_echo "$as_me:$LINENO: checking whether blk_queue_physical_block_size() is available" >&5
14341 $as_echo_n "checking whether blk_queue_physical_block_size() is available... " >&6; }
14342         tmp_flags="$EXTRA_KCFLAGS"
14343         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14344
14345
14346 cat confdefs.h - <<_ACEOF >conftest.c
14347 /* confdefs.h.  */
14348 _ACEOF
14349 cat confdefs.h >>conftest.$ac_ext
14350 cat >>conftest.$ac_ext <<_ACEOF
14351 /* end confdefs.h.  */
14352
14353
14354                 #include <linux/blkdev.h>
14355
14356 int
14357 main (void)
14358 {
14359
14360                 struct request_queue *q = NULL;
14361                 unsigned short block_size = 1;
14362                 (void) blk_queue_physical_block_size(q, block_size);
14363
14364   ;
14365   return 0;
14366 }
14367
14368 _ACEOF
14369
14370
14371         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14372         echo "obj-m := conftest.o" >build/Makefile
14373         modpost_flag=''
14374         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14375         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14376   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14377   (eval $ac_try) 2>&5
14378   ac_status=$?
14379   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14380   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14381   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14382   (eval $ac_try) 2>&5
14383   ac_status=$?
14384   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14385   (exit $ac_status); }; }; then
14386
14387                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14388 $as_echo "yes" >&6; }
14389
14390 cat >>confdefs.h <<\_ACEOF
14391 #define HAVE_BLK_QUEUE_PHYSICAL_BLOCK_SIZE 1
14392 _ACEOF
14393
14394
14395 else
14396   $as_echo "$as_me: failed program was:" >&5
14397 sed 's/^/| /' conftest.$ac_ext >&5
14398
14399                 { $as_echo "$as_me:$LINENO: result: no" >&5
14400 $as_echo "no" >&6; }
14401
14402
14403
14404 fi
14405
14406         rm -Rf build
14407
14408
14409         EXTRA_KCFLAGS="$tmp_flags"
14410
14411
14412         { $as_echo "$as_me:$LINENO: checking whether blk_queue_io_opt() is available" >&5
14413 $as_echo_n "checking whether blk_queue_io_opt() is available... " >&6; }
14414         tmp_flags="$EXTRA_KCFLAGS"
14415         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14416
14417
14418 cat confdefs.h - <<_ACEOF >conftest.c
14419 /* confdefs.h.  */
14420 _ACEOF
14421 cat confdefs.h >>conftest.$ac_ext
14422 cat >>conftest.$ac_ext <<_ACEOF
14423 /* end confdefs.h.  */
14424
14425
14426                 #include <linux/blkdev.h>
14427
14428 int
14429 main (void)
14430 {
14431
14432                 struct request_queue *q = NULL;
14433                 unsigned int opt = 1;
14434                 (void) blk_queue_io_opt(q, opt);
14435
14436   ;
14437   return 0;
14438 }
14439
14440 _ACEOF
14441
14442
14443         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14444         echo "obj-m := conftest.o" >build/Makefile
14445         modpost_flag=''
14446         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14447         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14448   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14449   (eval $ac_try) 2>&5
14450   ac_status=$?
14451   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14452   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14453   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14454   (eval $ac_try) 2>&5
14455   ac_status=$?
14456   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14457   (exit $ac_status); }; }; then
14458
14459                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14460 $as_echo "yes" >&6; }
14461
14462 cat >>confdefs.h <<\_ACEOF
14463 #define HAVE_BLK_QUEUE_IO_OPT 1
14464 _ACEOF
14465
14466
14467 else
14468   $as_echo "$as_me: failed program was:" >&5
14469 sed 's/^/| /' conftest.$ac_ext >&5
14470
14471                 { $as_echo "$as_me:$LINENO: result: no" >&5
14472 $as_echo "no" >&6; }
14473
14474
14475
14476 fi
14477
14478         rm -Rf build
14479
14480
14481         EXTRA_KCFLAGS="$tmp_flags"
14482
14483
14484         { $as_echo "$as_me:$LINENO: checking whether blk_queue_nonrot() is available" >&5
14485 $as_echo_n "checking whether blk_queue_nonrot() is available... " >&6; }
14486         tmp_flags="$EXTRA_KCFLAGS"
14487         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14488
14489
14490 cat confdefs.h - <<_ACEOF >conftest.c
14491 /* confdefs.h.  */
14492 _ACEOF
14493 cat confdefs.h >>conftest.$ac_ext
14494 cat >>conftest.$ac_ext <<_ACEOF
14495 /* end confdefs.h.  */
14496
14497
14498                 #include <linux/blkdev.h>
14499
14500 int
14501 main (void)
14502 {
14503
14504                 struct request_queue *q = NULL;
14505                 (void) blk_queue_nonrot(q);
14506
14507   ;
14508   return 0;
14509 }
14510
14511 _ACEOF
14512
14513
14514         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14515         echo "obj-m := conftest.o" >build/Makefile
14516         modpost_flag=''
14517         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14518         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14519   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14520   (eval $ac_try) 2>&5
14521   ac_status=$?
14522   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14523   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14524   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14525   (eval $ac_try) 2>&5
14526   ac_status=$?
14527   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14528   (exit $ac_status); }; }; then
14529
14530                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14531 $as_echo "yes" >&6; }
14532
14533 cat >>confdefs.h <<\_ACEOF
14534 #define HAVE_BLK_QUEUE_NONROT 1
14535 _ACEOF
14536
14537
14538 else
14539   $as_echo "$as_me: failed program was:" >&5
14540 sed 's/^/| /' conftest.$ac_ext >&5
14541
14542                 { $as_echo "$as_me:$LINENO: result: no" >&5
14543 $as_echo "no" >&6; }
14544
14545
14546
14547 fi
14548
14549         rm -Rf build
14550
14551
14552         EXTRA_KCFLAGS="$tmp_flags"
14553
14554
14555         { $as_echo "$as_me:$LINENO: checking whether blk_queue_discard() is available" >&5
14556 $as_echo_n "checking whether blk_queue_discard() is available... " >&6; }
14557         tmp_flags="$EXTRA_KCFLAGS"
14558         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14559
14560
14561 cat confdefs.h - <<_ACEOF >conftest.c
14562 /* confdefs.h.  */
14563 _ACEOF
14564 cat confdefs.h >>conftest.$ac_ext
14565 cat >>conftest.$ac_ext <<_ACEOF
14566 /* end confdefs.h.  */
14567
14568
14569                 #include <linux/blkdev.h>
14570
14571 int
14572 main (void)
14573 {
14574
14575                 struct request_queue *q = NULL;
14576                 (void) blk_queue_discard(q);
14577
14578   ;
14579   return 0;
14580 }
14581
14582 _ACEOF
14583
14584
14585         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14586         echo "obj-m := conftest.o" >build/Makefile
14587         modpost_flag=''
14588         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14589         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14590   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14591   (eval $ac_try) 2>&5
14592   ac_status=$?
14593   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14594   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14595   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14596   (eval $ac_try) 2>&5
14597   ac_status=$?
14598   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14599   (exit $ac_status); }; }; then
14600
14601                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14602 $as_echo "yes" >&6; }
14603
14604 cat >>confdefs.h <<\_ACEOF
14605 #define HAVE_BLK_QUEUE_DISCARD 1
14606 _ACEOF
14607
14608
14609 else
14610   $as_echo "$as_me: failed program was:" >&5
14611 sed 's/^/| /' conftest.$ac_ext >&5
14612
14613                 { $as_echo "$as_me:$LINENO: result: no" >&5
14614 $as_echo "no" >&6; }
14615
14616
14617
14618 fi
14619
14620         rm -Rf build
14621
14622
14623         EXTRA_KCFLAGS="$tmp_flags"
14624
14625
14626         { $as_echo "$as_me:$LINENO: checking whether blk_fetch_request() is available" >&5
14627 $as_echo_n "checking whether blk_fetch_request() is available... " >&6; }
14628         tmp_flags="$EXTRA_KCFLAGS"
14629         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14630
14631
14632 cat confdefs.h - <<_ACEOF >conftest.c
14633 /* confdefs.h.  */
14634 _ACEOF
14635 cat confdefs.h >>conftest.$ac_ext
14636 cat >>conftest.$ac_ext <<_ACEOF
14637 /* end confdefs.h.  */
14638
14639
14640                 #include <linux/blkdev.h>
14641
14642 int
14643 main (void)
14644 {
14645
14646                 struct request_queue *q = NULL;
14647                 (void) blk_fetch_request(q);
14648
14649   ;
14650   return 0;
14651 }
14652
14653 _ACEOF
14654
14655
14656         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14657         echo "obj-m := conftest.o" >build/Makefile
14658         modpost_flag=''
14659         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14660         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14661   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14662   (eval $ac_try) 2>&5
14663   ac_status=$?
14664   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14665   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14666   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14667   (eval $ac_try) 2>&5
14668   ac_status=$?
14669   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14670   (exit $ac_status); }; }; then
14671
14672                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14673 $as_echo "yes" >&6; }
14674
14675 cat >>confdefs.h <<\_ACEOF
14676 #define HAVE_BLK_FETCH_REQUEST 1
14677 _ACEOF
14678
14679
14680 else
14681   $as_echo "$as_me: failed program was:" >&5
14682 sed 's/^/| /' conftest.$ac_ext >&5
14683
14684                 { $as_echo "$as_me:$LINENO: result: no" >&5
14685 $as_echo "no" >&6; }
14686
14687
14688
14689 fi
14690
14691         rm -Rf build
14692
14693
14694         EXTRA_KCFLAGS="$tmp_flags"
14695
14696
14697         { $as_echo "$as_me:$LINENO: checking whether blk_requeue_request() is available" >&5
14698 $as_echo_n "checking whether blk_requeue_request() is available... " >&6; }
14699         tmp_flags="$EXTRA_KCFLAGS"
14700         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14701
14702
14703 cat confdefs.h - <<_ACEOF >conftest.c
14704 /* confdefs.h.  */
14705 _ACEOF
14706 cat confdefs.h >>conftest.$ac_ext
14707 cat >>conftest.$ac_ext <<_ACEOF
14708 /* end confdefs.h.  */
14709
14710
14711                 #include <linux/blkdev.h>
14712
14713 int
14714 main (void)
14715 {
14716
14717                 struct request_queue *q = NULL;
14718                 struct request *req = NULL;
14719                 blk_requeue_request(q, req);
14720
14721   ;
14722   return 0;
14723 }
14724
14725 _ACEOF
14726
14727
14728         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14729         echo "obj-m := conftest.o" >build/Makefile
14730         modpost_flag=''
14731         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14732         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14733   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14734   (eval $ac_try) 2>&5
14735   ac_status=$?
14736   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14737   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14738   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14739   (eval $ac_try) 2>&5
14740   ac_status=$?
14741   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14742   (exit $ac_status); }; }; then
14743
14744                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14745 $as_echo "yes" >&6; }
14746
14747 cat >>confdefs.h <<\_ACEOF
14748 #define HAVE_BLK_REQUEUE_REQUEST 1
14749 _ACEOF
14750
14751
14752 else
14753   $as_echo "$as_me: failed program was:" >&5
14754 sed 's/^/| /' conftest.$ac_ext >&5
14755
14756                 { $as_echo "$as_me:$LINENO: result: no" >&5
14757 $as_echo "no" >&6; }
14758
14759
14760
14761 fi
14762
14763         rm -Rf build
14764
14765
14766         EXTRA_KCFLAGS="$tmp_flags"
14767
14768
14769         { $as_echo "$as_me:$LINENO: checking whether blk_rq_bytes() is available" >&5
14770 $as_echo_n "checking whether blk_rq_bytes() is available... " >&6; }
14771         tmp_flags="$EXTRA_KCFLAGS"
14772         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14773
14774
14775 cat confdefs.h - <<_ACEOF >conftest.c
14776 /* confdefs.h.  */
14777 _ACEOF
14778 cat confdefs.h >>conftest.$ac_ext
14779 cat >>conftest.$ac_ext <<_ACEOF
14780 /* end confdefs.h.  */
14781
14782
14783                 #include <linux/blkdev.h>
14784
14785 int
14786 main (void)
14787 {
14788
14789                 struct request *req = NULL;
14790                 (void) blk_rq_bytes(req);
14791
14792   ;
14793   return 0;
14794 }
14795
14796 _ACEOF
14797
14798
14799         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14800         echo "obj-m := conftest.o" >build/Makefile
14801         modpost_flag=''
14802         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14803         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14804   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14805   (eval $ac_try) 2>&5
14806   ac_status=$?
14807   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14808   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14810   (eval $ac_try) 2>&5
14811   ac_status=$?
14812   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14813   (exit $ac_status); }; }; then
14814
14815                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14816 $as_echo "yes" >&6; }
14817
14818 cat >>confdefs.h <<\_ACEOF
14819 #define HAVE_BLK_RQ_BYTES 1
14820 _ACEOF
14821
14822
14823 else
14824   $as_echo "$as_me: failed program was:" >&5
14825 sed 's/^/| /' conftest.$ac_ext >&5
14826
14827                 { $as_echo "$as_me:$LINENO: result: no" >&5
14828 $as_echo "no" >&6; }
14829
14830
14831
14832 fi
14833
14834         rm -Rf build
14835
14836
14837
14838         { $as_echo "$as_me:$LINENO: checking whether blk_rq_bytes() is GPL-only" >&5
14839 $as_echo_n "checking whether blk_rq_bytes() is GPL-only... " >&6; }
14840
14841
14842 cat confdefs.h - <<_ACEOF >conftest.c
14843 /* confdefs.h.  */
14844 _ACEOF
14845 cat confdefs.h >>conftest.$ac_ext
14846 cat >>conftest.$ac_ext <<_ACEOF
14847 /* end confdefs.h.  */
14848
14849
14850                 #include <linux/module.h>
14851                 #include <linux/blkdev.h>
14852
14853                 MODULE_LICENSE("CDDL");
14854
14855 int
14856 main (void)
14857 {
14858
14859                 struct request *req = NULL;
14860                 (void) blk_rq_bytes(req);
14861
14862   ;
14863   return 0;
14864 }
14865
14866 _ACEOF
14867
14868
14869         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14870         echo "obj-m := conftest.o" >build/Makefile
14871         modpost_flag=''
14872         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14873         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14874   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14875   (eval $ac_try) 2>&5
14876   ac_status=$?
14877   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14878   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14879   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14880   (eval $ac_try) 2>&5
14881   ac_status=$?
14882   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14883   (exit $ac_status); }; }; then
14884
14885                 { $as_echo "$as_me:$LINENO: result: no" >&5
14886 $as_echo "no" >&6; }
14887
14888 else
14889   $as_echo "$as_me: failed program was:" >&5
14890 sed 's/^/| /' conftest.$ac_ext >&5
14891
14892                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14893 $as_echo "yes" >&6; }
14894
14895 cat >>confdefs.h <<\_ACEOF
14896 #define HAVE_BLK_RQ_BYTES_GPL_ONLY 1
14897 _ACEOF
14898
14899
14900
14901
14902 fi
14903
14904         rm -Rf build
14905
14906
14907         EXTRA_KCFLAGS="$tmp_flags"
14908
14909
14910         { $as_echo "$as_me:$LINENO: checking whether blk_rq_pos() is available" >&5
14911 $as_echo_n "checking whether blk_rq_pos() is available... " >&6; }
14912         tmp_flags="$EXTRA_KCFLAGS"
14913         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14914
14915
14916 cat confdefs.h - <<_ACEOF >conftest.c
14917 /* confdefs.h.  */
14918 _ACEOF
14919 cat confdefs.h >>conftest.$ac_ext
14920 cat >>conftest.$ac_ext <<_ACEOF
14921 /* end confdefs.h.  */
14922
14923
14924                 #include <linux/blkdev.h>
14925
14926 int
14927 main (void)
14928 {
14929
14930                 struct request *req = NULL;
14931                 (void) blk_rq_pos(req);
14932
14933   ;
14934   return 0;
14935 }
14936
14937 _ACEOF
14938
14939
14940         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
14941         echo "obj-m := conftest.o" >build/Makefile
14942         modpost_flag=''
14943         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
14944         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
14945   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14946   (eval $ac_try) 2>&5
14947   ac_status=$?
14948   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14949   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
14950   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14951   (eval $ac_try) 2>&5
14952   ac_status=$?
14953   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14954   (exit $ac_status); }; }; then
14955
14956                 { $as_echo "$as_me:$LINENO: result: yes" >&5
14957 $as_echo "yes" >&6; }
14958
14959 cat >>confdefs.h <<\_ACEOF
14960 #define HAVE_BLK_RQ_POS 1
14961 _ACEOF
14962
14963
14964 else
14965   $as_echo "$as_me: failed program was:" >&5
14966 sed 's/^/| /' conftest.$ac_ext >&5
14967
14968                 { $as_echo "$as_me:$LINENO: result: no" >&5
14969 $as_echo "no" >&6; }
14970
14971
14972
14973 fi
14974
14975         rm -Rf build
14976
14977
14978         EXTRA_KCFLAGS="$tmp_flags"
14979
14980
14981         { $as_echo "$as_me:$LINENO: checking whether blk_rq_sectors() is available" >&5
14982 $as_echo_n "checking whether blk_rq_sectors() is available... " >&6; }
14983         tmp_flags="$EXTRA_KCFLAGS"
14984         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
14985
14986
14987 cat confdefs.h - <<_ACEOF >conftest.c
14988 /* confdefs.h.  */
14989 _ACEOF
14990 cat confdefs.h >>conftest.$ac_ext
14991 cat >>conftest.$ac_ext <<_ACEOF
14992 /* end confdefs.h.  */
14993
14994
14995                 #include <linux/blkdev.h>
14996
14997 int
14998 main (void)
14999 {
15000
15001                 struct request *req = NULL;
15002                 (void) blk_rq_sectors(req);
15003
15004   ;
15005   return 0;
15006 }
15007
15008 _ACEOF
15009
15010
15011         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15012         echo "obj-m := conftest.o" >build/Makefile
15013         modpost_flag=''
15014         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15015         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15016   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15017   (eval $ac_try) 2>&5
15018   ac_status=$?
15019   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15020   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15021   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15022   (eval $ac_try) 2>&5
15023   ac_status=$?
15024   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15025   (exit $ac_status); }; }; then
15026
15027                 { $as_echo "$as_me:$LINENO: result: yes" >&5
15028 $as_echo "yes" >&6; }
15029
15030 cat >>confdefs.h <<\_ACEOF
15031 #define HAVE_BLK_RQ_SECTORS 1
15032 _ACEOF
15033
15034
15035 else
15036   $as_echo "$as_me: failed program was:" >&5
15037 sed 's/^/| /' conftest.$ac_ext >&5
15038
15039                 { $as_echo "$as_me:$LINENO: result: no" >&5
15040 $as_echo "no" >&6; }
15041
15042
15043
15044 fi
15045
15046         rm -Rf build
15047
15048
15049         EXTRA_KCFLAGS="$tmp_flags"
15050
15051
15052         { $as_echo "$as_me:$LINENO: checking whether get_disk_ro() is available" >&5
15053 $as_echo_n "checking whether get_disk_ro() is available... " >&6; }
15054         tmp_flags="$EXTRA_KCFLAGS"
15055         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
15056
15057
15058 cat confdefs.h - <<_ACEOF >conftest.c
15059 /* confdefs.h.  */
15060 _ACEOF
15061 cat confdefs.h >>conftest.$ac_ext
15062 cat >>conftest.$ac_ext <<_ACEOF
15063 /* end confdefs.h.  */
15064
15065
15066                 #include <linux/blkdev.h>
15067
15068 int
15069 main (void)
15070 {
15071
15072                 struct gendisk *disk = NULL;
15073                 (void) get_disk_ro(disk);
15074
15075   ;
15076   return 0;
15077 }
15078
15079 _ACEOF
15080
15081
15082         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15083         echo "obj-m := conftest.o" >build/Makefile
15084         modpost_flag=''
15085         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15086         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15087   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15088   (eval $ac_try) 2>&5
15089   ac_status=$?
15090   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15091   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15092   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15093   (eval $ac_try) 2>&5
15094   ac_status=$?
15095   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15096   (exit $ac_status); }; }; then
15097
15098                 { $as_echo "$as_me:$LINENO: result: yes" >&5
15099 $as_echo "yes" >&6; }
15100
15101 cat >>confdefs.h <<\_ACEOF
15102 #define HAVE_GET_DISK_RO 1
15103 _ACEOF
15104
15105
15106 else
15107   $as_echo "$as_me: failed program was:" >&5
15108 sed 's/^/| /' conftest.$ac_ext >&5
15109
15110                 { $as_echo "$as_me:$LINENO: result: no" >&5
15111 $as_echo "no" >&6; }
15112
15113
15114
15115 fi
15116
15117         rm -Rf build
15118
15119
15120         EXTRA_KCFLAGS="$tmp_flags"
15121
15122         { $as_echo "$as_me:$LINENO: checking whether get_gendisk() is available" >&5
15123 $as_echo_n "checking whether get_gendisk() is available... " >&6; }
15124
15125
15126
15127 cat confdefs.h - <<_ACEOF >conftest.c
15128 /* confdefs.h.  */
15129 _ACEOF
15130 cat confdefs.h >>conftest.$ac_ext
15131 cat >>conftest.$ac_ext <<_ACEOF
15132 /* end confdefs.h.  */
15133
15134
15135                 #include <linux/genhd.h>
15136
15137 int
15138 main (void)
15139 {
15140
15141                 get_gendisk(0, NULL);
15142
15143   ;
15144   return 0;
15145 }
15146
15147 _ACEOF
15148
15149
15150         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15151         echo "obj-m := conftest.o" >build/Makefile
15152         modpost_flag=''
15153         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15154         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15155   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15156   (eval $ac_try) 2>&5
15157   ac_status=$?
15158   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15159   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15160   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15161   (eval $ac_try) 2>&5
15162   ac_status=$?
15163   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15164   (exit $ac_status); }; }; then
15165   rc=0
15166 else
15167   $as_echo "$as_me: failed program was:" >&5
15168 sed 's/^/| /' conftest.$ac_ext >&5
15169  rc=1
15170
15171
15172 fi
15173
15174         rm -Rf build
15175
15176
15177         if test $rc -ne 0; then :
15178
15179                 { $as_echo "$as_me:$LINENO: result: no" >&5
15180 $as_echo "no" >&6; }
15181
15182         else
15183                 if test "x$enable_linux_builtin" != xyes; then
15184
15185         grep -q -E '[[:space:]]get_gendisk[[:space:]]' \
15186                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
15187         rc=$?
15188         if test $rc -ne 0; then
15189                 export=0
15190                 for file in block/genhd.c; do
15191                         grep -q -E "EXPORT_SYMBOL.*(get_gendisk)" \
15192                                 "$LINUX/$file" 2>/dev/null
15193                         rc=$?
15194                         if test $rc -eq 0; then
15195                                 export=1
15196                                 break;
15197                         fi
15198                 done
15199                 if test $export -eq 0; then :
15200                         rc=1
15201                 else :
15202                         rc=0
15203                 fi
15204         else :
15205                 rc=0
15206         fi
15207
15208                 fi
15209                 if test $rc -ne 0; then :
15210
15211                 { $as_echo "$as_me:$LINENO: result: no" >&5
15212 $as_echo "no" >&6; }
15213
15214                 else :
15215
15216                 { $as_echo "$as_me:$LINENO: result: yes" >&5
15217 $as_echo "yes" >&6; }
15218
15219 cat >>confdefs.h <<\_ACEOF
15220 #define HAVE_GET_GENDISK 1
15221 _ACEOF
15222
15223
15224                 fi
15225         fi
15226
15227
15228
15229         { $as_echo "$as_me:$LINENO: checking whether rq_is_sync() is available" >&5
15230 $as_echo_n "checking whether rq_is_sync() is available... " >&6; }
15231         tmp_flags="$EXTRA_KCFLAGS"
15232         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
15233
15234
15235 cat confdefs.h - <<_ACEOF >conftest.c
15236 /* confdefs.h.  */
15237 _ACEOF
15238 cat confdefs.h >>conftest.$ac_ext
15239 cat >>conftest.$ac_ext <<_ACEOF
15240 /* end confdefs.h.  */
15241
15242
15243                 #include <linux/blkdev.h>
15244
15245 int
15246 main (void)
15247 {
15248
15249                 struct request *req = NULL;
15250                 (void) rq_is_sync(req);
15251
15252   ;
15253   return 0;
15254 }
15255
15256 _ACEOF
15257
15258
15259         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15260         echo "obj-m := conftest.o" >build/Makefile
15261         modpost_flag=''
15262         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15263         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15264   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15265   (eval $ac_try) 2>&5
15266   ac_status=$?
15267   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15268   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15269   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15270   (eval $ac_try) 2>&5
15271   ac_status=$?
15272   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15273   (exit $ac_status); }; }; then
15274
15275                 { $as_echo "$as_me:$LINENO: result: yes" >&5
15276 $as_echo "yes" >&6; }
15277
15278 cat >>confdefs.h <<\_ACEOF
15279 #define HAVE_RQ_IS_SYNC 1
15280 _ACEOF
15281
15282
15283 else
15284   $as_echo "$as_me: failed program was:" >&5
15285 sed 's/^/| /' conftest.$ac_ext >&5
15286
15287                 { $as_echo "$as_me:$LINENO: result: no" >&5
15288 $as_echo "no" >&6; }
15289
15290
15291
15292 fi
15293
15294         rm -Rf build
15295
15296
15297         EXTRA_KCFLAGS="$tmp_flags"
15298
15299
15300         { $as_echo "$as_me:$LINENO: checking whether rq_for_each_segment() is available" >&5
15301 $as_echo_n "checking whether rq_for_each_segment() is available... " >&6; }
15302         tmp_flags="$EXTRA_KCFLAGS"
15303         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
15304
15305
15306 cat confdefs.h - <<_ACEOF >conftest.c
15307 /* confdefs.h.  */
15308 _ACEOF
15309 cat confdefs.h >>conftest.$ac_ext
15310 cat >>conftest.$ac_ext <<_ACEOF
15311 /* end confdefs.h.  */
15312
15313
15314                 #include <linux/blkdev.h>
15315
15316 int
15317 main (void)
15318 {
15319
15320                 struct bio_vec *bv;
15321                 struct req_iterator iter;
15322                 struct request *req = NULL;
15323                 rq_for_each_segment(bv, req, iter) { }
15324
15325   ;
15326   return 0;
15327 }
15328
15329 _ACEOF
15330
15331
15332         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15333         echo "obj-m := conftest.o" >build/Makefile
15334         modpost_flag=''
15335         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15336         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15337   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15338   (eval $ac_try) 2>&5
15339   ac_status=$?
15340   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15341   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15342   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15343   (eval $ac_try) 2>&5
15344   ac_status=$?
15345   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15346   (exit $ac_status); }; }; then
15347
15348                 { $as_echo "$as_me:$LINENO: result: yes" >&5
15349 $as_echo "yes" >&6; }
15350
15351 cat >>confdefs.h <<\_ACEOF
15352 #define HAVE_RQ_FOR_EACH_SEGMENT 1
15353 _ACEOF
15354
15355
15356 else
15357   $as_echo "$as_me: failed program was:" >&5
15358 sed 's/^/| /' conftest.$ac_ext >&5
15359
15360                 { $as_echo "$as_me:$LINENO: result: no" >&5
15361 $as_echo "no" >&6; }
15362
15363
15364
15365 fi
15366
15367         rm -Rf build
15368
15369
15370         EXTRA_KCFLAGS="$tmp_flags"
15371
15372
15373         { $as_echo "$as_me:$LINENO: checking whether ql->discard_granularity is available" >&5
15374 $as_echo_n "checking whether ql->discard_granularity is available... " >&6; }
15375
15376
15377 cat confdefs.h - <<_ACEOF >conftest.c
15378 /* confdefs.h.  */
15379 _ACEOF
15380 cat confdefs.h >>conftest.$ac_ext
15381 cat >>conftest.$ac_ext <<_ACEOF
15382 /* end confdefs.h.  */
15383
15384
15385                 #include <linux/blkdev.h>
15386
15387 int
15388 main (void)
15389 {
15390
15391                 struct queue_limits ql __attribute__ ((unused));
15392
15393                 ql.discard_granularity = 0;
15394
15395   ;
15396   return 0;
15397 }
15398
15399 _ACEOF
15400
15401
15402         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15403         echo "obj-m := conftest.o" >build/Makefile
15404         modpost_flag=''
15405         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15406         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15407   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15408   (eval $ac_try) 2>&5
15409   ac_status=$?
15410   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15411   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15412   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15413   (eval $ac_try) 2>&5
15414   ac_status=$?
15415   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15416   (exit $ac_status); }; }; then
15417
15418                 { $as_echo "$as_me:$LINENO: result: yes" >&5
15419 $as_echo "yes" >&6; }
15420
15421 cat >>confdefs.h <<\_ACEOF
15422 #define HAVE_DISCARD_GRANULARITY 1
15423 _ACEOF
15424
15425
15426 else
15427   $as_echo "$as_me: failed program was:" >&5
15428 sed 's/^/| /' conftest.$ac_ext >&5
15429
15430                 { $as_echo "$as_me:$LINENO: result: no" >&5
15431 $as_echo "no" >&6; }
15432
15433
15434
15435 fi
15436
15437         rm -Rf build
15438
15439
15440
15441         { $as_echo "$as_me:$LINENO: checking whether super_block uses const struct xattr_hander" >&5
15442 $as_echo_n "checking whether super_block uses const struct xattr_hander... " >&6; }
15443
15444
15445 cat confdefs.h - <<_ACEOF >conftest.c
15446 /* confdefs.h.  */
15447 _ACEOF
15448 cat confdefs.h >>conftest.$ac_ext
15449 cat >>conftest.$ac_ext <<_ACEOF
15450 /* end confdefs.h.  */
15451
15452
15453                 #include <linux/fs.h>
15454                 #include <linux/xattr.h>
15455
15456                 const struct xattr_handler xattr_test_handler = {
15457                         .prefix = "test",
15458                         .get    = NULL,
15459                         .set    = NULL,
15460                 };
15461
15462                 const struct xattr_handler *xattr_handlers[] = {
15463                         &xattr_test_handler,
15464                 };
15465
15466 int
15467 main (void)
15468 {
15469
15470                 struct super_block sb __attribute__ ((unused));
15471
15472                 sb.s_xattr = xattr_handlers;
15473
15474   ;
15475   return 0;
15476 }
15477
15478 _ACEOF
15479
15480
15481         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15482         echo "obj-m := conftest.o" >build/Makefile
15483         modpost_flag=''
15484         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15485         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15486   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15487   (eval $ac_try) 2>&5
15488   ac_status=$?
15489   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15490   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15491   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15492   (eval $ac_try) 2>&5
15493   ac_status=$?
15494   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15495   (exit $ac_status); }; }; then
15496
15497                 { $as_echo "$as_me:$LINENO: result: yes" >&5
15498 $as_echo "yes" >&6; }
15499
15500 cat >>confdefs.h <<\_ACEOF
15501 #define HAVE_CONST_XATTR_HANDLER 1
15502 _ACEOF
15503
15504
15505 else
15506   $as_echo "$as_me: failed program was:" >&5
15507 sed 's/^/| /' conftest.$ac_ext >&5
15508
15509                 { $as_echo "$as_me:$LINENO: result: no" >&5
15510 $as_echo "no" >&6; }
15511
15512
15513
15514 fi
15515
15516         rm -Rf build
15517
15518
15519
15520
15521         { $as_echo "$as_me:$LINENO: checking whether xattr_handler->get() wants dentry" >&5
15522 $as_echo_n "checking whether xattr_handler->get() wants dentry... " >&6; }
15523
15524
15525 cat confdefs.h - <<_ACEOF >conftest.c
15526 /* confdefs.h.  */
15527 _ACEOF
15528 cat confdefs.h >>conftest.$ac_ext
15529 cat >>conftest.$ac_ext <<_ACEOF
15530 /* end confdefs.h.  */
15531
15532
15533                 #include <linux/xattr.h>
15534
15535 int
15536 main (void)
15537 {
15538
15539                 int (*get)(struct dentry *dentry, const char *name,
15540                     void *buffer, size_t size, int handler_flags) = NULL;
15541                 struct xattr_handler xops __attribute__ ((unused));
15542
15543                 xops.get = get;
15544
15545   ;
15546   return 0;
15547 }
15548
15549 _ACEOF
15550
15551
15552         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15553         echo "obj-m := conftest.o" >build/Makefile
15554         modpost_flag=''
15555         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15556         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15557   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15558   (eval $ac_try) 2>&5
15559   ac_status=$?
15560   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15561   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15562   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15563   (eval $ac_try) 2>&5
15564   ac_status=$?
15565   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15566   (exit $ac_status); }; }; then
15567
15568                 { $as_echo "$as_me:$LINENO: result: yes" >&5
15569 $as_echo "yes" >&6; }
15570
15571 cat >>confdefs.h <<\_ACEOF
15572 #define HAVE_DENTRY_XATTR_GET 1
15573 _ACEOF
15574
15575
15576 else
15577   $as_echo "$as_me: failed program was:" >&5
15578 sed 's/^/| /' conftest.$ac_ext >&5
15579
15580                 { $as_echo "$as_me:$LINENO: result: no" >&5
15581 $as_echo "no" >&6; }
15582
15583
15584
15585 fi
15586
15587         rm -Rf build
15588
15589
15590
15591
15592         { $as_echo "$as_me:$LINENO: checking whether xattr_handler->set() wants dentry" >&5
15593 $as_echo_n "checking whether xattr_handler->set() wants dentry... " >&6; }
15594
15595
15596 cat confdefs.h - <<_ACEOF >conftest.c
15597 /* confdefs.h.  */
15598 _ACEOF
15599 cat confdefs.h >>conftest.$ac_ext
15600 cat >>conftest.$ac_ext <<_ACEOF
15601 /* end confdefs.h.  */
15602
15603
15604                 #include <linux/xattr.h>
15605
15606 int
15607 main (void)
15608 {
15609
15610                 int (*set)(struct dentry *dentry, const char *name,
15611                     const void *buffer, size_t size, int flags,
15612                     int handler_flags) = NULL;
15613                 struct xattr_handler xops __attribute__ ((unused));
15614
15615                 xops.set = set;
15616
15617   ;
15618   return 0;
15619 }
15620
15621 _ACEOF
15622
15623
15624         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15625         echo "obj-m := conftest.o" >build/Makefile
15626         modpost_flag=''
15627         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15628         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15629   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15630   (eval $ac_try) 2>&5
15631   ac_status=$?
15632   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15633   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15634   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15635   (eval $ac_try) 2>&5
15636   ac_status=$?
15637   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15638   (exit $ac_status); }; }; then
15639
15640                 { $as_echo "$as_me:$LINENO: result: yes" >&5
15641 $as_echo "yes" >&6; }
15642
15643 cat >>confdefs.h <<\_ACEOF
15644 #define HAVE_DENTRY_XATTR_SET 1
15645 _ACEOF
15646
15647
15648 else
15649   $as_echo "$as_me: failed program was:" >&5
15650 sed 's/^/| /' conftest.$ac_ext >&5
15651
15652                 { $as_echo "$as_me:$LINENO: result: no" >&5
15653 $as_echo "no" >&6; }
15654
15655
15656
15657 fi
15658
15659         rm -Rf build
15660
15661
15662
15663
15664         { $as_echo "$as_me:$LINENO: checking whether sops->show_options() wants dentry" >&5
15665 $as_echo_n "checking whether sops->show_options() wants dentry... " >&6; }
15666
15667
15668
15669 cat confdefs.h - <<_ACEOF >conftest.c
15670 /* confdefs.h.  */
15671 _ACEOF
15672 cat confdefs.h >>conftest.$ac_ext
15673 cat >>conftest.$ac_ext <<_ACEOF
15674 /* end confdefs.h.  */
15675
15676
15677                 #include <linux/fs.h>
15678
15679                 int show_options (struct seq_file * x, struct dentry * y) { return 0; };
15680                 static struct super_operations sops __attribute__ ((unused)) = {
15681                         .show_options = show_options,
15682                 };
15683
15684 int
15685 main (void)
15686 {
15687
15688
15689   ;
15690   return 0;
15691 }
15692
15693 _ACEOF
15694
15695
15696         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15697         echo "obj-m := conftest.o" >build/Makefile
15698         modpost_flag=''
15699         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15700         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15701   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15702   (eval $ac_try) 2>&5
15703   ac_status=$?
15704   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15705   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15706   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15707   (eval $ac_try) 2>&5
15708   ac_status=$?
15709   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15710   (exit $ac_status); }; }; then
15711
15712                 { $as_echo "$as_me:$LINENO: result: yes" >&5
15713 $as_echo "yes" >&6; }
15714
15715 cat >>confdefs.h <<\_ACEOF
15716 #define HAVE_SHOW_OPTIONS_WITH_DENTRY 1
15717 _ACEOF
15718
15719
15720 else
15721   $as_echo "$as_me: failed program was:" >&5
15722 sed 's/^/| /' conftest.$ac_ext >&5
15723
15724                 { $as_echo "$as_me:$LINENO: result: no" >&5
15725 $as_echo "no" >&6; }
15726
15727
15728
15729 fi
15730
15731         rm -Rf build
15732
15733
15734
15735
15736         { $as_echo "$as_me:$LINENO: checking whether fops->fsync() wants" >&5
15737 $as_echo_n "checking whether fops->fsync() wants... " >&6; }
15738
15739
15740
15741 cat confdefs.h - <<_ACEOF >conftest.c
15742 /* confdefs.h.  */
15743 _ACEOF
15744 cat confdefs.h >>conftest.$ac_ext
15745 cat >>conftest.$ac_ext <<_ACEOF
15746 /* end confdefs.h.  */
15747
15748
15749                 #include <linux/fs.h>
15750
15751 int
15752 main (void)
15753 {
15754
15755                 int (*fsync) (struct file *, struct dentry *, int) = NULL;
15756                 struct file_operations fops __attribute__ ((unused));
15757
15758                 fops.fsync = fsync;
15759
15760   ;
15761   return 0;
15762 }
15763
15764 _ACEOF
15765
15766
15767         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15768         echo "obj-m := conftest.o" >build/Makefile
15769         modpost_flag=''
15770         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15771         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15772   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15773   (eval $ac_try) 2>&5
15774   ac_status=$?
15775   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15776   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15777   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15778   (eval $ac_try) 2>&5
15779   ac_status=$?
15780   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15781   (exit $ac_status); }; }; then
15782
15783                 { $as_echo "$as_me:$LINENO: result: dentry" >&5
15784 $as_echo "dentry" >&6; }
15785
15786 cat >>confdefs.h <<\_ACEOF
15787 #define HAVE_FSYNC_WITH_DENTRY 1
15788 _ACEOF
15789
15790
15791 else
15792   $as_echo "$as_me: failed program was:" >&5
15793 sed 's/^/| /' conftest.$ac_ext >&5
15794
15795
15796
15797
15798 fi
15799
15800         rm -Rf build
15801
15802
15803
15804
15805
15806
15807 cat confdefs.h - <<_ACEOF >conftest.c
15808 /* confdefs.h.  */
15809 _ACEOF
15810 cat confdefs.h >>conftest.$ac_ext
15811 cat >>conftest.$ac_ext <<_ACEOF
15812 /* end confdefs.h.  */
15813
15814
15815                 #include <linux/fs.h>
15816
15817 int
15818 main (void)
15819 {
15820
15821                 int (*fsync) (struct file *, int) = NULL;
15822                 struct file_operations fops __attribute__ ((unused));
15823
15824                 fops.fsync = fsync;
15825
15826   ;
15827   return 0;
15828 }
15829
15830 _ACEOF
15831
15832
15833         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15834         echo "obj-m := conftest.o" >build/Makefile
15835         modpost_flag=''
15836         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15837         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15838   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15839   (eval $ac_try) 2>&5
15840   ac_status=$?
15841   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15842   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15844   (eval $ac_try) 2>&5
15845   ac_status=$?
15846   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15847   (exit $ac_status); }; }; then
15848
15849                 { $as_echo "$as_me:$LINENO: result: no dentry" >&5
15850 $as_echo "no dentry" >&6; }
15851
15852 cat >>confdefs.h <<\_ACEOF
15853 #define HAVE_FSYNC_WITHOUT_DENTRY 1
15854 _ACEOF
15855
15856
15857 else
15858   $as_echo "$as_me: failed program was:" >&5
15859 sed 's/^/| /' conftest.$ac_ext >&5
15860
15861
15862
15863
15864 fi
15865
15866         rm -Rf build
15867
15868
15869
15870
15871
15872
15873 cat confdefs.h - <<_ACEOF >conftest.c
15874 /* confdefs.h.  */
15875 _ACEOF
15876 cat confdefs.h >>conftest.$ac_ext
15877 cat >>conftest.$ac_ext <<_ACEOF
15878 /* end confdefs.h.  */
15879
15880
15881                 #include <linux/fs.h>
15882
15883 int
15884 main (void)
15885 {
15886
15887                 int (*fsync) (struct file *, loff_t, loff_t, int) = NULL;
15888                 struct file_operations fops __attribute__ ((unused));
15889
15890                 fops.fsync = fsync;
15891
15892   ;
15893   return 0;
15894 }
15895
15896 _ACEOF
15897
15898
15899         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15900         echo "obj-m := conftest.o" >build/Makefile
15901         modpost_flag=''
15902         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15903         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15904   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15905   (eval $ac_try) 2>&5
15906   ac_status=$?
15907   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15908   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15909   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15910   (eval $ac_try) 2>&5
15911   ac_status=$?
15912   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15913   (exit $ac_status); }; }; then
15914
15915                 { $as_echo "$as_me:$LINENO: result: range" >&5
15916 $as_echo "range" >&6; }
15917
15918 cat >>confdefs.h <<\_ACEOF
15919 #define HAVE_FSYNC_RANGE 1
15920 _ACEOF
15921
15922
15923 else
15924   $as_echo "$as_me: failed program was:" >&5
15925 sed 's/^/| /' conftest.$ac_ext >&5
15926
15927
15928
15929
15930 fi
15931
15932         rm -Rf build
15933
15934
15935
15936
15937
15938
15939 cat confdefs.h - <<_ACEOF >conftest.c
15940 /* confdefs.h.  */
15941 _ACEOF
15942 cat confdefs.h >>conftest.$ac_ext
15943 cat >>conftest.$ac_ext <<_ACEOF
15944 /* end confdefs.h.  */
15945
15946
15947                 #include <linux/fs.h>
15948
15949 int
15950 main (void)
15951 {
15952
15953                 int (*fsync) (struct file *, struct dentry *, int) = NULL;
15954                 file_operations_no_const fops __attribute__ ((unused));
15955
15956                 fops.fsync = fsync;
15957
15958   ;
15959   return 0;
15960 }
15961
15962 _ACEOF
15963
15964
15965         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
15966         echo "obj-m := conftest.o" >build/Makefile
15967         modpost_flag=''
15968         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
15969         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
15970   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15971   (eval $ac_try) 2>&5
15972   ac_status=$?
15973   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15974   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
15975   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15976   (eval $ac_try) 2>&5
15977   ac_status=$?
15978   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15979   (exit $ac_status); }; }; then
15980
15981                 { $as_echo "$as_me:$LINENO: result: dentry" >&5
15982 $as_echo "dentry" >&6; }
15983
15984 cat >>confdefs.h <<\_ACEOF
15985 #define HAVE_FSYNC_WITH_DENTRY 1
15986 _ACEOF
15987
15988
15989 else
15990   $as_echo "$as_me: failed program was:" >&5
15991 sed 's/^/| /' conftest.$ac_ext >&5
15992
15993
15994
15995
15996 fi
15997
15998         rm -Rf build
15999
16000
16001
16002
16003
16004
16005 cat confdefs.h - <<_ACEOF >conftest.c
16006 /* confdefs.h.  */
16007 _ACEOF
16008 cat confdefs.h >>conftest.$ac_ext
16009 cat >>conftest.$ac_ext <<_ACEOF
16010 /* end confdefs.h.  */
16011
16012
16013                 #include <linux/fs.h>
16014
16015 int
16016 main (void)
16017 {
16018
16019                 int (*fsync) (struct file *, int) = NULL;
16020                 file_operations_no_const fops __attribute__ ((unused));
16021
16022                 fops.fsync = fsync;
16023
16024   ;
16025   return 0;
16026 }
16027
16028 _ACEOF
16029
16030
16031         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16032         echo "obj-m := conftest.o" >build/Makefile
16033         modpost_flag=''
16034         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16035         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16036   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16037   (eval $ac_try) 2>&5
16038   ac_status=$?
16039   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16040   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16041   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16042   (eval $ac_try) 2>&5
16043   ac_status=$?
16044   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16045   (exit $ac_status); }; }; then
16046
16047                 { $as_echo "$as_me:$LINENO: result: no dentry" >&5
16048 $as_echo "no dentry" >&6; }
16049
16050 cat >>confdefs.h <<\_ACEOF
16051 #define HAVE_FSYNC_WITHOUT_DENTRY 1
16052 _ACEOF
16053
16054
16055 else
16056   $as_echo "$as_me: failed program was:" >&5
16057 sed 's/^/| /' conftest.$ac_ext >&5
16058
16059
16060
16061
16062 fi
16063
16064         rm -Rf build
16065
16066
16067
16068
16069
16070
16071 cat confdefs.h - <<_ACEOF >conftest.c
16072 /* confdefs.h.  */
16073 _ACEOF
16074 cat confdefs.h >>conftest.$ac_ext
16075 cat >>conftest.$ac_ext <<_ACEOF
16076 /* end confdefs.h.  */
16077
16078
16079                 #include <linux/fs.h>
16080
16081 int
16082 main (void)
16083 {
16084
16085                 int (*fsync) (struct file *, loff_t, loff_t, int) = NULL;
16086                 file_operations_no_const fops __attribute__ ((unused));
16087
16088                 fops.fsync = fsync;
16089
16090   ;
16091   return 0;
16092 }
16093
16094 _ACEOF
16095
16096
16097         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16098         echo "obj-m := conftest.o" >build/Makefile
16099         modpost_flag=''
16100         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16101         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16102   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16103   (eval $ac_try) 2>&5
16104   ac_status=$?
16105   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16106   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16107   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16108   (eval $ac_try) 2>&5
16109   ac_status=$?
16110   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16111   (exit $ac_status); }; }; then
16112
16113                 { $as_echo "$as_me:$LINENO: result: range" >&5
16114 $as_echo "range" >&6; }
16115
16116 cat >>confdefs.h <<\_ACEOF
16117 #define HAVE_FSYNC_RANGE 1
16118 _ACEOF
16119
16120
16121 else
16122   $as_echo "$as_me: failed program was:" >&5
16123 sed 's/^/| /' conftest.$ac_ext >&5
16124
16125
16126
16127
16128 fi
16129
16130         rm -Rf build
16131
16132
16133
16134
16135
16136         { $as_echo "$as_me:$LINENO: checking whether sops->evict_inode() exists" >&5
16137 $as_echo_n "checking whether sops->evict_inode() exists... " >&6; }
16138
16139
16140 cat confdefs.h - <<_ACEOF >conftest.c
16141 /* confdefs.h.  */
16142 _ACEOF
16143 cat confdefs.h >>conftest.$ac_ext
16144 cat >>conftest.$ac_ext <<_ACEOF
16145 /* end confdefs.h.  */
16146
16147
16148                 #include <linux/fs.h>
16149                 void evict_inode (struct inode * t) { return; }
16150                 static struct super_operations sops __attribute__ ((unused)) = {
16151                         .evict_inode = evict_inode,
16152                 };
16153
16154 int
16155 main (void)
16156 {
16157
16158
16159   ;
16160   return 0;
16161 }
16162
16163 _ACEOF
16164
16165
16166         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16167         echo "obj-m := conftest.o" >build/Makefile
16168         modpost_flag=''
16169         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16170         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16171   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16172   (eval $ac_try) 2>&5
16173   ac_status=$?
16174   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16175   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16176   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16177   (eval $ac_try) 2>&5
16178   ac_status=$?
16179   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16180   (exit $ac_status); }; }; then
16181
16182                 { $as_echo "$as_me:$LINENO: result: yes" >&5
16183 $as_echo "yes" >&6; }
16184
16185 cat >>confdefs.h <<\_ACEOF
16186 #define HAVE_EVICT_INODE 1
16187 _ACEOF
16188
16189
16190 else
16191   $as_echo "$as_me: failed program was:" >&5
16192 sed 's/^/| /' conftest.$ac_ext >&5
16193
16194                 { $as_echo "$as_me:$LINENO: result: no" >&5
16195 $as_echo "no" >&6; }
16196
16197
16198
16199 fi
16200
16201         rm -Rf build
16202
16203
16204
16205
16206         { $as_echo "$as_me:$LINENO: checking whether sops->nr_cached_objects() exists" >&5
16207 $as_echo_n "checking whether sops->nr_cached_objects() exists... " >&6; }
16208
16209
16210 cat confdefs.h - <<_ACEOF >conftest.c
16211 /* confdefs.h.  */
16212 _ACEOF
16213 cat confdefs.h >>conftest.$ac_ext
16214 cat >>conftest.$ac_ext <<_ACEOF
16215 /* end confdefs.h.  */
16216
16217
16218                 #include <linux/fs.h>
16219
16220 int
16221 main (void)
16222 {
16223
16224                 int (*nr_cached_objects)(struct super_block *)
16225                         __attribute__ ((unused)) = NULL;
16226                 struct super_operations sops __attribute__ ((unused)) = {
16227                         .nr_cached_objects = nr_cached_objects,
16228                 };
16229
16230   ;
16231   return 0;
16232 }
16233
16234 _ACEOF
16235
16236
16237         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16238         echo "obj-m := conftest.o" >build/Makefile
16239         modpost_flag=''
16240         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16241         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16242   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16243   (eval $ac_try) 2>&5
16244   ac_status=$?
16245   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16246   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16247   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16248   (eval $ac_try) 2>&5
16249   ac_status=$?
16250   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16251   (exit $ac_status); }; }; then
16252
16253                 { $as_echo "$as_me:$LINENO: result: yes" >&5
16254 $as_echo "yes" >&6; }
16255
16256 cat >>confdefs.h <<\_ACEOF
16257 #define HAVE_NR_CACHED_OBJECTS 1
16258 _ACEOF
16259
16260
16261 else
16262   $as_echo "$as_me: failed program was:" >&5
16263 sed 's/^/| /' conftest.$ac_ext >&5
16264
16265                 { $as_echo "$as_me:$LINENO: result: no" >&5
16266 $as_echo "no" >&6; }
16267
16268
16269
16270 fi
16271
16272         rm -Rf build
16273
16274
16275
16276
16277         { $as_echo "$as_me:$LINENO: checking whether sops->free_cached_objects() exists" >&5
16278 $as_echo_n "checking whether sops->free_cached_objects() exists... " >&6; }
16279
16280
16281 cat confdefs.h - <<_ACEOF >conftest.c
16282 /* confdefs.h.  */
16283 _ACEOF
16284 cat confdefs.h >>conftest.$ac_ext
16285 cat >>conftest.$ac_ext <<_ACEOF
16286 /* end confdefs.h.  */
16287
16288
16289                 #include <linux/fs.h>
16290
16291 int
16292 main (void)
16293 {
16294
16295                 void (*free_cached_objects)(struct super_block *, int)
16296                         __attribute__ ((unused)) = NULL;
16297                 struct super_operations sops __attribute__ ((unused)) = {
16298                         .free_cached_objects = free_cached_objects,
16299                 };
16300
16301   ;
16302   return 0;
16303 }
16304
16305 _ACEOF
16306
16307
16308         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16309         echo "obj-m := conftest.o" >build/Makefile
16310         modpost_flag=''
16311         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16312         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16313   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16314   (eval $ac_try) 2>&5
16315   ac_status=$?
16316   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16317   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16318   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16319   (eval $ac_try) 2>&5
16320   ac_status=$?
16321   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16322   (exit $ac_status); }; }; then
16323
16324                 { $as_echo "$as_me:$LINENO: result: yes" >&5
16325 $as_echo "yes" >&6; }
16326
16327 cat >>confdefs.h <<\_ACEOF
16328 #define HAVE_FREE_CACHED_OBJECTS 1
16329 _ACEOF
16330
16331
16332 else
16333   $as_echo "$as_me: failed program was:" >&5
16334 sed 's/^/| /' conftest.$ac_ext >&5
16335
16336                 { $as_echo "$as_me:$LINENO: result: no" >&5
16337 $as_echo "no" >&6; }
16338
16339
16340
16341 fi
16342
16343         rm -Rf build
16344
16345
16346
16347
16348
16349         { $as_echo "$as_me:$LINENO: checking whether fops->fallocate() exists" >&5
16350 $as_echo_n "checking whether fops->fallocate() exists... " >&6; }
16351
16352
16353 cat confdefs.h - <<_ACEOF >conftest.c
16354 /* confdefs.h.  */
16355 _ACEOF
16356 cat confdefs.h >>conftest.$ac_ext
16357 cat >>conftest.$ac_ext <<_ACEOF
16358 /* end confdefs.h.  */
16359
16360
16361                 #include <linux/fs.h>
16362
16363 int
16364 main (void)
16365 {
16366
16367                 long (*fallocate) (struct file *, int, loff_t, loff_t) = NULL;
16368                 struct file_operations fops __attribute__ ((unused)) = {
16369                         .fallocate = fallocate,
16370                 };
16371
16372   ;
16373   return 0;
16374 }
16375
16376 _ACEOF
16377
16378
16379         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16380         echo "obj-m := conftest.o" >build/Makefile
16381         modpost_flag=''
16382         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16383         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16384   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16385   (eval $ac_try) 2>&5
16386   ac_status=$?
16387   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16388   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16389   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16390   (eval $ac_try) 2>&5
16391   ac_status=$?
16392   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16393   (exit $ac_status); }; }; then
16394
16395                 { $as_echo "$as_me:$LINENO: result: yes" >&5
16396 $as_echo "yes" >&6; }
16397
16398 cat >>confdefs.h <<\_ACEOF
16399 #define HAVE_FILE_FALLOCATE 1
16400 _ACEOF
16401
16402
16403 else
16404   $as_echo "$as_me: failed program was:" >&5
16405 sed 's/^/| /' conftest.$ac_ext >&5
16406
16407                 { $as_echo "$as_me:$LINENO: result: no" >&5
16408 $as_echo "no" >&6; }
16409
16410
16411
16412 fi
16413
16414         rm -Rf build
16415
16416
16417
16418
16419         { $as_echo "$as_me:$LINENO: checking whether iops->fallocate() exists" >&5
16420 $as_echo_n "checking whether iops->fallocate() exists... " >&6; }
16421
16422
16423 cat confdefs.h - <<_ACEOF >conftest.c
16424 /* confdefs.h.  */
16425 _ACEOF
16426 cat confdefs.h >>conftest.$ac_ext
16427 cat >>conftest.$ac_ext <<_ACEOF
16428 /* end confdefs.h.  */
16429
16430
16431                 #include <linux/fs.h>
16432
16433 int
16434 main (void)
16435 {
16436
16437                 long (*fallocate) (struct inode *, int, loff_t, loff_t) = NULL;
16438                 struct inode_operations fops __attribute__ ((unused)) = {
16439                         .fallocate = fallocate,
16440                 };
16441
16442   ;
16443   return 0;
16444 }
16445
16446 _ACEOF
16447
16448
16449         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16450         echo "obj-m := conftest.o" >build/Makefile
16451         modpost_flag=''
16452         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16453         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16454   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16455   (eval $ac_try) 2>&5
16456   ac_status=$?
16457   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16458   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16459   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16460   (eval $ac_try) 2>&5
16461   ac_status=$?
16462   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16463   (exit $ac_status); }; }; then
16464
16465                 { $as_echo "$as_me:$LINENO: result: yes" >&5
16466 $as_echo "yes" >&6; }
16467
16468 cat >>confdefs.h <<\_ACEOF
16469 #define HAVE_INODE_FALLOCATE 1
16470 _ACEOF
16471
16472
16473 else
16474   $as_echo "$as_me: failed program was:" >&5
16475 sed 's/^/| /' conftest.$ac_ext >&5
16476
16477                 { $as_echo "$as_me:$LINENO: result: no" >&5
16478 $as_echo "no" >&6; }
16479
16480
16481
16482 fi
16483
16484         rm -Rf build
16485
16486
16487
16488
16489         { $as_echo "$as_me:$LINENO: checking whether fops->fallocate() exists" >&5
16490 $as_echo_n "checking whether fops->fallocate() exists... " >&6; }
16491
16492
16493 cat confdefs.h - <<_ACEOF >conftest.c
16494 /* confdefs.h.  */
16495 _ACEOF
16496 cat confdefs.h >>conftest.$ac_ext
16497 cat >>conftest.$ac_ext <<_ACEOF
16498 /* end confdefs.h.  */
16499
16500
16501                 #include <linux/fs.h>
16502
16503 int
16504 main (void)
16505 {
16506
16507                 long (*fallocate) (struct file *, int, loff_t, loff_t) = NULL;
16508                 struct file_operations_no_const fops __attribute__ ((unused)) = {
16509                         .fallocate = fallocate,
16510                 };
16511
16512   ;
16513   return 0;
16514 }
16515
16516 _ACEOF
16517
16518
16519         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16520         echo "obj-m := conftest.o" >build/Makefile
16521         modpost_flag=''
16522         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16523         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16524   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16525   (eval $ac_try) 2>&5
16526   ac_status=$?
16527   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16528   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16529   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16530   (eval $ac_try) 2>&5
16531   ac_status=$?
16532   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16533   (exit $ac_status); }; }; then
16534
16535                 { $as_echo "$as_me:$LINENO: result: yes" >&5
16536 $as_echo "yes" >&6; }
16537
16538 cat >>confdefs.h <<\_ACEOF
16539 #define HAVE_FILE_FALLOCATE 1
16540 _ACEOF
16541
16542
16543 else
16544   $as_echo "$as_me: failed program was:" >&5
16545 sed 's/^/| /' conftest.$ac_ext >&5
16546
16547                 { $as_echo "$as_me:$LINENO: result: no" >&5
16548 $as_echo "no" >&6; }
16549
16550
16551
16552 fi
16553
16554         rm -Rf build
16555
16556
16557
16558
16559
16560         { $as_echo "$as_me:$LINENO: checking whether iops->truncate_range() exists" >&5
16561 $as_echo_n "checking whether iops->truncate_range() exists... " >&6; }
16562
16563
16564 cat confdefs.h - <<_ACEOF >conftest.c
16565 /* confdefs.h.  */
16566 _ACEOF
16567 cat confdefs.h >>conftest.$ac_ext
16568 cat >>conftest.$ac_ext <<_ACEOF
16569 /* end confdefs.h.  */
16570
16571
16572                 #include <linux/fs.h>
16573                 void truncate_range(struct inode *inode, loff_t start,
16574                                     loff_t end) { return; }
16575                 static struct inode_operations iops __attribute__ ((unused)) = {
16576                         .truncate_range = truncate_range,
16577                 };
16578
16579 int
16580 main (void)
16581 {
16582
16583
16584   ;
16585   return 0;
16586 }
16587
16588 _ACEOF
16589
16590
16591         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16592         echo "obj-m := conftest.o" >build/Makefile
16593         modpost_flag=''
16594         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16595         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16596   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16597   (eval $ac_try) 2>&5
16598   ac_status=$?
16599   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16600   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16601   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16602   (eval $ac_try) 2>&5
16603   ac_status=$?
16604   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16605   (exit $ac_status); }; }; then
16606
16607                 { $as_echo "$as_me:$LINENO: result: yes" >&5
16608 $as_echo "yes" >&6; }
16609
16610 cat >>confdefs.h <<\_ACEOF
16611 #define HAVE_INODE_TRUNCATE_RANGE 1
16612 _ACEOF
16613
16614
16615 else
16616   $as_echo "$as_me: failed program was:" >&5
16617 sed 's/^/| /' conftest.$ac_ext >&5
16618
16619                 { $as_echo "$as_me:$LINENO: result: no" >&5
16620 $as_echo "no" >&6; }
16621
16622
16623
16624 fi
16625
16626         rm -Rf build
16627
16628
16629
16630
16631         { $as_echo "$as_me:$LINENO: checking whether iops->create()/mkdir()/mknod() take umode_t" >&5
16632 $as_echo_n "checking whether iops->create()/mkdir()/mknod() take umode_t... " >&6; }
16633
16634
16635 cat confdefs.h - <<_ACEOF >conftest.c
16636 /* confdefs.h.  */
16637 _ACEOF
16638 cat confdefs.h >>conftest.$ac_ext
16639 cat >>conftest.$ac_ext <<_ACEOF
16640 /* end confdefs.h.  */
16641
16642
16643                 #include <linux/fs.h>
16644
16645 int
16646 main (void)
16647 {
16648
16649                 int (*create) (struct inode *, struct dentry *, umode_t,
16650                     struct nameidata *) = NULL;
16651                 struct inode_operations iops __attribute__ ((unused)) = {
16652                         .create = create,
16653                 };
16654
16655   ;
16656   return 0;
16657 }
16658
16659 _ACEOF
16660
16661
16662         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16663         echo "obj-m := conftest.o" >build/Makefile
16664         modpost_flag=''
16665         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16666         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16667   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16668   (eval $ac_try) 2>&5
16669   ac_status=$?
16670   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16671   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16672   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16673   (eval $ac_try) 2>&5
16674   ac_status=$?
16675   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16676   (exit $ac_status); }; }; then
16677
16678                 { $as_echo "$as_me:$LINENO: result: yes" >&5
16679 $as_echo "yes" >&6; }
16680
16681 cat >>confdefs.h <<\_ACEOF
16682 #define HAVE_CREATE_UMODE_T 1
16683 _ACEOF
16684
16685
16686 else
16687   $as_echo "$as_me: failed program was:" >&5
16688 sed 's/^/| /' conftest.$ac_ext >&5
16689
16690                 { $as_echo "$as_me:$LINENO: result: no" >&5
16691 $as_echo "no" >&6; }
16692
16693
16694
16695 fi
16696
16697         rm -Rf build
16698
16699
16700
16701
16702         { $as_echo "$as_me:$LINENO: checking whether dops->d_automount() exists" >&5
16703 $as_echo_n "checking whether dops->d_automount() exists... " >&6; }
16704
16705
16706 cat confdefs.h - <<_ACEOF >conftest.c
16707 /* confdefs.h.  */
16708 _ACEOF
16709 cat confdefs.h >>conftest.$ac_ext
16710 cat >>conftest.$ac_ext <<_ACEOF
16711 /* end confdefs.h.  */
16712
16713
16714                 #include <linux/dcache.h>
16715
16716 int
16717 main (void)
16718 {
16719
16720                 struct vfsmount *(*d_automount) (struct path *) = NULL;
16721                 struct dentry_operations dops __attribute__ ((unused)) = {
16722                         .d_automount = d_automount,
16723                 };
16724
16725   ;
16726   return 0;
16727 }
16728
16729 _ACEOF
16730
16731
16732         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16733         echo "obj-m := conftest.o" >build/Makefile
16734         modpost_flag=''
16735         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16736         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16737   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16738   (eval $ac_try) 2>&5
16739   ac_status=$?
16740   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16741   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16742   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16743   (eval $ac_try) 2>&5
16744   ac_status=$?
16745   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16746   (exit $ac_status); }; }; then
16747
16748                 { $as_echo "$as_me:$LINENO: result: yes" >&5
16749 $as_echo "yes" >&6; }
16750
16751 cat >>confdefs.h <<\_ACEOF
16752 #define HAVE_AUTOMOUNT 1
16753 _ACEOF
16754
16755
16756 else
16757   $as_echo "$as_me: failed program was:" >&5
16758 sed 's/^/| /' conftest.$ac_ext >&5
16759
16760                 { $as_echo "$as_me:$LINENO: result: no" >&5
16761 $as_echo "no" >&6; }
16762
16763
16764
16765 fi
16766
16767         rm -Rf build
16768
16769
16770
16771
16772         { $as_echo "$as_me:$LINENO: checking whether eops->encode_fh() wants inode" >&5
16773 $as_echo_n "checking whether eops->encode_fh() wants inode... " >&6; }
16774
16775
16776 cat confdefs.h - <<_ACEOF >conftest.c
16777 /* confdefs.h.  */
16778 _ACEOF
16779 cat confdefs.h >>conftest.$ac_ext
16780 cat >>conftest.$ac_ext <<_ACEOF
16781 /* end confdefs.h.  */
16782
16783
16784                 #include <linux/exportfs.h>
16785                 int encode_fh(struct inode *inode, __u32 *fh, int *max_len,
16786                               struct inode *parent) { return 0; }
16787                 static struct export_operations eops __attribute__ ((unused))={
16788                         .encode_fh = encode_fh,
16789                 };
16790
16791 int
16792 main (void)
16793 {
16794
16795
16796   ;
16797   return 0;
16798 }
16799
16800 _ACEOF
16801
16802
16803         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16804         echo "obj-m := conftest.o" >build/Makefile
16805         modpost_flag=''
16806         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16807         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16808   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16809   (eval $ac_try) 2>&5
16810   ac_status=$?
16811   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16812   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16813   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16814   (eval $ac_try) 2>&5
16815   ac_status=$?
16816   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16817   (exit $ac_status); }; }; then
16818
16819                 { $as_echo "$as_me:$LINENO: result: yes" >&5
16820 $as_echo "yes" >&6; }
16821
16822 cat >>confdefs.h <<\_ACEOF
16823 #define HAVE_ENCODE_FH_WITH_INODE 1
16824 _ACEOF
16825
16826
16827 else
16828   $as_echo "$as_me: failed program was:" >&5
16829 sed 's/^/| /' conftest.$ac_ext >&5
16830
16831                 { $as_echo "$as_me:$LINENO: result: no" >&5
16832 $as_echo "no" >&6; }
16833
16834
16835
16836 fi
16837
16838         rm -Rf build
16839
16840
16841
16842         { $as_echo "$as_me:$LINENO: checking whether clear_inode() is available" >&5
16843 $as_echo_n "checking whether clear_inode() is available... " >&6; }
16844
16845
16846
16847 cat confdefs.h - <<_ACEOF >conftest.c
16848 /* confdefs.h.  */
16849 _ACEOF
16850 cat confdefs.h >>conftest.$ac_ext
16851 cat >>conftest.$ac_ext <<_ACEOF
16852 /* end confdefs.h.  */
16853
16854
16855                 #include <linux/fs.h>
16856
16857 int
16858 main (void)
16859 {
16860
16861                 clear_inode(NULL);
16862
16863   ;
16864   return 0;
16865 }
16866
16867 _ACEOF
16868
16869
16870         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16871         echo "obj-m := conftest.o" >build/Makefile
16872         modpost_flag=''
16873         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16874         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16875   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16876   (eval $ac_try) 2>&5
16877   ac_status=$?
16878   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16879   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16880   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16881   (eval $ac_try) 2>&5
16882   ac_status=$?
16883   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16884   (exit $ac_status); }; }; then
16885   rc=0
16886 else
16887   $as_echo "$as_me: failed program was:" >&5
16888 sed 's/^/| /' conftest.$ac_ext >&5
16889  rc=1
16890
16891
16892 fi
16893
16894         rm -Rf build
16895
16896
16897         if test $rc -ne 0; then :
16898
16899                 { $as_echo "$as_me:$LINENO: result: no" >&5
16900 $as_echo "no" >&6; }
16901
16902         else
16903                 if test "x$enable_linux_builtin" != xyes; then
16904
16905         grep -q -E '[[:space:]]clear_inode[[:space:]]' \
16906                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
16907         rc=$?
16908         if test $rc -ne 0; then
16909                 export=0
16910                 for file in fs/inode.c; do
16911                         grep -q -E "EXPORT_SYMBOL.*(clear_inode)" \
16912                                 "$LINUX/$file" 2>/dev/null
16913                         rc=$?
16914                         if test $rc -eq 0; then
16915                                 export=1
16916                                 break;
16917                         fi
16918                 done
16919                 if test $export -eq 0; then :
16920                         rc=1
16921                 else :
16922                         rc=0
16923                 fi
16924         else :
16925                 rc=0
16926         fi
16927
16928                 fi
16929                 if test $rc -ne 0; then :
16930
16931                 { $as_echo "$as_me:$LINENO: result: no" >&5
16932 $as_echo "no" >&6; }
16933
16934                 else :
16935
16936                 { $as_echo "$as_me:$LINENO: result: yes" >&5
16937 $as_echo "yes" >&6; }
16938
16939 cat >>confdefs.h <<\_ACEOF
16940 #define HAVE_CLEAR_INODE 1
16941 _ACEOF
16942
16943
16944                 fi
16945         fi
16946
16947
16948         { $as_echo "$as_me:$LINENO: checking whether insert_inode_locked() is available" >&5
16949 $as_echo_n "checking whether insert_inode_locked() is available... " >&6; }
16950
16951
16952
16953 cat confdefs.h - <<_ACEOF >conftest.c
16954 /* confdefs.h.  */
16955 _ACEOF
16956 cat confdefs.h >>conftest.$ac_ext
16957 cat >>conftest.$ac_ext <<_ACEOF
16958 /* end confdefs.h.  */
16959
16960
16961                 #include <linux/fs.h>
16962
16963 int
16964 main (void)
16965 {
16966
16967                 insert_inode_locked(NULL);
16968
16969   ;
16970   return 0;
16971 }
16972
16973 _ACEOF
16974
16975
16976         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
16977         echo "obj-m := conftest.o" >build/Makefile
16978         modpost_flag=''
16979         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
16980         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
16981   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16982   (eval $ac_try) 2>&5
16983   ac_status=$?
16984   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16985   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
16986   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16987   (eval $ac_try) 2>&5
16988   ac_status=$?
16989   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16990   (exit $ac_status); }; }; then
16991   rc=0
16992 else
16993   $as_echo "$as_me: failed program was:" >&5
16994 sed 's/^/| /' conftest.$ac_ext >&5
16995  rc=1
16996
16997
16998 fi
16999
17000         rm -Rf build
17001
17002
17003         if test $rc -ne 0; then :
17004
17005                 { $as_echo "$as_me:$LINENO: result: no" >&5
17006 $as_echo "no" >&6; }
17007
17008         else
17009                 if test "x$enable_linux_builtin" != xyes; then
17010
17011         grep -q -E '[[:space:]]insert_inode_locked[[:space:]]' \
17012                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
17013         rc=$?
17014         if test $rc -ne 0; then
17015                 export=0
17016                 for file in fs/inode.c; do
17017                         grep -q -E "EXPORT_SYMBOL.*(insert_inode_locked)" \
17018                                 "$LINUX/$file" 2>/dev/null
17019                         rc=$?
17020                         if test $rc -eq 0; then
17021                                 export=1
17022                                 break;
17023                         fi
17024                 done
17025                 if test $export -eq 0; then :
17026                         rc=1
17027                 else :
17028                         rc=0
17029                 fi
17030         else :
17031                 rc=0
17032         fi
17033
17034                 fi
17035                 if test $rc -ne 0; then :
17036
17037                 { $as_echo "$as_me:$LINENO: result: no" >&5
17038 $as_echo "no" >&6; }
17039
17040                 else :
17041
17042                 { $as_echo "$as_me:$LINENO: result: yes" >&5
17043 $as_echo "yes" >&6; }
17044
17045 cat >>confdefs.h <<\_ACEOF
17046 #define HAVE_INSERT_INODE_LOCKED 1
17047 _ACEOF
17048
17049
17050                 fi
17051         fi
17052
17053
17054         { $as_echo "$as_me:$LINENO: checking whether d_make_root() is available" >&5
17055 $as_echo_n "checking whether d_make_root() is available... " >&6; }
17056
17057
17058
17059 cat confdefs.h - <<_ACEOF >conftest.c
17060 /* confdefs.h.  */
17061 _ACEOF
17062 cat confdefs.h >>conftest.$ac_ext
17063 cat >>conftest.$ac_ext <<_ACEOF
17064 /* end confdefs.h.  */
17065
17066
17067                 #include <linux/dcache.h>
17068
17069 int
17070 main (void)
17071 {
17072
17073                 d_make_root(NULL);
17074
17075   ;
17076   return 0;
17077 }
17078
17079 _ACEOF
17080
17081
17082         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
17083         echo "obj-m := conftest.o" >build/Makefile
17084         modpost_flag=''
17085         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
17086         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
17087   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17088   (eval $ac_try) 2>&5
17089   ac_status=$?
17090   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17091   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
17092   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17093   (eval $ac_try) 2>&5
17094   ac_status=$?
17095   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17096   (exit $ac_status); }; }; then
17097   rc=0
17098 else
17099   $as_echo "$as_me: failed program was:" >&5
17100 sed 's/^/| /' conftest.$ac_ext >&5
17101  rc=1
17102
17103
17104 fi
17105
17106         rm -Rf build
17107
17108
17109         if test $rc -ne 0; then :
17110
17111                 { $as_echo "$as_me:$LINENO: result: no" >&5
17112 $as_echo "no" >&6; }
17113
17114         else
17115                 if test "x$enable_linux_builtin" != xyes; then
17116
17117         grep -q -E '[[:space:]]d_make_root[[:space:]]' \
17118                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
17119         rc=$?
17120         if test $rc -ne 0; then
17121                 export=0
17122                 for file in fs/dcache.c; do
17123                         grep -q -E "EXPORT_SYMBOL.*(d_make_root)" \
17124                                 "$LINUX/$file" 2>/dev/null
17125                         rc=$?
17126                         if test $rc -eq 0; then
17127                                 export=1
17128                                 break;
17129                         fi
17130                 done
17131                 if test $export -eq 0; then :
17132                         rc=1
17133                 else :
17134                         rc=0
17135                 fi
17136         else :
17137                 rc=0
17138         fi
17139
17140                 fi
17141                 if test $rc -ne 0; then :
17142
17143                 { $as_echo "$as_me:$LINENO: result: no" >&5
17144 $as_echo "no" >&6; }
17145
17146                 else :
17147
17148                 { $as_echo "$as_me:$LINENO: result: yes" >&5
17149 $as_echo "yes" >&6; }
17150
17151 cat >>confdefs.h <<\_ACEOF
17152 #define HAVE_D_MAKE_ROOT 1
17153 _ACEOF
17154
17155
17156                 fi
17157         fi
17158
17159
17160         { $as_echo "$as_me:$LINENO: checking whether d_obtain_alias() is available" >&5
17161 $as_echo_n "checking whether d_obtain_alias() is available... " >&6; }
17162
17163
17164
17165 cat confdefs.h - <<_ACEOF >conftest.c
17166 /* confdefs.h.  */
17167 _ACEOF
17168 cat confdefs.h >>conftest.$ac_ext
17169 cat >>conftest.$ac_ext <<_ACEOF
17170 /* end confdefs.h.  */
17171
17172
17173                 #include <linux/dcache.h>
17174
17175 int
17176 main (void)
17177 {
17178
17179                 d_obtain_alias(NULL);
17180
17181   ;
17182   return 0;
17183 }
17184
17185 _ACEOF
17186
17187
17188         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
17189         echo "obj-m := conftest.o" >build/Makefile
17190         modpost_flag=''
17191         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
17192         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
17193   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17194   (eval $ac_try) 2>&5
17195   ac_status=$?
17196   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17197   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
17198   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17199   (eval $ac_try) 2>&5
17200   ac_status=$?
17201   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17202   (exit $ac_status); }; }; then
17203   rc=0
17204 else
17205   $as_echo "$as_me: failed program was:" >&5
17206 sed 's/^/| /' conftest.$ac_ext >&5
17207  rc=1
17208
17209
17210 fi
17211
17212         rm -Rf build
17213
17214
17215         if test $rc -ne 0; then :
17216
17217                 { $as_echo "$as_me:$LINENO: result: no" >&5
17218 $as_echo "no" >&6; }
17219
17220         else
17221                 if test "x$enable_linux_builtin" != xyes; then
17222
17223         grep -q -E '[[:space:]]d_obtain_alias[[:space:]]' \
17224                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
17225         rc=$?
17226         if test $rc -ne 0; then
17227                 export=0
17228                 for file in fs/dcache.c; do
17229                         grep -q -E "EXPORT_SYMBOL.*(d_obtain_alias)" \
17230                                 "$LINUX/$file" 2>/dev/null
17231                         rc=$?
17232                         if test $rc -eq 0; then
17233                                 export=1
17234                                 break;
17235                         fi
17236                 done
17237                 if test $export -eq 0; then :
17238                         rc=1
17239                 else :
17240                         rc=0
17241                 fi
17242         else :
17243                 rc=0
17244         fi
17245
17246                 fi
17247                 if test $rc -ne 0; then :
17248
17249                 { $as_echo "$as_me:$LINENO: result: no" >&5
17250 $as_echo "no" >&6; }
17251
17252                 else :
17253
17254                 { $as_echo "$as_me:$LINENO: result: yes" >&5
17255 $as_echo "yes" >&6; }
17256
17257 cat >>confdefs.h <<\_ACEOF
17258 #define HAVE_D_OBTAIN_ALIAS 1
17259 _ACEOF
17260
17261
17262                 fi
17263         fi
17264
17265
17266         { $as_echo "$as_me:$LINENO: checking whether check_disk_size_change() is available" >&5
17267 $as_echo_n "checking whether check_disk_size_change() is available... " >&6; }
17268
17269
17270
17271 cat confdefs.h - <<_ACEOF >conftest.c
17272 /* confdefs.h.  */
17273 _ACEOF
17274 cat confdefs.h >>conftest.$ac_ext
17275 cat >>conftest.$ac_ext <<_ACEOF
17276 /* end confdefs.h.  */
17277
17278
17279                 #include <linux/fs.h>
17280
17281 int
17282 main (void)
17283 {
17284
17285                 check_disk_size_change(NULL, NULL);
17286
17287   ;
17288   return 0;
17289 }
17290
17291 _ACEOF
17292
17293
17294         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
17295         echo "obj-m := conftest.o" >build/Makefile
17296         modpost_flag=''
17297         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
17298         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
17299   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17300   (eval $ac_try) 2>&5
17301   ac_status=$?
17302   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17303   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
17304   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17305   (eval $ac_try) 2>&5
17306   ac_status=$?
17307   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17308   (exit $ac_status); }; }; then
17309   rc=0
17310 else
17311   $as_echo "$as_me: failed program was:" >&5
17312 sed 's/^/| /' conftest.$ac_ext >&5
17313  rc=1
17314
17315
17316 fi
17317
17318         rm -Rf build
17319
17320
17321         if test $rc -ne 0; then :
17322
17323                 { $as_echo "$as_me:$LINENO: result: no" >&5
17324 $as_echo "no" >&6; }
17325
17326         else
17327                 if test "x$enable_linux_builtin" != xyes; then
17328
17329         grep -q -E '[[:space:]]check_disk_size_change[[:space:]]' \
17330                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
17331         rc=$?
17332         if test $rc -ne 0; then
17333                 export=0
17334                 for file in fs/block_dev.c; do
17335                         grep -q -E "EXPORT_SYMBOL.*(check_disk_size_change)" \
17336                                 "$LINUX/$file" 2>/dev/null
17337                         rc=$?
17338                         if test $rc -eq 0; then
17339                                 export=1
17340                                 break;
17341                         fi
17342                 done
17343                 if test $export -eq 0; then :
17344                         rc=1
17345                 else :
17346                         rc=0
17347                 fi
17348         else :
17349                 rc=0
17350         fi
17351
17352                 fi
17353                 if test $rc -ne 0; then :
17354
17355                 { $as_echo "$as_me:$LINENO: result: no" >&5
17356 $as_echo "no" >&6; }
17357
17358                 else :
17359
17360                 { $as_echo "$as_me:$LINENO: result: yes" >&5
17361 $as_echo "yes" >&6; }
17362
17363 cat >>confdefs.h <<\_ACEOF
17364 #define HAVE_CHECK_DISK_SIZE_CHANGE 1
17365 _ACEOF
17366
17367
17368                 fi
17369         fi
17370
17371
17372         { $as_echo "$as_me:$LINENO: checking whether truncate_setsize() is available" >&5
17373 $as_echo_n "checking whether truncate_setsize() is available... " >&6; }
17374
17375
17376
17377 cat confdefs.h - <<_ACEOF >conftest.c
17378 /* confdefs.h.  */
17379 _ACEOF
17380 cat confdefs.h >>conftest.$ac_ext
17381 cat >>conftest.$ac_ext <<_ACEOF
17382 /* end confdefs.h.  */
17383
17384
17385                 #include <linux/mm.h>
17386
17387 int
17388 main (void)
17389 {
17390
17391                 truncate_setsize(NULL, 0);
17392
17393   ;
17394   return 0;
17395 }
17396
17397 _ACEOF
17398
17399
17400         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
17401         echo "obj-m := conftest.o" >build/Makefile
17402         modpost_flag=''
17403         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
17404         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
17405   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17406   (eval $ac_try) 2>&5
17407   ac_status=$?
17408   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17409   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
17410   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17411   (eval $ac_try) 2>&5
17412   ac_status=$?
17413   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17414   (exit $ac_status); }; }; then
17415   rc=0
17416 else
17417   $as_echo "$as_me: failed program was:" >&5
17418 sed 's/^/| /' conftest.$ac_ext >&5
17419  rc=1
17420
17421
17422 fi
17423
17424         rm -Rf build
17425
17426
17427         if test $rc -ne 0; then :
17428
17429                 { $as_echo "$as_me:$LINENO: result: no" >&5
17430 $as_echo "no" >&6; }
17431
17432         else
17433                 if test "x$enable_linux_builtin" != xyes; then
17434
17435         grep -q -E '[[:space:]]truncate_setsize[[:space:]]' \
17436                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
17437         rc=$?
17438         if test $rc -ne 0; then
17439                 export=0
17440                 for file in mm/truncate.c; do
17441                         grep -q -E "EXPORT_SYMBOL.*(truncate_setsize)" \
17442                                 "$LINUX/$file" 2>/dev/null
17443                         rc=$?
17444                         if test $rc -eq 0; then
17445                                 export=1
17446                                 break;
17447                         fi
17448                 done
17449                 if test $export -eq 0; then :
17450                         rc=1
17451                 else :
17452                         rc=0
17453                 fi
17454         else :
17455                 rc=0
17456         fi
17457
17458                 fi
17459                 if test $rc -ne 0; then :
17460
17461                 { $as_echo "$as_me:$LINENO: result: no" >&5
17462 $as_echo "no" >&6; }
17463
17464                 else :
17465
17466                 { $as_echo "$as_me:$LINENO: result: yes" >&5
17467 $as_echo "yes" >&6; }
17468
17469 cat >>confdefs.h <<\_ACEOF
17470 #define HAVE_TRUNCATE_SETSIZE 1
17471 _ACEOF
17472
17473
17474                 fi
17475         fi
17476
17477
17478
17479         { $as_echo "$as_me:$LINENO: checking whether security_inode_init_security wants 6 args" >&5
17480 $as_echo_n "checking whether security_inode_init_security wants 6 args... " >&6; }
17481         tmp_flags="$EXTRA_KCFLAGS"
17482         EXTRA_KCFLAGS="-Werror"
17483
17484
17485 cat confdefs.h - <<_ACEOF >conftest.c
17486 /* confdefs.h.  */
17487 _ACEOF
17488 cat confdefs.h >>conftest.$ac_ext
17489 cat >>conftest.$ac_ext <<_ACEOF
17490 /* end confdefs.h.  */
17491
17492
17493                 #include <linux/security.h>
17494
17495 int
17496 main (void)
17497 {
17498
17499                 struct inode *ip __attribute__ ((unused)) = NULL;
17500                 struct inode *dip __attribute__ ((unused)) = NULL;
17501                 const struct qstr *str __attribute__ ((unused)) = NULL;
17502                 char *name __attribute__ ((unused)) = NULL;
17503                 void *value __attribute__ ((unused)) = NULL;
17504                 size_t len __attribute__ ((unused)) = 0;
17505
17506                 security_inode_init_security(ip, dip, str, &name, &value, &len);
17507
17508   ;
17509   return 0;
17510 }
17511
17512 _ACEOF
17513
17514
17515         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
17516         echo "obj-m := conftest.o" >build/Makefile
17517         modpost_flag=''
17518         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
17519         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
17520   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17521   (eval $ac_try) 2>&5
17522   ac_status=$?
17523   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17524   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
17525   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17526   (eval $ac_try) 2>&5
17527   ac_status=$?
17528   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17529   (exit $ac_status); }; }; then
17530
17531                 { $as_echo "$as_me:$LINENO: result: yes" >&5
17532 $as_echo "yes" >&6; }
17533
17534 cat >>confdefs.h <<\_ACEOF
17535 #define HAVE_6ARGS_SECURITY_INODE_INIT_SECURITY 1
17536 _ACEOF
17537
17538
17539 else
17540   $as_echo "$as_me: failed program was:" >&5
17541 sed 's/^/| /' conftest.$ac_ext >&5
17542
17543                 { $as_echo "$as_me:$LINENO: result: no" >&5
17544 $as_echo "no" >&6; }
17545
17546
17547
17548 fi
17549
17550         rm -Rf build
17551
17552
17553         EXTRA_KCFLAGS="$tmp_flags"
17554
17555
17556         { $as_echo "$as_me:$LINENO: checking whether security_inode_init_security wants callback" >&5
17557 $as_echo_n "checking whether security_inode_init_security wants callback... " >&6; }
17558         tmp_flags="$EXTRA_KCFLAGS"
17559         EXTRA_KCFLAGS="-Werror"
17560
17561
17562 cat confdefs.h - <<_ACEOF >conftest.c
17563 /* confdefs.h.  */
17564 _ACEOF
17565 cat confdefs.h >>conftest.$ac_ext
17566 cat >>conftest.$ac_ext <<_ACEOF
17567 /* end confdefs.h.  */
17568
17569
17570                 #include <linux/security.h>
17571
17572 int
17573 main (void)
17574 {
17575
17576                 struct inode *ip __attribute__ ((unused)) = NULL;
17577                 struct inode *dip __attribute__ ((unused)) = NULL;
17578                 const struct qstr *str __attribute__ ((unused)) = NULL;
17579                 initxattrs func __attribute__ ((unused)) = NULL;
17580
17581                 security_inode_init_security(ip, dip, str, func, NULL);
17582
17583   ;
17584   return 0;
17585 }
17586
17587 _ACEOF
17588
17589
17590         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
17591         echo "obj-m := conftest.o" >build/Makefile
17592         modpost_flag=''
17593         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
17594         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
17595   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17596   (eval $ac_try) 2>&5
17597   ac_status=$?
17598   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17599   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
17600   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17601   (eval $ac_try) 2>&5
17602   ac_status=$?
17603   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17604   (exit $ac_status); }; }; then
17605
17606                 { $as_echo "$as_me:$LINENO: result: yes" >&5
17607 $as_echo "yes" >&6; }
17608
17609 cat >>confdefs.h <<\_ACEOF
17610 #define HAVE_CALLBACK_SECURITY_INODE_INIT_SECURITY 1
17611 _ACEOF
17612
17613
17614 else
17615   $as_echo "$as_me: failed program was:" >&5
17616 sed 's/^/| /' conftest.$ac_ext >&5
17617
17618                 { $as_echo "$as_me:$LINENO: result: no" >&5
17619 $as_echo "no" >&6; }
17620
17621
17622
17623 fi
17624
17625         rm -Rf build
17626
17627
17628         EXTRA_KCFLAGS="$tmp_flags"
17629
17630         { $as_echo "$as_me:$LINENO: checking whether mount_nodev() is available" >&5
17631 $as_echo_n "checking whether mount_nodev() is available... " >&6; }
17632
17633
17634
17635 cat confdefs.h - <<_ACEOF >conftest.c
17636 /* confdefs.h.  */
17637 _ACEOF
17638 cat confdefs.h >>conftest.$ac_ext
17639 cat >>conftest.$ac_ext <<_ACEOF
17640 /* end confdefs.h.  */
17641
17642
17643                 #include <linux/fs.h>
17644
17645 int
17646 main (void)
17647 {
17648
17649                 mount_nodev(NULL, 0, NULL, NULL);
17650
17651   ;
17652   return 0;
17653 }
17654
17655 _ACEOF
17656
17657
17658         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
17659         echo "obj-m := conftest.o" >build/Makefile
17660         modpost_flag=''
17661         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
17662         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
17663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17664   (eval $ac_try) 2>&5
17665   ac_status=$?
17666   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17667   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
17668   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17669   (eval $ac_try) 2>&5
17670   ac_status=$?
17671   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17672   (exit $ac_status); }; }; then
17673   rc=0
17674 else
17675   $as_echo "$as_me: failed program was:" >&5
17676 sed 's/^/| /' conftest.$ac_ext >&5
17677  rc=1
17678
17679
17680 fi
17681
17682         rm -Rf build
17683
17684
17685         if test $rc -ne 0; then :
17686
17687                 { $as_echo "$as_me:$LINENO: result: no" >&5
17688 $as_echo "no" >&6; }
17689
17690         else
17691                 if test "x$enable_linux_builtin" != xyes; then
17692
17693         grep -q -E '[[:space:]]mount_nodev[[:space:]]' \
17694                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
17695         rc=$?
17696         if test $rc -ne 0; then
17697                 export=0
17698                 for file in fs/super.c; do
17699                         grep -q -E "EXPORT_SYMBOL.*(mount_nodev)" \
17700                                 "$LINUX/$file" 2>/dev/null
17701                         rc=$?
17702                         if test $rc -eq 0; then
17703                                 export=1
17704                                 break;
17705                         fi
17706                 done
17707                 if test $export -eq 0; then :
17708                         rc=1
17709                 else :
17710                         rc=0
17711                 fi
17712         else :
17713                 rc=0
17714         fi
17715
17716                 fi
17717                 if test $rc -ne 0; then :
17718
17719                 { $as_echo "$as_me:$LINENO: result: no" >&5
17720 $as_echo "no" >&6; }
17721
17722                 else :
17723
17724                 { $as_echo "$as_me:$LINENO: result: yes" >&5
17725 $as_echo "yes" >&6; }
17726
17727 cat >>confdefs.h <<\_ACEOF
17728 #define HAVE_MOUNT_NODEV 1
17729 _ACEOF
17730
17731
17732                 fi
17733         fi
17734
17735
17736
17737         { $as_echo "$as_me:$LINENO: checking whether super_block has s_shrink" >&5
17738 $as_echo_n "checking whether super_block has s_shrink... " >&6; }
17739
17740
17741 cat confdefs.h - <<_ACEOF >conftest.c
17742 /* confdefs.h.  */
17743 _ACEOF
17744 cat confdefs.h >>conftest.$ac_ext
17745 cat >>conftest.$ac_ext <<_ACEOF
17746 /* end confdefs.h.  */
17747
17748
17749                 #include <linux/fs.h>
17750
17751 int
17752 main (void)
17753 {
17754
17755                 int (*shrink)(struct shrinker *, struct shrink_control *sc)
17756                         __attribute__ ((unused)) = NULL;
17757                 struct super_block sb __attribute__ ((unused)) = {
17758                         .s_shrink.shrink = shrink,
17759                         .s_shrink.seeks = DEFAULT_SEEKS,
17760                         .s_shrink.batch = 0,
17761                 };
17762
17763   ;
17764   return 0;
17765 }
17766
17767 _ACEOF
17768
17769
17770         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
17771         echo "obj-m := conftest.o" >build/Makefile
17772         modpost_flag=''
17773         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
17774         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
17775   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17776   (eval $ac_try) 2>&5
17777   ac_status=$?
17778   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17779   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
17780   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17781   (eval $ac_try) 2>&5
17782   ac_status=$?
17783   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17784   (exit $ac_status); }; }; then
17785
17786                 { $as_echo "$as_me:$LINENO: result: yes" >&5
17787 $as_echo "yes" >&6; }
17788
17789 cat >>confdefs.h <<\_ACEOF
17790 #define HAVE_SHRINK 1
17791 _ACEOF
17792
17793
17794
17795 else
17796   $as_echo "$as_me: failed program was:" >&5
17797 sed 's/^/| /' conftest.$ac_ext >&5
17798
17799                 { $as_echo "$as_me:$LINENO: result: no" >&5
17800 $as_echo "no" >&6; }
17801
17802
17803
17804 fi
17805
17806         rm -Rf build
17807
17808
17809
17810
17811         { $as_echo "$as_me:$LINENO: checking whether super_block has s_bdi" >&5
17812 $as_echo_n "checking whether super_block has s_bdi... " >&6; }
17813
17814
17815 cat confdefs.h - <<_ACEOF >conftest.c
17816 /* confdefs.h.  */
17817 _ACEOF
17818 cat confdefs.h >>conftest.$ac_ext
17819 cat >>conftest.$ac_ext <<_ACEOF
17820 /* end confdefs.h.  */
17821
17822
17823                 #include <linux/fs.h>
17824
17825 int
17826 main (void)
17827 {
17828
17829                 struct super_block sb __attribute__ ((unused));
17830                 sb.s_bdi = NULL;
17831
17832   ;
17833   return 0;
17834 }
17835
17836 _ACEOF
17837
17838
17839         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
17840         echo "obj-m := conftest.o" >build/Makefile
17841         modpost_flag=''
17842         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
17843         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
17844   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17845   (eval $ac_try) 2>&5
17846   ac_status=$?
17847   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17848   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
17849   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17850   (eval $ac_try) 2>&5
17851   ac_status=$?
17852   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17853   (exit $ac_status); }; }; then
17854
17855                 { $as_echo "$as_me:$LINENO: result: yes" >&5
17856 $as_echo "yes" >&6; }
17857
17858 cat >>confdefs.h <<\_ACEOF
17859 #define HAVE_BDI 1
17860 _ACEOF
17861
17862
17863 else
17864   $as_echo "$as_me: failed program was:" >&5
17865 sed 's/^/| /' conftest.$ac_ext >&5
17866
17867                 { $as_echo "$as_me:$LINENO: result: no" >&5
17868 $as_echo "no" >&6; }
17869
17870
17871
17872 fi
17873
17874         rm -Rf build
17875
17876
17877
17878         { $as_echo "$as_me:$LINENO: checking whether bdi_setup_and_register() is available" >&5
17879 $as_echo_n "checking whether bdi_setup_and_register() is available... " >&6; }
17880
17881
17882
17883 cat confdefs.h - <<_ACEOF >conftest.c
17884 /* confdefs.h.  */
17885 _ACEOF
17886 cat confdefs.h >>conftest.$ac_ext
17887 cat >>conftest.$ac_ext <<_ACEOF
17888 /* end confdefs.h.  */
17889
17890
17891                 #include <linux/backing-dev.h>
17892
17893 int
17894 main (void)
17895 {
17896
17897                 bdi_setup_and_register(NULL, NULL, 0);
17898
17899   ;
17900   return 0;
17901 }
17902
17903 _ACEOF
17904
17905
17906         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
17907         echo "obj-m := conftest.o" >build/Makefile
17908         modpost_flag=''
17909         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
17910         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
17911   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17912   (eval $ac_try) 2>&5
17913   ac_status=$?
17914   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17915   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
17916   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17917   (eval $ac_try) 2>&5
17918   ac_status=$?
17919   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17920   (exit $ac_status); }; }; then
17921   rc=0
17922 else
17923   $as_echo "$as_me: failed program was:" >&5
17924 sed 's/^/| /' conftest.$ac_ext >&5
17925  rc=1
17926
17927
17928 fi
17929
17930         rm -Rf build
17931
17932
17933         if test $rc -ne 0; then :
17934
17935                 { $as_echo "$as_me:$LINENO: result: no" >&5
17936 $as_echo "no" >&6; }
17937
17938         else
17939                 if test "x$enable_linux_builtin" != xyes; then
17940
17941         grep -q -E '[[:space:]]bdi_setup_and_register[[:space:]]' \
17942                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
17943         rc=$?
17944         if test $rc -ne 0; then
17945                 export=0
17946                 for file in mm/backing-dev.c; do
17947                         grep -q -E "EXPORT_SYMBOL.*(bdi_setup_and_register)" \
17948                                 "$LINUX/$file" 2>/dev/null
17949                         rc=$?
17950                         if test $rc -eq 0; then
17951                                 export=1
17952                                 break;
17953                         fi
17954                 done
17955                 if test $export -eq 0; then :
17956                         rc=1
17957                 else :
17958                         rc=0
17959                 fi
17960         else :
17961                 rc=0
17962         fi
17963
17964                 fi
17965                 if test $rc -ne 0; then :
17966
17967                 { $as_echo "$as_me:$LINENO: result: no" >&5
17968 $as_echo "no" >&6; }
17969
17970                 else :
17971
17972                 { $as_echo "$as_me:$LINENO: result: yes" >&5
17973 $as_echo "yes" >&6; }
17974
17975 cat >>confdefs.h <<\_ACEOF
17976 #define HAVE_BDI_SETUP_AND_REGISTER 1
17977 _ACEOF
17978
17979
17980                 fi
17981         fi
17982
17983
17984
17985         { $as_echo "$as_me:$LINENO: checking whether set_nlink() is available" >&5
17986 $as_echo_n "checking whether set_nlink() is available... " >&6; }
17987
17988
17989 cat confdefs.h - <<_ACEOF >conftest.c
17990 /* confdefs.h.  */
17991 _ACEOF
17992 cat confdefs.h >>conftest.$ac_ext
17993 cat >>conftest.$ac_ext <<_ACEOF
17994 /* end confdefs.h.  */
17995
17996
17997                 #include <linux/fs.h>
17998
17999 int
18000 main (void)
18001 {
18002
18003                 struct inode node;
18004                 unsigned int link = 0;
18005                 (void) set_nlink(&node, link);
18006
18007   ;
18008   return 0;
18009 }
18010
18011 _ACEOF
18012
18013
18014         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
18015         echo "obj-m := conftest.o" >build/Makefile
18016         modpost_flag=''
18017         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
18018         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
18019   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18020   (eval $ac_try) 2>&5
18021   ac_status=$?
18022   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18023   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
18024   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18025   (eval $ac_try) 2>&5
18026   ac_status=$?
18027   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18028   (exit $ac_status); }; }; then
18029
18030                 { $as_echo "$as_me:$LINENO: result: yes" >&5
18031 $as_echo "yes" >&6; }
18032
18033 cat >>confdefs.h <<\_ACEOF
18034 #define HAVE_SET_NLINK 1
18035 _ACEOF
18036
18037
18038 else
18039   $as_echo "$as_me: failed program was:" >&5
18040 sed 's/^/| /' conftest.$ac_ext >&5
18041
18042                 { $as_echo "$as_me:$LINENO: result: no" >&5
18043 $as_echo "no" >&6; }
18044
18045
18046
18047 fi
18048
18049         rm -Rf build
18050
18051
18052
18053
18054         if test "$LINUX_OBJ" != "$LINUX"; then
18055
18056                 KERNELMAKE_PARAMS="$KERNELMAKE_PARAMS O=$LINUX_OBJ"
18057
18058 fi
18059
18060
18061
18062
18063                         KERNELCPPFLAGS="$KERNELCPPFLAGS $NO_UNUSED_BUT_SET_VARIABLE"
18064         KERNELCPPFLAGS="$KERNELCPPFLAGS -DHAVE_SPL -D_KERNEL"
18065         KERNELCPPFLAGS="$KERNELCPPFLAGS -DTEXT_DOMAIN=\\\"zfs-linux-kernel\\\""
18066
18067
18068  ;;
18069                 user)
18070
18071
18072 # Check whether --with-udevdir was given.
18073 if test "${with_udevdir+set}" = set; then
18074   withval=$with_udevdir; udevdir=$withval
18075 else
18076   udevdir='${exec_prefix}/lib/udev'
18077 fi
18078
18079
18080
18081 # Check whether --with-udevruledir was given.
18082 if test "${with_udevruledir+set}" = set; then
18083   withval=$with_udevruledir; udevruledir=$withval
18084 else
18085   udevruledir='${udevdir}/rules.d'
18086 fi
18087
18088
18089
18090
18091
18092
18093         { $as_echo "$as_me:$LINENO: checking for target asm dir" >&5
18094 $as_echo_n "checking for target asm dir... " >&6; }
18095         TARGET_ARCH=`echo ${target_cpu} | sed -e s/i.86/i386/`
18096
18097         case $TARGET_ARCH in
18098         i386|x86_64)
18099                 TARGET_ASM_DIR=asm-${TARGET_ARCH}
18100                 ;;
18101         *)
18102                 TARGET_ASM_DIR=asm-generic
18103                 ;;
18104         esac
18105
18106
18107         { $as_echo "$as_me:$LINENO: result: $TARGET_ASM_DIR" >&5
18108 $as_echo "$TARGET_ASM_DIR" >&6; }
18109
18110
18111         { $as_echo "$as_me:$LINENO: checking for ioctl()" >&5
18112 $as_echo_n "checking for ioctl()... " >&6; }
18113         cat >conftest.$ac_ext <<_ACEOF
18114 /* confdefs.h.  */
18115 _ACEOF
18116 cat confdefs.h >>conftest.$ac_ext
18117 cat >>conftest.$ac_ext <<_ACEOF
18118 /* end confdefs.h.  */
18119 #include <unistd.h>
18120
18121 _ACEOF
18122 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18123   $EGREP "ioctl" >/dev/null 2>&1; then
18124   is_unistd=yes
18125 else
18126   is_unistd=no
18127 fi
18128 rm -f conftest*
18129
18130         cat >conftest.$ac_ext <<_ACEOF
18131 /* confdefs.h.  */
18132 _ACEOF
18133 cat confdefs.h >>conftest.$ac_ext
18134 cat >>conftest.$ac_ext <<_ACEOF
18135 /* end confdefs.h.  */
18136 #include <sys/ioctl.h>
18137
18138 _ACEOF
18139 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18140   $EGREP "ioctl" >/dev/null 2>&1; then
18141   is_sys_ioctl=yes
18142 else
18143   is_sys_ioctl=no
18144 fi
18145 rm -f conftest*
18146
18147         cat >conftest.$ac_ext <<_ACEOF
18148 /* confdefs.h.  */
18149 _ACEOF
18150 cat confdefs.h >>conftest.$ac_ext
18151 cat >>conftest.$ac_ext <<_ACEOF
18152 /* end confdefs.h.  */
18153 #include <stropts.h>
18154
18155 _ACEOF
18156 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18157   $EGREP "ioctl" >/dev/null 2>&1; then
18158   is_stropts=yes
18159 else
18160   is_stropts=no
18161 fi
18162 rm -f conftest*
18163
18164
18165         if test $is_unistd = yes; then
18166                 result=unistd.h
18167
18168 cat >>confdefs.h <<\_ACEOF
18169 #define HAVE_IOCTL_IN_UNISTD_H 1
18170 _ACEOF
18171
18172         else
18173
18174                 if test $is_sys_ioctl = yes; then
18175                         result=sys/ioctl.h
18176
18177 cat >>confdefs.h <<\_ACEOF
18178 #define HAVE_IOCTL_IN_SYS_IOCTL_H 1
18179 _ACEOF
18180
18181                 elif test $is_stropts = yes; then
18182
18183 cat >>confdefs.h <<\_ACEOF
18184 #define HAVE_IOCTL_IN_STROPTS_H 1
18185 _ACEOF
18186
18187                 else
18188                         result=no
18189                 fi
18190         fi
18191
18192         if test $result = no; then
18193                 { $as_echo "$as_me:$LINENO: result: no" >&5
18194 $as_echo "no" >&6; }
18195                 { { $as_echo "$as_me:$LINENO: error: *** Cannot locate ioctl() definition" >&5
18196 $as_echo "$as_me: error: *** Cannot locate ioctl() definition" >&2;}
18197    { (exit 1); exit 1; }; }
18198         else
18199                 { $as_echo "$as_me:$LINENO: result: yes" >&5
18200 $as_echo "yes" >&6; }
18201         fi
18202
18203
18204         ZLIB=
18205
18206         if test "${ac_cv_header_zlib_h+set}" = set; then
18207   { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
18208 $as_echo_n "checking for zlib.h... " >&6; }
18209 if test "${ac_cv_header_zlib_h+set}" = set; then
18210   $as_echo_n "(cached) " >&6
18211 fi
18212 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
18213 $as_echo "$ac_cv_header_zlib_h" >&6; }
18214 else
18215   # Is the header compilable?
18216 { $as_echo "$as_me:$LINENO: checking zlib.h usability" >&5
18217 $as_echo_n "checking zlib.h usability... " >&6; }
18218 cat >conftest.$ac_ext <<_ACEOF
18219 /* confdefs.h.  */
18220 _ACEOF
18221 cat confdefs.h >>conftest.$ac_ext
18222 cat >>conftest.$ac_ext <<_ACEOF
18223 /* end confdefs.h.  */
18224 $ac_includes_default
18225 #include <zlib.h>
18226 _ACEOF
18227 rm -f conftest.$ac_objext
18228 if { (ac_try="$ac_compile"
18229 case "(($ac_try" in
18230   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18231   *) ac_try_echo=$ac_try;;
18232 esac
18233 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18234 $as_echo "$ac_try_echo") >&5
18235   (eval "$ac_compile") 2>conftest.er1
18236   ac_status=$?
18237   grep -v '^ *+' conftest.er1 >conftest.err
18238   rm -f conftest.er1
18239   cat conftest.err >&5
18240   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18241   (exit $ac_status); } && {
18242          test -z "$ac_c_werror_flag" ||
18243          test ! -s conftest.err
18244        } && test -s conftest.$ac_objext; then
18245   ac_header_compiler=yes
18246 else
18247   $as_echo "$as_me: failed program was:" >&5
18248 sed 's/^/| /' conftest.$ac_ext >&5
18249
18250         ac_header_compiler=no
18251 fi
18252
18253 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18254 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18255 $as_echo "$ac_header_compiler" >&6; }
18256
18257 # Is the header present?
18258 { $as_echo "$as_me:$LINENO: checking zlib.h presence" >&5
18259 $as_echo_n "checking zlib.h presence... " >&6; }
18260 cat >conftest.$ac_ext <<_ACEOF
18261 /* confdefs.h.  */
18262 _ACEOF
18263 cat confdefs.h >>conftest.$ac_ext
18264 cat >>conftest.$ac_ext <<_ACEOF
18265 /* end confdefs.h.  */
18266 #include <zlib.h>
18267 _ACEOF
18268 if { (ac_try="$ac_cpp conftest.$ac_ext"
18269 case "(($ac_try" in
18270   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18271   *) ac_try_echo=$ac_try;;
18272 esac
18273 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18274 $as_echo "$ac_try_echo") >&5
18275   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
18276   ac_status=$?
18277   grep -v '^ *+' conftest.er1 >conftest.err
18278   rm -f conftest.er1
18279   cat conftest.err >&5
18280   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18281   (exit $ac_status); } >/dev/null && {
18282          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
18283          test ! -s conftest.err
18284        }; then
18285   ac_header_preproc=yes
18286 else
18287   $as_echo "$as_me: failed program was:" >&5
18288 sed 's/^/| /' conftest.$ac_ext >&5
18289
18290   ac_header_preproc=no
18291 fi
18292
18293 rm -f conftest.err conftest.$ac_ext
18294 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18295 $as_echo "$ac_header_preproc" >&6; }
18296
18297 # So?  What about this header?
18298 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18299   yes:no: )
18300     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
18301 $as_echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
18302     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
18303 $as_echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
18304     ac_header_preproc=yes
18305     ;;
18306   no:yes:* )
18307     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
18308 $as_echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
18309     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
18310 $as_echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
18311     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
18312 $as_echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
18313     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
18314 $as_echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
18315     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
18316 $as_echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
18317     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
18318 $as_echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
18319
18320     ;;
18321 esac
18322 { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
18323 $as_echo_n "checking for zlib.h... " >&6; }
18324 if test "${ac_cv_header_zlib_h+set}" = set; then
18325   $as_echo_n "(cached) " >&6
18326 else
18327   ac_cv_header_zlib_h=$ac_header_preproc
18328 fi
18329 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
18330 $as_echo "$ac_cv_header_zlib_h" >&6; }
18331
18332 fi
18333 if test "x$ac_cv_header_zlib_h" = x""yes; then
18334   :
18335 else
18336   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18337 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18338 { { $as_echo "$as_me:$LINENO: error:
18339         *** zlib.h missing, zlib-devel package required
18340 See \`config.log' for more details." >&5
18341 $as_echo "$as_me: error:
18342         *** zlib.h missing, zlib-devel package required
18343 See \`config.log' for more details." >&2;}
18344    { (exit 1); exit 1; }; }; }
18345 fi
18346
18347
18348
18349
18350 { $as_echo "$as_me:$LINENO: checking for compress2 in -lz" >&5
18351 $as_echo_n "checking for compress2 in -lz... " >&6; }
18352 if test "${ac_cv_lib_z_compress2+set}" = set; then
18353   $as_echo_n "(cached) " >&6
18354 else
18355   ac_check_lib_save_LIBS=$LIBS
18356 LIBS="-lz  $LIBS"
18357 cat >conftest.$ac_ext <<_ACEOF
18358 /* confdefs.h.  */
18359 _ACEOF
18360 cat confdefs.h >>conftest.$ac_ext
18361 cat >>conftest.$ac_ext <<_ACEOF
18362 /* end confdefs.h.  */
18363
18364 /* Override any GCC internal prototype to avoid an error.
18365    Use char because int might match the return type of a GCC
18366    builtin and then its argument prototype would still apply.  */
18367 #ifdef __cplusplus
18368 extern "C"
18369 #endif
18370 char compress2 ();
18371 int
18372 main ()
18373 {
18374 return compress2 ();
18375   ;
18376   return 0;
18377 }
18378 _ACEOF
18379 rm -f conftest.$ac_objext conftest$ac_exeext
18380 if { (ac_try="$ac_link"
18381 case "(($ac_try" in
18382   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18383   *) ac_try_echo=$ac_try;;
18384 esac
18385 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18386 $as_echo "$ac_try_echo") >&5
18387   (eval "$ac_link") 2>conftest.er1
18388   ac_status=$?
18389   grep -v '^ *+' conftest.er1 >conftest.err
18390   rm -f conftest.er1
18391   cat conftest.err >&5
18392   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18393   (exit $ac_status); } && {
18394          test -z "$ac_c_werror_flag" ||
18395          test ! -s conftest.err
18396        } && test -s conftest$ac_exeext && {
18397          test "$cross_compiling" = yes ||
18398          $as_test_x conftest$ac_exeext
18399        }; then
18400   ac_cv_lib_z_compress2=yes
18401 else
18402   $as_echo "$as_me: failed program was:" >&5
18403 sed 's/^/| /' conftest.$ac_ext >&5
18404
18405         ac_cv_lib_z_compress2=no
18406 fi
18407
18408 rm -rf conftest.dSYM
18409 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18410       conftest$ac_exeext conftest.$ac_ext
18411 LIBS=$ac_check_lib_save_LIBS
18412 fi
18413 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_compress2" >&5
18414 $as_echo "$ac_cv_lib_z_compress2" >&6; }
18415 if test "x$ac_cv_lib_z_compress2" = x""yes; then
18416   cat >>confdefs.h <<_ACEOF
18417 #define HAVE_LIBZ 1
18418 _ACEOF
18419
18420   LIBS="-lz $LIBS"
18421
18422 else
18423   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18424 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18425 { { $as_echo "$as_me:$LINENO: error:
18426         *** compress2() missing, zlib-devel package required
18427 See \`config.log' for more details." >&5
18428 $as_echo "$as_me: error:
18429         *** compress2() missing, zlib-devel package required
18430 See \`config.log' for more details." >&2;}
18431    { (exit 1); exit 1; }; }; }
18432 fi
18433
18434
18435
18436 { $as_echo "$as_me:$LINENO: checking for uncompress in -lz" >&5
18437 $as_echo_n "checking for uncompress in -lz... " >&6; }
18438 if test "${ac_cv_lib_z_uncompress+set}" = set; then
18439   $as_echo_n "(cached) " >&6
18440 else
18441   ac_check_lib_save_LIBS=$LIBS
18442 LIBS="-lz  $LIBS"
18443 cat >conftest.$ac_ext <<_ACEOF
18444 /* confdefs.h.  */
18445 _ACEOF
18446 cat confdefs.h >>conftest.$ac_ext
18447 cat >>conftest.$ac_ext <<_ACEOF
18448 /* end confdefs.h.  */
18449
18450 /* Override any GCC internal prototype to avoid an error.
18451    Use char because int might match the return type of a GCC
18452    builtin and then its argument prototype would still apply.  */
18453 #ifdef __cplusplus
18454 extern "C"
18455 #endif
18456 char uncompress ();
18457 int
18458 main ()
18459 {
18460 return uncompress ();
18461   ;
18462   return 0;
18463 }
18464 _ACEOF
18465 rm -f conftest.$ac_objext conftest$ac_exeext
18466 if { (ac_try="$ac_link"
18467 case "(($ac_try" in
18468   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18469   *) ac_try_echo=$ac_try;;
18470 esac
18471 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18472 $as_echo "$ac_try_echo") >&5
18473   (eval "$ac_link") 2>conftest.er1
18474   ac_status=$?
18475   grep -v '^ *+' conftest.er1 >conftest.err
18476   rm -f conftest.er1
18477   cat conftest.err >&5
18478   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18479   (exit $ac_status); } && {
18480          test -z "$ac_c_werror_flag" ||
18481          test ! -s conftest.err
18482        } && test -s conftest$ac_exeext && {
18483          test "$cross_compiling" = yes ||
18484          $as_test_x conftest$ac_exeext
18485        }; then
18486   ac_cv_lib_z_uncompress=yes
18487 else
18488   $as_echo "$as_me: failed program was:" >&5
18489 sed 's/^/| /' conftest.$ac_ext >&5
18490
18491         ac_cv_lib_z_uncompress=no
18492 fi
18493
18494 rm -rf conftest.dSYM
18495 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18496       conftest$ac_exeext conftest.$ac_ext
18497 LIBS=$ac_check_lib_save_LIBS
18498 fi
18499 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_uncompress" >&5
18500 $as_echo "$ac_cv_lib_z_uncompress" >&6; }
18501 if test "x$ac_cv_lib_z_uncompress" = x""yes; then
18502   cat >>confdefs.h <<_ACEOF
18503 #define HAVE_LIBZ 1
18504 _ACEOF
18505
18506   LIBS="-lz $LIBS"
18507
18508 else
18509   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18510 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18511 { { $as_echo "$as_me:$LINENO: error:
18512         *** uncompress() missing, zlib-devel package required
18513 See \`config.log' for more details." >&5
18514 $as_echo "$as_me: error:
18515         *** uncompress() missing, zlib-devel package required
18516 See \`config.log' for more details." >&2;}
18517    { (exit 1); exit 1; }; }; }
18518 fi
18519
18520
18521
18522 { $as_echo "$as_me:$LINENO: checking for crc32 in -lz" >&5
18523 $as_echo_n "checking for crc32 in -lz... " >&6; }
18524 if test "${ac_cv_lib_z_crc32+set}" = set; then
18525   $as_echo_n "(cached) " >&6
18526 else
18527   ac_check_lib_save_LIBS=$LIBS
18528 LIBS="-lz  $LIBS"
18529 cat >conftest.$ac_ext <<_ACEOF
18530 /* confdefs.h.  */
18531 _ACEOF
18532 cat confdefs.h >>conftest.$ac_ext
18533 cat >>conftest.$ac_ext <<_ACEOF
18534 /* end confdefs.h.  */
18535
18536 /* Override any GCC internal prototype to avoid an error.
18537    Use char because int might match the return type of a GCC
18538    builtin and then its argument prototype would still apply.  */
18539 #ifdef __cplusplus
18540 extern "C"
18541 #endif
18542 char crc32 ();
18543 int
18544 main ()
18545 {
18546 return crc32 ();
18547   ;
18548   return 0;
18549 }
18550 _ACEOF
18551 rm -f conftest.$ac_objext conftest$ac_exeext
18552 if { (ac_try="$ac_link"
18553 case "(($ac_try" in
18554   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18555   *) ac_try_echo=$ac_try;;
18556 esac
18557 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18558 $as_echo "$ac_try_echo") >&5
18559   (eval "$ac_link") 2>conftest.er1
18560   ac_status=$?
18561   grep -v '^ *+' conftest.er1 >conftest.err
18562   rm -f conftest.er1
18563   cat conftest.err >&5
18564   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18565   (exit $ac_status); } && {
18566          test -z "$ac_c_werror_flag" ||
18567          test ! -s conftest.err
18568        } && test -s conftest$ac_exeext && {
18569          test "$cross_compiling" = yes ||
18570          $as_test_x conftest$ac_exeext
18571        }; then
18572   ac_cv_lib_z_crc32=yes
18573 else
18574   $as_echo "$as_me: failed program was:" >&5
18575 sed 's/^/| /' conftest.$ac_ext >&5
18576
18577         ac_cv_lib_z_crc32=no
18578 fi
18579
18580 rm -rf conftest.dSYM
18581 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18582       conftest$ac_exeext conftest.$ac_ext
18583 LIBS=$ac_check_lib_save_LIBS
18584 fi
18585 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_crc32" >&5
18586 $as_echo "$ac_cv_lib_z_crc32" >&6; }
18587 if test "x$ac_cv_lib_z_crc32" = x""yes; then
18588   cat >>confdefs.h <<_ACEOF
18589 #define HAVE_LIBZ 1
18590 _ACEOF
18591
18592   LIBS="-lz $LIBS"
18593
18594 else
18595   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18596 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18597 { { $as_echo "$as_me:$LINENO: error:
18598         *** crc32() missing, zlib-devel package required
18599 See \`config.log' for more details." >&5
18600 $as_echo "$as_me: error:
18601         *** crc32() missing, zlib-devel package required
18602 See \`config.log' for more details." >&2;}
18603    { (exit 1); exit 1; }; }; }
18604 fi
18605
18606
18607         ZLIB="-lz"
18608
18609
18610 cat >>confdefs.h <<\_ACEOF
18611 #define HAVE_ZLIB 1
18612 _ACEOF
18613
18614
18615
18616         LIBUUID=
18617
18618         if test "${ac_cv_header_uuid_uuid_h+set}" = set; then
18619   { $as_echo "$as_me:$LINENO: checking for uuid/uuid.h" >&5
18620 $as_echo_n "checking for uuid/uuid.h... " >&6; }
18621 if test "${ac_cv_header_uuid_uuid_h+set}" = set; then
18622   $as_echo_n "(cached) " >&6
18623 fi
18624 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_uuid_uuid_h" >&5
18625 $as_echo "$ac_cv_header_uuid_uuid_h" >&6; }
18626 else
18627   # Is the header compilable?
18628 { $as_echo "$as_me:$LINENO: checking uuid/uuid.h usability" >&5
18629 $as_echo_n "checking uuid/uuid.h usability... " >&6; }
18630 cat >conftest.$ac_ext <<_ACEOF
18631 /* confdefs.h.  */
18632 _ACEOF
18633 cat confdefs.h >>conftest.$ac_ext
18634 cat >>conftest.$ac_ext <<_ACEOF
18635 /* end confdefs.h.  */
18636 $ac_includes_default
18637 #include <uuid/uuid.h>
18638 _ACEOF
18639 rm -f conftest.$ac_objext
18640 if { (ac_try="$ac_compile"
18641 case "(($ac_try" in
18642   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18643   *) ac_try_echo=$ac_try;;
18644 esac
18645 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18646 $as_echo "$ac_try_echo") >&5
18647   (eval "$ac_compile") 2>conftest.er1
18648   ac_status=$?
18649   grep -v '^ *+' conftest.er1 >conftest.err
18650   rm -f conftest.er1
18651   cat conftest.err >&5
18652   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18653   (exit $ac_status); } && {
18654          test -z "$ac_c_werror_flag" ||
18655          test ! -s conftest.err
18656        } && test -s conftest.$ac_objext; then
18657   ac_header_compiler=yes
18658 else
18659   $as_echo "$as_me: failed program was:" >&5
18660 sed 's/^/| /' conftest.$ac_ext >&5
18661
18662         ac_header_compiler=no
18663 fi
18664
18665 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18666 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18667 $as_echo "$ac_header_compiler" >&6; }
18668
18669 # Is the header present?
18670 { $as_echo "$as_me:$LINENO: checking uuid/uuid.h presence" >&5
18671 $as_echo_n "checking uuid/uuid.h presence... " >&6; }
18672 cat >conftest.$ac_ext <<_ACEOF
18673 /* confdefs.h.  */
18674 _ACEOF
18675 cat confdefs.h >>conftest.$ac_ext
18676 cat >>conftest.$ac_ext <<_ACEOF
18677 /* end confdefs.h.  */
18678 #include <uuid/uuid.h>
18679 _ACEOF
18680 if { (ac_try="$ac_cpp conftest.$ac_ext"
18681 case "(($ac_try" in
18682   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18683   *) ac_try_echo=$ac_try;;
18684 esac
18685 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18686 $as_echo "$ac_try_echo") >&5
18687   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
18688   ac_status=$?
18689   grep -v '^ *+' conftest.er1 >conftest.err
18690   rm -f conftest.er1
18691   cat conftest.err >&5
18692   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18693   (exit $ac_status); } >/dev/null && {
18694          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
18695          test ! -s conftest.err
18696        }; then
18697   ac_header_preproc=yes
18698 else
18699   $as_echo "$as_me: failed program was:" >&5
18700 sed 's/^/| /' conftest.$ac_ext >&5
18701
18702   ac_header_preproc=no
18703 fi
18704
18705 rm -f conftest.err conftest.$ac_ext
18706 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18707 $as_echo "$ac_header_preproc" >&6; }
18708
18709 # So?  What about this header?
18710 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
18711   yes:no: )
18712     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: accepted by the compiler, rejected by the preprocessor!" >&5
18713 $as_echo "$as_me: WARNING: uuid/uuid.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
18714     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: proceeding with the compiler's result" >&5
18715 $as_echo "$as_me: WARNING: uuid/uuid.h: proceeding with the compiler's result" >&2;}
18716     ac_header_preproc=yes
18717     ;;
18718   no:yes:* )
18719     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: present but cannot be compiled" >&5
18720 $as_echo "$as_me: WARNING: uuid/uuid.h: present but cannot be compiled" >&2;}
18721     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h:     check for missing prerequisite headers?" >&5
18722 $as_echo "$as_me: WARNING: uuid/uuid.h:     check for missing prerequisite headers?" >&2;}
18723     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: see the Autoconf documentation" >&5
18724 $as_echo "$as_me: WARNING: uuid/uuid.h: see the Autoconf documentation" >&2;}
18725     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h:     section \"Present But Cannot Be Compiled\"" >&5
18726 $as_echo "$as_me: WARNING: uuid/uuid.h:     section \"Present But Cannot Be Compiled\"" >&2;}
18727     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: proceeding with the preprocessor's result" >&5
18728 $as_echo "$as_me: WARNING: uuid/uuid.h: proceeding with the preprocessor's result" >&2;}
18729     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: in the future, the compiler will take precedence" >&5
18730 $as_echo "$as_me: WARNING: uuid/uuid.h: in the future, the compiler will take precedence" >&2;}
18731
18732     ;;
18733 esac
18734 { $as_echo "$as_me:$LINENO: checking for uuid/uuid.h" >&5
18735 $as_echo_n "checking for uuid/uuid.h... " >&6; }
18736 if test "${ac_cv_header_uuid_uuid_h+set}" = set; then
18737   $as_echo_n "(cached) " >&6
18738 else
18739   ac_cv_header_uuid_uuid_h=$ac_header_preproc
18740 fi
18741 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_uuid_uuid_h" >&5
18742 $as_echo "$ac_cv_header_uuid_uuid_h" >&6; }
18743
18744 fi
18745 if test "x$ac_cv_header_uuid_uuid_h" = x""yes; then
18746   :
18747 else
18748   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18749 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18750 { { $as_echo "$as_me:$LINENO: error:
18751         *** uuid/uuid.h missing, libuuid-devel package required
18752 See \`config.log' for more details." >&5
18753 $as_echo "$as_me: error:
18754         *** uuid/uuid.h missing, libuuid-devel package required
18755 See \`config.log' for more details." >&2;}
18756    { (exit 1); exit 1; }; }; }
18757 fi
18758
18759
18760
18761
18762 { $as_echo "$as_me:$LINENO: checking for uuid_generate in -luuid" >&5
18763 $as_echo_n "checking for uuid_generate in -luuid... " >&6; }
18764 if test "${ac_cv_lib_uuid_uuid_generate+set}" = set; then
18765   $as_echo_n "(cached) " >&6
18766 else
18767   ac_check_lib_save_LIBS=$LIBS
18768 LIBS="-luuid  $LIBS"
18769 cat >conftest.$ac_ext <<_ACEOF
18770 /* confdefs.h.  */
18771 _ACEOF
18772 cat confdefs.h >>conftest.$ac_ext
18773 cat >>conftest.$ac_ext <<_ACEOF
18774 /* end confdefs.h.  */
18775
18776 /* Override any GCC internal prototype to avoid an error.
18777    Use char because int might match the return type of a GCC
18778    builtin and then its argument prototype would still apply.  */
18779 #ifdef __cplusplus
18780 extern "C"
18781 #endif
18782 char uuid_generate ();
18783 int
18784 main ()
18785 {
18786 return uuid_generate ();
18787   ;
18788   return 0;
18789 }
18790 _ACEOF
18791 rm -f conftest.$ac_objext conftest$ac_exeext
18792 if { (ac_try="$ac_link"
18793 case "(($ac_try" in
18794   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18795   *) ac_try_echo=$ac_try;;
18796 esac
18797 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18798 $as_echo "$ac_try_echo") >&5
18799   (eval "$ac_link") 2>conftest.er1
18800   ac_status=$?
18801   grep -v '^ *+' conftest.er1 >conftest.err
18802   rm -f conftest.er1
18803   cat conftest.err >&5
18804   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18805   (exit $ac_status); } && {
18806          test -z "$ac_c_werror_flag" ||
18807          test ! -s conftest.err
18808        } && test -s conftest$ac_exeext && {
18809          test "$cross_compiling" = yes ||
18810          $as_test_x conftest$ac_exeext
18811        }; then
18812   ac_cv_lib_uuid_uuid_generate=yes
18813 else
18814   $as_echo "$as_me: failed program was:" >&5
18815 sed 's/^/| /' conftest.$ac_ext >&5
18816
18817         ac_cv_lib_uuid_uuid_generate=no
18818 fi
18819
18820 rm -rf conftest.dSYM
18821 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18822       conftest$ac_exeext conftest.$ac_ext
18823 LIBS=$ac_check_lib_save_LIBS
18824 fi
18825 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_generate" >&5
18826 $as_echo "$ac_cv_lib_uuid_uuid_generate" >&6; }
18827 if test "x$ac_cv_lib_uuid_uuid_generate" = x""yes; then
18828   cat >>confdefs.h <<_ACEOF
18829 #define HAVE_LIBUUID 1
18830 _ACEOF
18831
18832   LIBS="-luuid $LIBS"
18833
18834 else
18835   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18836 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18837 { { $as_echo "$as_me:$LINENO: error:
18838         *** uuid_generate() missing, libuuid-devel package required
18839 See \`config.log' for more details." >&5
18840 $as_echo "$as_me: error:
18841         *** uuid_generate() missing, libuuid-devel package required
18842 See \`config.log' for more details." >&2;}
18843    { (exit 1); exit 1; }; }; }
18844 fi
18845
18846
18847
18848 { $as_echo "$as_me:$LINENO: checking for uuid_is_null in -luuid" >&5
18849 $as_echo_n "checking for uuid_is_null in -luuid... " >&6; }
18850 if test "${ac_cv_lib_uuid_uuid_is_null+set}" = set; then
18851   $as_echo_n "(cached) " >&6
18852 else
18853   ac_check_lib_save_LIBS=$LIBS
18854 LIBS="-luuid  $LIBS"
18855 cat >conftest.$ac_ext <<_ACEOF
18856 /* confdefs.h.  */
18857 _ACEOF
18858 cat confdefs.h >>conftest.$ac_ext
18859 cat >>conftest.$ac_ext <<_ACEOF
18860 /* end confdefs.h.  */
18861
18862 /* Override any GCC internal prototype to avoid an error.
18863    Use char because int might match the return type of a GCC
18864    builtin and then its argument prototype would still apply.  */
18865 #ifdef __cplusplus
18866 extern "C"
18867 #endif
18868 char uuid_is_null ();
18869 int
18870 main ()
18871 {
18872 return uuid_is_null ();
18873   ;
18874   return 0;
18875 }
18876 _ACEOF
18877 rm -f conftest.$ac_objext conftest$ac_exeext
18878 if { (ac_try="$ac_link"
18879 case "(($ac_try" in
18880   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18881   *) ac_try_echo=$ac_try;;
18882 esac
18883 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18884 $as_echo "$ac_try_echo") >&5
18885   (eval "$ac_link") 2>conftest.er1
18886   ac_status=$?
18887   grep -v '^ *+' conftest.er1 >conftest.err
18888   rm -f conftest.er1
18889   cat conftest.err >&5
18890   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18891   (exit $ac_status); } && {
18892          test -z "$ac_c_werror_flag" ||
18893          test ! -s conftest.err
18894        } && test -s conftest$ac_exeext && {
18895          test "$cross_compiling" = yes ||
18896          $as_test_x conftest$ac_exeext
18897        }; then
18898   ac_cv_lib_uuid_uuid_is_null=yes
18899 else
18900   $as_echo "$as_me: failed program was:" >&5
18901 sed 's/^/| /' conftest.$ac_ext >&5
18902
18903         ac_cv_lib_uuid_uuid_is_null=no
18904 fi
18905
18906 rm -rf conftest.dSYM
18907 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18908       conftest$ac_exeext conftest.$ac_ext
18909 LIBS=$ac_check_lib_save_LIBS
18910 fi
18911 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_is_null" >&5
18912 $as_echo "$ac_cv_lib_uuid_uuid_is_null" >&6; }
18913 if test "x$ac_cv_lib_uuid_uuid_is_null" = x""yes; then
18914   cat >>confdefs.h <<_ACEOF
18915 #define HAVE_LIBUUID 1
18916 _ACEOF
18917
18918   LIBS="-luuid $LIBS"
18919
18920 else
18921   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18922 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18923 { { $as_echo "$as_me:$LINENO: error:
18924         *** uuid_is_null() missing, libuuid-devel package required
18925 See \`config.log' for more details." >&5
18926 $as_echo "$as_me: error:
18927         *** uuid_is_null() missing, libuuid-devel package required
18928 See \`config.log' for more details." >&2;}
18929    { (exit 1); exit 1; }; }; }
18930 fi
18931
18932
18933         LIBUUID="-luuid"
18934
18935
18936 cat >>confdefs.h <<\_ACEOF
18937 #define HAVE_LIBUUID 1
18938 _ACEOF
18939
18940
18941
18942
18943 # Check whether --with-blkid was given.
18944 if test "${with_blkid+set}" = set; then
18945   withval=$with_blkid;
18946 else
18947   with_blkid=check
18948 fi
18949
18950
18951         LIBBLKID=
18952         if test "x$with_blkid" != xno; then
18953
18954                 { $as_echo "$as_me:$LINENO: checking for blkid_get_cache in -lblkid" >&5
18955 $as_echo_n "checking for blkid_get_cache in -lblkid... " >&6; }
18956 if test "${ac_cv_lib_blkid_blkid_get_cache+set}" = set; then
18957   $as_echo_n "(cached) " >&6
18958 else
18959   ac_check_lib_save_LIBS=$LIBS
18960 LIBS="-lblkid  $LIBS"
18961 cat >conftest.$ac_ext <<_ACEOF
18962 /* confdefs.h.  */
18963 _ACEOF
18964 cat confdefs.h >>conftest.$ac_ext
18965 cat >>conftest.$ac_ext <<_ACEOF
18966 /* end confdefs.h.  */
18967
18968 /* Override any GCC internal prototype to avoid an error.
18969    Use char because int might match the return type of a GCC
18970    builtin and then its argument prototype would still apply.  */
18971 #ifdef __cplusplus
18972 extern "C"
18973 #endif
18974 char blkid_get_cache ();
18975 int
18976 main ()
18977 {
18978 return blkid_get_cache ();
18979   ;
18980   return 0;
18981 }
18982 _ACEOF
18983 rm -f conftest.$ac_objext conftest$ac_exeext
18984 if { (ac_try="$ac_link"
18985 case "(($ac_try" in
18986   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18987   *) ac_try_echo=$ac_try;;
18988 esac
18989 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18990 $as_echo "$ac_try_echo") >&5
18991   (eval "$ac_link") 2>conftest.er1
18992   ac_status=$?
18993   grep -v '^ *+' conftest.er1 >conftest.err
18994   rm -f conftest.er1
18995   cat conftest.err >&5
18996   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18997   (exit $ac_status); } && {
18998          test -z "$ac_c_werror_flag" ||
18999          test ! -s conftest.err
19000        } && test -s conftest$ac_exeext && {
19001          test "$cross_compiling" = yes ||
19002          $as_test_x conftest$ac_exeext
19003        }; then
19004   ac_cv_lib_blkid_blkid_get_cache=yes
19005 else
19006   $as_echo "$as_me: failed program was:" >&5
19007 sed 's/^/| /' conftest.$ac_ext >&5
19008
19009         ac_cv_lib_blkid_blkid_get_cache=no
19010 fi
19011
19012 rm -rf conftest.dSYM
19013 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19014       conftest$ac_exeext conftest.$ac_ext
19015 LIBS=$ac_check_lib_save_LIBS
19016 fi
19017 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_blkid_blkid_get_cache" >&5
19018 $as_echo "$ac_cv_lib_blkid_blkid_get_cache" >&6; }
19019 if test "x$ac_cv_lib_blkid_blkid_get_cache" = x""yes; then
19020
19021                         { $as_echo "$as_me:$LINENO: checking for blkid zfs support" >&5
19022 $as_echo_n "checking for blkid zfs support... " >&6; }
19023
19024                         ZFS_DEV=`mktemp`
19025                         dd if=/dev/zero of=$ZFS_DEV bs=1024k count=8 \
19026                                 >/dev/null 2>/dev/null
19027                         echo -en "\x0c\xb1\xba\0\0\0\0\0" | \
19028                                 dd of=$ZFS_DEV bs=1k count=8 \
19029                                 seek=132 conv=notrunc &>/dev/null \
19030                                 >/dev/null 2>/dev/null
19031
19032                         saved_LDFLAGS="$LDFLAGS"
19033                         LDFLAGS="-lblkid"
19034
19035                         if test "$cross_compiling" = yes; then
19036   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
19037 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19038 { { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19039 See \`config.log' for more details." >&5
19040 $as_echo "$as_me: error: cannot run test program while cross compiling
19041 See \`config.log' for more details." >&2;}
19042    { (exit 1); exit 1; }; }; }
19043 else
19044   cat >conftest.$ac_ext <<_ACEOF
19045 /* confdefs.h.  */
19046 _ACEOF
19047 cat confdefs.h >>conftest.$ac_ext
19048 cat >>conftest.$ac_ext <<_ACEOF
19049 /* end confdefs.h.  */
19050
19051                                 #include <stdio.h>
19052                                 #include <blkid/blkid.h>
19053
19054 int
19055 main ()
19056 {
19057
19058                                 blkid_cache cache;
19059                                 char *value;
19060
19061                                 if (blkid_get_cache(&cache, NULL) < 0)
19062                                         return 1;
19063
19064                                 value = blkid_get_tag_value(cache, "TYPE",
19065                                                             "$ZFS_DEV");
19066                                 if (!value) {
19067                                         blkid_put_cache(cache);
19068                                         return 2;
19069                                 }
19070
19071                                 if (strcmp(value, "zfs")) {
19072                                         free(value);
19073                                         blkid_put_cache(cache);
19074                                         return 3;
19075                                 }
19076
19077                                 free(value);
19078                                 blkid_put_cache(cache);
19079
19080   ;
19081   return 0;
19082 }
19083 _ACEOF
19084 rm -f conftest$ac_exeext
19085 if { (ac_try="$ac_link"
19086 case "(($ac_try" in
19087   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19088   *) ac_try_echo=$ac_try;;
19089 esac
19090 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19091 $as_echo "$ac_try_echo") >&5
19092   (eval "$ac_link") 2>&5
19093   ac_status=$?
19094   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19095   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19096   { (case "(($ac_try" in
19097   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19098   *) ac_try_echo=$ac_try;;
19099 esac
19100 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19101 $as_echo "$ac_try_echo") >&5
19102   (eval "$ac_try") 2>&5
19103   ac_status=$?
19104   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19105   (exit $ac_status); }; }; then
19106
19107                                 rm -f $ZFS_DEV
19108                                 { $as_echo "$as_me:$LINENO: result: yes" >&5
19109 $as_echo "yes" >&6; }
19110                                 LIBBLKID="-lblkid"
19111
19112
19113 cat >>confdefs.h <<\_ACEOF
19114 #define HAVE_LIBBLKID 1
19115 _ACEOF
19116
19117
19118 else
19119   $as_echo "$as_me: program exited with status $ac_status" >&5
19120 $as_echo "$as_me: failed program was:" >&5
19121 sed 's/^/| /' conftest.$ac_ext >&5
19122
19123 ( exit $ac_status )
19124
19125                                 rm -f $ZFS_DEV
19126                                 { $as_echo "$as_me:$LINENO: result: no" >&5
19127 $as_echo "no" >&6; }
19128                                 if test "x$with_blkid" != xcheck; then
19129   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
19130 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19131 { { $as_echo "$as_me:$LINENO: error: --with-blkid given but unavailable
19132 See \`config.log' for more details." >&5
19133 $as_echo "$as_me: error: --with-blkid given but unavailable
19134 See \`config.log' for more details." >&2;}
19135    { (exit 1); exit 1; }; }; }
19136 fi
19137
19138
19139 fi
19140 rm -rf conftest.dSYM
19141 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19142 fi
19143
19144
19145
19146                         LDFLAGS="$saved_LDFLAGS"
19147
19148 else
19149
19150                         if test "x$with_blkid" != xcheck; then
19151   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
19152 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19153 { { $as_echo "$as_me:$LINENO: error: --with-blkid given but unavailable
19154 See \`config.log' for more details." >&5
19155 $as_echo "$as_me: error: --with-blkid given but unavailable
19156 See \`config.log' for more details." >&2;}
19157    { (exit 1); exit 1; }; }; }
19158 fi
19159
19160
19161
19162 fi
19163
19164
19165 fi
19166
19167
19168
19169
19170 # Check whether --with-selinux was given.
19171 if test "${with_selinux+set}" = set; then
19172   withval=$with_selinux;
19173 else
19174   with_selinux=check
19175 fi
19176
19177
19178         LIBSELINUX=
19179         if test "x$with_selinux" != xno; then
19180
19181                 if test "${ac_cv_header_selinux_selinux_h+set}" = set; then
19182   { $as_echo "$as_me:$LINENO: checking for selinux/selinux.h" >&5
19183 $as_echo_n "checking for selinux/selinux.h... " >&6; }
19184 if test "${ac_cv_header_selinux_selinux_h+set}" = set; then
19185   $as_echo_n "(cached) " >&6
19186 fi
19187 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_selinux_selinux_h" >&5
19188 $as_echo "$ac_cv_header_selinux_selinux_h" >&6; }
19189 else
19190   # Is the header compilable?
19191 { $as_echo "$as_me:$LINENO: checking selinux/selinux.h usability" >&5
19192 $as_echo_n "checking selinux/selinux.h usability... " >&6; }
19193 cat >conftest.$ac_ext <<_ACEOF
19194 /* confdefs.h.  */
19195 _ACEOF
19196 cat confdefs.h >>conftest.$ac_ext
19197 cat >>conftest.$ac_ext <<_ACEOF
19198 /* end confdefs.h.  */
19199 $ac_includes_default
19200 #include <selinux/selinux.h>
19201 _ACEOF
19202 rm -f conftest.$ac_objext
19203 if { (ac_try="$ac_compile"
19204 case "(($ac_try" in
19205   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19206   *) ac_try_echo=$ac_try;;
19207 esac
19208 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19209 $as_echo "$ac_try_echo") >&5
19210   (eval "$ac_compile") 2>conftest.er1
19211   ac_status=$?
19212   grep -v '^ *+' conftest.er1 >conftest.err
19213   rm -f conftest.er1
19214   cat conftest.err >&5
19215   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19216   (exit $ac_status); } && {
19217          test -z "$ac_c_werror_flag" ||
19218          test ! -s conftest.err
19219        } && test -s conftest.$ac_objext; then
19220   ac_header_compiler=yes
19221 else
19222   $as_echo "$as_me: failed program was:" >&5
19223 sed 's/^/| /' conftest.$ac_ext >&5
19224
19225         ac_header_compiler=no
19226 fi
19227
19228 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19229 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19230 $as_echo "$ac_header_compiler" >&6; }
19231
19232 # Is the header present?
19233 { $as_echo "$as_me:$LINENO: checking selinux/selinux.h presence" >&5
19234 $as_echo_n "checking selinux/selinux.h presence... " >&6; }
19235 cat >conftest.$ac_ext <<_ACEOF
19236 /* confdefs.h.  */
19237 _ACEOF
19238 cat confdefs.h >>conftest.$ac_ext
19239 cat >>conftest.$ac_ext <<_ACEOF
19240 /* end confdefs.h.  */
19241 #include <selinux/selinux.h>
19242 _ACEOF
19243 if { (ac_try="$ac_cpp conftest.$ac_ext"
19244 case "(($ac_try" in
19245   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19246   *) ac_try_echo=$ac_try;;
19247 esac
19248 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19249 $as_echo "$ac_try_echo") >&5
19250   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
19251   ac_status=$?
19252   grep -v '^ *+' conftest.er1 >conftest.err
19253   rm -f conftest.er1
19254   cat conftest.err >&5
19255   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19256   (exit $ac_status); } >/dev/null && {
19257          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
19258          test ! -s conftest.err
19259        }; then
19260   ac_header_preproc=yes
19261 else
19262   $as_echo "$as_me: failed program was:" >&5
19263 sed 's/^/| /' conftest.$ac_ext >&5
19264
19265   ac_header_preproc=no
19266 fi
19267
19268 rm -f conftest.err conftest.$ac_ext
19269 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19270 $as_echo "$ac_header_preproc" >&6; }
19271
19272 # So?  What about this header?
19273 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19274   yes:no: )
19275     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: accepted by the compiler, rejected by the preprocessor!" >&5
19276 $as_echo "$as_me: WARNING: selinux/selinux.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
19277     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: proceeding with the compiler's result" >&5
19278 $as_echo "$as_me: WARNING: selinux/selinux.h: proceeding with the compiler's result" >&2;}
19279     ac_header_preproc=yes
19280     ;;
19281   no:yes:* )
19282     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: present but cannot be compiled" >&5
19283 $as_echo "$as_me: WARNING: selinux/selinux.h: present but cannot be compiled" >&2;}
19284     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h:     check for missing prerequisite headers?" >&5
19285 $as_echo "$as_me: WARNING: selinux/selinux.h:     check for missing prerequisite headers?" >&2;}
19286     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: see the Autoconf documentation" >&5
19287 $as_echo "$as_me: WARNING: selinux/selinux.h: see the Autoconf documentation" >&2;}
19288     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h:     section \"Present But Cannot Be Compiled\"" >&5
19289 $as_echo "$as_me: WARNING: selinux/selinux.h:     section \"Present But Cannot Be Compiled\"" >&2;}
19290     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: proceeding with the preprocessor's result" >&5
19291 $as_echo "$as_me: WARNING: selinux/selinux.h: proceeding with the preprocessor's result" >&2;}
19292     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: in the future, the compiler will take precedence" >&5
19293 $as_echo "$as_me: WARNING: selinux/selinux.h: in the future, the compiler will take precedence" >&2;}
19294
19295     ;;
19296 esac
19297 { $as_echo "$as_me:$LINENO: checking for selinux/selinux.h" >&5
19298 $as_echo_n "checking for selinux/selinux.h... " >&6; }
19299 if test "${ac_cv_header_selinux_selinux_h+set}" = set; then
19300   $as_echo_n "(cached) " >&6
19301 else
19302   ac_cv_header_selinux_selinux_h=$ac_header_preproc
19303 fi
19304 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_selinux_selinux_h" >&5
19305 $as_echo "$ac_cv_header_selinux_selinux_h" >&6; }
19306
19307 fi
19308 if test "x$ac_cv_header_selinux_selinux_h" = x""yes; then
19309
19310                         { $as_echo "$as_me:$LINENO: checking for is_selinux_enabled in -lselinux" >&5
19311 $as_echo_n "checking for is_selinux_enabled in -lselinux... " >&6; }
19312 if test "${ac_cv_lib_selinux_is_selinux_enabled+set}" = set; then
19313   $as_echo_n "(cached) " >&6
19314 else
19315   ac_check_lib_save_LIBS=$LIBS
19316 LIBS="-lselinux  $LIBS"
19317 cat >conftest.$ac_ext <<_ACEOF
19318 /* confdefs.h.  */
19319 _ACEOF
19320 cat confdefs.h >>conftest.$ac_ext
19321 cat >>conftest.$ac_ext <<_ACEOF
19322 /* end confdefs.h.  */
19323
19324 /* Override any GCC internal prototype to avoid an error.
19325    Use char because int might match the return type of a GCC
19326    builtin and then its argument prototype would still apply.  */
19327 #ifdef __cplusplus
19328 extern "C"
19329 #endif
19330 char is_selinux_enabled ();
19331 int
19332 main ()
19333 {
19334 return is_selinux_enabled ();
19335   ;
19336   return 0;
19337 }
19338 _ACEOF
19339 rm -f conftest.$ac_objext conftest$ac_exeext
19340 if { (ac_try="$ac_link"
19341 case "(($ac_try" in
19342   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19343   *) ac_try_echo=$ac_try;;
19344 esac
19345 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19346 $as_echo "$ac_try_echo") >&5
19347   (eval "$ac_link") 2>conftest.er1
19348   ac_status=$?
19349   grep -v '^ *+' conftest.er1 >conftest.err
19350   rm -f conftest.er1
19351   cat conftest.err >&5
19352   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19353   (exit $ac_status); } && {
19354          test -z "$ac_c_werror_flag" ||
19355          test ! -s conftest.err
19356        } && test -s conftest$ac_exeext && {
19357          test "$cross_compiling" = yes ||
19358          $as_test_x conftest$ac_exeext
19359        }; then
19360   ac_cv_lib_selinux_is_selinux_enabled=yes
19361 else
19362   $as_echo "$as_me: failed program was:" >&5
19363 sed 's/^/| /' conftest.$ac_ext >&5
19364
19365         ac_cv_lib_selinux_is_selinux_enabled=no
19366 fi
19367
19368 rm -rf conftest.dSYM
19369 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19370       conftest$ac_exeext conftest.$ac_ext
19371 LIBS=$ac_check_lib_save_LIBS
19372 fi
19373 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_selinux_is_selinux_enabled" >&5
19374 $as_echo "$ac_cv_lib_selinux_is_selinux_enabled" >&6; }
19375 if test "x$ac_cv_lib_selinux_is_selinux_enabled" = x""yes; then
19376
19377                                 LIBSELINUX="-lselinux"
19378
19379
19380 cat >>confdefs.h <<\_ACEOF
19381 #define HAVE_LIBSELINUX 1
19382 _ACEOF
19383
19384
19385 else
19386
19387                                 if test "x$with_selinux" != xcheck; then
19388   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
19389 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19390 { { $as_echo "$as_me:$LINENO: error: --with-selinux given but unavailable
19391 See \`config.log' for more details." >&5
19392 $as_echo "$as_me: error: --with-selinux given but unavailable
19393 See \`config.log' for more details." >&2;}
19394    { (exit 1); exit 1; }; }; }
19395
19396 fi
19397
19398
19399 fi
19400
19401
19402 else
19403
19404                         if test "x$with_selinux" != xcheck; then
19405   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
19406 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19407 { { $as_echo "$as_me:$LINENO: error: --with-selinux given but unavailable
19408 See \`config.log' for more details." >&5
19409 $as_echo "$as_me: error: --with-selinux given but unavailable
19410 See \`config.log' for more details." >&2;}
19411    { (exit 1); exit 1; }; }; }
19412
19413 fi
19414
19415
19416 fi
19417
19418
19419
19420 else
19421
19422                 { $as_echo "$as_me:$LINENO: checking for selinux support" >&5
19423 $as_echo_n "checking for selinux support... " >&6; }
19424                 { $as_echo "$as_me:$LINENO: result: no" >&5
19425 $as_echo "no" >&6; }
19426
19427 fi
19428
19429
19430
19431         { $as_echo "$as_me:$LINENO: checking for -Wframe-larger-than=<size> support" >&5
19432 $as_echo_n "checking for -Wframe-larger-than=<size> support... " >&6; }
19433
19434         saved_flags="$CFLAGS"
19435         CFLAGS="$CFLAGS -Wframe-larger-than=1024"
19436
19437         if test "$cross_compiling" = yes; then
19438   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
19439 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19440 { { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19441 See \`config.log' for more details." >&5
19442 $as_echo "$as_me: error: cannot run test program while cross compiling
19443 See \`config.log' for more details." >&2;}
19444    { (exit 1); exit 1; }; }; }
19445 else
19446   cat >conftest.$ac_ext <<_ACEOF
19447 /* confdefs.h.  */
19448 _ACEOF
19449 cat confdefs.h >>conftest.$ac_ext
19450 cat >>conftest.$ac_ext <<_ACEOF
19451 /* end confdefs.h.  */
19452
19453 int
19454 main ()
19455 {
19456
19457   ;
19458   return 0;
19459 }
19460 _ACEOF
19461 rm -f conftest$ac_exeext
19462 if { (ac_try="$ac_link"
19463 case "(($ac_try" in
19464   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19465   *) ac_try_echo=$ac_try;;
19466 esac
19467 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19468 $as_echo "$ac_try_echo") >&5
19469   (eval "$ac_link") 2>&5
19470   ac_status=$?
19471   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19472   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19473   { (case "(($ac_try" in
19474   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19475   *) ac_try_echo=$ac_try;;
19476 esac
19477 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19478 $as_echo "$ac_try_echo") >&5
19479   (eval "$ac_try") 2>&5
19480   ac_status=$?
19481   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19482   (exit $ac_status); }; }; then
19483
19484                 FRAME_LARGER_THAN=-Wframe-larger-than=1024
19485                 { $as_echo "$as_me:$LINENO: result: yes" >&5
19486 $as_echo "yes" >&6; }
19487
19488 else
19489   $as_echo "$as_me: program exited with status $ac_status" >&5
19490 $as_echo "$as_me: failed program was:" >&5
19491 sed 's/^/| /' conftest.$ac_ext >&5
19492
19493 ( exit $ac_status )
19494
19495                 FRAME_LARGER_THAN=
19496                 { $as_echo "$as_me:$LINENO: result: no" >&5
19497 $as_echo "no" >&6; }
19498
19499 fi
19500 rm -rf conftest.dSYM
19501 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19502 fi
19503
19504
19505
19506         CFLAGS="$saved_flags"
19507
19508
19509
19510
19511         { $as_echo "$as_me:$LINENO: checking whether pthread stack includes guard" >&5
19512 $as_echo_n "checking whether pthread stack includes guard... " >&6; }
19513
19514         saved_CFLAGS="$CFLAGS"
19515         CFLAGS="-fstack-check"
19516         saved_LDFLAGS="$LDFLAGS"
19517         LDFLAGS="-lpthread"
19518
19519         if test "$cross_compiling" = yes; then
19520   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
19521 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19522 { { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19523 See \`config.log' for more details." >&5
19524 $as_echo "$as_me: error: cannot run test program while cross compiling
19525 See \`config.log' for more details." >&2;}
19526    { (exit 1); exit 1; }; }; }
19527 else
19528   cat >conftest.$ac_ext <<_ACEOF
19529 /* confdefs.h.  */
19530 _ACEOF
19531 cat confdefs.h >>conftest.$ac_ext
19532 cat >>conftest.$ac_ext <<_ACEOF
19533 /* end confdefs.h.  */
19534
19535                 #include <pthread.h>
19536                 #include <sys/resource.h>
19537                 #include <unistd.h>
19538                 #include <bits/local_lim.h>
19539
19540                 #define PAGESIZE (sysconf(_SC_PAGESIZE))
19541                 #define STACK_SIZE 8192
19542                 #define BUFSIZE 4096
19543
19544                 void * func(void *arg)
19545                 {
19546                         char buf[BUFSIZE];
19547                 }
19548
19549 int
19550 main ()
19551 {
19552
19553                 pthread_t tid;
19554                 pthread_attr_t attr;
19555                 struct rlimit l;
19556
19557                 l.rlim_cur = 0;
19558                 l.rlim_max = 0;
19559                 setrlimit(RLIMIT_CORE, &l);
19560                 pthread_attr_init(&attr);
19561                 pthread_attr_setstacksize(&attr, PTHREAD_STACK_MIN + STACK_SIZE);
19562                 pthread_attr_setguardsize(&attr, PAGESIZE);
19563                 pthread_create(&tid, &attr, func, NULL);
19564                 pthread_join(tid, NULL);
19565
19566   ;
19567   return 0;
19568 }
19569 _ACEOF
19570 rm -f conftest$ac_exeext
19571 if { (ac_try="$ac_link"
19572 case "(($ac_try" in
19573   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19574   *) ac_try_echo=$ac_try;;
19575 esac
19576 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19577 $as_echo "$ac_try_echo") >&5
19578   (eval "$ac_link") 2>&5
19579   ac_status=$?
19580   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19581   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19582   { (case "(($ac_try" in
19583   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19584   *) ac_try_echo=$ac_try;;
19585 esac
19586 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19587 $as_echo "$ac_try_echo") >&5
19588   (eval "$ac_try") 2>&5
19589   ac_status=$?
19590   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19591   (exit $ac_status); }; }; then
19592
19593                 { $as_echo "$as_me:$LINENO: result: no" >&5
19594 $as_echo "no" >&6; }
19595
19596 else
19597   $as_echo "$as_me: program exited with status $ac_status" >&5
19598 $as_echo "$as_me: failed program was:" >&5
19599 sed 's/^/| /' conftest.$ac_ext >&5
19600
19601 ( exit $ac_status )
19602
19603
19604 cat >>confdefs.h <<\_ACEOF
19605 #define NPTL_GUARD_WITHIN_STACK 1
19606 _ACEOF
19607
19608                 { $as_echo "$as_me:$LINENO: result: yes" >&5
19609 $as_echo "yes" >&6; }
19610
19611 fi
19612 rm -rf conftest.dSYM
19613 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19614 fi
19615
19616
19617         CFLAGS="$saved_CFLAGS"
19618         LDFLAGS="$saved_LDFLAGS"
19619
19620    ;;
19621                 all)
19622
19623
19624 # Check whether --with-linux was given.
19625 if test "${with_linux+set}" = set; then
19626   withval=$with_linux; kernelsrc="$withval"
19627 fi
19628
19629
19630
19631 # Check whether --with-linux-obj was given.
19632 if test "${with_linux_obj+set}" = set; then
19633   withval=$with_linux_obj; kernelbuild="$withval"
19634 fi
19635
19636
19637         { $as_echo "$as_me:$LINENO: checking kernel source directory" >&5
19638 $as_echo_n "checking kernel source directory... " >&6; }
19639         if test -z "$kernelsrc"; then
19640
19641                 if test -e "/lib/modules/$(uname -r)/source"; then
19642
19643                         headersdir="/lib/modules/$(uname -r)/source"
19644                         sourcelink=$(readlink -f "$headersdir")
19645
19646 elif test -e "/lib/modules/$(uname -r)/build"; then
19647
19648                         headersdir="/lib/modules/$(uname -r)/build"
19649                         sourcelink=$(readlink -f "$headersdir")
19650
19651 else
19652
19653                         sourcelink=$(ls -1d /usr/src/kernels/* \
19654                                      /usr/src/linux-* \
19655                                      2>/dev/null | grep -v obj | tail -1)
19656
19657 fi
19658
19659
19660                 if test -n "$sourcelink" && test -e ${sourcelink}; then
19661
19662                         kernelsrc=`readlink -f ${sourcelink}`
19663
19664 else
19665
19666                         { $as_echo "$as_me:$LINENO: result: Not found" >&5
19667 $as_echo "Not found" >&6; }
19668                         { { $as_echo "$as_me:$LINENO: error:
19669         *** Please make sure the kernel devel package for your distribution
19670         *** is installed then try again.  If that fails you can specify the
19671         *** location of the kernel source with the '--with-linux=PATH' option." >&5
19672 $as_echo "$as_me: error:
19673         *** Please make sure the kernel devel package for your distribution
19674         *** is installed then try again.  If that fails you can specify the
19675         *** location of the kernel source with the '--with-linux=PATH' option." >&2;}
19676    { (exit 1); exit 1; }; }
19677
19678 fi
19679
19680
19681 else
19682
19683                 if test "$kernelsrc" = "NONE"; then
19684
19685                         kernsrcver=NONE
19686
19687 fi
19688
19689
19690 fi
19691
19692
19693         { $as_echo "$as_me:$LINENO: result: $kernelsrc" >&5
19694 $as_echo "$kernelsrc" >&6; }
19695         { $as_echo "$as_me:$LINENO: checking kernel build directory" >&5
19696 $as_echo_n "checking kernel build directory... " >&6; }
19697         if test -z "$kernelbuild"; then
19698
19699                 if test -e "/lib/modules/$(uname -r)/build"; then
19700
19701                         kernelbuild=`readlink -f /lib/modules/$(uname -r)/build`
19702
19703 elif test -d ${kernelsrc}-obj/${target_cpu}/${target_cpu}; then
19704
19705                         kernelbuild=${kernelsrc}-obj/${target_cpu}/${target_cpu}
19706
19707 elif test -d ${kernelsrc}-obj/${target_cpu}/default; then
19708
19709                         kernelbuild=${kernelsrc}-obj/${target_cpu}/default
19710
19711 elif test -d `dirname ${kernelsrc}`/build-${target_cpu}; then
19712
19713                         kernelbuild=`dirname ${kernelsrc}`/build-${target_cpu}
19714
19715 else
19716
19717                         kernelbuild=${kernelsrc}
19718
19719 fi
19720
19721
19722 fi
19723
19724         { $as_echo "$as_me:$LINENO: result: $kernelbuild" >&5
19725 $as_echo "$kernelbuild" >&6; }
19726
19727         { $as_echo "$as_me:$LINENO: checking kernel source version" >&5
19728 $as_echo_n "checking kernel source version... " >&6; }
19729         utsrelease1=$kernelbuild/include/linux/version.h
19730         utsrelease2=$kernelbuild/include/linux/utsrelease.h
19731         utsrelease3=$kernelbuild/include/generated/utsrelease.h
19732         if test -r $utsrelease1 && fgrep -q UTS_RELEASE $utsrelease1; then
19733
19734                 utsrelease=linux/version.h
19735
19736 elif test -r $utsrelease2 && fgrep -q UTS_RELEASE $utsrelease2; then
19737
19738                 utsrelease=linux/utsrelease.h
19739
19740 elif test -r $utsrelease3 && fgrep -q UTS_RELEASE $utsrelease3; then
19741
19742                 utsrelease=generated/utsrelease.h
19743
19744 fi
19745
19746
19747         if test "$utsrelease"; then
19748
19749                 kernsrcver=`(echo "#include <$utsrelease>";
19750                              echo "kernsrcver=UTS_RELEASE") |
19751                              cpp -I $kernelbuild/include |
19752                              grep "^kernsrcver=" | cut -d \" -f 2`
19753
19754                 if test -z "$kernsrcver"; then
19755
19756                         { $as_echo "$as_me:$LINENO: result: Not found" >&5
19757 $as_echo "Not found" >&6; }
19758                         { { $as_echo "$as_me:$LINENO: error: *** Cannot determine kernel version." >&5
19759 $as_echo "$as_me: error: *** Cannot determine kernel version." >&2;}
19760    { (exit 1); exit 1; }; }
19761
19762 fi
19763
19764
19765 else
19766
19767                 { $as_echo "$as_me:$LINENO: result: Not found" >&5
19768 $as_echo "Not found" >&6; }
19769                 if test "x$enable_linux_builtin" != xyes; then
19770                         { { $as_echo "$as_me:$LINENO: error: *** Cannot find UTS_RELEASE definition." >&5
19771 $as_echo "$as_me: error: *** Cannot find UTS_RELEASE definition." >&2;}
19772    { (exit 1); exit 1; }; }
19773                 else
19774                         { { $as_echo "$as_me:$LINENO: error:
19775         *** Cannot find UTS_RELEASE definition.
19776         *** Please run 'make prepare' inside the kernel source tree." >&5
19777 $as_echo "$as_me: error:
19778         *** Cannot find UTS_RELEASE definition.
19779         *** Please run 'make prepare' inside the kernel source tree." >&2;}
19780    { (exit 1); exit 1; }; }
19781                 fi
19782
19783 fi
19784
19785
19786         { $as_echo "$as_me:$LINENO: result: $kernsrcver" >&5
19787 $as_echo "$kernsrcver" >&6; }
19788
19789         LINUX=${kernelsrc}
19790         LINUX_OBJ=${kernelbuild}
19791         LINUX_VERSION=${kernsrcver}
19792
19793
19794
19795
19796
19797
19798         modpost=$LINUX/scripts/Makefile.modpost
19799         { $as_echo "$as_me:$LINENO: checking kernel file name for module symbols" >&5
19800 $as_echo_n "checking kernel file name for module symbols... " >&6; }
19801         if test "x$enable_linux_builtin" != xyes -a -f "$modpost"; then
19802
19803                 if grep -q Modules.symvers $modpost; then
19804
19805                         LINUX_SYMBOLS=Modules.symvers
19806
19807 else
19808
19809                         LINUX_SYMBOLS=Module.symvers
19810
19811 fi
19812
19813
19814                 if test ! -f "$LINUX_OBJ/$LINUX_SYMBOLS"; then
19815
19816                         { { $as_echo "$as_me:$LINENO: error:
19817         *** Please make sure the kernel devel package for your distribution
19818         *** is installed.  If your building with a custom kernel make sure the
19819         *** kernel is configured, built, and the '--with-linux=PATH' configure
19820         *** option refers to the location of the kernel source." >&5
19821 $as_echo "$as_me: error:
19822         *** Please make sure the kernel devel package for your distribution
19823         *** is installed.  If your building with a custom kernel make sure the
19824         *** kernel is configured, built, and the '--with-linux=PATH' configure
19825         *** option refers to the location of the kernel source." >&2;}
19826    { (exit 1); exit 1; }; }
19827
19828 fi
19829
19830
19831 else
19832
19833                 LINUX_SYMBOLS=NONE
19834
19835 fi
19836
19837         { $as_echo "$as_me:$LINENO: result: $LINUX_SYMBOLS" >&5
19838 $as_echo "$LINUX_SYMBOLS" >&6; }
19839
19840
19841
19842
19843
19844 # Check whether --with-spl was given.
19845 if test "${with_spl+set}" = set; then
19846   withval=$with_spl; splsrc="$withval"
19847 fi
19848
19849
19850
19851 # Check whether --with-spl-obj was given.
19852 if test "${with_spl_obj+set}" = set; then
19853   withval=$with_spl_obj; splbuild="$withval"
19854 fi
19855
19856
19857
19858         { $as_echo "$as_me:$LINENO: checking spl source directory" >&5
19859 $as_echo_n "checking spl source directory... " >&6; }
19860         if test -z "$splsrc"; then
19861
19862                 sourcelink=`ls -1d /usr/src/spl-*/${LINUX_VERSION} \
19863                             2>/dev/null | tail -1`
19864
19865                 if test -z "$sourcelink" || test ! -e $sourcelink; then
19866
19867                         sourcelink=../spl
19868
19869 fi
19870
19871
19872                 if test -e $sourcelink; then
19873
19874                         splsrc=`readlink -f ${sourcelink}`
19875
19876 else
19877
19878                         { $as_echo "$as_me:$LINENO: result: Not found" >&5
19879 $as_echo "Not found" >&6; }
19880                         { { $as_echo "$as_me:$LINENO: error:
19881         *** Please make sure the spl devel package for your distribution
19882         *** is installed then try again.  If that fails you can specify the
19883         *** location of the spl source with the '--with-spl=PATH' option." >&5
19884 $as_echo "$as_me: error:
19885         *** Please make sure the spl devel package for your distribution
19886         *** is installed then try again.  If that fails you can specify the
19887         *** location of the spl source with the '--with-spl=PATH' option." >&2;}
19888    { (exit 1); exit 1; }; }
19889
19890 fi
19891
19892
19893 else
19894
19895                 if test "$splsrc" = "NONE"; then
19896
19897                         splbuild=NONE
19898                         splsrcver=NONE
19899
19900 fi
19901
19902
19903 fi
19904
19905
19906         { $as_echo "$as_me:$LINENO: result: $splsrc" >&5
19907 $as_echo "$splsrc" >&6; }
19908         { $as_echo "$as_me:$LINENO: checking spl build directory" >&5
19909 $as_echo_n "checking spl build directory... " >&6; }
19910         if test -z "$splbuild"; then
19911
19912                 splbuild=${splsrc}
19913
19914 fi
19915
19916         { $as_echo "$as_me:$LINENO: result: $splbuild" >&5
19917 $as_echo "$splbuild" >&6; }
19918
19919         { $as_echo "$as_me:$LINENO: checking spl source version" >&5
19920 $as_echo_n "checking spl source version... " >&6; }
19921         if test -r $splbuild/spl_config.h &&
19922                 fgrep -q SPL_META_VERSION $splbuild/spl_config.h; then
19923
19924
19925                 splsrcver=`(echo "#include <spl_config.h>";
19926                             echo "splsrcver=SPL_META_VERSION-SPL_META_RELEASE") |
19927                             cpp -I $splbuild |
19928                             grep "^splsrcver=" | tr -d \" | cut -d= -f2`
19929
19930 fi
19931
19932
19933         if test -z "$splsrcver"; then
19934
19935                 { $as_echo "$as_me:$LINENO: result: Not found" >&5
19936 $as_echo "Not found" >&6; }
19937                 { { $as_echo "$as_me:$LINENO: error:
19938         *** Cannot determine the version of the spl source.
19939         *** Please prepare the spl source before running this script" >&5
19940 $as_echo "$as_me: error:
19941         *** Cannot determine the version of the spl source.
19942         *** Please prepare the spl source before running this script" >&2;}
19943    { (exit 1); exit 1; }; }
19944
19945 fi
19946
19947
19948         { $as_echo "$as_me:$LINENO: result: $splsrcver" >&5
19949 $as_echo "$splsrcver" >&6; }
19950
19951         SPL=${splsrc}
19952         SPL_OBJ=${splbuild}
19953         SPL_VERSION=${splsrcver}
19954
19955
19956
19957
19958
19959
19960         { $as_echo "$as_me:$LINENO: checking spl file name for module symbols" >&5
19961 $as_echo_n "checking spl file name for module symbols... " >&6; }
19962         if test -r $SPL_OBJ/Module.symvers; then
19963
19964                 SPL_SYMBOLS=Module.symvers
19965
19966 elif test -r $SPL_OBJ/Modules.symvers; then
19967
19968                 SPL_SYMBOLS=Modules.symvers
19969
19970 elif test -r $SPL_OBJ/module/Module.symvers; then
19971
19972                 SPL_SYMBOLS=Module.symvers
19973
19974 elif test -r $SPL_OBJ/module/Modules.symvers; then
19975
19976                 SPL_SYMBOLS=Modules.symvers
19977
19978 else
19979
19980                 SPL_SYMBOLS=$LINUX_SYMBOLS
19981
19982 fi
19983
19984
19985         { $as_echo "$as_me:$LINENO: result: $SPL_SYMBOLS" >&5
19986 $as_echo "$SPL_SYMBOLS" >&6; }
19987
19988
19989
19990         { $as_echo "$as_me:$LINENO: checking whether modules can be built" >&5
19991 $as_echo_n "checking whether modules can be built... " >&6; }
19992
19993
19994 cat confdefs.h - <<_ACEOF >conftest.c
19995 /* confdefs.h.  */
19996 _ACEOF
19997 cat confdefs.h >>conftest.$ac_ext
19998 cat >>conftest.$ac_ext <<_ACEOF
19999 /* end confdefs.h.  */
20000
20001
20002 int
20003 main (void)
20004 {
20005
20006   ;
20007   return 0;
20008 }
20009
20010 _ACEOF
20011
20012
20013         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20014         echo "obj-m := conftest.o" >build/Makefile
20015         modpost_flag=''
20016         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20017         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20018   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20019   (eval $ac_try) 2>&5
20020   ac_status=$?
20021   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20022   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20023   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20024   (eval $ac_try) 2>&5
20025   ac_status=$?
20026   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20027   (exit $ac_status); }; }; then
20028
20029                 { $as_echo "$as_me:$LINENO: result: yes" >&5
20030 $as_echo "yes" >&6; }
20031
20032 else
20033   $as_echo "$as_me: failed program was:" >&5
20034 sed 's/^/| /' conftest.$ac_ext >&5
20035
20036                 { $as_echo "$as_me:$LINENO: result: no" >&5
20037 $as_echo "no" >&6; }
20038                 if test "x$enable_linux_builtin" != xyes; then
20039                         { { $as_echo "$as_me:$LINENO: error: *** Unable to build an empty module." >&5
20040 $as_echo "$as_me: error: *** Unable to build an empty module." >&2;}
20041    { (exit 1); exit 1; }; }
20042                 else
20043                         { { $as_echo "$as_me:$LINENO: error:
20044         *** Unable to build an empty module.
20045         *** Please run 'make scripts' inside the kernel source tree." >&5
20046 $as_echo "$as_me: error:
20047         *** Unable to build an empty module.
20048         *** Please run 'make scripts' inside the kernel source tree." >&2;}
20049    { (exit 1); exit 1; }; }
20050                 fi
20051
20052
20053
20054 fi
20055
20056         rm -Rf build
20057
20058
20059
20060
20061
20062         if test "$ZFS_META_LICENSE" = GPL; then
20063
20064
20065 cat >>confdefs.h <<\_ACEOF
20066 #define HAVE_GPL_ONLY_SYMBOLS 1
20067 _ACEOF
20068
20069
20070 fi
20071
20072
20073
20074
20075         { $as_echo "$as_me:$LINENO: checking whether Linux was built with CONFIG_PREEMPT" >&5
20076 $as_echo_n "checking whether Linux was built with CONFIG_PREEMPT... " >&6; }
20077
20078
20079 cat confdefs.h - <<_ACEOF >conftest.c
20080 /* confdefs.h.  */
20081 _ACEOF
20082 cat confdefs.h >>conftest.$ac_ext
20083 cat >>conftest.$ac_ext <<_ACEOF
20084 /* end confdefs.h.  */
20085
20086
20087                 #include <linux/module.h>
20088
20089 int
20090 main (void)
20091 {
20092
20093                 #ifndef CONFIG_PREEMPT
20094                 #error CONFIG_PREEMPT not #defined
20095                 #endif
20096
20097   ;
20098   return 0;
20099 }
20100
20101 _ACEOF
20102
20103
20104         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20105         echo "obj-m := conftest.o" >build/Makefile
20106         modpost_flag=''
20107         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20108         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20109   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20110   (eval $ac_try) 2>&5
20111   ac_status=$?
20112   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20113   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20114   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20115   (eval $ac_try) 2>&5
20116   ac_status=$?
20117   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20118   (exit $ac_status); }; }; then
20119
20120                 { $as_echo "$as_me:$LINENO: result: yes" >&5
20121 $as_echo "yes" >&6; }
20122                 { { $as_echo "$as_me:$LINENO: error:
20123         *** Kernel built with CONFIG_PREEMPT which is not supported.
20124         *** You must rebuild your kernel without this option." >&5
20125 $as_echo "$as_me: error:
20126         *** Kernel built with CONFIG_PREEMPT which is not supported.
20127         *** You must rebuild your kernel without this option." >&2;}
20128    { (exit 1); exit 1; }; }
20129
20130 else
20131   $as_echo "$as_me: failed program was:" >&5
20132 sed 's/^/| /' conftest.$ac_ext >&5
20133
20134                 { $as_echo "$as_me:$LINENO: result: no" >&5
20135 $as_echo "no" >&6; }
20136
20137
20138
20139
20140 fi
20141
20142         rm -Rf build
20143
20144
20145
20146
20147
20148
20149         { $as_echo "$as_me:$LINENO: checking whether Linux was built with CONFIG_DEBUG_LOCK_ALLOC" >&5
20150 $as_echo_n "checking whether Linux was built with CONFIG_DEBUG_LOCK_ALLOC... " >&6; }
20151
20152
20153 cat confdefs.h - <<_ACEOF >conftest.c
20154 /* confdefs.h.  */
20155 _ACEOF
20156 cat confdefs.h >>conftest.$ac_ext
20157 cat >>conftest.$ac_ext <<_ACEOF
20158 /* end confdefs.h.  */
20159
20160
20161                 #include <linux/module.h>
20162
20163 int
20164 main (void)
20165 {
20166
20167                 #ifndef CONFIG_DEBUG_LOCK_ALLOC
20168                 #error CONFIG_DEBUG_LOCK_ALLOC not #defined
20169                 #endif
20170
20171   ;
20172   return 0;
20173 }
20174
20175 _ACEOF
20176
20177
20178         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20179         echo "obj-m := conftest.o" >build/Makefile
20180         modpost_flag=''
20181         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20182         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20183   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20184   (eval $ac_try) 2>&5
20185   ac_status=$?
20186   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20187   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20189   (eval $ac_try) 2>&5
20190   ac_status=$?
20191   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20192   (exit $ac_status); }; }; then
20193
20194                 { $as_echo "$as_me:$LINENO: result: yes" >&5
20195 $as_echo "yes" >&6; }
20196
20197                 { $as_echo "$as_me:$LINENO: checking whether mutex_lock() is GPL-only" >&5
20198 $as_echo_n "checking whether mutex_lock() is GPL-only... " >&6; }
20199                 tmp_flags="$EXTRA_KCFLAGS"
20200
20201
20202 cat confdefs.h - <<_ACEOF >conftest.c
20203 /* confdefs.h.  */
20204 _ACEOF
20205 cat confdefs.h >>conftest.$ac_ext
20206 cat >>conftest.$ac_ext <<_ACEOF
20207 /* end confdefs.h.  */
20208
20209
20210                         #include <linux/module.h>
20211                         #include <linux/mutex.h>
20212
20213                         MODULE_LICENSE("$ZFS_META_LICENSE");
20214
20215 int
20216 main (void)
20217 {
20218
20219                         struct mutex lock;
20220
20221                         mutex_init(&lock);
20222                         mutex_lock(&lock);
20223                         mutex_unlock(&lock);
20224
20225   ;
20226   return 0;
20227 }
20228
20229 _ACEOF
20230
20231
20232         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20233         echo "obj-m := conftest.o" >build/Makefile
20234         modpost_flag=''
20235         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20236         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20237   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20238   (eval $ac_try) 2>&5
20239   ac_status=$?
20240   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20241   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20242   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20243   (eval $ac_try) 2>&5
20244   ac_status=$?
20245   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20246   (exit $ac_status); }; }; then
20247
20248                         { $as_echo "$as_me:$LINENO: result: no" >&5
20249 $as_echo "no" >&6; }
20250
20251 else
20252   $as_echo "$as_me: failed program was:" >&5
20253 sed 's/^/| /' conftest.$ac_ext >&5
20254
20255                         { $as_echo "$as_me:$LINENO: result: yes" >&5
20256 $as_echo "yes" >&6; }
20257                         { { $as_echo "$as_me:$LINENO: error:
20258         *** Kernel built with CONFIG_DEBUG_LOCK_ALLOC which is incompatible
20259         *** with the CDDL license and will prevent the module linking stage
20260         *** from succeeding.  You must rebuild your kernel without this
20261         *** option enabled." >&5
20262 $as_echo "$as_me: error:
20263         *** Kernel built with CONFIG_DEBUG_LOCK_ALLOC which is incompatible
20264         *** with the CDDL license and will prevent the module linking stage
20265         *** from succeeding.  You must rebuild your kernel without this
20266         *** option enabled." >&2;}
20267    { (exit 1); exit 1; }; }
20268
20269
20270
20271 fi
20272
20273         rm -Rf build
20274
20275
20276                 EXTRA_KCFLAGS="$tmp_flags"
20277
20278
20279 else
20280   $as_echo "$as_me: failed program was:" >&5
20281 sed 's/^/| /' conftest.$ac_ext >&5
20282
20283                 { $as_echo "$as_me:$LINENO: result: no" >&5
20284 $as_echo "no" >&6; }
20285
20286
20287
20288
20289 fi
20290
20291         rm -Rf build
20292
20293
20294
20295
20296
20297
20298         { $as_echo "$as_me:$LINENO: checking block device operation prototypes" >&5
20299 $as_echo_n "checking block device operation prototypes... " >&6; }
20300         tmp_flags="$EXTRA_KCFLAGS"
20301         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
20302
20303
20304 cat confdefs.h - <<_ACEOF >conftest.c
20305 /* confdefs.h.  */
20306 _ACEOF
20307 cat confdefs.h >>conftest.$ac_ext
20308 cat >>conftest.$ac_ext <<_ACEOF
20309 /* end confdefs.h.  */
20310
20311
20312                 #include <linux/blkdev.h>
20313
20314 int
20315 main (void)
20316 {
20317
20318                 int (*blk_open) (struct block_device *, fmode_t) = NULL;
20319                 int (*blk_release) (struct gendisk *, fmode_t) = NULL;
20320                 int (*blk_ioctl) (struct block_device *, fmode_t,
20321                                   unsigned, unsigned long) = NULL;
20322                 int (*blk_compat_ioctl) (struct block_device *, fmode_t,
20323                                          unsigned, unsigned long) = NULL;
20324                 struct block_device_operations blk_ops = {
20325                         .open           = blk_open,
20326                         .release        = blk_release,
20327                         .ioctl          = blk_ioctl,
20328                         .compat_ioctl   = blk_compat_ioctl,
20329                 };
20330
20331                 blk_ops.open(NULL, 0);
20332                 blk_ops.release(NULL, 0);
20333                 blk_ops.ioctl(NULL, 0, 0, 0);
20334                 blk_ops.compat_ioctl(NULL, 0, 0, 0);
20335
20336   ;
20337   return 0;
20338 }
20339
20340 _ACEOF
20341
20342
20343         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20344         echo "obj-m := conftest.o" >build/Makefile
20345         modpost_flag=''
20346         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20347         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20348   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20349   (eval $ac_try) 2>&5
20350   ac_status=$?
20351   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20352   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20353   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20354   (eval $ac_try) 2>&5
20355   ac_status=$?
20356   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20357   (exit $ac_status); }; }; then
20358
20359                 { $as_echo "$as_me:$LINENO: result: struct block_device" >&5
20360 $as_echo "struct block_device" >&6; }
20361
20362 cat >>confdefs.h <<\_ACEOF
20363 #define HAVE_BDEV_BLOCK_DEVICE_OPERATIONS 1
20364 _ACEOF
20365
20366
20367 else
20368   $as_echo "$as_me: failed program was:" >&5
20369 sed 's/^/| /' conftest.$ac_ext >&5
20370
20371                 { $as_echo "$as_me:$LINENO: result: struct inode" >&5
20372 $as_echo "struct inode" >&6; }
20373
20374
20375
20376 fi
20377
20378         rm -Rf build
20379
20380
20381         EXTRA_KCFLAGS="$tmp_flags"
20382
20383         { $as_echo "$as_me:$LINENO: checking whether kernel defines fmode_t" >&5
20384 $as_echo_n "checking whether kernel defines fmode_t... " >&6; }
20385
20386
20387 cat confdefs.h - <<_ACEOF >conftest.c
20388 /* confdefs.h.  */
20389 _ACEOF
20390 cat confdefs.h >>conftest.$ac_ext
20391 cat >>conftest.$ac_ext <<_ACEOF
20392 /* end confdefs.h.  */
20393
20394
20395                 #include <linux/types.h>
20396
20397 int
20398 main (void)
20399 {
20400
20401                 fmode_t *ptr __attribute__ ((unused));
20402
20403   ;
20404   return 0;
20405 }
20406
20407 _ACEOF
20408
20409
20410         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20411         echo "obj-m := conftest.o" >build/Makefile
20412         modpost_flag=''
20413         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20414         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20415   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20416   (eval $ac_try) 2>&5
20417   ac_status=$?
20418   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20419   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20420   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20421   (eval $ac_try) 2>&5
20422   ac_status=$?
20423   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20424   (exit $ac_status); }; }; then
20425
20426                 { $as_echo "$as_me:$LINENO: result: yes" >&5
20427 $as_echo "yes" >&6; }
20428
20429 cat >>confdefs.h <<\_ACEOF
20430 #define HAVE_FMODE_T 1
20431 _ACEOF
20432
20433
20434 else
20435   $as_echo "$as_me: failed program was:" >&5
20436 sed 's/^/| /' conftest.$ac_ext >&5
20437
20438                 { $as_echo "$as_me:$LINENO: result: no" >&5
20439 $as_echo "no" >&6; }
20440
20441
20442
20443 fi
20444
20445         rm -Rf build
20446
20447
20448
20449
20450         { $as_echo "$as_me:$LINENO: checking whether kernel defines KOBJ_NAME_LEN" >&5
20451 $as_echo_n "checking whether kernel defines KOBJ_NAME_LEN... " >&6; }
20452
20453
20454 cat confdefs.h - <<_ACEOF >conftest.c
20455 /* confdefs.h.  */
20456 _ACEOF
20457 cat confdefs.h >>conftest.$ac_ext
20458 cat >>conftest.$ac_ext <<_ACEOF
20459 /* end confdefs.h.  */
20460
20461
20462                 #include <linux/kobject.h>
20463
20464 int
20465 main (void)
20466 {
20467
20468                 int val __attribute__ ((unused));
20469                 val = KOBJ_NAME_LEN;
20470
20471   ;
20472   return 0;
20473 }
20474
20475 _ACEOF
20476
20477
20478         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20479         echo "obj-m := conftest.o" >build/Makefile
20480         modpost_flag=''
20481         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20482         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20483   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20484   (eval $ac_try) 2>&5
20485   ac_status=$?
20486   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20487   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20488   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20489   (eval $ac_try) 2>&5
20490   ac_status=$?
20491   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20492   (exit $ac_status); }; }; then
20493
20494                 { $as_echo "$as_me:$LINENO: result: yes" >&5
20495 $as_echo "yes" >&6; }
20496
20497 cat >>confdefs.h <<\_ACEOF
20498 #define HAVE_KOBJ_NAME_LEN 1
20499 _ACEOF
20500
20501
20502 else
20503   $as_echo "$as_me: failed program was:" >&5
20504 sed 's/^/| /' conftest.$ac_ext >&5
20505
20506                 { $as_echo "$as_me:$LINENO: result: no" >&5
20507 $as_echo "no" >&6; }
20508
20509
20510
20511 fi
20512
20513         rm -Rf build
20514
20515
20516
20517
20518         { $as_echo "$as_me:$LINENO: checking whether blkdev_get() wants 3 args" >&5
20519 $as_echo_n "checking whether blkdev_get() wants 3 args... " >&6; }
20520
20521
20522 cat confdefs.h - <<_ACEOF >conftest.c
20523 /* confdefs.h.  */
20524 _ACEOF
20525 cat confdefs.h >>conftest.$ac_ext
20526 cat >>conftest.$ac_ext <<_ACEOF
20527 /* end confdefs.h.  */
20528
20529
20530                 #include <linux/fs.h>
20531
20532 int
20533 main (void)
20534 {
20535
20536                 struct block_device *bdev = NULL;
20537                 (void) blkdev_get(bdev, 0, NULL);
20538
20539   ;
20540   return 0;
20541 }
20542
20543 _ACEOF
20544
20545
20546         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20547         echo "obj-m := conftest.o" >build/Makefile
20548         modpost_flag=''
20549         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20550         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20551   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20552   (eval $ac_try) 2>&5
20553   ac_status=$?
20554   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20555   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20556   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20557   (eval $ac_try) 2>&5
20558   ac_status=$?
20559   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20560   (exit $ac_status); }; }; then
20561
20562                 { $as_echo "$as_me:$LINENO: result: yes" >&5
20563 $as_echo "yes" >&6; }
20564
20565 cat >>confdefs.h <<\_ACEOF
20566 #define HAVE_3ARG_BLKDEV_GET 1
20567 _ACEOF
20568
20569
20570 else
20571   $as_echo "$as_me: failed program was:" >&5
20572 sed 's/^/| /' conftest.$ac_ext >&5
20573
20574                 { $as_echo "$as_me:$LINENO: result: no" >&5
20575 $as_echo "no" >&6; }
20576
20577
20578
20579 fi
20580
20581         rm -Rf build
20582
20583
20584
20585         { $as_echo "$as_me:$LINENO: checking whether blkdev_get_by_path() is available" >&5
20586 $as_echo_n "checking whether blkdev_get_by_path() is available... " >&6; }
20587
20588
20589
20590 cat confdefs.h - <<_ACEOF >conftest.c
20591 /* confdefs.h.  */
20592 _ACEOF
20593 cat confdefs.h >>conftest.$ac_ext
20594 cat >>conftest.$ac_ext <<_ACEOF
20595 /* end confdefs.h.  */
20596
20597
20598                 #include <linux/fs.h>
20599
20600 int
20601 main (void)
20602 {
20603
20604                 blkdev_get_by_path(NULL, 0, NULL);
20605
20606   ;
20607   return 0;
20608 }
20609
20610 _ACEOF
20611
20612
20613         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20614         echo "obj-m := conftest.o" >build/Makefile
20615         modpost_flag=''
20616         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20617         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20618   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20619   (eval $ac_try) 2>&5
20620   ac_status=$?
20621   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20622   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20623   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20624   (eval $ac_try) 2>&5
20625   ac_status=$?
20626   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20627   (exit $ac_status); }; }; then
20628   rc=0
20629 else
20630   $as_echo "$as_me: failed program was:" >&5
20631 sed 's/^/| /' conftest.$ac_ext >&5
20632  rc=1
20633
20634
20635 fi
20636
20637         rm -Rf build
20638
20639
20640         if test $rc -ne 0; then :
20641
20642                 { $as_echo "$as_me:$LINENO: result: no" >&5
20643 $as_echo "no" >&6; }
20644
20645         else
20646                 if test "x$enable_linux_builtin" != xyes; then
20647
20648         grep -q -E '[[:space:]]blkdev_get_by_path[[:space:]]' \
20649                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
20650         rc=$?
20651         if test $rc -ne 0; then
20652                 export=0
20653                 for file in fs/block_dev.c; do
20654                         grep -q -E "EXPORT_SYMBOL.*(blkdev_get_by_path)" \
20655                                 "$LINUX/$file" 2>/dev/null
20656                         rc=$?
20657                         if test $rc -eq 0; then
20658                                 export=1
20659                                 break;
20660                         fi
20661                 done
20662                 if test $export -eq 0; then :
20663                         rc=1
20664                 else :
20665                         rc=0
20666                 fi
20667         else :
20668                 rc=0
20669         fi
20670
20671                 fi
20672                 if test $rc -ne 0; then :
20673
20674                 { $as_echo "$as_me:$LINENO: result: no" >&5
20675 $as_echo "no" >&6; }
20676
20677                 else :
20678
20679                 { $as_echo "$as_me:$LINENO: result: yes" >&5
20680 $as_echo "yes" >&6; }
20681
20682 cat >>confdefs.h <<\_ACEOF
20683 #define HAVE_BLKDEV_GET_BY_PATH 1
20684 _ACEOF
20685
20686
20687                 fi
20688         fi
20689
20690
20691         { $as_echo "$as_me:$LINENO: checking whether open_bdev_exclusive() is available" >&5
20692 $as_echo_n "checking whether open_bdev_exclusive() is available... " >&6; }
20693
20694
20695
20696 cat confdefs.h - <<_ACEOF >conftest.c
20697 /* confdefs.h.  */
20698 _ACEOF
20699 cat confdefs.h >>conftest.$ac_ext
20700 cat >>conftest.$ac_ext <<_ACEOF
20701 /* end confdefs.h.  */
20702
20703
20704                 #include <linux/fs.h>
20705
20706 int
20707 main (void)
20708 {
20709
20710                 open_bdev_exclusive(NULL, 0, NULL);
20711
20712   ;
20713   return 0;
20714 }
20715
20716 _ACEOF
20717
20718
20719         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20720         echo "obj-m := conftest.o" >build/Makefile
20721         modpost_flag=''
20722         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20723         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20724   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20725   (eval $ac_try) 2>&5
20726   ac_status=$?
20727   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20728   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20729   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20730   (eval $ac_try) 2>&5
20731   ac_status=$?
20732   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20733   (exit $ac_status); }; }; then
20734   rc=0
20735 else
20736   $as_echo "$as_me: failed program was:" >&5
20737 sed 's/^/| /' conftest.$ac_ext >&5
20738  rc=1
20739
20740
20741 fi
20742
20743         rm -Rf build
20744
20745
20746         if test $rc -ne 0; then :
20747
20748                 { $as_echo "$as_me:$LINENO: result: no" >&5
20749 $as_echo "no" >&6; }
20750
20751         else
20752                 if test "x$enable_linux_builtin" != xyes; then
20753
20754         grep -q -E '[[:space:]]open_bdev_exclusive[[:space:]]' \
20755                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
20756         rc=$?
20757         if test $rc -ne 0; then
20758                 export=0
20759                 for file in fs/block_dev.c; do
20760                         grep -q -E "EXPORT_SYMBOL.*(open_bdev_exclusive)" \
20761                                 "$LINUX/$file" 2>/dev/null
20762                         rc=$?
20763                         if test $rc -eq 0; then
20764                                 export=1
20765                                 break;
20766                         fi
20767                 done
20768                 if test $export -eq 0; then :
20769                         rc=1
20770                 else :
20771                         rc=0
20772                 fi
20773         else :
20774                 rc=0
20775         fi
20776
20777                 fi
20778                 if test $rc -ne 0; then :
20779
20780                 { $as_echo "$as_me:$LINENO: result: no" >&5
20781 $as_echo "no" >&6; }
20782
20783                 else :
20784
20785                 { $as_echo "$as_me:$LINENO: result: yes" >&5
20786 $as_echo "yes" >&6; }
20787
20788 cat >>confdefs.h <<\_ACEOF
20789 #define HAVE_OPEN_BDEV_EXCLUSIVE 1
20790 _ACEOF
20791
20792
20793                 fi
20794         fi
20795
20796
20797
20798         { $as_echo "$as_me:$LINENO: checking whether invalidate_bdev() wants 1 arg" >&5
20799 $as_echo_n "checking whether invalidate_bdev() wants 1 arg... " >&6; }
20800
20801
20802 cat confdefs.h - <<_ACEOF >conftest.c
20803 /* confdefs.h.  */
20804 _ACEOF
20805 cat confdefs.h >>conftest.$ac_ext
20806 cat >>conftest.$ac_ext <<_ACEOF
20807 /* end confdefs.h.  */
20808
20809
20810                 #include <linux/buffer_head.h>
20811
20812 int
20813 main (void)
20814 {
20815
20816                 struct block_device *bdev = NULL;
20817                 invalidate_bdev(bdev);
20818
20819   ;
20820   return 0;
20821 }
20822
20823 _ACEOF
20824
20825
20826         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20827         echo "obj-m := conftest.o" >build/Makefile
20828         modpost_flag=''
20829         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20830         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20831   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20832   (eval $ac_try) 2>&5
20833   ac_status=$?
20834   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20835   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20836   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20837   (eval $ac_try) 2>&5
20838   ac_status=$?
20839   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20840   (exit $ac_status); }; }; then
20841
20842                 { $as_echo "$as_me:$LINENO: result: yes" >&5
20843 $as_echo "yes" >&6; }
20844
20845 cat >>confdefs.h <<\_ACEOF
20846 #define HAVE_1ARG_INVALIDATE_BDEV 1
20847 _ACEOF
20848
20849
20850 else
20851   $as_echo "$as_me: failed program was:" >&5
20852 sed 's/^/| /' conftest.$ac_ext >&5
20853
20854                 { $as_echo "$as_me:$LINENO: result: no" >&5
20855 $as_echo "no" >&6; }
20856
20857
20858
20859 fi
20860
20861         rm -Rf build
20862
20863
20864
20865
20866         { $as_echo "$as_me:$LINENO: checking whether bdev_logical_block_size() is available" >&5
20867 $as_echo_n "checking whether bdev_logical_block_size() is available... " >&6; }
20868         tmp_flags="$EXTRA_KCFLAGS"
20869         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
20870
20871
20872 cat confdefs.h - <<_ACEOF >conftest.c
20873 /* confdefs.h.  */
20874 _ACEOF
20875 cat confdefs.h >>conftest.$ac_ext
20876 cat >>conftest.$ac_ext <<_ACEOF
20877 /* end confdefs.h.  */
20878
20879
20880                 #include <linux/blkdev.h>
20881
20882 int
20883 main (void)
20884 {
20885
20886                 struct block_device *bdev = NULL;
20887                 bdev_logical_block_size(bdev);
20888
20889   ;
20890   return 0;
20891 }
20892
20893 _ACEOF
20894
20895
20896         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20897         echo "obj-m := conftest.o" >build/Makefile
20898         modpost_flag=''
20899         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20900         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20901   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20902   (eval $ac_try) 2>&5
20903   ac_status=$?
20904   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20905   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20906   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20907   (eval $ac_try) 2>&5
20908   ac_status=$?
20909   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20910   (exit $ac_status); }; }; then
20911
20912                 { $as_echo "$as_me:$LINENO: result: yes" >&5
20913 $as_echo "yes" >&6; }
20914
20915 cat >>confdefs.h <<\_ACEOF
20916 #define HAVE_BDEV_LOGICAL_BLOCK_SIZE 1
20917 _ACEOF
20918
20919
20920 else
20921   $as_echo "$as_me: failed program was:" >&5
20922 sed 's/^/| /' conftest.$ac_ext >&5
20923
20924                 { $as_echo "$as_me:$LINENO: result: no" >&5
20925 $as_echo "no" >&6; }
20926
20927
20928
20929 fi
20930
20931         rm -Rf build
20932
20933
20934         EXTRA_KCFLAGS="$tmp_flags"
20935
20936
20937         { $as_echo "$as_me:$LINENO: checking whether bio_empty_barrier() is defined" >&5
20938 $as_echo_n "checking whether bio_empty_barrier() is defined... " >&6; }
20939         EXTRA_KCFLAGS="-Werror"
20940
20941
20942 cat confdefs.h - <<_ACEOF >conftest.c
20943 /* confdefs.h.  */
20944 _ACEOF
20945 cat confdefs.h >>conftest.$ac_ext
20946 cat >>conftest.$ac_ext <<_ACEOF
20947 /* end confdefs.h.  */
20948
20949
20950                 #include <linux/bio.h>
20951
20952 int
20953 main (void)
20954 {
20955
20956                 struct bio bio;
20957                 (void)bio_empty_barrier(&bio);
20958
20959   ;
20960   return 0;
20961 }
20962
20963 _ACEOF
20964
20965
20966         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
20967         echo "obj-m := conftest.o" >build/Makefile
20968         modpost_flag=''
20969         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
20970         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
20971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20972   (eval $ac_try) 2>&5
20973   ac_status=$?
20974   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20975   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
20976   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20977   (eval $ac_try) 2>&5
20978   ac_status=$?
20979   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20980   (exit $ac_status); }; }; then
20981
20982                 { $as_echo "$as_me:$LINENO: result: yes" >&5
20983 $as_echo "yes" >&6; }
20984
20985 cat >>confdefs.h <<\_ACEOF
20986 #define HAVE_BIO_EMPTY_BARRIER 1
20987 _ACEOF
20988
20989
20990 else
20991   $as_echo "$as_me: failed program was:" >&5
20992 sed 's/^/| /' conftest.$ac_ext >&5
20993
20994                 { $as_echo "$as_me:$LINENO: result: no" >&5
20995 $as_echo "no" >&6; }
20996
20997
20998
20999 fi
21000
21001         rm -Rf build
21002
21003
21004
21005
21006         { $as_echo "$as_me:$LINENO: checking whether BIO_RW_FAILFAST is defined" >&5
21007 $as_echo_n "checking whether BIO_RW_FAILFAST is defined... " >&6; }
21008
21009
21010 cat confdefs.h - <<_ACEOF >conftest.c
21011 /* confdefs.h.  */
21012 _ACEOF
21013 cat confdefs.h >>conftest.$ac_ext
21014 cat >>conftest.$ac_ext <<_ACEOF
21015 /* end confdefs.h.  */
21016
21017
21018                 #include <linux/bio.h>
21019
21020 int
21021 main (void)
21022 {
21023
21024                 int flags __attribute__ ((unused));
21025                 flags = (1 << BIO_RW_FAILFAST);
21026
21027   ;
21028   return 0;
21029 }
21030
21031 _ACEOF
21032
21033
21034         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21035         echo "obj-m := conftest.o" >build/Makefile
21036         modpost_flag=''
21037         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21038         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21039   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21040   (eval $ac_try) 2>&5
21041   ac_status=$?
21042   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21043   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21044   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21045   (eval $ac_try) 2>&5
21046   ac_status=$?
21047   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21048   (exit $ac_status); }; }; then
21049
21050                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21051 $as_echo "yes" >&6; }
21052
21053 cat >>confdefs.h <<\_ACEOF
21054 #define HAVE_BIO_RW_FAILFAST 1
21055 _ACEOF
21056
21057
21058 else
21059   $as_echo "$as_me: failed program was:" >&5
21060 sed 's/^/| /' conftest.$ac_ext >&5
21061
21062                 { $as_echo "$as_me:$LINENO: result: no" >&5
21063 $as_echo "no" >&6; }
21064
21065
21066
21067 fi
21068
21069         rm -Rf build
21070
21071
21072
21073
21074         { $as_echo "$as_me:$LINENO: checking whether BIO_RW_FAILFAST_* are defined" >&5
21075 $as_echo_n "checking whether BIO_RW_FAILFAST_* are defined... " >&6; }
21076
21077
21078 cat confdefs.h - <<_ACEOF >conftest.c
21079 /* confdefs.h.  */
21080 _ACEOF
21081 cat confdefs.h >>conftest.$ac_ext
21082 cat >>conftest.$ac_ext <<_ACEOF
21083 /* end confdefs.h.  */
21084
21085
21086                 #include <linux/bio.h>
21087
21088 int
21089 main (void)
21090 {
21091
21092                 int flags __attribute__ ((unused));
21093                 flags = ((1 << BIO_RW_FAILFAST_DEV) |
21094                          (1 << BIO_RW_FAILFAST_TRANSPORT) |
21095                          (1 << BIO_RW_FAILFAST_DRIVER));
21096
21097   ;
21098   return 0;
21099 }
21100
21101 _ACEOF
21102
21103
21104         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21105         echo "obj-m := conftest.o" >build/Makefile
21106         modpost_flag=''
21107         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21108         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21109   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21110   (eval $ac_try) 2>&5
21111   ac_status=$?
21112   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21113   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21114   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21115   (eval $ac_try) 2>&5
21116   ac_status=$?
21117   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21118   (exit $ac_status); }; }; then
21119
21120                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21121 $as_echo "yes" >&6; }
21122
21123 cat >>confdefs.h <<\_ACEOF
21124 #define HAVE_BIO_RW_FAILFAST_DTD 1
21125 _ACEOF
21126
21127
21128 else
21129   $as_echo "$as_me: failed program was:" >&5
21130 sed 's/^/| /' conftest.$ac_ext >&5
21131
21132                 { $as_echo "$as_me:$LINENO: result: no" >&5
21133 $as_echo "no" >&6; }
21134
21135
21136
21137 fi
21138
21139         rm -Rf build
21140
21141
21142
21143
21144         { $as_echo "$as_me:$LINENO: checking whether REQ_FAILFAST_MASK is defined" >&5
21145 $as_echo_n "checking whether REQ_FAILFAST_MASK is defined... " >&6; }
21146
21147
21148 cat confdefs.h - <<_ACEOF >conftest.c
21149 /* confdefs.h.  */
21150 _ACEOF
21151 cat confdefs.h >>conftest.$ac_ext
21152 cat >>conftest.$ac_ext <<_ACEOF
21153 /* end confdefs.h.  */
21154
21155
21156                 #include <linux/bio.h>
21157
21158 int
21159 main (void)
21160 {
21161
21162                 int flags __attribute__ ((unused));
21163                 flags = REQ_FAILFAST_MASK;
21164
21165   ;
21166   return 0;
21167 }
21168
21169 _ACEOF
21170
21171
21172         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21173         echo "obj-m := conftest.o" >build/Makefile
21174         modpost_flag=''
21175         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21176         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21177   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21178   (eval $ac_try) 2>&5
21179   ac_status=$?
21180   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21181   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21182   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21183   (eval $ac_try) 2>&5
21184   ac_status=$?
21185   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21186   (exit $ac_status); }; }; then
21187
21188                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21189 $as_echo "yes" >&6; }
21190
21191 cat >>confdefs.h <<\_ACEOF
21192 #define HAVE_BIO_REQ_FAILFAST_MASK 1
21193 _ACEOF
21194
21195
21196 else
21197   $as_echo "$as_me: failed program was:" >&5
21198 sed 's/^/| /' conftest.$ac_ext >&5
21199
21200                 { $as_echo "$as_me:$LINENO: result: no" >&5
21201 $as_echo "no" >&6; }
21202
21203
21204
21205 fi
21206
21207         rm -Rf build
21208
21209
21210
21211
21212         { $as_echo "$as_me:$LINENO: checking whether bio_end_io_t wants 2 args" >&5
21213 $as_echo_n "checking whether bio_end_io_t wants 2 args... " >&6; }
21214         tmp_flags="$EXTRA_KCFLAGS"
21215         EXTRA_KCFLAGS="-Werror"
21216
21217
21218 cat confdefs.h - <<_ACEOF >conftest.c
21219 /* confdefs.h.  */
21220 _ACEOF
21221 cat confdefs.h >>conftest.$ac_ext
21222 cat >>conftest.$ac_ext <<_ACEOF
21223 /* end confdefs.h.  */
21224
21225
21226                 #include <linux/bio.h>
21227
21228 int
21229 main (void)
21230 {
21231
21232                 void (*wanted_end_io)(struct bio *, int) = NULL;
21233                 bio_end_io_t *local_end_io __attribute__ ((unused));
21234
21235                 local_end_io = wanted_end_io;
21236
21237   ;
21238   return 0;
21239 }
21240
21241 _ACEOF
21242
21243
21244         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21245         echo "obj-m := conftest.o" >build/Makefile
21246         modpost_flag=''
21247         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21248         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21249   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21250   (eval $ac_try) 2>&5
21251   ac_status=$?
21252   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21253   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21254   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21255   (eval $ac_try) 2>&5
21256   ac_status=$?
21257   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21258   (exit $ac_status); }; }; then
21259
21260                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21261 $as_echo "yes" >&6; }
21262
21263 cat >>confdefs.h <<\_ACEOF
21264 #define HAVE_2ARGS_BIO_END_IO_T 1
21265 _ACEOF
21266
21267
21268 else
21269   $as_echo "$as_me: failed program was:" >&5
21270 sed 's/^/| /' conftest.$ac_ext >&5
21271
21272                 { $as_echo "$as_me:$LINENO: result: no" >&5
21273 $as_echo "no" >&6; }
21274
21275
21276
21277 fi
21278
21279         rm -Rf build
21280
21281
21282         EXTRA_KCFLAGS="$tmp_flags"
21283
21284
21285         { $as_echo "$as_me:$LINENO: checking whether BIO_RW_SYNC is defined" >&5
21286 $as_echo_n "checking whether BIO_RW_SYNC is defined... " >&6; }
21287
21288
21289 cat confdefs.h - <<_ACEOF >conftest.c
21290 /* confdefs.h.  */
21291 _ACEOF
21292 cat confdefs.h >>conftest.$ac_ext
21293 cat >>conftest.$ac_ext <<_ACEOF
21294 /* end confdefs.h.  */
21295
21296
21297                 #include <linux/bio.h>
21298
21299 int
21300 main (void)
21301 {
21302
21303                 int flags __attribute__ ((unused));
21304                 flags = BIO_RW_SYNC;
21305
21306   ;
21307   return 0;
21308 }
21309
21310 _ACEOF
21311
21312
21313         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21314         echo "obj-m := conftest.o" >build/Makefile
21315         modpost_flag=''
21316         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21317         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21318   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21319   (eval $ac_try) 2>&5
21320   ac_status=$?
21321   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21322   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21323   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21324   (eval $ac_try) 2>&5
21325   ac_status=$?
21326   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21327   (exit $ac_status); }; }; then
21328
21329                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21330 $as_echo "yes" >&6; }
21331
21332 cat >>confdefs.h <<\_ACEOF
21333 #define HAVE_BIO_RW_SYNC 1
21334 _ACEOF
21335
21336
21337 else
21338   $as_echo "$as_me: failed program was:" >&5
21339 sed 's/^/| /' conftest.$ac_ext >&5
21340
21341                 { $as_echo "$as_me:$LINENO: result: no" >&5
21342 $as_echo "no" >&6; }
21343
21344
21345
21346 fi
21347
21348         rm -Rf build
21349
21350
21351
21352
21353         { $as_echo "$as_me:$LINENO: checking whether BIO_RW_SYNCIO is defined" >&5
21354 $as_echo_n "checking whether BIO_RW_SYNCIO is defined... " >&6; }
21355
21356
21357 cat confdefs.h - <<_ACEOF >conftest.c
21358 /* confdefs.h.  */
21359 _ACEOF
21360 cat confdefs.h >>conftest.$ac_ext
21361 cat >>conftest.$ac_ext <<_ACEOF
21362 /* end confdefs.h.  */
21363
21364
21365                 #include <linux/bio.h>
21366
21367 int
21368 main (void)
21369 {
21370
21371                 int flags __attribute__ ((unused));
21372                 flags = BIO_RW_SYNCIO;
21373
21374   ;
21375   return 0;
21376 }
21377
21378 _ACEOF
21379
21380
21381         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21382         echo "obj-m := conftest.o" >build/Makefile
21383         modpost_flag=''
21384         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21385         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21386   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21387   (eval $ac_try) 2>&5
21388   ac_status=$?
21389   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21390   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21391   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21392   (eval $ac_try) 2>&5
21393   ac_status=$?
21394   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21395   (exit $ac_status); }; }; then
21396
21397                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21398 $as_echo "yes" >&6; }
21399
21400 cat >>confdefs.h <<\_ACEOF
21401 #define HAVE_BIO_RW_SYNCIO 1
21402 _ACEOF
21403
21404
21405 else
21406   $as_echo "$as_me: failed program was:" >&5
21407 sed 's/^/| /' conftest.$ac_ext >&5
21408
21409                 { $as_echo "$as_me:$LINENO: result: no" >&5
21410 $as_echo "no" >&6; }
21411
21412
21413
21414 fi
21415
21416         rm -Rf build
21417
21418
21419
21420
21421         { $as_echo "$as_me:$LINENO: checking whether REQ_SYNC is defined" >&5
21422 $as_echo_n "checking whether REQ_SYNC is defined... " >&6; }
21423
21424
21425 cat confdefs.h - <<_ACEOF >conftest.c
21426 /* confdefs.h.  */
21427 _ACEOF
21428 cat confdefs.h >>conftest.$ac_ext
21429 cat >>conftest.$ac_ext <<_ACEOF
21430 /* end confdefs.h.  */
21431
21432
21433                 #include <linux/bio.h>
21434
21435 int
21436 main (void)
21437 {
21438
21439                 int flags __attribute__ ((unused));
21440                 flags = REQ_SYNC;
21441
21442   ;
21443   return 0;
21444 }
21445
21446 _ACEOF
21447
21448
21449         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21450         echo "obj-m := conftest.o" >build/Makefile
21451         modpost_flag=''
21452         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21453         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21454   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21455   (eval $ac_try) 2>&5
21456   ac_status=$?
21457   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21458   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21459   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21460   (eval $ac_try) 2>&5
21461   ac_status=$?
21462   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21463   (exit $ac_status); }; }; then
21464
21465                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21466 $as_echo "yes" >&6; }
21467
21468 cat >>confdefs.h <<\_ACEOF
21469 #define HAVE_REQ_SYNC 1
21470 _ACEOF
21471
21472
21473 else
21474   $as_echo "$as_me: failed program was:" >&5
21475 sed 's/^/| /' conftest.$ac_ext >&5
21476
21477                 { $as_echo "$as_me:$LINENO: result: no" >&5
21478 $as_echo "no" >&6; }
21479
21480
21481
21482 fi
21483
21484         rm -Rf build
21485
21486
21487
21488
21489         { $as_echo "$as_me:$LINENO: checking whether blk_end_request() is available" >&5
21490 $as_echo_n "checking whether blk_end_request() is available... " >&6; }
21491         tmp_flags="$EXTRA_KCFLAGS"
21492         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
21493
21494
21495 cat confdefs.h - <<_ACEOF >conftest.c
21496 /* confdefs.h.  */
21497 _ACEOF
21498 cat confdefs.h >>conftest.$ac_ext
21499 cat >>conftest.$ac_ext <<_ACEOF
21500 /* end confdefs.h.  */
21501
21502
21503                 #include <linux/blkdev.h>
21504
21505 int
21506 main (void)
21507 {
21508
21509                 struct request *req = NULL;
21510                 (void) blk_end_request(req, 0, 0);
21511
21512   ;
21513   return 0;
21514 }
21515
21516 _ACEOF
21517
21518
21519         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21520         echo "obj-m := conftest.o" >build/Makefile
21521         modpost_flag=''
21522         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21523         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21524   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21525   (eval $ac_try) 2>&5
21526   ac_status=$?
21527   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21528   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21529   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21530   (eval $ac_try) 2>&5
21531   ac_status=$?
21532   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21533   (exit $ac_status); }; }; then
21534
21535                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21536 $as_echo "yes" >&6; }
21537
21538 cat >>confdefs.h <<\_ACEOF
21539 #define HAVE_BLK_END_REQUEST 1
21540 _ACEOF
21541
21542
21543 else
21544   $as_echo "$as_me: failed program was:" >&5
21545 sed 's/^/| /' conftest.$ac_ext >&5
21546
21547                 { $as_echo "$as_me:$LINENO: result: no" >&5
21548 $as_echo "no" >&6; }
21549
21550
21551
21552 fi
21553
21554         rm -Rf build
21555
21556
21557
21558         { $as_echo "$as_me:$LINENO: checking whether blk_end_request() is GPL-only" >&5
21559 $as_echo_n "checking whether blk_end_request() is GPL-only... " >&6; }
21560
21561
21562 cat confdefs.h - <<_ACEOF >conftest.c
21563 /* confdefs.h.  */
21564 _ACEOF
21565 cat confdefs.h >>conftest.$ac_ext
21566 cat >>conftest.$ac_ext <<_ACEOF
21567 /* end confdefs.h.  */
21568
21569
21570                 #include <linux/module.h>
21571                 #include <linux/blkdev.h>
21572
21573                 MODULE_LICENSE("CDDL");
21574
21575 int
21576 main (void)
21577 {
21578
21579                 struct request *req = NULL;
21580                 (void) blk_end_request(req, 0, 0);
21581
21582   ;
21583   return 0;
21584 }
21585
21586 _ACEOF
21587
21588
21589         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21590         echo "obj-m := conftest.o" >build/Makefile
21591         modpost_flag=''
21592         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21593         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21594   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21595   (eval $ac_try) 2>&5
21596   ac_status=$?
21597   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21598   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21599   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21600   (eval $ac_try) 2>&5
21601   ac_status=$?
21602   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21603   (exit $ac_status); }; }; then
21604
21605                 { $as_echo "$as_me:$LINENO: result: no" >&5
21606 $as_echo "no" >&6; }
21607
21608 else
21609   $as_echo "$as_me: failed program was:" >&5
21610 sed 's/^/| /' conftest.$ac_ext >&5
21611
21612                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21613 $as_echo "yes" >&6; }
21614
21615 cat >>confdefs.h <<\_ACEOF
21616 #define HAVE_BLK_END_REQUEST_GPL_ONLY 1
21617 _ACEOF
21618
21619
21620
21621
21622 fi
21623
21624         rm -Rf build
21625
21626
21627         EXTRA_KCFLAGS="$tmp_flags"
21628
21629
21630         { $as_echo "$as_me:$LINENO: checking whether blk_queue_flush() is available" >&5
21631 $as_echo_n "checking whether blk_queue_flush() is available... " >&6; }
21632         tmp_flags="$EXTRA_KCFLAGS"
21633         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
21634
21635
21636 cat confdefs.h - <<_ACEOF >conftest.c
21637 /* confdefs.h.  */
21638 _ACEOF
21639 cat confdefs.h >>conftest.$ac_ext
21640 cat >>conftest.$ac_ext <<_ACEOF
21641 /* end confdefs.h.  */
21642
21643
21644                 #include <linux/blkdev.h>
21645
21646 int
21647 main (void)
21648 {
21649
21650                 struct request_queue *q = NULL;
21651                 (void) blk_queue_flush(q, REQ_FLUSH);
21652
21653   ;
21654   return 0;
21655 }
21656
21657 _ACEOF
21658
21659
21660         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21661         echo "obj-m := conftest.o" >build/Makefile
21662         modpost_flag=''
21663         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21664         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21665   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21666   (eval $ac_try) 2>&5
21667   ac_status=$?
21668   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21669   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21670   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21671   (eval $ac_try) 2>&5
21672   ac_status=$?
21673   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21674   (exit $ac_status); }; }; then
21675
21676                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21677 $as_echo "yes" >&6; }
21678
21679 cat >>confdefs.h <<\_ACEOF
21680 #define HAVE_BLK_QUEUE_FLUSH 1
21681 _ACEOF
21682
21683
21684 else
21685   $as_echo "$as_me: failed program was:" >&5
21686 sed 's/^/| /' conftest.$ac_ext >&5
21687
21688                 { $as_echo "$as_me:$LINENO: result: no" >&5
21689 $as_echo "no" >&6; }
21690
21691
21692
21693 fi
21694
21695         rm -Rf build
21696
21697
21698
21699         { $as_echo "$as_me:$LINENO: checking whether blk_queue_flush() is GPL-only" >&5
21700 $as_echo_n "checking whether blk_queue_flush() is GPL-only... " >&6; }
21701
21702
21703 cat confdefs.h - <<_ACEOF >conftest.c
21704 /* confdefs.h.  */
21705 _ACEOF
21706 cat confdefs.h >>conftest.$ac_ext
21707 cat >>conftest.$ac_ext <<_ACEOF
21708 /* end confdefs.h.  */
21709
21710
21711                 #include <linux/module.h>
21712                 #include <linux/blkdev.h>
21713
21714                 MODULE_LICENSE("CDDL");
21715
21716 int
21717 main (void)
21718 {
21719
21720                 struct request_queue *q = NULL;
21721                 (void) blk_queue_flush(q, REQ_FLUSH);
21722
21723   ;
21724   return 0;
21725 }
21726
21727 _ACEOF
21728
21729
21730         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21731         echo "obj-m := conftest.o" >build/Makefile
21732         modpost_flag=''
21733         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21734         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21735   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21736   (eval $ac_try) 2>&5
21737   ac_status=$?
21738   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21739   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21740   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21741   (eval $ac_try) 2>&5
21742   ac_status=$?
21743   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21744   (exit $ac_status); }; }; then
21745
21746                 { $as_echo "$as_me:$LINENO: result: no" >&5
21747 $as_echo "no" >&6; }
21748
21749 else
21750   $as_echo "$as_me: failed program was:" >&5
21751 sed 's/^/| /' conftest.$ac_ext >&5
21752
21753                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21754 $as_echo "yes" >&6; }
21755
21756 cat >>confdefs.h <<\_ACEOF
21757 #define HAVE_BLK_QUEUE_FLUSH_GPL_ONLY 1
21758 _ACEOF
21759
21760
21761
21762
21763 fi
21764
21765         rm -Rf build
21766
21767
21768         EXTRA_KCFLAGS="$tmp_flags"
21769
21770
21771         { $as_echo "$as_me:$LINENO: checking whether blk_queue_max_hw_sectors() is available" >&5
21772 $as_echo_n "checking whether blk_queue_max_hw_sectors() is available... " >&6; }
21773         tmp_flags="$EXTRA_KCFLAGS"
21774         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
21775
21776
21777 cat confdefs.h - <<_ACEOF >conftest.c
21778 /* confdefs.h.  */
21779 _ACEOF
21780 cat confdefs.h >>conftest.$ac_ext
21781 cat >>conftest.$ac_ext <<_ACEOF
21782 /* end confdefs.h.  */
21783
21784
21785                 #include <linux/blkdev.h>
21786
21787 int
21788 main (void)
21789 {
21790
21791                 struct request_queue *q = NULL;
21792                 (void) blk_queue_max_hw_sectors(q, BLK_SAFE_MAX_SECTORS);
21793
21794   ;
21795   return 0;
21796 }
21797
21798 _ACEOF
21799
21800
21801         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21802         echo "obj-m := conftest.o" >build/Makefile
21803         modpost_flag=''
21804         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21805         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21806   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21807   (eval $ac_try) 2>&5
21808   ac_status=$?
21809   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21810   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21811   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21812   (eval $ac_try) 2>&5
21813   ac_status=$?
21814   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21815   (exit $ac_status); }; }; then
21816
21817                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21818 $as_echo "yes" >&6; }
21819
21820 cat >>confdefs.h <<\_ACEOF
21821 #define HAVE_BLK_QUEUE_MAX_HW_SECTORS 1
21822 _ACEOF
21823
21824
21825 else
21826   $as_echo "$as_me: failed program was:" >&5
21827 sed 's/^/| /' conftest.$ac_ext >&5
21828
21829                 { $as_echo "$as_me:$LINENO: result: no" >&5
21830 $as_echo "no" >&6; }
21831
21832
21833
21834 fi
21835
21836         rm -Rf build
21837
21838
21839         EXTRA_KCFLAGS="$tmp_flags"
21840
21841
21842         { $as_echo "$as_me:$LINENO: checking whether blk_queue_max_segments() is available" >&5
21843 $as_echo_n "checking whether blk_queue_max_segments() is available... " >&6; }
21844         tmp_flags="$EXTRA_KCFLAGS"
21845         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
21846
21847
21848 cat confdefs.h - <<_ACEOF >conftest.c
21849 /* confdefs.h.  */
21850 _ACEOF
21851 cat confdefs.h >>conftest.$ac_ext
21852 cat >>conftest.$ac_ext <<_ACEOF
21853 /* end confdefs.h.  */
21854
21855
21856                 #include <linux/blkdev.h>
21857
21858 int
21859 main (void)
21860 {
21861
21862                 struct request_queue *q = NULL;
21863                 (void) blk_queue_max_segments(q, BLK_MAX_SEGMENTS);
21864
21865   ;
21866   return 0;
21867 }
21868
21869 _ACEOF
21870
21871
21872         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21873         echo "obj-m := conftest.o" >build/Makefile
21874         modpost_flag=''
21875         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21876         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21877   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21878   (eval $ac_try) 2>&5
21879   ac_status=$?
21880   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21881   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21882   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21883   (eval $ac_try) 2>&5
21884   ac_status=$?
21885   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21886   (exit $ac_status); }; }; then
21887
21888                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21889 $as_echo "yes" >&6; }
21890
21891 cat >>confdefs.h <<\_ACEOF
21892 #define HAVE_BLK_QUEUE_MAX_SEGMENTS 1
21893 _ACEOF
21894
21895
21896 else
21897   $as_echo "$as_me: failed program was:" >&5
21898 sed 's/^/| /' conftest.$ac_ext >&5
21899
21900                 { $as_echo "$as_me:$LINENO: result: no" >&5
21901 $as_echo "no" >&6; }
21902
21903
21904
21905 fi
21906
21907         rm -Rf build
21908
21909
21910         EXTRA_KCFLAGS="$tmp_flags"
21911
21912
21913         { $as_echo "$as_me:$LINENO: checking whether blk_queue_physical_block_size() is available" >&5
21914 $as_echo_n "checking whether blk_queue_physical_block_size() is available... " >&6; }
21915         tmp_flags="$EXTRA_KCFLAGS"
21916         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
21917
21918
21919 cat confdefs.h - <<_ACEOF >conftest.c
21920 /* confdefs.h.  */
21921 _ACEOF
21922 cat confdefs.h >>conftest.$ac_ext
21923 cat >>conftest.$ac_ext <<_ACEOF
21924 /* end confdefs.h.  */
21925
21926
21927                 #include <linux/blkdev.h>
21928
21929 int
21930 main (void)
21931 {
21932
21933                 struct request_queue *q = NULL;
21934                 unsigned short block_size = 1;
21935                 (void) blk_queue_physical_block_size(q, block_size);
21936
21937   ;
21938   return 0;
21939 }
21940
21941 _ACEOF
21942
21943
21944         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
21945         echo "obj-m := conftest.o" >build/Makefile
21946         modpost_flag=''
21947         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
21948         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
21949   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21950   (eval $ac_try) 2>&5
21951   ac_status=$?
21952   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21953   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
21954   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21955   (eval $ac_try) 2>&5
21956   ac_status=$?
21957   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21958   (exit $ac_status); }; }; then
21959
21960                 { $as_echo "$as_me:$LINENO: result: yes" >&5
21961 $as_echo "yes" >&6; }
21962
21963 cat >>confdefs.h <<\_ACEOF
21964 #define HAVE_BLK_QUEUE_PHYSICAL_BLOCK_SIZE 1
21965 _ACEOF
21966
21967
21968 else
21969   $as_echo "$as_me: failed program was:" >&5
21970 sed 's/^/| /' conftest.$ac_ext >&5
21971
21972                 { $as_echo "$as_me:$LINENO: result: no" >&5
21973 $as_echo "no" >&6; }
21974
21975
21976
21977 fi
21978
21979         rm -Rf build
21980
21981
21982         EXTRA_KCFLAGS="$tmp_flags"
21983
21984
21985         { $as_echo "$as_me:$LINENO: checking whether blk_queue_io_opt() is available" >&5
21986 $as_echo_n "checking whether blk_queue_io_opt() is available... " >&6; }
21987         tmp_flags="$EXTRA_KCFLAGS"
21988         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
21989
21990
21991 cat confdefs.h - <<_ACEOF >conftest.c
21992 /* confdefs.h.  */
21993 _ACEOF
21994 cat confdefs.h >>conftest.$ac_ext
21995 cat >>conftest.$ac_ext <<_ACEOF
21996 /* end confdefs.h.  */
21997
21998
21999                 #include <linux/blkdev.h>
22000
22001 int
22002 main (void)
22003 {
22004
22005                 struct request_queue *q = NULL;
22006                 unsigned int opt = 1;
22007                 (void) blk_queue_io_opt(q, opt);
22008
22009   ;
22010   return 0;
22011 }
22012
22013 _ACEOF
22014
22015
22016         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22017         echo "obj-m := conftest.o" >build/Makefile
22018         modpost_flag=''
22019         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22020         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22021   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22022   (eval $ac_try) 2>&5
22023   ac_status=$?
22024   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22025   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22026   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22027   (eval $ac_try) 2>&5
22028   ac_status=$?
22029   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22030   (exit $ac_status); }; }; then
22031
22032                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22033 $as_echo "yes" >&6; }
22034
22035 cat >>confdefs.h <<\_ACEOF
22036 #define HAVE_BLK_QUEUE_IO_OPT 1
22037 _ACEOF
22038
22039
22040 else
22041   $as_echo "$as_me: failed program was:" >&5
22042 sed 's/^/| /' conftest.$ac_ext >&5
22043
22044                 { $as_echo "$as_me:$LINENO: result: no" >&5
22045 $as_echo "no" >&6; }
22046
22047
22048
22049 fi
22050
22051         rm -Rf build
22052
22053
22054         EXTRA_KCFLAGS="$tmp_flags"
22055
22056
22057         { $as_echo "$as_me:$LINENO: checking whether blk_queue_nonrot() is available" >&5
22058 $as_echo_n "checking whether blk_queue_nonrot() is available... " >&6; }
22059         tmp_flags="$EXTRA_KCFLAGS"
22060         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
22061
22062
22063 cat confdefs.h - <<_ACEOF >conftest.c
22064 /* confdefs.h.  */
22065 _ACEOF
22066 cat confdefs.h >>conftest.$ac_ext
22067 cat >>conftest.$ac_ext <<_ACEOF
22068 /* end confdefs.h.  */
22069
22070
22071                 #include <linux/blkdev.h>
22072
22073 int
22074 main (void)
22075 {
22076
22077                 struct request_queue *q = NULL;
22078                 (void) blk_queue_nonrot(q);
22079
22080   ;
22081   return 0;
22082 }
22083
22084 _ACEOF
22085
22086
22087         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22088         echo "obj-m := conftest.o" >build/Makefile
22089         modpost_flag=''
22090         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22091         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22092   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22093   (eval $ac_try) 2>&5
22094   ac_status=$?
22095   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22096   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22097   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22098   (eval $ac_try) 2>&5
22099   ac_status=$?
22100   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22101   (exit $ac_status); }; }; then
22102
22103                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22104 $as_echo "yes" >&6; }
22105
22106 cat >>confdefs.h <<\_ACEOF
22107 #define HAVE_BLK_QUEUE_NONROT 1
22108 _ACEOF
22109
22110
22111 else
22112   $as_echo "$as_me: failed program was:" >&5
22113 sed 's/^/| /' conftest.$ac_ext >&5
22114
22115                 { $as_echo "$as_me:$LINENO: result: no" >&5
22116 $as_echo "no" >&6; }
22117
22118
22119
22120 fi
22121
22122         rm -Rf build
22123
22124
22125         EXTRA_KCFLAGS="$tmp_flags"
22126
22127
22128         { $as_echo "$as_me:$LINENO: checking whether blk_queue_discard() is available" >&5
22129 $as_echo_n "checking whether blk_queue_discard() is available... " >&6; }
22130         tmp_flags="$EXTRA_KCFLAGS"
22131         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
22132
22133
22134 cat confdefs.h - <<_ACEOF >conftest.c
22135 /* confdefs.h.  */
22136 _ACEOF
22137 cat confdefs.h >>conftest.$ac_ext
22138 cat >>conftest.$ac_ext <<_ACEOF
22139 /* end confdefs.h.  */
22140
22141
22142                 #include <linux/blkdev.h>
22143
22144 int
22145 main (void)
22146 {
22147
22148                 struct request_queue *q = NULL;
22149                 (void) blk_queue_discard(q);
22150
22151   ;
22152   return 0;
22153 }
22154
22155 _ACEOF
22156
22157
22158         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22159         echo "obj-m := conftest.o" >build/Makefile
22160         modpost_flag=''
22161         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22162         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22163   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22164   (eval $ac_try) 2>&5
22165   ac_status=$?
22166   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22167   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22168   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22169   (eval $ac_try) 2>&5
22170   ac_status=$?
22171   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22172   (exit $ac_status); }; }; then
22173
22174                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22175 $as_echo "yes" >&6; }
22176
22177 cat >>confdefs.h <<\_ACEOF
22178 #define HAVE_BLK_QUEUE_DISCARD 1
22179 _ACEOF
22180
22181
22182 else
22183   $as_echo "$as_me: failed program was:" >&5
22184 sed 's/^/| /' conftest.$ac_ext >&5
22185
22186                 { $as_echo "$as_me:$LINENO: result: no" >&5
22187 $as_echo "no" >&6; }
22188
22189
22190
22191 fi
22192
22193         rm -Rf build
22194
22195
22196         EXTRA_KCFLAGS="$tmp_flags"
22197
22198
22199         { $as_echo "$as_me:$LINENO: checking whether blk_fetch_request() is available" >&5
22200 $as_echo_n "checking whether blk_fetch_request() is available... " >&6; }
22201         tmp_flags="$EXTRA_KCFLAGS"
22202         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
22203
22204
22205 cat confdefs.h - <<_ACEOF >conftest.c
22206 /* confdefs.h.  */
22207 _ACEOF
22208 cat confdefs.h >>conftest.$ac_ext
22209 cat >>conftest.$ac_ext <<_ACEOF
22210 /* end confdefs.h.  */
22211
22212
22213                 #include <linux/blkdev.h>
22214
22215 int
22216 main (void)
22217 {
22218
22219                 struct request_queue *q = NULL;
22220                 (void) blk_fetch_request(q);
22221
22222   ;
22223   return 0;
22224 }
22225
22226 _ACEOF
22227
22228
22229         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22230         echo "obj-m := conftest.o" >build/Makefile
22231         modpost_flag=''
22232         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22233         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22234   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22235   (eval $ac_try) 2>&5
22236   ac_status=$?
22237   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22238   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22239   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22240   (eval $ac_try) 2>&5
22241   ac_status=$?
22242   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22243   (exit $ac_status); }; }; then
22244
22245                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22246 $as_echo "yes" >&6; }
22247
22248 cat >>confdefs.h <<\_ACEOF
22249 #define HAVE_BLK_FETCH_REQUEST 1
22250 _ACEOF
22251
22252
22253 else
22254   $as_echo "$as_me: failed program was:" >&5
22255 sed 's/^/| /' conftest.$ac_ext >&5
22256
22257                 { $as_echo "$as_me:$LINENO: result: no" >&5
22258 $as_echo "no" >&6; }
22259
22260
22261
22262 fi
22263
22264         rm -Rf build
22265
22266
22267         EXTRA_KCFLAGS="$tmp_flags"
22268
22269
22270         { $as_echo "$as_me:$LINENO: checking whether blk_requeue_request() is available" >&5
22271 $as_echo_n "checking whether blk_requeue_request() is available... " >&6; }
22272         tmp_flags="$EXTRA_KCFLAGS"
22273         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
22274
22275
22276 cat confdefs.h - <<_ACEOF >conftest.c
22277 /* confdefs.h.  */
22278 _ACEOF
22279 cat confdefs.h >>conftest.$ac_ext
22280 cat >>conftest.$ac_ext <<_ACEOF
22281 /* end confdefs.h.  */
22282
22283
22284                 #include <linux/blkdev.h>
22285
22286 int
22287 main (void)
22288 {
22289
22290                 struct request_queue *q = NULL;
22291                 struct request *req = NULL;
22292                 blk_requeue_request(q, req);
22293
22294   ;
22295   return 0;
22296 }
22297
22298 _ACEOF
22299
22300
22301         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22302         echo "obj-m := conftest.o" >build/Makefile
22303         modpost_flag=''
22304         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22305         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22306   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22307   (eval $ac_try) 2>&5
22308   ac_status=$?
22309   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22310   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22311   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22312   (eval $ac_try) 2>&5
22313   ac_status=$?
22314   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22315   (exit $ac_status); }; }; then
22316
22317                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22318 $as_echo "yes" >&6; }
22319
22320 cat >>confdefs.h <<\_ACEOF
22321 #define HAVE_BLK_REQUEUE_REQUEST 1
22322 _ACEOF
22323
22324
22325 else
22326   $as_echo "$as_me: failed program was:" >&5
22327 sed 's/^/| /' conftest.$ac_ext >&5
22328
22329                 { $as_echo "$as_me:$LINENO: result: no" >&5
22330 $as_echo "no" >&6; }
22331
22332
22333
22334 fi
22335
22336         rm -Rf build
22337
22338
22339         EXTRA_KCFLAGS="$tmp_flags"
22340
22341
22342         { $as_echo "$as_me:$LINENO: checking whether blk_rq_bytes() is available" >&5
22343 $as_echo_n "checking whether blk_rq_bytes() is available... " >&6; }
22344         tmp_flags="$EXTRA_KCFLAGS"
22345         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
22346
22347
22348 cat confdefs.h - <<_ACEOF >conftest.c
22349 /* confdefs.h.  */
22350 _ACEOF
22351 cat confdefs.h >>conftest.$ac_ext
22352 cat >>conftest.$ac_ext <<_ACEOF
22353 /* end confdefs.h.  */
22354
22355
22356                 #include <linux/blkdev.h>
22357
22358 int
22359 main (void)
22360 {
22361
22362                 struct request *req = NULL;
22363                 (void) blk_rq_bytes(req);
22364
22365   ;
22366   return 0;
22367 }
22368
22369 _ACEOF
22370
22371
22372         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22373         echo "obj-m := conftest.o" >build/Makefile
22374         modpost_flag=''
22375         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22376         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22377   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22378   (eval $ac_try) 2>&5
22379   ac_status=$?
22380   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22381   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22382   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22383   (eval $ac_try) 2>&5
22384   ac_status=$?
22385   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22386   (exit $ac_status); }; }; then
22387
22388                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22389 $as_echo "yes" >&6; }
22390
22391 cat >>confdefs.h <<\_ACEOF
22392 #define HAVE_BLK_RQ_BYTES 1
22393 _ACEOF
22394
22395
22396 else
22397   $as_echo "$as_me: failed program was:" >&5
22398 sed 's/^/| /' conftest.$ac_ext >&5
22399
22400                 { $as_echo "$as_me:$LINENO: result: no" >&5
22401 $as_echo "no" >&6; }
22402
22403
22404
22405 fi
22406
22407         rm -Rf build
22408
22409
22410
22411         { $as_echo "$as_me:$LINENO: checking whether blk_rq_bytes() is GPL-only" >&5
22412 $as_echo_n "checking whether blk_rq_bytes() is GPL-only... " >&6; }
22413
22414
22415 cat confdefs.h - <<_ACEOF >conftest.c
22416 /* confdefs.h.  */
22417 _ACEOF
22418 cat confdefs.h >>conftest.$ac_ext
22419 cat >>conftest.$ac_ext <<_ACEOF
22420 /* end confdefs.h.  */
22421
22422
22423                 #include <linux/module.h>
22424                 #include <linux/blkdev.h>
22425
22426                 MODULE_LICENSE("CDDL");
22427
22428 int
22429 main (void)
22430 {
22431
22432                 struct request *req = NULL;
22433                 (void) blk_rq_bytes(req);
22434
22435   ;
22436   return 0;
22437 }
22438
22439 _ACEOF
22440
22441
22442         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22443         echo "obj-m := conftest.o" >build/Makefile
22444         modpost_flag=''
22445         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22446         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22447   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22448   (eval $ac_try) 2>&5
22449   ac_status=$?
22450   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22451   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22452   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22453   (eval $ac_try) 2>&5
22454   ac_status=$?
22455   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22456   (exit $ac_status); }; }; then
22457
22458                 { $as_echo "$as_me:$LINENO: result: no" >&5
22459 $as_echo "no" >&6; }
22460
22461 else
22462   $as_echo "$as_me: failed program was:" >&5
22463 sed 's/^/| /' conftest.$ac_ext >&5
22464
22465                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22466 $as_echo "yes" >&6; }
22467
22468 cat >>confdefs.h <<\_ACEOF
22469 #define HAVE_BLK_RQ_BYTES_GPL_ONLY 1
22470 _ACEOF
22471
22472
22473
22474
22475 fi
22476
22477         rm -Rf build
22478
22479
22480         EXTRA_KCFLAGS="$tmp_flags"
22481
22482
22483         { $as_echo "$as_me:$LINENO: checking whether blk_rq_pos() is available" >&5
22484 $as_echo_n "checking whether blk_rq_pos() is available... " >&6; }
22485         tmp_flags="$EXTRA_KCFLAGS"
22486         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
22487
22488
22489 cat confdefs.h - <<_ACEOF >conftest.c
22490 /* confdefs.h.  */
22491 _ACEOF
22492 cat confdefs.h >>conftest.$ac_ext
22493 cat >>conftest.$ac_ext <<_ACEOF
22494 /* end confdefs.h.  */
22495
22496
22497                 #include <linux/blkdev.h>
22498
22499 int
22500 main (void)
22501 {
22502
22503                 struct request *req = NULL;
22504                 (void) blk_rq_pos(req);
22505
22506   ;
22507   return 0;
22508 }
22509
22510 _ACEOF
22511
22512
22513         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22514         echo "obj-m := conftest.o" >build/Makefile
22515         modpost_flag=''
22516         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22517         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22518   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22519   (eval $ac_try) 2>&5
22520   ac_status=$?
22521   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22522   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22523   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22524   (eval $ac_try) 2>&5
22525   ac_status=$?
22526   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22527   (exit $ac_status); }; }; then
22528
22529                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22530 $as_echo "yes" >&6; }
22531
22532 cat >>confdefs.h <<\_ACEOF
22533 #define HAVE_BLK_RQ_POS 1
22534 _ACEOF
22535
22536
22537 else
22538   $as_echo "$as_me: failed program was:" >&5
22539 sed 's/^/| /' conftest.$ac_ext >&5
22540
22541                 { $as_echo "$as_me:$LINENO: result: no" >&5
22542 $as_echo "no" >&6; }
22543
22544
22545
22546 fi
22547
22548         rm -Rf build
22549
22550
22551         EXTRA_KCFLAGS="$tmp_flags"
22552
22553
22554         { $as_echo "$as_me:$LINENO: checking whether blk_rq_sectors() is available" >&5
22555 $as_echo_n "checking whether blk_rq_sectors() is available... " >&6; }
22556         tmp_flags="$EXTRA_KCFLAGS"
22557         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
22558
22559
22560 cat confdefs.h - <<_ACEOF >conftest.c
22561 /* confdefs.h.  */
22562 _ACEOF
22563 cat confdefs.h >>conftest.$ac_ext
22564 cat >>conftest.$ac_ext <<_ACEOF
22565 /* end confdefs.h.  */
22566
22567
22568                 #include <linux/blkdev.h>
22569
22570 int
22571 main (void)
22572 {
22573
22574                 struct request *req = NULL;
22575                 (void) blk_rq_sectors(req);
22576
22577   ;
22578   return 0;
22579 }
22580
22581 _ACEOF
22582
22583
22584         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22585         echo "obj-m := conftest.o" >build/Makefile
22586         modpost_flag=''
22587         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22588         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22589   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22590   (eval $ac_try) 2>&5
22591   ac_status=$?
22592   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22593   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22594   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22595   (eval $ac_try) 2>&5
22596   ac_status=$?
22597   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22598   (exit $ac_status); }; }; then
22599
22600                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22601 $as_echo "yes" >&6; }
22602
22603 cat >>confdefs.h <<\_ACEOF
22604 #define HAVE_BLK_RQ_SECTORS 1
22605 _ACEOF
22606
22607
22608 else
22609   $as_echo "$as_me: failed program was:" >&5
22610 sed 's/^/| /' conftest.$ac_ext >&5
22611
22612                 { $as_echo "$as_me:$LINENO: result: no" >&5
22613 $as_echo "no" >&6; }
22614
22615
22616
22617 fi
22618
22619         rm -Rf build
22620
22621
22622         EXTRA_KCFLAGS="$tmp_flags"
22623
22624
22625         { $as_echo "$as_me:$LINENO: checking whether get_disk_ro() is available" >&5
22626 $as_echo_n "checking whether get_disk_ro() is available... " >&6; }
22627         tmp_flags="$EXTRA_KCFLAGS"
22628         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
22629
22630
22631 cat confdefs.h - <<_ACEOF >conftest.c
22632 /* confdefs.h.  */
22633 _ACEOF
22634 cat confdefs.h >>conftest.$ac_ext
22635 cat >>conftest.$ac_ext <<_ACEOF
22636 /* end confdefs.h.  */
22637
22638
22639                 #include <linux/blkdev.h>
22640
22641 int
22642 main (void)
22643 {
22644
22645                 struct gendisk *disk = NULL;
22646                 (void) get_disk_ro(disk);
22647
22648   ;
22649   return 0;
22650 }
22651
22652 _ACEOF
22653
22654
22655         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22656         echo "obj-m := conftest.o" >build/Makefile
22657         modpost_flag=''
22658         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22659         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22660   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22661   (eval $ac_try) 2>&5
22662   ac_status=$?
22663   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22664   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22665   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22666   (eval $ac_try) 2>&5
22667   ac_status=$?
22668   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22669   (exit $ac_status); }; }; then
22670
22671                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22672 $as_echo "yes" >&6; }
22673
22674 cat >>confdefs.h <<\_ACEOF
22675 #define HAVE_GET_DISK_RO 1
22676 _ACEOF
22677
22678
22679 else
22680   $as_echo "$as_me: failed program was:" >&5
22681 sed 's/^/| /' conftest.$ac_ext >&5
22682
22683                 { $as_echo "$as_me:$LINENO: result: no" >&5
22684 $as_echo "no" >&6; }
22685
22686
22687
22688 fi
22689
22690         rm -Rf build
22691
22692
22693         EXTRA_KCFLAGS="$tmp_flags"
22694
22695         { $as_echo "$as_me:$LINENO: checking whether get_gendisk() is available" >&5
22696 $as_echo_n "checking whether get_gendisk() is available... " >&6; }
22697
22698
22699
22700 cat confdefs.h - <<_ACEOF >conftest.c
22701 /* confdefs.h.  */
22702 _ACEOF
22703 cat confdefs.h >>conftest.$ac_ext
22704 cat >>conftest.$ac_ext <<_ACEOF
22705 /* end confdefs.h.  */
22706
22707
22708                 #include <linux/genhd.h>
22709
22710 int
22711 main (void)
22712 {
22713
22714                 get_gendisk(0, NULL);
22715
22716   ;
22717   return 0;
22718 }
22719
22720 _ACEOF
22721
22722
22723         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22724         echo "obj-m := conftest.o" >build/Makefile
22725         modpost_flag=''
22726         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22727         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22728   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22729   (eval $ac_try) 2>&5
22730   ac_status=$?
22731   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22732   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22733   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22734   (eval $ac_try) 2>&5
22735   ac_status=$?
22736   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22737   (exit $ac_status); }; }; then
22738   rc=0
22739 else
22740   $as_echo "$as_me: failed program was:" >&5
22741 sed 's/^/| /' conftest.$ac_ext >&5
22742  rc=1
22743
22744
22745 fi
22746
22747         rm -Rf build
22748
22749
22750         if test $rc -ne 0; then :
22751
22752                 { $as_echo "$as_me:$LINENO: result: no" >&5
22753 $as_echo "no" >&6; }
22754
22755         else
22756                 if test "x$enable_linux_builtin" != xyes; then
22757
22758         grep -q -E '[[:space:]]get_gendisk[[:space:]]' \
22759                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
22760         rc=$?
22761         if test $rc -ne 0; then
22762                 export=0
22763                 for file in block/genhd.c; do
22764                         grep -q -E "EXPORT_SYMBOL.*(get_gendisk)" \
22765                                 "$LINUX/$file" 2>/dev/null
22766                         rc=$?
22767                         if test $rc -eq 0; then
22768                                 export=1
22769                                 break;
22770                         fi
22771                 done
22772                 if test $export -eq 0; then :
22773                         rc=1
22774                 else :
22775                         rc=0
22776                 fi
22777         else :
22778                 rc=0
22779         fi
22780
22781                 fi
22782                 if test $rc -ne 0; then :
22783
22784                 { $as_echo "$as_me:$LINENO: result: no" >&5
22785 $as_echo "no" >&6; }
22786
22787                 else :
22788
22789                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22790 $as_echo "yes" >&6; }
22791
22792 cat >>confdefs.h <<\_ACEOF
22793 #define HAVE_GET_GENDISK 1
22794 _ACEOF
22795
22796
22797                 fi
22798         fi
22799
22800
22801
22802         { $as_echo "$as_me:$LINENO: checking whether rq_is_sync() is available" >&5
22803 $as_echo_n "checking whether rq_is_sync() is available... " >&6; }
22804         tmp_flags="$EXTRA_KCFLAGS"
22805         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
22806
22807
22808 cat confdefs.h - <<_ACEOF >conftest.c
22809 /* confdefs.h.  */
22810 _ACEOF
22811 cat confdefs.h >>conftest.$ac_ext
22812 cat >>conftest.$ac_ext <<_ACEOF
22813 /* end confdefs.h.  */
22814
22815
22816                 #include <linux/blkdev.h>
22817
22818 int
22819 main (void)
22820 {
22821
22822                 struct request *req = NULL;
22823                 (void) rq_is_sync(req);
22824
22825   ;
22826   return 0;
22827 }
22828
22829 _ACEOF
22830
22831
22832         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22833         echo "obj-m := conftest.o" >build/Makefile
22834         modpost_flag=''
22835         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22836         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22838   (eval $ac_try) 2>&5
22839   ac_status=$?
22840   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22841   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22842   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22843   (eval $ac_try) 2>&5
22844   ac_status=$?
22845   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22846   (exit $ac_status); }; }; then
22847
22848                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22849 $as_echo "yes" >&6; }
22850
22851 cat >>confdefs.h <<\_ACEOF
22852 #define HAVE_RQ_IS_SYNC 1
22853 _ACEOF
22854
22855
22856 else
22857   $as_echo "$as_me: failed program was:" >&5
22858 sed 's/^/| /' conftest.$ac_ext >&5
22859
22860                 { $as_echo "$as_me:$LINENO: result: no" >&5
22861 $as_echo "no" >&6; }
22862
22863
22864
22865 fi
22866
22867         rm -Rf build
22868
22869
22870         EXTRA_KCFLAGS="$tmp_flags"
22871
22872
22873         { $as_echo "$as_me:$LINENO: checking whether rq_for_each_segment() is available" >&5
22874 $as_echo_n "checking whether rq_for_each_segment() is available... " >&6; }
22875         tmp_flags="$EXTRA_KCFLAGS"
22876         EXTRA_KCFLAGS="-Wno-unused-but-set-variable"
22877
22878
22879 cat confdefs.h - <<_ACEOF >conftest.c
22880 /* confdefs.h.  */
22881 _ACEOF
22882 cat confdefs.h >>conftest.$ac_ext
22883 cat >>conftest.$ac_ext <<_ACEOF
22884 /* end confdefs.h.  */
22885
22886
22887                 #include <linux/blkdev.h>
22888
22889 int
22890 main (void)
22891 {
22892
22893                 struct bio_vec *bv;
22894                 struct req_iterator iter;
22895                 struct request *req = NULL;
22896                 rq_for_each_segment(bv, req, iter) { }
22897
22898   ;
22899   return 0;
22900 }
22901
22902 _ACEOF
22903
22904
22905         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22906         echo "obj-m := conftest.o" >build/Makefile
22907         modpost_flag=''
22908         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22909         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22910   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22911   (eval $ac_try) 2>&5
22912   ac_status=$?
22913   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22914   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22915   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22916   (eval $ac_try) 2>&5
22917   ac_status=$?
22918   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22919   (exit $ac_status); }; }; then
22920
22921                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22922 $as_echo "yes" >&6; }
22923
22924 cat >>confdefs.h <<\_ACEOF
22925 #define HAVE_RQ_FOR_EACH_SEGMENT 1
22926 _ACEOF
22927
22928
22929 else
22930   $as_echo "$as_me: failed program was:" >&5
22931 sed 's/^/| /' conftest.$ac_ext >&5
22932
22933                 { $as_echo "$as_me:$LINENO: result: no" >&5
22934 $as_echo "no" >&6; }
22935
22936
22937
22938 fi
22939
22940         rm -Rf build
22941
22942
22943         EXTRA_KCFLAGS="$tmp_flags"
22944
22945
22946         { $as_echo "$as_me:$LINENO: checking whether ql->discard_granularity is available" >&5
22947 $as_echo_n "checking whether ql->discard_granularity is available... " >&6; }
22948
22949
22950 cat confdefs.h - <<_ACEOF >conftest.c
22951 /* confdefs.h.  */
22952 _ACEOF
22953 cat confdefs.h >>conftest.$ac_ext
22954 cat >>conftest.$ac_ext <<_ACEOF
22955 /* end confdefs.h.  */
22956
22957
22958                 #include <linux/blkdev.h>
22959
22960 int
22961 main (void)
22962 {
22963
22964                 struct queue_limits ql __attribute__ ((unused));
22965
22966                 ql.discard_granularity = 0;
22967
22968   ;
22969   return 0;
22970 }
22971
22972 _ACEOF
22973
22974
22975         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
22976         echo "obj-m := conftest.o" >build/Makefile
22977         modpost_flag=''
22978         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
22979         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
22980   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22981   (eval $ac_try) 2>&5
22982   ac_status=$?
22983   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22984   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
22985   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22986   (eval $ac_try) 2>&5
22987   ac_status=$?
22988   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22989   (exit $ac_status); }; }; then
22990
22991                 { $as_echo "$as_me:$LINENO: result: yes" >&5
22992 $as_echo "yes" >&6; }
22993
22994 cat >>confdefs.h <<\_ACEOF
22995 #define HAVE_DISCARD_GRANULARITY 1
22996 _ACEOF
22997
22998
22999 else
23000   $as_echo "$as_me: failed program was:" >&5
23001 sed 's/^/| /' conftest.$ac_ext >&5
23002
23003                 { $as_echo "$as_me:$LINENO: result: no" >&5
23004 $as_echo "no" >&6; }
23005
23006
23007
23008 fi
23009
23010         rm -Rf build
23011
23012
23013
23014         { $as_echo "$as_me:$LINENO: checking whether super_block uses const struct xattr_hander" >&5
23015 $as_echo_n "checking whether super_block uses const struct xattr_hander... " >&6; }
23016
23017
23018 cat confdefs.h - <<_ACEOF >conftest.c
23019 /* confdefs.h.  */
23020 _ACEOF
23021 cat confdefs.h >>conftest.$ac_ext
23022 cat >>conftest.$ac_ext <<_ACEOF
23023 /* end confdefs.h.  */
23024
23025
23026                 #include <linux/fs.h>
23027                 #include <linux/xattr.h>
23028
23029                 const struct xattr_handler xattr_test_handler = {
23030                         .prefix = "test",
23031                         .get    = NULL,
23032                         .set    = NULL,
23033                 };
23034
23035                 const struct xattr_handler *xattr_handlers[] = {
23036                         &xattr_test_handler,
23037                 };
23038
23039 int
23040 main (void)
23041 {
23042
23043                 struct super_block sb __attribute__ ((unused));
23044
23045                 sb.s_xattr = xattr_handlers;
23046
23047   ;
23048   return 0;
23049 }
23050
23051 _ACEOF
23052
23053
23054         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23055         echo "obj-m := conftest.o" >build/Makefile
23056         modpost_flag=''
23057         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23058         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23059   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23060   (eval $ac_try) 2>&5
23061   ac_status=$?
23062   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23063   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23064   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23065   (eval $ac_try) 2>&5
23066   ac_status=$?
23067   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23068   (exit $ac_status); }; }; then
23069
23070                 { $as_echo "$as_me:$LINENO: result: yes" >&5
23071 $as_echo "yes" >&6; }
23072
23073 cat >>confdefs.h <<\_ACEOF
23074 #define HAVE_CONST_XATTR_HANDLER 1
23075 _ACEOF
23076
23077
23078 else
23079   $as_echo "$as_me: failed program was:" >&5
23080 sed 's/^/| /' conftest.$ac_ext >&5
23081
23082                 { $as_echo "$as_me:$LINENO: result: no" >&5
23083 $as_echo "no" >&6; }
23084
23085
23086
23087 fi
23088
23089         rm -Rf build
23090
23091
23092
23093
23094         { $as_echo "$as_me:$LINENO: checking whether xattr_handler->get() wants dentry" >&5
23095 $as_echo_n "checking whether xattr_handler->get() wants dentry... " >&6; }
23096
23097
23098 cat confdefs.h - <<_ACEOF >conftest.c
23099 /* confdefs.h.  */
23100 _ACEOF
23101 cat confdefs.h >>conftest.$ac_ext
23102 cat >>conftest.$ac_ext <<_ACEOF
23103 /* end confdefs.h.  */
23104
23105
23106                 #include <linux/xattr.h>
23107
23108 int
23109 main (void)
23110 {
23111
23112                 int (*get)(struct dentry *dentry, const char *name,
23113                     void *buffer, size_t size, int handler_flags) = NULL;
23114                 struct xattr_handler xops __attribute__ ((unused));
23115
23116                 xops.get = get;
23117
23118   ;
23119   return 0;
23120 }
23121
23122 _ACEOF
23123
23124
23125         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23126         echo "obj-m := conftest.o" >build/Makefile
23127         modpost_flag=''
23128         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23129         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23130   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23131   (eval $ac_try) 2>&5
23132   ac_status=$?
23133   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23134   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23135   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23136   (eval $ac_try) 2>&5
23137   ac_status=$?
23138   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23139   (exit $ac_status); }; }; then
23140
23141                 { $as_echo "$as_me:$LINENO: result: yes" >&5
23142 $as_echo "yes" >&6; }
23143
23144 cat >>confdefs.h <<\_ACEOF
23145 #define HAVE_DENTRY_XATTR_GET 1
23146 _ACEOF
23147
23148
23149 else
23150   $as_echo "$as_me: failed program was:" >&5
23151 sed 's/^/| /' conftest.$ac_ext >&5
23152
23153                 { $as_echo "$as_me:$LINENO: result: no" >&5
23154 $as_echo "no" >&6; }
23155
23156
23157
23158 fi
23159
23160         rm -Rf build
23161
23162
23163
23164
23165         { $as_echo "$as_me:$LINENO: checking whether xattr_handler->set() wants dentry" >&5
23166 $as_echo_n "checking whether xattr_handler->set() wants dentry... " >&6; }
23167
23168
23169 cat confdefs.h - <<_ACEOF >conftest.c
23170 /* confdefs.h.  */
23171 _ACEOF
23172 cat confdefs.h >>conftest.$ac_ext
23173 cat >>conftest.$ac_ext <<_ACEOF
23174 /* end confdefs.h.  */
23175
23176
23177                 #include <linux/xattr.h>
23178
23179 int
23180 main (void)
23181 {
23182
23183                 int (*set)(struct dentry *dentry, const char *name,
23184                     const void *buffer, size_t size, int flags,
23185                     int handler_flags) = NULL;
23186                 struct xattr_handler xops __attribute__ ((unused));
23187
23188                 xops.set = set;
23189
23190   ;
23191   return 0;
23192 }
23193
23194 _ACEOF
23195
23196
23197         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23198         echo "obj-m := conftest.o" >build/Makefile
23199         modpost_flag=''
23200         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23201         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23202   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23203   (eval $ac_try) 2>&5
23204   ac_status=$?
23205   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23206   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23207   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23208   (eval $ac_try) 2>&5
23209   ac_status=$?
23210   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23211   (exit $ac_status); }; }; then
23212
23213                 { $as_echo "$as_me:$LINENO: result: yes" >&5
23214 $as_echo "yes" >&6; }
23215
23216 cat >>confdefs.h <<\_ACEOF
23217 #define HAVE_DENTRY_XATTR_SET 1
23218 _ACEOF
23219
23220
23221 else
23222   $as_echo "$as_me: failed program was:" >&5
23223 sed 's/^/| /' conftest.$ac_ext >&5
23224
23225                 { $as_echo "$as_me:$LINENO: result: no" >&5
23226 $as_echo "no" >&6; }
23227
23228
23229
23230 fi
23231
23232         rm -Rf build
23233
23234
23235
23236
23237         { $as_echo "$as_me:$LINENO: checking whether sops->show_options() wants dentry" >&5
23238 $as_echo_n "checking whether sops->show_options() wants dentry... " >&6; }
23239
23240
23241
23242 cat confdefs.h - <<_ACEOF >conftest.c
23243 /* confdefs.h.  */
23244 _ACEOF
23245 cat confdefs.h >>conftest.$ac_ext
23246 cat >>conftest.$ac_ext <<_ACEOF
23247 /* end confdefs.h.  */
23248
23249
23250                 #include <linux/fs.h>
23251
23252                 int show_options (struct seq_file * x, struct dentry * y) { return 0; };
23253                 static struct super_operations sops __attribute__ ((unused)) = {
23254                         .show_options = show_options,
23255                 };
23256
23257 int
23258 main (void)
23259 {
23260
23261
23262   ;
23263   return 0;
23264 }
23265
23266 _ACEOF
23267
23268
23269         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23270         echo "obj-m := conftest.o" >build/Makefile
23271         modpost_flag=''
23272         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23273         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23274   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23275   (eval $ac_try) 2>&5
23276   ac_status=$?
23277   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23278   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23279   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23280   (eval $ac_try) 2>&5
23281   ac_status=$?
23282   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23283   (exit $ac_status); }; }; then
23284
23285                 { $as_echo "$as_me:$LINENO: result: yes" >&5
23286 $as_echo "yes" >&6; }
23287
23288 cat >>confdefs.h <<\_ACEOF
23289 #define HAVE_SHOW_OPTIONS_WITH_DENTRY 1
23290 _ACEOF
23291
23292
23293 else
23294   $as_echo "$as_me: failed program was:" >&5
23295 sed 's/^/| /' conftest.$ac_ext >&5
23296
23297                 { $as_echo "$as_me:$LINENO: result: no" >&5
23298 $as_echo "no" >&6; }
23299
23300
23301
23302 fi
23303
23304         rm -Rf build
23305
23306
23307
23308
23309         { $as_echo "$as_me:$LINENO: checking whether fops->fsync() wants" >&5
23310 $as_echo_n "checking whether fops->fsync() wants... " >&6; }
23311
23312
23313
23314 cat confdefs.h - <<_ACEOF >conftest.c
23315 /* confdefs.h.  */
23316 _ACEOF
23317 cat confdefs.h >>conftest.$ac_ext
23318 cat >>conftest.$ac_ext <<_ACEOF
23319 /* end confdefs.h.  */
23320
23321
23322                 #include <linux/fs.h>
23323
23324 int
23325 main (void)
23326 {
23327
23328                 int (*fsync) (struct file *, struct dentry *, int) = NULL;
23329                 struct file_operations fops __attribute__ ((unused));
23330
23331                 fops.fsync = fsync;
23332
23333   ;
23334   return 0;
23335 }
23336
23337 _ACEOF
23338
23339
23340         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23341         echo "obj-m := conftest.o" >build/Makefile
23342         modpost_flag=''
23343         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23344         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23345   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23346   (eval $ac_try) 2>&5
23347   ac_status=$?
23348   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23349   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23350   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23351   (eval $ac_try) 2>&5
23352   ac_status=$?
23353   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23354   (exit $ac_status); }; }; then
23355
23356                 { $as_echo "$as_me:$LINENO: result: dentry" >&5
23357 $as_echo "dentry" >&6; }
23358
23359 cat >>confdefs.h <<\_ACEOF
23360 #define HAVE_FSYNC_WITH_DENTRY 1
23361 _ACEOF
23362
23363
23364 else
23365   $as_echo "$as_me: failed program was:" >&5
23366 sed 's/^/| /' conftest.$ac_ext >&5
23367
23368
23369
23370
23371 fi
23372
23373         rm -Rf build
23374
23375
23376
23377
23378
23379
23380 cat confdefs.h - <<_ACEOF >conftest.c
23381 /* confdefs.h.  */
23382 _ACEOF
23383 cat confdefs.h >>conftest.$ac_ext
23384 cat >>conftest.$ac_ext <<_ACEOF
23385 /* end confdefs.h.  */
23386
23387
23388                 #include <linux/fs.h>
23389
23390 int
23391 main (void)
23392 {
23393
23394                 int (*fsync) (struct file *, int) = NULL;
23395                 struct file_operations fops __attribute__ ((unused));
23396
23397                 fops.fsync = fsync;
23398
23399   ;
23400   return 0;
23401 }
23402
23403 _ACEOF
23404
23405
23406         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23407         echo "obj-m := conftest.o" >build/Makefile
23408         modpost_flag=''
23409         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23410         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23411   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23412   (eval $ac_try) 2>&5
23413   ac_status=$?
23414   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23415   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23416   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23417   (eval $ac_try) 2>&5
23418   ac_status=$?
23419   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23420   (exit $ac_status); }; }; then
23421
23422                 { $as_echo "$as_me:$LINENO: result: no dentry" >&5
23423 $as_echo "no dentry" >&6; }
23424
23425 cat >>confdefs.h <<\_ACEOF
23426 #define HAVE_FSYNC_WITHOUT_DENTRY 1
23427 _ACEOF
23428
23429
23430 else
23431   $as_echo "$as_me: failed program was:" >&5
23432 sed 's/^/| /' conftest.$ac_ext >&5
23433
23434
23435
23436
23437 fi
23438
23439         rm -Rf build
23440
23441
23442
23443
23444
23445
23446 cat confdefs.h - <<_ACEOF >conftest.c
23447 /* confdefs.h.  */
23448 _ACEOF
23449 cat confdefs.h >>conftest.$ac_ext
23450 cat >>conftest.$ac_ext <<_ACEOF
23451 /* end confdefs.h.  */
23452
23453
23454                 #include <linux/fs.h>
23455
23456 int
23457 main (void)
23458 {
23459
23460                 int (*fsync) (struct file *, loff_t, loff_t, int) = NULL;
23461                 struct file_operations fops __attribute__ ((unused));
23462
23463                 fops.fsync = fsync;
23464
23465   ;
23466   return 0;
23467 }
23468
23469 _ACEOF
23470
23471
23472         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23473         echo "obj-m := conftest.o" >build/Makefile
23474         modpost_flag=''
23475         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23476         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23477   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23478   (eval $ac_try) 2>&5
23479   ac_status=$?
23480   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23481   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23482   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23483   (eval $ac_try) 2>&5
23484   ac_status=$?
23485   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23486   (exit $ac_status); }; }; then
23487
23488                 { $as_echo "$as_me:$LINENO: result: range" >&5
23489 $as_echo "range" >&6; }
23490
23491 cat >>confdefs.h <<\_ACEOF
23492 #define HAVE_FSYNC_RANGE 1
23493 _ACEOF
23494
23495
23496 else
23497   $as_echo "$as_me: failed program was:" >&5
23498 sed 's/^/| /' conftest.$ac_ext >&5
23499
23500
23501
23502
23503 fi
23504
23505         rm -Rf build
23506
23507
23508
23509
23510
23511
23512 cat confdefs.h - <<_ACEOF >conftest.c
23513 /* confdefs.h.  */
23514 _ACEOF
23515 cat confdefs.h >>conftest.$ac_ext
23516 cat >>conftest.$ac_ext <<_ACEOF
23517 /* end confdefs.h.  */
23518
23519
23520                 #include <linux/fs.h>
23521
23522 int
23523 main (void)
23524 {
23525
23526                 int (*fsync) (struct file *, struct dentry *, int) = NULL;
23527                 file_operations_no_const fops __attribute__ ((unused));
23528
23529                 fops.fsync = fsync;
23530
23531   ;
23532   return 0;
23533 }
23534
23535 _ACEOF
23536
23537
23538         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23539         echo "obj-m := conftest.o" >build/Makefile
23540         modpost_flag=''
23541         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23542         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23543   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23544   (eval $ac_try) 2>&5
23545   ac_status=$?
23546   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23547   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23548   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23549   (eval $ac_try) 2>&5
23550   ac_status=$?
23551   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23552   (exit $ac_status); }; }; then
23553
23554                 { $as_echo "$as_me:$LINENO: result: dentry" >&5
23555 $as_echo "dentry" >&6; }
23556
23557 cat >>confdefs.h <<\_ACEOF
23558 #define HAVE_FSYNC_WITH_DENTRY 1
23559 _ACEOF
23560
23561
23562 else
23563   $as_echo "$as_me: failed program was:" >&5
23564 sed 's/^/| /' conftest.$ac_ext >&5
23565
23566
23567
23568
23569 fi
23570
23571         rm -Rf build
23572
23573
23574
23575
23576
23577
23578 cat confdefs.h - <<_ACEOF >conftest.c
23579 /* confdefs.h.  */
23580 _ACEOF
23581 cat confdefs.h >>conftest.$ac_ext
23582 cat >>conftest.$ac_ext <<_ACEOF
23583 /* end confdefs.h.  */
23584
23585
23586                 #include <linux/fs.h>
23587
23588 int
23589 main (void)
23590 {
23591
23592                 int (*fsync) (struct file *, int) = NULL;
23593                 file_operations_no_const fops __attribute__ ((unused));
23594
23595                 fops.fsync = fsync;
23596
23597   ;
23598   return 0;
23599 }
23600
23601 _ACEOF
23602
23603
23604         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23605         echo "obj-m := conftest.o" >build/Makefile
23606         modpost_flag=''
23607         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23608         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23609   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23610   (eval $ac_try) 2>&5
23611   ac_status=$?
23612   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23613   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23614   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23615   (eval $ac_try) 2>&5
23616   ac_status=$?
23617   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23618   (exit $ac_status); }; }; then
23619
23620                 { $as_echo "$as_me:$LINENO: result: no dentry" >&5
23621 $as_echo "no dentry" >&6; }
23622
23623 cat >>confdefs.h <<\_ACEOF
23624 #define HAVE_FSYNC_WITHOUT_DENTRY 1
23625 _ACEOF
23626
23627
23628 else
23629   $as_echo "$as_me: failed program was:" >&5
23630 sed 's/^/| /' conftest.$ac_ext >&5
23631
23632
23633
23634
23635 fi
23636
23637         rm -Rf build
23638
23639
23640
23641
23642
23643
23644 cat confdefs.h - <<_ACEOF >conftest.c
23645 /* confdefs.h.  */
23646 _ACEOF
23647 cat confdefs.h >>conftest.$ac_ext
23648 cat >>conftest.$ac_ext <<_ACEOF
23649 /* end confdefs.h.  */
23650
23651
23652                 #include <linux/fs.h>
23653
23654 int
23655 main (void)
23656 {
23657
23658                 int (*fsync) (struct file *, loff_t, loff_t, int) = NULL;
23659                 file_operations_no_const fops __attribute__ ((unused));
23660
23661                 fops.fsync = fsync;
23662
23663   ;
23664   return 0;
23665 }
23666
23667 _ACEOF
23668
23669
23670         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23671         echo "obj-m := conftest.o" >build/Makefile
23672         modpost_flag=''
23673         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23674         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23675   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23676   (eval $ac_try) 2>&5
23677   ac_status=$?
23678   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23679   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23680   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23681   (eval $ac_try) 2>&5
23682   ac_status=$?
23683   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23684   (exit $ac_status); }; }; then
23685
23686                 { $as_echo "$as_me:$LINENO: result: range" >&5
23687 $as_echo "range" >&6; }
23688
23689 cat >>confdefs.h <<\_ACEOF
23690 #define HAVE_FSYNC_RANGE 1
23691 _ACEOF
23692
23693
23694 else
23695   $as_echo "$as_me: failed program was:" >&5
23696 sed 's/^/| /' conftest.$ac_ext >&5
23697
23698
23699
23700
23701 fi
23702
23703         rm -Rf build
23704
23705
23706
23707
23708
23709         { $as_echo "$as_me:$LINENO: checking whether sops->evict_inode() exists" >&5
23710 $as_echo_n "checking whether sops->evict_inode() exists... " >&6; }
23711
23712
23713 cat confdefs.h - <<_ACEOF >conftest.c
23714 /* confdefs.h.  */
23715 _ACEOF
23716 cat confdefs.h >>conftest.$ac_ext
23717 cat >>conftest.$ac_ext <<_ACEOF
23718 /* end confdefs.h.  */
23719
23720
23721                 #include <linux/fs.h>
23722                 void evict_inode (struct inode * t) { return; }
23723                 static struct super_operations sops __attribute__ ((unused)) = {
23724                         .evict_inode = evict_inode,
23725                 };
23726
23727 int
23728 main (void)
23729 {
23730
23731
23732   ;
23733   return 0;
23734 }
23735
23736 _ACEOF
23737
23738
23739         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23740         echo "obj-m := conftest.o" >build/Makefile
23741         modpost_flag=''
23742         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23743         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23744   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23745   (eval $ac_try) 2>&5
23746   ac_status=$?
23747   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23748   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23749   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23750   (eval $ac_try) 2>&5
23751   ac_status=$?
23752   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23753   (exit $ac_status); }; }; then
23754
23755                 { $as_echo "$as_me:$LINENO: result: yes" >&5
23756 $as_echo "yes" >&6; }
23757
23758 cat >>confdefs.h <<\_ACEOF
23759 #define HAVE_EVICT_INODE 1
23760 _ACEOF
23761
23762
23763 else
23764   $as_echo "$as_me: failed program was:" >&5
23765 sed 's/^/| /' conftest.$ac_ext >&5
23766
23767                 { $as_echo "$as_me:$LINENO: result: no" >&5
23768 $as_echo "no" >&6; }
23769
23770
23771
23772 fi
23773
23774         rm -Rf build
23775
23776
23777
23778
23779         { $as_echo "$as_me:$LINENO: checking whether sops->nr_cached_objects() exists" >&5
23780 $as_echo_n "checking whether sops->nr_cached_objects() exists... " >&6; }
23781
23782
23783 cat confdefs.h - <<_ACEOF >conftest.c
23784 /* confdefs.h.  */
23785 _ACEOF
23786 cat confdefs.h >>conftest.$ac_ext
23787 cat >>conftest.$ac_ext <<_ACEOF
23788 /* end confdefs.h.  */
23789
23790
23791                 #include <linux/fs.h>
23792
23793 int
23794 main (void)
23795 {
23796
23797                 int (*nr_cached_objects)(struct super_block *)
23798                         __attribute__ ((unused)) = NULL;
23799                 struct super_operations sops __attribute__ ((unused)) = {
23800                         .nr_cached_objects = nr_cached_objects,
23801                 };
23802
23803   ;
23804   return 0;
23805 }
23806
23807 _ACEOF
23808
23809
23810         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23811         echo "obj-m := conftest.o" >build/Makefile
23812         modpost_flag=''
23813         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23814         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23815   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23816   (eval $ac_try) 2>&5
23817   ac_status=$?
23818   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23819   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23820   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23821   (eval $ac_try) 2>&5
23822   ac_status=$?
23823   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23824   (exit $ac_status); }; }; then
23825
23826                 { $as_echo "$as_me:$LINENO: result: yes" >&5
23827 $as_echo "yes" >&6; }
23828
23829 cat >>confdefs.h <<\_ACEOF
23830 #define HAVE_NR_CACHED_OBJECTS 1
23831 _ACEOF
23832
23833
23834 else
23835   $as_echo "$as_me: failed program was:" >&5
23836 sed 's/^/| /' conftest.$ac_ext >&5
23837
23838                 { $as_echo "$as_me:$LINENO: result: no" >&5
23839 $as_echo "no" >&6; }
23840
23841
23842
23843 fi
23844
23845         rm -Rf build
23846
23847
23848
23849
23850         { $as_echo "$as_me:$LINENO: checking whether sops->free_cached_objects() exists" >&5
23851 $as_echo_n "checking whether sops->free_cached_objects() exists... " >&6; }
23852
23853
23854 cat confdefs.h - <<_ACEOF >conftest.c
23855 /* confdefs.h.  */
23856 _ACEOF
23857 cat confdefs.h >>conftest.$ac_ext
23858 cat >>conftest.$ac_ext <<_ACEOF
23859 /* end confdefs.h.  */
23860
23861
23862                 #include <linux/fs.h>
23863
23864 int
23865 main (void)
23866 {
23867
23868                 void (*free_cached_objects)(struct super_block *, int)
23869                         __attribute__ ((unused)) = NULL;
23870                 struct super_operations sops __attribute__ ((unused)) = {
23871                         .free_cached_objects = free_cached_objects,
23872                 };
23873
23874   ;
23875   return 0;
23876 }
23877
23878 _ACEOF
23879
23880
23881         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23882         echo "obj-m := conftest.o" >build/Makefile
23883         modpost_flag=''
23884         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23885         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23886   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23887   (eval $ac_try) 2>&5
23888   ac_status=$?
23889   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23890   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23891   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23892   (eval $ac_try) 2>&5
23893   ac_status=$?
23894   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23895   (exit $ac_status); }; }; then
23896
23897                 { $as_echo "$as_me:$LINENO: result: yes" >&5
23898 $as_echo "yes" >&6; }
23899
23900 cat >>confdefs.h <<\_ACEOF
23901 #define HAVE_FREE_CACHED_OBJECTS 1
23902 _ACEOF
23903
23904
23905 else
23906   $as_echo "$as_me: failed program was:" >&5
23907 sed 's/^/| /' conftest.$ac_ext >&5
23908
23909                 { $as_echo "$as_me:$LINENO: result: no" >&5
23910 $as_echo "no" >&6; }
23911
23912
23913
23914 fi
23915
23916         rm -Rf build
23917
23918
23919
23920
23921
23922         { $as_echo "$as_me:$LINENO: checking whether fops->fallocate() exists" >&5
23923 $as_echo_n "checking whether fops->fallocate() exists... " >&6; }
23924
23925
23926 cat confdefs.h - <<_ACEOF >conftest.c
23927 /* confdefs.h.  */
23928 _ACEOF
23929 cat confdefs.h >>conftest.$ac_ext
23930 cat >>conftest.$ac_ext <<_ACEOF
23931 /* end confdefs.h.  */
23932
23933
23934                 #include <linux/fs.h>
23935
23936 int
23937 main (void)
23938 {
23939
23940                 long (*fallocate) (struct file *, int, loff_t, loff_t) = NULL;
23941                 struct file_operations fops __attribute__ ((unused)) = {
23942                         .fallocate = fallocate,
23943                 };
23944
23945   ;
23946   return 0;
23947 }
23948
23949 _ACEOF
23950
23951
23952         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
23953         echo "obj-m := conftest.o" >build/Makefile
23954         modpost_flag=''
23955         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
23956         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
23957   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23958   (eval $ac_try) 2>&5
23959   ac_status=$?
23960   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23961   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
23962   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
23963   (eval $ac_try) 2>&5
23964   ac_status=$?
23965   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23966   (exit $ac_status); }; }; then
23967
23968                 { $as_echo "$as_me:$LINENO: result: yes" >&5
23969 $as_echo "yes" >&6; }
23970
23971 cat >>confdefs.h <<\_ACEOF
23972 #define HAVE_FILE_FALLOCATE 1
23973 _ACEOF
23974
23975
23976 else
23977   $as_echo "$as_me: failed program was:" >&5
23978 sed 's/^/| /' conftest.$ac_ext >&5
23979
23980                 { $as_echo "$as_me:$LINENO: result: no" >&5
23981 $as_echo "no" >&6; }
23982
23983
23984
23985 fi
23986
23987         rm -Rf build
23988
23989
23990
23991
23992         { $as_echo "$as_me:$LINENO: checking whether iops->fallocate() exists" >&5
23993 $as_echo_n "checking whether iops->fallocate() exists... " >&6; }
23994
23995
23996 cat confdefs.h - <<_ACEOF >conftest.c
23997 /* confdefs.h.  */
23998 _ACEOF
23999 cat confdefs.h >>conftest.$ac_ext
24000 cat >>conftest.$ac_ext <<_ACEOF
24001 /* end confdefs.h.  */
24002
24003
24004                 #include <linux/fs.h>
24005
24006 int
24007 main (void)
24008 {
24009
24010                 long (*fallocate) (struct inode *, int, loff_t, loff_t) = NULL;
24011                 struct inode_operations fops __attribute__ ((unused)) = {
24012                         .fallocate = fallocate,
24013                 };
24014
24015   ;
24016   return 0;
24017 }
24018
24019 _ACEOF
24020
24021
24022         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24023         echo "obj-m := conftest.o" >build/Makefile
24024         modpost_flag=''
24025         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24026         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24027   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24028   (eval $ac_try) 2>&5
24029   ac_status=$?
24030   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24031   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24032   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24033   (eval $ac_try) 2>&5
24034   ac_status=$?
24035   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24036   (exit $ac_status); }; }; then
24037
24038                 { $as_echo "$as_me:$LINENO: result: yes" >&5
24039 $as_echo "yes" >&6; }
24040
24041 cat >>confdefs.h <<\_ACEOF
24042 #define HAVE_INODE_FALLOCATE 1
24043 _ACEOF
24044
24045
24046 else
24047   $as_echo "$as_me: failed program was:" >&5
24048 sed 's/^/| /' conftest.$ac_ext >&5
24049
24050                 { $as_echo "$as_me:$LINENO: result: no" >&5
24051 $as_echo "no" >&6; }
24052
24053
24054
24055 fi
24056
24057         rm -Rf build
24058
24059
24060
24061
24062         { $as_echo "$as_me:$LINENO: checking whether fops->fallocate() exists" >&5
24063 $as_echo_n "checking whether fops->fallocate() exists... " >&6; }
24064
24065
24066 cat confdefs.h - <<_ACEOF >conftest.c
24067 /* confdefs.h.  */
24068 _ACEOF
24069 cat confdefs.h >>conftest.$ac_ext
24070 cat >>conftest.$ac_ext <<_ACEOF
24071 /* end confdefs.h.  */
24072
24073
24074                 #include <linux/fs.h>
24075
24076 int
24077 main (void)
24078 {
24079
24080                 long (*fallocate) (struct file *, int, loff_t, loff_t) = NULL;
24081                 struct file_operations_no_const fops __attribute__ ((unused)) = {
24082                         .fallocate = fallocate,
24083                 };
24084
24085   ;
24086   return 0;
24087 }
24088
24089 _ACEOF
24090
24091
24092         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24093         echo "obj-m := conftest.o" >build/Makefile
24094         modpost_flag=''
24095         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24096         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24097   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24098   (eval $ac_try) 2>&5
24099   ac_status=$?
24100   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24101   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24102   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24103   (eval $ac_try) 2>&5
24104   ac_status=$?
24105   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24106   (exit $ac_status); }; }; then
24107
24108                 { $as_echo "$as_me:$LINENO: result: yes" >&5
24109 $as_echo "yes" >&6; }
24110
24111 cat >>confdefs.h <<\_ACEOF
24112 #define HAVE_FILE_FALLOCATE 1
24113 _ACEOF
24114
24115
24116 else
24117   $as_echo "$as_me: failed program was:" >&5
24118 sed 's/^/| /' conftest.$ac_ext >&5
24119
24120                 { $as_echo "$as_me:$LINENO: result: no" >&5
24121 $as_echo "no" >&6; }
24122
24123
24124
24125 fi
24126
24127         rm -Rf build
24128
24129
24130
24131
24132
24133         { $as_echo "$as_me:$LINENO: checking whether iops->truncate_range() exists" >&5
24134 $as_echo_n "checking whether iops->truncate_range() exists... " >&6; }
24135
24136
24137 cat confdefs.h - <<_ACEOF >conftest.c
24138 /* confdefs.h.  */
24139 _ACEOF
24140 cat confdefs.h >>conftest.$ac_ext
24141 cat >>conftest.$ac_ext <<_ACEOF
24142 /* end confdefs.h.  */
24143
24144
24145                 #include <linux/fs.h>
24146                 void truncate_range(struct inode *inode, loff_t start,
24147                                     loff_t end) { return; }
24148                 static struct inode_operations iops __attribute__ ((unused)) = {
24149                         .truncate_range = truncate_range,
24150                 };
24151
24152 int
24153 main (void)
24154 {
24155
24156
24157   ;
24158   return 0;
24159 }
24160
24161 _ACEOF
24162
24163
24164         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24165         echo "obj-m := conftest.o" >build/Makefile
24166         modpost_flag=''
24167         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24168         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24169   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24170   (eval $ac_try) 2>&5
24171   ac_status=$?
24172   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24173   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24174   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24175   (eval $ac_try) 2>&5
24176   ac_status=$?
24177   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24178   (exit $ac_status); }; }; then
24179
24180                 { $as_echo "$as_me:$LINENO: result: yes" >&5
24181 $as_echo "yes" >&6; }
24182
24183 cat >>confdefs.h <<\_ACEOF
24184 #define HAVE_INODE_TRUNCATE_RANGE 1
24185 _ACEOF
24186
24187
24188 else
24189   $as_echo "$as_me: failed program was:" >&5
24190 sed 's/^/| /' conftest.$ac_ext >&5
24191
24192                 { $as_echo "$as_me:$LINENO: result: no" >&5
24193 $as_echo "no" >&6; }
24194
24195
24196
24197 fi
24198
24199         rm -Rf build
24200
24201
24202
24203
24204         { $as_echo "$as_me:$LINENO: checking whether iops->create()/mkdir()/mknod() take umode_t" >&5
24205 $as_echo_n "checking whether iops->create()/mkdir()/mknod() take umode_t... " >&6; }
24206
24207
24208 cat confdefs.h - <<_ACEOF >conftest.c
24209 /* confdefs.h.  */
24210 _ACEOF
24211 cat confdefs.h >>conftest.$ac_ext
24212 cat >>conftest.$ac_ext <<_ACEOF
24213 /* end confdefs.h.  */
24214
24215
24216                 #include <linux/fs.h>
24217
24218 int
24219 main (void)
24220 {
24221
24222                 int (*create) (struct inode *, struct dentry *, umode_t,
24223                     struct nameidata *) = NULL;
24224                 struct inode_operations iops __attribute__ ((unused)) = {
24225                         .create = create,
24226                 };
24227
24228   ;
24229   return 0;
24230 }
24231
24232 _ACEOF
24233
24234
24235         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24236         echo "obj-m := conftest.o" >build/Makefile
24237         modpost_flag=''
24238         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24239         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24240   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24241   (eval $ac_try) 2>&5
24242   ac_status=$?
24243   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24244   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24245   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24246   (eval $ac_try) 2>&5
24247   ac_status=$?
24248   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24249   (exit $ac_status); }; }; then
24250
24251                 { $as_echo "$as_me:$LINENO: result: yes" >&5
24252 $as_echo "yes" >&6; }
24253
24254 cat >>confdefs.h <<\_ACEOF
24255 #define HAVE_CREATE_UMODE_T 1
24256 _ACEOF
24257
24258
24259 else
24260   $as_echo "$as_me: failed program was:" >&5
24261 sed 's/^/| /' conftest.$ac_ext >&5
24262
24263                 { $as_echo "$as_me:$LINENO: result: no" >&5
24264 $as_echo "no" >&6; }
24265
24266
24267
24268 fi
24269
24270         rm -Rf build
24271
24272
24273
24274
24275         { $as_echo "$as_me:$LINENO: checking whether dops->d_automount() exists" >&5
24276 $as_echo_n "checking whether dops->d_automount() exists... " >&6; }
24277
24278
24279 cat confdefs.h - <<_ACEOF >conftest.c
24280 /* confdefs.h.  */
24281 _ACEOF
24282 cat confdefs.h >>conftest.$ac_ext
24283 cat >>conftest.$ac_ext <<_ACEOF
24284 /* end confdefs.h.  */
24285
24286
24287                 #include <linux/dcache.h>
24288
24289 int
24290 main (void)
24291 {
24292
24293                 struct vfsmount *(*d_automount) (struct path *) = NULL;
24294                 struct dentry_operations dops __attribute__ ((unused)) = {
24295                         .d_automount = d_automount,
24296                 };
24297
24298   ;
24299   return 0;
24300 }
24301
24302 _ACEOF
24303
24304
24305         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24306         echo "obj-m := conftest.o" >build/Makefile
24307         modpost_flag=''
24308         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24309         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24310   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24311   (eval $ac_try) 2>&5
24312   ac_status=$?
24313   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24314   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24315   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24316   (eval $ac_try) 2>&5
24317   ac_status=$?
24318   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24319   (exit $ac_status); }; }; then
24320
24321                 { $as_echo "$as_me:$LINENO: result: yes" >&5
24322 $as_echo "yes" >&6; }
24323
24324 cat >>confdefs.h <<\_ACEOF
24325 #define HAVE_AUTOMOUNT 1
24326 _ACEOF
24327
24328
24329 else
24330   $as_echo "$as_me: failed program was:" >&5
24331 sed 's/^/| /' conftest.$ac_ext >&5
24332
24333                 { $as_echo "$as_me:$LINENO: result: no" >&5
24334 $as_echo "no" >&6; }
24335
24336
24337
24338 fi
24339
24340         rm -Rf build
24341
24342
24343
24344
24345         { $as_echo "$as_me:$LINENO: checking whether eops->encode_fh() wants inode" >&5
24346 $as_echo_n "checking whether eops->encode_fh() wants inode... " >&6; }
24347
24348
24349 cat confdefs.h - <<_ACEOF >conftest.c
24350 /* confdefs.h.  */
24351 _ACEOF
24352 cat confdefs.h >>conftest.$ac_ext
24353 cat >>conftest.$ac_ext <<_ACEOF
24354 /* end confdefs.h.  */
24355
24356
24357                 #include <linux/exportfs.h>
24358                 int encode_fh(struct inode *inode, __u32 *fh, int *max_len,
24359                               struct inode *parent) { return 0; }
24360                 static struct export_operations eops __attribute__ ((unused))={
24361                         .encode_fh = encode_fh,
24362                 };
24363
24364 int
24365 main (void)
24366 {
24367
24368
24369   ;
24370   return 0;
24371 }
24372
24373 _ACEOF
24374
24375
24376         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24377         echo "obj-m := conftest.o" >build/Makefile
24378         modpost_flag=''
24379         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24380         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24381   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24382   (eval $ac_try) 2>&5
24383   ac_status=$?
24384   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24385   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24386   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24387   (eval $ac_try) 2>&5
24388   ac_status=$?
24389   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24390   (exit $ac_status); }; }; then
24391
24392                 { $as_echo "$as_me:$LINENO: result: yes" >&5
24393 $as_echo "yes" >&6; }
24394
24395 cat >>confdefs.h <<\_ACEOF
24396 #define HAVE_ENCODE_FH_WITH_INODE 1
24397 _ACEOF
24398
24399
24400 else
24401   $as_echo "$as_me: failed program was:" >&5
24402 sed 's/^/| /' conftest.$ac_ext >&5
24403
24404                 { $as_echo "$as_me:$LINENO: result: no" >&5
24405 $as_echo "no" >&6; }
24406
24407
24408
24409 fi
24410
24411         rm -Rf build
24412
24413
24414
24415         { $as_echo "$as_me:$LINENO: checking whether clear_inode() is available" >&5
24416 $as_echo_n "checking whether clear_inode() is available... " >&6; }
24417
24418
24419
24420 cat confdefs.h - <<_ACEOF >conftest.c
24421 /* confdefs.h.  */
24422 _ACEOF
24423 cat confdefs.h >>conftest.$ac_ext
24424 cat >>conftest.$ac_ext <<_ACEOF
24425 /* end confdefs.h.  */
24426
24427
24428                 #include <linux/fs.h>
24429
24430 int
24431 main (void)
24432 {
24433
24434                 clear_inode(NULL);
24435
24436   ;
24437   return 0;
24438 }
24439
24440 _ACEOF
24441
24442
24443         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24444         echo "obj-m := conftest.o" >build/Makefile
24445         modpost_flag=''
24446         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24447         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24448   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24449   (eval $ac_try) 2>&5
24450   ac_status=$?
24451   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24452   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24453   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24454   (eval $ac_try) 2>&5
24455   ac_status=$?
24456   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24457   (exit $ac_status); }; }; then
24458   rc=0
24459 else
24460   $as_echo "$as_me: failed program was:" >&5
24461 sed 's/^/| /' conftest.$ac_ext >&5
24462  rc=1
24463
24464
24465 fi
24466
24467         rm -Rf build
24468
24469
24470         if test $rc -ne 0; then :
24471
24472                 { $as_echo "$as_me:$LINENO: result: no" >&5
24473 $as_echo "no" >&6; }
24474
24475         else
24476                 if test "x$enable_linux_builtin" != xyes; then
24477
24478         grep -q -E '[[:space:]]clear_inode[[:space:]]' \
24479                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
24480         rc=$?
24481         if test $rc -ne 0; then
24482                 export=0
24483                 for file in fs/inode.c; do
24484                         grep -q -E "EXPORT_SYMBOL.*(clear_inode)" \
24485                                 "$LINUX/$file" 2>/dev/null
24486                         rc=$?
24487                         if test $rc -eq 0; then
24488                                 export=1
24489                                 break;
24490                         fi
24491                 done
24492                 if test $export -eq 0; then :
24493                         rc=1
24494                 else :
24495                         rc=0
24496                 fi
24497         else :
24498                 rc=0
24499         fi
24500
24501                 fi
24502                 if test $rc -ne 0; then :
24503
24504                 { $as_echo "$as_me:$LINENO: result: no" >&5
24505 $as_echo "no" >&6; }
24506
24507                 else :
24508
24509                 { $as_echo "$as_me:$LINENO: result: yes" >&5
24510 $as_echo "yes" >&6; }
24511
24512 cat >>confdefs.h <<\_ACEOF
24513 #define HAVE_CLEAR_INODE 1
24514 _ACEOF
24515
24516
24517                 fi
24518         fi
24519
24520
24521         { $as_echo "$as_me:$LINENO: checking whether insert_inode_locked() is available" >&5
24522 $as_echo_n "checking whether insert_inode_locked() is available... " >&6; }
24523
24524
24525
24526 cat confdefs.h - <<_ACEOF >conftest.c
24527 /* confdefs.h.  */
24528 _ACEOF
24529 cat confdefs.h >>conftest.$ac_ext
24530 cat >>conftest.$ac_ext <<_ACEOF
24531 /* end confdefs.h.  */
24532
24533
24534                 #include <linux/fs.h>
24535
24536 int
24537 main (void)
24538 {
24539
24540                 insert_inode_locked(NULL);
24541
24542   ;
24543   return 0;
24544 }
24545
24546 _ACEOF
24547
24548
24549         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24550         echo "obj-m := conftest.o" >build/Makefile
24551         modpost_flag=''
24552         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24553         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24554   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24555   (eval $ac_try) 2>&5
24556   ac_status=$?
24557   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24558   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24559   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24560   (eval $ac_try) 2>&5
24561   ac_status=$?
24562   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24563   (exit $ac_status); }; }; then
24564   rc=0
24565 else
24566   $as_echo "$as_me: failed program was:" >&5
24567 sed 's/^/| /' conftest.$ac_ext >&5
24568  rc=1
24569
24570
24571 fi
24572
24573         rm -Rf build
24574
24575
24576         if test $rc -ne 0; then :
24577
24578                 { $as_echo "$as_me:$LINENO: result: no" >&5
24579 $as_echo "no" >&6; }
24580
24581         else
24582                 if test "x$enable_linux_builtin" != xyes; then
24583
24584         grep -q -E '[[:space:]]insert_inode_locked[[:space:]]' \
24585                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
24586         rc=$?
24587         if test $rc -ne 0; then
24588                 export=0
24589                 for file in fs/inode.c; do
24590                         grep -q -E "EXPORT_SYMBOL.*(insert_inode_locked)" \
24591                                 "$LINUX/$file" 2>/dev/null
24592                         rc=$?
24593                         if test $rc -eq 0; then
24594                                 export=1
24595                                 break;
24596                         fi
24597                 done
24598                 if test $export -eq 0; then :
24599                         rc=1
24600                 else :
24601                         rc=0
24602                 fi
24603         else :
24604                 rc=0
24605         fi
24606
24607                 fi
24608                 if test $rc -ne 0; then :
24609
24610                 { $as_echo "$as_me:$LINENO: result: no" >&5
24611 $as_echo "no" >&6; }
24612
24613                 else :
24614
24615                 { $as_echo "$as_me:$LINENO: result: yes" >&5
24616 $as_echo "yes" >&6; }
24617
24618 cat >>confdefs.h <<\_ACEOF
24619 #define HAVE_INSERT_INODE_LOCKED 1
24620 _ACEOF
24621
24622
24623                 fi
24624         fi
24625
24626
24627         { $as_echo "$as_me:$LINENO: checking whether d_make_root() is available" >&5
24628 $as_echo_n "checking whether d_make_root() is available... " >&6; }
24629
24630
24631
24632 cat confdefs.h - <<_ACEOF >conftest.c
24633 /* confdefs.h.  */
24634 _ACEOF
24635 cat confdefs.h >>conftest.$ac_ext
24636 cat >>conftest.$ac_ext <<_ACEOF
24637 /* end confdefs.h.  */
24638
24639
24640                 #include <linux/dcache.h>
24641
24642 int
24643 main (void)
24644 {
24645
24646                 d_make_root(NULL);
24647
24648   ;
24649   return 0;
24650 }
24651
24652 _ACEOF
24653
24654
24655         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24656         echo "obj-m := conftest.o" >build/Makefile
24657         modpost_flag=''
24658         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24659         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24660   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24661   (eval $ac_try) 2>&5
24662   ac_status=$?
24663   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24664   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24665   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24666   (eval $ac_try) 2>&5
24667   ac_status=$?
24668   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24669   (exit $ac_status); }; }; then
24670   rc=0
24671 else
24672   $as_echo "$as_me: failed program was:" >&5
24673 sed 's/^/| /' conftest.$ac_ext >&5
24674  rc=1
24675
24676
24677 fi
24678
24679         rm -Rf build
24680
24681
24682         if test $rc -ne 0; then :
24683
24684                 { $as_echo "$as_me:$LINENO: result: no" >&5
24685 $as_echo "no" >&6; }
24686
24687         else
24688                 if test "x$enable_linux_builtin" != xyes; then
24689
24690         grep -q -E '[[:space:]]d_make_root[[:space:]]' \
24691                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
24692         rc=$?
24693         if test $rc -ne 0; then
24694                 export=0
24695                 for file in fs/dcache.c; do
24696                         grep -q -E "EXPORT_SYMBOL.*(d_make_root)" \
24697                                 "$LINUX/$file" 2>/dev/null
24698                         rc=$?
24699                         if test $rc -eq 0; then
24700                                 export=1
24701                                 break;
24702                         fi
24703                 done
24704                 if test $export -eq 0; then :
24705                         rc=1
24706                 else :
24707                         rc=0
24708                 fi
24709         else :
24710                 rc=0
24711         fi
24712
24713                 fi
24714                 if test $rc -ne 0; then :
24715
24716                 { $as_echo "$as_me:$LINENO: result: no" >&5
24717 $as_echo "no" >&6; }
24718
24719                 else :
24720
24721                 { $as_echo "$as_me:$LINENO: result: yes" >&5
24722 $as_echo "yes" >&6; }
24723
24724 cat >>confdefs.h <<\_ACEOF
24725 #define HAVE_D_MAKE_ROOT 1
24726 _ACEOF
24727
24728
24729                 fi
24730         fi
24731
24732
24733         { $as_echo "$as_me:$LINENO: checking whether d_obtain_alias() is available" >&5
24734 $as_echo_n "checking whether d_obtain_alias() is available... " >&6; }
24735
24736
24737
24738 cat confdefs.h - <<_ACEOF >conftest.c
24739 /* confdefs.h.  */
24740 _ACEOF
24741 cat confdefs.h >>conftest.$ac_ext
24742 cat >>conftest.$ac_ext <<_ACEOF
24743 /* end confdefs.h.  */
24744
24745
24746                 #include <linux/dcache.h>
24747
24748 int
24749 main (void)
24750 {
24751
24752                 d_obtain_alias(NULL);
24753
24754   ;
24755   return 0;
24756 }
24757
24758 _ACEOF
24759
24760
24761         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24762         echo "obj-m := conftest.o" >build/Makefile
24763         modpost_flag=''
24764         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24765         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24766   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24767   (eval $ac_try) 2>&5
24768   ac_status=$?
24769   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24770   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24771   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24772   (eval $ac_try) 2>&5
24773   ac_status=$?
24774   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24775   (exit $ac_status); }; }; then
24776   rc=0
24777 else
24778   $as_echo "$as_me: failed program was:" >&5
24779 sed 's/^/| /' conftest.$ac_ext >&5
24780  rc=1
24781
24782
24783 fi
24784
24785         rm -Rf build
24786
24787
24788         if test $rc -ne 0; then :
24789
24790                 { $as_echo "$as_me:$LINENO: result: no" >&5
24791 $as_echo "no" >&6; }
24792
24793         else
24794                 if test "x$enable_linux_builtin" != xyes; then
24795
24796         grep -q -E '[[:space:]]d_obtain_alias[[:space:]]' \
24797                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
24798         rc=$?
24799         if test $rc -ne 0; then
24800                 export=0
24801                 for file in fs/dcache.c; do
24802                         grep -q -E "EXPORT_SYMBOL.*(d_obtain_alias)" \
24803                                 "$LINUX/$file" 2>/dev/null
24804                         rc=$?
24805                         if test $rc -eq 0; then
24806                                 export=1
24807                                 break;
24808                         fi
24809                 done
24810                 if test $export -eq 0; then :
24811                         rc=1
24812                 else :
24813                         rc=0
24814                 fi
24815         else :
24816                 rc=0
24817         fi
24818
24819                 fi
24820                 if test $rc -ne 0; then :
24821
24822                 { $as_echo "$as_me:$LINENO: result: no" >&5
24823 $as_echo "no" >&6; }
24824
24825                 else :
24826
24827                 { $as_echo "$as_me:$LINENO: result: yes" >&5
24828 $as_echo "yes" >&6; }
24829
24830 cat >>confdefs.h <<\_ACEOF
24831 #define HAVE_D_OBTAIN_ALIAS 1
24832 _ACEOF
24833
24834
24835                 fi
24836         fi
24837
24838
24839         { $as_echo "$as_me:$LINENO: checking whether check_disk_size_change() is available" >&5
24840 $as_echo_n "checking whether check_disk_size_change() is available... " >&6; }
24841
24842
24843
24844 cat confdefs.h - <<_ACEOF >conftest.c
24845 /* confdefs.h.  */
24846 _ACEOF
24847 cat confdefs.h >>conftest.$ac_ext
24848 cat >>conftest.$ac_ext <<_ACEOF
24849 /* end confdefs.h.  */
24850
24851
24852                 #include <linux/fs.h>
24853
24854 int
24855 main (void)
24856 {
24857
24858                 check_disk_size_change(NULL, NULL);
24859
24860   ;
24861   return 0;
24862 }
24863
24864 _ACEOF
24865
24866
24867         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24868         echo "obj-m := conftest.o" >build/Makefile
24869         modpost_flag=''
24870         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24871         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24872   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24873   (eval $ac_try) 2>&5
24874   ac_status=$?
24875   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24876   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24877   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24878   (eval $ac_try) 2>&5
24879   ac_status=$?
24880   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24881   (exit $ac_status); }; }; then
24882   rc=0
24883 else
24884   $as_echo "$as_me: failed program was:" >&5
24885 sed 's/^/| /' conftest.$ac_ext >&5
24886  rc=1
24887
24888
24889 fi
24890
24891         rm -Rf build
24892
24893
24894         if test $rc -ne 0; then :
24895
24896                 { $as_echo "$as_me:$LINENO: result: no" >&5
24897 $as_echo "no" >&6; }
24898
24899         else
24900                 if test "x$enable_linux_builtin" != xyes; then
24901
24902         grep -q -E '[[:space:]]check_disk_size_change[[:space:]]' \
24903                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
24904         rc=$?
24905         if test $rc -ne 0; then
24906                 export=0
24907                 for file in fs/block_dev.c; do
24908                         grep -q -E "EXPORT_SYMBOL.*(check_disk_size_change)" \
24909                                 "$LINUX/$file" 2>/dev/null
24910                         rc=$?
24911                         if test $rc -eq 0; then
24912                                 export=1
24913                                 break;
24914                         fi
24915                 done
24916                 if test $export -eq 0; then :
24917                         rc=1
24918                 else :
24919                         rc=0
24920                 fi
24921         else :
24922                 rc=0
24923         fi
24924
24925                 fi
24926                 if test $rc -ne 0; then :
24927
24928                 { $as_echo "$as_me:$LINENO: result: no" >&5
24929 $as_echo "no" >&6; }
24930
24931                 else :
24932
24933                 { $as_echo "$as_me:$LINENO: result: yes" >&5
24934 $as_echo "yes" >&6; }
24935
24936 cat >>confdefs.h <<\_ACEOF
24937 #define HAVE_CHECK_DISK_SIZE_CHANGE 1
24938 _ACEOF
24939
24940
24941                 fi
24942         fi
24943
24944
24945         { $as_echo "$as_me:$LINENO: checking whether truncate_setsize() is available" >&5
24946 $as_echo_n "checking whether truncate_setsize() is available... " >&6; }
24947
24948
24949
24950 cat confdefs.h - <<_ACEOF >conftest.c
24951 /* confdefs.h.  */
24952 _ACEOF
24953 cat confdefs.h >>conftest.$ac_ext
24954 cat >>conftest.$ac_ext <<_ACEOF
24955 /* end confdefs.h.  */
24956
24957
24958                 #include <linux/mm.h>
24959
24960 int
24961 main (void)
24962 {
24963
24964                 truncate_setsize(NULL, 0);
24965
24966   ;
24967   return 0;
24968 }
24969
24970 _ACEOF
24971
24972
24973         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
24974         echo "obj-m := conftest.o" >build/Makefile
24975         modpost_flag=''
24976         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
24977         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
24978   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24979   (eval $ac_try) 2>&5
24980   ac_status=$?
24981   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24982   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
24983   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
24984   (eval $ac_try) 2>&5
24985   ac_status=$?
24986   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24987   (exit $ac_status); }; }; then
24988   rc=0
24989 else
24990   $as_echo "$as_me: failed program was:" >&5
24991 sed 's/^/| /' conftest.$ac_ext >&5
24992  rc=1
24993
24994
24995 fi
24996
24997         rm -Rf build
24998
24999
25000         if test $rc -ne 0; then :
25001
25002                 { $as_echo "$as_me:$LINENO: result: no" >&5
25003 $as_echo "no" >&6; }
25004
25005         else
25006                 if test "x$enable_linux_builtin" != xyes; then
25007
25008         grep -q -E '[[:space:]]truncate_setsize[[:space:]]' \
25009                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
25010         rc=$?
25011         if test $rc -ne 0; then
25012                 export=0
25013                 for file in mm/truncate.c; do
25014                         grep -q -E "EXPORT_SYMBOL.*(truncate_setsize)" \
25015                                 "$LINUX/$file" 2>/dev/null
25016                         rc=$?
25017                         if test $rc -eq 0; then
25018                                 export=1
25019                                 break;
25020                         fi
25021                 done
25022                 if test $export -eq 0; then :
25023                         rc=1
25024                 else :
25025                         rc=0
25026                 fi
25027         else :
25028                 rc=0
25029         fi
25030
25031                 fi
25032                 if test $rc -ne 0; then :
25033
25034                 { $as_echo "$as_me:$LINENO: result: no" >&5
25035 $as_echo "no" >&6; }
25036
25037                 else :
25038
25039                 { $as_echo "$as_me:$LINENO: result: yes" >&5
25040 $as_echo "yes" >&6; }
25041
25042 cat >>confdefs.h <<\_ACEOF
25043 #define HAVE_TRUNCATE_SETSIZE 1
25044 _ACEOF
25045
25046
25047                 fi
25048         fi
25049
25050
25051
25052         { $as_echo "$as_me:$LINENO: checking whether security_inode_init_security wants 6 args" >&5
25053 $as_echo_n "checking whether security_inode_init_security wants 6 args... " >&6; }
25054         tmp_flags="$EXTRA_KCFLAGS"
25055         EXTRA_KCFLAGS="-Werror"
25056
25057
25058 cat confdefs.h - <<_ACEOF >conftest.c
25059 /* confdefs.h.  */
25060 _ACEOF
25061 cat confdefs.h >>conftest.$ac_ext
25062 cat >>conftest.$ac_ext <<_ACEOF
25063 /* end confdefs.h.  */
25064
25065
25066                 #include <linux/security.h>
25067
25068 int
25069 main (void)
25070 {
25071
25072                 struct inode *ip __attribute__ ((unused)) = NULL;
25073                 struct inode *dip __attribute__ ((unused)) = NULL;
25074                 const struct qstr *str __attribute__ ((unused)) = NULL;
25075                 char *name __attribute__ ((unused)) = NULL;
25076                 void *value __attribute__ ((unused)) = NULL;
25077                 size_t len __attribute__ ((unused)) = 0;
25078
25079                 security_inode_init_security(ip, dip, str, &name, &value, &len);
25080
25081   ;
25082   return 0;
25083 }
25084
25085 _ACEOF
25086
25087
25088         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
25089         echo "obj-m := conftest.o" >build/Makefile
25090         modpost_flag=''
25091         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
25092         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
25093   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25094   (eval $ac_try) 2>&5
25095   ac_status=$?
25096   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25097   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
25098   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25099   (eval $ac_try) 2>&5
25100   ac_status=$?
25101   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25102   (exit $ac_status); }; }; then
25103
25104                 { $as_echo "$as_me:$LINENO: result: yes" >&5
25105 $as_echo "yes" >&6; }
25106
25107 cat >>confdefs.h <<\_ACEOF
25108 #define HAVE_6ARGS_SECURITY_INODE_INIT_SECURITY 1
25109 _ACEOF
25110
25111
25112 else
25113   $as_echo "$as_me: failed program was:" >&5
25114 sed 's/^/| /' conftest.$ac_ext >&5
25115
25116                 { $as_echo "$as_me:$LINENO: result: no" >&5
25117 $as_echo "no" >&6; }
25118
25119
25120
25121 fi
25122
25123         rm -Rf build
25124
25125
25126         EXTRA_KCFLAGS="$tmp_flags"
25127
25128
25129         { $as_echo "$as_me:$LINENO: checking whether security_inode_init_security wants callback" >&5
25130 $as_echo_n "checking whether security_inode_init_security wants callback... " >&6; }
25131         tmp_flags="$EXTRA_KCFLAGS"
25132         EXTRA_KCFLAGS="-Werror"
25133
25134
25135 cat confdefs.h - <<_ACEOF >conftest.c
25136 /* confdefs.h.  */
25137 _ACEOF
25138 cat confdefs.h >>conftest.$ac_ext
25139 cat >>conftest.$ac_ext <<_ACEOF
25140 /* end confdefs.h.  */
25141
25142
25143                 #include <linux/security.h>
25144
25145 int
25146 main (void)
25147 {
25148
25149                 struct inode *ip __attribute__ ((unused)) = NULL;
25150                 struct inode *dip __attribute__ ((unused)) = NULL;
25151                 const struct qstr *str __attribute__ ((unused)) = NULL;
25152                 initxattrs func __attribute__ ((unused)) = NULL;
25153
25154                 security_inode_init_security(ip, dip, str, func, NULL);
25155
25156   ;
25157   return 0;
25158 }
25159
25160 _ACEOF
25161
25162
25163         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
25164         echo "obj-m := conftest.o" >build/Makefile
25165         modpost_flag=''
25166         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
25167         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
25168   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25169   (eval $ac_try) 2>&5
25170   ac_status=$?
25171   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25172   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
25173   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25174   (eval $ac_try) 2>&5
25175   ac_status=$?
25176   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25177   (exit $ac_status); }; }; then
25178
25179                 { $as_echo "$as_me:$LINENO: result: yes" >&5
25180 $as_echo "yes" >&6; }
25181
25182 cat >>confdefs.h <<\_ACEOF
25183 #define HAVE_CALLBACK_SECURITY_INODE_INIT_SECURITY 1
25184 _ACEOF
25185
25186
25187 else
25188   $as_echo "$as_me: failed program was:" >&5
25189 sed 's/^/| /' conftest.$ac_ext >&5
25190
25191                 { $as_echo "$as_me:$LINENO: result: no" >&5
25192 $as_echo "no" >&6; }
25193
25194
25195
25196 fi
25197
25198         rm -Rf build
25199
25200
25201         EXTRA_KCFLAGS="$tmp_flags"
25202
25203         { $as_echo "$as_me:$LINENO: checking whether mount_nodev() is available" >&5
25204 $as_echo_n "checking whether mount_nodev() is available... " >&6; }
25205
25206
25207
25208 cat confdefs.h - <<_ACEOF >conftest.c
25209 /* confdefs.h.  */
25210 _ACEOF
25211 cat confdefs.h >>conftest.$ac_ext
25212 cat >>conftest.$ac_ext <<_ACEOF
25213 /* end confdefs.h.  */
25214
25215
25216                 #include <linux/fs.h>
25217
25218 int
25219 main (void)
25220 {
25221
25222                 mount_nodev(NULL, 0, NULL, NULL);
25223
25224   ;
25225   return 0;
25226 }
25227
25228 _ACEOF
25229
25230
25231         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
25232         echo "obj-m := conftest.o" >build/Makefile
25233         modpost_flag=''
25234         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
25235         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
25236   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25237   (eval $ac_try) 2>&5
25238   ac_status=$?
25239   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25240   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
25241   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25242   (eval $ac_try) 2>&5
25243   ac_status=$?
25244   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25245   (exit $ac_status); }; }; then
25246   rc=0
25247 else
25248   $as_echo "$as_me: failed program was:" >&5
25249 sed 's/^/| /' conftest.$ac_ext >&5
25250  rc=1
25251
25252
25253 fi
25254
25255         rm -Rf build
25256
25257
25258         if test $rc -ne 0; then :
25259
25260                 { $as_echo "$as_me:$LINENO: result: no" >&5
25261 $as_echo "no" >&6; }
25262
25263         else
25264                 if test "x$enable_linux_builtin" != xyes; then
25265
25266         grep -q -E '[[:space:]]mount_nodev[[:space:]]' \
25267                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
25268         rc=$?
25269         if test $rc -ne 0; then
25270                 export=0
25271                 for file in fs/super.c; do
25272                         grep -q -E "EXPORT_SYMBOL.*(mount_nodev)" \
25273                                 "$LINUX/$file" 2>/dev/null
25274                         rc=$?
25275                         if test $rc -eq 0; then
25276                                 export=1
25277                                 break;
25278                         fi
25279                 done
25280                 if test $export -eq 0; then :
25281                         rc=1
25282                 else :
25283                         rc=0
25284                 fi
25285         else :
25286                 rc=0
25287         fi
25288
25289                 fi
25290                 if test $rc -ne 0; then :
25291
25292                 { $as_echo "$as_me:$LINENO: result: no" >&5
25293 $as_echo "no" >&6; }
25294
25295                 else :
25296
25297                 { $as_echo "$as_me:$LINENO: result: yes" >&5
25298 $as_echo "yes" >&6; }
25299
25300 cat >>confdefs.h <<\_ACEOF
25301 #define HAVE_MOUNT_NODEV 1
25302 _ACEOF
25303
25304
25305                 fi
25306         fi
25307
25308
25309
25310         { $as_echo "$as_me:$LINENO: checking whether super_block has s_shrink" >&5
25311 $as_echo_n "checking whether super_block has s_shrink... " >&6; }
25312
25313
25314 cat confdefs.h - <<_ACEOF >conftest.c
25315 /* confdefs.h.  */
25316 _ACEOF
25317 cat confdefs.h >>conftest.$ac_ext
25318 cat >>conftest.$ac_ext <<_ACEOF
25319 /* end confdefs.h.  */
25320
25321
25322                 #include <linux/fs.h>
25323
25324 int
25325 main (void)
25326 {
25327
25328                 int (*shrink)(struct shrinker *, struct shrink_control *sc)
25329                         __attribute__ ((unused)) = NULL;
25330                 struct super_block sb __attribute__ ((unused)) = {
25331                         .s_shrink.shrink = shrink,
25332                         .s_shrink.seeks = DEFAULT_SEEKS,
25333                         .s_shrink.batch = 0,
25334                 };
25335
25336   ;
25337   return 0;
25338 }
25339
25340 _ACEOF
25341
25342
25343         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
25344         echo "obj-m := conftest.o" >build/Makefile
25345         modpost_flag=''
25346         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
25347         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
25348   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25349   (eval $ac_try) 2>&5
25350   ac_status=$?
25351   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25352   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
25353   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25354   (eval $ac_try) 2>&5
25355   ac_status=$?
25356   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25357   (exit $ac_status); }; }; then
25358
25359                 { $as_echo "$as_me:$LINENO: result: yes" >&5
25360 $as_echo "yes" >&6; }
25361
25362 cat >>confdefs.h <<\_ACEOF
25363 #define HAVE_SHRINK 1
25364 _ACEOF
25365
25366
25367
25368 else
25369   $as_echo "$as_me: failed program was:" >&5
25370 sed 's/^/| /' conftest.$ac_ext >&5
25371
25372                 { $as_echo "$as_me:$LINENO: result: no" >&5
25373 $as_echo "no" >&6; }
25374
25375
25376
25377 fi
25378
25379         rm -Rf build
25380
25381
25382
25383
25384         { $as_echo "$as_me:$LINENO: checking whether super_block has s_bdi" >&5
25385 $as_echo_n "checking whether super_block has s_bdi... " >&6; }
25386
25387
25388 cat confdefs.h - <<_ACEOF >conftest.c
25389 /* confdefs.h.  */
25390 _ACEOF
25391 cat confdefs.h >>conftest.$ac_ext
25392 cat >>conftest.$ac_ext <<_ACEOF
25393 /* end confdefs.h.  */
25394
25395
25396                 #include <linux/fs.h>
25397
25398 int
25399 main (void)
25400 {
25401
25402                 struct super_block sb __attribute__ ((unused));
25403                 sb.s_bdi = NULL;
25404
25405   ;
25406   return 0;
25407 }
25408
25409 _ACEOF
25410
25411
25412         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
25413         echo "obj-m := conftest.o" >build/Makefile
25414         modpost_flag=''
25415         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
25416         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
25417   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25418   (eval $ac_try) 2>&5
25419   ac_status=$?
25420   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25421   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
25422   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25423   (eval $ac_try) 2>&5
25424   ac_status=$?
25425   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25426   (exit $ac_status); }; }; then
25427
25428                 { $as_echo "$as_me:$LINENO: result: yes" >&5
25429 $as_echo "yes" >&6; }
25430
25431 cat >>confdefs.h <<\_ACEOF
25432 #define HAVE_BDI 1
25433 _ACEOF
25434
25435
25436 else
25437   $as_echo "$as_me: failed program was:" >&5
25438 sed 's/^/| /' conftest.$ac_ext >&5
25439
25440                 { $as_echo "$as_me:$LINENO: result: no" >&5
25441 $as_echo "no" >&6; }
25442
25443
25444
25445 fi
25446
25447         rm -Rf build
25448
25449
25450
25451         { $as_echo "$as_me:$LINENO: checking whether bdi_setup_and_register() is available" >&5
25452 $as_echo_n "checking whether bdi_setup_and_register() is available... " >&6; }
25453
25454
25455
25456 cat confdefs.h - <<_ACEOF >conftest.c
25457 /* confdefs.h.  */
25458 _ACEOF
25459 cat confdefs.h >>conftest.$ac_ext
25460 cat >>conftest.$ac_ext <<_ACEOF
25461 /* end confdefs.h.  */
25462
25463
25464                 #include <linux/backing-dev.h>
25465
25466 int
25467 main (void)
25468 {
25469
25470                 bdi_setup_and_register(NULL, NULL, 0);
25471
25472   ;
25473   return 0;
25474 }
25475
25476 _ACEOF
25477
25478
25479         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
25480         echo "obj-m := conftest.o" >build/Makefile
25481         modpost_flag=''
25482         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
25483         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
25484   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25485   (eval $ac_try) 2>&5
25486   ac_status=$?
25487   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25488   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
25489   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25490   (eval $ac_try) 2>&5
25491   ac_status=$?
25492   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25493   (exit $ac_status); }; }; then
25494   rc=0
25495 else
25496   $as_echo "$as_me: failed program was:" >&5
25497 sed 's/^/| /' conftest.$ac_ext >&5
25498  rc=1
25499
25500
25501 fi
25502
25503         rm -Rf build
25504
25505
25506         if test $rc -ne 0; then :
25507
25508                 { $as_echo "$as_me:$LINENO: result: no" >&5
25509 $as_echo "no" >&6; }
25510
25511         else
25512                 if test "x$enable_linux_builtin" != xyes; then
25513
25514         grep -q -E '[[:space:]]bdi_setup_and_register[[:space:]]' \
25515                 $LINUX_OBJ/$LINUX_SYMBOLS 2>/dev/null
25516         rc=$?
25517         if test $rc -ne 0; then
25518                 export=0
25519                 for file in mm/backing-dev.c; do
25520                         grep -q -E "EXPORT_SYMBOL.*(bdi_setup_and_register)" \
25521                                 "$LINUX/$file" 2>/dev/null
25522                         rc=$?
25523                         if test $rc -eq 0; then
25524                                 export=1
25525                                 break;
25526                         fi
25527                 done
25528                 if test $export -eq 0; then :
25529                         rc=1
25530                 else :
25531                         rc=0
25532                 fi
25533         else :
25534                 rc=0
25535         fi
25536
25537                 fi
25538                 if test $rc -ne 0; then :
25539
25540                 { $as_echo "$as_me:$LINENO: result: no" >&5
25541 $as_echo "no" >&6; }
25542
25543                 else :
25544
25545                 { $as_echo "$as_me:$LINENO: result: yes" >&5
25546 $as_echo "yes" >&6; }
25547
25548 cat >>confdefs.h <<\_ACEOF
25549 #define HAVE_BDI_SETUP_AND_REGISTER 1
25550 _ACEOF
25551
25552
25553                 fi
25554         fi
25555
25556
25557
25558         { $as_echo "$as_me:$LINENO: checking whether set_nlink() is available" >&5
25559 $as_echo_n "checking whether set_nlink() is available... " >&6; }
25560
25561
25562 cat confdefs.h - <<_ACEOF >conftest.c
25563 /* confdefs.h.  */
25564 _ACEOF
25565 cat confdefs.h >>conftest.$ac_ext
25566 cat >>conftest.$ac_ext <<_ACEOF
25567 /* end confdefs.h.  */
25568
25569
25570                 #include <linux/fs.h>
25571
25572 int
25573 main (void)
25574 {
25575
25576                 struct inode node;
25577                 unsigned int link = 0;
25578                 (void) set_nlink(&node, link);
25579
25580   ;
25581   return 0;
25582 }
25583
25584 _ACEOF
25585
25586
25587         rm -Rf build && mkdir -p build && touch build/conftest.mod.c
25588         echo "obj-m := conftest.o" >build/Makefile
25589         modpost_flag=''
25590         test "x$enable_linux_builtin" = xyes && modpost_flag='modpost=true' # fake modpost stage
25591         if { ac_try='cp conftest.c build && make modules -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $ARCH_UM M=$PWD/build $modpost_flag'
25592   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25593   (eval $ac_try) 2>&5
25594   ac_status=$?
25595   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25596   (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
25597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
25598   (eval $ac_try) 2>&5
25599   ac_status=$?
25600   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25601   (exit $ac_status); }; }; then
25602
25603                 { $as_echo "$as_me:$LINENO: result: yes" >&5
25604 $as_echo "yes" >&6; }
25605
25606 cat >>confdefs.h <<\_ACEOF
25607 #define HAVE_SET_NLINK 1
25608 _ACEOF
25609
25610
25611 else
25612   $as_echo "$as_me: failed program was:" >&5
25613 sed 's/^/| /' conftest.$ac_ext >&5
25614
25615                 { $as_echo "$as_me:$LINENO: result: no" >&5
25616 $as_echo "no" >&6; }
25617
25618
25619
25620 fi
25621
25622         rm -Rf build
25623
25624
25625
25626
25627         if test "$LINUX_OBJ" != "$LINUX"; then
25628
25629                 KERNELMAKE_PARAMS="$KERNELMAKE_PARAMS O=$LINUX_OBJ"
25630
25631 fi
25632
25633
25634
25635
25636                         KERNELCPPFLAGS="$KERNELCPPFLAGS $NO_UNUSED_BUT_SET_VARIABLE"
25637         KERNELCPPFLAGS="$KERNELCPPFLAGS -DHAVE_SPL -D_KERNEL"
25638         KERNELCPPFLAGS="$KERNELCPPFLAGS -DTEXT_DOMAIN=\\\"zfs-linux-kernel\\\""
25639
25640
25641
25642
25643
25644
25645 # Check whether --with-udevdir was given.
25646 if test "${with_udevdir+set}" = set; then
25647   withval=$with_udevdir; udevdir=$withval
25648 else
25649   udevdir='${exec_prefix}/lib/udev'
25650 fi
25651
25652
25653
25654 # Check whether --with-udevruledir was given.
25655 if test "${with_udevruledir+set}" = set; then
25656   withval=$with_udevruledir; udevruledir=$withval
25657 else
25658   udevruledir='${udevdir}/rules.d'
25659 fi
25660
25661
25662
25663
25664
25665
25666         { $as_echo "$as_me:$LINENO: checking for target asm dir" >&5
25667 $as_echo_n "checking for target asm dir... " >&6; }
25668         TARGET_ARCH=`echo ${target_cpu} | sed -e s/i.86/i386/`
25669
25670         case $TARGET_ARCH in
25671         i386|x86_64)
25672                 TARGET_ASM_DIR=asm-${TARGET_ARCH}
25673                 ;;
25674         *)
25675                 TARGET_ASM_DIR=asm-generic
25676                 ;;
25677         esac
25678
25679
25680         { $as_echo "$as_me:$LINENO: result: $TARGET_ASM_DIR" >&5
25681 $as_echo "$TARGET_ASM_DIR" >&6; }
25682
25683
25684         { $as_echo "$as_me:$LINENO: checking for ioctl()" >&5
25685 $as_echo_n "checking for ioctl()... " >&6; }
25686         cat >conftest.$ac_ext <<_ACEOF
25687 /* confdefs.h.  */
25688 _ACEOF
25689 cat confdefs.h >>conftest.$ac_ext
25690 cat >>conftest.$ac_ext <<_ACEOF
25691 /* end confdefs.h.  */
25692 #include <unistd.h>
25693
25694 _ACEOF
25695 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
25696   $EGREP "ioctl" >/dev/null 2>&1; then
25697   is_unistd=yes
25698 else
25699   is_unistd=no
25700 fi
25701 rm -f conftest*
25702
25703         cat >conftest.$ac_ext <<_ACEOF
25704 /* confdefs.h.  */
25705 _ACEOF
25706 cat confdefs.h >>conftest.$ac_ext
25707 cat >>conftest.$ac_ext <<_ACEOF
25708 /* end confdefs.h.  */
25709 #include <sys/ioctl.h>
25710
25711 _ACEOF
25712 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
25713   $EGREP "ioctl" >/dev/null 2>&1; then
25714   is_sys_ioctl=yes
25715 else
25716   is_sys_ioctl=no
25717 fi
25718 rm -f conftest*
25719
25720         cat >conftest.$ac_ext <<_ACEOF
25721 /* confdefs.h.  */
25722 _ACEOF
25723 cat confdefs.h >>conftest.$ac_ext
25724 cat >>conftest.$ac_ext <<_ACEOF
25725 /* end confdefs.h.  */
25726 #include <stropts.h>
25727
25728 _ACEOF
25729 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
25730   $EGREP "ioctl" >/dev/null 2>&1; then
25731   is_stropts=yes
25732 else
25733   is_stropts=no
25734 fi
25735 rm -f conftest*
25736
25737
25738         if test $is_unistd = yes; then
25739                 result=unistd.h
25740
25741 cat >>confdefs.h <<\_ACEOF
25742 #define HAVE_IOCTL_IN_UNISTD_H 1
25743 _ACEOF
25744
25745         else
25746
25747                 if test $is_sys_ioctl = yes; then
25748                         result=sys/ioctl.h
25749
25750 cat >>confdefs.h <<\_ACEOF
25751 #define HAVE_IOCTL_IN_SYS_IOCTL_H 1
25752 _ACEOF
25753
25754                 elif test $is_stropts = yes; then
25755
25756 cat >>confdefs.h <<\_ACEOF
25757 #define HAVE_IOCTL_IN_STROPTS_H 1
25758 _ACEOF
25759
25760                 else
25761                         result=no
25762                 fi
25763         fi
25764
25765         if test $result = no; then
25766                 { $as_echo "$as_me:$LINENO: result: no" >&5
25767 $as_echo "no" >&6; }
25768                 { { $as_echo "$as_me:$LINENO: error: *** Cannot locate ioctl() definition" >&5
25769 $as_echo "$as_me: error: *** Cannot locate ioctl() definition" >&2;}
25770    { (exit 1); exit 1; }; }
25771         else
25772                 { $as_echo "$as_me:$LINENO: result: yes" >&5
25773 $as_echo "yes" >&6; }
25774         fi
25775
25776
25777         ZLIB=
25778
25779         if test "${ac_cv_header_zlib_h+set}" = set; then
25780   { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
25781 $as_echo_n "checking for zlib.h... " >&6; }
25782 if test "${ac_cv_header_zlib_h+set}" = set; then
25783   $as_echo_n "(cached) " >&6
25784 fi
25785 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
25786 $as_echo "$ac_cv_header_zlib_h" >&6; }
25787 else
25788   # Is the header compilable?
25789 { $as_echo "$as_me:$LINENO: checking zlib.h usability" >&5
25790 $as_echo_n "checking zlib.h usability... " >&6; }
25791 cat >conftest.$ac_ext <<_ACEOF
25792 /* confdefs.h.  */
25793 _ACEOF
25794 cat confdefs.h >>conftest.$ac_ext
25795 cat >>conftest.$ac_ext <<_ACEOF
25796 /* end confdefs.h.  */
25797 $ac_includes_default
25798 #include <zlib.h>
25799 _ACEOF
25800 rm -f conftest.$ac_objext
25801 if { (ac_try="$ac_compile"
25802 case "(($ac_try" in
25803   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25804   *) ac_try_echo=$ac_try;;
25805 esac
25806 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25807 $as_echo "$ac_try_echo") >&5
25808   (eval "$ac_compile") 2>conftest.er1
25809   ac_status=$?
25810   grep -v '^ *+' conftest.er1 >conftest.err
25811   rm -f conftest.er1
25812   cat conftest.err >&5
25813   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25814   (exit $ac_status); } && {
25815          test -z "$ac_c_werror_flag" ||
25816          test ! -s conftest.err
25817        } && test -s conftest.$ac_objext; then
25818   ac_header_compiler=yes
25819 else
25820   $as_echo "$as_me: failed program was:" >&5
25821 sed 's/^/| /' conftest.$ac_ext >&5
25822
25823         ac_header_compiler=no
25824 fi
25825
25826 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25827 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
25828 $as_echo "$ac_header_compiler" >&6; }
25829
25830 # Is the header present?
25831 { $as_echo "$as_me:$LINENO: checking zlib.h presence" >&5
25832 $as_echo_n "checking zlib.h presence... " >&6; }
25833 cat >conftest.$ac_ext <<_ACEOF
25834 /* confdefs.h.  */
25835 _ACEOF
25836 cat confdefs.h >>conftest.$ac_ext
25837 cat >>conftest.$ac_ext <<_ACEOF
25838 /* end confdefs.h.  */
25839 #include <zlib.h>
25840 _ACEOF
25841 if { (ac_try="$ac_cpp conftest.$ac_ext"
25842 case "(($ac_try" in
25843   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25844   *) ac_try_echo=$ac_try;;
25845 esac
25846 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25847 $as_echo "$ac_try_echo") >&5
25848   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
25849   ac_status=$?
25850   grep -v '^ *+' conftest.er1 >conftest.err
25851   rm -f conftest.er1
25852   cat conftest.err >&5
25853   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25854   (exit $ac_status); } >/dev/null && {
25855          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
25856          test ! -s conftest.err
25857        }; then
25858   ac_header_preproc=yes
25859 else
25860   $as_echo "$as_me: failed program was:" >&5
25861 sed 's/^/| /' conftest.$ac_ext >&5
25862
25863   ac_header_preproc=no
25864 fi
25865
25866 rm -f conftest.err conftest.$ac_ext
25867 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
25868 $as_echo "$ac_header_preproc" >&6; }
25869
25870 # So?  What about this header?
25871 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
25872   yes:no: )
25873     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
25874 $as_echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
25875     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
25876 $as_echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
25877     ac_header_preproc=yes
25878     ;;
25879   no:yes:* )
25880     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
25881 $as_echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
25882     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
25883 $as_echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
25884     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
25885 $as_echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
25886     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
25887 $as_echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
25888     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
25889 $as_echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
25890     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
25891 $as_echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
25892
25893     ;;
25894 esac
25895 { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
25896 $as_echo_n "checking for zlib.h... " >&6; }
25897 if test "${ac_cv_header_zlib_h+set}" = set; then
25898   $as_echo_n "(cached) " >&6
25899 else
25900   ac_cv_header_zlib_h=$ac_header_preproc
25901 fi
25902 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
25903 $as_echo "$ac_cv_header_zlib_h" >&6; }
25904
25905 fi
25906 if test "x$ac_cv_header_zlib_h" = x""yes; then
25907   :
25908 else
25909   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25910 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25911 { { $as_echo "$as_me:$LINENO: error:
25912         *** zlib.h missing, zlib-devel package required
25913 See \`config.log' for more details." >&5
25914 $as_echo "$as_me: error:
25915         *** zlib.h missing, zlib-devel package required
25916 See \`config.log' for more details." >&2;}
25917    { (exit 1); exit 1; }; }; }
25918 fi
25919
25920
25921
25922
25923 { $as_echo "$as_me:$LINENO: checking for compress2 in -lz" >&5
25924 $as_echo_n "checking for compress2 in -lz... " >&6; }
25925 if test "${ac_cv_lib_z_compress2+set}" = set; then
25926   $as_echo_n "(cached) " >&6
25927 else
25928   ac_check_lib_save_LIBS=$LIBS
25929 LIBS="-lz  $LIBS"
25930 cat >conftest.$ac_ext <<_ACEOF
25931 /* confdefs.h.  */
25932 _ACEOF
25933 cat confdefs.h >>conftest.$ac_ext
25934 cat >>conftest.$ac_ext <<_ACEOF
25935 /* end confdefs.h.  */
25936
25937 /* Override any GCC internal prototype to avoid an error.
25938    Use char because int might match the return type of a GCC
25939    builtin and then its argument prototype would still apply.  */
25940 #ifdef __cplusplus
25941 extern "C"
25942 #endif
25943 char compress2 ();
25944 int
25945 main ()
25946 {
25947 return compress2 ();
25948   ;
25949   return 0;
25950 }
25951 _ACEOF
25952 rm -f conftest.$ac_objext conftest$ac_exeext
25953 if { (ac_try="$ac_link"
25954 case "(($ac_try" in
25955   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25956   *) ac_try_echo=$ac_try;;
25957 esac
25958 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25959 $as_echo "$ac_try_echo") >&5
25960   (eval "$ac_link") 2>conftest.er1
25961   ac_status=$?
25962   grep -v '^ *+' conftest.er1 >conftest.err
25963   rm -f conftest.er1
25964   cat conftest.err >&5
25965   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25966   (exit $ac_status); } && {
25967          test -z "$ac_c_werror_flag" ||
25968          test ! -s conftest.err
25969        } && test -s conftest$ac_exeext && {
25970          test "$cross_compiling" = yes ||
25971          $as_test_x conftest$ac_exeext
25972        }; then
25973   ac_cv_lib_z_compress2=yes
25974 else
25975   $as_echo "$as_me: failed program was:" >&5
25976 sed 's/^/| /' conftest.$ac_ext >&5
25977
25978         ac_cv_lib_z_compress2=no
25979 fi
25980
25981 rm -rf conftest.dSYM
25982 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
25983       conftest$ac_exeext conftest.$ac_ext
25984 LIBS=$ac_check_lib_save_LIBS
25985 fi
25986 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_compress2" >&5
25987 $as_echo "$ac_cv_lib_z_compress2" >&6; }
25988 if test "x$ac_cv_lib_z_compress2" = x""yes; then
25989   cat >>confdefs.h <<_ACEOF
25990 #define HAVE_LIBZ 1
25991 _ACEOF
25992
25993   LIBS="-lz $LIBS"
25994
25995 else
25996   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25997 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25998 { { $as_echo "$as_me:$LINENO: error:
25999         *** compress2() missing, zlib-devel package required
26000 See \`config.log' for more details." >&5
26001 $as_echo "$as_me: error:
26002         *** compress2() missing, zlib-devel package required
26003 See \`config.log' for more details." >&2;}
26004    { (exit 1); exit 1; }; }; }
26005 fi
26006
26007
26008
26009 { $as_echo "$as_me:$LINENO: checking for uncompress in -lz" >&5
26010 $as_echo_n "checking for uncompress in -lz... " >&6; }
26011 if test "${ac_cv_lib_z_uncompress+set}" = set; then
26012   $as_echo_n "(cached) " >&6
26013 else
26014   ac_check_lib_save_LIBS=$LIBS
26015 LIBS="-lz  $LIBS"
26016 cat >conftest.$ac_ext <<_ACEOF
26017 /* confdefs.h.  */
26018 _ACEOF
26019 cat confdefs.h >>conftest.$ac_ext
26020 cat >>conftest.$ac_ext <<_ACEOF
26021 /* end confdefs.h.  */
26022
26023 /* Override any GCC internal prototype to avoid an error.
26024    Use char because int might match the return type of a GCC
26025    builtin and then its argument prototype would still apply.  */
26026 #ifdef __cplusplus
26027 extern "C"
26028 #endif
26029 char uncompress ();
26030 int
26031 main ()
26032 {
26033 return uncompress ();
26034   ;
26035   return 0;
26036 }
26037 _ACEOF
26038 rm -f conftest.$ac_objext conftest$ac_exeext
26039 if { (ac_try="$ac_link"
26040 case "(($ac_try" in
26041   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26042   *) ac_try_echo=$ac_try;;
26043 esac
26044 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26045 $as_echo "$ac_try_echo") >&5
26046   (eval "$ac_link") 2>conftest.er1
26047   ac_status=$?
26048   grep -v '^ *+' conftest.er1 >conftest.err
26049   rm -f conftest.er1
26050   cat conftest.err >&5
26051   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26052   (exit $ac_status); } && {
26053          test -z "$ac_c_werror_flag" ||
26054          test ! -s conftest.err
26055        } && test -s conftest$ac_exeext && {
26056          test "$cross_compiling" = yes ||
26057          $as_test_x conftest$ac_exeext
26058        }; then
26059   ac_cv_lib_z_uncompress=yes
26060 else
26061   $as_echo "$as_me: failed program was:" >&5
26062 sed 's/^/| /' conftest.$ac_ext >&5
26063
26064         ac_cv_lib_z_uncompress=no
26065 fi
26066
26067 rm -rf conftest.dSYM
26068 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
26069       conftest$ac_exeext conftest.$ac_ext
26070 LIBS=$ac_check_lib_save_LIBS
26071 fi
26072 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_uncompress" >&5
26073 $as_echo "$ac_cv_lib_z_uncompress" >&6; }
26074 if test "x$ac_cv_lib_z_uncompress" = x""yes; then
26075   cat >>confdefs.h <<_ACEOF
26076 #define HAVE_LIBZ 1
26077 _ACEOF
26078
26079   LIBS="-lz $LIBS"
26080
26081 else
26082   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26083 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26084 { { $as_echo "$as_me:$LINENO: error:
26085         *** uncompress() missing, zlib-devel package required
26086 See \`config.log' for more details." >&5
26087 $as_echo "$as_me: error:
26088         *** uncompress() missing, zlib-devel package required
26089 See \`config.log' for more details." >&2;}
26090    { (exit 1); exit 1; }; }; }
26091 fi
26092
26093
26094
26095 { $as_echo "$as_me:$LINENO: checking for crc32 in -lz" >&5
26096 $as_echo_n "checking for crc32 in -lz... " >&6; }
26097 if test "${ac_cv_lib_z_crc32+set}" = set; then
26098   $as_echo_n "(cached) " >&6
26099 else
26100   ac_check_lib_save_LIBS=$LIBS
26101 LIBS="-lz  $LIBS"
26102 cat >conftest.$ac_ext <<_ACEOF
26103 /* confdefs.h.  */
26104 _ACEOF
26105 cat confdefs.h >>conftest.$ac_ext
26106 cat >>conftest.$ac_ext <<_ACEOF
26107 /* end confdefs.h.  */
26108
26109 /* Override any GCC internal prototype to avoid an error.
26110    Use char because int might match the return type of a GCC
26111    builtin and then its argument prototype would still apply.  */
26112 #ifdef __cplusplus
26113 extern "C"
26114 #endif
26115 char crc32 ();
26116 int
26117 main ()
26118 {
26119 return crc32 ();
26120   ;
26121   return 0;
26122 }
26123 _ACEOF
26124 rm -f conftest.$ac_objext conftest$ac_exeext
26125 if { (ac_try="$ac_link"
26126 case "(($ac_try" in
26127   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26128   *) ac_try_echo=$ac_try;;
26129 esac
26130 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26131 $as_echo "$ac_try_echo") >&5
26132   (eval "$ac_link") 2>conftest.er1
26133   ac_status=$?
26134   grep -v '^ *+' conftest.er1 >conftest.err
26135   rm -f conftest.er1
26136   cat conftest.err >&5
26137   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26138   (exit $ac_status); } && {
26139          test -z "$ac_c_werror_flag" ||
26140          test ! -s conftest.err
26141        } && test -s conftest$ac_exeext && {
26142          test "$cross_compiling" = yes ||
26143          $as_test_x conftest$ac_exeext
26144        }; then
26145   ac_cv_lib_z_crc32=yes
26146 else
26147   $as_echo "$as_me: failed program was:" >&5
26148 sed 's/^/| /' conftest.$ac_ext >&5
26149
26150         ac_cv_lib_z_crc32=no
26151 fi
26152
26153 rm -rf conftest.dSYM
26154 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
26155       conftest$ac_exeext conftest.$ac_ext
26156 LIBS=$ac_check_lib_save_LIBS
26157 fi
26158 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_crc32" >&5
26159 $as_echo "$ac_cv_lib_z_crc32" >&6; }
26160 if test "x$ac_cv_lib_z_crc32" = x""yes; then
26161   cat >>confdefs.h <<_ACEOF
26162 #define HAVE_LIBZ 1
26163 _ACEOF
26164
26165   LIBS="-lz $LIBS"
26166
26167 else
26168   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26169 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26170 { { $as_echo "$as_me:$LINENO: error:
26171         *** crc32() missing, zlib-devel package required
26172 See \`config.log' for more details." >&5
26173 $as_echo "$as_me: error:
26174         *** crc32() missing, zlib-devel package required
26175 See \`config.log' for more details." >&2;}
26176    { (exit 1); exit 1; }; }; }
26177 fi
26178
26179
26180         ZLIB="-lz"
26181
26182
26183 cat >>confdefs.h <<\_ACEOF
26184 #define HAVE_ZLIB 1
26185 _ACEOF
26186
26187
26188
26189         LIBUUID=
26190
26191         if test "${ac_cv_header_uuid_uuid_h+set}" = set; then
26192   { $as_echo "$as_me:$LINENO: checking for uuid/uuid.h" >&5
26193 $as_echo_n "checking for uuid/uuid.h... " >&6; }
26194 if test "${ac_cv_header_uuid_uuid_h+set}" = set; then
26195   $as_echo_n "(cached) " >&6
26196 fi
26197 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_uuid_uuid_h" >&5
26198 $as_echo "$ac_cv_header_uuid_uuid_h" >&6; }
26199 else
26200   # Is the header compilable?
26201 { $as_echo "$as_me:$LINENO: checking uuid/uuid.h usability" >&5
26202 $as_echo_n "checking uuid/uuid.h usability... " >&6; }
26203 cat >conftest.$ac_ext <<_ACEOF
26204 /* confdefs.h.  */
26205 _ACEOF
26206 cat confdefs.h >>conftest.$ac_ext
26207 cat >>conftest.$ac_ext <<_ACEOF
26208 /* end confdefs.h.  */
26209 $ac_includes_default
26210 #include <uuid/uuid.h>
26211 _ACEOF
26212 rm -f conftest.$ac_objext
26213 if { (ac_try="$ac_compile"
26214 case "(($ac_try" in
26215   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26216   *) ac_try_echo=$ac_try;;
26217 esac
26218 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26219 $as_echo "$ac_try_echo") >&5
26220   (eval "$ac_compile") 2>conftest.er1
26221   ac_status=$?
26222   grep -v '^ *+' conftest.er1 >conftest.err
26223   rm -f conftest.er1
26224   cat conftest.err >&5
26225   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26226   (exit $ac_status); } && {
26227          test -z "$ac_c_werror_flag" ||
26228          test ! -s conftest.err
26229        } && test -s conftest.$ac_objext; then
26230   ac_header_compiler=yes
26231 else
26232   $as_echo "$as_me: failed program was:" >&5
26233 sed 's/^/| /' conftest.$ac_ext >&5
26234
26235         ac_header_compiler=no
26236 fi
26237
26238 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26239 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26240 $as_echo "$ac_header_compiler" >&6; }
26241
26242 # Is the header present?
26243 { $as_echo "$as_me:$LINENO: checking uuid/uuid.h presence" >&5
26244 $as_echo_n "checking uuid/uuid.h presence... " >&6; }
26245 cat >conftest.$ac_ext <<_ACEOF
26246 /* confdefs.h.  */
26247 _ACEOF
26248 cat confdefs.h >>conftest.$ac_ext
26249 cat >>conftest.$ac_ext <<_ACEOF
26250 /* end confdefs.h.  */
26251 #include <uuid/uuid.h>
26252 _ACEOF
26253 if { (ac_try="$ac_cpp conftest.$ac_ext"
26254 case "(($ac_try" in
26255   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26256   *) ac_try_echo=$ac_try;;
26257 esac
26258 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26259 $as_echo "$ac_try_echo") >&5
26260   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
26261   ac_status=$?
26262   grep -v '^ *+' conftest.er1 >conftest.err
26263   rm -f conftest.er1
26264   cat conftest.err >&5
26265   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26266   (exit $ac_status); } >/dev/null && {
26267          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
26268          test ! -s conftest.err
26269        }; then
26270   ac_header_preproc=yes
26271 else
26272   $as_echo "$as_me: failed program was:" >&5
26273 sed 's/^/| /' conftest.$ac_ext >&5
26274
26275   ac_header_preproc=no
26276 fi
26277
26278 rm -f conftest.err conftest.$ac_ext
26279 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26280 $as_echo "$ac_header_preproc" >&6; }
26281
26282 # So?  What about this header?
26283 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26284   yes:no: )
26285     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: accepted by the compiler, rejected by the preprocessor!" >&5
26286 $as_echo "$as_me: WARNING: uuid/uuid.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
26287     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: proceeding with the compiler's result" >&5
26288 $as_echo "$as_me: WARNING: uuid/uuid.h: proceeding with the compiler's result" >&2;}
26289     ac_header_preproc=yes
26290     ;;
26291   no:yes:* )
26292     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: present but cannot be compiled" >&5
26293 $as_echo "$as_me: WARNING: uuid/uuid.h: present but cannot be compiled" >&2;}
26294     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h:     check for missing prerequisite headers?" >&5
26295 $as_echo "$as_me: WARNING: uuid/uuid.h:     check for missing prerequisite headers?" >&2;}
26296     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: see the Autoconf documentation" >&5
26297 $as_echo "$as_me: WARNING: uuid/uuid.h: see the Autoconf documentation" >&2;}
26298     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h:     section \"Present But Cannot Be Compiled\"" >&5
26299 $as_echo "$as_me: WARNING: uuid/uuid.h:     section \"Present But Cannot Be Compiled\"" >&2;}
26300     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: proceeding with the preprocessor's result" >&5
26301 $as_echo "$as_me: WARNING: uuid/uuid.h: proceeding with the preprocessor's result" >&2;}
26302     { $as_echo "$as_me:$LINENO: WARNING: uuid/uuid.h: in the future, the compiler will take precedence" >&5
26303 $as_echo "$as_me: WARNING: uuid/uuid.h: in the future, the compiler will take precedence" >&2;}
26304
26305     ;;
26306 esac
26307 { $as_echo "$as_me:$LINENO: checking for uuid/uuid.h" >&5
26308 $as_echo_n "checking for uuid/uuid.h... " >&6; }
26309 if test "${ac_cv_header_uuid_uuid_h+set}" = set; then
26310   $as_echo_n "(cached) " >&6
26311 else
26312   ac_cv_header_uuid_uuid_h=$ac_header_preproc
26313 fi
26314 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_uuid_uuid_h" >&5
26315 $as_echo "$ac_cv_header_uuid_uuid_h" >&6; }
26316
26317 fi
26318 if test "x$ac_cv_header_uuid_uuid_h" = x""yes; then
26319   :
26320 else
26321   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26322 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26323 { { $as_echo "$as_me:$LINENO: error:
26324         *** uuid/uuid.h missing, libuuid-devel package required
26325 See \`config.log' for more details." >&5
26326 $as_echo "$as_me: error:
26327         *** uuid/uuid.h missing, libuuid-devel package required
26328 See \`config.log' for more details." >&2;}
26329    { (exit 1); exit 1; }; }; }
26330 fi
26331
26332
26333
26334
26335 { $as_echo "$as_me:$LINENO: checking for uuid_generate in -luuid" >&5
26336 $as_echo_n "checking for uuid_generate in -luuid... " >&6; }
26337 if test "${ac_cv_lib_uuid_uuid_generate+set}" = set; then
26338   $as_echo_n "(cached) " >&6
26339 else
26340   ac_check_lib_save_LIBS=$LIBS
26341 LIBS="-luuid  $LIBS"
26342 cat >conftest.$ac_ext <<_ACEOF
26343 /* confdefs.h.  */
26344 _ACEOF
26345 cat confdefs.h >>conftest.$ac_ext
26346 cat >>conftest.$ac_ext <<_ACEOF
26347 /* end confdefs.h.  */
26348
26349 /* Override any GCC internal prototype to avoid an error.
26350    Use char because int might match the return type of a GCC
26351    builtin and then its argument prototype would still apply.  */
26352 #ifdef __cplusplus
26353 extern "C"
26354 #endif
26355 char uuid_generate ();
26356 int
26357 main ()
26358 {
26359 return uuid_generate ();
26360   ;
26361   return 0;
26362 }
26363 _ACEOF
26364 rm -f conftest.$ac_objext conftest$ac_exeext
26365 if { (ac_try="$ac_link"
26366 case "(($ac_try" in
26367   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26368   *) ac_try_echo=$ac_try;;
26369 esac
26370 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26371 $as_echo "$ac_try_echo") >&5
26372   (eval "$ac_link") 2>conftest.er1
26373   ac_status=$?
26374   grep -v '^ *+' conftest.er1 >conftest.err
26375   rm -f conftest.er1
26376   cat conftest.err >&5
26377   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26378   (exit $ac_status); } && {
26379          test -z "$ac_c_werror_flag" ||
26380          test ! -s conftest.err
26381        } && test -s conftest$ac_exeext && {
26382          test "$cross_compiling" = yes ||
26383          $as_test_x conftest$ac_exeext
26384        }; then
26385   ac_cv_lib_uuid_uuid_generate=yes
26386 else
26387   $as_echo "$as_me: failed program was:" >&5
26388 sed 's/^/| /' conftest.$ac_ext >&5
26389
26390         ac_cv_lib_uuid_uuid_generate=no
26391 fi
26392
26393 rm -rf conftest.dSYM
26394 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
26395       conftest$ac_exeext conftest.$ac_ext
26396 LIBS=$ac_check_lib_save_LIBS
26397 fi
26398 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_generate" >&5
26399 $as_echo "$ac_cv_lib_uuid_uuid_generate" >&6; }
26400 if test "x$ac_cv_lib_uuid_uuid_generate" = x""yes; then
26401   cat >>confdefs.h <<_ACEOF
26402 #define HAVE_LIBUUID 1
26403 _ACEOF
26404
26405   LIBS="-luuid $LIBS"
26406
26407 else
26408   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26409 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26410 { { $as_echo "$as_me:$LINENO: error:
26411         *** uuid_generate() missing, libuuid-devel package required
26412 See \`config.log' for more details." >&5
26413 $as_echo "$as_me: error:
26414         *** uuid_generate() missing, libuuid-devel package required
26415 See \`config.log' for more details." >&2;}
26416    { (exit 1); exit 1; }; }; }
26417 fi
26418
26419
26420
26421 { $as_echo "$as_me:$LINENO: checking for uuid_is_null in -luuid" >&5
26422 $as_echo_n "checking for uuid_is_null in -luuid... " >&6; }
26423 if test "${ac_cv_lib_uuid_uuid_is_null+set}" = set; then
26424   $as_echo_n "(cached) " >&6
26425 else
26426   ac_check_lib_save_LIBS=$LIBS
26427 LIBS="-luuid  $LIBS"
26428 cat >conftest.$ac_ext <<_ACEOF
26429 /* confdefs.h.  */
26430 _ACEOF
26431 cat confdefs.h >>conftest.$ac_ext
26432 cat >>conftest.$ac_ext <<_ACEOF
26433 /* end confdefs.h.  */
26434
26435 /* Override any GCC internal prototype to avoid an error.
26436    Use char because int might match the return type of a GCC
26437    builtin and then its argument prototype would still apply.  */
26438 #ifdef __cplusplus
26439 extern "C"
26440 #endif
26441 char uuid_is_null ();
26442 int
26443 main ()
26444 {
26445 return uuid_is_null ();
26446   ;
26447   return 0;
26448 }
26449 _ACEOF
26450 rm -f conftest.$ac_objext conftest$ac_exeext
26451 if { (ac_try="$ac_link"
26452 case "(($ac_try" in
26453   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26454   *) ac_try_echo=$ac_try;;
26455 esac
26456 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26457 $as_echo "$ac_try_echo") >&5
26458   (eval "$ac_link") 2>conftest.er1
26459   ac_status=$?
26460   grep -v '^ *+' conftest.er1 >conftest.err
26461   rm -f conftest.er1
26462   cat conftest.err >&5
26463   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26464   (exit $ac_status); } && {
26465          test -z "$ac_c_werror_flag" ||
26466          test ! -s conftest.err
26467        } && test -s conftest$ac_exeext && {
26468          test "$cross_compiling" = yes ||
26469          $as_test_x conftest$ac_exeext
26470        }; then
26471   ac_cv_lib_uuid_uuid_is_null=yes
26472 else
26473   $as_echo "$as_me: failed program was:" >&5
26474 sed 's/^/| /' conftest.$ac_ext >&5
26475
26476         ac_cv_lib_uuid_uuid_is_null=no
26477 fi
26478
26479 rm -rf conftest.dSYM
26480 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
26481       conftest$ac_exeext conftest.$ac_ext
26482 LIBS=$ac_check_lib_save_LIBS
26483 fi
26484 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_is_null" >&5
26485 $as_echo "$ac_cv_lib_uuid_uuid_is_null" >&6; }
26486 if test "x$ac_cv_lib_uuid_uuid_is_null" = x""yes; then
26487   cat >>confdefs.h <<_ACEOF
26488 #define HAVE_LIBUUID 1
26489 _ACEOF
26490
26491   LIBS="-luuid $LIBS"
26492
26493 else
26494   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26495 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26496 { { $as_echo "$as_me:$LINENO: error:
26497         *** uuid_is_null() missing, libuuid-devel package required
26498 See \`config.log' for more details." >&5
26499 $as_echo "$as_me: error:
26500         *** uuid_is_null() missing, libuuid-devel package required
26501 See \`config.log' for more details." >&2;}
26502    { (exit 1); exit 1; }; }; }
26503 fi
26504
26505
26506         LIBUUID="-luuid"
26507
26508
26509 cat >>confdefs.h <<\_ACEOF
26510 #define HAVE_LIBUUID 1
26511 _ACEOF
26512
26513
26514
26515
26516 # Check whether --with-blkid was given.
26517 if test "${with_blkid+set}" = set; then
26518   withval=$with_blkid;
26519 else
26520   with_blkid=check
26521 fi
26522
26523
26524         LIBBLKID=
26525         if test "x$with_blkid" != xno; then
26526
26527                 { $as_echo "$as_me:$LINENO: checking for blkid_get_cache in -lblkid" >&5
26528 $as_echo_n "checking for blkid_get_cache in -lblkid... " >&6; }
26529 if test "${ac_cv_lib_blkid_blkid_get_cache+set}" = set; then
26530   $as_echo_n "(cached) " >&6
26531 else
26532   ac_check_lib_save_LIBS=$LIBS
26533 LIBS="-lblkid  $LIBS"
26534 cat >conftest.$ac_ext <<_ACEOF
26535 /* confdefs.h.  */
26536 _ACEOF
26537 cat confdefs.h >>conftest.$ac_ext
26538 cat >>conftest.$ac_ext <<_ACEOF
26539 /* end confdefs.h.  */
26540
26541 /* Override any GCC internal prototype to avoid an error.
26542    Use char because int might match the return type of a GCC
26543    builtin and then its argument prototype would still apply.  */
26544 #ifdef __cplusplus
26545 extern "C"
26546 #endif
26547 char blkid_get_cache ();
26548 int
26549 main ()
26550 {
26551 return blkid_get_cache ();
26552   ;
26553   return 0;
26554 }
26555 _ACEOF
26556 rm -f conftest.$ac_objext conftest$ac_exeext
26557 if { (ac_try="$ac_link"
26558 case "(($ac_try" in
26559   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26560   *) ac_try_echo=$ac_try;;
26561 esac
26562 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26563 $as_echo "$ac_try_echo") >&5
26564   (eval "$ac_link") 2>conftest.er1
26565   ac_status=$?
26566   grep -v '^ *+' conftest.er1 >conftest.err
26567   rm -f conftest.er1
26568   cat conftest.err >&5
26569   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26570   (exit $ac_status); } && {
26571          test -z "$ac_c_werror_flag" ||
26572          test ! -s conftest.err
26573        } && test -s conftest$ac_exeext && {
26574          test "$cross_compiling" = yes ||
26575          $as_test_x conftest$ac_exeext
26576        }; then
26577   ac_cv_lib_blkid_blkid_get_cache=yes
26578 else
26579   $as_echo "$as_me: failed program was:" >&5
26580 sed 's/^/| /' conftest.$ac_ext >&5
26581
26582         ac_cv_lib_blkid_blkid_get_cache=no
26583 fi
26584
26585 rm -rf conftest.dSYM
26586 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
26587       conftest$ac_exeext conftest.$ac_ext
26588 LIBS=$ac_check_lib_save_LIBS
26589 fi
26590 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_blkid_blkid_get_cache" >&5
26591 $as_echo "$ac_cv_lib_blkid_blkid_get_cache" >&6; }
26592 if test "x$ac_cv_lib_blkid_blkid_get_cache" = x""yes; then
26593
26594                         { $as_echo "$as_me:$LINENO: checking for blkid zfs support" >&5
26595 $as_echo_n "checking for blkid zfs support... " >&6; }
26596
26597                         ZFS_DEV=`mktemp`
26598                         dd if=/dev/zero of=$ZFS_DEV bs=1024k count=8 \
26599                                 >/dev/null 2>/dev/null
26600                         echo -en "\x0c\xb1\xba\0\0\0\0\0" | \
26601                                 dd of=$ZFS_DEV bs=1k count=8 \
26602                                 seek=132 conv=notrunc &>/dev/null \
26603                                 >/dev/null 2>/dev/null
26604
26605                         saved_LDFLAGS="$LDFLAGS"
26606                         LDFLAGS="-lblkid"
26607
26608                         if test "$cross_compiling" = yes; then
26609   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26610 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26611 { { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling
26612 See \`config.log' for more details." >&5
26613 $as_echo "$as_me: error: cannot run test program while cross compiling
26614 See \`config.log' for more details." >&2;}
26615    { (exit 1); exit 1; }; }; }
26616 else
26617   cat >conftest.$ac_ext <<_ACEOF
26618 /* confdefs.h.  */
26619 _ACEOF
26620 cat confdefs.h >>conftest.$ac_ext
26621 cat >>conftest.$ac_ext <<_ACEOF
26622 /* end confdefs.h.  */
26623
26624                                 #include <stdio.h>
26625                                 #include <blkid/blkid.h>
26626
26627 int
26628 main ()
26629 {
26630
26631                                 blkid_cache cache;
26632                                 char *value;
26633
26634                                 if (blkid_get_cache(&cache, NULL) < 0)
26635                                         return 1;
26636
26637                                 value = blkid_get_tag_value(cache, "TYPE",
26638                                                             "$ZFS_DEV");
26639                                 if (!value) {
26640                                         blkid_put_cache(cache);
26641                                         return 2;
26642                                 }
26643
26644                                 if (strcmp(value, "zfs")) {
26645                                         free(value);
26646                                         blkid_put_cache(cache);
26647                                         return 3;
26648                                 }
26649
26650                                 free(value);
26651                                 blkid_put_cache(cache);
26652
26653   ;
26654   return 0;
26655 }
26656 _ACEOF
26657 rm -f conftest$ac_exeext
26658 if { (ac_try="$ac_link"
26659 case "(($ac_try" in
26660   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26661   *) ac_try_echo=$ac_try;;
26662 esac
26663 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26664 $as_echo "$ac_try_echo") >&5
26665   (eval "$ac_link") 2>&5
26666   ac_status=$?
26667   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26668   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26669   { (case "(($ac_try" in
26670   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26671   *) ac_try_echo=$ac_try;;
26672 esac
26673 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26674 $as_echo "$ac_try_echo") >&5
26675   (eval "$ac_try") 2>&5
26676   ac_status=$?
26677   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26678   (exit $ac_status); }; }; then
26679
26680                                 rm -f $ZFS_DEV
26681                                 { $as_echo "$as_me:$LINENO: result: yes" >&5
26682 $as_echo "yes" >&6; }
26683                                 LIBBLKID="-lblkid"
26684
26685
26686 cat >>confdefs.h <<\_ACEOF
26687 #define HAVE_LIBBLKID 1
26688 _ACEOF
26689
26690
26691 else
26692   $as_echo "$as_me: program exited with status $ac_status" >&5
26693 $as_echo "$as_me: failed program was:" >&5
26694 sed 's/^/| /' conftest.$ac_ext >&5
26695
26696 ( exit $ac_status )
26697
26698                                 rm -f $ZFS_DEV
26699                                 { $as_echo "$as_me:$LINENO: result: no" >&5
26700 $as_echo "no" >&6; }
26701                                 if test "x$with_blkid" != xcheck; then
26702   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26703 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26704 { { $as_echo "$as_me:$LINENO: error: --with-blkid given but unavailable
26705 See \`config.log' for more details." >&5
26706 $as_echo "$as_me: error: --with-blkid given but unavailable
26707 See \`config.log' for more details." >&2;}
26708    { (exit 1); exit 1; }; }; }
26709 fi
26710
26711
26712 fi
26713 rm -rf conftest.dSYM
26714 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26715 fi
26716
26717
26718
26719                         LDFLAGS="$saved_LDFLAGS"
26720
26721 else
26722
26723                         if test "x$with_blkid" != xcheck; then
26724   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26725 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26726 { { $as_echo "$as_me:$LINENO: error: --with-blkid given but unavailable
26727 See \`config.log' for more details." >&5
26728 $as_echo "$as_me: error: --with-blkid given but unavailable
26729 See \`config.log' for more details." >&2;}
26730    { (exit 1); exit 1; }; }; }
26731 fi
26732
26733
26734
26735 fi
26736
26737
26738 fi
26739
26740
26741
26742
26743 # Check whether --with-selinux was given.
26744 if test "${with_selinux+set}" = set; then
26745   withval=$with_selinux;
26746 else
26747   with_selinux=check
26748 fi
26749
26750
26751         LIBSELINUX=
26752         if test "x$with_selinux" != xno; then
26753
26754                 if test "${ac_cv_header_selinux_selinux_h+set}" = set; then
26755   { $as_echo "$as_me:$LINENO: checking for selinux/selinux.h" >&5
26756 $as_echo_n "checking for selinux/selinux.h... " >&6; }
26757 if test "${ac_cv_header_selinux_selinux_h+set}" = set; then
26758   $as_echo_n "(cached) " >&6
26759 fi
26760 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_selinux_selinux_h" >&5
26761 $as_echo "$ac_cv_header_selinux_selinux_h" >&6; }
26762 else
26763   # Is the header compilable?
26764 { $as_echo "$as_me:$LINENO: checking selinux/selinux.h usability" >&5
26765 $as_echo_n "checking selinux/selinux.h usability... " >&6; }
26766 cat >conftest.$ac_ext <<_ACEOF
26767 /* confdefs.h.  */
26768 _ACEOF
26769 cat confdefs.h >>conftest.$ac_ext
26770 cat >>conftest.$ac_ext <<_ACEOF
26771 /* end confdefs.h.  */
26772 $ac_includes_default
26773 #include <selinux/selinux.h>
26774 _ACEOF
26775 rm -f conftest.$ac_objext
26776 if { (ac_try="$ac_compile"
26777 case "(($ac_try" in
26778   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26779   *) ac_try_echo=$ac_try;;
26780 esac
26781 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26782 $as_echo "$ac_try_echo") >&5
26783   (eval "$ac_compile") 2>conftest.er1
26784   ac_status=$?
26785   grep -v '^ *+' conftest.er1 >conftest.err
26786   rm -f conftest.er1
26787   cat conftest.err >&5
26788   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26789   (exit $ac_status); } && {
26790          test -z "$ac_c_werror_flag" ||
26791          test ! -s conftest.err
26792        } && test -s conftest.$ac_objext; then
26793   ac_header_compiler=yes
26794 else
26795   $as_echo "$as_me: failed program was:" >&5
26796 sed 's/^/| /' conftest.$ac_ext >&5
26797
26798         ac_header_compiler=no
26799 fi
26800
26801 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26802 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
26803 $as_echo "$ac_header_compiler" >&6; }
26804
26805 # Is the header present?
26806 { $as_echo "$as_me:$LINENO: checking selinux/selinux.h presence" >&5
26807 $as_echo_n "checking selinux/selinux.h presence... " >&6; }
26808 cat >conftest.$ac_ext <<_ACEOF
26809 /* confdefs.h.  */
26810 _ACEOF
26811 cat confdefs.h >>conftest.$ac_ext
26812 cat >>conftest.$ac_ext <<_ACEOF
26813 /* end confdefs.h.  */
26814 #include <selinux/selinux.h>
26815 _ACEOF
26816 if { (ac_try="$ac_cpp conftest.$ac_ext"
26817 case "(($ac_try" in
26818   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26819   *) ac_try_echo=$ac_try;;
26820 esac
26821 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26822 $as_echo "$ac_try_echo") >&5
26823   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
26824   ac_status=$?
26825   grep -v '^ *+' conftest.er1 >conftest.err
26826   rm -f conftest.er1
26827   cat conftest.err >&5
26828   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26829   (exit $ac_status); } >/dev/null && {
26830          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
26831          test ! -s conftest.err
26832        }; then
26833   ac_header_preproc=yes
26834 else
26835   $as_echo "$as_me: failed program was:" >&5
26836 sed 's/^/| /' conftest.$ac_ext >&5
26837
26838   ac_header_preproc=no
26839 fi
26840
26841 rm -f conftest.err conftest.$ac_ext
26842 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
26843 $as_echo "$ac_header_preproc" >&6; }
26844
26845 # So?  What about this header?
26846 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
26847   yes:no: )
26848     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: accepted by the compiler, rejected by the preprocessor!" >&5
26849 $as_echo "$as_me: WARNING: selinux/selinux.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
26850     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: proceeding with the compiler's result" >&5
26851 $as_echo "$as_me: WARNING: selinux/selinux.h: proceeding with the compiler's result" >&2;}
26852     ac_header_preproc=yes
26853     ;;
26854   no:yes:* )
26855     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: present but cannot be compiled" >&5
26856 $as_echo "$as_me: WARNING: selinux/selinux.h: present but cannot be compiled" >&2;}
26857     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h:     check for missing prerequisite headers?" >&5
26858 $as_echo "$as_me: WARNING: selinux/selinux.h:     check for missing prerequisite headers?" >&2;}
26859     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: see the Autoconf documentation" >&5
26860 $as_echo "$as_me: WARNING: selinux/selinux.h: see the Autoconf documentation" >&2;}
26861     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h:     section \"Present But Cannot Be Compiled\"" >&5
26862 $as_echo "$as_me: WARNING: selinux/selinux.h:     section \"Present But Cannot Be Compiled\"" >&2;}
26863     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: proceeding with the preprocessor's result" >&5
26864 $as_echo "$as_me: WARNING: selinux/selinux.h: proceeding with the preprocessor's result" >&2;}
26865     { $as_echo "$as_me:$LINENO: WARNING: selinux/selinux.h: in the future, the compiler will take precedence" >&5
26866 $as_echo "$as_me: WARNING: selinux/selinux.h: in the future, the compiler will take precedence" >&2;}
26867
26868     ;;
26869 esac
26870 { $as_echo "$as_me:$LINENO: checking for selinux/selinux.h" >&5
26871 $as_echo_n "checking for selinux/selinux.h... " >&6; }
26872 if test "${ac_cv_header_selinux_selinux_h+set}" = set; then
26873   $as_echo_n "(cached) " >&6
26874 else
26875   ac_cv_header_selinux_selinux_h=$ac_header_preproc
26876 fi
26877 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_selinux_selinux_h" >&5
26878 $as_echo "$ac_cv_header_selinux_selinux_h" >&6; }
26879
26880 fi
26881 if test "x$ac_cv_header_selinux_selinux_h" = x""yes; then
26882
26883                         { $as_echo "$as_me:$LINENO: checking for is_selinux_enabled in -lselinux" >&5
26884 $as_echo_n "checking for is_selinux_enabled in -lselinux... " >&6; }
26885 if test "${ac_cv_lib_selinux_is_selinux_enabled+set}" = set; then
26886   $as_echo_n "(cached) " >&6
26887 else
26888   ac_check_lib_save_LIBS=$LIBS
26889 LIBS="-lselinux  $LIBS"
26890 cat >conftest.$ac_ext <<_ACEOF
26891 /* confdefs.h.  */
26892 _ACEOF
26893 cat confdefs.h >>conftest.$ac_ext
26894 cat >>conftest.$ac_ext <<_ACEOF
26895 /* end confdefs.h.  */
26896
26897 /* Override any GCC internal prototype to avoid an error.
26898    Use char because int might match the return type of a GCC
26899    builtin and then its argument prototype would still apply.  */
26900 #ifdef __cplusplus
26901 extern "C"
26902 #endif
26903 char is_selinux_enabled ();
26904 int
26905 main ()
26906 {
26907 return is_selinux_enabled ();
26908   ;
26909   return 0;
26910 }
26911 _ACEOF
26912 rm -f conftest.$ac_objext conftest$ac_exeext
26913 if { (ac_try="$ac_link"
26914 case "(($ac_try" in
26915   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26916   *) ac_try_echo=$ac_try;;
26917 esac
26918 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26919 $as_echo "$ac_try_echo") >&5
26920   (eval "$ac_link") 2>conftest.er1
26921   ac_status=$?
26922   grep -v '^ *+' conftest.er1 >conftest.err
26923   rm -f conftest.er1
26924   cat conftest.err >&5
26925   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26926   (exit $ac_status); } && {
26927          test -z "$ac_c_werror_flag" ||
26928          test ! -s conftest.err
26929        } && test -s conftest$ac_exeext && {
26930          test "$cross_compiling" = yes ||
26931          $as_test_x conftest$ac_exeext
26932        }; then
26933   ac_cv_lib_selinux_is_selinux_enabled=yes
26934 else
26935   $as_echo "$as_me: failed program was:" >&5
26936 sed 's/^/| /' conftest.$ac_ext >&5
26937
26938         ac_cv_lib_selinux_is_selinux_enabled=no
26939 fi
26940
26941 rm -rf conftest.dSYM
26942 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
26943       conftest$ac_exeext conftest.$ac_ext
26944 LIBS=$ac_check_lib_save_LIBS
26945 fi
26946 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_selinux_is_selinux_enabled" >&5
26947 $as_echo "$ac_cv_lib_selinux_is_selinux_enabled" >&6; }
26948 if test "x$ac_cv_lib_selinux_is_selinux_enabled" = x""yes; then
26949
26950                                 LIBSELINUX="-lselinux"
26951
26952
26953 cat >>confdefs.h <<\_ACEOF
26954 #define HAVE_LIBSELINUX 1
26955 _ACEOF
26956
26957
26958 else
26959
26960                                 if test "x$with_selinux" != xcheck; then
26961   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26962 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26963 { { $as_echo "$as_me:$LINENO: error: --with-selinux given but unavailable
26964 See \`config.log' for more details." >&5
26965 $as_echo "$as_me: error: --with-selinux given but unavailable
26966 See \`config.log' for more details." >&2;}
26967    { (exit 1); exit 1; }; }; }
26968
26969 fi
26970
26971
26972 fi
26973
26974
26975 else
26976
26977                         if test "x$with_selinux" != xcheck; then
26978   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26979 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26980 { { $as_echo "$as_me:$LINENO: error: --with-selinux given but unavailable
26981 See \`config.log' for more details." >&5
26982 $as_echo "$as_me: error: --with-selinux given but unavailable
26983 See \`config.log' for more details." >&2;}
26984    { (exit 1); exit 1; }; }; }
26985
26986 fi
26987
26988
26989 fi
26990
26991
26992
26993 else
26994
26995                 { $as_echo "$as_me:$LINENO: checking for selinux support" >&5
26996 $as_echo_n "checking for selinux support... " >&6; }
26997                 { $as_echo "$as_me:$LINENO: result: no" >&5
26998 $as_echo "no" >&6; }
26999
27000 fi
27001
27002
27003
27004         { $as_echo "$as_me:$LINENO: checking for -Wframe-larger-than=<size> support" >&5
27005 $as_echo_n "checking for -Wframe-larger-than=<size> support... " >&6; }
27006
27007         saved_flags="$CFLAGS"
27008         CFLAGS="$CFLAGS -Wframe-larger-than=1024"
27009
27010         if test "$cross_compiling" = yes; then
27011   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27012 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27013 { { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling
27014 See \`config.log' for more details." >&5
27015 $as_echo "$as_me: error: cannot run test program while cross compiling
27016 See \`config.log' for more details." >&2;}
27017    { (exit 1); exit 1; }; }; }
27018 else
27019   cat >conftest.$ac_ext <<_ACEOF
27020 /* confdefs.h.  */
27021 _ACEOF
27022 cat confdefs.h >>conftest.$ac_ext
27023 cat >>conftest.$ac_ext <<_ACEOF
27024 /* end confdefs.h.  */
27025
27026 int
27027 main ()
27028 {
27029
27030   ;
27031   return 0;
27032 }
27033 _ACEOF
27034 rm -f conftest$ac_exeext
27035 if { (ac_try="$ac_link"
27036 case "(($ac_try" in
27037   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27038   *) ac_try_echo=$ac_try;;
27039 esac
27040 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27041 $as_echo "$ac_try_echo") >&5
27042   (eval "$ac_link") 2>&5
27043   ac_status=$?
27044   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27045   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27046   { (case "(($ac_try" in
27047   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27048   *) ac_try_echo=$ac_try;;
27049 esac
27050 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27051 $as_echo "$ac_try_echo") >&5
27052   (eval "$ac_try") 2>&5
27053   ac_status=$?
27054   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27055   (exit $ac_status); }; }; then
27056
27057                 FRAME_LARGER_THAN=-Wframe-larger-than=1024
27058                 { $as_echo "$as_me:$LINENO: result: yes" >&5
27059 $as_echo "yes" >&6; }
27060
27061 else
27062   $as_echo "$as_me: program exited with status $ac_status" >&5
27063 $as_echo "$as_me: failed program was:" >&5
27064 sed 's/^/| /' conftest.$ac_ext >&5
27065
27066 ( exit $ac_status )
27067
27068                 FRAME_LARGER_THAN=
27069                 { $as_echo "$as_me:$LINENO: result: no" >&5
27070 $as_echo "no" >&6; }
27071
27072 fi
27073 rm -rf conftest.dSYM
27074 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27075 fi
27076
27077
27078
27079         CFLAGS="$saved_flags"
27080
27081
27082
27083
27084         { $as_echo "$as_me:$LINENO: checking whether pthread stack includes guard" >&5
27085 $as_echo_n "checking whether pthread stack includes guard... " >&6; }
27086
27087         saved_CFLAGS="$CFLAGS"
27088         CFLAGS="-fstack-check"
27089         saved_LDFLAGS="$LDFLAGS"
27090         LDFLAGS="-lpthread"
27091
27092         if test "$cross_compiling" = yes; then
27093   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27094 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27095 { { $as_echo "$as_me:$LINENO: error: cannot run test program while cross compiling
27096 See \`config.log' for more details." >&5
27097 $as_echo "$as_me: error: cannot run test program while cross compiling
27098 See \`config.log' for more details." >&2;}
27099    { (exit 1); exit 1; }; }; }
27100 else
27101   cat >conftest.$ac_ext <<_ACEOF
27102 /* confdefs.h.  */
27103 _ACEOF
27104 cat confdefs.h >>conftest.$ac_ext
27105 cat >>conftest.$ac_ext <<_ACEOF
27106 /* end confdefs.h.  */
27107
27108                 #include <pthread.h>
27109                 #include <sys/resource.h>
27110                 #include <unistd.h>
27111                 #include <bits/local_lim.h>
27112
27113                 #define PAGESIZE (sysconf(_SC_PAGESIZE))
27114                 #define STACK_SIZE 8192
27115                 #define BUFSIZE 4096
27116
27117                 void * func(void *arg)
27118                 {
27119                         char buf[BUFSIZE];
27120                 }
27121
27122 int
27123 main ()
27124 {
27125
27126                 pthread_t tid;
27127                 pthread_attr_t attr;
27128                 struct rlimit l;
27129
27130                 l.rlim_cur = 0;
27131                 l.rlim_max = 0;
27132                 setrlimit(RLIMIT_CORE, &l);
27133                 pthread_attr_init(&attr);
27134                 pthread_attr_setstacksize(&attr, PTHREAD_STACK_MIN + STACK_SIZE);
27135                 pthread_attr_setguardsize(&attr, PAGESIZE);
27136                 pthread_create(&tid, &attr, func, NULL);
27137                 pthread_join(tid, NULL);
27138
27139   ;
27140   return 0;
27141 }
27142 _ACEOF
27143 rm -f conftest$ac_exeext
27144 if { (ac_try="$ac_link"
27145 case "(($ac_try" in
27146   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27147   *) ac_try_echo=$ac_try;;
27148 esac
27149 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27150 $as_echo "$ac_try_echo") >&5
27151   (eval "$ac_link") 2>&5
27152   ac_status=$?
27153   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27154   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27155   { (case "(($ac_try" in
27156   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27157   *) ac_try_echo=$ac_try;;
27158 esac
27159 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27160 $as_echo "$ac_try_echo") >&5
27161   (eval "$ac_try") 2>&5
27162   ac_status=$?
27163   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27164   (exit $ac_status); }; }; then
27165
27166                 { $as_echo "$as_me:$LINENO: result: no" >&5
27167 $as_echo "no" >&6; }
27168
27169 else
27170   $as_echo "$as_me: program exited with status $ac_status" >&5
27171 $as_echo "$as_me: failed program was:" >&5
27172 sed 's/^/| /' conftest.$ac_ext >&5
27173
27174 ( exit $ac_status )
27175
27176
27177 cat >>confdefs.h <<\_ACEOF
27178 #define NPTL_GUARD_WITHIN_STACK 1
27179 _ACEOF
27180
27181                 { $as_echo "$as_me:$LINENO: result: yes" >&5
27182 $as_echo "yes" >&6; }
27183
27184 fi
27185 rm -rf conftest.dSYM
27186 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27187 fi
27188
27189
27190         CFLAGS="$saved_CFLAGS"
27191         LDFLAGS="$saved_LDFLAGS"
27192
27193    ;;
27194                 srpm)                        ;;
27195                 *)
27196                 { $as_echo "$as_me:$LINENO: result: Error!" >&5
27197 $as_echo "Error!" >&6; }
27198                 { { $as_echo "$as_me:$LINENO: error: Bad value \"$ZFS_CONFIG\" for --with-config,
27199                               user kernel|user|all|srpm" >&5
27200 $as_echo "$as_me: error: Bad value \"$ZFS_CONFIG\" for --with-config,
27201                               user kernel|user|all|srpm" >&2;}
27202    { (exit 1); exit 1; }; } ;;
27203         esac
27204
27205          if test "$ZFS_CONFIG" = user -o "$ZFS_CONFIG" = all; then
27206   CONFIG_USER_TRUE=
27207   CONFIG_USER_FALSE='#'
27208 else
27209   CONFIG_USER_TRUE='#'
27210   CONFIG_USER_FALSE=
27211 fi
27212
27213          if test "$ZFS_CONFIG" = kernel -o "$ZFS_CONFIG" = all &&
27214                        test "x$enable_linux_builtin" != xyes ; then
27215   CONFIG_KERNEL_TRUE=
27216   CONFIG_KERNEL_FALSE='#'
27217 else
27218   CONFIG_KERNEL_TRUE='#'
27219   CONFIG_KERNEL_FALSE=
27220 fi
27221
27222
27223
27224         { $as_echo "$as_me:$LINENO: checking whether debugging is enabled" >&5
27225 $as_echo_n "checking whether debugging is enabled... " >&6; }
27226         # Check whether --enable-debug was given.
27227 if test "${enable_debug+set}" = set; then
27228   enableval=$enable_debug;
27229 else
27230   enable_debug=no
27231 fi
27232
27233
27234         if test "x$enable_debug" = xyes; then
27235
27236                 KERNELCPPFLAGS="${KERNELCPPFLAGS} -DDEBUG -Werror"
27237                 HOSTCFLAGS="${HOSTCFLAGS} -DDEBUG -Werror"
27238                 DEBUG_CFLAGS="-DDEBUG -Werror"
27239                 DEBUG_STACKFLAGS="-fstack-check"
27240                 DEBUG_ZFS="_with_debug"
27241
27242 cat >>confdefs.h <<\_ACEOF
27243 #define ZFS_DEBUG 1
27244 _ACEOF
27245
27246
27247 else
27248
27249                 KERNELCPPFLAGS="${KERNELCPPFLAGS} -DNDEBUG "
27250                 HOSTCFLAGS="${HOSTCFLAGS} -DNDEBUG "
27251                 DEBUG_CFLAGS="-DNDEBUG"
27252                 DEBUG_STACKFLAGS=""
27253                 DEBUG_ZFS="_without_debug"
27254
27255 fi
27256
27257
27258
27259
27260
27261         { $as_echo "$as_me:$LINENO: result: $enable_debug" >&5
27262 $as_echo "$enable_debug" >&6; }
27263
27264
27265         # Check whether --enable-debug-dmu-tx was given.
27266 if test "${enable_debug_dmu_tx+set}" = set; then
27267   enableval=$enable_debug_dmu_tx;
27268 else
27269   enable_debug_dmu_tx=no
27270 fi
27271
27272
27273         if test "x$enable_debug_dmu_tx" = xyes; then
27274
27275                 KERNELCPPFLAGS="${KERNELCPPFLAGS} -DDEBUG_DMU_TX"
27276                 DEBUG_DMU_TX="_with_debug_dmu_tx"
27277
27278 cat >>confdefs.h <<\_ACEOF
27279 #define DEBUG_DMU_TX 1
27280 _ACEOF
27281
27282
27283 else
27284
27285                 DEBUG_DMU_TX="_without_debug_dmu_tx"
27286
27287 fi
27288
27289
27290
27291         { $as_echo "$as_me:$LINENO: checking whether dmu tx validation is enabled" >&5
27292 $as_echo_n "checking whether dmu tx validation is enabled... " >&6; }
27293         { $as_echo "$as_me:$LINENO: result: $enable_debug_dmu_tx" >&5
27294 $as_echo "$enable_debug_dmu_tx" >&6; }
27295
27296
27297 ac_config_files="$ac_config_files Makefile dracut/Makefile dracut/90zfs/Makefile udev/Makefile udev/rules.d/Makefile etc/Makefile etc/init.d/Makefile etc/zfs/Makefile man/Makefile man/man5/Makefile man/man8/Makefile lib/Makefile lib/libspl/Makefile lib/libspl/asm-generic/Makefile lib/libspl/asm-i386/Makefile lib/libspl/asm-x86_64/Makefile lib/libspl/include/Makefile lib/libspl/include/ia32/Makefile lib/libspl/include/ia32/sys/Makefile lib/libspl/include/rpc/Makefile lib/libspl/include/sys/Makefile lib/libspl/include/sys/sysevent/Makefile lib/libspl/include/sys/dktp/Makefile lib/libspl/include/util/Makefile lib/libavl/Makefile lib/libefi/Makefile lib/libnvpair/Makefile lib/libunicode/Makefile lib/libuutil/Makefile lib/libzpool/Makefile lib/libzfs/Makefile lib/libshare/Makefile cmd/Makefile cmd/zdb/Makefile cmd/zfs/Makefile cmd/zinject/Makefile cmd/zpool/Makefile cmd/ztest/Makefile cmd/zpios/Makefile cmd/mount_zfs/Makefile cmd/zpool_layout/Makefile cmd/zvol_id/Makefile cmd/zpool_id/Makefile cmd/vdev_id/Makefile module/Makefile module/avl/Makefile module/nvpair/Makefile module/unicode/Makefile module/zcommon/Makefile module/zfs/Makefile module/zpios/Makefile include/Makefile include/linux/Makefile include/sys/Makefile include/sys/fs/Makefile include/sys/fm/Makefile include/sys/fm/fs/Makefile scripts/Makefile scripts/zpios-profile/Makefile scripts/zpios-test/Makefile scripts/zpool-config/Makefile scripts/zpool-layout/Makefile scripts/common.sh zfs.spec zfs-modules.spec PKGBUILD-zfs PKGBUILD-zfs-modules zfs-script-config.sh zfs.release"
27298
27299
27300 cat >confcache <<\_ACEOF
27301 # This file is a shell script that caches the results of configure
27302 # tests run on this system so they can be shared between configure
27303 # scripts and configure runs, see configure's option --config-cache.
27304 # It is not useful on other systems.  If it contains results you don't
27305 # want to keep, you may remove or edit it.
27306 #
27307 # config.status only pays attention to the cache file if you give it
27308 # the --recheck option to rerun configure.
27309 #
27310 # `ac_cv_env_foo' variables (set or unset) will be overridden when
27311 # loading this file, other *unset* `ac_cv_foo' will be assigned the
27312 # following values.
27313
27314 _ACEOF
27315
27316 # The following way of writing the cache mishandles newlines in values,
27317 # but we know of no workaround that is simple, portable, and efficient.
27318 # So, we kill variables containing newlines.
27319 # Ultrix sh set writes to stderr and can't be redirected directly,
27320 # and sets the high bit in the cache file unless we assign to the vars.
27321 (
27322   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
27323     eval ac_val=\$$ac_var
27324     case $ac_val in #(
27325     *${as_nl}*)
27326       case $ac_var in #(
27327       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
27328 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
27329       esac
27330       case $ac_var in #(
27331       _ | IFS | as_nl) ;; #(
27332       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
27333       *) $as_unset $ac_var ;;
27334       esac ;;
27335     esac
27336   done
27337
27338   (set) 2>&1 |
27339     case $as_nl`(ac_space=' '; set) 2>&1` in #(
27340     *${as_nl}ac_space=\ *)
27341       # `set' does not quote correctly, so add quotes (double-quote
27342       # substitution turns \\\\ into \\, and sed turns \\ into \).
27343       sed -n \
27344         "s/'/'\\\\''/g;
27345           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
27346       ;; #(
27347     *)
27348       # `set' quotes correctly as required by POSIX, so do not add quotes.
27349       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
27350       ;;
27351     esac |
27352     sort
27353 ) |
27354   sed '
27355      /^ac_cv_env_/b end
27356      t clear
27357      :clear
27358      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
27359      t end
27360      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
27361      :end' >>confcache
27362 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
27363   if test -w "$cache_file"; then
27364     test "x$cache_file" != "x/dev/null" &&
27365       { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
27366 $as_echo "$as_me: updating cache $cache_file" >&6;}
27367     cat confcache >$cache_file
27368   else
27369     { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
27370 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
27371   fi
27372 fi
27373 rm -f confcache
27374
27375 test "x$prefix" = xNONE && prefix=$ac_default_prefix
27376 # Let make expand exec_prefix.
27377 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
27378
27379 DEFS=-DHAVE_CONFIG_H
27380
27381 ac_libobjs=
27382 ac_ltlibobjs=
27383 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
27384   # 1. Remove the extension, and $U if already installed.
27385   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
27386   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
27387   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
27388   #    will be set to the directory where LIBOBJS objects are built.
27389   ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
27390   ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
27391 done
27392 LIBOBJS=$ac_libobjs
27393
27394 LTLIBOBJS=$ac_ltlibobjs
27395
27396
27397 if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
27398   { { $as_echo "$as_me:$LINENO: error: conditional \"MAINTAINER_MODE\" was never defined.
27399 Usually this means the macro was only invoked conditionally." >&5
27400 $as_echo "$as_me: error: conditional \"MAINTAINER_MODE\" was never defined.
27401 Usually this means the macro was only invoked conditionally." >&2;}
27402    { (exit 1); exit 1; }; }
27403 fi
27404  if test -n "$EXEEXT"; then
27405   am__EXEEXT_TRUE=
27406   am__EXEEXT_FALSE='#'
27407 else
27408   am__EXEEXT_TRUE='#'
27409   am__EXEEXT_FALSE=
27410 fi
27411
27412 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
27413   { { $as_echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined.
27414 Usually this means the macro was only invoked conditionally." >&5
27415 $as_echo "$as_me: error: conditional \"AMDEP\" was never defined.
27416 Usually this means the macro was only invoked conditionally." >&2;}
27417    { (exit 1); exit 1; }; }
27418 fi
27419 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
27420   { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
27421 Usually this means the macro was only invoked conditionally." >&5
27422 $as_echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
27423 Usually this means the macro was only invoked conditionally." >&2;}
27424    { (exit 1); exit 1; }; }
27425 fi
27426 if test -z "${am__fastdepCCAS_TRUE}" && test -z "${am__fastdepCCAS_FALSE}"; then
27427   { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCCAS\" was never defined.
27428 Usually this means the macro was only invoked conditionally." >&5
27429 $as_echo "$as_me: error: conditional \"am__fastdepCCAS\" was never defined.
27430 Usually this means the macro was only invoked conditionally." >&2;}
27431    { (exit 1); exit 1; }; }
27432 fi
27433 if test -z "${CONFIG_USER_TRUE}" && test -z "${CONFIG_USER_FALSE}"; then
27434   { { $as_echo "$as_me:$LINENO: error: conditional \"CONFIG_USER\" was never defined.
27435 Usually this means the macro was only invoked conditionally." >&5
27436 $as_echo "$as_me: error: conditional \"CONFIG_USER\" was never defined.
27437 Usually this means the macro was only invoked conditionally." >&2;}
27438    { (exit 1); exit 1; }; }
27439 fi
27440 if test -z "${CONFIG_KERNEL_TRUE}" && test -z "${CONFIG_KERNEL_FALSE}"; then
27441   { { $as_echo "$as_me:$LINENO: error: conditional \"CONFIG_KERNEL\" was never defined.
27442 Usually this means the macro was only invoked conditionally." >&5
27443 $as_echo "$as_me: error: conditional \"CONFIG_KERNEL\" was never defined.
27444 Usually this means the macro was only invoked conditionally." >&2;}
27445    { (exit 1); exit 1; }; }
27446 fi
27447
27448 : ${CONFIG_STATUS=./config.status}
27449 ac_write_fail=0
27450 ac_clean_files_save=$ac_clean_files
27451 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
27452 { $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
27453 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
27454 cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27455 #! $SHELL
27456 # Generated by $as_me.
27457 # Run this file to recreate the current configuration.
27458 # Compiler output produced by configure, useful for debugging
27459 # configure, is in config.log if it exists.
27460
27461 debug=false
27462 ac_cs_recheck=false
27463 ac_cs_silent=false
27464 SHELL=\${CONFIG_SHELL-$SHELL}
27465 _ACEOF
27466
27467 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27468 ## --------------------- ##
27469 ## M4sh Initialization.  ##
27470 ## --------------------- ##
27471
27472 # Be more Bourne compatible
27473 DUALCASE=1; export DUALCASE # for MKS sh
27474 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
27475   emulate sh
27476   NULLCMD=:
27477   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
27478   # is contrary to our usage.  Disable this feature.
27479   alias -g '${1+"$@"}'='"$@"'
27480   setopt NO_GLOB_SUBST
27481 else
27482   case `(set -o) 2>/dev/null` in
27483   *posix*) set -o posix ;;
27484 esac
27485
27486 fi
27487
27488
27489
27490
27491 # PATH needs CR
27492 # Avoid depending upon Character Ranges.
27493 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
27494 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
27495 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
27496 as_cr_digits='0123456789'
27497 as_cr_alnum=$as_cr_Letters$as_cr_digits
27498
27499 as_nl='
27500 '
27501 export as_nl
27502 # Printing a long string crashes Solaris 7 /usr/bin/printf.
27503 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
27504 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
27505 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
27506 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
27507   as_echo='printf %s\n'
27508   as_echo_n='printf %s'
27509 else
27510   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
27511     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
27512     as_echo_n='/usr/ucb/echo -n'
27513   else
27514     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
27515     as_echo_n_body='eval
27516       arg=$1;
27517       case $arg in
27518       *"$as_nl"*)
27519         expr "X$arg" : "X\\(.*\\)$as_nl";
27520         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
27521       esac;
27522       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
27523     '
27524     export as_echo_n_body
27525     as_echo_n='sh -c $as_echo_n_body as_echo'
27526   fi
27527   export as_echo_body
27528   as_echo='sh -c $as_echo_body as_echo'
27529 fi
27530
27531 # The user is always right.
27532 if test "${PATH_SEPARATOR+set}" != set; then
27533   PATH_SEPARATOR=:
27534   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
27535     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
27536       PATH_SEPARATOR=';'
27537   }
27538 fi
27539
27540 # Support unset when possible.
27541 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
27542   as_unset=unset
27543 else
27544   as_unset=false
27545 fi
27546
27547
27548 # IFS
27549 # We need space, tab and new line, in precisely that order.  Quoting is
27550 # there to prevent editors from complaining about space-tab.
27551 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
27552 # splitting by setting IFS to empty value.)
27553 IFS=" ""        $as_nl"
27554
27555 # Find who we are.  Look in the path if we contain no directory separator.
27556 case $0 in
27557   *[\\/]* ) as_myself=$0 ;;
27558   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27559 for as_dir in $PATH
27560 do
27561   IFS=$as_save_IFS
27562   test -z "$as_dir" && as_dir=.
27563   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
27564 done
27565 IFS=$as_save_IFS
27566
27567      ;;
27568 esac
27569 # We did not find ourselves, most probably we were run as `sh COMMAND'
27570 # in which case we are not to be found in the path.
27571 if test "x$as_myself" = x; then
27572   as_myself=$0
27573 fi
27574 if test ! -f "$as_myself"; then
27575   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
27576   { (exit 1); exit 1; }
27577 fi
27578
27579 # Work around bugs in pre-3.0 UWIN ksh.
27580 for as_var in ENV MAIL MAILPATH
27581 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
27582 done
27583 PS1='$ '
27584 PS2='> '
27585 PS4='+ '
27586
27587 # NLS nuisances.
27588 LC_ALL=C
27589 export LC_ALL
27590 LANGUAGE=C
27591 export LANGUAGE
27592
27593 # Required to use basename.
27594 if expr a : '\(a\)' >/dev/null 2>&1 &&
27595    test "X`expr 00001 : '.*\(...\)'`" = X001; then
27596   as_expr=expr
27597 else
27598   as_expr=false
27599 fi
27600
27601 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
27602   as_basename=basename
27603 else
27604   as_basename=false
27605 fi
27606
27607
27608 # Name of the executable.
27609 as_me=`$as_basename -- "$0" ||
27610 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
27611          X"$0" : 'X\(//\)$' \| \
27612          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
27613 $as_echo X/"$0" |
27614     sed '/^.*\/\([^/][^/]*\)\/*$/{
27615             s//\1/
27616             q
27617           }
27618           /^X\/\(\/\/\)$/{
27619             s//\1/
27620             q
27621           }
27622           /^X\/\(\/\).*/{
27623             s//\1/
27624             q
27625           }
27626           s/.*/./; q'`
27627
27628 # CDPATH.
27629 $as_unset CDPATH
27630
27631
27632
27633   as_lineno_1=$LINENO
27634   as_lineno_2=$LINENO
27635   test "x$as_lineno_1" != "x$as_lineno_2" &&
27636   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
27637
27638   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
27639   # uniformly replaced by the line number.  The first 'sed' inserts a
27640   # line-number line after each line using $LINENO; the second 'sed'
27641   # does the real work.  The second script uses 'N' to pair each
27642   # line-number line with the line containing $LINENO, and appends
27643   # trailing '-' during substitution so that $LINENO is not a special
27644   # case at line end.
27645   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
27646   # scripts with optimization help from Paolo Bonzini.  Blame Lee
27647   # E. McMahon (1931-1989) for sed's syntax.  :-)
27648   sed -n '
27649     p
27650     /[$]LINENO/=
27651   ' <$as_myself |
27652     sed '
27653       s/[$]LINENO.*/&-/
27654       t lineno
27655       b
27656       :lineno
27657       N
27658       :loop
27659       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
27660       t loop
27661       s/-\n.*//
27662     ' >$as_me.lineno &&
27663   chmod +x "$as_me.lineno" ||
27664     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
27665    { (exit 1); exit 1; }; }
27666
27667   # Don't try to exec as it changes $[0], causing all sort of problems
27668   # (the dirname of $[0] is not the place where we might find the
27669   # original and so on.  Autoconf is especially sensitive to this).
27670   . "./$as_me.lineno"
27671   # Exit status is that of the last command.
27672   exit
27673 }
27674
27675
27676 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
27677   as_dirname=dirname
27678 else
27679   as_dirname=false
27680 fi
27681
27682 ECHO_C= ECHO_N= ECHO_T=
27683 case `echo -n x` in
27684 -n*)
27685   case `echo 'x\c'` in
27686   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
27687   *)   ECHO_C='\c';;
27688   esac;;
27689 *)
27690   ECHO_N='-n';;
27691 esac
27692 if expr a : '\(a\)' >/dev/null 2>&1 &&
27693    test "X`expr 00001 : '.*\(...\)'`" = X001; then
27694   as_expr=expr
27695 else
27696   as_expr=false
27697 fi
27698
27699 rm -f conf$$ conf$$.exe conf$$.file
27700 if test -d conf$$.dir; then
27701   rm -f conf$$.dir/conf$$.file
27702 else
27703   rm -f conf$$.dir
27704   mkdir conf$$.dir 2>/dev/null
27705 fi
27706 if (echo >conf$$.file) 2>/dev/null; then
27707   if ln -s conf$$.file conf$$ 2>/dev/null; then
27708     as_ln_s='ln -s'
27709     # ... but there are two gotchas:
27710     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
27711     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
27712     # In both cases, we have to default to `cp -p'.
27713     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
27714       as_ln_s='cp -p'
27715   elif ln conf$$.file conf$$ 2>/dev/null; then
27716     as_ln_s=ln
27717   else
27718     as_ln_s='cp -p'
27719   fi
27720 else
27721   as_ln_s='cp -p'
27722 fi
27723 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
27724 rmdir conf$$.dir 2>/dev/null
27725
27726 if mkdir -p . 2>/dev/null; then
27727   as_mkdir_p=:
27728 else
27729   test -d ./-p && rmdir ./-p
27730   as_mkdir_p=false
27731 fi
27732
27733 if test -x / >/dev/null 2>&1; then
27734   as_test_x='test -x'
27735 else
27736   if ls -dL / >/dev/null 2>&1; then
27737     as_ls_L_option=L
27738   else
27739     as_ls_L_option=
27740   fi
27741   as_test_x='
27742     eval sh -c '\''
27743       if test -d "$1"; then
27744         test -d "$1/.";
27745       else
27746         case $1 in
27747         -*)set "./$1";;
27748         esac;
27749         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
27750         ???[sx]*):;;*)false;;esac;fi
27751     '\'' sh
27752   '
27753 fi
27754 as_executable_p=$as_test_x
27755
27756 # Sed expression to map a string onto a valid CPP name.
27757 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
27758
27759 # Sed expression to map a string onto a valid variable name.
27760 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
27761
27762
27763 exec 6>&1
27764
27765 # Save the log message, to keep $[0] and so on meaningful, and to
27766 # report actual input values of CONFIG_FILES etc. instead of their
27767 # values after options handling.
27768 ac_log="
27769 This file was extended by $as_me, which was
27770 generated by GNU Autoconf 2.63.  Invocation command line was
27771
27772   CONFIG_FILES    = $CONFIG_FILES
27773   CONFIG_HEADERS  = $CONFIG_HEADERS
27774   CONFIG_LINKS    = $CONFIG_LINKS
27775   CONFIG_COMMANDS = $CONFIG_COMMANDS
27776   $ $0 $@
27777
27778 on `(hostname || uname -n) 2>/dev/null | sed 1q`
27779 "
27780
27781 _ACEOF
27782
27783 case $ac_config_files in *"
27784 "*) set x $ac_config_files; shift; ac_config_files=$*;;
27785 esac
27786
27787 case $ac_config_headers in *"
27788 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
27789 esac
27790
27791
27792 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27793 # Files that config.status was made for.
27794 config_files="$ac_config_files"
27795 config_headers="$ac_config_headers"
27796 config_commands="$ac_config_commands"
27797
27798 _ACEOF
27799
27800 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27801 ac_cs_usage="\
27802 \`$as_me' instantiates files from templates according to the
27803 current configuration.
27804
27805 Usage: $0 [OPTION]... [FILE]...
27806
27807   -h, --help       print this help, then exit
27808   -V, --version    print version number and configuration settings, then exit
27809   -q, --quiet, --silent
27810                    do not print progress messages
27811   -d, --debug      don't remove temporary files
27812       --recheck    update $as_me by reconfiguring in the same conditions
27813       --file=FILE[:TEMPLATE]
27814                    instantiate the configuration file FILE
27815       --header=FILE[:TEMPLATE]
27816                    instantiate the configuration header FILE
27817
27818 Configuration files:
27819 $config_files
27820
27821 Configuration headers:
27822 $config_headers
27823
27824 Configuration commands:
27825 $config_commands
27826
27827 Report bugs to <bug-autoconf@gnu.org>."
27828
27829 _ACEOF
27830 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27831 ac_cs_version="\\
27832 config.status
27833 configured by $0, generated by GNU Autoconf 2.63,
27834   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
27835
27836 Copyright (C) 2008 Free Software Foundation, Inc.
27837 This config.status script is free software; the Free Software Foundation
27838 gives unlimited permission to copy, distribute and modify it."
27839
27840 ac_pwd='$ac_pwd'
27841 srcdir='$srcdir'
27842 INSTALL='$INSTALL'
27843 MKDIR_P='$MKDIR_P'
27844 AWK='$AWK'
27845 test -n "\$AWK" || AWK=awk
27846 _ACEOF
27847
27848 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27849 # The default lists apply if the user does not specify any file.
27850 ac_need_defaults=:
27851 while test $# != 0
27852 do
27853   case $1 in
27854   --*=*)
27855     ac_option=`expr "X$1" : 'X\([^=]*\)='`
27856     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
27857     ac_shift=:
27858     ;;
27859   *)
27860     ac_option=$1
27861     ac_optarg=$2
27862     ac_shift=shift
27863     ;;
27864   esac
27865
27866   case $ac_option in
27867   # Handling of the options.
27868   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
27869     ac_cs_recheck=: ;;
27870   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
27871     $as_echo "$ac_cs_version"; exit ;;
27872   --debug | --debu | --deb | --de | --d | -d )
27873     debug=: ;;
27874   --file | --fil | --fi | --f )
27875     $ac_shift
27876     case $ac_optarg in
27877     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
27878     esac
27879     CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
27880     ac_need_defaults=false;;
27881   --header | --heade | --head | --hea )
27882     $ac_shift
27883     case $ac_optarg in
27884     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
27885     esac
27886     CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
27887     ac_need_defaults=false;;
27888   --he | --h)
27889     # Conflict between --help and --header
27890     { $as_echo "$as_me: error: ambiguous option: $1
27891 Try \`$0 --help' for more information." >&2
27892    { (exit 1); exit 1; }; };;
27893   --help | --hel | -h )
27894     $as_echo "$ac_cs_usage"; exit ;;
27895   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
27896   | -silent | --silent | --silen | --sile | --sil | --si | --s)
27897     ac_cs_silent=: ;;
27898
27899   # This is an error.
27900   -*) { $as_echo "$as_me: error: unrecognized option: $1
27901 Try \`$0 --help' for more information." >&2
27902    { (exit 1); exit 1; }; } ;;
27903
27904   *) ac_config_targets="$ac_config_targets $1"
27905      ac_need_defaults=false ;;
27906
27907   esac
27908   shift
27909 done
27910
27911 ac_configure_extra_args=
27912
27913 if $ac_cs_silent; then
27914   exec 6>/dev/null
27915   ac_configure_extra_args="$ac_configure_extra_args --silent"
27916 fi
27917
27918 _ACEOF
27919 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27920 if \$ac_cs_recheck; then
27921   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
27922   shift
27923   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
27924   CONFIG_SHELL='$SHELL'
27925   export CONFIG_SHELL
27926   exec "\$@"
27927 fi
27928
27929 _ACEOF
27930 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
27931 exec 5>>config.log
27932 {
27933   echo
27934   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
27935 ## Running $as_me. ##
27936 _ASBOX
27937   $as_echo "$ac_log"
27938 } >&5
27939
27940 _ACEOF
27941 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
27942 #
27943 # INIT-COMMANDS
27944 #
27945 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
27946
27947
27948 # The HP-UX ksh and POSIX shell print the target directory to stdout
27949 # if CDPATH is set.
27950 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
27951
27952 sed_quote_subst='$sed_quote_subst'
27953 double_quote_subst='$double_quote_subst'
27954 delay_variable_subst='$delay_variable_subst'
27955 macro_version='`$ECHO "X$macro_version" | $Xsed -e "$delay_single_quote_subst"`'
27956 macro_revision='`$ECHO "X$macro_revision" | $Xsed -e "$delay_single_quote_subst"`'
27957 enable_shared='`$ECHO "X$enable_shared" | $Xsed -e "$delay_single_quote_subst"`'
27958 enable_static='`$ECHO "X$enable_static" | $Xsed -e "$delay_single_quote_subst"`'
27959 pic_mode='`$ECHO "X$pic_mode" | $Xsed -e "$delay_single_quote_subst"`'
27960 enable_fast_install='`$ECHO "X$enable_fast_install" | $Xsed -e "$delay_single_quote_subst"`'
27961 host_alias='`$ECHO "X$host_alias" | $Xsed -e "$delay_single_quote_subst"`'
27962 host='`$ECHO "X$host" | $Xsed -e "$delay_single_quote_subst"`'
27963 host_os='`$ECHO "X$host_os" | $Xsed -e "$delay_single_quote_subst"`'
27964 build_alias='`$ECHO "X$build_alias" | $Xsed -e "$delay_single_quote_subst"`'
27965 build='`$ECHO "X$build" | $Xsed -e "$delay_single_quote_subst"`'
27966 build_os='`$ECHO "X$build_os" | $Xsed -e "$delay_single_quote_subst"`'
27967 SED='`$ECHO "X$SED" | $Xsed -e "$delay_single_quote_subst"`'
27968 Xsed='`$ECHO "X$Xsed" | $Xsed -e "$delay_single_quote_subst"`'
27969 GREP='`$ECHO "X$GREP" | $Xsed -e "$delay_single_quote_subst"`'
27970 EGREP='`$ECHO "X$EGREP" | $Xsed -e "$delay_single_quote_subst"`'
27971 FGREP='`$ECHO "X$FGREP" | $Xsed -e "$delay_single_quote_subst"`'
27972 LD='`$ECHO "X$LD" | $Xsed -e "$delay_single_quote_subst"`'
27973 NM='`$ECHO "X$NM" | $Xsed -e "$delay_single_quote_subst"`'
27974 LN_S='`$ECHO "X$LN_S" | $Xsed -e "$delay_single_quote_subst"`'
27975 max_cmd_len='`$ECHO "X$max_cmd_len" | $Xsed -e "$delay_single_quote_subst"`'
27976 ac_objext='`$ECHO "X$ac_objext" | $Xsed -e "$delay_single_quote_subst"`'
27977 exeext='`$ECHO "X$exeext" | $Xsed -e "$delay_single_quote_subst"`'
27978 lt_unset='`$ECHO "X$lt_unset" | $Xsed -e "$delay_single_quote_subst"`'
27979 lt_SP2NL='`$ECHO "X$lt_SP2NL" | $Xsed -e "$delay_single_quote_subst"`'
27980 lt_NL2SP='`$ECHO "X$lt_NL2SP" | $Xsed -e "$delay_single_quote_subst"`'
27981 reload_flag='`$ECHO "X$reload_flag" | $Xsed -e "$delay_single_quote_subst"`'
27982 reload_cmds='`$ECHO "X$reload_cmds" | $Xsed -e "$delay_single_quote_subst"`'
27983 OBJDUMP='`$ECHO "X$OBJDUMP" | $Xsed -e "$delay_single_quote_subst"`'
27984 deplibs_check_method='`$ECHO "X$deplibs_check_method" | $Xsed -e "$delay_single_quote_subst"`'
27985 file_magic_cmd='`$ECHO "X$file_magic_cmd" | $Xsed -e "$delay_single_quote_subst"`'
27986 AR='`$ECHO "X$AR" | $Xsed -e "$delay_single_quote_subst"`'
27987 AR_FLAGS='`$ECHO "X$AR_FLAGS" | $Xsed -e "$delay_single_quote_subst"`'
27988 STRIP='`$ECHO "X$STRIP" | $Xsed -e "$delay_single_quote_subst"`'
27989 RANLIB='`$ECHO "X$RANLIB" | $Xsed -e "$delay_single_quote_subst"`'
27990 old_postinstall_cmds='`$ECHO "X$old_postinstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
27991 old_postuninstall_cmds='`$ECHO "X$old_postuninstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
27992 old_archive_cmds='`$ECHO "X$old_archive_cmds" | $Xsed -e "$delay_single_quote_subst"`'
27993 CC='`$ECHO "X$CC" | $Xsed -e "$delay_single_quote_subst"`'
27994 CFLAGS='`$ECHO "X$CFLAGS" | $Xsed -e "$delay_single_quote_subst"`'
27995 compiler='`$ECHO "X$compiler" | $Xsed -e "$delay_single_quote_subst"`'
27996 GCC='`$ECHO "X$GCC" | $Xsed -e "$delay_single_quote_subst"`'
27997 lt_cv_sys_global_symbol_pipe='`$ECHO "X$lt_cv_sys_global_symbol_pipe" | $Xsed -e "$delay_single_quote_subst"`'
27998 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "X$lt_cv_sys_global_symbol_to_cdecl" | $Xsed -e "$delay_single_quote_subst"`'
27999 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "X$lt_cv_sys_global_symbol_to_c_name_address" | $Xsed -e "$delay_single_quote_subst"`'
28000 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "X$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $Xsed -e "$delay_single_quote_subst"`'
28001 objdir='`$ECHO "X$objdir" | $Xsed -e "$delay_single_quote_subst"`'
28002 SHELL='`$ECHO "X$SHELL" | $Xsed -e "$delay_single_quote_subst"`'
28003 ECHO='`$ECHO "X$ECHO" | $Xsed -e "$delay_single_quote_subst"`'
28004 MAGIC_CMD='`$ECHO "X$MAGIC_CMD" | $Xsed -e "$delay_single_quote_subst"`'
28005 lt_prog_compiler_no_builtin_flag='`$ECHO "X$lt_prog_compiler_no_builtin_flag" | $Xsed -e "$delay_single_quote_subst"`'
28006 lt_prog_compiler_wl='`$ECHO "X$lt_prog_compiler_wl" | $Xsed -e "$delay_single_quote_subst"`'
28007 lt_prog_compiler_pic='`$ECHO "X$lt_prog_compiler_pic" | $Xsed -e "$delay_single_quote_subst"`'
28008 lt_prog_compiler_static='`$ECHO "X$lt_prog_compiler_static" | $Xsed -e "$delay_single_quote_subst"`'
28009 lt_cv_prog_compiler_c_o='`$ECHO "X$lt_cv_prog_compiler_c_o" | $Xsed -e "$delay_single_quote_subst"`'
28010 need_locks='`$ECHO "X$need_locks" | $Xsed -e "$delay_single_quote_subst"`'
28011 DSYMUTIL='`$ECHO "X$DSYMUTIL" | $Xsed -e "$delay_single_quote_subst"`'
28012 NMEDIT='`$ECHO "X$NMEDIT" | $Xsed -e "$delay_single_quote_subst"`'
28013 LIPO='`$ECHO "X$LIPO" | $Xsed -e "$delay_single_quote_subst"`'
28014 OTOOL='`$ECHO "X$OTOOL" | $Xsed -e "$delay_single_quote_subst"`'
28015 OTOOL64='`$ECHO "X$OTOOL64" | $Xsed -e "$delay_single_quote_subst"`'
28016 libext='`$ECHO "X$libext" | $Xsed -e "$delay_single_quote_subst"`'
28017 shrext_cmds='`$ECHO "X$shrext_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28018 extract_expsyms_cmds='`$ECHO "X$extract_expsyms_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28019 archive_cmds_need_lc='`$ECHO "X$archive_cmds_need_lc" | $Xsed -e "$delay_single_quote_subst"`'
28020 enable_shared_with_static_runtimes='`$ECHO "X$enable_shared_with_static_runtimes" | $Xsed -e "$delay_single_quote_subst"`'
28021 export_dynamic_flag_spec='`$ECHO "X$export_dynamic_flag_spec" | $Xsed -e "$delay_single_quote_subst"`'
28022 whole_archive_flag_spec='`$ECHO "X$whole_archive_flag_spec" | $Xsed -e "$delay_single_quote_subst"`'
28023 compiler_needs_object='`$ECHO "X$compiler_needs_object" | $Xsed -e "$delay_single_quote_subst"`'
28024 old_archive_from_new_cmds='`$ECHO "X$old_archive_from_new_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28025 old_archive_from_expsyms_cmds='`$ECHO "X$old_archive_from_expsyms_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28026 archive_cmds='`$ECHO "X$archive_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28027 archive_expsym_cmds='`$ECHO "X$archive_expsym_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28028 module_cmds='`$ECHO "X$module_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28029 module_expsym_cmds='`$ECHO "X$module_expsym_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28030 with_gnu_ld='`$ECHO "X$with_gnu_ld" | $Xsed -e "$delay_single_quote_subst"`'
28031 allow_undefined_flag='`$ECHO "X$allow_undefined_flag" | $Xsed -e "$delay_single_quote_subst"`'
28032 no_undefined_flag='`$ECHO "X$no_undefined_flag" | $Xsed -e "$delay_single_quote_subst"`'
28033 hardcode_libdir_flag_spec='`$ECHO "X$hardcode_libdir_flag_spec" | $Xsed -e "$delay_single_quote_subst"`'
28034 hardcode_libdir_flag_spec_ld='`$ECHO "X$hardcode_libdir_flag_spec_ld" | $Xsed -e "$delay_single_quote_subst"`'
28035 hardcode_libdir_separator='`$ECHO "X$hardcode_libdir_separator" | $Xsed -e "$delay_single_quote_subst"`'
28036 hardcode_direct='`$ECHO "X$hardcode_direct" | $Xsed -e "$delay_single_quote_subst"`'
28037 hardcode_direct_absolute='`$ECHO "X$hardcode_direct_absolute" | $Xsed -e "$delay_single_quote_subst"`'
28038 hardcode_minus_L='`$ECHO "X$hardcode_minus_L" | $Xsed -e "$delay_single_quote_subst"`'
28039 hardcode_shlibpath_var='`$ECHO "X$hardcode_shlibpath_var" | $Xsed -e "$delay_single_quote_subst"`'
28040 hardcode_automatic='`$ECHO "X$hardcode_automatic" | $Xsed -e "$delay_single_quote_subst"`'
28041 inherit_rpath='`$ECHO "X$inherit_rpath" | $Xsed -e "$delay_single_quote_subst"`'
28042 link_all_deplibs='`$ECHO "X$link_all_deplibs" | $Xsed -e "$delay_single_quote_subst"`'
28043 fix_srcfile_path='`$ECHO "X$fix_srcfile_path" | $Xsed -e "$delay_single_quote_subst"`'
28044 always_export_symbols='`$ECHO "X$always_export_symbols" | $Xsed -e "$delay_single_quote_subst"`'
28045 export_symbols_cmds='`$ECHO "X$export_symbols_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28046 exclude_expsyms='`$ECHO "X$exclude_expsyms" | $Xsed -e "$delay_single_quote_subst"`'
28047 include_expsyms='`$ECHO "X$include_expsyms" | $Xsed -e "$delay_single_quote_subst"`'
28048 prelink_cmds='`$ECHO "X$prelink_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28049 file_list_spec='`$ECHO "X$file_list_spec" | $Xsed -e "$delay_single_quote_subst"`'
28050 variables_saved_for_relink='`$ECHO "X$variables_saved_for_relink" | $Xsed -e "$delay_single_quote_subst"`'
28051 need_lib_prefix='`$ECHO "X$need_lib_prefix" | $Xsed -e "$delay_single_quote_subst"`'
28052 need_version='`$ECHO "X$need_version" | $Xsed -e "$delay_single_quote_subst"`'
28053 version_type='`$ECHO "X$version_type" | $Xsed -e "$delay_single_quote_subst"`'
28054 runpath_var='`$ECHO "X$runpath_var" | $Xsed -e "$delay_single_quote_subst"`'
28055 shlibpath_var='`$ECHO "X$shlibpath_var" | $Xsed -e "$delay_single_quote_subst"`'
28056 shlibpath_overrides_runpath='`$ECHO "X$shlibpath_overrides_runpath" | $Xsed -e "$delay_single_quote_subst"`'
28057 libname_spec='`$ECHO "X$libname_spec" | $Xsed -e "$delay_single_quote_subst"`'
28058 library_names_spec='`$ECHO "X$library_names_spec" | $Xsed -e "$delay_single_quote_subst"`'
28059 soname_spec='`$ECHO "X$soname_spec" | $Xsed -e "$delay_single_quote_subst"`'
28060 postinstall_cmds='`$ECHO "X$postinstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28061 postuninstall_cmds='`$ECHO "X$postuninstall_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28062 finish_cmds='`$ECHO "X$finish_cmds" | $Xsed -e "$delay_single_quote_subst"`'
28063 finish_eval='`$ECHO "X$finish_eval" | $Xsed -e "$delay_single_quote_subst"`'
28064 hardcode_into_libs='`$ECHO "X$hardcode_into_libs" | $Xsed -e "$delay_single_quote_subst"`'
28065 sys_lib_search_path_spec='`$ECHO "X$sys_lib_search_path_spec" | $Xsed -e "$delay_single_quote_subst"`'
28066 sys_lib_dlsearch_path_spec='`$ECHO "X$sys_lib_dlsearch_path_spec" | $Xsed -e "$delay_single_quote_subst"`'
28067 hardcode_action='`$ECHO "X$hardcode_action" | $Xsed -e "$delay_single_quote_subst"`'
28068 enable_dlopen='`$ECHO "X$enable_dlopen" | $Xsed -e "$delay_single_quote_subst"`'
28069 enable_dlopen_self='`$ECHO "X$enable_dlopen_self" | $Xsed -e "$delay_single_quote_subst"`'
28070 enable_dlopen_self_static='`$ECHO "X$enable_dlopen_self_static" | $Xsed -e "$delay_single_quote_subst"`'
28071 old_striplib='`$ECHO "X$old_striplib" | $Xsed -e "$delay_single_quote_subst"`'
28072 striplib='`$ECHO "X$striplib" | $Xsed -e "$delay_single_quote_subst"`'
28073
28074 LTCC='$LTCC'
28075 LTCFLAGS='$LTCFLAGS'
28076 compiler='$compiler_DEFAULT'
28077
28078 # Quote evaled strings.
28079 for var in SED \
28080 GREP \
28081 EGREP \
28082 FGREP \
28083 LD \
28084 NM \
28085 LN_S \
28086 lt_SP2NL \
28087 lt_NL2SP \
28088 reload_flag \
28089 OBJDUMP \
28090 deplibs_check_method \
28091 file_magic_cmd \
28092 AR \
28093 AR_FLAGS \
28094 STRIP \
28095 RANLIB \
28096 CC \
28097 CFLAGS \
28098 compiler \
28099 lt_cv_sys_global_symbol_pipe \
28100 lt_cv_sys_global_symbol_to_cdecl \
28101 lt_cv_sys_global_symbol_to_c_name_address \
28102 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
28103 SHELL \
28104 ECHO \
28105 lt_prog_compiler_no_builtin_flag \
28106 lt_prog_compiler_wl \
28107 lt_prog_compiler_pic \
28108 lt_prog_compiler_static \
28109 lt_cv_prog_compiler_c_o \
28110 need_locks \
28111 DSYMUTIL \
28112 NMEDIT \
28113 LIPO \
28114 OTOOL \
28115 OTOOL64 \
28116 shrext_cmds \
28117 export_dynamic_flag_spec \
28118 whole_archive_flag_spec \
28119 compiler_needs_object \
28120 with_gnu_ld \
28121 allow_undefined_flag \
28122 no_undefined_flag \
28123 hardcode_libdir_flag_spec \
28124 hardcode_libdir_flag_spec_ld \
28125 hardcode_libdir_separator \
28126 fix_srcfile_path \
28127 exclude_expsyms \
28128 include_expsyms \
28129 file_list_spec \
28130 variables_saved_for_relink \
28131 libname_spec \
28132 library_names_spec \
28133 soname_spec \
28134 finish_eval \
28135 old_striplib \
28136 striplib; do
28137     case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
28138     *[\\\\\\\`\\"\\\$]*)
28139       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
28140       ;;
28141     *)
28142       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
28143       ;;
28144     esac
28145 done
28146
28147 # Double-quote double-evaled strings.
28148 for var in reload_cmds \
28149 old_postinstall_cmds \
28150 old_postuninstall_cmds \
28151 old_archive_cmds \
28152 extract_expsyms_cmds \
28153 old_archive_from_new_cmds \
28154 old_archive_from_expsyms_cmds \
28155 archive_cmds \
28156 archive_expsym_cmds \
28157 module_cmds \
28158 module_expsym_cmds \
28159 export_symbols_cmds \
28160 prelink_cmds \
28161 postinstall_cmds \
28162 postuninstall_cmds \
28163 finish_cmds \
28164 sys_lib_search_path_spec \
28165 sys_lib_dlsearch_path_spec; do
28166     case \`eval \\\\\$ECHO "X\\\\\$\$var"\` in
28167     *[\\\\\\\`\\"\\\$]*)
28168       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"X\\\$\$var\\" | \\\$Xsed -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
28169       ;;
28170     *)
28171       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
28172       ;;
28173     esac
28174 done
28175
28176 # Fix-up fallback echo if it was mangled by the above quoting rules.
28177 case \$lt_ECHO in
28178 *'\\\$0 --fallback-echo"')  lt_ECHO=\`\$ECHO "X\$lt_ECHO" | \$Xsed -e 's/\\\\\\\\\\\\\\\$0 --fallback-echo"\$/\$0 --fallback-echo"/'\`
28179   ;;
28180 esac
28181
28182 ac_aux_dir='$ac_aux_dir'
28183 xsi_shell='$xsi_shell'
28184 lt_shell_append='$lt_shell_append'
28185
28186 # See if we are running on zsh, and set the options which allow our
28187 # commands through without removal of \ escapes INIT.
28188 if test -n "\${ZSH_VERSION+set}" ; then
28189    setopt NO_GLOB_SUBST
28190 fi
28191
28192
28193     PACKAGE='$PACKAGE'
28194     VERSION='$VERSION'
28195     TIMESTAMP='$TIMESTAMP'
28196     RM='$RM'
28197     ofile='$ofile'
28198
28199
28200
28201
28202 _ACEOF
28203
28204 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
28205
28206 # Handling of arguments.
28207 for ac_config_target in $ac_config_targets
28208 do
28209   case $ac_config_target in
28210     "zfs_config.h") CONFIG_HEADERS="$CONFIG_HEADERS zfs_config.h" ;;
28211     "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
28212     "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
28213     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
28214     "dracut/Makefile") CONFIG_FILES="$CONFIG_FILES dracut/Makefile" ;;
28215     "dracut/90zfs/Makefile") CONFIG_FILES="$CONFIG_FILES dracut/90zfs/Makefile" ;;
28216     "udev/Makefile") CONFIG_FILES="$CONFIG_FILES udev/Makefile" ;;
28217     "udev/rules.d/Makefile") CONFIG_FILES="$CONFIG_FILES udev/rules.d/Makefile" ;;
28218     "etc/Makefile") CONFIG_FILES="$CONFIG_FILES etc/Makefile" ;;
28219     "etc/init.d/Makefile") CONFIG_FILES="$CONFIG_FILES etc/init.d/Makefile" ;;
28220     "etc/zfs/Makefile") CONFIG_FILES="$CONFIG_FILES etc/zfs/Makefile" ;;
28221     "man/Makefile") CONFIG_FILES="$CONFIG_FILES man/Makefile" ;;
28222     "man/man5/Makefile") CONFIG_FILES="$CONFIG_FILES man/man5/Makefile" ;;
28223     "man/man8/Makefile") CONFIG_FILES="$CONFIG_FILES man/man8/Makefile" ;;
28224     "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
28225     "lib/libspl/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/Makefile" ;;
28226     "lib/libspl/asm-generic/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/asm-generic/Makefile" ;;
28227     "lib/libspl/asm-i386/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/asm-i386/Makefile" ;;
28228     "lib/libspl/asm-x86_64/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/asm-x86_64/Makefile" ;;
28229     "lib/libspl/include/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/include/Makefile" ;;
28230     "lib/libspl/include/ia32/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/include/ia32/Makefile" ;;
28231     "lib/libspl/include/ia32/sys/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/include/ia32/sys/Makefile" ;;
28232     "lib/libspl/include/rpc/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/include/rpc/Makefile" ;;
28233     "lib/libspl/include/sys/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/include/sys/Makefile" ;;
28234     "lib/libspl/include/sys/sysevent/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/include/sys/sysevent/Makefile" ;;
28235     "lib/libspl/include/sys/dktp/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/include/sys/dktp/Makefile" ;;
28236     "lib/libspl/include/util/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libspl/include/util/Makefile" ;;
28237     "lib/libavl/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libavl/Makefile" ;;
28238     "lib/libefi/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libefi/Makefile" ;;
28239     "lib/libnvpair/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libnvpair/Makefile" ;;
28240     "lib/libunicode/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libunicode/Makefile" ;;
28241     "lib/libuutil/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libuutil/Makefile" ;;
28242     "lib/libzpool/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libzpool/Makefile" ;;
28243     "lib/libzfs/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libzfs/Makefile" ;;
28244     "lib/libshare/Makefile") CONFIG_FILES="$CONFIG_FILES lib/libshare/Makefile" ;;
28245     "cmd/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/Makefile" ;;
28246     "cmd/zdb/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/zdb/Makefile" ;;
28247     "cmd/zfs/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/zfs/Makefile" ;;
28248     "cmd/zinject/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/zinject/Makefile" ;;
28249     "cmd/zpool/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/zpool/Makefile" ;;
28250     "cmd/ztest/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/ztest/Makefile" ;;
28251     "cmd/zpios/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/zpios/Makefile" ;;
28252     "cmd/mount_zfs/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/mount_zfs/Makefile" ;;
28253     "cmd/zpool_layout/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/zpool_layout/Makefile" ;;
28254     "cmd/zvol_id/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/zvol_id/Makefile" ;;
28255     "cmd/zpool_id/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/zpool_id/Makefile" ;;
28256     "cmd/vdev_id/Makefile") CONFIG_FILES="$CONFIG_FILES cmd/vdev_id/Makefile" ;;
28257     "module/Makefile") CONFIG_FILES="$CONFIG_FILES module/Makefile" ;;
28258     "module/avl/Makefile") CONFIG_FILES="$CONFIG_FILES module/avl/Makefile" ;;
28259     "module/nvpair/Makefile") CONFIG_FILES="$CONFIG_FILES module/nvpair/Makefile" ;;
28260     "module/unicode/Makefile") CONFIG_FILES="$CONFIG_FILES module/unicode/Makefile" ;;
28261     "module/zcommon/Makefile") CONFIG_FILES="$CONFIG_FILES module/zcommon/Makefile" ;;
28262     "module/zfs/Makefile") CONFIG_FILES="$CONFIG_FILES module/zfs/Makefile" ;;
28263     "module/zpios/Makefile") CONFIG_FILES="$CONFIG_FILES module/zpios/Makefile" ;;
28264     "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;;
28265     "include/linux/Makefile") CONFIG_FILES="$CONFIG_FILES include/linux/Makefile" ;;
28266     "include/sys/Makefile") CONFIG_FILES="$CONFIG_FILES include/sys/Makefile" ;;
28267     "include/sys/fs/Makefile") CONFIG_FILES="$CONFIG_FILES include/sys/fs/Makefile" ;;
28268     "include/sys/fm/Makefile") CONFIG_FILES="$CONFIG_FILES include/sys/fm/Makefile" ;;
28269     "include/sys/fm/fs/Makefile") CONFIG_FILES="$CONFIG_FILES include/sys/fm/fs/Makefile" ;;
28270     "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;;
28271     "scripts/zpios-profile/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/zpios-profile/Makefile" ;;
28272     "scripts/zpios-test/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/zpios-test/Makefile" ;;
28273     "scripts/zpool-config/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/zpool-config/Makefile" ;;
28274     "scripts/zpool-layout/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/zpool-layout/Makefile" ;;
28275     "scripts/common.sh") CONFIG_FILES="$CONFIG_FILES scripts/common.sh" ;;
28276     "zfs.spec") CONFIG_FILES="$CONFIG_FILES zfs.spec" ;;
28277     "zfs-modules.spec") CONFIG_FILES="$CONFIG_FILES zfs-modules.spec" ;;
28278     "PKGBUILD-zfs") CONFIG_FILES="$CONFIG_FILES PKGBUILD-zfs" ;;
28279     "PKGBUILD-zfs-modules") CONFIG_FILES="$CONFIG_FILES PKGBUILD-zfs-modules" ;;
28280     "zfs-script-config.sh") CONFIG_FILES="$CONFIG_FILES zfs-script-config.sh" ;;
28281     "zfs.release") CONFIG_FILES="$CONFIG_FILES zfs.release" ;;
28282
28283   *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
28284 $as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
28285    { (exit 1); exit 1; }; };;
28286   esac
28287 done
28288
28289
28290 # If the user did not use the arguments to specify the items to instantiate,
28291 # then the envvar interface is used.  Set only those that are not.
28292 # We use the long form for the default assignment because of an extremely
28293 # bizarre bug on SunOS 4.1.3.
28294 if $ac_need_defaults; then
28295   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
28296   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
28297   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
28298 fi
28299
28300 # Have a temporary directory for convenience.  Make it in the build tree
28301 # simply because there is no reason against having it here, and in addition,
28302 # creating and moving files from /tmp can sometimes cause problems.
28303 # Hook for its removal unless debugging.
28304 # Note that there is a small window in which the directory will not be cleaned:
28305 # after its creation but before its name has been assigned to `$tmp'.
28306 $debug ||
28307 {
28308   tmp=
28309   trap 'exit_status=$?
28310   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
28311 ' 0
28312   trap '{ (exit 1); exit 1; }' 1 2 13 15
28313 }
28314 # Create a (secure) tmp directory for tmp files.
28315
28316 {
28317   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
28318   test -n "$tmp" && test -d "$tmp"
28319 }  ||
28320 {
28321   tmp=./conf$$-$RANDOM
28322   (umask 077 && mkdir "$tmp")
28323 } ||
28324 {
28325    $as_echo "$as_me: cannot create a temporary directory in ." >&2
28326    { (exit 1); exit 1; }
28327 }
28328
28329 # Set up the scripts for CONFIG_FILES section.
28330 # No need to generate them if there are no CONFIG_FILES.
28331 # This happens for instance with `./config.status config.h'.
28332 if test -n "$CONFIG_FILES"; then
28333
28334
28335 ac_cr='\r'
28336 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
28337 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
28338   ac_cs_awk_cr='\\r'
28339 else
28340   ac_cs_awk_cr=$ac_cr
28341 fi
28342
28343 echo 'BEGIN {' >"$tmp/subs1.awk" &&
28344 _ACEOF
28345
28346
28347 {
28348   echo "cat >conf$$subs.awk <<_ACEOF" &&
28349   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
28350   echo "_ACEOF"
28351 } >conf$$subs.sh ||
28352   { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
28353 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
28354    { (exit 1); exit 1; }; }
28355 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
28356 ac_delim='%!_!# '
28357 for ac_last_try in false false false false false :; do
28358   . ./conf$$subs.sh ||
28359     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
28360 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
28361    { (exit 1); exit 1; }; }
28362
28363   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
28364   if test $ac_delim_n = $ac_delim_num; then
28365     break
28366   elif $ac_last_try; then
28367     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
28368 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
28369    { (exit 1); exit 1; }; }
28370   else
28371     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
28372   fi
28373 done
28374 rm -f conf$$subs.sh
28375
28376 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
28377 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
28378 _ACEOF
28379 sed -n '
28380 h
28381 s/^/S["/; s/!.*/"]=/
28382 p
28383 g
28384 s/^[^!]*!//
28385 :repl
28386 t repl
28387 s/'"$ac_delim"'$//
28388 t delim
28389 :nl
28390 h
28391 s/\(.\{148\}\).*/\1/
28392 t more1
28393 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
28394 p
28395 n
28396 b repl
28397 :more1
28398 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
28399 p
28400 g
28401 s/.\{148\}//
28402 t nl
28403 :delim
28404 h
28405 s/\(.\{148\}\).*/\1/
28406 t more2
28407 s/["\\]/\\&/g; s/^/"/; s/$/"/
28408 p
28409 b
28410 :more2
28411 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
28412 p
28413 g
28414 s/.\{148\}//
28415 t delim
28416 ' <conf$$subs.awk | sed '
28417 /^[^""]/{
28418   N
28419   s/\n//
28420 }
28421 ' >>$CONFIG_STATUS || ac_write_fail=1
28422 rm -f conf$$subs.awk
28423 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
28424 _ACAWK
28425 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
28426   for (key in S) S_is_set[key] = 1
28427   FS = "\a"
28428
28429 }
28430 {
28431   line = $ 0
28432   nfields = split(line, field, "@")
28433   substed = 0
28434   len = length(field[1])
28435   for (i = 2; i < nfields; i++) {
28436     key = field[i]
28437     keylen = length(key)
28438     if (S_is_set[key]) {
28439       value = S[key]
28440       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
28441       len += length(value) + length(field[++i])
28442       substed = 1
28443     } else
28444       len += 1 + keylen
28445   }
28446
28447   print line
28448 }
28449
28450 _ACAWK
28451 _ACEOF
28452 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
28453 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
28454   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
28455 else
28456   cat
28457 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
28458   || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
28459 $as_echo "$as_me: error: could not setup config files machinery" >&2;}
28460    { (exit 1); exit 1; }; }
28461 _ACEOF
28462
28463 # VPATH may cause trouble with some makes, so we remove $(srcdir),
28464 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
28465 # trailing colons and then remove the whole line if VPATH becomes empty
28466 # (actually we leave an empty line to preserve line numbers).
28467 if test "x$srcdir" = x.; then
28468   ac_vpsub='/^[  ]*VPATH[        ]*=/{
28469 s/:*\$(srcdir):*/:/
28470 s/:*\${srcdir}:*/:/
28471 s/:*@srcdir@:*/:/
28472 s/^\([^=]*=[     ]*\):*/\1/
28473 s/:*$//
28474 s/^[^=]*=[       ]*$//
28475 }'
28476 fi
28477
28478 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
28479 fi # test -n "$CONFIG_FILES"
28480
28481 # Set up the scripts for CONFIG_HEADERS section.
28482 # No need to generate them if there are no CONFIG_HEADERS.
28483 # This happens for instance with `./config.status Makefile'.
28484 if test -n "$CONFIG_HEADERS"; then
28485 cat >"$tmp/defines.awk" <<\_ACAWK ||
28486 BEGIN {
28487 _ACEOF
28488
28489 # Transform confdefs.h into an awk script `defines.awk', embedded as
28490 # here-document in config.status, that substitutes the proper values into
28491 # config.h.in to produce config.h.
28492
28493 # Create a delimiter string that does not exist in confdefs.h, to ease
28494 # handling of long lines.
28495 ac_delim='%!_!# '
28496 for ac_last_try in false false :; do
28497   ac_t=`sed -n "/$ac_delim/p" confdefs.h`
28498   if test -z "$ac_t"; then
28499     break
28500   elif $ac_last_try; then
28501     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
28502 $as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
28503    { (exit 1); exit 1; }; }
28504   else
28505     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
28506   fi
28507 done
28508
28509 # For the awk script, D is an array of macro values keyed by name,
28510 # likewise P contains macro parameters if any.  Preserve backslash
28511 # newline sequences.
28512
28513 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
28514 sed -n '
28515 s/.\{148\}/&'"$ac_delim"'/g
28516 t rset
28517 :rset
28518 s/^[     ]*#[    ]*define[       ][      ]*/ /
28519 t def
28520 d
28521 :def
28522 s/\\$//
28523 t bsnl
28524 s/["\\]/\\&/g
28525 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
28526 D["\1"]=" \3"/p
28527 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
28528 d
28529 :bsnl
28530 s/["\\]/\\&/g
28531 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
28532 D["\1"]=" \3\\\\\\n"\\/p
28533 t cont
28534 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
28535 t cont
28536 d
28537 :cont
28538 n
28539 s/.\{148\}/&'"$ac_delim"'/g
28540 t clear
28541 :clear
28542 s/\\$//
28543 t bsnlc
28544 s/["\\]/\\&/g; s/^/"/; s/$/"/p
28545 d
28546 :bsnlc
28547 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
28548 b cont
28549 ' <confdefs.h | sed '
28550 s/'"$ac_delim"'/"\\\
28551 "/g' >>$CONFIG_STATUS || ac_write_fail=1
28552
28553 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
28554   for (key in D) D_is_set[key] = 1
28555   FS = "\a"
28556 }
28557 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
28558   line = \$ 0
28559   split(line, arg, " ")
28560   if (arg[1] == "#") {
28561     defundef = arg[2]
28562     mac1 = arg[3]
28563   } else {
28564     defundef = substr(arg[1], 2)
28565     mac1 = arg[2]
28566   }
28567   split(mac1, mac2, "(") #)
28568   macro = mac2[1]
28569   prefix = substr(line, 1, index(line, defundef) - 1)
28570   if (D_is_set[macro]) {
28571     # Preserve the white space surrounding the "#".
28572     print prefix "define", macro P[macro] D[macro]
28573     next
28574   } else {
28575     # Replace #undef with comments.  This is necessary, for example,
28576     # in the case of _POSIX_SOURCE, which is predefined and required
28577     # on some systems where configure will not decide to define it.
28578     if (defundef == "undef") {
28579       print "/*", prefix defundef, macro, "*/"
28580       next
28581     }
28582   }
28583 }
28584 { print }
28585 _ACAWK
28586 _ACEOF
28587 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
28588   { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
28589 $as_echo "$as_me: error: could not setup config headers machinery" >&2;}
28590    { (exit 1); exit 1; }; }
28591 fi # test -n "$CONFIG_HEADERS"
28592
28593
28594 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS"
28595 shift
28596 for ac_tag
28597 do
28598   case $ac_tag in
28599   :[FHLC]) ac_mode=$ac_tag; continue;;
28600   esac
28601   case $ac_mode$ac_tag in
28602   :[FHL]*:*);;
28603   :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
28604 $as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
28605    { (exit 1); exit 1; }; };;
28606   :[FH]-) ac_tag=-:-;;
28607   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
28608   esac
28609   ac_save_IFS=$IFS
28610   IFS=:
28611   set x $ac_tag
28612   IFS=$ac_save_IFS
28613   shift
28614   ac_file=$1
28615   shift
28616
28617   case $ac_mode in
28618   :L) ac_source=$1;;
28619   :[FH])
28620     ac_file_inputs=
28621     for ac_f
28622     do
28623       case $ac_f in
28624       -) ac_f="$tmp/stdin";;
28625       *) # Look for the file first in the build tree, then in the source tree
28626          # (if the path is not absolute).  The absolute path cannot be DOS-style,
28627          # because $ac_f cannot contain `:'.
28628          test -f "$ac_f" ||
28629            case $ac_f in
28630            [\\/$]*) false;;
28631            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
28632            esac ||
28633            { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
28634 $as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
28635    { (exit 1); exit 1; }; };;
28636       esac
28637       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
28638       ac_file_inputs="$ac_file_inputs '$ac_f'"
28639     done
28640
28641     # Let's still pretend it is `configure' which instantiates (i.e., don't
28642     # use $as_me), people would be surprised to read:
28643     #    /* config.h.  Generated by config.status.  */
28644     configure_input='Generated from '`
28645           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
28646         `' by configure.'
28647     if test x"$ac_file" != x-; then
28648       configure_input="$ac_file.  $configure_input"
28649       { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
28650 $as_echo "$as_me: creating $ac_file" >&6;}
28651     fi
28652     # Neutralize special characters interpreted by sed in replacement strings.
28653     case $configure_input in #(
28654     *\&* | *\|* | *\\* )
28655        ac_sed_conf_input=`$as_echo "$configure_input" |
28656        sed 's/[\\\\&|]/\\\\&/g'`;; #(
28657     *) ac_sed_conf_input=$configure_input;;
28658     esac
28659
28660     case $ac_tag in
28661     *:-:* | *:-) cat >"$tmp/stdin" \
28662       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
28663 $as_echo "$as_me: error: could not create $ac_file" >&2;}
28664    { (exit 1); exit 1; }; } ;;
28665     esac
28666     ;;
28667   esac
28668
28669   ac_dir=`$as_dirname -- "$ac_file" ||
28670 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
28671          X"$ac_file" : 'X\(//\)[^/]' \| \
28672          X"$ac_file" : 'X\(//\)$' \| \
28673          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
28674 $as_echo X"$ac_file" |
28675     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
28676             s//\1/
28677             q
28678           }
28679           /^X\(\/\/\)[^/].*/{
28680             s//\1/
28681             q
28682           }
28683           /^X\(\/\/\)$/{
28684             s//\1/
28685             q
28686           }
28687           /^X\(\/\).*/{
28688             s//\1/
28689             q
28690           }
28691           s/.*/./; q'`
28692   { as_dir="$ac_dir"
28693   case $as_dir in #(
28694   -*) as_dir=./$as_dir;;
28695   esac
28696   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
28697     as_dirs=
28698     while :; do
28699       case $as_dir in #(
28700       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
28701       *) as_qdir=$as_dir;;
28702       esac
28703       as_dirs="'$as_qdir' $as_dirs"
28704       as_dir=`$as_dirname -- "$as_dir" ||
28705 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
28706          X"$as_dir" : 'X\(//\)[^/]' \| \
28707          X"$as_dir" : 'X\(//\)$' \| \
28708          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
28709 $as_echo X"$as_dir" |
28710     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
28711             s//\1/
28712             q
28713           }
28714           /^X\(\/\/\)[^/].*/{
28715             s//\1/
28716             q
28717           }
28718           /^X\(\/\/\)$/{
28719             s//\1/
28720             q
28721           }
28722           /^X\(\/\).*/{
28723             s//\1/
28724             q
28725           }
28726           s/.*/./; q'`
28727       test -d "$as_dir" && break
28728     done
28729     test -z "$as_dirs" || eval "mkdir $as_dirs"
28730   } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
28731 $as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
28732    { (exit 1); exit 1; }; }; }
28733   ac_builddir=.
28734
28735 case "$ac_dir" in
28736 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
28737 *)
28738   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
28739   # A ".." for each directory in $ac_dir_suffix.
28740   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
28741   case $ac_top_builddir_sub in
28742   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
28743   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
28744   esac ;;
28745 esac
28746 ac_abs_top_builddir=$ac_pwd
28747 ac_abs_builddir=$ac_pwd$ac_dir_suffix
28748 # for backward compatibility:
28749 ac_top_builddir=$ac_top_build_prefix
28750
28751 case $srcdir in
28752   .)  # We are building in place.
28753     ac_srcdir=.
28754     ac_top_srcdir=$ac_top_builddir_sub
28755     ac_abs_top_srcdir=$ac_pwd ;;
28756   [\\/]* | ?:[\\/]* )  # Absolute name.
28757     ac_srcdir=$srcdir$ac_dir_suffix;
28758     ac_top_srcdir=$srcdir
28759     ac_abs_top_srcdir=$srcdir ;;
28760   *) # Relative name.
28761     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
28762     ac_top_srcdir=$ac_top_build_prefix$srcdir
28763     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
28764 esac
28765 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
28766
28767
28768   case $ac_mode in
28769   :F)
28770   #
28771   # CONFIG_FILE
28772   #
28773
28774   case $INSTALL in
28775   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
28776   *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
28777   esac
28778   ac_MKDIR_P=$MKDIR_P
28779   case $MKDIR_P in
28780   [\\/$]* | ?:[\\/]* ) ;;
28781   */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
28782   esac
28783 _ACEOF
28784
28785 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
28786 # If the template does not know about datarootdir, expand it.
28787 # FIXME: This hack should be removed a few years after 2.60.
28788 ac_datarootdir_hack=; ac_datarootdir_seen=
28789
28790 ac_sed_dataroot='
28791 /datarootdir/ {
28792   p
28793   q
28794 }
28795 /@datadir@/p
28796 /@docdir@/p
28797 /@infodir@/p
28798 /@localedir@/p
28799 /@mandir@/p
28800 '
28801 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
28802 *datarootdir*) ac_datarootdir_seen=yes;;
28803 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
28804   { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
28805 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
28806 _ACEOF
28807 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
28808   ac_datarootdir_hack='
28809   s&@datadir@&$datadir&g
28810   s&@docdir@&$docdir&g
28811   s&@infodir@&$infodir&g
28812   s&@localedir@&$localedir&g
28813   s&@mandir@&$mandir&g
28814     s&\\\${datarootdir}&$datarootdir&g' ;;
28815 esac
28816 _ACEOF
28817
28818 # Neutralize VPATH when `$srcdir' = `.'.
28819 # Shell code in configure.ac might set extrasub.
28820 # FIXME: do we really want to maintain this feature?
28821 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
28822 ac_sed_extra="$ac_vpsub
28823 $extrasub
28824 _ACEOF
28825 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
28826 :t
28827 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
28828 s|@configure_input@|$ac_sed_conf_input|;t t
28829 s&@top_builddir@&$ac_top_builddir_sub&;t t
28830 s&@top_build_prefix@&$ac_top_build_prefix&;t t
28831 s&@srcdir@&$ac_srcdir&;t t
28832 s&@abs_srcdir@&$ac_abs_srcdir&;t t
28833 s&@top_srcdir@&$ac_top_srcdir&;t t
28834 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
28835 s&@builddir@&$ac_builddir&;t t
28836 s&@abs_builddir@&$ac_abs_builddir&;t t
28837 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
28838 s&@INSTALL@&$ac_INSTALL&;t t
28839 s&@MKDIR_P@&$ac_MKDIR_P&;t t
28840 $ac_datarootdir_hack
28841 "
28842 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
28843   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
28844 $as_echo "$as_me: error: could not create $ac_file" >&2;}
28845    { (exit 1); exit 1; }; }
28846
28847 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
28848   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
28849   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
28850   { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
28851 which seems to be undefined.  Please make sure it is defined." >&5
28852 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
28853 which seems to be undefined.  Please make sure it is defined." >&2;}
28854
28855   rm -f "$tmp/stdin"
28856   case $ac_file in
28857   -) cat "$tmp/out" && rm -f "$tmp/out";;
28858   *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
28859   esac \
28860   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
28861 $as_echo "$as_me: error: could not create $ac_file" >&2;}
28862    { (exit 1); exit 1; }; }
28863  ;;
28864   :H)
28865   #
28866   # CONFIG_HEADER
28867   #
28868   if test x"$ac_file" != x-; then
28869     {
28870       $as_echo "/* $configure_input  */" \
28871       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
28872     } >"$tmp/config.h" \
28873       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
28874 $as_echo "$as_me: error: could not create $ac_file" >&2;}
28875    { (exit 1); exit 1; }; }
28876     if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
28877       { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
28878 $as_echo "$as_me: $ac_file is unchanged" >&6;}
28879     else
28880       rm -f "$ac_file"
28881       mv "$tmp/config.h" "$ac_file" \
28882         || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
28883 $as_echo "$as_me: error: could not create $ac_file" >&2;}
28884    { (exit 1); exit 1; }; }
28885     fi
28886   else
28887     $as_echo "/* $configure_input  */" \
28888       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
28889       || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
28890 $as_echo "$as_me: error: could not create -" >&2;}
28891    { (exit 1); exit 1; }; }
28892   fi
28893 # Compute "$ac_file"'s index in $config_headers.
28894 _am_arg="$ac_file"
28895 _am_stamp_count=1
28896 for _am_header in $config_headers :; do
28897   case $_am_header in
28898     $_am_arg | $_am_arg:* )
28899       break ;;
28900     * )
28901       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
28902   esac
28903 done
28904 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
28905 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
28906          X"$_am_arg" : 'X\(//\)[^/]' \| \
28907          X"$_am_arg" : 'X\(//\)$' \| \
28908          X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
28909 $as_echo X"$_am_arg" |
28910     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
28911             s//\1/
28912             q
28913           }
28914           /^X\(\/\/\)[^/].*/{
28915             s//\1/
28916             q
28917           }
28918           /^X\(\/\/\)$/{
28919             s//\1/
28920             q
28921           }
28922           /^X\(\/\).*/{
28923             s//\1/
28924             q
28925           }
28926           s/.*/./; q'`/stamp-h$_am_stamp_count
28927  ;;
28928
28929   :C)  { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5
28930 $as_echo "$as_me: executing $ac_file commands" >&6;}
28931  ;;
28932   esac
28933
28934
28935   case $ac_file$ac_mode in
28936     "zfs_config.h":H)
28937         (mv zfs_config.h zfs_config.h.tmp &&
28938         awk -f ${ac_srcdir}/config/config.awk zfs_config.h.tmp >zfs_config.h &&
28939         rm zfs_config.h.tmp) || exit 1 ;;
28940     "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
28941   # Autoconf 2.62 quotes --file arguments for eval, but not when files
28942   # are listed without --file.  Let's play safe and only enable the eval
28943   # if we detect the quoting.
28944   case $CONFIG_FILES in
28945   *\'*) eval set x "$CONFIG_FILES" ;;
28946   *)   set x $CONFIG_FILES ;;
28947   esac
28948   shift
28949   for mf
28950   do
28951     # Strip MF so we end up with the name of the file.
28952     mf=`echo "$mf" | sed -e 's/:.*$//'`
28953     # Check whether this is an Automake generated Makefile or not.
28954     # We used to match only the files named `Makefile.in', but
28955     # some people rename them; so instead we look at the file content.
28956     # Grep'ing the first line is not enough: some people post-process
28957     # each Makefile.in and add a new line on top of each file to say so.
28958     # Grep'ing the whole file is not good either: AIX grep has a line
28959     # limit of 2048, but all sed's we know have understand at least 4000.
28960     if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
28961       dirpart=`$as_dirname -- "$mf" ||
28962 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
28963          X"$mf" : 'X\(//\)[^/]' \| \
28964          X"$mf" : 'X\(//\)$' \| \
28965          X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
28966 $as_echo X"$mf" |
28967     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
28968             s//\1/
28969             q
28970           }
28971           /^X\(\/\/\)[^/].*/{
28972             s//\1/
28973             q
28974           }
28975           /^X\(\/\/\)$/{
28976             s//\1/
28977             q
28978           }
28979           /^X\(\/\).*/{
28980             s//\1/
28981             q
28982           }
28983           s/.*/./; q'`
28984     else
28985       continue
28986     fi
28987     # Extract the definition of DEPDIR, am__include, and am__quote
28988     # from the Makefile without running `make'.
28989     DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
28990     test -z "$DEPDIR" && continue
28991     am__include=`sed -n 's/^am__include = //p' < "$mf"`
28992     test -z "am__include" && continue
28993     am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
28994     # When using ansi2knr, U may be empty or an underscore; expand it
28995     U=`sed -n 's/^U = //p' < "$mf"`
28996     # Find all dependency output files, they are included files with
28997     # $(DEPDIR) in their names.  We invoke sed twice because it is the
28998     # simplest approach to changing $(DEPDIR) to its actual value in the
28999     # expansion.
29000     for file in `sed -n "
29001       s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
29002          sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
29003       # Make sure the directory exists.
29004       test -f "$dirpart/$file" && continue
29005       fdir=`$as_dirname -- "$file" ||
29006 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
29007          X"$file" : 'X\(//\)[^/]' \| \
29008          X"$file" : 'X\(//\)$' \| \
29009          X"$file" : 'X\(/\)' \| . 2>/dev/null ||
29010 $as_echo X"$file" |
29011     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
29012             s//\1/
29013             q
29014           }
29015           /^X\(\/\/\)[^/].*/{
29016             s//\1/
29017             q
29018           }
29019           /^X\(\/\/\)$/{
29020             s//\1/
29021             q
29022           }
29023           /^X\(\/\).*/{
29024             s//\1/
29025             q
29026           }
29027           s/.*/./; q'`
29028       { as_dir=$dirpart/$fdir
29029   case $as_dir in #(
29030   -*) as_dir=./$as_dir;;
29031   esac
29032   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
29033     as_dirs=
29034     while :; do
29035       case $as_dir in #(
29036       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
29037       *) as_qdir=$as_dir;;
29038       esac
29039       as_dirs="'$as_qdir' $as_dirs"
29040       as_dir=`$as_dirname -- "$as_dir" ||
29041 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
29042          X"$as_dir" : 'X\(//\)[^/]' \| \
29043          X"$as_dir" : 'X\(//\)$' \| \
29044          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
29045 $as_echo X"$as_dir" |
29046     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
29047             s//\1/
29048             q
29049           }
29050           /^X\(\/\/\)[^/].*/{
29051             s//\1/
29052             q
29053           }
29054           /^X\(\/\/\)$/{
29055             s//\1/
29056             q
29057           }
29058           /^X\(\/\).*/{
29059             s//\1/
29060             q
29061           }
29062           s/.*/./; q'`
29063       test -d "$as_dir" && break
29064     done
29065     test -z "$as_dirs" || eval "mkdir $as_dirs"
29066   } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
29067 $as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
29068    { (exit 1); exit 1; }; }; }
29069       # echo "creating $dirpart/$file"
29070       echo '# dummy' > "$dirpart/$file"
29071     done
29072   done
29073 }
29074  ;;
29075     "libtool":C)
29076
29077     # See if we are running on zsh, and set the options which allow our
29078     # commands through without removal of \ escapes.
29079     if test -n "${ZSH_VERSION+set}" ; then
29080       setopt NO_GLOB_SUBST
29081     fi
29082
29083     cfgfile="${ofile}T"
29084     trap "$RM \"$cfgfile\"; exit 1" 1 2 15
29085     $RM "$cfgfile"
29086
29087     cat <<_LT_EOF >> "$cfgfile"
29088 #! $SHELL
29089
29090 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
29091 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
29092 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
29093 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
29094 #
29095 #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
29096 #                 2006, 2007, 2008 Free Software Foundation, Inc.
29097 #   Written by Gordon Matzigkeit, 1996
29098 #
29099 #   This file is part of GNU Libtool.
29100 #
29101 # GNU Libtool is free software; you can redistribute it and/or
29102 # modify it under the terms of the GNU General Public License as
29103 # published by the Free Software Foundation; either version 2 of
29104 # the License, or (at your option) any later version.
29105 #
29106 # As a special exception to the GNU General Public License,
29107 # if you distribute this file as part of a program or library that
29108 # is built using GNU Libtool, you may include this file under the
29109 # same distribution terms that you use for the rest of that program.
29110 #
29111 # GNU Libtool is distributed in the hope that it will be useful,
29112 # but WITHOUT ANY WARRANTY; without even the implied warranty of
29113 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
29114 # GNU General Public License for more details.
29115 #
29116 # You should have received a copy of the GNU General Public License
29117 # along with GNU Libtool; see the file COPYING.  If not, a copy
29118 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
29119 # obtained by writing to the Free Software Foundation, Inc.,
29120 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
29121
29122
29123 # The names of the tagged configurations supported by this script.
29124 available_tags=""
29125
29126 # ### BEGIN LIBTOOL CONFIG
29127
29128 # Which release of libtool.m4 was used?
29129 macro_version=$macro_version
29130 macro_revision=$macro_revision
29131
29132 # Whether or not to build shared libraries.
29133 build_libtool_libs=$enable_shared
29134
29135 # Whether or not to build static libraries.
29136 build_old_libs=$enable_static
29137
29138 # What type of objects to build.
29139 pic_mode=$pic_mode
29140
29141 # Whether or not to optimize for fast installation.
29142 fast_install=$enable_fast_install
29143
29144 # The host system.
29145 host_alias=$host_alias
29146 host=$host
29147 host_os=$host_os
29148
29149 # The build system.
29150 build_alias=$build_alias
29151 build=$build
29152 build_os=$build_os
29153
29154 # A sed program that does not truncate output.
29155 SED=$lt_SED
29156
29157 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
29158 Xsed="\$SED -e 1s/^X//"
29159
29160 # A grep program that handles long lines.
29161 GREP=$lt_GREP
29162
29163 # An ERE matcher.
29164 EGREP=$lt_EGREP
29165
29166 # A literal string matcher.
29167 FGREP=$lt_FGREP
29168
29169 # A BSD- or MS-compatible name lister.
29170 NM=$lt_NM
29171
29172 # Whether we need soft or hard links.
29173 LN_S=$lt_LN_S
29174
29175 # What is the maximum length of a command?
29176 max_cmd_len=$max_cmd_len
29177
29178 # Object file suffix (normally "o").
29179 objext=$ac_objext
29180
29181 # Executable file suffix (normally "").
29182 exeext=$exeext
29183
29184 # whether the shell understands "unset".
29185 lt_unset=$lt_unset
29186
29187 # turn spaces into newlines.
29188 SP2NL=$lt_lt_SP2NL
29189
29190 # turn newlines into spaces.
29191 NL2SP=$lt_lt_NL2SP
29192
29193 # How to create reloadable object files.
29194 reload_flag=$lt_reload_flag
29195 reload_cmds=$lt_reload_cmds
29196
29197 # An object symbol dumper.
29198 OBJDUMP=$lt_OBJDUMP
29199
29200 # Method to check whether dependent libraries are shared objects.
29201 deplibs_check_method=$lt_deplibs_check_method
29202
29203 # Command to use when deplibs_check_method == "file_magic".
29204 file_magic_cmd=$lt_file_magic_cmd
29205
29206 # The archiver.
29207 AR=$lt_AR
29208 AR_FLAGS=$lt_AR_FLAGS
29209
29210 # A symbol stripping program.
29211 STRIP=$lt_STRIP
29212
29213 # Commands used to install an old-style archive.
29214 RANLIB=$lt_RANLIB
29215 old_postinstall_cmds=$lt_old_postinstall_cmds
29216 old_postuninstall_cmds=$lt_old_postuninstall_cmds
29217
29218 # A C compiler.
29219 LTCC=$lt_CC
29220
29221 # LTCC compiler flags.
29222 LTCFLAGS=$lt_CFLAGS
29223
29224 # Take the output of nm and produce a listing of raw symbols and C names.
29225 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
29226
29227 # Transform the output of nm in a proper C declaration.
29228 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
29229
29230 # Transform the output of nm in a C name address pair.
29231 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
29232
29233 # Transform the output of nm in a C name address pair when lib prefix is needed.
29234 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
29235
29236 # The name of the directory that contains temporary libtool files.
29237 objdir=$objdir
29238
29239 # Shell to use when invoking shell scripts.
29240 SHELL=$lt_SHELL
29241
29242 # An echo program that does not interpret backslashes.
29243 ECHO=$lt_ECHO
29244
29245 # Used to examine libraries when file_magic_cmd begins with "file".
29246 MAGIC_CMD=$MAGIC_CMD
29247
29248 # Must we lock files when doing compilation?
29249 need_locks=$lt_need_locks
29250
29251 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
29252 DSYMUTIL=$lt_DSYMUTIL
29253
29254 # Tool to change global to local symbols on Mac OS X.
29255 NMEDIT=$lt_NMEDIT
29256
29257 # Tool to manipulate fat objects and archives on Mac OS X.
29258 LIPO=$lt_LIPO
29259
29260 # ldd/readelf like tool for Mach-O binaries on Mac OS X.
29261 OTOOL=$lt_OTOOL
29262
29263 # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
29264 OTOOL64=$lt_OTOOL64
29265
29266 # Old archive suffix (normally "a").
29267 libext=$libext
29268
29269 # Shared library suffix (normally ".so").
29270 shrext_cmds=$lt_shrext_cmds
29271
29272 # The commands to extract the exported symbol list from a shared archive.
29273 extract_expsyms_cmds=$lt_extract_expsyms_cmds
29274
29275 # Variables whose values should be saved in libtool wrapper scripts and
29276 # restored at link time.
29277 variables_saved_for_relink=$lt_variables_saved_for_relink
29278
29279 # Do we need the "lib" prefix for modules?
29280 need_lib_prefix=$need_lib_prefix
29281
29282 # Do we need a version for libraries?
29283 need_version=$need_version
29284
29285 # Library versioning type.
29286 version_type=$version_type
29287
29288 # Shared library runtime path variable.
29289 runpath_var=$runpath_var
29290
29291 # Shared library path variable.
29292 shlibpath_var=$shlibpath_var
29293
29294 # Is shlibpath searched before the hard-coded library search path?
29295 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
29296
29297 # Format of library name prefix.
29298 libname_spec=$lt_libname_spec
29299
29300 # List of archive names.  First name is the real one, the rest are links.
29301 # The last name is the one that the linker finds with -lNAME
29302 library_names_spec=$lt_library_names_spec
29303
29304 # The coded name of the library, if different from the real name.
29305 soname_spec=$lt_soname_spec
29306
29307 # Command to use after installation of a shared archive.
29308 postinstall_cmds=$lt_postinstall_cmds
29309
29310 # Command to use after uninstallation of a shared archive.
29311 postuninstall_cmds=$lt_postuninstall_cmds
29312
29313 # Commands used to finish a libtool library installation in a directory.
29314 finish_cmds=$lt_finish_cmds
29315
29316 # As "finish_cmds", except a single script fragment to be evaled but
29317 # not shown.
29318 finish_eval=$lt_finish_eval
29319
29320 # Whether we should hardcode library paths into libraries.
29321 hardcode_into_libs=$hardcode_into_libs
29322
29323 # Compile-time system search path for libraries.
29324 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
29325
29326 # Run-time system search path for libraries.
29327 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
29328
29329 # Whether dlopen is supported.
29330 dlopen_support=$enable_dlopen
29331
29332 # Whether dlopen of programs is supported.
29333 dlopen_self=$enable_dlopen_self
29334
29335 # Whether dlopen of statically linked programs is supported.
29336 dlopen_self_static=$enable_dlopen_self_static
29337
29338 # Commands to strip libraries.
29339 old_striplib=$lt_old_striplib
29340 striplib=$lt_striplib
29341
29342
29343 # The linker used to build libraries.
29344 LD=$lt_LD
29345
29346 # Commands used to build an old-style archive.
29347 old_archive_cmds=$lt_old_archive_cmds
29348
29349 # A language specific compiler.
29350 CC=$lt_compiler
29351
29352 # Is the compiler the GNU compiler?
29353 with_gcc=$GCC
29354
29355 # Compiler flag to turn off builtin functions.
29356 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
29357
29358 # How to pass a linker flag through the compiler.
29359 wl=$lt_lt_prog_compiler_wl
29360
29361 # Additional compiler flags for building library objects.
29362 pic_flag=$lt_lt_prog_compiler_pic
29363
29364 # Compiler flag to prevent dynamic linking.
29365 link_static_flag=$lt_lt_prog_compiler_static
29366
29367 # Does compiler simultaneously support -c and -o options?
29368 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
29369
29370 # Whether or not to add -lc for building shared libraries.
29371 build_libtool_need_lc=$archive_cmds_need_lc
29372
29373 # Whether or not to disallow shared libs when runtime libs are static.
29374 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
29375
29376 # Compiler flag to allow reflexive dlopens.
29377 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
29378
29379 # Compiler flag to generate shared objects directly from archives.
29380 whole_archive_flag_spec=$lt_whole_archive_flag_spec
29381
29382 # Whether the compiler copes with passing no objects directly.
29383 compiler_needs_object=$lt_compiler_needs_object
29384
29385 # Create an old-style archive from a shared archive.
29386 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
29387
29388 # Create a temporary old-style archive to link instead of a shared archive.
29389 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
29390
29391 # Commands used to build a shared archive.
29392 archive_cmds=$lt_archive_cmds
29393 archive_expsym_cmds=$lt_archive_expsym_cmds
29394
29395 # Commands used to build a loadable module if different from building
29396 # a shared archive.
29397 module_cmds=$lt_module_cmds
29398 module_expsym_cmds=$lt_module_expsym_cmds
29399
29400 # Whether we are building with GNU ld or not.
29401 with_gnu_ld=$lt_with_gnu_ld
29402
29403 # Flag that allows shared libraries with undefined symbols to be built.
29404 allow_undefined_flag=$lt_allow_undefined_flag
29405
29406 # Flag that enforces no undefined symbols.
29407 no_undefined_flag=$lt_no_undefined_flag
29408
29409 # Flag to hardcode \$libdir into a binary during linking.
29410 # This must work even if \$libdir does not exist
29411 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
29412
29413 # If ld is used when linking, flag to hardcode \$libdir into a binary
29414 # during linking.  This must work even if \$libdir does not exist.
29415 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
29416
29417 # Whether we need a single "-rpath" flag with a separated argument.
29418 hardcode_libdir_separator=$lt_hardcode_libdir_separator
29419
29420 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
29421 # DIR into the resulting binary.
29422 hardcode_direct=$hardcode_direct
29423
29424 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
29425 # DIR into the resulting binary and the resulting library dependency is
29426 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
29427 # library is relocated.
29428 hardcode_direct_absolute=$hardcode_direct_absolute
29429
29430 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
29431 # into the resulting binary.
29432 hardcode_minus_L=$hardcode_minus_L
29433
29434 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
29435 # into the resulting binary.
29436 hardcode_shlibpath_var=$hardcode_shlibpath_var
29437
29438 # Set to "yes" if building a shared library automatically hardcodes DIR
29439 # into the library and all subsequent libraries and executables linked
29440 # against it.
29441 hardcode_automatic=$hardcode_automatic
29442
29443 # Set to yes if linker adds runtime paths of dependent libraries
29444 # to runtime path list.
29445 inherit_rpath=$inherit_rpath
29446
29447 # Whether libtool must link a program against all its dependency libraries.
29448 link_all_deplibs=$link_all_deplibs
29449
29450 # Fix the shell variable \$srcfile for the compiler.
29451 fix_srcfile_path=$lt_fix_srcfile_path
29452
29453 # Set to "yes" if exported symbols are required.
29454 always_export_symbols=$always_export_symbols
29455
29456 # The commands to list exported symbols.
29457 export_symbols_cmds=$lt_export_symbols_cmds
29458
29459 # Symbols that should not be listed in the preloaded symbols.
29460 exclude_expsyms=$lt_exclude_expsyms
29461
29462 # Symbols that must always be exported.
29463 include_expsyms=$lt_include_expsyms
29464
29465 # Commands necessary for linking programs (against libraries) with templates.
29466 prelink_cmds=$lt_prelink_cmds
29467
29468 # Specify filename containing input files.
29469 file_list_spec=$lt_file_list_spec
29470
29471 # How to hardcode a shared library path into an executable.
29472 hardcode_action=$hardcode_action
29473
29474 # ### END LIBTOOL CONFIG
29475
29476 _LT_EOF
29477
29478   case $host_os in
29479   aix3*)
29480     cat <<\_LT_EOF >> "$cfgfile"
29481 # AIX sometimes has problems with the GCC collect2 program.  For some
29482 # reason, if we set the COLLECT_NAMES environment variable, the problems
29483 # vanish in a puff of smoke.
29484 if test "X${COLLECT_NAMES+set}" != Xset; then
29485   COLLECT_NAMES=
29486   export COLLECT_NAMES
29487 fi
29488 _LT_EOF
29489     ;;
29490   esac
29491
29492
29493 ltmain="$ac_aux_dir/ltmain.sh"
29494
29495
29496   # We use sed instead of cat because bash on DJGPP gets confused if
29497   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
29498   # text mode, it properly converts lines to CR/LF.  This bash problem
29499   # is reportedly fixed, but why not run on old versions too?
29500   sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
29501     || (rm -f "$cfgfile"; exit 1)
29502
29503   case $xsi_shell in
29504   yes)
29505     cat << \_LT_EOF >> "$cfgfile"
29506
29507 # func_dirname file append nondir_replacement
29508 # Compute the dirname of FILE.  If nonempty, add APPEND to the result,
29509 # otherwise set result to NONDIR_REPLACEMENT.
29510 func_dirname ()
29511 {
29512   case ${1} in
29513     */*) func_dirname_result="${1%/*}${2}" ;;
29514     *  ) func_dirname_result="${3}" ;;
29515   esac
29516 }
29517
29518 # func_basename file
29519 func_basename ()
29520 {
29521   func_basename_result="${1##*/}"
29522 }
29523
29524 # func_dirname_and_basename file append nondir_replacement
29525 # perform func_basename and func_dirname in a single function
29526 # call:
29527 #   dirname:  Compute the dirname of FILE.  If nonempty,
29528 #             add APPEND to the result, otherwise set result
29529 #             to NONDIR_REPLACEMENT.
29530 #             value returned in "$func_dirname_result"
29531 #   basename: Compute filename of FILE.
29532 #             value retuned in "$func_basename_result"
29533 # Implementation must be kept synchronized with func_dirname
29534 # and func_basename. For efficiency, we do not delegate to
29535 # those functions but instead duplicate the functionality here.
29536 func_dirname_and_basename ()
29537 {
29538   case ${1} in
29539     */*) func_dirname_result="${1%/*}${2}" ;;
29540     *  ) func_dirname_result="${3}" ;;
29541   esac
29542   func_basename_result="${1##*/}"
29543 }
29544
29545 # func_stripname prefix suffix name
29546 # strip PREFIX and SUFFIX off of NAME.
29547 # PREFIX and SUFFIX must not contain globbing or regex special
29548 # characters, hashes, percent signs, but SUFFIX may contain a leading
29549 # dot (in which case that matches only a dot).
29550 func_stripname ()
29551 {
29552   # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
29553   # positional parameters, so assign one to ordinary parameter first.
29554   func_stripname_result=${3}
29555   func_stripname_result=${func_stripname_result#"${1}"}
29556   func_stripname_result=${func_stripname_result%"${2}"}
29557 }
29558
29559 # func_opt_split
29560 func_opt_split ()
29561 {
29562   func_opt_split_opt=${1%%=*}
29563   func_opt_split_arg=${1#*=}
29564 }
29565
29566 # func_lo2o object
29567 func_lo2o ()
29568 {
29569   case ${1} in
29570     *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
29571     *)    func_lo2o_result=${1} ;;
29572   esac
29573 }
29574
29575 # func_xform libobj-or-source
29576 func_xform ()
29577 {
29578   func_xform_result=${1%.*}.lo
29579 }
29580
29581 # func_arith arithmetic-term...
29582 func_arith ()
29583 {
29584   func_arith_result=$(( $* ))
29585 }
29586
29587 # func_len string
29588 # STRING may not start with a hyphen.
29589 func_len ()
29590 {
29591   func_len_result=${#1}
29592 }
29593
29594 _LT_EOF
29595     ;;
29596   *) # Bourne compatible functions.
29597     cat << \_LT_EOF >> "$cfgfile"
29598
29599 # func_dirname file append nondir_replacement
29600 # Compute the dirname of FILE.  If nonempty, add APPEND to the result,
29601 # otherwise set result to NONDIR_REPLACEMENT.
29602 func_dirname ()
29603 {
29604   # Extract subdirectory from the argument.
29605   func_dirname_result=`$ECHO "X${1}" | $Xsed -e "$dirname"`
29606   if test "X$func_dirname_result" = "X${1}"; then
29607     func_dirname_result="${3}"
29608   else
29609     func_dirname_result="$func_dirname_result${2}"
29610   fi
29611 }
29612
29613 # func_basename file
29614 func_basename ()
29615 {
29616   func_basename_result=`$ECHO "X${1}" | $Xsed -e "$basename"`
29617 }
29618
29619
29620 # func_stripname prefix suffix name
29621 # strip PREFIX and SUFFIX off of NAME.
29622 # PREFIX and SUFFIX must not contain globbing or regex special
29623 # characters, hashes, percent signs, but SUFFIX may contain a leading
29624 # dot (in which case that matches only a dot).
29625 # func_strip_suffix prefix name
29626 func_stripname ()
29627 {
29628   case ${2} in
29629     .*) func_stripname_result=`$ECHO "X${3}" \
29630            | $Xsed -e "s%^${1}%%" -e "s%\\\\${2}\$%%"`;;
29631     *)  func_stripname_result=`$ECHO "X${3}" \
29632            | $Xsed -e "s%^${1}%%" -e "s%${2}\$%%"`;;
29633   esac
29634 }
29635
29636 # sed scripts:
29637 my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
29638 my_sed_long_arg='1s/^-[^=]*=//'
29639
29640 # func_opt_split
29641 func_opt_split ()
29642 {
29643   func_opt_split_opt=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_opt"`
29644   func_opt_split_arg=`$ECHO "X${1}" | $Xsed -e "$my_sed_long_arg"`
29645 }
29646
29647 # func_lo2o object
29648 func_lo2o ()
29649 {
29650   func_lo2o_result=`$ECHO "X${1}" | $Xsed -e "$lo2o"`
29651 }
29652
29653 # func_xform libobj-or-source
29654 func_xform ()
29655 {
29656   func_xform_result=`$ECHO "X${1}" | $Xsed -e 's/\.[^.]*$/.lo/'`
29657 }
29658
29659 # func_arith arithmetic-term...
29660 func_arith ()
29661 {
29662   func_arith_result=`expr "$@"`
29663 }
29664
29665 # func_len string
29666 # STRING may not start with a hyphen.
29667 func_len ()
29668 {
29669   func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
29670 }
29671
29672 _LT_EOF
29673 esac
29674
29675 case $lt_shell_append in
29676   yes)
29677     cat << \_LT_EOF >> "$cfgfile"
29678
29679 # func_append var value
29680 # Append VALUE to the end of shell variable VAR.
29681 func_append ()
29682 {
29683   eval "$1+=\$2"
29684 }
29685 _LT_EOF
29686     ;;
29687   *)
29688     cat << \_LT_EOF >> "$cfgfile"
29689
29690 # func_append var value
29691 # Append VALUE to the end of shell variable VAR.
29692 func_append ()
29693 {
29694   eval "$1=\$$1\$2"
29695 }
29696
29697 _LT_EOF
29698     ;;
29699   esac
29700
29701
29702   sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
29703     || (rm -f "$cfgfile"; exit 1)
29704
29705   mv -f "$cfgfile" "$ofile" ||
29706     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
29707   chmod +x "$ofile"
29708
29709  ;;
29710
29711   esac
29712 done # for ac_tag
29713
29714
29715 { (exit 0); exit 0; }
29716 _ACEOF
29717 chmod +x $CONFIG_STATUS
29718 ac_clean_files=$ac_clean_files_save
29719
29720 test $ac_write_fail = 0 ||
29721   { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
29722 $as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
29723    { (exit 1); exit 1; }; }
29724
29725
29726 # configure is writing to config.log, and then calls config.status.
29727 # config.status does its own redirection, appending to config.log.
29728 # Unfortunately, on DOS this fails, as config.log is still kept open
29729 # by configure, so config.status won't be able to write to it; its
29730 # output is simply discarded.  So we exec the FD to /dev/null,
29731 # effectively closing config.log, so it can be properly (re)opened and
29732 # appended to by config.status.  When coming back to configure, we
29733 # need to make the FD available again.
29734 if test "$no_create" != yes; then
29735   ac_cs_success=:
29736   ac_config_status_args=
29737   test "$silent" = yes &&
29738     ac_config_status_args="$ac_config_status_args --quiet"
29739   exec 5>/dev/null
29740   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
29741   exec 5>>config.log
29742   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
29743   # would make configure fail if this is the last instruction.
29744   $ac_cs_success || { (exit 1); exit 1; }
29745 fi
29746 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
29747   { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
29748 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
29749 fi
29750