#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.63 for Lustre LUSTRE_VERSION.
#
# Report bugs to <http://bugs.whamcloud.com/>.
#
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
# 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
# This configure script is free software; the Free Software Foundation
# gives unlimited permission to copy, distribute and modify it.
## --------------------- ##
## M4sh Initialization.  ##
## --------------------- ##

# Be more Bourne compatible
DUALCASE=1; export DUALCASE # for MKS sh
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
  emulate sh
  NULLCMD=:
  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
  # is contrary to our usage.  Disable this feature.
  alias -g '${1+"$@"}'='"$@"'
  setopt NO_GLOB_SUBST
else
  case `(set -o) 2>/dev/null` in
  *posix*) set -o posix ;;
esac

fi




# PATH needs CR
# Avoid depending upon Character Ranges.
as_cr_letters='abcdefghijklmnopqrstuvwxyz'
as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
as_cr_Letters=$as_cr_letters$as_cr_LETTERS
as_cr_digits='0123456789'
as_cr_alnum=$as_cr_Letters$as_cr_digits

as_nl='
'
export as_nl
# Printing a long string crashes Solaris 7 /usr/bin/printf.
as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
  as_echo='printf %s\n'
  as_echo_n='printf %s'
else
  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
    as_echo_n='/usr/ucb/echo -n'
  else
    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
    as_echo_n_body='eval
      arg=$1;
      case $arg in
      *"$as_nl"*)
	expr "X$arg" : "X\\(.*\\)$as_nl";
	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
      esac;
      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
    '
    export as_echo_n_body
    as_echo_n='sh -c $as_echo_n_body as_echo'
  fi
  export as_echo_body
  as_echo='sh -c $as_echo_body as_echo'
fi

# The user is always right.
if test "${PATH_SEPARATOR+set}" != set; then
  PATH_SEPARATOR=:
  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
      PATH_SEPARATOR=';'
  }
fi

# Support unset when possible.
if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
  as_unset=unset
else
  as_unset=false
fi


# IFS
# We need space, tab and new line, in precisely that order.  Quoting is
# there to prevent editors from complaining about space-tab.
# (If _AS_PATH_WALK were called with IFS unset, it would disable word
# splitting by setting IFS to empty value.)
IFS=" ""	$as_nl"

# Find who we are.  Look in the path if we contain no directory separator.
case $0 in
  *[\\/]* ) as_myself=$0 ;;
  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
done
IFS=$as_save_IFS

     ;;
esac
# We did not find ourselves, most probably we were run as `sh COMMAND'
# in which case we are not to be found in the path.
if test "x$as_myself" = x; then
  as_myself=$0
fi
if test ! -f "$as_myself"; then
  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
  { (exit 1); exit 1; }
fi

# Work around bugs in pre-3.0 UWIN ksh.
for as_var in ENV MAIL MAILPATH
do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
done
PS1='$ '
PS2='> '
PS4='+ '

# NLS nuisances.
LC_ALL=C
export LC_ALL
LANGUAGE=C
export LANGUAGE

# Required to use basename.
if expr a : '\(a\)' >/dev/null 2>&1 &&
   test "X`expr 00001 : '.*\(...\)'`" = X001; then
  as_expr=expr
else
  as_expr=false
fi

if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
  as_basename=basename
else
  as_basename=false
fi


# Name of the executable.
as_me=`$as_basename -- "$0" ||
$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
	 X"$0" : 'X\(//\)$' \| \
	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X/"$0" |
    sed '/^.*\/\([^/][^/]*\)\/*$/{
	    s//\1/
	    q
	  }
	  /^X\/\(\/\/\)$/{
	    s//\1/
	    q
	  }
	  /^X\/\(\/\).*/{
	    s//\1/
	    q
	  }
	  s/.*/./; q'`

# CDPATH.
$as_unset CDPATH


if test "x$CONFIG_SHELL" = x; then
  if (eval ":") 2>/dev/null; then
  as_have_required=yes
else
  as_have_required=no
fi

  if test $as_have_required = yes &&	 (eval ":
(as_func_return () {
  (exit \$1)
}
as_func_success () {
  as_func_return 0
}
as_func_failure () {
  as_func_return 1
}
as_func_ret_success () {
  return 0
}
as_func_ret_failure () {
  return 1
}

exitcode=0
if as_func_success; then
  :
else
  exitcode=1
  echo as_func_success failed.
fi

if as_func_failure; then
  exitcode=1
  echo as_func_failure succeeded.
fi

if as_func_ret_success; then
  :
else
  exitcode=1
  echo as_func_ret_success failed.
fi

if as_func_ret_failure; then
  exitcode=1
  echo as_func_ret_failure succeeded.
fi

if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
  :
else
  exitcode=1
  echo positional parameters were not saved.
fi

test \$exitcode = 0) || { (exit 1); exit 1; }

(
  as_lineno_1=\$LINENO
  as_lineno_2=\$LINENO
  test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
  test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
") 2> /dev/null; then
  :
else
  as_candidate_shells=
    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  case $as_dir in
	 /*)
	   for as_base in sh bash ksh sh5; do
	     as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
	   done;;
       esac
done
IFS=$as_save_IFS


      for as_shell in $as_candidate_shells $SHELL; do
	 # Try only shells that exist, to save several forks.
	 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
		{ ("$as_shell") 2> /dev/null <<\_ASEOF
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
  emulate sh
  NULLCMD=:
  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
  # is contrary to our usage.  Disable this feature.
  alias -g '${1+"$@"}'='"$@"'
  setopt NO_GLOB_SUBST
else
  case `(set -o) 2>/dev/null` in
  *posix*) set -o posix ;;
esac

fi


:
_ASEOF
}; then
  CONFIG_SHELL=$as_shell
	       as_have_required=yes
	       if { "$as_shell" 2> /dev/null <<\_ASEOF
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
  emulate sh
  NULLCMD=:
  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
  # is contrary to our usage.  Disable this feature.
  alias -g '${1+"$@"}'='"$@"'
  setopt NO_GLOB_SUBST
else
  case `(set -o) 2>/dev/null` in
  *posix*) set -o posix ;;
esac

fi


:
(as_func_return () {
  (exit $1)
}
as_func_success () {
  as_func_return 0
}
as_func_failure () {
  as_func_return 1
}
as_func_ret_success () {
  return 0
}
as_func_ret_failure () {
  return 1
}

exitcode=0
if as_func_success; then
  :
else
  exitcode=1
  echo as_func_success failed.
fi

if as_func_failure; then
  exitcode=1
  echo as_func_failure succeeded.
fi

if as_func_ret_success; then
  :
else
  exitcode=1
  echo as_func_ret_success failed.
fi

if as_func_ret_failure; then
  exitcode=1
  echo as_func_ret_failure succeeded.
fi

if ( set x; as_func_ret_success y && test x = "$1" ); then
  :
else
  exitcode=1
  echo positional parameters were not saved.
fi

test $exitcode = 0) || { (exit 1); exit 1; }

(
  as_lineno_1=$LINENO
  as_lineno_2=$LINENO
  test "x$as_lineno_1" != "x$as_lineno_2" &&
  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }

_ASEOF
}; then
  break
fi

fi

      done

      if test "x$CONFIG_SHELL" != x; then
  for as_var in BASH_ENV ENV
	do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
	done
	export CONFIG_SHELL
	exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
fi


    if test $as_have_required = no; then
  echo This script requires a shell more modern than all the
      echo shells that I found on your system.  Please install a
      echo modern shell, or manually run the script under such a
      echo shell if you do have one.
      { (exit 1); exit 1; }
fi


fi

fi



(eval "as_func_return () {
  (exit \$1)
}
as_func_success () {
  as_func_return 0
}
as_func_failure () {
  as_func_return 1
}
as_func_ret_success () {
  return 0
}
as_func_ret_failure () {
  return 1
}

exitcode=0
if as_func_success; then
  :
else
  exitcode=1
  echo as_func_success failed.
fi

if as_func_failure; then
  exitcode=1
  echo as_func_failure succeeded.
fi

if as_func_ret_success; then
  :
else
  exitcode=1
  echo as_func_ret_success failed.
fi

if as_func_ret_failure; then
  exitcode=1
  echo as_func_ret_failure succeeded.
fi

if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
  :
else
  exitcode=1
  echo positional parameters were not saved.
fi

test \$exitcode = 0") || {
  echo No shell found that supports shell functions.
  echo Please tell bug-autoconf@gnu.org about your system,
  echo including any error possibly output before this message.
  echo This can help us improve future autoconf versions.
  echo Configuration will now proceed without shell functions.
}



  as_lineno_1=$LINENO
  as_lineno_2=$LINENO
  test "x$as_lineno_1" != "x$as_lineno_2" &&
  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {

  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
  # uniformly replaced by the line number.  The first 'sed' inserts a
  # line-number line after each line using $LINENO; the second 'sed'
  # does the real work.  The second script uses 'N' to pair each
  # line-number line with the line containing $LINENO, and appends
  # trailing '-' during substitution so that $LINENO is not a special
  # case at line end.
  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
  # scripts with optimization help from Paolo Bonzini.  Blame Lee
  # E. McMahon (1931-1989) for sed's syntax.  :-)
  sed -n '
    p
    /[$]LINENO/=
  ' <$as_myself |
    sed '
      s/[$]LINENO.*/&-/
      t lineno
      b
      :lineno
      N
      :loop
      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
      t loop
      s/-\n.*//
    ' >$as_me.lineno &&
  chmod +x "$as_me.lineno" ||
    { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
   { (exit 1); exit 1; }; }

  # Don't try to exec as it changes $[0], causing all sort of problems
  # (the dirname of $[0] is not the place where we might find the
  # original and so on.  Autoconf is especially sensitive to this).
  . "./$as_me.lineno"
  # Exit status is that of the last command.
  exit
}


if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
  as_dirname=dirname
else
  as_dirname=false
fi

ECHO_C= ECHO_N= ECHO_T=
case `echo -n x` in
-n*)
  case `echo 'x\c'` in
  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
  *)   ECHO_C='\c';;
  esac;;
*)
  ECHO_N='-n';;
esac
if expr a : '\(a\)' >/dev/null 2>&1 &&
   test "X`expr 00001 : '.*\(...\)'`" = X001; then
  as_expr=expr
else
  as_expr=false
fi

rm -f conf$$ conf$$.exe conf$$.file
if test -d conf$$.dir; then
  rm -f conf$$.dir/conf$$.file
else
  rm -f conf$$.dir
  mkdir conf$$.dir 2>/dev/null
fi
if (echo >conf$$.file) 2>/dev/null; then
  if ln -s conf$$.file conf$$ 2>/dev/null; then
    as_ln_s='ln -s'
    # ... but there are two gotchas:
    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
    # In both cases, we have to default to `cp -p'.
    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
      as_ln_s='cp -p'
  elif ln conf$$.file conf$$ 2>/dev/null; then
    as_ln_s=ln
  else
    as_ln_s='cp -p'
  fi
else
  as_ln_s='cp -p'
fi
rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
rmdir conf$$.dir 2>/dev/null

if mkdir -p . 2>/dev/null; then
  as_mkdir_p=:
else
  test -d ./-p && rmdir ./-p
  as_mkdir_p=false
fi

if test -x / >/dev/null 2>&1; then
  as_test_x='test -x'
else
  if ls -dL / >/dev/null 2>&1; then
    as_ls_L_option=L
  else
    as_ls_L_option=
  fi
  as_test_x='
    eval sh -c '\''
      if test -d "$1"; then
	test -d "$1/.";
      else
	case $1 in
	-*)set "./$1";;
	esac;
	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
	???[sx]*):;;*)false;;esac;fi
    '\'' sh
  '
fi
as_executable_p=$as_test_x

# Sed expression to map a string onto a valid CPP name.
as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"

# Sed expression to map a string onto a valid variable name.
as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"


as_awk_strverscmp='
  # Use only awk features that work with 7th edition Unix awk (1978).
  # My, what an old awk you have, Mr. Solaris!
  END {
    while (length(v1) && length(v2)) {
      # Set d1 to be the next thing to compare from v1, and likewise for d2.
      # Normally this is a single character, but if v1 and v2 contain digits,
      # compare them as integers and fractions as strverscmp does.
      if (v1 ~ /^[0-9]/ && v2 ~ /^[0-9]/) {
	# Split v1 and v2 into their leading digit string components d1 and d2,
	# and advance v1 and v2 past the leading digit strings.
	for (len1 = 1; substr(v1, len1 + 1) ~ /^[0-9]/; len1++) continue
	for (len2 = 1; substr(v2, len2 + 1) ~ /^[0-9]/; len2++) continue
	d1 = substr(v1, 1, len1); v1 = substr(v1, len1 + 1)
	d2 = substr(v2, 1, len2); v2 = substr(v2, len2 + 1)
	if (d1 ~ /^0/) {
	  if (d2 ~ /^0/) {
	    # Compare two fractions.
	    while (d1 ~ /^0/ && d2 ~ /^0/) {
	      d1 = substr(d1, 2); len1--
	      d2 = substr(d2, 2); len2--
	    }
	    if (len1 != len2 && ! (len1 && len2 && substr(d1, 1, 1) == substr(d2, 1, 1))) {
	      # The two components differ in length, and the common prefix
	      # contains only leading zeros.  Consider the longer to be less.
	      d1 = -len1
	      d2 = -len2
	    } else {
	      # Otherwise, compare as strings.
	      d1 = "x" d1
	      d2 = "x" d2
	    }
	  } else {
	    # A fraction is less than an integer.
	    exit 1
	  }
	} else {
	  if (d2 ~ /^0/) {
	    # An integer is greater than a fraction.
	    exit 2
	  } else {
	    # Compare two integers.
	    d1 += 0
	    d2 += 0
	  }
	}
      } else {
	# The normal case, without worrying about digits.
	d1 = substr(v1, 1, 1); v1 = substr(v1, 2)
	d2 = substr(v2, 1, 1); v2 = substr(v2, 2)
      }
      if (d1 < d2) exit 1
      if (d1 > d2) exit 2
    }
    # Beware Solaris /usr/xgp4/bin/awk (at least through Solaris 10),
    # which mishandles some comparisons of empty strings to integers.
    if (length(v2)) exit 1
    if (length(v1)) exit 2
  }
'

exec 7<&0 </dev/null 6>&1

# Name of the host.
# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
# so uname gets run too.
ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`

#
# Initializations.
#
ac_default_prefix=/usr/local
ac_clean_files=
ac_config_libobj_dir=.
LIBOBJS=
cross_compiling=no
subdirs=
MFLAGS=
MAKEFLAGS=
SHELL=${CONFIG_SHELL-/bin/sh}

# Identity of this package.
PACKAGE_NAME='Lustre'
PACKAGE_TARNAME='lustre'
PACKAGE_VERSION='LUSTRE_VERSION'
PACKAGE_STRING='Lustre LUSTRE_VERSION'
PACKAGE_BUGREPORT='http://bugs.whamcloud.com/'

ac_unique_file="lustre/obdclass/obdo.c"
ac_default_prefix=/usr
# Factoring default headers for most tests.
ac_includes_default="\
#include <stdio.h>
#ifdef HAVE_SYS_TYPES_H
# include <sys/types.h>
#endif
#ifdef HAVE_SYS_STAT_H
# include <sys/stat.h>
#endif
#ifdef STDC_HEADERS
# include <stdlib.h>
# include <stddef.h>
#else
# ifdef HAVE_STDLIB_H
#  include <stdlib.h>
# endif
#endif
#ifdef HAVE_STRING_H
# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
#  include <memory.h>
# endif
# include <string.h>
#endif
#ifdef HAVE_STRINGS_H
# include <strings.h>
#endif
#ifdef HAVE_INTTYPES_H
# include <inttypes.h>
#endif
#ifdef HAVE_STDINT_H
# include <stdint.h>
#endif
#ifdef HAVE_UNISTD_H
# include <unistd.h>
#endif"

enable_option_checking=no
ac_subst_vars='am__EXEEXT_FALSE
am__EXEEXT_TRUE
LTLIBOBJS
LIBOBJS
MOSTLYCLEANFILES
ac_configure_args
LLITE_LLOOP_FALSE
LLITE_LLOOP_TRUE
LIBPTHREAD_FALSE
LIBPTHREAD_TRUE
GSS_PIPEFS_FALSE
GSS_PIPEFS_TRUE
GSS_KEYRING_FALSE
GSS_KEYRING_TRUE
GSS_FALSE
GSS_TRUE
EXT2FS_DEVEL_FALSE
EXT2FS_DEVEL_TRUE
BLKID_FALSE
BLKID_TRUE
SPLIT_FALSE
SPLIT_TRUE
SERVER_FALSE
SERVER_TRUE
CLIENT_FALSE
CLIENT_TRUE
MPITESTS_FALSE
MPITESTS_TRUE
LIBLUSTRE_TESTS_FALSE
LIBLUSTRE_TESTS_TRUE
LIBLUSTRE_FALSE
LIBLUSTRE_TRUE
BUILD_USOCKLND_FALSE
BUILD_USOCKLND_TRUE
BUILD_PTLLND_FALSE
BUILD_PTLLND_TRUE
BUILD_GNILND_RCA_FALSE
BUILD_GNILND_RCA_TRUE
BUILD_GNILND_FALSE
BUILD_GNILND_TRUE
BUILD_RALND_FALSE
BUILD_RALND_TRUE
BUILD_O2IBLND_FALSE
BUILD_O2IBLND_TRUE
BUILD_MXLND_FALSE
BUILD_MXLND_TRUE
BUILD_QSWLND_FALSE
BUILD_QSWLND_TRUE
SYSIO
LIBSYSIO_SUBDIR
HAVE_PCLMULQDQ_FALSE
HAVE_PCLMULQDQ_TRUE
USE_QUILT_FALSE
USE_QUILT_TRUE
USES_DPKG_FALSE
USES_DPKG_TRUE
SUNOS_FALSE
SUNOS_TRUE
DARWIN_FALSE
DARWIN_TRUE
LINUX_FALSE
LINUX_TRUE
INIT_SCRIPTS_FALSE
INIT_SCRIPTS_TRUE
DOC_FALSE
DOC_TRUE
TESTS_FALSE
TESTS_TRUE
UTILS_FALSE
UTILS_TRUE
MODULES_FALSE
MODULES_TRUE
mibdir
agentdir
NET_SNMP_LIBS
NET_SNMP_CFLAGS
NET_SNMP_CONFIG
SELINUX
ZLIB
USOCKLND
UPTLLND
CAP_LIBS
LIBWRAP
LIBREADLINE
ENABLE_LIBPTHREAD
PTHREAD_LIBS
LIBEFENCE
MPICC_WRAPPER
PFSCK
E2FSCK
DUMPE2FS
E2LABEL
TUNE2FS
DEBUGFS
MKE2FS
E2FSPROGS
BUILD_LUSTREIOKIT_FALSE
BUILD_LUSTREIOKIT_TRUE
LUSTREIOKIT_SUBDIR
SNMP_SUBDIR
SNMP_DIST_SUBDIR
subdirs
ZFS_ENABLED_FALSE
ZFS_ENABLED_TRUE
ZFS_LIBZFS_INCLUDE
ZFS_SYMBOLS
ZFS_VERSION
ZFS_OBJ
ZFS
SPL_SYMBOLS
SPL_VERSION
SPL_OBJ
SPL
LDISKFS_ENABLED_FALSE
LDISKFS_ENABLED_TRUE
LDISKFS_SUBDIR
patch_avail
quilt_avail
LDISKFS_SERIES
macosdir
plistdir
kextdir
EXTRA_KLIBS
EXTRA_KLDFLAGS
GSSAPI_LIBS
K5VERS
KRBLDFLAGS
KRBCFLAGS
KRBLIBS
KRBDIR
EXT4_SRC_DIR
MXLND
MXLIBS
MXCPPFLAGS
PTLLND
PTLLNDCPPFLAGS
GNILND
GNILNDRCA
GNICPPFLAGS
RALND
RACPPFLAGS
O2IBLND
O2IBCPPFLAGS
EXTRA_LNET_INCLUDE
QSWLND
QSWCPPFLAGS
SYMVERFILE
modulenetdir
modulefsdir
moduledir
KMP_MODDIR
RHEL_KERNEL_VERSION
RELEASE
LINUXRELEASE
LINUX_VERSION
KMODEXT
MODULE_TARGET
CROSS_PATH
CROSS_VARS
CC_TARGET_ARCH
CONFIG_INCLUDE
VERSION_HDIR
AUTOCONF_HDIR
LINUX_CONFIG
LINUX_OBJ
LINUX
ENABLE_INIT_SCRIPTS
ENABLE_DOC
OSDADDON
EXTRA_KCFLAGS
LLCFLAGS
LLCPPFLAGS
EGREP
GREP
CPP
OBJDUMP
LD
RANLIB
pkgexampledir
demodir
rootsbindir
LUSTRE
INCLUDE_RULES
LIBCFS_INCLUDE_DIR
LIBCFS_SUBDIR
BUILDID
DOWNSTREAM_RELEASE
lb_target_os
ac_ct_AR
AR
am__fastdepCCAS_FALSE
am__fastdepCCAS_TRUE
CCASDEPMODE
CCASFLAGS
CCAS
am__fastdepCC_FALSE
am__fastdepCC_TRUE
CCDEPMODE
AMDEPBACKSLASH
AMDEP_FALSE
AMDEP_TRUE
am__quote
am__include
DEPDIR
OBJEXT
EXEEXT
ac_ct_CC
CPPFLAGS
LDFLAGS
CFLAGS
CC
MAINT
MAINTAINER_MODE_FALSE
MAINTAINER_MODE_TRUE
am__untar
am__tar
AMTAR
am__leading_dot
SET_MAKE
AWK
mkdir_p
MKDIR_P
INSTALL_STRIP_PROGRAM
STRIP
install_sh
MAKEINFO
AUTOHEADER
AUTOMAKE
AUTOCONF
ACLOCAL
VERSION
PACKAGE
CYGPATH_W
am__isrc
INSTALL_DATA
INSTALL_SCRIPT
INSTALL_PROGRAM
target_os
target_vendor
target_cpu
target
host_os
host_vendor
host_cpu
host
build_os
build_vendor
build_cpu
build
AC_LUSTRE_CLI_VER_OFFSET_WARN
AC_LUSTRE_LIB_VER_OFFSET_WARN
AC_LUSTRE_VER_ALLOWED_OFFSET
AC_LUSTRE_VERSION_STRING
AC_LUSTRE_FIX
AC_LUSTRE_PATCH
AC_LUSTRE_MINOR
AC_LUSTRE_MAJOR
target_alias
host_alias
build_alias
LIBS
ECHO_T
ECHO_N
ECHO_C
DEFS
mandir
localedir
libdir
psdir
pdfdir
dvidir
htmldir
infodir
docdir
oldincludedir
includedir
localstatedir
sharedstatedir
sysconfdir
datadir
datarootdir
libexecdir
sbindir
bindir
program_transform_name
prefix
exec_prefix
PACKAGE_BUGREPORT
PACKAGE_STRING
PACKAGE_VERSION
PACKAGE_TARNAME
PACKAGE_NAME
PATH_SEPARATOR
SHELL'
ac_subst_files=''
ac_user_opts='
enable_option_checking
enable_maintainer_mode
enable_dependency_tracking
enable_dist
with_downstream_release
with_osd
enable_doc
enable_utils
enable_tests
enable_client
enable_server
enable_modules
with_linux
with_linux_obj
with_linux_config
with_kernel_source_header
with_release
with_kmp_moddir
with_o2ib
enable_panic_dumplog
enable_affinity
enable_backoff
with_qsnet
enable_gni
with_portals
with_mx
enable_pinger
enable_checksum
enable_liblustre_recovery
enable_health_write
enable_lru_resize
enable_gss
enable_gss_keyring
with_krb5
with_ldiskfs
enable_ldiskfs
enable_quilt
with_zfs
with_spl
with_spl_obj
with_zfs_obj
with_zfs_devel
enable_split
enable_libcfs_cdebug
enable_libcfs_trace
enable_libcfs_assert
enable_quota
with_sysio
enable_iokit
with_ldiskfsprogs
enable_liblustre
enable_liblustre_tests
enable_liblustre_acl
enable_mpitests
enable_efence
enable_libpthread
enable_readline
enable_libwrap
enable_sysio_init
enable_urandom
with_max_payload_mb
enable_usocklnd
with_obd_buffer_size
with_mds_max_threads
enable_mindf
enable_fail_alloc
enable_invariants
enable_lu_ref
enable_pgstate_track
enable_snmp
'
      ac_precious_vars='build_alias
host_alias
target_alias
CC
CFLAGS
LDFLAGS
LIBS
CPPFLAGS
CCAS
CCASFLAGS
CPP'
ac_subdirs_all='libsysio'

# Initialize some variables set by options.
ac_init_help=
ac_init_version=false
ac_unrecognized_opts=
ac_unrecognized_sep=
# The variables have the same names as the options, with
# dashes changed to underlines.
cache_file=/dev/null
exec_prefix=NONE
no_create=
no_recursion=
prefix=NONE
program_prefix=NONE
program_suffix=NONE
program_transform_name=s,x,x,
silent=
site=
srcdir=
verbose=
x_includes=NONE
x_libraries=NONE

# Installation directory options.
# These are left unexpanded so users can "make install exec_prefix=/foo"
# and all the variables that are supposed to be based on exec_prefix
# by default will actually change.
# Use braces instead of parens because sh, perl, etc. also accept them.
# (The list follows the same order as the GNU Coding Standards.)
bindir='${exec_prefix}/bin'
sbindir='${exec_prefix}/sbin'
libexecdir='${exec_prefix}/libexec'
datarootdir='${prefix}/share'
datadir='${datarootdir}'
sysconfdir='${prefix}/etc'
sharedstatedir='${prefix}/com'
localstatedir='${prefix}/var'
includedir='${prefix}/include'
oldincludedir='/usr/include'
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
infodir='${datarootdir}/info'
htmldir='${docdir}'
dvidir='${docdir}'
pdfdir='${docdir}'
psdir='${docdir}'
libdir='${exec_prefix}/lib'
localedir='${datarootdir}/locale'
mandir='${datarootdir}/man'

ac_prev=
ac_dashdash=
for ac_option
do
  # If the previous option needs an argument, assign it.
  if test -n "$ac_prev"; then
    eval $ac_prev=\$ac_option
    ac_prev=
    continue
  fi

  case $ac_option in
  *=*)	ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
  *)	ac_optarg=yes ;;
  esac

  # Accept the important Cygnus configure options, so we can diagnose typos.

  case $ac_dashdash$ac_option in
  --)
    ac_dashdash=yes ;;

  -bindir | --bindir | --bindi | --bind | --bin | --bi)
    ac_prev=bindir ;;
  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
    bindir=$ac_optarg ;;

  -build | --build | --buil | --bui | --bu)
    ac_prev=build_alias ;;
  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
    build_alias=$ac_optarg ;;

  -cache-file | --cache-file | --cache-fil | --cache-fi \
  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
    ac_prev=cache_file ;;
  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
    cache_file=$ac_optarg ;;

  --config-cache | -C)
    cache_file=config.cache ;;

  -datadir | --datadir | --datadi | --datad)
    ac_prev=datadir ;;
  -datadir=* | --datadir=* | --datadi=* | --datad=*)
    datadir=$ac_optarg ;;

  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
  | --dataroo | --dataro | --datar)
    ac_prev=datarootdir ;;
  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
    datarootdir=$ac_optarg ;;

  -disable-* | --disable-*)
    ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
    # Reject names that are not valid shell variable names.
    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
      { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
   { (exit 1); exit 1; }; }
    ac_useropt_orig=$ac_useropt
    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
    case $ac_user_opts in
      *"
"enable_$ac_useropt"
"*) ;;
      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
	 ac_unrecognized_sep=', ';;
    esac
    eval enable_$ac_useropt=no ;;

  -docdir | --docdir | --docdi | --doc | --do)
    ac_prev=docdir ;;
  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
    docdir=$ac_optarg ;;

  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
    ac_prev=dvidir ;;
  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
    dvidir=$ac_optarg ;;

  -enable-* | --enable-*)
    ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
    # Reject names that are not valid shell variable names.
    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
      { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
   { (exit 1); exit 1; }; }
    ac_useropt_orig=$ac_useropt
    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
    case $ac_user_opts in
      *"
"enable_$ac_useropt"
"*) ;;
      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
	 ac_unrecognized_sep=', ';;
    esac
    eval enable_$ac_useropt=\$ac_optarg ;;

  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
  | --exec | --exe | --ex)
    ac_prev=exec_prefix ;;
  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
  | --exec=* | --exe=* | --ex=*)
    exec_prefix=$ac_optarg ;;

  -gas | --gas | --ga | --g)
    # Obsolete; use --with-gas.
    with_gas=yes ;;

  -help | --help | --hel | --he | -h)
    ac_init_help=long ;;
  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
    ac_init_help=recursive ;;
  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
    ac_init_help=short ;;

  -host | --host | --hos | --ho)
    ac_prev=host_alias ;;
  -host=* | --host=* | --hos=* | --ho=*)
    host_alias=$ac_optarg ;;

  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
    ac_prev=htmldir ;;
  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
  | --ht=*)
    htmldir=$ac_optarg ;;

  -includedir | --includedir | --includedi | --included | --include \
  | --includ | --inclu | --incl | --inc)
    ac_prev=includedir ;;
  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
  | --includ=* | --inclu=* | --incl=* | --inc=*)
    includedir=$ac_optarg ;;

  -infodir | --infodir | --infodi | --infod | --info | --inf)
    ac_prev=infodir ;;
  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
    infodir=$ac_optarg ;;

  -libdir | --libdir | --libdi | --libd)
    ac_prev=libdir ;;
  -libdir=* | --libdir=* | --libdi=* | --libd=*)
    libdir=$ac_optarg ;;

  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
  | --libexe | --libex | --libe)
    ac_prev=libexecdir ;;
  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
  | --libexe=* | --libex=* | --libe=*)
    libexecdir=$ac_optarg ;;

  -localedir | --localedir | --localedi | --localed | --locale)
    ac_prev=localedir ;;
  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
    localedir=$ac_optarg ;;

  -localstatedir | --localstatedir | --localstatedi | --localstated \
  | --localstate | --localstat | --localsta | --localst | --locals)
    ac_prev=localstatedir ;;
  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
    localstatedir=$ac_optarg ;;

  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
    ac_prev=mandir ;;
  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
    mandir=$ac_optarg ;;

  -nfp | --nfp | --nf)
    # Obsolete; use --without-fp.
    with_fp=no ;;

  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
  | --no-cr | --no-c | -n)
    no_create=yes ;;

  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
    no_recursion=yes ;;

  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
  | --oldin | --oldi | --old | --ol | --o)
    ac_prev=oldincludedir ;;
  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
    oldincludedir=$ac_optarg ;;

  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
    ac_prev=prefix ;;
  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
    prefix=$ac_optarg ;;

  -program-prefix | --program-prefix | --program-prefi | --program-pref \
  | --program-pre | --program-pr | --program-p)
    ac_prev=program_prefix ;;
  -program-prefix=* | --program-prefix=* | --program-prefi=* \
  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
    program_prefix=$ac_optarg ;;

  -program-suffix | --program-suffix | --program-suffi | --program-suff \
  | --program-suf | --program-su | --program-s)
    ac_prev=program_suffix ;;
  -program-suffix=* | --program-suffix=* | --program-suffi=* \
  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
    program_suffix=$ac_optarg ;;

  -program-transform-name | --program-transform-name \
  | --program-transform-nam | --program-transform-na \
  | --program-transform-n | --program-transform- \
  | --program-transform | --program-transfor \
  | --program-transfo | --program-transf \
  | --program-trans | --program-tran \
  | --progr-tra | --program-tr | --program-t)
    ac_prev=program_transform_name ;;
  -program-transform-name=* | --program-transform-name=* \
  | --program-transform-nam=* | --program-transform-na=* \
  | --program-transform-n=* | --program-transform-=* \
  | --program-transform=* | --program-transfor=* \
  | --program-transfo=* | --program-transf=* \
  | --program-trans=* | --program-tran=* \
  | --progr-tra=* | --program-tr=* | --program-t=*)
    program_transform_name=$ac_optarg ;;

  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
    ac_prev=pdfdir ;;
  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
    pdfdir=$ac_optarg ;;

  -psdir | --psdir | --psdi | --psd | --ps)
    ac_prev=psdir ;;
  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
    psdir=$ac_optarg ;;

  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  | -silent | --silent | --silen | --sile | --sil)
    silent=yes ;;

  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
    ac_prev=sbindir ;;
  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
  | --sbi=* | --sb=*)
    sbindir=$ac_optarg ;;

  -sharedstatedir | --sharedstatedir | --sharedstatedi \
  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
  | --sharedst | --shareds | --shared | --share | --shar \
  | --sha | --sh)
    ac_prev=sharedstatedir ;;
  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
  | --sha=* | --sh=*)
    sharedstatedir=$ac_optarg ;;

  -site | --site | --sit)
    ac_prev=site ;;
  -site=* | --site=* | --sit=*)
    site=$ac_optarg ;;

  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
    ac_prev=srcdir ;;
  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
    srcdir=$ac_optarg ;;

  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
  | --syscon | --sysco | --sysc | --sys | --sy)
    ac_prev=sysconfdir ;;
  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
    sysconfdir=$ac_optarg ;;

  -target | --target | --targe | --targ | --tar | --ta | --t)
    ac_prev=target_alias ;;
  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
    target_alias=$ac_optarg ;;

  -v | -verbose | --verbose | --verbos | --verbo | --verb)
    verbose=yes ;;

  -version | --version | --versio | --versi | --vers | -V)
    ac_init_version=: ;;

  -with-* | --with-*)
    ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
    # Reject names that are not valid shell variable names.
    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
      { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
   { (exit 1); exit 1; }; }
    ac_useropt_orig=$ac_useropt
    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
    case $ac_user_opts in
      *"
"with_$ac_useropt"
"*) ;;
      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
	 ac_unrecognized_sep=', ';;
    esac
    eval with_$ac_useropt=\$ac_optarg ;;

  -without-* | --without-*)
    ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
    # Reject names that are not valid shell variable names.
    expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
      { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
   { (exit 1); exit 1; }; }
    ac_useropt_orig=$ac_useropt
    ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
    case $ac_user_opts in
      *"
"with_$ac_useropt"
"*) ;;
      *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
	 ac_unrecognized_sep=', ';;
    esac
    eval with_$ac_useropt=no ;;

  --x)
    # Obsolete; use --with-x.
    with_x=yes ;;

  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
  | --x-incl | --x-inc | --x-in | --x-i)
    ac_prev=x_includes ;;
  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
    x_includes=$ac_optarg ;;

  -x-libraries | --x-libraries | --x-librarie | --x-librari \
  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
    ac_prev=x_libraries ;;
  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
    x_libraries=$ac_optarg ;;

  -*) { $as_echo "$as_me: error: unrecognized option: $ac_option
Try \`$0 --help' for more information." >&2
   { (exit 1); exit 1; }; }
    ;;

  *=*)
    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
    # Reject names that are not valid shell variable names.
    expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
      { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2
   { (exit 1); exit 1; }; }
    eval $ac_envvar=\$ac_optarg
    export $ac_envvar ;;

  *)
    # FIXME: should be removed in autoconf 3.0.
    $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
      $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
    ;;

  esac
done

if test -n "$ac_prev"; then
  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
  { $as_echo "$as_me: error: missing argument to $ac_option" >&2
   { (exit 1); exit 1; }; }
fi

if test -n "$ac_unrecognized_opts"; then
  case $enable_option_checking in
    no) ;;
    fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2
   { (exit 1); exit 1; }; } ;;
    *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
  esac
fi

# Check all directory arguments for consistency.
for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
		datadir sysconfdir sharedstatedir localstatedir includedir \
		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
		libdir localedir mandir
do
  eval ac_val=\$$ac_var
  # Remove trailing slashes.
  case $ac_val in
    */ )
      ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
      eval $ac_var=\$ac_val;;
  esac
  # Be sure to have absolute directory names.
  case $ac_val in
    [\\/$]* | ?:[\\/]* )  continue;;
    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
  esac
  { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
   { (exit 1); exit 1; }; }
done

# There might be people who depend on the old broken behavior: `$host'
# used to hold the argument of --host etc.
# FIXME: To remove some day.
build=$build_alias
host=$host_alias
target=$target_alias

# FIXME: To remove some day.
if test "x$host_alias" != x; then
  if test "x$build_alias" = x; then
    cross_compiling=maybe
    $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
    If a cross compiler is detected then cross compile mode will be used." >&2
  elif test "x$build_alias" != "x$host_alias"; then
    cross_compiling=yes
  fi
fi

ac_tool_prefix=
test -n "$host_alias" && ac_tool_prefix=$host_alias-

test "$silent" = yes && exec 6>/dev/null


ac_pwd=`pwd` && test -n "$ac_pwd" &&
ac_ls_di=`ls -di .` &&
ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
  { $as_echo "$as_me: error: working directory cannot be determined" >&2
   { (exit 1); exit 1; }; }
test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
  { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
   { (exit 1); exit 1; }; }


# Find the source files, if location was not specified.
if test -z "$srcdir"; then
  ac_srcdir_defaulted=yes
  # Try the directory containing this script, then the parent directory.
  ac_confdir=`$as_dirname -- "$as_myself" ||
$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
	 X"$as_myself" : 'X\(//\)[^/]' \| \
	 X"$as_myself" : 'X\(//\)$' \| \
	 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X"$as_myself" |
    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)[^/].*/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\).*/{
	    s//\1/
	    q
	  }
	  s/.*/./; q'`
  srcdir=$ac_confdir
  if test ! -r "$srcdir/$ac_unique_file"; then
    srcdir=..
  fi
else
  ac_srcdir_defaulted=no
fi
if test ! -r "$srcdir/$ac_unique_file"; then
  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
  { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
   { (exit 1); exit 1; }; }
fi
ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
ac_abs_confdir=`(
	cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2
   { (exit 1); exit 1; }; }
	pwd)`
# When building in place, set srcdir=.
if test "$ac_abs_confdir" = "$ac_pwd"; then
  srcdir=.
fi
# Remove unnecessary trailing slashes from srcdir.
# Double slashes in file names in object file debugging info
# mess up M-x gdb in Emacs.
case $srcdir in
*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
esac
for ac_var in $ac_precious_vars; do
  eval ac_env_${ac_var}_set=\${${ac_var}+set}
  eval ac_env_${ac_var}_value=\$${ac_var}
  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
  eval ac_cv_env_${ac_var}_value=\$${ac_var}
done

#
# Report the --help message.
#
if test "$ac_init_help" = "long"; then
  # Omit some internal or obsolete options to make the list less imposing.
  # This message is too long to be a string in the A/UX 3.1 sh.
  cat <<_ACEOF
\`configure' configures Lustre LUSTRE_VERSION to adapt to many kinds of systems.

Usage: $0 [OPTION]... [VAR=VALUE]...

To assign environment variables (e.g., CC, CFLAGS...), specify them as
VAR=VALUE.  See below for descriptions of some of the useful variables.

Defaults for the options are specified in brackets.

Configuration:
  -h, --help              display this help and exit
      --help=short        display options specific to this package
      --help=recursive    display the short help of all the included packages
  -V, --version           display version information and exit
  -q, --quiet, --silent   do not print \`checking...' messages
      --cache-file=FILE   cache test results in FILE [disabled]
  -C, --config-cache      alias for \`--cache-file=config.cache'
  -n, --no-create         do not create output files
      --srcdir=DIR        find the sources in DIR [configure dir or \`..']

Installation directories:
  --prefix=PREFIX         install architecture-independent files in PREFIX
                          [$ac_default_prefix]
  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
                          [PREFIX]

By default, \`make install' will install all the files in
\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
an installation prefix other than \`$ac_default_prefix' using \`--prefix',
for instance \`--prefix=\$HOME'.

For better control, use the options below.

Fine tuning of the installation directories:
  --bindir=DIR            user executables [EPREFIX/bin]
  --sbindir=DIR           system admin executables [EPREFIX/sbin]
  --libexecdir=DIR        program executables [EPREFIX/libexec]
  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
  --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
  --libdir=DIR            object code libraries [EPREFIX/lib]
  --includedir=DIR        C header files [PREFIX/include]
  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
  --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
  --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
  --infodir=DIR           info documentation [DATAROOTDIR/info]
  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
  --mandir=DIR            man documentation [DATAROOTDIR/man]
  --docdir=DIR            documentation root [DATAROOTDIR/doc/lustre]
  --htmldir=DIR           html documentation [DOCDIR]
  --dvidir=DIR            dvi documentation [DOCDIR]
  --pdfdir=DIR            pdf documentation [DOCDIR]
  --psdir=DIR             ps documentation [DOCDIR]
_ACEOF

  cat <<\_ACEOF

Program names:
  --program-prefix=PREFIX            prepend PREFIX to installed program names
  --program-suffix=SUFFIX            append SUFFIX to installed program names
  --program-transform-name=PROGRAM   run sed PROGRAM on installed program names

System types:
  --build=BUILD     configure for building on BUILD [guessed]
  --host=HOST       cross-compile to build programs to run on HOST [BUILD]
  --target=TARGET   configure for building compilers for TARGET [HOST]
_ACEOF
fi

if test -n "$ac_init_help"; then
  case $ac_init_help in
     short | recursive ) echo "Configuration of Lustre LUSTRE_VERSION:";;
   esac
  cat <<\_ACEOF

Optional Features:
  --disable-option-checking  ignore unrecognized --enable/--with options
  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  --disable-maintainer-mode  disable make rules and dependencies not useful
			  (and sometimes confusing) to the casual installer
  --disable-dependency-tracking  speeds up one-time build
  --enable-dependency-tracking   do not reject slow dependency extractors
  --enable-dist           only configure enough for make dist
  --disable-doc           skip creation of pdf documentation
  --disable-utils         disable building of Lustre utility programs
  --disable-tests         disable building of Lustre tests
  --disable-client        disable Lustre client support
  --disable-server        disable Lustre server support
  --disable-modules       disable building of Lustre kernel modules
  --enable-panic_dumplog  enable panic_dumplog
  --disable-affinity      disable process/irq affinity
  --disable-backoff       disable socknal tunable backoff
  --enable-gni            enable GNI lnd
  --disable-pinger        disable recovery pinger support
  --disable-checksum      disable data checksum support
  --disable-liblustre-recovery
                          disable liblustre recovery support
  --enable-health_write   enable disk writes when doing health check
  --enable-lru-resize     enable lru resize support
  --enable-gss            enable gss/krb5 support
  --disable-gss-keyring   disable gss keyring backend
  --disable-ldiskfs       disable ldiskfs osd (default is enable)
  --disable-quilt         disable use of quilt for ldiskfs
  --enable-split          enable split support
  --disable-libcfs-cdebug disable libcfs CDEBUG, CWARN
  --disable-libcfs-trace  disable libcfs ENTRY/EXIT
  --disable-libcfs-assert disable libcfs LASSERT, LASSERTF
  --enable-quota          enable quota support
  --disable-iokit         disable iokit (default is enable)
  --disable-liblustre     disable building of Lustre library
  --enable-liblustre-tests
                          enable liblustre tests, if --disable-tests is used
  --disable-liblustre-acl disable ACL support for liblustre
  --enable-mpitests=yes|no|mpicc wrapper
                          include mpi tests
  --enable-efence         use efence library
  --disable-libpthread    disable libpthread
  --disable-readline      disable readline support
  --enable-libwrap        use TCP wrappers
  --disable-sysio-init    call sysio init functions when initializing
                          liblustre
  --disable-urandom       disable use of /dev/urandom for liblustre
  --disable-usocklnd      disable usocklnd
  --enable-mindf          Make statfs report the minimum available space on
                          any single OST instead of the sum of free space on
                          all OSTs
  --disable-fail-alloc    disable randomly alloc failure
  --enable-invariants     enable invariant checking (cpu intensive)
  --enable-lu_ref         enable lu_ref reference tracking code
  --enable-pgstate-track  enable page state tracking
  --enable-snmp           require SNMP support (default=auto)

Optional Packages:
  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  --with-downstream-release=string
                          set a string in the BUILD_VERSION and RPM Release:
                          (default is nothing)
  --with-osd=path         set path to optional osd
  --with-linux=path       set path to Linux source
                          (default=/lib/modules/$(uname
                          -r)/{source,build},/usr/src/linux)
  --with-linux-obj=path   set path to Linux objects dir
                          (default=/lib/modules/$(uname
                          -r)/build,/usr/src/linux)
  --with-linux-config=path
                          set path to Linux .conf (default=$LINUX_OBJ/.config)
  --with-kernel-source-header=path
                          Use a different kernel version header. Consult
                          build/README.kernel-source for details.
  --with-release=string   set the release string (default=$kvers_YYYYMMDDhhmm)
  --with-kmp-moddir=string
                          set the kmod updates or extra directory
  --with-o2ib=path        build o2iblnd against path
  --with-qsnet=path       set path to qsnet source (default=$LINUX)
  --with-portals=path     set path to portals
  --with-mx=path          build mxlnd against path
  --with-krb5=DIR         use Kerberos v5 installation in DIR

  --with-zfs=PATH         Path to zfs source
  --with-spl=PATH         Path to spl source
  --with-spl-obj=PATH     Path to spl build objects
  --with-zfs-obj=PATH     Path to zfs build objects
  --with-zfs-devel=PATH   Path to zfs development headers
  --with-sysio=path       set path to libsysio source (default is included
                          libsysio)
  --with-ldiskfsprogs     use alternate names for ldiskfs-enabled e2fsprogs
  --with-max-payload-mb=MBytes
                          set maximum lnet payload in MBytes
  --with-obd-buffer-size=size
                          set lctl ioctl maximum bytes (default=8192)
  --with-mds-max-threads=count
                          maximum threads available on the MDS: (default=512)

Some influential environment variables:
  CC          C compiler command
  CFLAGS      C compiler flags
  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
              nonstandard directory <lib dir>
  LIBS        libraries to pass to the linker, e.g. -l<library>
  CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
              you have headers in a nonstandard directory <include dir>
  CCAS        assembler compiler command (defaults to CC)
  CCASFLAGS   assembler compiler flags (defaults to CFLAGS)
  CPP         C preprocessor

Use these variables to override the choices made by `configure' or to help
it to find libraries and programs with nonstandard names/locations.

Report bugs to <http://bugs.whamcloud.com/>.
_ACEOF
ac_status=$?
fi

if test "$ac_init_help" = "recursive"; then
  # If there are subdirs, report their specific --help.
  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
    test -d "$ac_dir" ||
      { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
      continue
    ac_builddir=.

case "$ac_dir" in
.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
*)
  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
  # A ".." for each directory in $ac_dir_suffix.
  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
  case $ac_top_builddir_sub in
  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
  esac ;;
esac
ac_abs_top_builddir=$ac_pwd
ac_abs_builddir=$ac_pwd$ac_dir_suffix
# for backward compatibility:
ac_top_builddir=$ac_top_build_prefix

case $srcdir in
  .)  # We are building in place.
    ac_srcdir=.
    ac_top_srcdir=$ac_top_builddir_sub
    ac_abs_top_srcdir=$ac_pwd ;;
  [\\/]* | ?:[\\/]* )  # Absolute name.
    ac_srcdir=$srcdir$ac_dir_suffix;
    ac_top_srcdir=$srcdir
    ac_abs_top_srcdir=$srcdir ;;
  *) # Relative name.
    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
    ac_top_srcdir=$ac_top_build_prefix$srcdir
    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
esac
ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix

    cd "$ac_dir" || { ac_status=$?; continue; }
    # Check for guested configure.
    if test -f "$ac_srcdir/configure.gnu"; then
      echo &&
      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
    elif test -f "$ac_srcdir/configure"; then
      echo &&
      $SHELL "$ac_srcdir/configure" --help=recursive
    else
      $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
    fi || ac_status=$?
    cd "$ac_pwd" || { ac_status=$?; break; }
  done
fi

test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
  cat <<\_ACEOF
Lustre configure LUSTRE_VERSION
generated by GNU Autoconf 2.63

Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
This configure script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it.
_ACEOF
  exit
fi
cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by Lustre $as_me LUSTRE_VERSION, which was
generated by GNU Autoconf 2.63.  Invocation command line was

  $ $0 $@

_ACEOF
exec 5>>config.log
{
cat <<_ASUNAME
## --------- ##
## Platform. ##
## --------- ##

hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
uname -m = `(uname -m) 2>/dev/null || echo unknown`
uname -r = `(uname -r) 2>/dev/null || echo unknown`
uname -s = `(uname -s) 2>/dev/null || echo unknown`
uname -v = `(uname -v) 2>/dev/null || echo unknown`

/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`

/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`

_ASUNAME

as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  $as_echo "PATH: $as_dir"
done
IFS=$as_save_IFS

} >&5

cat >&5 <<_ACEOF


## ----------- ##
## Core tests. ##
## ----------- ##

_ACEOF


# Keep a trace of the command line.
# Strip out --no-create and --no-recursion so they do not pile up.
# Strip out --silent because we don't want to record it for future runs.
# Also quote any args containing shell meta-characters.
# Make two passes to allow for proper duplicate-argument suppression.
ac_configure_args=
ac_configure_args0=
ac_configure_args1=
ac_must_keep_next=false
for ac_pass in 1 2
do
  for ac_arg
  do
    case $ac_arg in
    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
    | -silent | --silent | --silen | --sile | --sil)
      continue ;;
    *\'*)
      ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
    esac
    case $ac_pass in
    1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
    2)
      ac_configure_args1="$ac_configure_args1 '$ac_arg'"
      if test $ac_must_keep_next = true; then
	ac_must_keep_next=false # Got value, back to normal.
      else
	case $ac_arg in
	  *=* | --config-cache | -C | -disable-* | --disable-* \
	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
	  | -with-* | --with-* | -without-* | --without-* | --x)
	    case "$ac_configure_args0 " in
	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
	    esac
	    ;;
	  -* ) ac_must_keep_next=true ;;
	esac
      fi
      ac_configure_args="$ac_configure_args '$ac_arg'"
      ;;
    esac
  done
done
$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }

# When interrupted or exit'd, cleanup temporary files, and complete
# config.log.  We remove comments because anyway the quotes in there
# would cause problems or look ugly.
# WARNING: Use '\'' to represent an apostrophe within the trap.
# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
trap 'exit_status=$?
  # Save into config.log some information that might help in debugging.
  {
    echo

    cat <<\_ASBOX
## ---------------- ##
## Cache variables. ##
## ---------------- ##
_ASBOX
    echo
    # The following way of writing the cache mishandles newlines in values,
(
  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
    eval ac_val=\$$ac_var
    case $ac_val in #(
    *${as_nl}*)
      case $ac_var in #(
      *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
      esac
      case $ac_var in #(
      _ | IFS | as_nl) ;; #(
      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
      *) $as_unset $ac_var ;;
      esac ;;
    esac
  done
  (set) 2>&1 |
    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
    *${as_nl}ac_space=\ *)
      sed -n \
	"s/'\''/'\''\\\\'\'''\''/g;
	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
      ;; #(
    *)
      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
      ;;
    esac |
    sort
)
    echo

    cat <<\_ASBOX
## ----------------- ##
## Output variables. ##
## ----------------- ##
_ASBOX
    echo
    for ac_var in $ac_subst_vars
    do
      eval ac_val=\$$ac_var
      case $ac_val in
      *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
      esac
      $as_echo "$ac_var='\''$ac_val'\''"
    done | sort
    echo

    if test -n "$ac_subst_files"; then
      cat <<\_ASBOX
## ------------------- ##
## File substitutions. ##
## ------------------- ##
_ASBOX
      echo
      for ac_var in $ac_subst_files
      do
	eval ac_val=\$$ac_var
	case $ac_val in
	*\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
	esac
	$as_echo "$ac_var='\''$ac_val'\''"
      done | sort
      echo
    fi

    if test -s confdefs.h; then
      cat <<\_ASBOX
## ----------- ##
## confdefs.h. ##
## ----------- ##
_ASBOX
      echo
      cat confdefs.h
      echo
    fi
    test "$ac_signal" != 0 &&
      $as_echo "$as_me: caught signal $ac_signal"
    $as_echo "$as_me: exit $exit_status"
  } >&5
  rm -f core *.core core.conftest.* &&
    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
    exit $exit_status
' 0
for ac_signal in 1 2 13 15; do
  trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
done
ac_signal=0

# confdefs.h avoids OS command line length limits that DEFS can exceed.
rm -f -r conftest* confdefs.h

# Predefined preprocessor variables.

cat >>confdefs.h <<_ACEOF
#define PACKAGE_NAME "$PACKAGE_NAME"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define PACKAGE_VERSION "$PACKAGE_VERSION"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define PACKAGE_STRING "$PACKAGE_STRING"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
_ACEOF


# Let the site file select an alternate cache file if it wants to.
# Prefer an explicitly selected file to automatically selected ones.
ac_site_file1=NONE
ac_site_file2=NONE
if test -n "$CONFIG_SITE"; then
  ac_site_file1=$CONFIG_SITE
elif test "x$prefix" != xNONE; then
  ac_site_file1=$prefix/share/config.site
  ac_site_file2=$prefix/etc/config.site
else
  ac_site_file1=$ac_default_prefix/share/config.site
  ac_site_file2=$ac_default_prefix/etc/config.site
fi
for ac_site_file in "$ac_site_file1" "$ac_site_file2"
do
  test "x$ac_site_file" = xNONE && continue
  if test -r "$ac_site_file"; then
    { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
$as_echo "$as_me: loading site script $ac_site_file" >&6;}
    sed 's/^/| /' "$ac_site_file" >&5
    . "$ac_site_file"
  fi
done

if test -r "$cache_file"; then
  # Some versions of bash will fail to source /dev/null (special
  # files actually), so we avoid doing that.
  if test -f "$cache_file"; then
    { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
$as_echo "$as_me: loading cache $cache_file" >&6;}
    case $cache_file in
      [\\/]* | ?:[\\/]* ) . "$cache_file";;
      *)                      . "./$cache_file";;
    esac
  fi
else
  { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
$as_echo "$as_me: creating cache $cache_file" >&6;}
  >$cache_file
fi

# Check that the precious variables saved in the cache have kept the same
# value.
ac_cache_corrupted=false
for ac_var in $ac_precious_vars; do
  eval ac_old_set=\$ac_cv_env_${ac_var}_set
  eval ac_new_set=\$ac_env_${ac_var}_set
  eval ac_old_val=\$ac_cv_env_${ac_var}_value
  eval ac_new_val=\$ac_env_${ac_var}_value
  case $ac_old_set,$ac_new_set in
    set,)
      { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
      ac_cache_corrupted=: ;;
    ,set)
      { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
      ac_cache_corrupted=: ;;
    ,);;
    *)
      if test "x$ac_old_val" != "x$ac_new_val"; then
	# differences in whitespace do not lead to failure.
	ac_old_val_w=`echo x $ac_old_val`
	ac_new_val_w=`echo x $ac_new_val`
	if test "$ac_old_val_w" != "$ac_new_val_w"; then
	  { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
	  ac_cache_corrupted=:
	else
	  { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
	  eval $ac_var=\$ac_old_val
	fi
	{ $as_echo "$as_me:$LINENO:   former value:  \`$ac_old_val'" >&5
$as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
	{ $as_echo "$as_me:$LINENO:   current value: \`$ac_new_val'" >&5
$as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
      fi;;
  esac
  # Pass precious variables to config.status.
  if test "$ac_new_set" = set; then
    case $ac_new_val in
    *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
    *) ac_arg=$ac_var=$ac_new_val ;;
    esac
    case " $ac_configure_args " in
      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
      *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
    esac
  fi
done
if $ac_cache_corrupted; then
  { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
  { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
  { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
$as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
   { (exit 1); exit 1; }; }
fi

























ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
















AC_LUSTRE_MAJOR=2
AC_LUSTRE_MINOR=5
AC_LUSTRE_PATCH=1
AC_LUSTRE_FIX=0
AC_LUSTRE_VERSION_STRING=2.5.1
AC_LUSTRE_VER_ALLOWED_OFFSET="OBD_OCD_VERSION(0, 0, 1, 32)"
AC_LUSTRE_LIB_VER_OFFSET_WARN="OBD_OCD_VERSION(0, 0, 1, 32)"
AC_LUSTRE_CLI_VER_OFFSET_WARN="OBD_OCD_VERSION(0, 4, 50, 0)"











ac_aux_dir=
for ac_dir in config "$srcdir"/config; do
  if test -f "$ac_dir/install-sh"; then
    ac_aux_dir=$ac_dir
    ac_install_sh="$ac_aux_dir/install-sh -c"
    break
  elif test -f "$ac_dir/install.sh"; then
    ac_aux_dir=$ac_dir
    ac_install_sh="$ac_aux_dir/install.sh -c"
    break
  elif test -f "$ac_dir/shtool"; then
    ac_aux_dir=$ac_dir
    ac_install_sh="$ac_aux_dir/shtool install -c"
    break
  fi
done
if test -z "$ac_aux_dir"; then
  { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5
$as_echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;}
   { (exit 1); exit 1; }; }
fi

# These three variables are undocumented and unsupported,
# and are intended to be withdrawn in a future Autoconf release.
# They can cause serious problems if a builder's source tree is in a directory
# whose full name contains unusual characters.
ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.




if test "2.5.1" = "LUSTRE""_VERSION" ; then
	{ { $as_echo "$as_me:$LINENO: error: This script was not built with a version number." >&5
$as_echo "$as_me: error: This script was not built with a version number." >&2;}
   { (exit 1); exit 1; }; }
fi



libcfs_is_module=yes
ldiskfs_is_ext4=yes


# Make sure we can run config.sub.
$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
  { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
$as_echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
   { (exit 1); exit 1; }; }

{ $as_echo "$as_me:$LINENO: checking build system type" >&5
$as_echo_n "checking build system type... " >&6; }
if test "${ac_cv_build+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_build_alias=$build_alias
test "x$ac_build_alias" = x &&
  ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
test "x$ac_build_alias" = x &&
  { { $as_echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
$as_echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
   { (exit 1); exit 1; }; }
ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
  { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
$as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
   { (exit 1); exit 1; }; }

fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5
$as_echo "$ac_cv_build" >&6; }
case $ac_cv_build in
*-*-*) ;;
*) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
$as_echo "$as_me: error: invalid value of canonical build" >&2;}
   { (exit 1); exit 1; }; };;
esac
build=$ac_cv_build
ac_save_IFS=$IFS; IFS='-'
set x $ac_cv_build
shift
build_cpu=$1
build_vendor=$2
shift; shift
# Remember, the first character of IFS is used to create $*,
# except with old shells:
build_os=$*
IFS=$ac_save_IFS
case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac


{ $as_echo "$as_me:$LINENO: checking host system type" >&5
$as_echo_n "checking host system type... " >&6; }
if test "${ac_cv_host+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test "x$host_alias" = x; then
  ac_cv_host=$ac_cv_build
else
  ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
    { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
$as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
   { (exit 1); exit 1; }; }
fi

fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5
$as_echo "$ac_cv_host" >&6; }
case $ac_cv_host in
*-*-*) ;;
*) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
$as_echo "$as_me: error: invalid value of canonical host" >&2;}
   { (exit 1); exit 1; }; };;
esac
host=$ac_cv_host
ac_save_IFS=$IFS; IFS='-'
set x $ac_cv_host
shift
host_cpu=$1
host_vendor=$2
shift; shift
# Remember, the first character of IFS is used to create $*,
# except with old shells:
host_os=$*
IFS=$ac_save_IFS
case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac


{ $as_echo "$as_me:$LINENO: checking target system type" >&5
$as_echo_n "checking target system type... " >&6; }
if test "${ac_cv_target+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test "x$target_alias" = x; then
  ac_cv_target=$ac_cv_host
else
  ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
    { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $target_alias failed" >&5
$as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $target_alias failed" >&2;}
   { (exit 1); exit 1; }; }
fi

fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_target" >&5
$as_echo "$ac_cv_target" >&6; }
case $ac_cv_target in
*-*-*) ;;
*) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical target" >&5
$as_echo "$as_me: error: invalid value of canonical target" >&2;}
   { (exit 1); exit 1; }; };;
esac
target=$ac_cv_target
ac_save_IFS=$IFS; IFS='-'
set x $ac_cv_target
shift
target_cpu=$1
target_vendor=$2
shift; shift
# Remember, the first character of IFS is used to create $*,
# except with old shells:
target_os=$*
IFS=$ac_save_IFS
case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac


# The aliases save the names the user supplied, while $host etc.
# will get canonicalized.
test -n "$target_alias" &&
  test "$program_prefix$program_suffix$program_transform_name" = \
    NONENONEs,x,x, &&
  program_prefix=${target_alias}-

am__api_version='1.11'

# Find a good install program.  We prefer a C program (faster),
# so one script is as good as another.  But avoid the broken or
# incompatible versions:
# SysV /etc/install, /usr/sbin/install
# SunOS /usr/etc/install
# IRIX /sbin/install
# AIX /bin/install
# AmigaOS /C/install, which installs bootblocks on floppy discs
# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
# AFS /usr/afsws/bin/install, which mishandles nonexistent args
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# OS/2's system install, which has a completely different semantic
# ./install, which can be erroneously created by make from ./install.sh.
# Reject install programs that cannot install multiple files.
{ $as_echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
$as_echo_n "checking for a BSD-compatible install... " >&6; }
if test -z "$INSTALL"; then
if test "${ac_cv_path_install+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  # Account for people who put trailing slashes in PATH elements.
case $as_dir/ in
  ./ | .// | /cC/* | \
  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
  ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
  /usr/ucb/* ) ;;
  *)
    # OSF1 and SCO ODT 3.0 have their own names for install.
    # Don't use installbsd from OSF since it installs stuff as root
    # by default.
    for ac_prog in ginstall scoinst install; do
      for ac_exec_ext in '' $ac_executable_extensions; do
	if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
	  if test $ac_prog = install &&
	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
	    # AIX install.  It has an incompatible calling convention.
	    :
	  elif test $ac_prog = install &&
	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
	    # program-specific install script used by HP pwplus--don't use.
	    :
	  else
	    rm -rf conftest.one conftest.two conftest.dir
	    echo one > conftest.one
	    echo two > conftest.two
	    mkdir conftest.dir
	    if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
	      test -s conftest.one && test -s conftest.two &&
	      test -s conftest.dir/conftest.one &&
	      test -s conftest.dir/conftest.two
	    then
	      ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
	      break 3
	    fi
	  fi
	fi
      done
    done
    ;;
esac

done
IFS=$as_save_IFS

rm -rf conftest.one conftest.two conftest.dir

fi
  if test "${ac_cv_path_install+set}" = set; then
    INSTALL=$ac_cv_path_install
  else
    # As a last resort, use the slow shell script.  Don't cache a
    # value for INSTALL within a source directory, because that will
    # break other packages using the cache if that directory is
    # removed, or if the value is a relative name.
    INSTALL=$ac_install_sh
  fi
fi
{ $as_echo "$as_me:$LINENO: result: $INSTALL" >&5
$as_echo "$INSTALL" >&6; }

# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
# It thinks the first close brace ends the variable substitution.
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'

test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'

test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'

{ $as_echo "$as_me:$LINENO: checking whether build environment is sane" >&5
$as_echo_n "checking whether build environment is sane... " >&6; }
# Just in case
sleep 1
echo timestamp > conftest.file
# Reject unsafe characters in $srcdir or the absolute working directory
# name.  Accept space and tab only in the latter.
am_lf='
'
case `pwd` in
  *[\\\"\#\$\&\'\`$am_lf]*)
    { { $as_echo "$as_me:$LINENO: error: unsafe absolute working directory name" >&5
$as_echo "$as_me: error: unsafe absolute working directory name" >&2;}
   { (exit 1); exit 1; }; };;
esac
case $srcdir in
  *[\\\"\#\$\&\'\`$am_lf\ \	]*)
    { { $as_echo "$as_me:$LINENO: error: unsafe srcdir value: \`$srcdir'" >&5
$as_echo "$as_me: error: unsafe srcdir value: \`$srcdir'" >&2;}
   { (exit 1); exit 1; }; };;
esac

# Do `set' in a subshell so we don't clobber the current shell's
# arguments.  Must try -L first in case configure is actually a
# symlink; some systems play weird games with the mod time of symlinks
# (eg FreeBSD returns the mod time of the symlink's containing
# directory).
if (
   set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
   if test "$*" = "X"; then
      # -L didn't work.
      set X `ls -t "$srcdir/configure" conftest.file`
   fi
   rm -f conftest.file
   if test "$*" != "X $srcdir/configure conftest.file" \
      && test "$*" != "X conftest.file $srcdir/configure"; then

      # If neither matched, then we have a broken ls.  This can happen
      # if, for instance, CONFIG_SHELL is bash and it inherits a
      # broken ls alias from the environment.  This has actually
      # happened.  Such a system could not be considered "sane".
      { { $as_echo "$as_me:$LINENO: error: ls -t appears to fail.  Make sure there is not a broken
alias in your environment" >&5
$as_echo "$as_me: error: ls -t appears to fail.  Make sure there is not a broken
alias in your environment" >&2;}
   { (exit 1); exit 1; }; }
   fi

   test "$2" = conftest.file
   )
then
   # Ok.
   :
else
   { { $as_echo "$as_me:$LINENO: error: newly created file is older than distributed files!
Check your system clock" >&5
$as_echo "$as_me: error: newly created file is older than distributed files!
Check your system clock" >&2;}
   { (exit 1); exit 1; }; }
fi
{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
test "$program_prefix" != NONE &&
  program_transform_name="s&^&$program_prefix&;$program_transform_name"
# Use a double $ so make ignores it.
test "$program_suffix" != NONE &&
  program_transform_name="s&\$&$program_suffix&;$program_transform_name"
# Double any \ or $.
# By default was `s,x,x', remove it if useless.
ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`

# expand $ac_aux_dir to an absolute path
am_aux_dir=`cd $ac_aux_dir && pwd`

if test x"${MISSING+set}" != xset; then
  case $am_aux_dir in
  *\ * | *\	*)
    MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
  *)
    MISSING="\${SHELL} $am_aux_dir/missing" ;;
  esac
fi
# Use eval to expand $SHELL
if eval "$MISSING --run true"; then
  am_missing_run="$MISSING --run "
else
  am_missing_run=
  { $as_echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5
$as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
fi

if test x"${install_sh}" != xset; then
  case $am_aux_dir in
  *\ * | *\	*)
    install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
  *)
    install_sh="\${SHELL} $am_aux_dir/install-sh"
  esac
fi

# Installed binaries are usually stripped using `strip' when the user
# run `make install-strip'.  However `strip' might not be the right
# tool to use in cross-compilation environments, therefore Automake
# will honor the `STRIP' environment variable to overrule this program.
if test "$cross_compiling" != no; then
  if test -n "$ac_tool_prefix"; then
  # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_STRIP+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$STRIP"; then
  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_STRIP="${ac_tool_prefix}strip"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
STRIP=$ac_cv_prog_STRIP
if test -n "$STRIP"; then
  { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
$as_echo "$STRIP" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


fi
if test -z "$ac_cv_prog_STRIP"; then
  ac_ct_STRIP=$STRIP
  # Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$ac_ct_STRIP"; then
  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_ac_ct_STRIP="strip"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
if test -n "$ac_ct_STRIP"; then
  { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
$as_echo "$ac_ct_STRIP" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi

  if test "x$ac_ct_STRIP" = x; then
    STRIP=":"
  else
    case $cross_compiling:$ac_tool_warned in
yes:)
{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
    STRIP=$ac_ct_STRIP
  fi
else
  STRIP="$ac_cv_prog_STRIP"
fi

fi
INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"

{ $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5
$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
if test -z "$MKDIR_P"; then
  if test "${ac_cv_path_mkdir+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_prog in mkdir gmkdir; do
	 for ac_exec_ext in '' $ac_executable_extensions; do
	   { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
	   case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
	     'mkdir (GNU coreutils) '* | \
	     'mkdir (coreutils) '* | \
	     'mkdir (fileutils) '4.1*)
	       ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
	       break 3;;
	   esac
	 done
       done
done
IFS=$as_save_IFS

fi

  if test "${ac_cv_path_mkdir+set}" = set; then
    MKDIR_P="$ac_cv_path_mkdir -p"
  else
    # As a last resort, use the slow shell script.  Don't cache a
    # value for MKDIR_P within a source directory, because that will
    # break other packages using the cache if that directory is
    # removed, or if the value is a relative name.
    test -d ./--version && rmdir ./--version
    MKDIR_P="$ac_install_sh -d"
  fi
fi
{ $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5
$as_echo "$MKDIR_P" >&6; }

mkdir_p="$MKDIR_P"
case $mkdir_p in
  [\\/$]* | ?:[\\/]*) ;;
  */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
esac

for ac_prog in gawk mawk nawk awk
do
  # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_AWK+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$AWK"; then
  ac_cv_prog_AWK="$AWK" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_AWK="$ac_prog"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
AWK=$ac_cv_prog_AWK
if test -n "$AWK"; then
  { $as_echo "$as_me:$LINENO: result: $AWK" >&5
$as_echo "$AWK" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


  test -n "$AWK" && break
done

{ $as_echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5
$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
set x ${MAKE-make}
ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.make <<\_ACEOF
SHELL = /bin/sh
all:
	@echo '@@@%%%=$(MAKE)=@@@%%%'
_ACEOF
# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
case `${MAKE-make} -f conftest.make 2>/dev/null` in
  *@@@%%%=?*=@@@%%%*)
    eval ac_cv_prog_make_${ac_make}_set=yes;;
  *)
    eval ac_cv_prog_make_${ac_make}_set=no;;
esac
rm -f conftest.make
fi
if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
  { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
  SET_MAKE=
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
  SET_MAKE="MAKE=${MAKE-make}"
fi

rm -rf .tst 2>/dev/null
mkdir .tst 2>/dev/null
if test -d .tst; then
  am__leading_dot=.
else
  am__leading_dot=_
fi
rmdir .tst 2>/dev/null

if test "`cd $srcdir && pwd`" != "`pwd`"; then
  # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
  # is not polluted with repeated "-I."
  am__isrc=' -I$(srcdir)'
  # test to see if srcdir already configured
  if test -f $srcdir/config.status; then
    { { $as_echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5
$as_echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;}
   { (exit 1); exit 1; }; }
  fi
fi

# test whether we have cygpath
if test -z "$CYGPATH_W"; then
  if (cygpath --version) >/dev/null 2>/dev/null; then
    CYGPATH_W='cygpath -w'
  else
    CYGPATH_W=echo
  fi
fi


# Define the identity of the package.
 PACKAGE='lustre'
 VERSION='2.5.1'


cat >>confdefs.h <<_ACEOF
#define PACKAGE "$PACKAGE"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define VERSION "$VERSION"
_ACEOF

# Some tools Automake needs.

ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}


AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}


AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}


AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}


MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}

# We need awk for the "check" target.  The system "awk" is bad on
# some platforms.
# Always define AMTAR for backward compatibility.

AMTAR=${AMTAR-"${am_missing_run}tar"}


{ $as_echo "$as_me:$LINENO: checking how to create a ustar tar archive" >&5
$as_echo_n "checking how to create a ustar tar archive... " >&6; }
# Loop over all known methods to create a tar archive until one works.
_am_tools='gnutar plaintar pax cpio none'
_am_tools=${am_cv_prog_tar_ustar-$_am_tools}
# Do not fold the above two line into one, because Tru64 sh and
# Solaris sh will not grok spaces in the rhs of `-'.
for _am_tool in $_am_tools
do
  case $_am_tool in
  gnutar)
    for _am_tar in tar gnutar gtar;
    do
      { echo "$as_me:$LINENO: $_am_tar --version" >&5
   ($_am_tar --version) >&5 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); } && break
    done
    am__tar="$_am_tar --format=ustar -chf - "'"$$tardir"'
    am__tar_="$_am_tar --format=ustar -chf - "'"$tardir"'
    am__untar="$_am_tar -xf -"
    ;;
  plaintar)
    # Must skip GNU tar: if it does not support --format= it doesn't create
    # ustar tarball either.
    (tar --version) >/dev/null 2>&1 && continue
    am__tar='tar chf - "$$tardir"'
    am__tar_='tar chf - "$tardir"'
    am__untar='tar xf -'
    ;;
  pax)
    am__tar='pax -L -x ustar -w "$$tardir"'
    am__tar_='pax -L -x ustar -w "$tardir"'
    am__untar='pax -r'
    ;;
  cpio)
    am__tar='find "$$tardir" -print | cpio -o -H ustar -L'
    am__tar_='find "$tardir" -print | cpio -o -H ustar -L'
    am__untar='cpio -i -H ustar -d'
    ;;
  none)
    am__tar=false
    am__tar_=false
    am__untar=false
    ;;
  esac

  # If the value was cached, stop now.  We just wanted to have am__tar
  # and am__untar set.
  test -n "${am_cv_prog_tar_ustar}" && break

  # tar/untar a dummy directory, and stop if the command works
  rm -rf conftest.dir
  mkdir conftest.dir
  echo GrepMe > conftest.dir/file
  { echo "$as_me:$LINENO: tardir=conftest.dir && eval $am__tar_ >conftest.tar" >&5
   (tardir=conftest.dir && eval $am__tar_ >conftest.tar) >&5 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }
  rm -rf conftest.dir
  if test -s conftest.tar; then
    { echo "$as_me:$LINENO: $am__untar <conftest.tar" >&5
   ($am__untar <conftest.tar) >&5 2>&5
   ac_status=$?
   echo "$as_me:$LINENO: \$? = $ac_status" >&5
   (exit $ac_status); }
    grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
  fi
done
rm -rf conftest.dir

if test "${am_cv_prog_tar_ustar+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  am_cv_prog_tar_ustar=$_am_tool
fi

{ $as_echo "$as_me:$LINENO: result: $am_cv_prog_tar_ustar" >&5
$as_echo "$am_cv_prog_tar_ustar" >&6; }






{ $as_echo "$as_me:$LINENO: checking whether to disable maintainer-specific portions of Makefiles" >&5
$as_echo_n "checking whether to disable maintainer-specific portions of Makefiles... " >&6; }
    # Check whether --enable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
  enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
else
  USE_MAINTAINER_MODE=yes
fi

  { $as_echo "$as_me:$LINENO: result: $USE_MAINTAINER_MODE" >&5
$as_echo "$USE_MAINTAINER_MODE" >&6; }
   if test $USE_MAINTAINER_MODE = yes; then
  MAINTAINER_MODE_TRUE=
  MAINTAINER_MODE_FALSE='#'
else
  MAINTAINER_MODE_TRUE='#'
  MAINTAINER_MODE_FALSE=
fi

  MAINT=$MAINTAINER_MODE_TRUE



ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
if test -n "$ac_tool_prefix"; then
  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
set dummy ${ac_tool_prefix}gcc; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_CC="${ac_tool_prefix}gcc"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
  { $as_echo "$as_me:$LINENO: result: $CC" >&5
$as_echo "$CC" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


fi
if test -z "$ac_cv_prog_CC"; then
  ac_ct_CC=$CC
  # Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$ac_ct_CC"; then
  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_ac_ct_CC="gcc"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
  { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
$as_echo "$ac_ct_CC" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi

  if test "x$ac_ct_CC" = x; then
    CC=""
  else
    case $cross_compiling:$ac_tool_warned in
yes:)
{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
    CC=$ac_ct_CC
  fi
else
  CC="$ac_cv_prog_CC"
fi

if test -z "$CC"; then
          if test -n "$ac_tool_prefix"; then
    # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
set dummy ${ac_tool_prefix}cc; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_CC="${ac_tool_prefix}cc"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
  { $as_echo "$as_me:$LINENO: result: $CC" >&5
$as_echo "$CC" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


  fi
fi
if test -z "$CC"; then
  # Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
  ac_prog_rejected=no
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
       ac_prog_rejected=yes
       continue
     fi
    ac_cv_prog_CC="cc"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

if test $ac_prog_rejected = yes; then
  # We found a bogon in the path, so make sure we never use it.
  set dummy $ac_cv_prog_CC
  shift
  if test $# != 0; then
    # We chose a different compiler from the bogus one.
    # However, it has the same basename, so the bogon will be chosen
    # first if we set CC to just the basename; use the full file name.
    shift
    ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
  fi
fi
fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
  { $as_echo "$as_me:$LINENO: result: $CC" >&5
$as_echo "$CC" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


fi
if test -z "$CC"; then
  if test -n "$ac_tool_prefix"; then
  for ac_prog in cl.exe
  do
    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_CC+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$CC"; then
  ac_cv_prog_CC="$CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
CC=$ac_cv_prog_CC
if test -n "$CC"; then
  { $as_echo "$as_me:$LINENO: result: $CC" >&5
$as_echo "$CC" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


    test -n "$CC" && break
  done
fi
if test -z "$CC"; then
  ac_ct_CC=$CC
  for ac_prog in cl.exe
do
  # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$ac_ct_CC"; then
  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_ac_ct_CC="$ac_prog"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
ac_ct_CC=$ac_cv_prog_ac_ct_CC
if test -n "$ac_ct_CC"; then
  { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
$as_echo "$ac_ct_CC" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


  test -n "$ac_ct_CC" && break
done

  if test "x$ac_ct_CC" = x; then
    CC=""
  else
    case $cross_compiling:$ac_tool_warned in
yes:)
{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
    CC=$ac_ct_CC
  fi
fi

fi


test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
{ { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
See \`config.log' for more details." >&5
$as_echo "$as_me: error: no acceptable C compiler found in \$PATH
See \`config.log' for more details." >&2;}
   { (exit 1); exit 1; }; }; }

# Provide some information about the compiler.
$as_echo "$as_me:$LINENO: checking for C compiler version" >&5
set X $ac_compile
ac_compiler=$2
{ (ac_try="$ac_compiler --version >&5"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compiler --version >&5") 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }
{ (ac_try="$ac_compiler -v >&5"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compiler -v >&5") 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }
{ (ac_try="$ac_compiler -V >&5"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compiler -V >&5") 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }

cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

int
main ()
{

  ;
  return 0;
}
_ACEOF
ac_clean_files_save=$ac_clean_files
ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
# Try to create an executable without -o first, disregard a.out.
# It will help us diagnose broken compilers, and finding out an intuition
# of exeext.
{ $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
$as_echo_n "checking for C compiler default output file name... " >&6; }
ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`

# The possible output files:
ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"

ac_rmfiles=
for ac_file in $ac_files
do
  case $ac_file in
    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
  esac
done
rm -f $ac_rmfiles

if { (ac_try="$ac_link_default"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link_default") 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; then
  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
# in a Makefile.  We should not override ac_cv_exeext if it was cached,
# so that the user can short-circuit this test for compilers unknown to
# Autoconf.
for ac_file in $ac_files ''
do
  test -f "$ac_file" || continue
  case $ac_file in
    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
	;;
    [ab].out )
	# We found the default executable, but exeext='' is most
	# certainly right.
	break;;
    *.* )
        if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
	then :; else
	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
	fi
	# We set ac_cv_exeext here because the later test for it is not
	# safe: cross compilers may not add the suffix if given an `-o'
	# argument, so we may need to know it at that point already.
	# Even if this section looks crufty: it has the advantage of
	# actually working.
	break;;
    * )
	break;;
  esac
done
test "$ac_cv_exeext" = no && ac_cv_exeext=

else
  ac_file=''
fi

{ $as_echo "$as_me:$LINENO: result: $ac_file" >&5
$as_echo "$ac_file" >&6; }
if test -z "$ac_file"; then
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

{ { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
{ { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables
See \`config.log' for more details." >&5
$as_echo "$as_me: error: C compiler cannot create executables
See \`config.log' for more details." >&2;}
   { (exit 77); exit 77; }; }; }
fi

ac_exeext=$ac_cv_exeext

# Check that the compiler produces executables we can run.  If not, either
# the compiler is broken, or we cross compile.
{ $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5
$as_echo_n "checking whether the C compiler works... " >&6; }
# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
# If not cross compiling, check that we can run a simple program.
if test "$cross_compiling" != yes; then
  if { ac_try='./$ac_file'
  { (case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_try") 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
    cross_compiling=no
  else
    if test "$cross_compiling" = maybe; then
	cross_compiling=yes
    else
	{ { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
{ { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs.
If you meant to cross compile, use \`--host'.
See \`config.log' for more details." >&5
$as_echo "$as_me: error: cannot run C compiled programs.
If you meant to cross compile, use \`--host'.
See \`config.log' for more details." >&2;}
   { (exit 1); exit 1; }; }; }
    fi
  fi
fi
{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
ac_clean_files=$ac_clean_files_save
# Check that the compiler produces executables we can run.  If not, either
# the compiler is broken, or we cross compile.
{ $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
$as_echo_n "checking whether we are cross compiling... " >&6; }
{ $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5
$as_echo "$cross_compiling" >&6; }

{ $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5
$as_echo_n "checking for suffix of executables... " >&6; }
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; then
  # If both `conftest.exe' and `conftest' are `present' (well, observable)
# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
# work properly (i.e., refer to `conftest.exe'), while it won't with
# `rm'.
for ac_file in conftest.exe conftest conftest.*; do
  test -f "$ac_file" || continue
  case $ac_file in
    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
	  break;;
    * ) break;;
  esac
done
else
  { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
{ { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
See \`config.log' for more details." >&5
$as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
See \`config.log' for more details." >&2;}
   { (exit 1); exit 1; }; }; }
fi

rm -f conftest$ac_cv_exeext
{ $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
$as_echo "$ac_cv_exeext" >&6; }

rm -f conftest.$ac_ext
EXEEXT=$ac_cv_exeext
ac_exeext=$EXEEXT
{ $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5
$as_echo_n "checking for suffix of object files... " >&6; }
if test "${ac_cv_objext+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.o conftest.obj
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; then
  for ac_file in conftest.o conftest.obj conftest.*; do
  test -f "$ac_file" || continue;
  case $ac_file in
    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
       break;;
  esac
done
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

{ { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
{ { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
See \`config.log' for more details." >&5
$as_echo "$as_me: error: cannot compute suffix of object files: cannot compile
See \`config.log' for more details." >&2;}
   { (exit 1); exit 1; }; }; }
fi

rm -f conftest.$ac_cv_objext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
$as_echo "$ac_cv_objext" >&6; }
OBJEXT=$ac_cv_objext
ac_objext=$OBJEXT
{ $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
if test "${ac_cv_c_compiler_gnu+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

int
main ()
{
#ifndef __GNUC__
       choke me
#endif

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_compiler_gnu=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_compiler_gnu=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
ac_cv_c_compiler_gnu=$ac_compiler_gnu

fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
$as_echo "$ac_cv_c_compiler_gnu" >&6; }
if test $ac_compiler_gnu = yes; then
  GCC=yes
else
  GCC=
fi
ac_test_CFLAGS=${CFLAGS+set}
ac_save_CFLAGS=$CFLAGS
{ $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
$as_echo_n "checking whether $CC accepts -g... " >&6; }
if test "${ac_cv_prog_cc_g+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_save_c_werror_flag=$ac_c_werror_flag
   ac_c_werror_flag=yes
   ac_cv_prog_cc_g=no
   CFLAGS="-g"
   cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_cv_prog_cc_g=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	CFLAGS=""
      cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_c_werror_flag=$ac_save_c_werror_flag
	 CFLAGS="-g"
	 cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_cv_prog_cc_g=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
   ac_c_werror_flag=$ac_save_c_werror_flag
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
$as_echo "$ac_cv_prog_cc_g" >&6; }
if test "$ac_test_CFLAGS" = set; then
  CFLAGS=$ac_save_CFLAGS
elif test $ac_cv_prog_cc_g = yes; then
  if test "$GCC" = yes; then
    CFLAGS="-g -O2"
  else
    CFLAGS="-g"
  fi
else
  if test "$GCC" = yes; then
    CFLAGS="-O2"
  else
    CFLAGS=
  fi
fi
{ $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
if test "${ac_cv_prog_cc_c89+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_prog_cc_c89=no
ac_save_CC=$CC
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <stdarg.h>
#include <stdio.h>
#include <sys/types.h>
#include <sys/stat.h>
/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
struct buf { int x; };
FILE * (*rcsopen) (struct buf *, struct stat *, int);
static char *e (p, i)
     char **p;
     int i;
{
  return p[i];
}
static char *f (char * (*g) (char **, int), char **p, ...)
{
  char *s;
  va_list v;
  va_start (v,p);
  s = g (p, va_arg (v,int));
  va_end (v);
  return s;
}

/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
   function prototypes and stuff, but not '\xHH' hex character constants.
   These don't provoke an error unfortunately, instead are silently treated
   as 'x'.  The following induces an error, until -std is added to get
   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
   array size at least.  It's necessary to write '\x00'==0 to get something
   that's true only with -std.  */
int osf4_cc_array ['\x00' == 0 ? 1 : -1];

/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
   inside strings and character constants.  */
#define FOO(x) 'x'
int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];

int test (int i, double x);
struct s1 {int (*f) (int a);};
struct s2 {int (*f) (double a);};
int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
int argc;
char **argv;
int
main ()
{
return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
  ;
  return 0;
}
_ACEOF
for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
do
  CC="$ac_save_CC $ac_arg"
  rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_cv_prog_cc_c89=$ac_arg
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext
  test "x$ac_cv_prog_cc_c89" != "xno" && break
done
rm -f conftest.$ac_ext
CC=$ac_save_CC

fi
# AC_CACHE_VAL
case "x$ac_cv_prog_cc_c89" in
  x)
    { $as_echo "$as_me:$LINENO: result: none needed" >&5
$as_echo "none needed" >&6; } ;;
  xno)
    { $as_echo "$as_me:$LINENO: result: unsupported" >&5
$as_echo "unsupported" >&6; } ;;
  *)
    CC="$CC $ac_cv_prog_cc_c89"
    { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
esac


ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
DEPDIR="${am__leading_dot}deps"

ac_config_commands="$ac_config_commands depfiles"


am_make=${MAKE-make}
cat > confinc << 'END'
am__doit:
	@echo this is the am__doit target
.PHONY: am__doit
END
# If we don't find an include directive, just comment out the code.
{ $as_echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5
$as_echo_n "checking for style of include used by $am_make... " >&6; }
am__include="#"
am__quote=
_am_result=none
# First try GNU make style include.
echo "include confinc" > confmf
# Ignore all kinds of additional output from `make'.
case `$am_make -s -f confmf 2> /dev/null` in #(
*the\ am__doit\ target*)
  am__include=include
  am__quote=
  _am_result=GNU
  ;;
esac
# Now try BSD make style include.
if test "$am__include" = "#"; then
   echo '.include "confinc"' > confmf
   case `$am_make -s -f confmf 2> /dev/null` in #(
   *the\ am__doit\ target*)
     am__include=.include
     am__quote="\""
     _am_result=BSD
     ;;
   esac
fi


{ $as_echo "$as_me:$LINENO: result: $_am_result" >&5
$as_echo "$_am_result" >&6; }
rm -f confinc confmf

# Check whether --enable-dependency-tracking was given.
if test "${enable_dependency_tracking+set}" = set; then
  enableval=$enable_dependency_tracking;
fi

if test "x$enable_dependency_tracking" != xno; then
  am_depcomp="$ac_aux_dir/depcomp"
  AMDEPBACKSLASH='\'
fi
 if test "x$enable_dependency_tracking" != xno; then
  AMDEP_TRUE=
  AMDEP_FALSE='#'
else
  AMDEP_TRUE='#'
  AMDEP_FALSE=
fi



depcc="$CC"   am_compiler_list=

{ $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
$as_echo_n "checking dependency style of $depcc... " >&6; }
if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
  # We make a subdir and do the tests there.  Otherwise we can end up
  # making bogus files that we don't know about and never remove.  For
  # instance it was reported that on HP-UX the gcc test will end up
  # making a dummy file named `D' -- because `-MD' means `put the output
  # in D'.
  mkdir conftest.dir
  # Copy depcomp to subdir because otherwise we won't find it if we're
  # using a relative directory.
  cp "$am_depcomp" conftest.dir
  cd conftest.dir
  # We will build objects and dependencies in a subdirectory because
  # it helps to detect inapplicable dependency modes.  For instance
  # both Tru64's cc and ICC support -MD to output dependencies as a
  # side effect of compilation, but ICC will put the dependencies in
  # the current directory while Tru64 will put them in the object
  # directory.
  mkdir sub

  am_cv_CC_dependencies_compiler_type=none
  if test "$am_compiler_list" = ""; then
     am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
  fi
  am__universal=false
  case " $depcc " in #(
     *\ -arch\ *\ -arch\ *) am__universal=true ;;
     esac

  for depmode in $am_compiler_list; do
    # Setup a source with many dependencies, because some compilers
    # like to wrap large dependency lists on column 80 (with \), and
    # we should not choose a depcomp mode which is confused by this.
    #
    # We need to recreate these files for each test, as the compiler may
    # overwrite some of them when testing with obscure command lines.
    # This happens at least with the AIX C compiler.
    : > sub/conftest.c
    for i in 1 2 3 4 5 6; do
      echo '#include "conftst'$i'.h"' >> sub/conftest.c
      # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
      # Solaris 8's {/usr,}/bin/sh.
      touch sub/conftst$i.h
    done
    echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf

    # We check with `-c' and `-o' for the sake of the "dashmstdout"
    # mode.  It turns out that the SunPro C++ compiler does not properly
    # handle `-M -o', and we need to detect this.  Also, some Intel
    # versions had trouble with output in subdirs
    am__obj=sub/conftest.${OBJEXT-o}
    am__minus_obj="-o $am__obj"
    case $depmode in
    gcc)
      # This depmode causes a compiler race in universal mode.
      test "$am__universal" = false || continue
      ;;
    nosideeffect)
      # after this tag, mechanisms are not by side-effect, so they'll
      # only be used when explicitly requested
      if test "x$enable_dependency_tracking" = xyes; then
	continue
      else
	break
      fi
      ;;
    msvisualcpp | msvcmsys)
      # This compiler won't grok `-c -o', but also, the minuso test has
      # not run yet.  These depmodes are late enough in the game, and
      # so weak that their functioning should not be impacted.
      am__obj=conftest.${OBJEXT-o}
      am__minus_obj=
      ;;
    none) break ;;
    esac
    if depmode=$depmode \
       source=sub/conftest.c object=$am__obj \
       depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
       $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
         >/dev/null 2>conftest.err &&
       grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
       grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
       grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
       ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
      # icc doesn't choke on unknown options, it will just issue warnings
      # or remarks (even with -Werror).  So we grep stderr for any message
      # that says an option was ignored or not supported.
      # When given -MP, icc 7.0 and 7.1 complain thusly:
      #   icc: Command line warning: ignoring option '-M'; no argument required
      # The diagnosis changed in icc 8.0:
      #   icc: Command line remark: option '-MP' not supported
      if (grep 'ignoring option' conftest.err ||
          grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
        am_cv_CC_dependencies_compiler_type=$depmode
        break
      fi
    fi
  done

  cd ..
  rm -rf conftest.dir
else
  am_cv_CC_dependencies_compiler_type=none
fi

fi
{ $as_echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5
$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type

 if
  test "x$enable_dependency_tracking" != xno \
  && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
  am__fastdepCC_TRUE=
  am__fastdepCC_FALSE='#'
else
  am__fastdepCC_TRUE='#'
  am__fastdepCC_FALSE=
fi



# By default we simply use the C compiler to build assembly code.

test "${CCAS+set}" = set || CCAS=$CC
test "${CCASFLAGS+set}" = set || CCASFLAGS=$CFLAGS



depcc="$CCAS"   am_compiler_list=

{ $as_echo "$as_me:$LINENO: checking dependency style of $depcc" >&5
$as_echo_n "checking dependency style of $depcc... " >&6; }
if test "${am_cv_CCAS_dependencies_compiler_type+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
  # We make a subdir and do the tests there.  Otherwise we can end up
  # making bogus files that we don't know about and never remove.  For
  # instance it was reported that on HP-UX the gcc test will end up
  # making a dummy file named `D' -- because `-MD' means `put the output
  # in D'.
  mkdir conftest.dir
  # Copy depcomp to subdir because otherwise we won't find it if we're
  # using a relative directory.
  cp "$am_depcomp" conftest.dir
  cd conftest.dir
  # We will build objects and dependencies in a subdirectory because
  # it helps to detect inapplicable dependency modes.  For instance
  # both Tru64's cc and ICC support -MD to output dependencies as a
  # side effect of compilation, but ICC will put the dependencies in
  # the current directory while Tru64 will put them in the object
  # directory.
  mkdir sub

  am_cv_CCAS_dependencies_compiler_type=none
  if test "$am_compiler_list" = ""; then
     am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
  fi
  am__universal=false


  for depmode in $am_compiler_list; do
    # Setup a source with many dependencies, because some compilers
    # like to wrap large dependency lists on column 80 (with \), and
    # we should not choose a depcomp mode which is confused by this.
    #
    # We need to recreate these files for each test, as the compiler may
    # overwrite some of them when testing with obscure command lines.
    # This happens at least with the AIX C compiler.
    : > sub/conftest.c
    for i in 1 2 3 4 5 6; do
      echo '#include "conftst'$i'.h"' >> sub/conftest.c
      # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
      # Solaris 8's {/usr,}/bin/sh.
      touch sub/conftst$i.h
    done
    echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf

    # We check with `-c' and `-o' for the sake of the "dashmstdout"
    # mode.  It turns out that the SunPro C++ compiler does not properly
    # handle `-M -o', and we need to detect this.  Also, some Intel
    # versions had trouble with output in subdirs
    am__obj=sub/conftest.${OBJEXT-o}
    am__minus_obj="-o $am__obj"
    case $depmode in
    gcc)
      # This depmode causes a compiler race in universal mode.
      test "$am__universal" = false || continue
      ;;
    nosideeffect)
      # after this tag, mechanisms are not by side-effect, so they'll
      # only be used when explicitly requested
      if test "x$enable_dependency_tracking" = xyes; then
	continue
      else
	break
      fi
      ;;
    msvisualcpp | msvcmsys)
      # This compiler won't grok `-c -o', but also, the minuso test has
      # not run yet.  These depmodes are late enough in the game, and
      # so weak that their functioning should not be impacted.
      am__obj=conftest.${OBJEXT-o}
      am__minus_obj=
      ;;
    none) break ;;
    esac
    if depmode=$depmode \
       source=sub/conftest.c object=$am__obj \
       depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
       $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
         >/dev/null 2>conftest.err &&
       grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
       grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
       grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
       ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
      # icc doesn't choke on unknown options, it will just issue warnings
      # or remarks (even with -Werror).  So we grep stderr for any message
      # that says an option was ignored or not supported.
      # When given -MP, icc 7.0 and 7.1 complain thusly:
      #   icc: Command line warning: ignoring option '-M'; no argument required
      # The diagnosis changed in icc 8.0:
      #   icc: Command line remark: option '-MP' not supported
      if (grep 'ignoring option' conftest.err ||
          grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
        am_cv_CCAS_dependencies_compiler_type=$depmode
        break
      fi
    fi
  done

  cd ..
  rm -rf conftest.dir
else
  am_cv_CCAS_dependencies_compiler_type=none
fi

fi
{ $as_echo "$as_me:$LINENO: result: $am_cv_CCAS_dependencies_compiler_type" >&5
$as_echo "$am_cv_CCAS_dependencies_compiler_type" >&6; }
CCASDEPMODE=depmode=$am_cv_CCAS_dependencies_compiler_type

 if
  test "x$enable_dependency_tracking" != xno \
  && test "$am_cv_CCAS_dependencies_compiler_type" = gcc3; then
  am__fastdepCCAS_TRUE=
  am__fastdepCCAS_FALSE='#'
else
  am__fastdepCCAS_TRUE='#'
  am__fastdepCCAS_FALSE=
fi



if test -n "$ac_tool_prefix"; then
  for ac_prog in ar
  do
    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
set dummy $ac_tool_prefix$ac_prog; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_AR+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$AR"; then
  ac_cv_prog_AR="$AR" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
AR=$ac_cv_prog_AR
if test -n "$AR"; then
  { $as_echo "$as_me:$LINENO: result: $AR" >&5
$as_echo "$AR" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


    test -n "$AR" && break
  done
fi
if test -z "$AR"; then
  ac_ct_AR=$AR
  for ac_prog in ar
do
  # Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$ac_ct_AR"; then
  ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_ac_ct_AR="$ac_prog"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
ac_ct_AR=$ac_cv_prog_ac_ct_AR
if test -n "$ac_ct_AR"; then
  { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
$as_echo "$ac_ct_AR" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


  test -n "$ac_ct_AR" && break
done

  if test "x$ac_ct_AR" = x; then
    AR=""
  else
    case $cross_compiling:$ac_tool_warned in
yes:)
{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
    AR=$ac_ct_AR
  fi
fi



ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
{ $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
$as_echo_n "checking how to run the C preprocessor... " >&6; }
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
  CPP=
fi
if test -z "$CPP"; then
  if test "${ac_cv_prog_CPP+set}" = set; then
  $as_echo_n "(cached) " >&6
else
      # Double quotes because CPP needs to be expanded
    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
    do
      ac_preproc_ok=false
for ac_c_preproc_warn_flag in '' yes
do
  # Use a header file that comes with gcc, so configuring glibc
  # with a fresh cross-compiler works.
  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  # <limits.h> exists even on freestanding compilers.
  # On the NeXT, cc -E runs the code through the compiler's parser,
  # not just through cpp. "Syntax error" is here to catch this case.
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif
		     Syntax error
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  # Broken: fails on valid input.
continue
fi

rm -f conftest.err conftest.$ac_ext

  # OK, works on sane cases.  Now check whether nonexistent headers
  # can be detected and how.
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <ac_nonexistent.h>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  # Broken: success on invalid input.
continue
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  # Passes both tests.
ac_preproc_ok=:
break
fi

rm -f conftest.err conftest.$ac_ext

done
# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
rm -f conftest.err conftest.$ac_ext
if $ac_preproc_ok; then
  break
fi

    done
    ac_cv_prog_CPP=$CPP

fi
  CPP=$ac_cv_prog_CPP
else
  ac_cv_prog_CPP=$CPP
fi
{ $as_echo "$as_me:$LINENO: result: $CPP" >&5
$as_echo "$CPP" >&6; }
ac_preproc_ok=false
for ac_c_preproc_warn_flag in '' yes
do
  # Use a header file that comes with gcc, so configuring glibc
  # with a fresh cross-compiler works.
  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
  # <limits.h> exists even on freestanding compilers.
  # On the NeXT, cc -E runs the code through the compiler's parser,
  # not just through cpp. "Syntax error" is here to catch this case.
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif
		     Syntax error
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  # Broken: fails on valid input.
continue
fi

rm -f conftest.err conftest.$ac_ext

  # OK, works on sane cases.  Now check whether nonexistent headers
  # can be detected and how.
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <ac_nonexistent.h>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  # Broken: success on invalid input.
continue
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  # Passes both tests.
ac_preproc_ok=:
break
fi

rm -f conftest.err conftest.$ac_ext

done
# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
rm -f conftest.err conftest.$ac_ext
if $ac_preproc_ok; then
  :
else
  { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
{ { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
See \`config.log' for more details." >&5
$as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
See \`config.log' for more details." >&2;}
   { (exit 1); exit 1; }; }; }
fi

ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu


{ $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
if test "${ac_cv_path_GREP+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -z "$GREP"; then
  ac_path_GREP_found=false
  # Loop through the user's path and test for each of PROGNAME-LIST
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_prog in grep ggrep; do
    for ac_exec_ext in '' $ac_executable_extensions; do
      ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
      { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
# Check for GNU ac_path_GREP and select it if it is found.
  # Check for GNU $ac_path_GREP
case `"$ac_path_GREP" --version 2>&1` in
*GNU*)
  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
*)
  ac_count=0
  $as_echo_n 0123456789 >"conftest.in"
  while :
  do
    cat "conftest.in" "conftest.in" >"conftest.tmp"
    mv "conftest.tmp" "conftest.in"
    cp "conftest.in" "conftest.nl"
    $as_echo 'GREP' >> "conftest.nl"
    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
    ac_count=`expr $ac_count + 1`
    if test $ac_count -gt ${ac_path_GREP_max-0}; then
      # Best one so far, save it but keep looking for a better one
      ac_cv_path_GREP="$ac_path_GREP"
      ac_path_GREP_max=$ac_count
    fi
    # 10*(2^10) chars as input seems more than enough
    test $ac_count -gt 10 && break
  done
  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
esac

      $ac_path_GREP_found && break 3
    done
  done
done
IFS=$as_save_IFS
  if test -z "$ac_cv_path_GREP"; then
    { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
$as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
   { (exit 1); exit 1; }; }
  fi
else
  ac_cv_path_GREP=$GREP
fi

fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
$as_echo "$ac_cv_path_GREP" >&6; }
 GREP="$ac_cv_path_GREP"


{ $as_echo "$as_me:$LINENO: checking for egrep" >&5
$as_echo_n "checking for egrep... " >&6; }
if test "${ac_cv_path_EGREP+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
   then ac_cv_path_EGREP="$GREP -E"
   else
     if test -z "$EGREP"; then
  ac_path_EGREP_found=false
  # Loop through the user's path and test for each of PROGNAME-LIST
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_prog in egrep; do
    for ac_exec_ext in '' $ac_executable_extensions; do
      ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
      { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
# Check for GNU ac_path_EGREP and select it if it is found.
  # Check for GNU $ac_path_EGREP
case `"$ac_path_EGREP" --version 2>&1` in
*GNU*)
  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
*)
  ac_count=0
  $as_echo_n 0123456789 >"conftest.in"
  while :
  do
    cat "conftest.in" "conftest.in" >"conftest.tmp"
    mv "conftest.tmp" "conftest.in"
    cp "conftest.in" "conftest.nl"
    $as_echo 'EGREP' >> "conftest.nl"
    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
    ac_count=`expr $ac_count + 1`
    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
      # Best one so far, save it but keep looking for a better one
      ac_cv_path_EGREP="$ac_path_EGREP"
      ac_path_EGREP_max=$ac_count
    fi
    # 10*(2^10) chars as input seems more than enough
    test $ac_count -gt 10 && break
  done
  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
esac

      $ac_path_EGREP_found && break 3
    done
  done
done
IFS=$as_save_IFS
  if test -z "$ac_cv_path_EGREP"; then
    { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
$as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
   { (exit 1); exit 1; }; }
  fi
else
  ac_cv_path_EGREP=$EGREP
fi

   fi
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
$as_echo "$ac_cv_path_EGREP" >&6; }
 EGREP="$ac_cv_path_EGREP"


{ $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
$as_echo_n "checking for ANSI C header files... " >&6; }
if test "${ac_cv_header_stdc+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <stdlib.h>
#include <stdarg.h>
#include <string.h>
#include <float.h>

int
main ()
{

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_cv_header_stdc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_header_stdc=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext

if test $ac_cv_header_stdc = yes; then
  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <string.h>

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  $EGREP "memchr" >/dev/null 2>&1; then
  :
else
  ac_cv_header_stdc=no
fi
rm -f conftest*

fi

if test $ac_cv_header_stdc = yes; then
  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <stdlib.h>

_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
  $EGREP "free" >/dev/null 2>&1; then
  :
else
  ac_cv_header_stdc=no
fi
rm -f conftest*

fi

if test $ac_cv_header_stdc = yes; then
  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
  if test "$cross_compiling" = yes; then
  :
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <ctype.h>
#include <stdlib.h>
#if ((' ' & 0x0FF) == 0x020)
# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
#else
# define ISLOWER(c) \
		   (('a' <= (c) && (c) <= 'i') \
		     || ('j' <= (c) && (c) <= 'r') \
		     || ('s' <= (c) && (c) <= 'z'))
# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
#endif

#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
int
main ()
{
  int i;
  for (i = 0; i < 256; i++)
    if (XOR (islower (i), ISLOWER (i))
	|| toupper (i) != TOUPPER (i))
      return 2;
  return 0;
}
_ACEOF
rm -f conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_try") 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  :
else
  $as_echo "$as_me: program exited with status $ac_status" >&5
$as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

( exit $ac_status )
ac_cv_header_stdc=no
fi
rm -rf conftest.dSYM
rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi


fi
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
$as_echo "$ac_cv_header_stdc" >&6; }
if test $ac_cv_header_stdc = yes; then

cat >>confdefs.h <<\_ACEOF
#define STDC_HEADERS 1
_ACEOF

fi

# On IRIX 5.3, sys/types and inttypes.h are conflicting.









for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
		  inttypes.h stdint.h unistd.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default

#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  eval "$as_ac_Header=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_Header=no"
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF

fi

done




case $target_os in
	linux*)
		lb_target_os="linux"
		;;
	darwin*)
		lb_target_os="darwin"
		;;
	solaris*)
		lb_target_os="SunOS"
		;;
esac



{ $as_echo "$as_me:$LINENO: checking whether to configure just enough for make dist" >&5
$as_echo_n "checking whether to configure just enough for make dist... " >&6; }
# Check whether --enable-dist was given.
if test "${enable_dist+set}" = set; then
  enableval=$enable_dist; enable_dist='yes'
else
  enable_dist='no'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_dist" >&5
$as_echo "$enable_dist" >&6; }
if test x$enable_dist != xno; then
	enable_modules='no'
	enable_utils='no'
        enable_liblustre='no'
        enable_doc='no'
        enable_tests='no'
fi



# Check whether --with-downstream-release was given.
if test "${with_downstream_release+set}" = set; then
  withval=$with_downstream_release; DOWNSTREAM_RELEASE=$with_downstream_release
else

	# if not specified, see if it's in the META file
	if test -f META; then
		DOWNSTREAM_RELEASE=$(sed -ne '/^LOCAL_VERSION =/s/.*= *//p' META)
	fi

fi




{ $as_echo "$as_me:$LINENO: checking if this distro uses dpkg" >&5
$as_echo_n "checking if this distro uses dpkg... " >&6; }
case `lsb_release -i -s 2>/dev/null` in
        Ubuntu | Debian)
                { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
                uses_dpkg=yes
                ;;
        *)
                { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
                uses_dpkg=no
                ;;
esac


{ $as_echo "$as_me:$LINENO: checking for buildid" >&5
$as_echo_n "checking for buildid... " >&6; }
BUILDID=""
if git branch >/dev/null 2>&1; then
	ffw=0
	hash=""
	ver=$(git describe --match v[0-9]_*_[0-9]* --tags)
	if [[ $ver = *-*-* ]]; then
		hash=${ver##*-}
		ffw=${ver#*-}
		ffw=${ffw%-*}
		ver=${ver%%-*}
	fi
	# it's tempting to use [[ $ver =~ ^v([0-9]+_)+([0-9]+|RC[0-9]+)$ ]]
	# here but the portability of the regex on the right is dismal
	# (thanx suse)
	if echo "$ver" | egrep -q "^v([0-9]+_)+([0-9]+|RC[0-9]+)$"; then
		ver=$(echo $ver | sed -e 's/^v\(.*\)/\1/' \
				      -e 's/_RC[0-9].*$//' -e 's/_/./g')
	fi

	# a "lustre fix" value of .0 should be truncated
	if [[ $ver = *.*.*.0 ]]; then
		ver=${ver%.0}
	fi
	# ditto for a "lustre fix" value of _0
	if [[ $ver = v*_*_*_0 ]]; then
		ver=${ver%_0}
	fi
	if [[ $ver = v*_*_* ]]; then
		ver=${ver#v}
		ver=${ver//_/.}
	fi

	if test "$ver" != "$VERSION"; then
		{ $as_echo "$as_me:$LINENO: WARNING: most recent tag found: $ver does not match current version $VERSION." >&5
$as_echo "$as_me: WARNING: most recent tag found: $ver does not match current version $VERSION." >&2;}
	fi

	if test "$ffw" != "0"; then
		BUILDID="$hash"
		msg="$BUILDID (ahead by $ffw commits)"
		{ $as_echo "$as_me:$LINENO: result: $msg" >&5
$as_echo "$msg" >&6; }
	else
		{ $as_echo "$as_me:$LINENO: result: none... congratulations, you must be on a tag" >&5
$as_echo "none... congratulations, you must be on a tag" >&6; }
	fi
elif test -f META; then
	BUILDID=$(sed -ne '/^BUILDID =/s/.*= *//p' META)
	msg="$BUILDID (from META file)"
	{ $as_echo "$as_me:$LINENO: result: $msg" >&5
$as_echo "$msg" >&6; }
else
	{ $as_echo "$as_me:$LINENO: WARNING: FIXME: I don't know how to deal with source trees outside of git that don't have a META file.  Not setting a buildid." >&5
$as_echo "$as_me: WARNING: FIXME: I don't know how to deal with source trees outside of git that don't have a META file.  Not setting a buildid." >&2;}
fi




case x$libcfs_is_module in
	xyes)
          LIBCFS_INCLUDE_DIR="libcfs/include"
          LIBCFS_SUBDIR="libcfs"
          ;;
        x*)
          LIBCFS_INCLUDE_DIR="lnet/include"
          LIBCFS_SUBDIR=""
          ;;
esac





	INCLUDE_RULES="include $PWD/Rules"



# directories for binaries


sysconfdir='$(CROSS_PATH)/etc'


# Directories for documentation and demos.
docdir='$(datadir)/doc/$(PACKAGE)'






# ptlrpc kernel build requires this
LUSTRE="$PWD/lustre"


# mount.lustre
rootsbindir='$(CROSS_PATH)/sbin'


demodir='$(docdir)/demo'


pkgexampledir='${pkgdatadir}/examples'





if test -n "$ac_tool_prefix"; then
  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_RANLIB+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$RANLIB"; then
  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
RANLIB=$ac_cv_prog_RANLIB
if test -n "$RANLIB"; then
  { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
$as_echo "$RANLIB" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


fi
if test -z "$ac_cv_prog_RANLIB"; then
  ac_ct_RANLIB=$RANLIB
  # Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$ac_ct_RANLIB"; then
  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_ac_ct_RANLIB="ranlib"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
if test -n "$ac_ct_RANLIB"; then
  { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
$as_echo "$ac_ct_RANLIB" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi

  if test "x$ac_ct_RANLIB" = x; then
    RANLIB=":"
  else
    case $cross_compiling:$ac_tool_warned in
yes:)
{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
    RANLIB=$ac_ct_RANLIB
  fi
else
  RANLIB="$ac_cv_prog_RANLIB"
fi

if test -n "$ac_tool_prefix"; then
  # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
set dummy ${ac_tool_prefix}ld; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_LD+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$LD"; then
  ac_cv_prog_LD="$LD" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_LD="${ac_tool_prefix}ld"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
LD=$ac_cv_prog_LD
if test -n "$LD"; then
  { $as_echo "$as_me:$LINENO: result: $LD" >&5
$as_echo "$LD" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


fi
if test -z "$ac_cv_prog_LD"; then
  ac_ct_LD=$LD
  # Extract the first word of "ld", so it can be a program name with args.
set dummy ld; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_LD+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$ac_ct_LD"; then
  ac_cv_prog_ac_ct_LD="$ac_ct_LD" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_ac_ct_LD="ld"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
ac_ct_LD=$ac_cv_prog_ac_ct_LD
if test -n "$ac_ct_LD"; then
  { $as_echo "$as_me:$LINENO: result: $ac_ct_LD" >&5
$as_echo "$ac_ct_LD" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi

  if test "x$ac_ct_LD" = x; then
    LD="no"
  else
    case $cross_compiling:$ac_tool_warned in
yes:)
{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
    LD=$ac_ct_LD
  fi
else
  LD="$ac_cv_prog_LD"
fi

if test -n "$ac_tool_prefix"; then
  # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
set dummy ${ac_tool_prefix}objdump; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_OBJDUMP+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$OBJDUMP"; then
  ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
OBJDUMP=$ac_cv_prog_OBJDUMP
if test -n "$OBJDUMP"; then
  { $as_echo "$as_me:$LINENO: result: $OBJDUMP" >&5
$as_echo "$OBJDUMP" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


fi
if test -z "$ac_cv_prog_OBJDUMP"; then
  ac_ct_OBJDUMP=$OBJDUMP
  # Extract the first word of "objdump", so it can be a program name with args.
set dummy objdump; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$ac_ct_OBJDUMP"; then
  ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_ac_ct_OBJDUMP="objdump"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
if test -n "$ac_ct_OBJDUMP"; then
  { $as_echo "$as_me:$LINENO: result: $ac_ct_OBJDUMP" >&5
$as_echo "$ac_ct_OBJDUMP" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi

  if test "x$ac_ct_OBJDUMP" = x; then
    OBJDUMP="no"
  else
    case $cross_compiling:$ac_tool_warned in
yes:)
{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
    OBJDUMP=$ac_ct_OBJDUMP
  fi
else
  OBJDUMP="$ac_cv_prog_OBJDUMP"
fi

if test -n "$ac_tool_prefix"; then
  # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_STRIP+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$STRIP"; then
  ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_STRIP="${ac_tool_prefix}strip"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
STRIP=$ac_cv_prog_STRIP
if test -n "$STRIP"; then
  { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
$as_echo "$STRIP" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


fi
if test -z "$ac_cv_prog_STRIP"; then
  ac_ct_STRIP=$STRIP
  # Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$ac_ct_STRIP"; then
  ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_ac_ct_STRIP="strip"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
if test -n "$ac_ct_STRIP"; then
  { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
$as_echo "$ac_ct_STRIP" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi

  if test "x$ac_ct_STRIP" = x; then
    STRIP="no"
  else
    case $cross_compiling:$ac_tool_warned in
yes:)
{ $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
ac_tool_warned=yes ;;
esac
    STRIP=$ac_ct_STRIP
  fi
else
  STRIP="$ac_cv_prog_STRIP"
fi


# ---------  unsigned long long sane? -------
# The cast to long int works around a bug in the HP C Compiler
# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
# This bug is HP SR number 8606223364.
{ $as_echo "$as_me:$LINENO: checking size of unsigned long long" >&5
$as_echo_n "checking size of unsigned long long... " >&6; }
if test "${ac_cv_sizeof_unsigned_long_long+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test "$cross_compiling" = yes; then
  # Depending upon the size, compute the lo and hi bounds.
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
int
main ()
{
static int test_array [1 - 2 * !(((long int) (sizeof (unsigned long long))) >= 0)];
test_array [0] = 0

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_lo=0 ac_mid=0
  while :; do
    cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
int
main ()
{
static int test_array [1 - 2 * !(((long int) (sizeof (unsigned long long))) <= $ac_mid)];
test_array [0] = 0

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_hi=$ac_mid; break
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_lo=`expr $ac_mid + 1`
			if test $ac_lo -le $ac_mid; then
			  ac_lo= ac_hi=
			  break
			fi
			ac_mid=`expr 2 '*' $ac_mid + 1`
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  done
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
int
main ()
{
static int test_array [1 - 2 * !(((long int) (sizeof (unsigned long long))) < 0)];
test_array [0] = 0

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_hi=-1 ac_mid=-1
  while :; do
    cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
int
main ()
{
static int test_array [1 - 2 * !(((long int) (sizeof (unsigned long long))) >= $ac_mid)];
test_array [0] = 0

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_lo=$ac_mid; break
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_hi=`expr '(' $ac_mid ')' - 1`
			if test $ac_mid -le $ac_hi; then
			  ac_lo= ac_hi=
			  break
			fi
			ac_mid=`expr 2 '*' $ac_mid`
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
  done
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_lo= ac_hi=
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
# Binary search between lo and hi bounds.
while test "x$ac_lo" != "x$ac_hi"; do
  ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
int
main ()
{
static int test_array [1 - 2 * !(((long int) (sizeof (unsigned long long))) <= $ac_mid)];
test_array [0] = 0

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_hi=$ac_mid
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_lo=`expr '(' $ac_mid ')' + 1`
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
done
case $ac_lo in
?*) ac_cv_sizeof_unsigned_long_long=$ac_lo;;
'') if test "$ac_cv_type_unsigned_long_long" = yes; then
     { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long long)
See \`config.log' for more details." >&5
$as_echo "$as_me: error: cannot compute sizeof (unsigned long long)
See \`config.log' for more details." >&2;}
   { (exit 77); exit 77; }; }; }
   else
     ac_cv_sizeof_unsigned_long_long=0
   fi ;;
esac
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
static long int longval () { return (long int) (sizeof (unsigned long long)); }
static unsigned long int ulongval () { return (long int) (sizeof (unsigned long long)); }
#include <stdio.h>
#include <stdlib.h>
int
main ()
{

  FILE *f = fopen ("conftest.val", "w");
  if (! f)
    return 1;
  if (((long int) (sizeof (unsigned long long))) < 0)
    {
      long int i = longval ();
      if (i != ((long int) (sizeof (unsigned long long))))
	return 1;
      fprintf (f, "%ld", i);
    }
  else
    {
      unsigned long int i = ulongval ();
      if (i != ((long int) (sizeof (unsigned long long))))
	return 1;
      fprintf (f, "%lu", i);
    }
  /* Do not output a trailing newline, as this causes \r\n confusion
     on some platforms.  */
  return ferror (f) || fclose (f) != 0;

  ;
  return 0;
}
_ACEOF
rm -f conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
  { (case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_try") 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then
  ac_cv_sizeof_unsigned_long_long=`cat conftest.val`
else
  $as_echo "$as_me: program exited with status $ac_status" >&5
$as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

( exit $ac_status )
if test "$ac_cv_type_unsigned_long_long" = yes; then
     { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
{ { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long long)
See \`config.log' for more details." >&5
$as_echo "$as_me: error: cannot compute sizeof (unsigned long long)
See \`config.log' for more details." >&2;}
   { (exit 77); exit 77; }; }; }
   else
     ac_cv_sizeof_unsigned_long_long=0
   fi
fi
rm -rf conftest.dSYM
rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
rm -f conftest.val
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long_long" >&5
$as_echo "$ac_cv_sizeof_unsigned_long_long" >&6; }



cat >>confdefs.h <<_ACEOF
#define SIZEOF_UNSIGNED_LONG_LONG $ac_cv_sizeof_unsigned_long_long
_ACEOF


echo "---> size SIZEOF $SIZEOF_unsigned_long_long"
echo "---> size SIZEOF $ac_cv_sizeof_unsigned_long_long"
if test $ac_cv_sizeof_unsigned_long_long != 8 ; then
	{ { $as_echo "$as_me:$LINENO: error: ** we assume that sizeof(long long) == 8." >&5
$as_echo "$as_me: error: ** we assume that sizeof(long long) == 8." >&2;}
   { (exit 1); exit 1; }; }
fi

if test $target_cpu == "powerpc64"; then
	{ $as_echo "$as_me:$LINENO: WARNING: set compiler with -m64" >&5
$as_echo "$as_me: WARNING: set compiler with -m64" >&2;}
	CFLAGS="$CFLAGS -m64"
	CC="$CC -m64"
fi

CPPFLAGS="-I$PWD/$LIBCFS_INCLUDE_DIR -I$PWD/lnet/include -I$PWD/lustre/include $CPPFLAGS"

LLCPPFLAGS="-D__arch_lib__ -D_LARGEFILE64_SOURCE=1"


# Add _GNU_SOURCE for strnlen on linux
LLCFLAGS="-g -Wall -fPIC -D_GNU_SOURCE"


CCASFLAGS="-Wall -fPIC -D_GNU_SOURCE"


# everyone builds against lnet and lustre
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -g -I$PWD/$LIBCFS_INCLUDE_DIR -I$PWD/lnet/include -I$PWD/lustre/include"



{ $as_echo "$as_me:$LINENO: checking for osd" >&5
$as_echo_n "checking for osd... " >&6; }

# Check whether --with-osd was given.
if test "${with_osd+set}" = set; then
  withval=$with_osd;
		case $with_osd in
			no)     ENABLEOSDADDON=0
				;;
			*)	OSDADDON="${with_osd}"
				ENABLEOSDADDON=1
				;;
		esac

else

		ENABLEOSDADDON=0

fi

if test $ENABLEOSDADDON -eq 0; then
	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
	OSDADDON=
else
	OSDMODNAME=`basename $OSDADDON`
	if test -e $LUSTRE/$OSDMODNAME; then
		{ $as_echo "$as_me:$LINENO: result: can't link" >&5
$as_echo "can't link" >&6; }
		OSDADDON=
	elif ln -s $OSDADDON $LUSTRE/$OSDMODNAME; then
		{ $as_echo "$as_me:$LINENO: result: $OSDMODNAME" >&5
$as_echo "$OSDMODNAME" >&6; }
		OSDADDON="subdir-m += $OSDMODNAME"
	else
		{ $as_echo "$as_me:$LINENO: result: can't link" >&5
$as_echo "can't link" >&6; }
		OSDADDON=
	fi
fi



{ $as_echo "$as_me:$LINENO: checking whether to build docs" >&5
$as_echo_n "checking whether to build docs... " >&6; }
# Check whether --enable-doc was given.
if test "${enable_doc+set}" = set; then
  enableval=$enable_doc;
		if test x$enable_doc = xyes ; then
		    ENABLE_DOC=1
		else
		    ENABLE_DOC=0
		fi

else

		ENABLE_DOC=0
		enable_doc='no'

fi

{ $as_echo "$as_me:$LINENO: result: $enable_doc" >&5
$as_echo "$enable_doc" >&6; }


{ $as_echo "$as_me:$LINENO: checking whether to build utilities" >&5
$as_echo_n "checking whether to build utilities... " >&6; }
# Check whether --enable-utils was given.
if test "${enable_utils+set}" = set; then
  enableval=$enable_utils;
else
  enable_utils='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_utils" >&5
$as_echo "$enable_utils" >&6; }
if test x$enable_utils = xyes ; then
	ENABLE_INIT_SCRIPTS=0
if test x$enable_utils = xyes ; then
        { $as_echo "$as_me:$LINENO: checking whether to install init scripts" >&5
$as_echo_n "checking whether to install init scripts... " >&6; }
        # our scripts only work on red hat systems
        if test -f /etc/init.d/functions -a -f /etc/sysconfig/network ; then
                ENABLE_INIT_SCRIPTS=1
                { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
        else
                { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
        fi
fi


fi

{ $as_echo "$as_me:$LINENO: checking whether to build Lustre tests" >&5
$as_echo_n "checking whether to build Lustre tests... " >&6; }
# Check whether --enable-tests was given.
if test "${enable_tests+set}" = set; then
  enableval=$enable_tests;
else

		enable_tests='yes'

fi

{ $as_echo "$as_me:$LINENO: result: $enable_tests" >&5
$as_echo "$enable_tests" >&6; }

{ $as_echo "$as_me:$LINENO: checking whether to build Lustre client support" >&5
$as_echo_n "checking whether to build Lustre client support... " >&6; }
# Check whether --enable-client was given.
if test "${enable_client+set}" = set; then
  enableval=$enable_client;
else
  enable_client='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_client" >&5
$as_echo "$enable_client" >&6; }


# Check whether --enable-server was given.
if test "${enable_server+set}" = set; then
  enableval=$enable_server; if test x$enable_server != xyes -a x$enable_server != xno; then
  { { $as_echo "$as_me:$LINENO: error: server valid options are \"yes\" or \"no\"" >&5
$as_echo "$as_me: error: server valid options are \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; }
fi

	if test x$enable_server = xyes -a x$enable_dist = xyes; then
  { { $as_echo "$as_me:$LINENO: error: --enable-server cannot be used with --enable-dist" >&5
$as_echo "$as_me: error: --enable-server cannot be used with --enable-dist" >&2;}
   { (exit 1); exit 1; }; }
fi


else
  if test x$enable_dist = xyes; then
  enable_server=no
else
  enable_server=maybe
fi



fi


# There are at least two good reasons why we should really run
# LB_CONFIG_MODULES elsewhere before the call to LB_CONFIG_SERVERS:
# LB_CONFIG_MODULES needs to be run for client support even when
# servers are disabled, and because module support is actually a
# prerequisite of server support.  However, some things under
# LB_CONFIG_MODULES need us to already have checked for --disable-server,
# before running, so until LB_CONFIG_MODULES can be reorganized, we
# call it here.
{ $as_echo "$as_me:$LINENO: checking whether to build kernel modules" >&5
$as_echo_n "checking whether to build kernel modules... " >&6; }
# Check whether --enable-modules was given.
if test "${enable_modules+set}" = set; then
  enableval=$enable_modules;
else

		case $target_os in
	linux* | darwin*)

			enable_modules='yes'

		;;
	*)

			enable_modules='no'

		;;
esac


fi

{ $as_echo "$as_me:$LINENO: result: $enable_modules ($target_os)" >&5
$as_echo "$enable_modules ($target_os)" >&6; }

if test x$enable_modules = xyes ; then
	case $target_os in
		linux*)
			# prep some default values
for DEFAULT_LINUX in /lib/modules/$(uname -r)/{source,build} /usr/src/linux; do
	if readlink -q -e $DEFAULT_LINUX; then
		break
	fi
done
if test "$DEFAULT_LINUX" = "/lib/modules/$(uname -r)/source"; then
	PATHS="/lib/modules/$(uname -r)/build"
fi
PATHS+=" $DEFAULT_LINUX"
for DEFAULT_LINUX_OBJ in $PATHS; do
	if readlink -q -e $DEFAULT_LINUX_OBJ; then
		break
	fi
done
{ $as_echo "$as_me:$LINENO: checking for Linux sources" >&5
$as_echo_n "checking for Linux sources... " >&6; }

# Check whether --with-linux was given.
if test "${with_linux+set}" = set; then
  withval=$with_linux;

	LINUX=$(readlink -f $with_linux)

	new_configure_args=
	eval "set x $ac_configure_args"
	shift
	for arg; do
		case $arg in
			--with-linux=*)
				arg=--with-linux=$LINUX
				;;
			*\'*)
				arg=$(printf %s\n "$arg" | \
				      sed "s/'/'\\\\\\\\''/g")
				;;
		esac
				new_configure_args="$new_configure_args \"$arg\""
	done
	ac_configure_args=$new_configure_args



	DEFAULT_LINUX_OBJ=$LINUX
else
  LINUX=$DEFAULT_LINUX
fi

{ $as_echo "$as_me:$LINENO: result: $LINUX" >&5
$as_echo "$LINUX" >&6; }


# -------- check for linux --------
as_lb_File=`$as_echo "lb_cv_file_$LINUX" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX" >&5
$as_echo_n "checking for $LINUX... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  :
else
  { { $as_echo "$as_me:$LINENO: error: Kernel source $LINUX could not be found." >&5
$as_echo "$as_me: error: Kernel source $LINUX could not be found." >&2;}
   { (exit 1); exit 1; }; }
fi


# -------- linux objects (for 2.6) --
{ $as_echo "$as_me:$LINENO: checking for Linux objects dir" >&5
$as_echo_n "checking for Linux objects dir... " >&6; }

# Check whether --with-linux-obj was given.
if test "${with_linux_obj+set}" = set; then
  withval=$with_linux_obj;

	LINUX_OBJ=$(readlink -f $with_linux_obj)

	new_configure_args=
	eval "set x $ac_configure_args"
	shift
	for arg; do
		case $arg in
			--with-linux-obj=*)
				arg=--with-linux-obj=$LINUX_OBJ
				;;
			*\'*)
				arg=$(printf %s\n "$arg" | \
				      sed "s/'/'\\\\\\\\''/g")
				;;
		esac
				new_configure_args="$new_configure_args \"$arg\""
	done
	ac_configure_args=$new_configure_args



else
  LINUX_OBJ=$DEFAULT_LINUX_OBJ
fi


{ $as_echo "$as_me:$LINENO: result: $LINUX_OBJ" >&5
$as_echo "$LINUX_OBJ" >&6; }


# -------- check for .config --------

# Check whether --with-linux-config was given.
if test "${with_linux_config+set}" = set; then
  withval=$with_linux_config;

	LINUX_CONFIG=$(readlink -f $with_linux_config)

	new_configure_args=
	eval "set x $ac_configure_args"
	shift
	for arg; do
		case $arg in
			--with-linux-config=*)
				arg=--with-linux-config=$LINUX_CONFIG
				;;
			*\'*)
				arg=$(printf %s\n "$arg" | \
				      sed "s/'/'\\\\\\\\''/g")
				;;
		esac
				new_configure_args="$new_configure_args \"$arg\""
	done
	ac_configure_args=$new_configure_args



else
  LINUX_CONFIG=$LINUX_OBJ/.config
fi



{ $as_echo "$as_me:$LINENO: checking for /boot/kernel.h" >&5
$as_echo_n "checking for /boot/kernel.h... " >&6; }
if test "${lb_cv_file__boot_kernel_h+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -r "/boot/kernel.h"; then
	lb_cv_file__boot_kernel_h=yes
else
	lb_cv_file__boot_kernel_h=no
fi
fi
{ $as_echo "$as_me:$LINENO: result: $lb_cv_file__boot_kernel_h" >&5
$as_echo "$lb_cv_file__boot_kernel_h" >&6; }
if test $lb_cv_file__boot_kernel_h = yes; then
  KERNEL_SOURCE_HEADER='/boot/kernel.h'
else
  { $as_echo "$as_me:$LINENO: checking for /var/adm/running-kernel.h" >&5
$as_echo_n "checking for /var/adm/running-kernel.h... " >&6; }
if test "${lb_cv_file__var_adm_running_kernel_h+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -r "/var/adm/running-kernel.h"; then
	lb_cv_file__var_adm_running_kernel_h=yes
else
	lb_cv_file__var_adm_running_kernel_h=no
fi
fi
{ $as_echo "$as_me:$LINENO: result: $lb_cv_file__var_adm_running_kernel_h" >&5
$as_echo "$lb_cv_file__var_adm_running_kernel_h" >&6; }
if test $lb_cv_file__var_adm_running_kernel_h = yes; then
  KERNEL_SOURCE_HEADER='/var/adm/running-kernel.h'
fi

fi



# Check whether --with-kernel-source-header was given.
if test "${with_kernel_source_header+set}" = set; then
  withval=$with_kernel_source_header;

	KERNEL_SOURCE_HEADER=$(readlink -f $with_kernel_source_header)

	new_configure_args=
	eval "set x $ac_configure_args"
	shift
	for arg; do
		case $arg in
			--with-kernel-source-header=*)
				arg=--with-kernel-source-header=$KERNEL_SOURCE_HEADER
				;;
			*\'*)
				arg=$(printf %s\n "$arg" | \
				      sed "s/'/'\\\\\\\\''/g")
				;;
		esac
				new_configure_args="$new_configure_args \"$arg\""
	done
	ac_configure_args=$new_configure_args



fi


# ------------ .config exists ----------------
as_lb_File=`$as_echo "lb_cv_file_$LINUX_CONFIG" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX_CONFIG" >&5
$as_echo_n "checking for $LINUX_CONFIG... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX_CONFIG"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  :
else
  { { $as_echo "$as_me:$LINENO: error: Kernel config could not be found.  If you are building from a kernel-source rpm consult build/README.kernel-source" >&5
$as_echo "$as_me: error: Kernel config could not be found.  If you are building from a kernel-source rpm consult build/README.kernel-source" >&2;}
   { (exit 1); exit 1; }; }
fi


# ----------- make dep run? ------------------
# at 2.6.19 # $LINUX/include/linux/config.h is removed
# and at more old has only one line
# include <autoconf.h>
as_lb_File=`$as_echo "lb_cv_file_$LINUX_OBJ/include/generated/autoconf.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX_OBJ/include/generated/autoconf.h" >&5
$as_echo_n "checking for $LINUX_OBJ/include/generated/autoconf.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX_OBJ/include/generated/autoconf.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  AUTOCONF_HDIR=generated
else
  as_lb_File=`$as_echo "lb_cv_file_$LINUX_OBJ/include/linux/autoconf.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX_OBJ/include/linux/autoconf.h" >&5
$as_echo_n "checking for $LINUX_OBJ/include/linux/autoconf.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX_OBJ/include/linux/autoconf.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  AUTOCONF_HDIR=linux
else
  { { $as_echo "$as_me:$LINENO: error: Run make config in $LINUX." >&5
$as_echo "$as_me: error: Run make config in $LINUX." >&2;}
   { (exit 1); exit 1; }; }
fi

fi


as_lb_File=`$as_echo "lb_cv_file_$LINUX_OBJ/include/linux/version.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX_OBJ/include/linux/version.h" >&5
$as_echo_n "checking for $LINUX_OBJ/include/linux/version.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX_OBJ/include/linux/version.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  VERSION_HDIR=linux
else
  as_lb_File=`$as_echo "lb_cv_file_$LINUX_OBJ/include/generated/uapi/linux/version.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX_OBJ/include/generated/uapi/linux/version.h" >&5
$as_echo_n "checking for $LINUX_OBJ/include/generated/uapi/linux/version.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX_OBJ/include/generated/uapi/linux/version.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  VERSION_HDIR=generated/uapi/linux
else
  { { $as_echo "$as_me:$LINENO: error: Run make config in $LINUX." >&5
$as_echo "$as_me: error: Run make config in $LINUX." >&2;}
   { (exit 1); exit 1; }; }
fi


fi



# ----------- kconfig.h exists ---------------
# kernel 3.1, $LINUX/include/linux/kconfig.h is added
# see kernel commit 2a11c8ea20bf850b3a2c60db8c2e7497d28aba99
as_lb_File=`$as_echo "lb_cv_file_$LINUX_OBJ/include/linux/kconfig.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX_OBJ/include/linux/kconfig.h" >&5
$as_echo_n "checking for $LINUX_OBJ/include/linux/kconfig.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX_OBJ/include/linux/kconfig.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  CONFIG_INCLUDE=include/linux/kconfig.h
else
  CONFIG_INCLUDE=include/$AUTOCONF_HDIR/autoconf.h
fi



# ------------ rhconfig.h includes runtime-generated bits --
# red hat kernel-source checks

# we know this exists after the check above.  if the user
# tarred up the tree and ran make dep etc. in it, then
# version.h gets overwritten with a standard linux one.

if grep rhconfig $LINUX_OBJ/include/$VERSION_HDIR/version.h >/dev/null ; then
	# This is a clean kernel-source tree, we need to
	# enable extensive workarounds to get this to build
	# modules
	as_lb_File=`$as_echo "lb_cv_file_$KERNEL_SOURCE_HEADER" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $KERNEL_SOURCE_HEADER" >&5
$as_echo_n "checking for $KERNEL_SOURCE_HEADER... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$KERNEL_SOURCE_HEADER"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  if test $KERNEL_SOURCE_HEADER = '/boot/kernel.h' ; then
			{ $as_echo "$as_me:$LINENO: WARNING: Using /boot/kernel.h from RUNNING kernel." >&5
$as_echo "$as_me: WARNING: Using /boot/kernel.h from RUNNING kernel." >&2;}
			{ $as_echo "$as_me:$LINENO: WARNING: If this is not what you want, use --with-kernel-source-header." >&5
$as_echo "$as_me: WARNING: If this is not what you want, use --with-kernel-source-header." >&2;}
			{ $as_echo "$as_me:$LINENO: WARNING: Consult build/README.kernel-source for details." >&5
$as_echo "$as_me: WARNING: Consult build/README.kernel-source for details." >&2;}
		fi
else
  { { $as_echo "$as_me:$LINENO: error: $KERNEL_SOURCE_HEADER not found.  Consult build/README.kernel-source for details." >&5
$as_echo "$as_me: error: $KERNEL_SOURCE_HEADER not found.  Consult build/README.kernel-source for details." >&2;}
   { (exit 1); exit 1; }; }
fi

	EXTRA_KCFLAGS="-include $KERNEL_SOURCE_HEADER $EXTRA_KCFLAGS"
fi

# this is needed before we can build modules
{ $as_echo "$as_me:$LINENO: checking for cross compilation" >&5
$as_echo_n "checking for cross compilation... " >&6; }
if test "x$cross_compiling" = xno; then
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
else
  case $host_vendor in
		# The K1OM architecture is an extension of the x86 architecture
		# and in MPSS 2.1 it's defined in $host_vendor. But in MPSS 3.x
		# it's defined in $host_arch. So, try to support both case.
		k1om | mpss)
			{ $as_echo "$as_me:$LINENO: result: Intel(R) Xeon Phi(TM)" >&5
$as_echo "Intel(R) Xeon Phi(TM)" >&6; }
			CC_TARGET_ARCH=`$CC -v 2>&1 | grep Target: | sed -e 's/Target: //'`

			if test \( $CC_TARGET_ARCH != x86_64-k1om-linux \
				-a $CC_TARGET_ARCH != k1om-mpss-linux \)
			then
				{ { $as_echo "$as_me:$LINENO: error: Cross compiler not found in PATH." >&5
$as_echo "$as_me: error: Cross compiler not found in PATH." >&2;}
   { (exit 1); exit 1; }; }
			fi
			CROSS_VARS="ARCH=k1om CROSS_COMPILE=${CC_TARGET_ARCH}-"
			CROSS_PATH="${CROSS_PATH:=/opt/lustre/${VERSION}/${CC_TARGET_ARCH}}"
			CCAS=$CC
			# need to produce special section for debuginfo extraction
			LDFLAGS="${LDFLAGS} -Wl,--build-id"
			EXTRA_KLDFLAGS="${EXTRA_KLDFLAGS} -Wl,--build-id"
			if test x$enable_server != xno ; then
				{ $as_echo "$as_me:$LINENO: WARNING: Disabling server (not supported for k1om architecture)." >&5
$as_echo "$as_me: WARNING: Disabling server (not supported for k1om architecture)." >&2;}
				enable_server='no'
			fi
			;;
		*)
			{ $as_echo "$as_me:$LINENO: result: yes, but no changes" >&5
$as_echo "yes, but no changes" >&6; }
			;;
	esac

fi





KMODEXT=".ko"

MODULE_TARGET="SUBDIRS"
makerule="$PWD/build"
{ $as_echo "$as_me:$LINENO: checking for external module build support" >&5
$as_echo_n "checking for external module build support... " >&6; }
rm -f build/conftest.i
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

int
main (void)
{

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d $makerule LUSTRE_KERNEL_TEST=conftest.i ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.i'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		makerule="_module_$makerule"
		MODULE_TARGET="M"
		cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

int
main (void)
{

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d $makerule LUSTRE_KERNEL_TEST=conftest.i ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.i'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

				{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


				{ { $as_echo "$as_me:$LINENO: error: unknown; check config.log for details" >&5
$as_echo "$as_me: error: unknown; check config.log for details" >&2;}
   { (exit 1); exit 1; }; }


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c



fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c






# --- check that we can build modules at all
{ $as_echo "$as_me:$LINENO: checking that modules can be built at all" >&5
$as_echo_n "checking that modules can be built at all... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

int
main (void)
{

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
	{ $as_echo "$as_me:$LINENO: WARNING: Consult config.log for details." >&5
$as_echo "$as_me: WARNING: Consult config.log for details." >&2;}
	{ $as_echo "$as_me:$LINENO: WARNING: If you are trying to build with a kernel-source rpm, consult build/README.kernel-source" >&5
$as_echo "$as_me: WARNING: If you are trying to build with a kernel-source rpm, consult build/README.kernel-source" >&2;}
	{ { $as_echo "$as_me:$LINENO: error: Kernel modules cannot be built." >&5
$as_echo "$as_me: error: Kernel modules cannot be built." >&2;}
   { (exit 1); exit 1; }; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c



	{ $as_echo "$as_me:$LINENO: checking kernel source version" >&5
$as_echo_n "checking kernel source version... " >&6; }

	utsrelease1=${LINUX_OBJ}/include/generated/utsrelease.h
	utsrelease2=${LINUX_OBJ}/include/linux/utsrelease.h
	utsrelease3=${LINUX_OBJ}/include/linux/version.h
	if test -r ${utsrelease1} && fgrep -q UTS_RELEASE ${utsrelease1}; then

		utsrelease=${utsrelease1}

elif test -r ${utsrelease2} && fgrep -q UTS_RELEASE ${utsrelease2}; then

		utsrelease=${utsrelease2}

elif test -r ${utsrelease3} && fgrep -q UTS_RELEASE ${utsrelease3}; then

		utsrelease=${utsrelease3}

fi


	if test ! -z "${utsrelease}"; then

		UTS_RELEASE=$(awk -F \" '/ UTS_RELEASE / { print $2 }' \
		              ${utsrelease})
		if test -z "$UTS_RELEASE"; then

			{ $as_echo "$as_me:$LINENO: result: Not found" >&5
$as_echo "Not found" >&6; }
			{ { $as_echo "$as_me:$LINENO: error: *** Cannot determine kernel version." >&5
$as_echo "$as_me: error: *** Cannot determine kernel version." >&2;}
   { (exit 1); exit 1; }; }

fi


else

		{ $as_echo "$as_me:$LINENO: result: Not found" >&5
$as_echo "Not found" >&6; }
		{ { $as_echo "$as_me:$LINENO: error:
	*** Cannot find UTS_RELEASE definition.
	*** This is often provided by the kernel-devel package." >&5
$as_echo "$as_me: error:
	*** Cannot find UTS_RELEASE definition.
	*** This is often provided by the kernel-devel package." >&2;}
   { (exit 1); exit 1; }; }

fi


	{ $as_echo "$as_me:$LINENO: result: ${UTS_RELEASE}" >&5
$as_echo "${UTS_RELEASE}" >&6; }

	LINUX_VERSION=${UTS_RELEASE}

	LINUXRELEASE=${UTS_RELEASE}



# ------------ RELEASE --------------------------------
{ $as_echo "$as_me:$LINENO: checking for Lustre release" >&5
$as_echo_n "checking for Lustre release... " >&6; }

# Check whether --with-release was given.
if test "${with_release+set}" = set; then
  withval=$with_release; RELEASE=$withval
else

	RELEASE=""
	if test -n "$DOWNSTREAM_RELEASE"; then
		RELEASE="${DOWNSTREAM_RELEASE}_"
	fi
	RELEASE="$RELEASE`echo ${LINUXRELEASE} | tr '-' '_'`_$BUILDID"
fi

{ $as_echo "$as_me:$LINENO: result: $RELEASE" >&5
$as_echo "$RELEASE" >&6; }


# check if the kernel is one from RHEL or SUSE
{ $as_echo "$as_me:$LINENO: checking for RedHat kernel version" >&5
$as_echo_n "checking for RedHat kernel version... " >&6; }
	if fgrep -q RHEL_RELEASE ${LINUX_OBJ}/include/$VERSION_HDIR/version.h; then

		RHEL_KERNEL="yes"
		RHEL_RELEASE=$(expr 0$(awk -F \" '/ RHEL_RELEASE / { print $2 }' \
			       ${LINUX_OBJ}/include/$VERSION_HDIR/version.h) + 1)
		KERNEL_VERSION=$(sed -e 's/\([23]\.[0-9]*\.[0-9]*\).*/\1/' <<< ${LINUXRELEASE})
		RHEL_KERNEL_VERSION=${KERNEL_VERSION}-${RHEL_RELEASE}

		{ $as_echo "$as_me:$LINENO: result: ${RHEL_KERNEL_VERSION}" >&5
$as_echo "${RHEL_KERNEL_VERSION}" >&6; }

else

		{ $as_echo "$as_me:$LINENO: result: not found" >&5
$as_echo "not found" >&6; }

	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_SUSE_KERNEL" >&5
$as_echo_n "checking if Linux was built with CONFIG_SUSE_KERNEL... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#ifndef CONFIG_SUSE_KERNEL
		#error CONFIG_SUSE_KERNEL not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
		SUSE_KERNEL="yes"

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


fi


{ $as_echo "$as_me:$LINENO: checking for kernel module package directory" >&5
$as_echo_n "checking for kernel module package directory... " >&6; }

# Check whether --with-kmp-moddir was given.
if test "${with_kmp_moddir+set}" = set; then
  withval=$with_kmp_moddir; KMP_MODDIR=$withval
else

	if test x$RHEL_KERNEL = xyes; then
  KMP_MODDIR="extra"
elif test x$SUSE_KERNEL = xyes; then
  KMP_MODDIR="updates"
fi

fi


{ $as_echo "$as_me:$LINENO: result: $KMP_MODDIR" >&5
$as_echo "$KMP_MODDIR" >&6; }


moduledir='$(CROSS_PATH)/lib/modules/$(LINUXRELEASE)/$(KMP_MODDIR)/kernel'


modulefsdir='$(moduledir)/fs/$(PACKAGE)'


modulenetdir='$(moduledir)/net/$(PACKAGE)'




{ $as_echo "$as_me:$LINENO: checking Linux kernel architecture" >&5
$as_echo_n "checking Linux kernel architecture... " >&6; }
          if rm -f $PWD/build/arch
                 make -s --no-print-directory echoarch -f $PWD/build/Makefile \
                     LUSTRE_LINUX_CONFIG=$LINUX_CONFIG -C $LINUX $CROSS_VARS  \
                     ARCHFILE=$PWD/build/arch && LINUX_ARCH=`cat $PWD/build/arch`; then
  { $as_echo "$as_me:$LINENO: result: $LINUX_ARCH" >&5
$as_echo "$LINUX_ARCH" >&6; }
else
  { { $as_echo "$as_me:$LINENO: error: Could not determine the kernel architecture." >&5
$as_echo "$as_me: error: Could not determine the kernel architecture." >&2;}
   { (exit 1); exit 1; }; }
fi

          rm -f build/arch
{ $as_echo "$as_me:$LINENO: checking name of module symbol version file" >&5
$as_echo_n "checking name of module symbol version file... " >&6; }
	if grep -q Modules.symvers $LINUX/scripts/Makefile.modpost ; then
		SYMVERFILE=Modules.symvers
	else
		SYMVERFILE=Module.symvers
	fi
	{ $as_echo "$as_me:$LINENO: result: $SYMVERFILE" >&5
$as_echo "$SYMVERFILE" >&6; }





	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_MODULES" >&5
$as_echo_n "checking if Linux was built with CONFIG_MODULES... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#ifndef CONFIG_MODULES
		#error CONFIG_MODULES not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

	{ { $as_echo "$as_me:$LINENO: error: module support is required to build Lustre kernel modules." >&5
$as_echo "$as_me: error: module support is required to build Lustre kernel modules." >&2;}
   { (exit 1); exit 1; }; }


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c



	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_MODVERSIONS" >&5
$as_echo_n "checking if Linux was built with CONFIG_MODVERSIONS... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#ifndef CONFIG_MODVERSIONS
		#error CONFIG_MODVERSIONS not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c



	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_KALLSYMS" >&5
$as_echo_n "checking if Linux was built with CONFIG_KALLSYMS... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#ifndef CONFIG_KALLSYMS
		#error CONFIG_KALLSYMS not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

	{ { $as_echo "$as_me:$LINENO: error: Lustre requires that CONFIG_KALLSYMS is enabled in your kernel." >&5
$as_echo "$as_me: error: Lustre requires that CONFIG_KALLSYMS is enabled in your kernel." >&2;}
   { (exit 1); exit 1; }; }


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


# 2.6.28
{ $as_echo "$as_me:$LINENO: checking if kernel module loading is possible" >&5
$as_echo_n "checking if kernel module loading is possible... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/kmod.h>

int
main (void)
{

	int myretval=ENOSYS ;
	return myretval;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d
	$makerule LUSTRE_KERNEL_TEST=conftest.i
 ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='	grep request_module build/conftest.i |		grep -v `grep "int myretval=" build/conftest.i |			cut -d= -f2 | cut -d" "  -f1`		>/dev/null '
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_MODULE_LOADING_SUPPORT 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
	{ $as_echo "$as_me:$LINENO: WARNING: " >&5
$as_echo "$as_me: WARNING: " >&2;}
	{ $as_echo "$as_me:$LINENO: WARNING: Kernel module loading support is highly recommended." >&5
$as_echo "$as_me: WARNING: Kernel module loading support is highly recommended." >&2;}
	{ $as_echo "$as_me:$LINENO: WARNING: " >&5
$as_echo "$as_me: WARNING: " >&2;}


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c



{ $as_echo "$as_me:$LINENO: checking whether to use Compat RDMA" >&5
$as_echo_n "checking whether to use Compat RDMA... " >&6; }
# set default

# Check whether --with-o2ib was given.
if test "${with_o2ib+set}" = set; then
  withval=$with_o2ib;
		case $with_o2ib in
		yes)    O2IBPATHS="$LINUX $LINUX/drivers/infiniband"
			ENABLEO2IB=2
			;;
		no)     ENABLEO2IB=0
			;;
		*)      O2IBPATHS=$with_o2ib
			ENABLEO2IB=3
			;;
		esac

else

		O2IBPATHS="$LINUX $LINUX/drivers/infiniband"
		ENABLEO2IB=1

fi

if test $ENABLEO2IB -eq 0; then
	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
else
	o2ib_found=false
	for O2IBPATH in $O2IBPATHS; do
		if test \( -f ${O2IBPATH}/include/rdma/rdma_cm.h -a \
			   -f ${O2IBPATH}/include/rdma/ib_cm.h -a \
			   -f ${O2IBPATH}/include/rdma/ib_verbs.h -a \
			   -f ${O2IBPATH}/include/rdma/ib_fmr_pool.h \); then
			o2ib_found=true
			break
		fi
	done
	compatrdma_found=false
	if $o2ib_found; then
		if test \( -f ${O2IBPATH}/include/linux/compat-2.6.h \); then
			compatrdma_found=true
			{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_COMPAT_RDMA 1
_ACEOF

		else
			{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		fi
	fi
fi


# it's ugly to be doing anything with OFED outside of the lnet module, but
# this has to be done here so that the backports path is set before all of
# the LN_PROG_LINUX checks are done
{ $as_echo "$as_me:$LINENO: checking whether to use any OFED backport headers" >&5
$as_echo_n "checking whether to use any OFED backport headers... " >&6; }
if test $ENABLEO2IB -eq 0; then
	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
else
	if ! $o2ib_found; then
		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		case $ENABLEO2IB in
			1) ;;
			2) { { $as_echo "$as_me:$LINENO: error: kernel OpenIB gen2 headers not present" >&5
$as_echo "$as_me: error: kernel OpenIB gen2 headers not present" >&2;}
   { (exit 1); exit 1; }; };;
			3) { { $as_echo "$as_me:$LINENO: error: bad --with-o2ib path" >&5
$as_echo "$as_me: error: bad --with-o2ib path" >&2;}
   { (exit 1); exit 1; }; };;
			*) { { $as_echo "$as_me:$LINENO: error: internal error" >&5
$as_echo "$as_me: error: internal error" >&2;}
   { (exit 1); exit 1; }; };;
		esac
	else
		if ! $compatrdma_found; then
			if test -f $O2IBPATH/config.mk; then
				. $O2IBPATH/config.mk
			elif test -f $O2IBPATH/ofed_patch.mk; then
				. $O2IBPATH/ofed_patch.mk
			fi
		else
			if test x$RHEL_KERNEL = xyes; then
				case $RHEL_KERNEL_VERSION in
					2.6.32-358*)
						EXTRA_LNET_INCLUDE="$EXTRA_LNET_INCLUDE -DCONFIG_COMPAT_RHEL_6_4";;
					2.6.32-431*)
						EXTRA_LNET_INCLUDE="$EXTRA_LNET_INCLUDE -DCONFIG_COMPAT_RHEL_6_5";;
				esac
			elif test x$SUSE_KERNEL = xyes; then
				SP=$(grep PATCHLEVEL /etc/SuSE-release | sed -e 's/.*= *//')
				EXTRA_LNET_INCLUDE="$EXTRA_LNET_INCLUDE -DCONFIG_COMPAT_SLES_11_$SP"
			fi
		fi
		if test -n "$BACKPORT_INCLUDES"; then
			OFED_BACKPORT_PATH="$O2IBPATH/${BACKPORT_INCLUDES/*\/kernel_addons/kernel_addons}/"
			EXTRA_LNET_INCLUDE="-I$OFED_BACKPORT_PATH $EXTRA_LNET_INCLUDE"
			{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
		else
			{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		fi
	fi
fi



{ $as_echo "$as_me:$LINENO: checking for tunable panic_dumplog support" >&5
$as_echo_n "checking for tunable panic_dumplog support... " >&6; }
# Check whether --enable-panic_dumplog was given.
if test "${enable_panic_dumplog+set}" = set; then
  enableval=$enable_panic_dumplog;
else
  enable_panic_dumplog='no'
fi

if test x$enable_panic_dumplog = xyes ; then

cat >>confdefs.h <<\_ACEOF
#define LNET_DUMP_ON_PANIC 1
_ACEOF

       { $as_echo "$as_me:$LINENO: result: yes (by request)" >&5
$as_echo "yes (by request)" >&6; }
else
       { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi



{ $as_echo "$as_me:$LINENO: checking kernel __u64 is long long type" >&5
$as_echo_n "checking kernel __u64 is long long type... " >&6; }
tmp_flags="$EXTRA_KCFLAGS"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -Werror"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/types.h>
	#include <linux/stddef.h>

int
main (void)
{

	unsigned long long *data;

	data = (__u64*)sizeof(data);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_KERN__U64_LONG_LONG 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
EXTRA_KCFLAGS="$tmp_flags"

# 2.6.24
{ $as_echo "$as_me:$LINENO: checking for CTL_UNNUMBERED" >&5
$as_echo_n "checking for CTL_UNNUMBERED... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/sysctl.h>

int
main (void)
{

	#ifndef CTL_UNNUMBERED
	#error CTL_UNNUMBERED not exist in kernel
	#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_SYSCTL_UNNUMBERED 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: NO" >&5
$as_echo "NO" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

{ $as_echo "$as_me:$LINENO: checking if Linux was built with symbol dump_trace exported" >&5
$as_echo_n "checking if Linux was built with symbol dump_trace exported... " >&6; }
grep -q -E '[[:space:]]dump_trace[[:space:]]' $LINUX_OBJ/$SYMVERFILE 2>/dev/null
rc=$?
if test $rc -ne 0; then
	export=0
	for file in kernel/ksyms.c arch/${LINUX_ARCH%_64}/kernel/traps_64.c arch/x86/kernel/dumpstack_32.c arch/x86/kernel/dumpstack_64.c; do
		grep -q -E "EXPORT_SYMBOL.*\(dump_trace\)" "$LINUX/$file" 2>/dev/null
		rc=$?
		if test $rc -eq 0; then
			export=1
			break;
		fi
	done
	if test $export -eq 0; then
		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

	else
		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

	tmp_flags="$EXTRA_KCFLAGS"
	EXTRA_KCFLAGS="-Werror"
	{ $as_echo "$as_me:$LINENO: checking whether we can really use dump_trace" >&5
$as_echo_n "checking whether we can really use dump_trace... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		struct task_struct;
		struct pt_regs;
		#include <asm/stacktrace.h>

int
main (void)
{


  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_DUMP_TRACE 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
	{ $as_echo "$as_me:$LINENO: checking whether print_trace_address has reliable argument" >&5
$as_echo_n "checking whether print_trace_address has reliable argument... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		struct task_struct;
		struct pt_regs;
		#include <asm/stacktrace.h>

int
main (void)
{

		((struct stacktrace_ops *)0)->address(NULL, 0, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_TRACE_ADDRESS_RELIABLE 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
	{ $as_echo "$as_me:$LINENO: checking whether stacktrace_ops.warning is exist" >&5
$as_echo_n "checking whether stacktrace_ops.warning is exist... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		struct task_struct;
		struct pt_regs;
		#include <asm/stacktrace.h>

int
main (void)
{

		((struct stacktrace_ops *)0)->warning(NULL, NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_STACKTRACE_WARNING 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
	{ $as_echo "$as_me:$LINENO: checking dump_trace want address" >&5
$as_echo_n "checking dump_trace want address... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		struct task_struct;
		struct pt_regs;
		#include <asm/stacktrace.h>

int
main (void)
{

		dump_trace(NULL, NULL, NULL, 0, NULL, NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_DUMP_TRACE_ADDRESS 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

EXTRA_KCFLAGS="$tmp_flags"

	fi
else
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

	tmp_flags="$EXTRA_KCFLAGS"
	EXTRA_KCFLAGS="-Werror"
	{ $as_echo "$as_me:$LINENO: checking whether we can really use dump_trace" >&5
$as_echo_n "checking whether we can really use dump_trace... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		struct task_struct;
		struct pt_regs;
		#include <asm/stacktrace.h>

int
main (void)
{


  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_DUMP_TRACE 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
	{ $as_echo "$as_me:$LINENO: checking whether print_trace_address has reliable argument" >&5
$as_echo_n "checking whether print_trace_address has reliable argument... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		struct task_struct;
		struct pt_regs;
		#include <asm/stacktrace.h>

int
main (void)
{

		((struct stacktrace_ops *)0)->address(NULL, 0, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_TRACE_ADDRESS_RELIABLE 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
	{ $as_echo "$as_me:$LINENO: checking whether stacktrace_ops.warning is exist" >&5
$as_echo_n "checking whether stacktrace_ops.warning is exist... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		struct task_struct;
		struct pt_regs;
		#include <asm/stacktrace.h>

int
main (void)
{

		((struct stacktrace_ops *)0)->warning(NULL, NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_STACKTRACE_WARNING 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
	{ $as_echo "$as_me:$LINENO: checking dump_trace want address" >&5
$as_echo_n "checking dump_trace want address... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		struct task_struct;
		struct pt_regs;
		#include <asm/stacktrace.h>

int
main (void)
{

		dump_trace(NULL, NULL, NULL, 0, NULL, NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_DUMP_TRACE_ADDRESS 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

EXTRA_KCFLAGS="$tmp_flags"

fi


as_lb_File=`$as_echo "lb_cv_file_$LINUX/include/linux/key-type.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX/include/linux/key-type.h" >&5
$as_echo_n "checking for $LINUX/include/linux/key-type.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX/include/linux/key-type.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_LINUX_KEYTYPE_H 1
_ACEOF


else

        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi


# 2.6.30
{ $as_echo "$as_me:$LINENO: checking sock_map_fd have second argument" >&5
$as_echo_n "checking sock_map_fd have second argument... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/net.h>

int
main (void)
{

        sock_map_fd(NULL, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_SOCK_MAP_FD_2ARG 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: NO" >&5
$as_echo "NO" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

# 2.6.32
{ $as_echo "$as_me:$LINENO: checking if 'struct stacktrace_ops' has 'walk_stack' field" >&5
$as_echo_n "checking if 'struct stacktrace_ops' has 'walk_stack' field... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <asm/stacktrace.h>

int
main (void)
{

        ((struct stacktrace_ops *)0)->walk_stack(NULL, NULL, 0, NULL, NULL, NULL, NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define STACKTRACE_OPS_HAVE_WALK_STACK 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

{ $as_echo "$as_me:$LINENO: checking shrinker want self pointer in handler" >&5
$as_echo_n "checking shrinker want self pointer in handler... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/mm.h>

int
main (void)
{

        struct shrinker *tmp = NULL;
        tmp->shrink(tmp, 0, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_SHRINKER_WANT_SHRINK_PTR 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

# 2.6.33
{ $as_echo "$as_me:$LINENO: checking if ctl_table has a ctl_name field" >&5
$as_echo_n "checking if ctl_table has a ctl_name field... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/sysctl.h>

int
main (void)
{

        struct ctl_table ct;
        ct.ctl_name = sizeof(ct);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_SYSCTL_CTLNAME 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

# 2.6.34
{ $as_echo "$as_me:$LINENO: checking if __add_wait_queue_exclusive exists" >&5
$as_echo_n "checking if __add_wait_queue_exclusive exists... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/wait.h>

int
main (void)
{

        wait_queue_head_t queue;
        wait_queue_t      wait;

        __add_wait_queue_exclusive(&queue, &wait);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE___ADD_WAIT_QUEUE_EXCLUSIVE 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

# 2.6.35
{ $as_echo "$as_me:$LINENO: checking if kernel has sk_sleep" >&5
$as_echo_n "checking if kernel has sk_sleep... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <net/sock.h>

int
main (void)
{

        sk_sleep(NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_SK_SLEEP 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

# 2.6.40 fc15
{ $as_echo "$as_me:$LINENO: checking shrink_control is present" >&5
$as_echo_n "checking shrink_control is present... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/mm.h>

int
main (void)
{

        struct shrink_control tmp = {0};
        tmp.nr_to_scan = sizeof(tmp);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_SHRINK_CONTROL 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

# 3.7
{ $as_echo "$as_me:$LINENO: checking sock_alloc_file is exported" >&5
$as_echo_n "checking sock_alloc_file is exported... " >&6; }
{ $as_echo "$as_me:$LINENO: checking if Linux was built with symbol sock_alloc_file exported" >&5
$as_echo_n "checking if Linux was built with symbol sock_alloc_file exported... " >&6; }
grep -q -E '[[:space:]]sock_alloc_file[[:space:]]' $LINUX_OBJ/$SYMVERFILE 2>/dev/null
rc=$?
if test $rc -ne 0; then
	export=0
	for file in net/socket.c; do
		grep -q -E "EXPORT_SYMBOL.*\(sock_alloc_file\)" "$LINUX/$file" 2>/dev/null
		rc=$?
		if test $rc -eq 0; then
			export=1
			break;
		fi
	done
	if test $export -eq 0; then
		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }


	else
		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/net.h>

int
main (void)
{

		sock_alloc_file(NULL, 0, NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_SOCK_ALLOC_FILE_3ARGS 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_SOCK_ALLOC_FILE 1
_ACEOF


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	fi
else
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/net.h>

int
main (void)
{

		sock_alloc_file(NULL, 0, NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_SOCK_ALLOC_FILE_3ARGS 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_SOCK_ALLOC_FILE 1
_ACEOF


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

fi




{ $as_echo "$as_me:$LINENO: checking if dev_get_by_name has two args" >&5
$as_echo_n "checking if dev_get_by_name has two args... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/netdevice.h>

int
main (void)
{

        dev_get_by_name(NULL, NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_DEV_GET_BY_NAME_2ARG 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

# Check whether --enable-affinity was given.
if test "${enable_affinity+set}" = set; then
  enableval=$enable_affinity;
else
  enable_affinity='yes'
fi


{ $as_echo "$as_me:$LINENO: checking for CPU affinity support" >&5
$as_echo_n "checking for CPU affinity support... " >&6; }
if test x$enable_affinity = xno ; then
	{ $as_echo "$as_me:$LINENO: result: no (by request)" >&5
$as_echo "no (by request)" >&6; }
else
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/sched.h>

int
main (void)
{

		struct task_struct *t;
		#if HAVE_CPUMASK_T
		cpumask_t     m;
	        #else
	        unsigned long m;
		#endif
		set_cpus_allowed_ptr(t, &m);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define CPU_AFFINITY 1
_ACEOF

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no (no kernel support)" >&5
$as_echo "no (no kernel support)" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
fi

{ $as_echo "$as_me:$LINENO: checking for tunable backoff TCP support" >&5
$as_echo_n "checking for tunable backoff TCP support... " >&6; }
# Check whether --enable-backoff was given.
if test "${enable_backoff+set}" = set; then
  enableval=$enable_backoff;
else
  enable_backoff='yes'
fi

if test x$enable_backoff = xno ; then
       { $as_echo "$as_me:$LINENO: result: no (by request)" >&5
$as_echo "no (by request)" >&6; }
else
       BOCD="`grep -c TCP_BACKOFF $LINUX/include/linux/tcp.h`"
       if test "$BOCD" != 0 ; then

cat >>confdefs.h <<\_ACEOF
#define SOCKNAL_BACKOFF 1
_ACEOF

               { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
               if grep rto_max $LINUX/include/linux/tcp.h|grep -q __u16; then

cat >>confdefs.h <<\_ACEOF
#define SOCKNAL_BACKOFF_MS 1
_ACEOF

               fi
       else
               { $as_echo "$as_me:$LINENO: result: no (no kernel support)" >&5
$as_echo "no (no kernel support)" >&6; }
       fi
fi

{ $as_echo "$as_me:$LINENO: checking for QsNet sources" >&5
$as_echo_n "checking for QsNet sources... " >&6; }

# Check whether --with-qsnet was given.
if test "${with_qsnet+set}" = set; then
  withval=$with_qsnet; QSNET=$with_qsnet
else
  QSNET=$LINUX
fi

{ $as_echo "$as_me:$LINENO: result: $QSNET" >&5
$as_echo "$QSNET" >&6; }

{ $as_echo "$as_me:$LINENO: checking if quadrics kernel headers are present" >&5
$as_echo_n "checking if quadrics kernel headers are present... " >&6; }
if test -d $QSNET/drivers/net/qsnet ; then
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
	QSWLND="qswlnd"
	{ $as_echo "$as_me:$LINENO: checking for multirail EKC" >&5
$as_echo_n "checking for multirail EKC... " >&6; }
	if test -f $QSNET/include/elan/epcomms.h; then
		QSNET=$(readlink --canonicalize $QSNET)
		{ $as_echo "$as_me:$LINENO: result: supported" >&5
$as_echo "supported" >&6; }
		QSWCPPFLAGS="-I$QSNET/include -DMULTIRAIL_EKC=1"
	else
		{ $as_echo "$as_me:$LINENO: result: not supported" >&5
$as_echo "not supported" >&6; }
		{ { $as_echo "$as_me:$LINENO: error: Need multirail EKC" >&5
$as_echo "$as_me: error: Need multirail EKC" >&2;}
   { (exit 1); exit 1; }; }
	fi

	if test x$QSNET = x$LINUX ; then

	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_QSNET" >&5
$as_echo_n "checking if Linux was built with CONFIG_QSNET... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#ifndef CONFIG_QSNET
		#error CONFIG_QSNET not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }


	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_QSNET_MODULE" >&5
$as_echo_n "checking if Linux was built with CONFIG_QSNET_MODULE... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#ifndef CONFIG_QSNET_MODULE
		#error CONFIG_QSNET_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

				{ $as_echo "$as_me:$LINENO: WARNING: QSNET is not enabled in this kernel; not building qswlnd." >&5
$as_echo "$as_me: WARNING: QSNET is not enabled in this kernel; not building qswlnd." >&2;}
				QSWLND=""
				QSWCPPFLAGS=""


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c



fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	fi
else
	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
	QSWLND=""
	QSWCPPFLAGS=""
fi





{ $as_echo "$as_me:$LINENO: checking whether to enable OpenIB gen2 support" >&5
$as_echo_n "checking whether to enable OpenIB gen2 support... " >&6; }
# set default

# Check whether --with-o2ib was given.
if test "${with_o2ib+set}" = set; then
  withval=$with_o2ib;
		case $with_o2ib in
		yes)    O2IBPATHS="$LINUX $LINUX/drivers/infiniband"
			ENABLEO2IB=2
			;;
		no)     ENABLEO2IB=0
			;;
		*)      O2IBPATHS=$with_o2ib
			ENABLEO2IB=3
			;;
		esac

else

		O2IBPATHS="$LINUX $LINUX/drivers/infiniband"
		ENABLEO2IB=1

fi

if test $ENABLEO2IB -eq 0; then
	{ $as_echo "$as_me:$LINENO: result: disabled" >&5
$as_echo "disabled" >&6; }
else
	o2ib_found=false
	for O2IBPATH in $O2IBPATHS; do
		if test \( -f ${O2IBPATH}/include/rdma/rdma_cm.h -a \
			   -f ${O2IBPATH}/include/rdma/ib_cm.h -a \
			   -f ${O2IBPATH}/include/rdma/ib_verbs.h -a \
			   -f ${O2IBPATH}/include/rdma/ib_fmr_pool.h \); then
			if test \( -d ${O2IBPATH}/kernel_patches -a \
				   -f ${O2IBPATH}/Makefile \); then
				{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
				{ { $as_echo "$as_me:$LINENO: error: you appear to be trying to use the OFED distribution's source directory (${O2IBPATH}) rather than the \"development/headers\" directory which is likely in ${O2IBPATH%-*}" >&5
$as_echo "$as_me: error: you appear to be trying to use the OFED distribution's source directory (${O2IBPATH}) rather than the \"development/headers\" directory which is likely in ${O2IBPATH%-*}" >&2;}
   { (exit 1); exit 1; }; }
			fi
			o2ib_found=true
			break
 		fi
	done
	if ! $o2ib_found; then
		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		case $ENABLEO2IB in
			1) ;;
			2) { { $as_echo "$as_me:$LINENO: error: kernel OpenIB gen2 headers not present" >&5
$as_echo "$as_me: error: kernel OpenIB gen2 headers not present" >&2;}
   { (exit 1); exit 1; }; };;
			3) { { $as_echo "$as_me:$LINENO: error: bad --with-o2ib path" >&5
$as_echo "$as_me: error: bad --with-o2ib path" >&2;}
   { (exit 1); exit 1; }; };;
			*) { { $as_echo "$as_me:$LINENO: error: internal error" >&5
$as_echo "$as_me: error: internal error" >&2;}
   { (exit 1); exit 1; }; };;
		esac
	else
		O2IBPATH=$(readlink --canonicalize $O2IBPATH)
		O2IBCPPFLAGS="-I$O2IBPATH/include"
		EXTRA_KCFLAGS_save="$EXTRA_KCFLAGS"
		EXTRA_KCFLAGS="$EXTRA_KCFLAGS $O2IBCPPFLAGS"
		EXTRA_LNET_INCLUDE="$EXTRA_LNET_INCLUDE $O2IBCPPFLAGS"

		cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		        #include <linux/version.h>
		        #include <linux/pci.h>
			#include <linux/gfp.h>
			#ifdef HAVE_COMPAT_RDMA
			#include <linux/compat-2.6.h>
			#endif
		        #include <rdma/rdma_cm.h>
		        #include <rdma/ib_cm.h>
		        #include <rdma/ib_verbs.h>
		        #include <rdma/ib_fmr_pool.h>

int
main (void)
{

		        struct rdma_cm_id      *cm_idi __attribute__ ((unused));
		        struct rdma_conn_param  conn_param __attribute__ ((unused));
		        struct ib_device_attr   device_attr __attribute__ ((unused));
		        struct ib_qp_attr       qp_attr __attribute__ ((unused));
		        struct ib_pool_fmr      pool_fmr __attribute__ ((unused));
		        enum   ib_cm_rej_reason rej_reason __attribute__ ((unused));

			rdma_destroy_id(NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
		        O2IBLND="o2iblnd"

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		        case $ENABLEO2IB in
		        1) ;;
		        2) { { $as_echo "$as_me:$LINENO: error: can't compile with kernel OpenIB gen2 headers" >&5
$as_echo "$as_me: error: can't compile with kernel OpenIB gen2 headers" >&2;}
   { (exit 1); exit 1; }; };;
		        3) { { $as_echo "$as_me:$LINENO: error: can't compile with OpenIB gen2 headers under $O2IBPATH" >&5
$as_echo "$as_me: error: can't compile with OpenIB gen2 headers under $O2IBPATH" >&2;}
   { (exit 1); exit 1; }; };;
		        *) { { $as_echo "$as_me:$LINENO: error: internal error" >&5
$as_echo "$as_me: error: internal error" >&2;}
   { (exit 1); exit 1; }; };;
		        esac
		        O2IBLND=""
		        O2IBCPPFLAGS=""

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
		# we know at this point that the found OFED source is good
		O2IB_SYMVER=""
		if test $ENABLEO2IB -eq 3 ; then
			# OFED default rpm not handle sles10 Modules.symvers name
			for name in Module.symvers Modules.symvers; do
				if test -f $O2IBPATH/$name; then
					O2IB_SYMVER=$name;
					break;
				fi
			done
			if test -n "$O2IB_SYMVER"; then
				{ $as_echo "$as_me:$LINENO: adding $O2IBPATH/$O2IB_SYMVER to $PWD/$SYMVERFILE" >&5
$as_echo "$as_me: adding $O2IBPATH/$O2IB_SYMVER to $PWD/$SYMVERFILE" >&6;}
				# strip out the existing symbols versions first
				if test -f $PWD/$SYMVERFILE; then
				egrep -v $(echo $(awk '{ print  }' $O2IBPATH/$O2IB_SYMVER) | tr ' ' '|') $PWD/$SYMVERFILE > $PWD/$SYMVERFILE.old
				else
				    touch $PWD/$SYMVERFILE.old
				fi
				cat $PWD/$SYMVERFILE.old $O2IBPATH/$O2IB_SYMVER > $PWD/$SYMVERFILE
				rm $PWD/$SYMVERFILE.old
			else
				{ { $as_echo "$as_me:$LINENO: error: an external source tree was specified for o2iblnd however I could not find a $O2IBPATH/Module.symvers there" >&5
$as_echo "$as_me: error: an external source tree was specified for o2iblnd however I could not find a $O2IBPATH/Module.symvers there" >&2;}
   { (exit 1); exit 1; }; }
			fi
		fi


	{ $as_echo "$as_me:$LINENO: checking if OFED has ib_dma_map_single" >&5
$as_echo_n "checking if OFED has ib_dma_map_single... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/version.h>
		#include <linux/pci.h>
		#include <linux/gfp.h>
		#include <rdma/ib_verbs.h>

int
main (void)
{

		ib_dma_map_single(NULL, NULL, 0, 0);
		return 0;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_OFED_IB_DMA_MAP 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	{ $as_echo "$as_me:$LINENO: checking if ib_create_cq wants comp_vector" >&5
$as_echo_n "checking if ib_create_cq wants comp_vector... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/version.h>
		#include <linux/pci.h>
		#include <linux/gfp.h>
		#include <rdma/ib_verbs.h>

int
main (void)
{

		ib_create_cq(NULL, NULL, NULL, NULL, 0, 0);
		return 0;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_OFED_IB_COMP_VECTOR 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	{ $as_echo "$as_me:$LINENO: checking if OFED has RDMA_CM_EVENT_ADDR_CHANGE" >&5
$as_echo_n "checking if OFED has RDMA_CM_EVENT_ADDR_CHANGE... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/version.h>
		#include <linux/pci.h>
		#include <linux/gfp.h>
		#ifdef HAVE_COMPAT_RDMA
		#include <linux/compat-2.6.h>
		#endif
		#include <rdma/rdma_cm.h>

int
main (void)
{

		return (RDMA_CM_EVENT_ADDR_CHANGE == 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_OFED_RDMA_CMEV_ADDRCHANGE 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	{ $as_echo "$as_me:$LINENO: checking if OFED has RDMA_CM_EVENT_TIMEWAIT_EXIT" >&5
$as_echo_n "checking if OFED has RDMA_CM_EVENT_TIMEWAIT_EXIT... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/version.h>
		#include <linux/pci.h>
		#include <linux/gfp.h>
		#ifdef HAVE_COMPAT_RDMA
		#include <linux/compat-2.6.h>
		#endif
		#include <rdma/rdma_cm.h>

int
main (void)
{

		return (RDMA_CM_EVENT_TIMEWAIT_EXIT == 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_OFED_RDMA_CMEV_TIMEWAIT_EXIT 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	{ $as_echo "$as_me:$LINENO: checking if OFED has rdma_set_reuseaddr" >&5
$as_echo_n "checking if OFED has rdma_set_reuseaddr... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/version.h>
		#include <linux/pci.h>
		#include <linux/gfp.h>
		#ifdef HAVE_COMPAT_RDMA
		#include <linux/compat-2.6.h>
		#endif
		#include <rdma/rdma_cm.h>

int
main (void)
{

		rdma_set_reuseaddr(NULL, 1);
		return 0;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_OFED_RDMA_SET_REUSEADDR 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

		EXTRA_KCFLAGS="$EXTRA_KCFLAGS_save"
	fi
fi





# In RHEL 6.2, rdma_create_id() takes the queue-pair type as a fourth argument
if test $ENABLEO2IB -ne 0; then
	{ $as_echo "$as_me:$LINENO: checking if rdma_create_id wants four args" >&5
$as_echo_n "checking if rdma_create_id wants four args... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#ifdef HAVE_COMPAT_RDMA
		#include <linux/compat-2.6.h>
		#endif
		#include <rdma/rdma_cm.h>

int
main (void)
{

		rdma_create_id(NULL, NULL, 0, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_RDMA_CREATE_ID_4ARG 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
fi

#### Rapid Array
{ $as_echo "$as_me:$LINENO: checking if RapidArray kernel headers are present" >&5
$as_echo_n "checking if RapidArray kernel headers are present... " >&6; }
# placeholder
RACPPFLAGS="-I${LINUX}/drivers/xd1/include"
EXTRA_KCFLAGS_save="$EXTRA_KCFLAGS"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS $RACPPFLAGS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/types.h>
	#include <rapl.h>

int
main (void)
{

        RAP_RETURN          rc;
	RAP_PVOID           dev_handle;

        rc = RapkGetDeviceByIndex(0, NULL, &dev_handle);

	return rc == RAP_SUCCESS ? 0 : 1;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
	RALND="ralnd"

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
	RALND=""
	RACPPFLAGS=""

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
EXTRA_KCFLAGS="$EXTRA_KCFLAGS_save"



#### Gemini Network Interface
{ $as_echo "$as_me:$LINENO: checking whether to enable GNI lnd" >&5
$as_echo_n "checking whether to enable GNI lnd... " >&6; }
# Check whether --enable-gni was given.
if test "${enable_gni+set}" = set; then
  enableval=$enable_gni;
else
  enable_gni='no'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_gni" >&5
$as_echo "$enable_gni" >&6; }

if test x$enable_gni = xyes ; then
	{ $as_echo "$as_me:$LINENO: checking if GNI kernel headers are present" >&5
$as_echo_n "checking if GNI kernel headers are present... " >&6; }
	# placeholder
	# GNICPPFLAGS was set in spec file
	EXTRA_KCFLAGS_save="$EXTRA_KCFLAGS"
	EXTRA_KCFLAGS="$EXTRA_KCFLAGS $GNICPPFLAGS"
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/types.h>
		#include <gni_pub.h>

int
main (void)
{

		gni_cdm_handle_t	kgni_domain;
		gni_return_t		rc;
		int			rrc;

		rc = gni_cdm_create(0, 1, 1, 0, &kgni_domain);

		rrc = (rc == GNI_RC_SUCCESS) ? 0 : 1;

		return rrc;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
		GNILND="gnilnd"

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		{ { $as_echo "$as_me:$LINENO: error: can't compile gnilnd with given GNICPPFLAGS: $GNICPPFLAGS" >&5
$as_echo "$as_me: error: can't compile gnilnd with given GNICPPFLAGS: $GNICPPFLAGS" >&2;}
   { (exit 1); exit 1; }; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
	# at this point, we have gnilnd basic support, now check for extra features
	{ $as_echo "$as_me:$LINENO: checking to use RCA in gnilnd" >&5
$as_echo_n "checking to use RCA in gnilnd... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/types.h>
		#include <gni_pub.h>
		#include <krca_lib.h>

int
main (void)
{

		gni_cdm_handle_t	kgni_domain;
		gni_return_t		rc;
		krca_ticket_t		ticket = KRCA_NULL_TICKET;
		int			rrc;
		__u32			nid = 0, nic_addr;

		rc = gni_cdm_create(0, 1, 1, 0, &kgni_domain);

		rrc = (rc == GNI_RC_SUCCESS) ? 0 : 1;

		rrc += krca_nid_to_nicaddrs(nid, 1, &nic_addr);

		rrc += krca_register(&ticket, RCA_MAKE_SERVICE_INDEX(RCA_IO_CLASS, 9), 99, 0);

		return rrc;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
		GNICPPFLAGS="$GNICPPFLAGS -DGNILND_USE_RCA=1"
		GNILNDRCA="gnilndrca"

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
	EXTRA_KCFLAGS="$EXTRA_KCFLAGS_save"
fi





if test -z "$ENABLEPORTALS"; then
	{ $as_echo "$as_me:$LINENO: checking for portals" >&5
$as_echo_n "checking for portals... " >&6; }

# Check whether --with-portals was given.
if test "${with_portals+set}" = set; then
  withval=$with_portals;
		case $with_portals in
			no)     ENABLEPORTALS=0
				;;
			*)	PORTALS="${with_portals}"
				ENABLEPORTALS=1
				;;
		esac

else

		ENABLEPORTALS=0

fi

PTLLNDCPPFLAGS=""
if test $ENABLEPORTALS -eq 0; then
	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
elif test ! \( -f ${PORTALS}/include/portals/p30.h \); then
	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
	{ { $as_echo "$as_me:$LINENO: error: bad --with-portals path" >&5
$as_echo "$as_me: error: bad --with-portals path" >&2;}
   { (exit 1); exit 1; }; }
else
	PORTALS=$(readlink --canonicalize $PORTALS)
	{ $as_echo "$as_me:$LINENO: result: $PORTALS" >&5
$as_echo "$PORTALS" >&6; }
	PTLLNDCPPFLAGS="-I${PORTALS}/include"
fi


fi

{ $as_echo "$as_me:$LINENO: checking whether to build the kernel portals LND" >&5
$as_echo_n "checking whether to build the kernel portals LND... " >&6; }

PTLLND=""
if test $ENABLEPORTALS -ne 0; then
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
	PTLLND="ptllnd"
else
	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


{ $as_echo "$as_me:$LINENO: checking whether to enable Myrinet MX support" >&5
$as_echo_n "checking whether to enable Myrinet MX support... " >&6; }
# set default
MXPATH="/opt/mx"

# Check whether --with-mx was given.
if test "${with_mx+set}" = set; then
  withval=$with_mx;
               case $with_mx in
               yes)    ENABLEMX=2
                       ;;
               no)     ENABLEMX=0
                       ;;
               *)      MXPATH=$with_mx
                       ENABLEMX=3
                       ;;
               esac

else

               ENABLEMX=1

fi

if test $ENABLEMX -eq 0; then
       { $as_echo "$as_me:$LINENO: result: disabled" >&5
$as_echo "disabled" >&6; }
elif test ! \( -f ${MXPATH}/include/myriexpress.h -a \
              -f ${MXPATH}/include/mx_kernel_api.h -a \
              -f ${MXPATH}/include/mx_pin.h \); then
       { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
       case $ENABLEMX in
       1) ;;
       2) { { $as_echo "$as_me:$LINENO: error: Myrinet MX kernel headers not present" >&5
$as_echo "$as_me: error: Myrinet MX kernel headers not present" >&2;}
   { (exit 1); exit 1; }; };;
       3) { { $as_echo "$as_me:$LINENO: error: bad --with-mx path" >&5
$as_echo "$as_me: error: bad --with-mx path" >&2;}
   { (exit 1); exit 1; }; };;
       *) { { $as_echo "$as_me:$LINENO: error: internal error" >&5
$as_echo "$as_me: error: internal error" >&2;}
   { (exit 1); exit 1; }; };;
       esac
else
       MXPATH=$(readlink --canonicalize $MXPATH)
       MXCPPFLAGS="-I$MXPATH/include"
       EXTRA_KCFLAGS_save="$EXTRA_KCFLAGS"
       EXTRA_KCFLAGS="$EXTRA_KCFLAGS $MXCPPFLAGS"
       MXLIBS="-L$MXPATH/lib"
       cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

               #define MX_KERNEL 1
               #include <mx_extensions.h>
               #include <myriexpress.h>

int
main (void)
{

               mx_endpoint_t   end;
               mx_status_t     status;
               mx_request_t    request;
               int             result;

               mx_init();
               mx_open_endpoint(MX_ANY_NIC, MX_ANY_ENDPOINT, 0, NULL, 0, &end);
	       mx_register_unexp_handler(end, (mx_unexp_handler_t) NULL, NULL);
               mx_wait_any(end, MX_INFINITE, 0LL, 0LL, &status, &result);
               mx_iconnect(end, 0LL, 0, 0, 0, NULL, &request);
               return 0;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

               { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
               MXLND="mxlnd"

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


               { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
               case $ENABLEMX in
               1) ;;
               2) { { $as_echo "$as_me:$LINENO: error: can't compile with Myrinet MX kernel headers" >&5
$as_echo "$as_me: error: can't compile with Myrinet MX kernel headers" >&2;}
   { (exit 1); exit 1; }; };;
               3) { { $as_echo "$as_me:$LINENO: error: can't compile with Myrinet MX headers under $MXPATH" >&5
$as_echo "$as_me: error: can't compile with Myrinet MX headers under $MXPATH" >&2;}
   { (exit 1); exit 1; }; };;
               *) { { $as_echo "$as_me:$LINENO: error: internal error" >&5
$as_echo "$as_me: error: internal error" >&2;}
   { (exit 1); exit 1; }; };;
               esac
               MXLND=""
               MXCPPFLAGS=""

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
       EXTRA_KCFLAGS="$EXTRA_KCFLAGS_save"
fi




# 2.6.32
{ $as_echo "$as_me:$LINENO: checking if sysctl proc_handler wants 5 args" >&5
$as_echo_n "checking if sysctl proc_handler wants 5 args... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/sysctl.h>

int
main (void)
{

        struct ctl_table *table = NULL;
        int write = 1;
        void __user *buffer = NULL;
        size_t *lenp = NULL;
        loff_t *ppos = NULL;

        proc_handler *proc_handler = NULL;
        proc_handler(table, write, buffer, lenp, ppos);


  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_5ARGS_SYSCTL_PROC_HANDLER 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

# 2.6.36
{ $as_echo "$as_me:$LINENO: checking if tcp_sendpage first parameter is socket" >&5
$as_echo_n "checking if tcp_sendpage first parameter is socket... " >&6; }
tmp_flags="$EXTRA_KCFLAGS"
EXTRA_KCFLAGS="-Werror"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/net.h>
        #include <net/tcp.h>

int
main (void)
{

        tcp_sendpage((struct socket*)0, NULL, 0, 0, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_TCP_SENDPAGE_USE_SOCKET 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
EXTRA_KCFLAGS="$tmp_flags"



# Kernel ext source located with devel headers
linux_src=$LINUX
if test -e "$linux_src/fs/ext4/super.c"; then
	EXT4_SRC_DIR=$linux_src/fs/ext4
else
	# Kernel ext source provided by kernel-debuginfo-common package
	linux_src=$(ls -1d /usr/src/debug/*/linux-$LINUXRELEASE \
		2>/dev/null | tail -1)
	if test -e "$linux_src/fs/ext4/super.c"; then
		EXT4_SRC_DIR=$linux_src/fs/ext4
	else
		EXT4_SRC_DIR=
	fi
fi

{ $as_echo "$as_me:$LINENO: checking ext4 source directory" >&5
$as_echo_n "checking ext4 source directory... " >&6; }
{ $as_echo "$as_me:$LINENO: result: $EXT4_SRC_DIR" >&5
$as_echo "$EXT4_SRC_DIR" >&6; }



if test x$EXT4_SRC_DIR = x; then
	enable_ldiskfs_build='no'
else
	as_lb_File=`$as_echo "lb_cv_file_$EXT4_SRC_DIR/dir.c" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $EXT4_SRC_DIR/dir.c" >&5
$as_echo_n "checking for $EXT4_SRC_DIR/dir.c... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$EXT4_SRC_DIR/dir.c"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  :
else

		enable_ldiskfs_build='no'
		{ $as_echo "$as_me:$LINENO: WARNING: ext4 must exist for ldiskfs build" >&5
$as_echo "$as_me: WARNING: ext4 must exist for ldiskfs build" >&2;}
fi

	as_lb_File=`$as_echo "lb_cv_file_$EXT4_SRC_DIR/file.c" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $EXT4_SRC_DIR/file.c" >&5
$as_echo_n "checking for $EXT4_SRC_DIR/file.c... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$EXT4_SRC_DIR/file.c"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  :
else

		enable_ldiskfs_build='no'
		{ $as_echo "$as_me:$LINENO: WARNING: ext4 must exist for ldiskfs build" >&5
$as_echo "$as_me: WARNING: ext4 must exist for ldiskfs build" >&2;}
fi

	as_lb_File=`$as_echo "lb_cv_file_$EXT4_SRC_DIR/inode.c" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $EXT4_SRC_DIR/inode.c" >&5
$as_echo_n "checking for $EXT4_SRC_DIR/inode.c... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$EXT4_SRC_DIR/inode.c"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  :
else

		enable_ldiskfs_build='no'
		{ $as_echo "$as_me:$LINENO: WARNING: ext4 must exist for ldiskfs build" >&5
$as_echo "$as_me: WARNING: ext4 must exist for ldiskfs build" >&2;}
fi

	as_lb_File=`$as_echo "lb_cv_file_$EXT4_SRC_DIR/super.c" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $EXT4_SRC_DIR/super.c" >&5
$as_echo_n "checking for $EXT4_SRC_DIR/super.c... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$EXT4_SRC_DIR/super.c"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  :
else

		enable_ldiskfs_build='no'
		{ $as_echo "$as_me:$LINENO: WARNING: ext4 must exist for ldiskfs build" >&5
$as_echo "$as_me: WARNING: ext4 must exist for ldiskfs build" >&2;}
fi

fi

if test x$enable_ldiskfs_build = xno; then
	enable_ldiskfs='no'

	{ $as_echo "$as_me:$LINENO: WARNING:

Disabling ldiskfs support because complete ext4 source does not exist.

If you are building using kernel-devel packages and require ldiskfs
server support then ensure that the matching kernel-debuginfo-common
and kernel-debuginfo-common-<arch> packages are installed.

" >&5
$as_echo "$as_me: WARNING:

Disabling ldiskfs support because complete ext4 source does not exist.

If you are building using kernel-devel packages and require ldiskfs
server support then ensure that the matching kernel-debuginfo-common
and kernel-debuginfo-common-<arch> packages are installed.

" >&2;}

fi



         { $as_echo "$as_me:$LINENO: checking whether to enable pinger support" >&5
$as_echo_n "checking whether to enable pinger support... " >&6; }
# Check whether --enable-pinger was given.
if test "${enable_pinger+set}" = set; then
  enableval=$enable_pinger;
else
  enable_pinger='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_pinger" >&5
$as_echo "$enable_pinger" >&6; }
if test x$enable_pinger != xno ; then

cat >>confdefs.h <<\_ACEOF
#define ENABLE_PINGER 1
_ACEOF

fi

         { $as_echo "$as_me:$LINENO: checking whether to enable data checksum support" >&5
$as_echo_n "checking whether to enable data checksum support... " >&6; }
# Check whether --enable-checksum was given.
if test "${enable_checksum+set}" = set; then
  enableval=$enable_checksum;
else
  enable_checksum='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_checksum" >&5
$as_echo "$enable_checksum" >&6; }
if test x$enable_checksum != xno ; then

cat >>confdefs.h <<\_ACEOF
#define ENABLE_CHECKSUM 1
_ACEOF

fi

         { $as_echo "$as_me:$LINENO: checking whether to enable liblustre recovery support" >&5
$as_echo_n "checking whether to enable liblustre recovery support... " >&6; }
# Check whether --enable-liblustre-recovery was given.
if test "${enable_liblustre_recovery+set}" = set; then
  enableval=$enable_liblustre_recovery;
else
  enable_liblustre_recovery='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_liblustre_recovery" >&5
$as_echo "$enable_liblustre_recovery" >&6; }
if test x$enable_liblustre_recovery != xno ; then

cat >>confdefs.h <<\_ACEOF
#define ENABLE_LIBLUSTRE_RECOVERY 1
_ACEOF

fi

         { $as_echo "$as_me:$LINENO: checking whether to enable a write with the health check" >&5
$as_echo_n "checking whether to enable a write with the health check... " >&6; }
# Check whether --enable-health_write was given.
if test "${enable_health_write+set}" = set; then
  enableval=$enable_health_write;
else
  enable_health_write='no'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_health_write" >&5
$as_echo "$enable_health_write" >&6; }
if test x$enable_health_write != xno ; then

cat >>confdefs.h <<\_ACEOF
#define USE_HEALTH_CHECK_WRITE 1
_ACEOF

fi

         { $as_echo "$as_me:$LINENO: checking whether to enable lru self-adjusting" >&5
$as_echo_n "checking whether to enable lru self-adjusting... " >&6; }
# Check whether --enable-lru_resize was given.
if test "${enable_lru_resize+set}" = set; then
  enableval=$enable_lru_resize;
else
  enable_lru_resize='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_lru_resize" >&5
$as_echo "$enable_lru_resize" >&6; }
if test x$enable_lru_resize != xno; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_LRU_RESIZE_SUPPORT 1
_ACEOF

fi

         { $as_echo "$as_me:$LINENO: checking whether to enable llite_lloop module" >&5
$as_echo_n "checking whether to enable llite_lloop module... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <asm/page.h>

int
main (void)
{

        #if PAGE_SIZE >= 65536
        #error "PAGE_SIZE >= 65536"
        #endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        enable_llite_lloop_module='yes'
        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        enable_llite_lloop_module='no'
        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c



	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_CRYPTO in or as module" >&5
$as_echo_n "checking if Linux was built with CONFIG_CRYPTO in or as module... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#if !(defined(CONFIG_CRYPTO) || defined(CONFIG_CRYPTO_MODULE))
		#error CONFIG_CRYPTO and CONFIG_CRYPTO_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

	{ { $as_echo "$as_me:$LINENO: error: Lustre capability require that CONFIG_CRYPTO is enabled in your kernel." >&5
$as_echo "$as_me: error: Lustre capability require that CONFIG_CRYPTO is enabled in your kernel." >&2;}
   { (exit 1); exit 1; }; }


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_CRYPTO_HMAC in or as module" >&5
$as_echo_n "checking if Linux was built with CONFIG_CRYPTO_HMAC in or as module... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#if !(defined(CONFIG_CRYPTO_HMAC) || defined(CONFIG_CRYPTO_HMAC_MODULE))
		#error CONFIG_CRYPTO_HMAC and CONFIG_CRYPTO_HMAC_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

	{ { $as_echo "$as_me:$LINENO: error: Lustre capability require that CONFIG_CRYPTO_HMAC is enabled in your kernel." >&5
$as_echo "$as_me: error: Lustre capability require that CONFIG_CRYPTO_HMAC is enabled in your kernel." >&2;}
   { (exit 1); exit 1; }; }


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_CRYPTO_SHA1 in or as module" >&5
$as_echo_n "checking if Linux was built with CONFIG_CRYPTO_SHA1 in or as module... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#if !(defined(CONFIG_CRYPTO_SHA1) || defined(CONFIG_CRYPTO_SHA1_MODULE))
		#error CONFIG_CRYPTO_SHA1 and CONFIG_CRYPTO_SHA1_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

	{ { $as_echo "$as_me:$LINENO: error: Lustre capability require that CONFIG_CRYPTO_SHA1 is enabled in your kernel." >&5
$as_echo "$as_me: error: Lustre capability require that CONFIG_CRYPTO_SHA1 is enabled in your kernel." >&2;}
   { (exit 1); exit 1; }; }


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c



	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_CRYPTO_AES in or as module" >&5
$as_echo_n "checking if Linux was built with CONFIG_CRYPTO_AES in or as module... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#if !(defined(CONFIG_CRYPTO_AES) || defined(CONFIG_CRYPTO_AES_MODULE))
		#error CONFIG_CRYPTO_AES and CONFIG_CRYPTO_AES_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

        { $as_echo "$as_me:$LINENO: WARNING: Lustre remote client require that CONFIG_CRYPTO_AES is enabled in your kernel." >&5
$as_echo "$as_me: WARNING: Lustre remote client require that CONFIG_CRYPTO_AES is enabled in your kernel." >&2;}


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


         { $as_echo "$as_me:$LINENO: checking whether to enable gss/krb5 support" >&5
$as_echo_n "checking whether to enable gss/krb5 support... " >&6; }
 # Check whether --enable-gss was given.
if test "${enable_gss+set}" = set; then
  enableval=$enable_gss;
else
  enable_gss='auto'
fi

 { $as_echo "$as_me:$LINENO: result: $enable_gss" >&5
$as_echo "$enable_gss" >&6; }

 if test x$enable_gss != xno; then
        { $as_echo "$as_me:$LINENO: checking whether to enable gss keyring backend" >&5
$as_echo_n "checking whether to enable gss keyring backend... " >&6; }
 # Check whether --enable-gss_keyring was given.
if test "${enable_gss_keyring+set}" = set; then
  enableval=$enable_gss_keyring;
else
  enable_gss_keyring='auto'
fi

 { $as_echo "$as_me:$LINENO: result: $enable_gss_keyring" >&5
$as_echo "$enable_gss_keyring" >&6; }

 if test x$enable_gss_keyring != xno; then

	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_KEYS in or as module" >&5
$as_echo_n "checking if Linux was built with CONFIG_KEYS in or as module... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#if !(defined(CONFIG_KEYS) || defined(CONFIG_KEYS_MODULE))
		#error CONFIG_KEYS and CONFIG_KEYS_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		gss_keyring_conf_test='fail';
			    { $as_echo "$as_me:$LINENO: WARNING: GSS keyring backend require that CONFIG_KEYS be enabled in your kernel." >&5
$as_echo "$as_me: WARNING: GSS keyring backend require that CONFIG_KEYS be enabled in your kernel." >&2;}

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c



{ $as_echo "$as_me:$LINENO: checking for keyctl_search in -lkeyutils" >&5
$as_echo_n "checking for keyctl_search in -lkeyutils... " >&6; }
if test "${ac_cv_lib_keyutils_keyctl_search+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lkeyutils  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char keyctl_search ();
int
main ()
{
return keyctl_search ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  ac_cv_lib_keyutils_keyctl_search=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_lib_keyutils_keyctl_search=no
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_keyutils_keyctl_search" >&5
$as_echo "$ac_cv_lib_keyutils_keyctl_search" >&6; }
if test "x$ac_cv_lib_keyutils_keyctl_search" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define HAVE_LIBKEYUTILS 1
_ACEOF

  LIBS="-lkeyutils $LIBS"

else
  gss_keyring_conf_test='fail';
		      { $as_echo "$as_me:$LINENO: WARNING: libkeyutils is not found, which is required by gss keyring backend" >&5
$as_echo "$as_me: WARNING: libkeyutils is not found, which is required by gss keyring backend" >&2;}
fi


	if test x$gss_keyring_conf_test != xfail; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_GSS_KEYRING 1
_ACEOF

		enable_gss_keyring='yes'
	else
		if test x$enable_gss_keyring == xyes; then
			{ { $as_echo "$as_me:$LINENO: error: Cannot enable gss_keyring. See above for details." >&5
$as_echo "$as_me: error: Cannot enable gss_keyring. See above for details." >&2;}
   { (exit 1); exit 1; }; }
		else
			{ $as_echo "$as_me:$LINENO: WARNING: Cannot enable gss keyring.  See above for details." >&5
$as_echo "$as_me: WARNING: Cannot enable gss keyring.  See above for details." >&2;}
		fi
	fi
 fi

	sunrpc_required=$enable_gss

	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_SUNRPC in or as module" >&5
$as_echo_n "checking if Linux was built with CONFIG_SUNRPC in or as module... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#if !(defined(CONFIG_SUNRPC) || defined(CONFIG_SUNRPC_MODULE))
		#error CONFIG_SUNRPC and CONFIG_SUNRPC_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		if test x$sunrpc_required == xyes; then
                         { { $as_echo "$as_me:$LINENO: error: kernel SUNRPC support is required by using GSS." >&5
$as_echo "$as_me: error: kernel SUNRPC support is required by using GSS." >&2;}
   { (exit 1); exit 1; }; }
                     fi

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


        sunrpc_required=no


	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_CRYPTO_MD5 in or as module" >&5
$as_echo_n "checking if Linux was built with CONFIG_CRYPTO_MD5 in or as module... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#if !(defined(CONFIG_CRYPTO_MD5) || defined(CONFIG_CRYPTO_MD5_MODULE))
		#error CONFIG_CRYPTO_MD5 and CONFIG_CRYPTO_MD5_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		{ $as_echo "$as_me:$LINENO: WARNING: kernel MD5 support is recommended by using GSS." >&5
$as_echo "$as_me: WARNING: kernel MD5 support is recommended by using GSS." >&2;}

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_CRYPTO_SHA1 in or as module" >&5
$as_echo_n "checking if Linux was built with CONFIG_CRYPTO_SHA1 in or as module... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#if !(defined(CONFIG_CRYPTO_SHA1) || defined(CONFIG_CRYPTO_SHA1_MODULE))
		#error CONFIG_CRYPTO_SHA1 and CONFIG_CRYPTO_SHA1_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		{ $as_echo "$as_me:$LINENO: WARNING: kernel SHA1 support is recommended by using GSS." >&5
$as_echo "$as_me: WARNING: kernel SHA1 support is recommended by using GSS." >&2;}

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_CRYPTO_SHA256 in or as module" >&5
$as_echo_n "checking if Linux was built with CONFIG_CRYPTO_SHA256 in or as module... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#if !(defined(CONFIG_CRYPTO_SHA256) || defined(CONFIG_CRYPTO_SHA256_MODULE))
		#error CONFIG_CRYPTO_SHA256 and CONFIG_CRYPTO_SHA256_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		{ $as_echo "$as_me:$LINENO: WARNING: kernel SHA256 support is recommended by using GSS." >&5
$as_echo "$as_me: WARNING: kernel SHA256 support is recommended by using GSS." >&2;}

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_CRYPTO_SHA512 in or as module" >&5
$as_echo_n "checking if Linux was built with CONFIG_CRYPTO_SHA512 in or as module... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#if !(defined(CONFIG_CRYPTO_SHA512) || defined(CONFIG_CRYPTO_SHA512_MODULE))
		#error CONFIG_CRYPTO_SHA512 and CONFIG_CRYPTO_SHA512_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		{ $as_echo "$as_me:$LINENO: WARNING: kernel SHA512 support is recommended by using GSS." >&5
$as_echo "$as_me: WARNING: kernel SHA512 support is recommended by using GSS." >&2;}

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	require_krb5=$enable_gss

  { $as_echo "$as_me:$LINENO: checking for Kerberos v5" >&5
$as_echo_n "checking for Kerberos v5... " >&6; }

# Check whether --with-krb5 was given.
if test "${with_krb5+set}" = set; then
  withval=$with_krb5;  case "$withval" in
    yes|no)
       krb5_with=""
       ;;
    *)
       krb5_with="$withval"
       ;;
    esac

fi


  for dir in $krb5_with /usr /usr/kerberos /usr/local /usr/local/krb5 \
  	     /usr/krb5 /usr/heimdal /usr/local/heimdal /usr/athena ; do
            K5CONFIG=""
    if test -f $dir/bin/krb5-config; then
      K5CONFIG=$dir/bin/krb5-config
    elif test -f "/usr/kerberos/bin/krb5-config"; then
      K5CONFIG="/usr/kerberos/bin/krb5-config"
    elif test -f "/usr/lib/mit/bin/krb5-config"; then
      K5CONFIG="/usr/lib/mit/bin/krb5-config"
    fi
    if test "$K5CONFIG" != ""; then
      KRBCFLAGS=`$K5CONFIG --cflags`
      KRBLIBS=`$K5CONFIG --libs gssapi`
      K5VERS=`$K5CONFIG --version | head -n 1 | awk '{split($(4),v,"."); if (v["3"] == "") v["3"] = "0"; print v["1"]v["2"]v["3"] }'`

cat >>confdefs.h <<_ACEOF
#define KRB5_VERSION $K5VERS
_ACEOF

      if test -f $dir/include/gssapi/gssapi_krb5.h -a \
                \( -f $dir/lib/libgssapi_krb5.a -o \
                   -f $dir/lib64/libgssapi_krb5.a -o \
                   -f $dir/lib64/libgssapi_krb5.so -o \
                   -f $dir/lib/x86_64-linux-gnu/libgssapi_krb5.so -o \
                   -f $dir/lib/libgssapi_krb5.so \) ; then
         KRBDIR="$dir"
                     if test $K5VERS -le 131; then

cat >>confdefs.h <<\_ACEOF
#define USE_GSS_KRB5_CCACHE_NAME 1
_ACEOF

         fi
         gssapi_lib=gssapi_krb5
         break
                  elif test \( -f $dir/include/heim_err.h -o\
      		 -f $dir/include/heimdal/heim_err.h \) -a \
                -f $dir/lib/libroken.a; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_HEIMDAL 1
_ACEOF

         KRBDIR="$dir"
         gssapi_lib=gssapi
        break
      fi
    fi
  done
    if test "x$require_krb5" = "xyes" && "x$KRBDIR" = "x"; then
    if test "x$krb5_with" = "x"; then
      { { $as_echo "$as_me:$LINENO: error: Kerberos v5 with GSS support not found: consider --disable-gss or --with-krb5=" >&5
$as_echo "$as_me: error: Kerberos v5 with GSS support not found: consider --disable-gss or --with-krb5=" >&2;}
   { (exit 1); exit 1; }; }
    else
      { { $as_echo "$as_me:$LINENO: error: Kerberos v5 with GSS support not found at $krb5_with" >&5
$as_echo "$as_me: error: Kerberos v5 with GSS support not found at $krb5_with" >&2;}
   { (exit 1); exit 1; }; }
    fi
  fi
  { $as_echo "$as_me:$LINENO: result: $KRBDIR" >&5
$as_echo "$KRBDIR" >&6; }

    echo "The current KRBDIR is $KRBDIR"
  if test "$KRBDIR/lib" = "/lib" -o "$KRBDIR/lib" = "/usr/lib" \
       -o "$KRBDIR/lib" = "//lib" -o "$KRBDIR/lib" = "/usr//lib" ; then
    KRBLDFLAGS="";
  elif /sbin/ldconfig -p | grep > /dev/null "=> $KRBDIR/lib/"; then
    KRBLDFLAGS="";
  else
    KRBLDFLAGS="-Wl,-rpath=$KRBDIR/lib"
  fi

    as_ac_Lib=`$as_echo "ac_cv_lib_$gssapi_lib''_gss_krb5_export_lucid_sec_context" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for gss_krb5_export_lucid_sec_context in -l$gssapi_lib" >&5
$as_echo_n "checking for gss_krb5_export_lucid_sec_context in -l$gssapi_lib... " >&6; }
if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-l$gssapi_lib $KRBLIBS $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char gss_krb5_export_lucid_sec_context ();
int
main ()
{
return gss_krb5_export_lucid_sec_context ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_Lib=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_Lib=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
ac_res=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_LUCID_CONTEXT_SUPPORT 1
_ACEOF

fi

  as_ac_Lib=`$as_echo "ac_cv_lib_$gssapi_lib''_gss_krb5_set_allowable_enctypes" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for gss_krb5_set_allowable_enctypes in -l$gssapi_lib" >&5
$as_echo_n "checking for gss_krb5_set_allowable_enctypes in -l$gssapi_lib... " >&6; }
if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-l$gssapi_lib $KRBLIBS $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char gss_krb5_set_allowable_enctypes ();
int
main ()
{
return gss_krb5_set_allowable_enctypes ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_Lib=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_Lib=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
ac_res=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_SET_ALLOWABLE_ENCTYPES 1
_ACEOF

fi

  as_ac_Lib=`$as_echo "ac_cv_lib_$gssapi_lib''_gss_krb5_ccache_name" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for gss_krb5_ccache_name in -l$gssapi_lib" >&5
$as_echo_n "checking for gss_krb5_ccache_name in -l$gssapi_lib... " >&6; }
if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-l$gssapi_lib $KRBLIBS $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char gss_krb5_ccache_name ();
int
main ()
{
return gss_krb5_ccache_name ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_Lib=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_Lib=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
ac_res=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_GSS_KRB5_CCACHE_NAME 1
_ACEOF

fi


    as_ac_Lib=`$as_echo "ac_cv_lib_$gssapi_lib''_krb5_get_error_message" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for krb5_get_error_message in -l$gssapi_lib" >&5
$as_echo_n "checking for krb5_get_error_message in -l$gssapi_lib... " >&6; }
if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-l$gssapi_lib $KRBLIBS $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char krb5_get_error_message ();
int
main ()
{
return krb5_get_error_message ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_Lib=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_Lib=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
ac_res=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_KRB5_GET_ERROR_MESSAGE 1
_ACEOF

fi


    as_ac_Lib=`$as_echo "ac_cv_lib_$gssapi_lib''_krb5_get_init_creds_opt_set_addressless" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for krb5_get_init_creds_opt_set_addressless in -l$gssapi_lib" >&5
$as_echo_n "checking for krb5_get_init_creds_opt_set_addressless in -l$gssapi_lib... " >&6; }
if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-l$gssapi_lib $KRBLIBS $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char krb5_get_init_creds_opt_set_addressless ();
int
main ()
{
return krb5_get_init_creds_opt_set_addressless ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_Lib=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_Lib=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
ac_res=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_KRB5_GET_INIT_CREDS_OPT_SET_ADDRESSLESS 1
_ACEOF

fi


    as_ac_Lib=`$as_echo "ac_cv_lib_$gssapi_lib''_krb5int_derive_key" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for krb5int_derive_key in -l$gssapi_lib" >&5
$as_echo_n "checking for krb5int_derive_key in -l$gssapi_lib... " >&6; }
if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-l$gssapi_lib $KRBLIBS $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char krb5int_derive_key ();
int
main ()
{
return krb5int_derive_key ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_Lib=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_Lib=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
ac_res=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_KRB5INT_DERIVE_KEY 1
_ACEOF

fi


    as_ac_Lib=`$as_echo "ac_cv_lib_$gssapi_lib''_krb5_derive_key" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for krb5_derive_key in -l$gssapi_lib" >&5
$as_echo_n "checking for krb5_derive_key in -l$gssapi_lib... " >&6; }
if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-l$gssapi_lib $KRBLIBS $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char krb5_derive_key ();
int
main ()
{
return krb5_derive_key ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_Lib=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_Lib=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
ac_res=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_Lib'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_KRB5_DERIVE_KEY 1
_ACEOF

fi


  if test "x$HAVE_KRB5INT_DERIVE_KEY" = "x1" -o "x$HAVE_KRB5_DERIVE_KEY" = "x1"; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_KRB5 1
_ACEOF

else
  KRBDIR=""; { $as_echo "$as_me:$LINENO: WARNING: Disable gss/krb5 due to missing both krb5int_derive_key and krb5_derive_key functions!" >&5
$as_echo "$as_me: WARNING: Disable gss/krb5 due to missing both krb5int_derive_key and krb5_derive_key functions!" >&2;}
fi


    if test "x$krb5_with" != "x" -a "$krb5_with" != "$KRBDIR"; then
    { $as_echo "$as_me:$LINENO: WARNING: Using $KRBDIR instead of requested value of $krb5_with for Kerberos!" >&5
$as_echo "$as_me: WARNING: Using $KRBDIR instead of requested value of $krb5_with for Kerberos!" >&2;}
  fi








	require_krb5=no

	if test x$KRBDIR != x; then
		{ $as_echo "$as_me:$LINENO: checking for gss_export_lucid_sec_context in -lgssapi" >&5
$as_echo_n "checking for gss_export_lucid_sec_context in -lgssapi... " >&6; }
if test "${ac_cv_lib_gssapi_gss_export_lucid_sec_context+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lgssapi  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char gss_export_lucid_sec_context ();
int
main ()
{
return gss_export_lucid_sec_context ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  ac_cv_lib_gssapi_gss_export_lucid_sec_context=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_lib_gssapi_gss_export_lucid_sec_context=no
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_gssapi_gss_export_lucid_sec_context" >&5
$as_echo "$ac_cv_lib_gssapi_gss_export_lucid_sec_context" >&6; }
if test "x$ac_cv_lib_gssapi_gss_export_lucid_sec_context" = x""yes; then
  GSSAPI_LIBS="$GSSAPI_LDFLAGS -lgssapi";
			      gss_conf_test='success'
else
  { $as_echo "$as_me:$LINENO: checking for gss_export_lucid_sec_context in -lgssglue" >&5
$as_echo_n "checking for gss_export_lucid_sec_context in -lgssglue... " >&6; }
if test "${ac_cv_lib_gssglue_gss_export_lucid_sec_context+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lgssglue  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char gss_export_lucid_sec_context ();
int
main ()
{
return gss_export_lucid_sec_context ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  ac_cv_lib_gssglue_gss_export_lucid_sec_context=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_lib_gssglue_gss_export_lucid_sec_context=no
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_gssglue_gss_export_lucid_sec_context" >&5
$as_echo "$ac_cv_lib_gssglue_gss_export_lucid_sec_context" >&6; }
if test "x$ac_cv_lib_gssglue_gss_export_lucid_sec_context" = x""yes; then
  GSSAPI_LIBS="$GSSAPI_LDFLAGS -lgssglue";
					    gss_conf_test='success'
else
  if test x$enable_gss == xyes; then
						{ { $as_echo "$as_me:$LINENO: error: libgssapi or libgssglue is not found, which is required by GSS." >&5
$as_echo "$as_me: error: libgssapi or libgssglue is not found, which is required by GSS." >&2;}
   { (exit 1); exit 1; }; }
					    else
						{ $as_echo "$as_me:$LINENO: WARNING: libgssapi or libgssglue is not found, which is required by GSS." >&5
$as_echo "$as_me: WARNING: libgssapi or libgssglue is not found, which is required by GSS." >&2;}
					    fi
fi

fi


	fi

	if test x$gss_conf_test == xsuccess; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_GSS 1
_ACEOF

		enable_gss='yes'
	fi

 fi


         # 2.6.24
         { $as_echo "$as_me:$LINENO: checking if kernel has bio_endio with 2 args" >&5
$as_echo_n "checking if kernel has bio_endio with 2 args... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/bio.h>

int
main (void)
{

        bio_endio(NULL, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_BIO_ENDIO_2ARG 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

         { $as_echo "$as_me:$LINENO: checking if kernel has deleted member in procfs entry struct" >&5
$as_echo_n "checking if kernel has deleted member in procfs entry struct... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/proc_fs.h>

int
main (void)
{

        struct proc_dir_entry pde;

        pde.deleted = sizeof(pde);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_PROCFS_DELETED 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


         # 2.6.27.15-2 sles11
         as_lb_File=`$as_echo "lb_cv_file_$LINUX/include/linux/quotaio_v2.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX/include/linux/quotaio_v2.h" >&5
$as_echo_n "checking for $LINUX/include/linux/quotaio_v2.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX/include/linux/quotaio_v2.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_QUOTAIO_H 1
_ACEOF


else
  as_lb_File=`$as_echo "lb_cv_file_$LINUX/fs/quotaio_v2.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX/fs/quotaio_v2.h" >&5
$as_echo_n "checking for $LINUX/fs/quotaio_v2.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX/fs/quotaio_v2.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_FS_QUOTAIO_H 1
_ACEOF


else
  as_lb_File=`$as_echo "lb_cv_file_$LINUX/fs/quota/quotaio_v2.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX/fs/quota/quotaio_v2.h" >&5
$as_echo_n "checking for $LINUX/fs/quota/quotaio_v2.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX/fs/quota/quotaio_v2.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_FS_QUOTA_QUOTAIO_H 1
_ACEOF


else

        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi


fi


fi



         # 2.6.32
         { $as_echo "$as_me:$LINENO: checking if blk_queue_max_segments is defined" >&5
$as_echo_n "checking if blk_queue_max_segments is defined... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/blkdev.h>

int
main (void)
{

        blk_queue_max_segments(NULL, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_BLK_QUEUE_MAX_SEGMENTS 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 # 2.6.34
	 tmp_flags="$EXTRA_KCFLAGS"
EXTRA_KCFLAGS="-Werror"
{ $as_echo "$as_me:$LINENO: checking if quotactl_ops.set_dqblk takes struct fs_disk_quota" >&5
$as_echo_n "checking if quotactl_ops.set_dqblk takes struct fs_disk_quota... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>
	#include <linux/quota.h>

int
main (void)
{

	((struct quotactl_ops *)0)->set_dqblk(NULL, 0, 0, (struct fs_disk_quota*)0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_DQUOT_FS_DISK_QUOTA 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
	{ $as_echo "$as_me:$LINENO: checking if quotactl_ops.set_dqblk takes struct kqid & fs_disk_quota" >&5
$as_echo_n "checking if quotactl_ops.set_dqblk takes struct kqid & fs_disk_quota... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/fs.h>
		#include <linux/quota.h>

int
main (void)
{

		((struct quotactl_ops *)0)->set_dqblk((struct super_block*)0, *((struct kqid*)0), (struct fs_disk_quota*)0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_DQUOT_FS_DISK_QUOTA 1
_ACEOF


cat >>confdefs.h <<\_ACEOF
#define HAVE_DQUOT_KQID 1
_ACEOF

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		{ $as_echo "$as_me:$LINENO: checking if quotactl_ops.set_dqblk takes struct kqid&fs_disk_quota" >&5
$as_echo_n "checking if quotactl_ops.set_dqblk takes struct kqid&fs_disk_quota... " >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
EXTRA_KCFLAGS="$tmp_flags"

	 { $as_echo "$as_me:$LINENO: checking if dquot_suspend is defined" >&5
$as_echo_n "checking if dquot_suspend is defined... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/quotaops.h>

int
main (void)
{

	dquot_suspend(NULL, -1);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_DQUOT_SUSPEND 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


         # 2.6.35, 3.0.0
         { $as_echo "$as_me:$LINENO: checking if file_operations.fsync takes 4 or 2 arguments" >&5
$as_echo_n "checking if file_operations.fsync takes 4 or 2 arguments... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/fs.h>

int
main (void)
{

        ((struct file_operations *)0)->fsync(NULL, 0, 0, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_FILE_FSYNC_4ARGS 1
_ACEOF

        { $as_echo "$as_me:$LINENO: result: yes, 4 args" >&5
$as_echo "yes, 4 args" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

                #include <linux/fs.h>

int
main (void)
{

           ((struct file_operations *)0)->fsync(NULL, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_FILE_FSYNC_2ARGS 1
_ACEOF

                { $as_echo "$as_me:$LINENO: result: yes, 2 args" >&5
$as_echo "yes, 2 args" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


                { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

         { $as_echo "$as_me:$LINENO: checking if Linux was built with symbol simple_setattr exported" >&5
$as_echo_n "checking if Linux was built with symbol simple_setattr exported... " >&6; }
grep -q -E '[[:space:]]simple_setattr[[:space:]]' $LINUX_OBJ/$SYMVERFILE 2>/dev/null
rc=$?
if test $rc -ne 0; then
	export=0
	for file in fs/libfs.c; do
		grep -q -E "EXPORT_SYMBOL.*\(simple_setattr\)" "$LINUX/$file" 2>/dev/null
		rc=$?
		if test $rc -eq 0; then
			export=1
			break;
		fi
	done
	if test $export -eq 0; then
		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }


	else
		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


cat >>confdefs.h <<\_ACEOF
#define HAVE_SIMPLE_SETATTR 1
_ACEOF


	fi
else
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


cat >>confdefs.h <<\_ACEOF
#define HAVE_SIMPLE_SETATTR 1
_ACEOF


fi


	 { $as_echo "$as_me:$LINENO: checking if Linux was built with symbol truncate_complete_page exported" >&5
$as_echo_n "checking if Linux was built with symbol truncate_complete_page exported... " >&6; }
grep -q -E '[[:space:]]truncate_complete_page[[:space:]]' $LINUX_OBJ/$SYMVERFILE 2>/dev/null
rc=$?
if test $rc -ne 0; then
	export=0
	for file in mm/truncate.c; do
		grep -q -E "EXPORT_SYMBOL.*\(truncate_complete_page\)" "$LINUX/$file" 2>/dev/null
		rc=$?
		if test $rc -eq 0; then
			export=1
			break;
		fi
	done
	if test $export -eq 0; then
		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

	else
		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_TRUNCATE_COMPLETE_PAGE 1
_ACEOF

	fi
else
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_TRUNCATE_COMPLETE_PAGE 1
_ACEOF

fi

          { $as_echo "$as_me:$LINENO: checking if Linux was built with symbol remove_from_page_cache exported" >&5
$as_echo_n "checking if Linux was built with symbol remove_from_page_cache exported... " >&6; }
grep -q -E '[[:space:]]remove_from_page_cache[[:space:]]' $LINUX_OBJ/$SYMVERFILE 2>/dev/null
rc=$?
if test $rc -ne 0; then
	export=0
	for file in mm/filemap.c; do
		grep -q -E "EXPORT_SYMBOL.*\(remove_from_page_cache\)" "$LINUX/$file" 2>/dev/null
		rc=$?
		if test $rc -eq 0; then
			export=1
			break;
		fi
	done
	if test $export -eq 0; then
		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

	else
		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_REMOVE_FROM_PAGE_CACHE 1
_ACEOF

	fi
else
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_REMOVE_FROM_PAGE_CACHE 1
_ACEOF

fi

          { $as_echo "$as_me:$LINENO: checking if Linux was built with symbol delete_from_page_cache exported" >&5
$as_echo_n "checking if Linux was built with symbol delete_from_page_cache exported... " >&6; }
grep -q -E '[[:space:]]delete_from_page_cache[[:space:]]' $LINUX_OBJ/$SYMVERFILE 2>/dev/null
rc=$?
if test $rc -ne 0; then
	export=0
	for file in mm/filemap.c; do
		grep -q -E "EXPORT_SYMBOL.*\(delete_from_page_cache\)" "$LINUX/$file" 2>/dev/null
		rc=$?
		if test $rc -eq 0; then
			export=1
			break;
		fi
	done
	if test $export -eq 0; then
		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

	else
		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_DELETE_FROM_PAGE_CACHE 1
_ACEOF

	fi
else
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_DELETE_FROM_PAGE_CACHE 1
_ACEOF

fi



         # 2.6.36
         { $as_echo "$as_me:$LINENO: checking if fs_struct.lock use rwlock" >&5
$as_echo_n "checking if fs_struct.lock use rwlock... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <asm/atomic.h>
        #include <linux/spinlock.h>
        #include <linux/fs_struct.h>

int
main (void)
{

        ((struct fs_struct *)0)->lock = (rwlock_t){ 0 };

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_FS_STRUCT_RWLOCK 1
_ACEOF

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

         { $as_echo "$as_me:$LINENO: checking if super_operations.evict_inode exist" >&5
$as_echo_n "checking if super_operations.evict_inode exist... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/fs.h>

int
main (void)
{

        ((struct super_operations *)0)->evict_inode(NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_SBOPS_EVICT_INODE 1
_ACEOF

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


         # 2.6.37
         { $as_echo "$as_me:$LINENO: checking if kernel_locked is defined" >&5
$as_echo_n "checking if kernel_locked is defined... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/smp_lock.h>

int
main (void)
{

        kernel_locked();

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_KERNEL_LOCKED 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


         # 2.6.38
         { $as_echo "$as_me:$LINENO: checking if Linux was built with symbol blkdev_get_by_dev exported" >&5
$as_echo_n "checking if Linux was built with symbol blkdev_get_by_dev exported... " >&6; }
grep -q -E '[[:space:]]blkdev_get_by_dev[[:space:]]' $LINUX_OBJ/$SYMVERFILE 2>/dev/null
rc=$?
if test $rc -ne 0; then
	export=0
	for file in fs/block_dev.c; do
		grep -q -E "EXPORT_SYMBOL.*\(blkdev_get_by_dev\)" "$LINUX/$file" 2>/dev/null
		rc=$?
		if test $rc -eq 0; then
			export=1
			break;
		fi
	done
	if test $export -eq 0; then
		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }


	else
		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


cat >>confdefs.h <<\_ACEOF
#define HAVE_BLKDEV_GET_BY_DEV 1
_ACEOF


	fi
else
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


cat >>confdefs.h <<\_ACEOF
#define HAVE_BLKDEV_GET_BY_DEV 1
_ACEOF


fi


         { $as_echo "$as_me:$LINENO: checking if generic_permission take 2 or 4 arguments" >&5
$as_echo_n "checking if generic_permission take 2 or 4 arguments... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	generic_permission(NULL, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_GENERIC_PERMISSION_2ARGS 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes, 2 args" >&5
$as_echo "yes, 2 args" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <linux/fs.h>

int
main (void)
{

		generic_permission(NULL, 0, 0, NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_GENERIC_PERMISSION_4ARGS 1
_ACEOF

		{ $as_echo "$as_me:$LINENO: result: yes, 4 args" >&5
$as_echo "yes, 4 args" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

         { $as_echo "$as_me:$LINENO: checking if dcache_lock is exist" >&5
$as_echo_n "checking if dcache_lock is exist... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/dcache.h>

int
main (void)
{

	spin_lock(&dcache_lock);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_DCACHE_LOCK 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking if inode.i_rcu exists" >&5
$as_echo_n "checking if inode.i_rcu exists... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	struct inode ino;
	struct rcu_head rcu = {};
	ino.i_rcu = rcu;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_INODE_I_RCU 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

         { $as_echo "$as_me:$LINENO: checking if d_compare taken 7 arguments" >&5
$as_echo_n "checking if d_compare taken 7 arguments... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/dcache.h>

int
main (void)
{

	((struct dentry_operations*)0)->d_compare(NULL,NULL,NULL,NULL,0,NULL,NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_D_COMPARE_7ARGS 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

         { $as_echo "$as_me:$LINENO: checking if d_delete has const declare on first parameter" >&5
$as_echo_n "checking if d_delete has const declare on first parameter... " >&6; }
tmp_flags="$EXTRA_KCFLAGS"
EXTRA_KCFLAGS="-Werror"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/dcache.h>

int
main (void)
{

	const struct dentry *d = NULL;
	((struct dentry_operations*)0)->d_delete(d);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_D_DELETE_CONST const
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	cat >>confdefs.h <<\_ACEOF
#define HAVE_D_DELETE_CONST /**/
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
EXTRA_KCFLAGS="$tmp_flags"


         # 2.6.39
         { $as_echo "$as_me:$LINENO: checking if request_queue has unplug_fn field" >&5
$as_echo_n "checking if request_queue has unplug_fn field... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/blkdev.h>

int
main (void)
{

        do{ }while(sizeof(((struct request_queue *)0)->unplug_fn));

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_REQUEST_QUEUE_UNPLUG_FN 1
_ACEOF

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking if file_system_type has mount field" >&5
$as_echo_n "checking if file_system_type has mount field... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	struct file_system_type fst;
	void *i = (void *) fst.mount;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_FSTYPE_MOUNT 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking inode_operations has .truncate member function" >&5
$as_echo_n "checking inode_operations has .truncate member function... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/fs.h>

int
main (void)
{

        ((struct inode_operations *)0)->truncate(NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_INODEOPS_TRUNCATE 1
_ACEOF

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking if inode_owner_or_capable exist" >&5
$as_echo_n "checking if inode_owner_or_capable exist... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	inode_owner_or_capable(NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_INODE_OWNER_OR_CAPABLE 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 # 3.0
	 { $as_echo "$as_me:$LINENO: checking if dirty_inode super_operation takes flag" >&5
$as_echo_n "checking if dirty_inode super_operation takes flag... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	struct inode *inode;
	inode->i_sb->s_op->dirty_inode(NULL, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_DIRTY_INODE_HAS_FLAG 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 # 3.1
	 { $as_echo "$as_me:$LINENO: checking if lock-manager ops renamed to lm_xxx" >&5
$as_echo_n "checking if lock-manager ops renamed to lm_xxx... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	struct lock_manager_operations lm_ops;
	lm_ops.lm_compare_owner = NULL;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_LM_XXX_LOCK_MANAGER_OPS 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking if inode->i_alloc_sem is killed and use inode_dio_wait/done." >&5
$as_echo_n "checking if inode->i_alloc_sem is killed and use inode_dio_wait/done.... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	inode_dio_wait((struct inode *)0);
	inode_dio_done((struct inode *)0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_INODE_DIO_WAIT 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking inode_operations has .get_acl member function" >&5
$as_echo_n "checking inode_operations has .get_acl member function... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/fs.h>

int
main (void)
{

        struct inode_operations iop;
        iop.get_acl = NULL;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_IOP_GET_ACL 1
_ACEOF

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking if Linux was built with symbol generic_file_llseek_size exported" >&5
$as_echo_n "checking if Linux was built with symbol generic_file_llseek_size exported... " >&6; }
grep -q -E '[[:space:]]generic_file_llseek_size[[:space:]]' $LINUX_OBJ/$SYMVERFILE 2>/dev/null
rc=$?
if test $rc -ne 0; then
	export=0
	for file in fs/read_write.c; do
		grep -q -E "EXPORT_SYMBOL.*\(generic_file_llseek_size\)" "$LINUX/$file" 2>/dev/null
		rc=$?
		if test $rc -eq 0; then
			export=1
			break;
		fi
	done
	if test $export -eq 0; then
		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

	else
		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_FILE_LLSEEK_SIZE 1
_ACEOF

	fi
else
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_FILE_LLSEEK_SIZE 1
_ACEOF

fi


	 { $as_echo "$as_me:$LINENO: checking inode_operations->permission has two args" >&5
$as_echo_n "checking inode_operations->permission has two args... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

        #include <linux/fs.h>

int
main (void)
{

        struct inode *inode __attribute__ ((unused));

        inode = NULL;
        inode->i_op->permission(NULL, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_INODE_PERMISION_2ARGS 1
_ACEOF

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 # 3.1.1
	 { $as_echo "$as_me:$LINENO: checking if kernel has ext4_blocks_for_truncate" >&5
$as_echo_n "checking if kernel has ext4_blocks_for_truncate... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>
	#include "$LINUX/fs/ext4/ext4_jbd2.h"
	#include "$LINUX/fs/ext4/truncate.h"

int
main (void)
{

	ext4_blocks_for_truncate(NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_BLOCKS_FOR_TRUNCATE 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 # 3.2
	 { $as_echo "$as_me:$LINENO: checking if request_queue.make_request_fn returns void but not int" >&5
$as_echo_n "checking if request_queue.make_request_fn returns void but not int... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/blkdev.h>

int
main (void)
{

	int ret;
	make_request_fn		*mrf;
	ret = mrf(NULL, NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5



cat >>confdefs.h <<\_ACEOF
#define HAVE_VOID_MAKE_REQUEST_FN 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking if inode->i_nlink is protected from direct modification" >&5
$as_echo_n "checking if inode->i_nlink is protected from direct modification... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	struct inode i;
	set_nlink(&i, 1);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_PROTECT_I_NLINK 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 # 3.3
	 as_lb_File=`$as_echo "lb_cv_file_$LINUX/include/linux/migrate.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX/include/linux/migrate.h" >&5
$as_echo_n "checking for $LINUX/include/linux/migrate.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX/include/linux/migrate.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_MIGRATE_H 1
_ACEOF


else
  as_lb_File=`$as_echo "lb_cv_file_$LINUX/include/linux/migrate_mode.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX/include/linux/migrate_mode.h" >&5
$as_echo_n "checking for $LINUX/include/linux/migrate_mode.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX/include/linux/migrate_mode.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_MIGRATE_MODE_H 1
_ACEOF


else

	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi


fi


	 { $as_echo "$as_me:$LINENO: checking if address_space_operations.migratepage has 4 args" >&5
$as_echo_n "checking if address_space_operations.migratepage has 4 args... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>
#ifdef HAVE_MIGRATE_H
	#include <linux/migrate.h>
#elif defined(HAVE_MIGRATE_MODE_H)
	#include <linux/migrate_mode.h>
#endif

int
main (void)
{

	struct address_space_operations aops;

	aops.migratepage(NULL, NULL, NULL, MIGRATE_ASYNC);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_MIGRATEPAGE_4ARGS 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking if super_operations use dentry as parameter" >&5
$as_echo_n "checking if super_operations use dentry as parameter... " >&6; }
tmp_flags="$EXTRA_KCFLAGS"
EXTRA_KCFLAGS="-Werror"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>
	int show_options(struct seq_file *seq, struct dentry *root){
		return 0;
	}

int
main (void)
{

	struct super_operations ops;
	ops.show_options = show_options;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_SUPEROPS_USE_DENTRY 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
EXTRA_KCFLAGS="$tmp_flags"

	 { $as_echo "$as_me:$LINENO: checking if inode_operations use umode_t as parameter" >&5
$as_echo_n "checking if inode_operations use umode_t as parameter... " >&6; }
tmp_flags="$EXTRA_KCFLAGS"
EXTRA_KCFLAGS="-Werror"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>
	#include <linux/types.h>
	int my_mknod(struct inode *dir, struct dentry *dchild,
		     umode_t mode, dev_t dev)
	{
		return 0;
	}

int
main (void)
{

	struct inode_operations ops;
	ops.mknod = my_mknod;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_INODEOPS_USE_UMODE_T 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
EXTRA_KCFLAGS="$tmp_flags"


	 # 3.4
	 { $as_echo "$as_me:$LINENO: checking if touch_atime use one argument" >&5
$as_echo_n "checking if touch_atime use one argument... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	touch_atime((struct path *)NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_TOUCH_ATIME_1ARG 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking if have d_make_root" >&5
$as_echo_n "checking if have d_make_root... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	d_make_root((struct inode *)NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_D_MAKE_ROOT 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking if kmap_atomic has only 1 argument" >&5
$as_echo_n "checking if kmap_atomic has only 1 argument... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/highmem.h>

int
main (void)
{

	kmap_atomic(NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_KMAP_ATOMIC_HAS_1ARG 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 # 3.5
	 { $as_echo "$as_me:$LINENO: checking if have clear_inode" >&5
$as_echo_n "checking if have clear_inode... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	clear_inode((struct inode *)NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_CLEAR_INODE 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking if encode_fh have parent inode as parameter" >&5
$as_echo_n "checking if encode_fh have parent inode as parameter... " >&6; }
tmp_flags="$EXTRA_KCFLAGS"
EXTRA_KCFLAGS="-Werror"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/exportfs.h>
	#include <linux/fs.h>
	#include <linux/types.h>
	int ll_encode_fh(struct inode *i, __u32 *a, int *b, struct inode *p)
	{
		return 0;
	}

int
main (void)
{

	struct export_operations exp_op;
	exp_op.encode_fh = ll_encode_fh;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_ENCODE_FH_PARENT 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
EXTRA_KCFLAGS="$tmp_flags"

	 { $as_echo "$as_me:$LINENO: checking if kernel has generic_file_llseek_size with 5 args" >&5
$as_echo_n "checking if kernel has generic_file_llseek_size with 5 args... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	generic_file_llseek_size(NULL, 0, 0, 0, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_FILE_LLSEEK_SIZE_5ARGS 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 # 3.6
	 { $as_echo "$as_me:$LINENO: checking if i_dentry/d_alias uses hlist" >&5
$as_echo_n "checking if i_dentry/d_alias uses hlist... " >&6; }
tmp_flags="$EXTRA_KCFLAGS"
EXTRA_KCFLAGS="-Werror"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>
	#include <linux/list.h>

int
main (void)
{

	struct inode inode;
	struct dentry dentry;
	struct hlist_head head;
	struct hlist_node node;
	inode.i_dentry = head;
	dentry.d_alias = node;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_DENTRY_D_ALIAS_HLIST 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
EXTRA_KCFLAGS="$tmp_flags"

	 { $as_echo "$as_me:$LINENO: checking if dentry_open uses struct path as first argument" >&5
$as_echo_n "checking if dentry_open uses struct path as first argument... " >&6; }
tmp_flags="$EXTRA_KCFLAGS"
EXTRA_KCFLAGS="-Werror"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>
	#include <linux/path.h>

int
main (void)
{

	struct path path;
	dentry_open(&path, 0, NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_DENTRY_OPEN_USE_PATH 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
EXTRA_KCFLAGS="$tmp_flags"

	 { $as_echo "$as_me:$LINENO: checking if iop has atomic_open" >&5
$as_echo_n "checking if iop has atomic_open... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	struct inode_operations iop;
	iop.atomic_open = NULL;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_IOP_ATOMIC_OPEN 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 # 3.7
	 { $as_echo "$as_me:$LINENO: checking if posix_acl_to_xattr takes struct user_namespace" >&5
$as_echo_n "checking if posix_acl_to_xattr takes struct user_namespace... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>
	#include <linux/posix_acl_xattr.h>

int
main (void)
{

	posix_acl_to_xattr((struct user_namespace *)NULL, NULL, NULL, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_POSIXACL_USER_NS 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 # 3.9
	 { $as_echo "$as_me:$LINENO: checking if hlist_for_each_entry has 3 args" >&5
$as_echo_n "checking if hlist_for_each_entry has 3 args... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/list.h>
	#include <linux/fs.h>

int
main (void)
{

	struct inode *inode;
	struct dentry *dentry;
	hlist_for_each_entry(dentry, &inode->i_dentry, d_alias) {
		continue;
	}

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_HLIST_FOR_EACH_3ARG 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	 { $as_echo "$as_me:$LINENO: checking if struct file has f_path.mnt" >&5
$as_echo_n "checking if struct file has f_path.mnt... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>

int
main (void)
{

	struct file *fp = NULL;
	struct path  path;

	path.mnt = fp->f_path.mnt;

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_F_PATH_MNT 1
_ACEOF

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 #
	 if test x$enable_server != xno ; then
		{ $as_echo "$as_me:$LINENO: checking if Linux was built with symbol dev_set_rdonly exported" >&5
$as_echo_n "checking if Linux was built with symbol dev_set_rdonly exported... " >&6; }
grep -q -E '[[:space:]]dev_set_rdonly[[:space:]]' $LINUX_OBJ/$SYMVERFILE 2>/dev/null
rc=$?
if test $rc -ne 0; then
	export=0
	for file in block/ll_rw_block.c,block/blk-core.c; do
		grep -q -E "EXPORT_SYMBOL.*\(dev_set_rdonly\)" "$LINUX/$file" 2>/dev/null
		rc=$?
		if test $rc -eq 0; then
			export=1
			break;
		fi
	done
	if test $export -eq 0; then
		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

        { $as_echo "$as_me:$LINENO: WARNING: kernel missing dev_set_rdonly patch for testing" >&5
$as_echo "$as_me: WARNING: kernel missing dev_set_rdonly patch for testing" >&2;}

	else
		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


cat >>confdefs.h <<\_ACEOF
#define HAVE_DEV_SET_RDONLY 1
_ACEOF


	fi
else
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


cat >>confdefs.h <<\_ACEOF
#define HAVE_DEV_SET_RDONLY 1
_ACEOF


fi


		{ $as_echo "$as_me:$LINENO: checking stack size big than 8k" >&5
$as_echo_n "checking stack size big than 8k... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/thread_info.h>

int
main (void)
{

        #if THREAD_SIZE < 8192
        #error "stack size < 8192"
        #endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

        { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


        { { $as_echo "$as_me:$LINENO: error: Lustre requires that Linux is configured with at least a 8KB stack." >&5
$as_echo "$as_me: error: Lustre requires that Linux is configured with at least a 8KB stack." >&2;}
   { (exit 1); exit 1; }; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


        { $as_echo "$as_me:$LINENO: checking if kernel has 64-bit quota limits support" >&5
$as_echo_n "checking if kernel has 64-bit quota limits support... " >&6; }
tmp_flags="$EXTRA_KCFLAGS"
EXTRA_KCFLAGS="-I$LINUX/fs"
        cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

                #include <linux/kernel.h>
                #include <linux/fs.h>
		#if defined(HAVE_FS_QUOTA_QUOTAIO_H)
                # include <quota/quotaio_v2.h>
                struct v2r1_disk_dqblk dqblk_r1;
                #else
                #include <linux/quota.h>
                int ver = QFMT_VFS_V1;
                #endif

int
main (void)
{

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_QUOTA64 1
_ACEOF

                { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


                as_lb_File=`$as_echo "lb_cv_file_$LINUX/include/linux/lustre_version.h" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $LINUX/include/linux/lustre_version.h" >&5
$as_echo_n "checking for $LINUX/include/linux/lustre_version.h... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$LINUX/include/linux/lustre_version.h"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then

                        { { $as_echo "$as_me:$LINENO: error: You have got no 64-bit kernel quota support." >&5
$as_echo "$as_me: error: You have got no 64-bit kernel quota support." >&2;}
   { (exit 1); exit 1; }; }

fi

                { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c
EXTRA_KCFLAGS=$tmp_flags


	{ $as_echo "$as_me:$LINENO: checking if Linux was built with CONFIG_QUOTA in or as module" >&5
$as_echo_n "checking if Linux was built with CONFIG_QUOTA in or as module... " >&6; }
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

		#include <$AUTOCONF_HDIR/autoconf.h>

int
main (void)
{

		#if !(defined(CONFIG_QUOTA) || defined(CONFIG_QUOTA_MODULE))
		#error CONFIG_QUOTA and CONFIG_QUOTA_MODULE not #defined
		#endif

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

        { { $as_echo "$as_me:$LINENO: error: Lustre quota requires that CONFIG_QUOTA is enabled in your kernel." >&5
$as_echo "$as_me: error: Lustre quota requires that CONFIG_QUOTA is enabled in your kernel." >&2;}
   { (exit 1); exit 1; }; }


fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


	 fi

			;;
		darwin*)
			kernel_framework="/System/Library/Frameworks/Kernel.framework"
#
# FIXME: there should be a better way to get these than hard coding them
#
case $target_cpu in
	powerpc*)
		EXTRA_KCFLAGS="$EXTRA_KCFLAGS -arch ppc -mtune=G4 -mlong-branch"
		EXTRA_KLDFLAGS="-arch ppc"
		;;
	i?86 | x86_64)
		EXTRA_KCFLAGS="$EXTRA_KCFLAGS -arch i386"
		EXTRA_KLDFLAGS="-arch i386"
		;;
esac

# Kernel of OS X is not 64bits(even in Tiger), but -m64 can be taken by gcc in Tiger
# (Tiger can support 64bits applications), so we have to eliminate -m64 while
# building kextensions for and OS X.
CC=`echo $CC | sed -e "s/\-m64//g"`
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -x c -pipe -Wno-trigraphs -fasm-blocks -g -O0"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -Wno-four-char-constants -Wmost -O0"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -fmessage-length=0"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -I$kernel_framework/Headers"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -I$kernel_framework/Headers/bsd"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -I$kernel_framework/PrivateHeaders"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -fno-common -nostdinc -fno-builtin"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -finline -fno-keep-inline-functions"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -force_cpusubtype_ALL -fno-exceptions"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -msoft-float -static"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -DKERNEL -DKERNEL_PRIVATE"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -DDRIVER_PRIVATE -DAPPLE -DNeXT"
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -D__KERNEL__ -D__DARWIN__"
#
# C flags for Panther/Tiger
#
case $target_os in
        darwin8*)
                EXTRA_KCFLAGS="$EXTRA_KCFLAGS -D__DARWIN8__"
	;;
        darwin7*)
                EXTRA_KCFLAGS="$EXTRA_KCFLAGS -ffix-and-continue"
        ;;
esac

#
# Debugging flags. Remove!
#
EXTRA_KCFLAGS="$EXTRA_KCFLAGS -O0 -DMACH_ASSERT=1"
EXTRA_KLDFLAGS="$EXTRA_KLDFLAGS -static -nostdlib -r"
EXTRA_KLIBS="-lkmodc++ -lkmod -lcc_kext"
KMODEXT=""




kextdir='/System/Library/Extensions/$(firstword $(macos_PROGRAMS)).kext'
plistdir='$(kextdir)/Contents'
macosdir='$(plistdir)/MacOS'






for ac_func in get_preemption_level
do
{ $as_echo "$as_me:$LINENO: checking for get_preemption_level" >&5
$as_echo_n "checking for get_preemption_level... " >&6; }
if { ac_try='nm /mach | grep "get_preemption_level" >/dev/null 2>/dev/null'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
	cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF


else

	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

done



LP_PROG_DARWIN

LC_PROG_DARWIN


for ac_func in get_preemption_level
do
{ $as_echo "$as_me:$LINENO: checking for get_preemption_level" >&5
$as_echo_n "checking for get_preemption_level... " >&6; }
if { ac_try='nm /mach | grep "get_preemption_level" >/dev/null 2>/dev/null'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
	cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF


else

	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

done


			;;
		*)
			# This is strange - Lustre supports a target we don't
			{ { $as_echo "$as_me:$LINENO: error: Modules are not supported on $target_os" >&5
$as_echo "$as_me: error: Modules are not supported on $target_os" >&2;}
   { (exit 1); exit 1; }; }
			;;
	esac
fi

if test x$enable_modules = xno; then
  enable_server=no
fi


# --with-ldiskfs is deprecated now that ldiskfs is fully merged with lustre.
# However we continue to support this option through Lustre 2.5.

# Check whether --with-ldiskfs was given.
if test "${with_ldiskfs+set}" = set; then
  withval=$with_ldiskfs; { $as_echo "$as_me:$LINENO: WARNING: --with-ldiskfs is deprecated, please use --enable-ldiskfs" >&5
$as_echo "$as_me: WARNING: --with-ldiskfs is deprecated, please use --enable-ldiskfs" >&2;}
	if test x$withval != xyes -a x$withval != xno; then
  { { $as_echo "$as_me:$LINENO: error: the ldiskfs option is deprecated, and
			no longer supports paths to external ldiskfs source" >&5
$as_echo "$as_me: error: the ldiskfs option is deprecated, and
			no longer supports paths to external ldiskfs source" >&2;}
   { (exit 1); exit 1; }; }
fi



fi


# Check whether --enable-ldiskfs was given.
if test "${enable_ldiskfs+set}" = set; then
  enableval=$enable_ldiskfs; if test x$enable_ldiskfs != xyes -a x$enable_ldiskfs != xno; then
  { { $as_echo "$as_me:$LINENO: error: ldiskfs valid options are \"yes\" or \"no\"" >&5
$as_echo "$as_me: error: ldiskfs valid options are \"yes\" or \"no\"" >&2;}
   { (exit 1); exit 1; }; }
fi

else
  if test "${with_ldiskfs+set}" = set; then
  enable_ldiskfs=$with_ldiskfs
else
  enable_ldiskfs=maybe
fi



fi


if test x$enable_server = xno; then
  case $enable_ldiskfs in
  maybe) enable_ldiskfs=no ;;
  yes) { { $as_echo "$as_me:$LINENO: error: cannot build ldiskfs when servers are disabled" >&5
$as_echo "$as_me: error: cannot build ldiskfs when servers are disabled" >&2;}
   { (exit 1); exit 1; }; }
	 ;;
esac


fi


if test x$enable_ldiskfs != xno; then

	# In the future, we chould change enable_ldiskfs from maybe to
	# either yes or no based on additional tests, e.g.  whether a patch
	# set is available for the detected kernel.  For now, we just always
	# set it to "yes".
	if test x$enable_ldiskfs = xmaybe; then
  enable_ldiskfs=yes
fi



LDISKFS_SERIES=
{ $as_echo "$as_me:$LINENO: checking which ldiskfs series to use" >&5
$as_echo_n "checking which ldiskfs series to use... " >&6; }

SER=
if test x$RHEL_KERNEL = xyes; then

	as_arg_v1=$RHEL_KERNEL_VERSION
as_arg_v2=2.6.32-431
awk "$as_awk_strverscmp" v1="$as_arg_v1" v2="$as_arg_v2" /dev/null
case $? in
1)
	as_arg_v1=$RHEL_KERNEL_VERSION
as_arg_v2=2.6.32-343
awk "$as_awk_strverscmp" v1="$as_arg_v1" v2="$as_arg_v2" /dev/null
case $? in
1)
	as_arg_v1=$RHEL_KERNEL_VERSION
as_arg_v2=2.6.32
awk "$as_awk_strverscmp" v1="$as_arg_v1" v2="$as_arg_v2" /dev/null
case $? in
1) ;;
0) SER="2.6-rhel6.series";;
2) SER="2.6-rhel6.series";;
esac;;
0) SER="2.6-rhel6.4.series";;
2) SER="2.6-rhel6.4.series";;
esac;;
0) SER="2.6-rhel6.5.series";;
2) SER="2.6-rhel6.5.series";;
esac

elif test x$SUSE_KERNEL = xyes; then

	as_arg_v1=$LINUXRELEASE
as_arg_v2=3.0.0
awk "$as_awk_strverscmp" v1="$as_arg_v1" v2="$as_arg_v2" /dev/null
case $? in
1)
	as_arg_v1=$LINUXRELEASE
as_arg_v2=2.6.32
awk "$as_awk_strverscmp" v1="$as_arg_v1" v2="$as_arg_v2" /dev/null
case $? in
1) ;;
0) SER="2.6-sles11.series";;
2) SER="2.6-sles11.series";;
esac;;
0) SER="3.0-sles11.series";;
2)
		PLEV=$(grep PATCHLEVEL /etc/SuSE-release | sed -e 's/.*= *//')
		case $PLEV in
		2) SER="3.0-sles11.series"
			;;
		3) SER="3.0-sles11sp3.series"
			;;
		esac
	;;
esac

fi

LDISKFS_SERIES=$SER

if test -z "$LDISKFS_SERIES"; then
  { $as_echo "$as_me:$LINENO: WARNING: Unknown kernel version $LDISKFS_VERSIONRELEASE" >&5
$as_echo "$as_me: WARNING: Unknown kernel version $LDISKFS_VERSIONRELEASE" >&2;}
fi

{ $as_echo "$as_me:$LINENO: result: $LDISKFS_SERIES" >&5
$as_echo "$LDISKFS_SERIES" >&6; }




	# Check whether --enable-quilt was given.
if test "${enable_quilt+set}" = set; then
  enableval=$enable_quilt; if test "x$enableval" = xno; then
  use_quilt=no
else
  use_quilt=maybe
fi

else
  use_quilt=maybe

fi


	if test x$use_quilt = xmaybe; then

		# Extract the first word of "quilt", so it can be a program name with args.
set dummy quilt; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_path_quilt_avail+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  case $quilt_avail in
  [\\/]* | ?:[\\/]*)
  ac_cv_path_quilt_avail="$quilt_avail" # Let the user override the test with a path.
  ;;
  *)
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_path_quilt_avail="$as_dir/$ac_word$ac_exec_ext"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

  test -z "$ac_cv_path_quilt_avail" && ac_cv_path_quilt_avail="no"
  ;;
esac
fi
quilt_avail=$ac_cv_path_quilt_avail
if test -n "$quilt_avail"; then
  { $as_echo "$as_me:$LINENO: result: $quilt_avail" >&5
$as_echo "$quilt_avail" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


		if test x$quilt_avail = xno; then

			use_quilt=no

else

			use_quilt=yes

fi


fi


	if test x$use_quilt = xno; then

		# Extract the first word of "patch", so it can be a program name with args.
set dummy patch; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_path_patch_avail+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  case $patch_avail in
  [\\/]* | ?:[\\/]*)
  ac_cv_path_patch_avail="$patch_avail" # Let the user override the test with a path.
  ;;
  *)
  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_path_patch_avail="$as_dir/$ac_word$ac_exec_ext"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

  test -z "$ac_cv_path_patch_avail" && ac_cv_path_patch_avail="no"
  ;;
esac
fi
patch_avail=$ac_cv_path_patch_avail
if test -n "$patch_avail"; then
  { $as_echo "$as_me:$LINENO: result: $patch_avail" >&5
$as_echo "$patch_avail" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


		if test x$patch_avail = xno; then

			{ { $as_echo "$as_me:$LINENO: error: *** Need \"quilt\" or \"patch\" command" >&5
$as_echo "$as_me: error: *** Need \"quilt\" or \"patch\" command" >&2;}
   { (exit 1); exit 1; }; }

fi


fi


	{ $as_echo "$as_me:$LINENO: checking if ext4_free_blocks needs struct buffer_head" >&5
$as_echo_n "checking if ext4_free_blocks needs struct buffer_head... " >&6; }
 cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>
	#include "$EXT4_SRC_DIR/ext4.h"

int
main (void)
{

	ext4_free_blocks(NULL, NULL, NULL, 0, 0, 0);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_EXT_FREE_BLOCK_WITH_BUFFER_HEAD 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

	{ $as_echo "$as_me:$LINENO: checking if kernel has ext_pblocks" >&5
$as_echo_n "checking if kernel has ext_pblocks... " >&6; }
 cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

	#include <linux/fs.h>
	#include "$EXT4_SRC_DIR/ext4_extents.h"

int
main (void)
{

	ext_pblock(NULL);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_EXT_PBLOCK 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c


cat >>confdefs.h <<\_ACEOF
#define CONFIG_LDISKFS_FS_POSIX_ACL 1
_ACEOF


cat >>confdefs.h <<\_ACEOF
#define CONFIG_LDISKFS_FS_SECURITY 1
_ACEOF


cat >>confdefs.h <<\_ACEOF
#define CONFIG_LDISKFS_FS_XATTR 1
_ACEOF


cat >>confdefs.h <<\_ACEOF
#define CONFIG_LDISKFS_FS_RW 1
_ACEOF

	LDISKFS_SUBDIR=ldiskfs


cat >>confdefs.h <<\_ACEOF
#define HAVE_LDISKFS_OSD 1
_ACEOF


fi


{ $as_echo "$as_me:$LINENO: checking whether to build ldiskfs" >&5
$as_echo_n "checking whether to build ldiskfs... " >&6; }
{ $as_echo "$as_me:$LINENO: result: $enable_ldiskfs" >&5
$as_echo "$enable_ldiskfs" >&6; }

 if test x$enable_ldiskfs = xyes; then
  LDISKFS_ENABLED_TRUE=
  LDISKFS_ENABLED_FALSE='#'
else
  LDISKFS_ENABLED_TRUE='#'
  LDISKFS_ENABLED_FALSE=
fi




# Check whether --with-zfs was given.
if test "${with_zfs+set}" = set; then
  withval=$with_zfs;
			if test x$withval = xno; then

				enable_zfs=no
				require_zfs=no

elif test x$withval = xyes; then

				enable_zfs=yes
				require_zfs=yes

else

				enable_zfs=yes
				require_zfs=yes
				zfssrc="$withval"

fi


else

			if test x$enable_server != xno; then

				require_zfs=no
				enable_zfs=yes

else

				require_zfs=no
				enable_zfs=no

fi


fi


	{ $as_echo "$as_me:$LINENO: checking whether to enable zfs" >&5
$as_echo_n "checking whether to enable zfs... " >&6; }
	{ $as_echo "$as_me:$LINENO: result: $enable_zfs" >&5
$as_echo "$enable_zfs" >&6; }

	if test x$enable_zfs = xyes; then

		if test x$enable_modules = xyes; then



# Check whether --with-spl was given.
if test "${with_spl+set}" = set; then
  withval=$with_spl; splsrc="$withval"
fi



# Check whether --with-spl-obj was given.
if test "${with_spl_obj+set}" = set; then
  withval=$with_spl_obj; splobj="$withval"
fi


					splver=$(ls -1 /usr/src/ | grep -m1 spl | cut -f2 -d'-')
	splsrc0="/var/lib/dkms/spl/${splver}/build"
	splsrc1="/usr/src/spl-${splver}/${LINUXRELEASE}"
	splsrc2="/usr/src/spl-${splver}"
	splsrc3="../spl/"
	splsrc4="$LINUX"

	{ $as_echo "$as_me:$LINENO: checking spl source directory" >&5
$as_echo_n "checking spl source directory... " >&6; }
	if test -z "${splsrc}"; then

		if test -e "${splsrc0}/spl.release.in"; then

			splsrc=${splsrc0}

elif test -e "${splsrc1}/spl.release.in"; then

			splsrc=${splsrc1}

elif test -e "${splsrc2}/spl.release.in"; then

			splsrc=${splsrc2}

elif test -e "${splsrc3}/spl.release.in"; then

			splsrc=$(readlink -f "${splsrc3}")

elif test -e "${splsrc4}/spl.release.in"; then

			splsrc=${splsrc4}

else

			splsrc="Not found"

fi


fi

	{ $as_echo "$as_me:$LINENO: result: $splsrc" >&5
$as_echo "$splsrc" >&6; }

	if test ! -e "$splsrc/spl.release" &&
	    test ! -e "$splsrc/spl.release.in"; then

		enable_zfs=no

fi


							{ $as_echo "$as_me:$LINENO: checking spl build directory" >&5
$as_echo_n "checking spl build directory... " >&6; }
	if test -z "$splobj"; then

		if test -e "${splsrc}/${LINUXRELEASE}/spl_config.h"; then

			splobj="${splsrc}/${LINUXRELEASE}"

elif test -e "${splsrc}/spl_config.h"; then

			splobj="${splsrc}"

else

			splobj="Not found"

fi


fi

	{ $as_echo "$as_me:$LINENO: result: $splobj" >&5
$as_echo "$splobj" >&6; }

	if test ! -e "$splobj/spl_config.h"; then

		enable_zfs=no

fi


				if test x$enable_zfs = xyes; then

		{ $as_echo "$as_me:$LINENO: checking spl source version" >&5
$as_echo_n "checking spl source version... " >&6; }
		if fgrep -q SPL_META_VERSION $splobj/spl_config.h; then

			splver=$((echo "#include <spl_config.h>";
			    echo "splver=SPL_META_VERSION-SPL_META_RELEASE") |
			    cpp -I $splobj |
			    grep "^splver=" | tr -d \" | cut -d= -f2)

else

			splver="Not found"
			enable_zfs=no

fi

		{ $as_echo "$as_me:$LINENO: result: $splver" >&5
$as_echo "$splver" >&6; }

fi


				if test x$enable_zfs = xyes; then

		{ $as_echo "$as_me:$LINENO: checking spl file name for module symbols" >&5
$as_echo_n "checking spl file name for module symbols... " >&6; }
		if test -r $splobj/$SYMVERFILE; then

			splsym=$SYMVERFILE

elif test -r $splobj/module/$SYMVERFILE; then

			splsym=$SYMVERFILE

else

			splsym="Not found"
			enable_zfs=no

fi

		{ $as_echo "$as_me:$LINENO: result: $splsym" >&5
$as_echo "$splsym" >&6; }

fi


	SPL=${splsrc}
	SPL_OBJ=${splobj}
	SPL_VERSION=${splver}
	SPL_SYMBOLS=${splsym}








# Check whether --with-zfs-obj was given.
if test "${with_zfs_obj+set}" = set; then
  withval=$with_zfs_obj; zfsobj="$withval"
fi


					zfsver=$(ls -1 /usr/src/ | grep -m1 zfs | cut -f2 -d'-')
	zfssrc0="/var/lib/dkms/zfs/${zfsver}/build"
	zfssrc1="/usr/src/zfs-${zfsver}/${LINUXRELEASE}"
	zfssrc2="/usr/src/zfs-${zfsver}"
	zfssrc3="../zfs/"
	zfssrc4="$LINUX"

	{ $as_echo "$as_me:$LINENO: checking zfs source directory" >&5
$as_echo_n "checking zfs source directory... " >&6; }
	if test -z "${zfssrc}"; then

		if test -e "${zfssrc0}/zfs.release.in"; then

			zfssrc=${zfssrc0}

elif test -e "${zfssrc1}/zfs.release.in"; then

			zfssrc=${zfssrc1}

elif test -e "${zfssrc2}/zfs.release.in"; then

			zfssrc=${zfssrc2}

elif test -e "${zfssrc3}/zfs.release.in"; then

			zfssrc=$(readlink -f "${zfssrc3}")

elif test -e "${zfssrc4}/zfs.release.in"; then

			zfssrc=${zfssrc4}

else

			zfssrc="Not found"

fi


fi

	{ $as_echo "$as_me:$LINENO: result: $zfssrc" >&5
$as_echo "$zfssrc" >&6; }

	if test ! -e "$zfssrc/zfs.release.in" &&
	    test ! -e "$zfssrc/zfs.release"; then

		enable_zfs=no

fi


							{ $as_echo "$as_me:$LINENO: checking zfs build directory" >&5
$as_echo_n "checking zfs build directory... " >&6; }
	if test -z "$zfsobj"; then

		if test -e "${zfssrc}/${LINUXRELEASE}/zfs_config.h"; then

			zfsobj="${zfssrc}/${LINUXRELEASE}"

elif test -e "${zfssrc}/zfs_config.h"; then

			zfsobj="${zfssrc}"

else

			zfsobj="Not found"

fi


fi


	{ $as_echo "$as_me:$LINENO: result: $zfsobj" >&5
$as_echo "$zfsobj" >&6; }
	if test ! -e "$zfsobj/zfs_config.h"; then

		enable_zfs=no

fi


				if test x$enable_zfs = xyes; then

		{ $as_echo "$as_me:$LINENO: checking zfs source version" >&5
$as_echo_n "checking zfs source version... " >&6; }
		if fgrep -q ZFS_META_VERSION $zfsobj/zfs_config.h; then

			zfsver=$((echo "#include <zfs_config.h>";
			    echo "zfsver=ZFS_META_VERSION-ZFS_META_RELEASE") |
			    cpp -I $zfsobj |
			    grep "^zfsver=" | tr -d \" | cut -d= -f2)

else

			zfsver="Not found"
			enable_zfs=no

fi

		{ $as_echo "$as_me:$LINENO: result: $zfsver" >&5
$as_echo "$zfsver" >&6; }

fi


				if test x$enable_zfs = xyes; then

		{ $as_echo "$as_me:$LINENO: checking zfs file name for module symbols" >&5
$as_echo_n "checking zfs file name for module symbols... " >&6; }
		if test -r $zfsobj/$SYMVERFILE; then

			zfssym=$SYMVERFILE

elif test -r $zfsobj/module/$SYMVERFILE; then

			zfssym=$SYMVERFILE

else

			zfssym="Not found"
			enable_zfs=no

fi

		{ $as_echo "$as_me:$LINENO: result: $zfssym" >&5
$as_echo "$zfssym" >&6; }

fi


	ZFS=${zfssrc}
	ZFS_OBJ=${zfsobj}
	ZFS_VERSION=${zfsver}
	ZFS_SYMBOLS=${zfssym}







fi



# Check whether --with-zfs-devel was given.
if test "${with_zfs_devel+set}" = set; then
  withval=$with_zfs_devel; zfsdevel="$withval"
fi


	{ $as_echo "$as_me:$LINENO: checking user provided zfs devel headers" >&5
$as_echo_n "checking user provided zfs devel headers... " >&6; }
	if test ! -z "${zfsdevel}"; then

		if test -d "${zfsdevel}/usr/include/libspl" && test -d "${zfsdevel}/usr/include/libzfs"; then

			zfslib="-I $zfsdevel/usr/include/libspl -I $zfsdevel/usr/include/libzfs"

else

			{ { $as_echo "$as_me:$LINENO: error: Path to development headers directory does not exist" >&5
$as_echo "$as_me: error: Path to development headers directory does not exist" >&2;}
   { (exit 1); exit 1; }; }

fi


fi

	{ $as_echo "$as_me:$LINENO: result: $zfslib" >&5
$as_echo "$zfslib" >&6; }


				{ $as_echo "$as_me:$LINENO: checking zfs devel headers" >&5
$as_echo_n "checking zfs devel headers... " >&6; }
	if test -z "${zfslib}"; then

        	if test -e "${zfssrc}/include/libzfs.h" && test -e "${zfssrc}/lib/libspl/include"; then

                	zfslib="-I $zfssrc/lib/libspl/include -I $zfssrc/include"

elif test -d /usr/include/libzfs && test -d /usr/include/libspl; then

			zfslib="-I /usr/include/libspl -I /usr/include/libzfs"

else

			zfslib="Not Found"
			enable_zfs=no

fi


fi

	{ $as_echo "$as_me:$LINENO: result: $zfslib" >&5
$as_echo "$zfslib" >&6; }

	ZFS_LIBZFS_INCLUDE=${zfslib}



										if test x$enable_zfs = xyes; then


cat >>confdefs.h <<\_ACEOF
#define HAVE_ZFS_OSD 1
_ACEOF


else

			if test x$require_zfs = xyes; then

				{ { $as_echo "$as_me:$LINENO: error:

Required zfs osd cannot be built due to missing zfs development headers.

Support for zfs can be enabled by downloading the required packages for your
distribution.  See http://zfsonlinux.org/ to determine is zfs is supported by
your distribution.
				" >&5
$as_echo "$as_me: error:

Required zfs osd cannot be built due to missing zfs development headers.

Support for zfs can be enabled by downloading the required packages for your
distribution.  See http://zfsonlinux.org/ to determine is zfs is supported by
your distribution.
				" >&2;}
   { (exit 1); exit 1; }; }

else

				{ $as_echo "$as_me:$LINENO: WARNING:

Disabling optional zfs osd due to missing development headers.

Support for zfs can be enabled by downloading the required packages for your
distribution.  See http://zfsonlinux.org/ to determine is zfs is supported by
your distribution.
				" >&5
$as_echo "$as_me: WARNING:

Disabling optional zfs osd due to missing development headers.

Support for zfs can be enabled by downloading the required packages for your
distribution.  See http://zfsonlinux.org/ to determine is zfs is supported by
your distribution.
				" >&2;}

fi


fi


fi


	if test x$enable_zfs = xyes; then

		{ $as_echo "$as_me:$LINENO: checking if zfs defines dsl_pool_config_enter/exit" >&5
$as_echo_n "checking if zfs defines dsl_pool_config_enter/exit... " >&6; }
		cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

#include <linux/kernel.h>

			#include <sys/dsl_pool.h>

int
main (void)
{

			dsl_pool_config_enter(NULL, FTAG);

  ;
  return 0;
}
_ACEOF
rm -f build/conftest.o build/conftest.mod.c build/conftest.ko
SUBARCH=$(echo $target_cpu | sed -e 's/powerpc64/powerpc/' -e 's/x86_64/x86/' -e 's/i.86/x86/' -e 's/k1om/x86/')
if { ac_try='cp conftest.c build && make -d modules ${LD:+"LD=$LD"} CC="$CC" -f $PWD/build/Makefile LUSTRE_LINUX_CONFIG=$LINUX_CONFIG LINUXINCLUDE="$EXTRA_LNET_INCLUDE -I$LINUX/arch/$SUBARCH/include -I$LINUX/arch/$SUBARCH/include/generated -Iinclude -I$LINUX/include -Iinclude2 -I$LINUX/include/uapi -I$LINUX/include/generated -I$LINUX/arch/$SUBARCH/include/uapi -Iarch/$SUBARCH/include/generated/uapi -I$LINUX/include/uapi -Iinclude/generated/uapi ${SPL_OBJ:+-include $SPL_OBJ/spl_config.h} ${ZFS_OBJ:+-include $ZFS_OBJ/zfs_config.h} ${SPL:+-I$SPL -I$SPL/include } ${ZFS:+-I$ZFS -I$ZFS/include} -include $CONFIG_INCLUDE" -o tmp_include_depends -o scripts -o include/config/MARKER -C $LINUX_OBJ EXTRA_CFLAGS="-Werror-implicit-function-declaration $EXTRA_KCFLAGS" $CROSS_VARS $MODULE_TARGET=$PWD/build'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; } >/dev/null && { ac_try='test -s build/conftest.o'
  { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
  (eval $ac_try) 2>&5
  ac_status=$?
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); }; }; then

			{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_DSL_POOL_CONFIG 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


			{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f build/conftest.o build/conftest.mod.c build/conftest.mod.o build/conftest.ko build/conftest.c conftest.c

fi


	 if test x$enable_zfs = xyes; then
  ZFS_ENABLED_TRUE=
  ZFS_ENABLED_FALSE='#'
else
  ZFS_ENABLED_TRUE='#'
  ZFS_ENABLED_FALSE=
fi



# If no backends were configured, and the user did not explicitly
# require servers to be enabled, we just disable servers.
if test x$enable_ldiskfs = xno -a x$enable_zfs = xno; then
  case $enable_server in
  maybe) enable_server=no ;;
  yes) { { $as_echo "$as_me:$LINENO: error: cannot enable servers, no backends were configured" >&5
$as_echo "$as_me: error: cannot enable servers, no backends were configured" >&2;}
   { (exit 1); exit 1; }; } ;;
esac


else
  if test x$enable_server = xmaybe; then
  enable_server=yes
fi


fi


{ $as_echo "$as_me:$LINENO: checking whether to build Lustre server support" >&5
$as_echo_n "checking whether to build Lustre server support... " >&6; }
{ $as_echo "$as_me:$LINENO: result: $enable_server" >&5
$as_echo "$enable_server" >&6; }
if test x$enable_server = xyes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_SERVER_SUPPORT 1
_ACEOF


fi



# two macros for cmd3
{ $as_echo "$as_me:$LINENO: checking whether to enable split support" >&5
$as_echo_n "checking whether to enable split support... " >&6; }
# Check whether --enable-split was given.
if test "${enable_split+set}" = set; then
  enableval=$enable_split;
else
  enable_split='no'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_split" >&5
$as_echo "$enable_split" >&6; }
if test x$enable_split != xno; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_SPLIT_SUPPORT 1
_ACEOF

fi


{ $as_echo "$as_me:$LINENO: checking whether to enable CDEBUG, CWARN" >&5
$as_echo_n "checking whether to enable CDEBUG, CWARN... " >&6; }
# Check whether --enable-libcfs_cdebug was given.
if test "${enable_libcfs_cdebug+set}" = set; then
  enableval=$enable_libcfs_cdebug;
else
  enable_libcfs_cdebug='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_libcfs_cdebug" >&5
$as_echo "$enable_libcfs_cdebug" >&6; }
if test x$enable_libcfs_cdebug = xyes; then

cat >>confdefs.h <<\_ACEOF
#define CDEBUG_ENABLED 1
_ACEOF

else

cat >>confdefs.h <<\_ACEOF
#define CDEBUG_ENABLED 0
_ACEOF

fi

{ $as_echo "$as_me:$LINENO: checking whether to enable ENTRY/EXIT" >&5
$as_echo_n "checking whether to enable ENTRY/EXIT... " >&6; }
# Check whether --enable-libcfs_trace was given.
if test "${enable_libcfs_trace+set}" = set; then
  enableval=$enable_libcfs_trace;
else
  enable_libcfs_trace='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_libcfs_trace" >&5
$as_echo "$enable_libcfs_trace" >&6; }
if test x$enable_libcfs_trace = xyes; then

cat >>confdefs.h <<\_ACEOF
#define CDEBUG_ENTRY_EXIT 1
_ACEOF

else

cat >>confdefs.h <<\_ACEOF
#define CDEBUG_ENTRY_EXIT 0
_ACEOF

fi

{ $as_echo "$as_me:$LINENO: checking whether to enable LASSERT, LASSERTF" >&5
$as_echo_n "checking whether to enable LASSERT, LASSERTF... " >&6; }
# Check whether --enable-libcfs_assert was given.
if test "${enable_libcfs_assert+set}" = set; then
  enableval=$enable_libcfs_assert;
else
  enable_libcfs_assert='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_libcfs_assert" >&5
$as_echo "$enable_libcfs_assert" >&6; }
if test x$enable_libcfs_assert = xyes; then

cat >>confdefs.h <<\_ACEOF
#define LIBCFS_DEBUG 1
_ACEOF

fi

#check global
# Check whether --enable-quota was given.
if test "${enable_quota+set}" = set; then
  enableval=$enable_quota;
else
  enable_quota='yes'
fi


#check for utils
if test x$enable_quota != xno -a x$enable_utils != xno; then
if test "${ac_cv_header_sys_quota_h+set}" = set; then
  { $as_echo "$as_me:$LINENO: checking for sys/quota.h" >&5
$as_echo_n "checking for sys/quota.h... " >&6; }
if test "${ac_cv_header_sys_quota_h+set}" = set; then
  $as_echo_n "(cached) " >&6
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_sys_quota_h" >&5
$as_echo "$ac_cv_header_sys_quota_h" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking sys/quota.h usability" >&5
$as_echo_n "checking sys/quota.h usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <sys/quota.h>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking sys/quota.h presence" >&5
$as_echo_n "checking sys/quota.h presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <sys/quota.h>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: sys/quota.h: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: sys/quota.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: sys/quota.h: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: sys/quota.h: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: sys/quota.h: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: sys/quota.h: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: sys/quota.h:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: sys/quota.h:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: sys/quota.h: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: sys/quota.h: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: sys/quota.h:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: sys/quota.h:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: sys/quota.h: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: sys/quota.h: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: sys/quota.h: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: sys/quota.h: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for sys/quota.h" >&5
$as_echo_n "checking for sys/quota.h... " >&6; }
if test "${ac_cv_header_sys_quota_h+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_header_sys_quota_h=$ac_header_preproc
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_sys_quota_h" >&5
$as_echo "$ac_cv_header_sys_quota_h" >&6; }

fi
if test "x$ac_cv_header_sys_quota_h" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_SYS_QUOTA_H 1
_ACEOF

else
  { { $as_echo "$as_me:$LINENO: error: don't find <sys/quota.h> in your system" >&5
$as_echo "$as_me: error: don't find <sys/quota.h> in your system" >&2;}
   { (exit 1); exit 1; }; }
fi


fi






# Check whether --with-sysio was given.
if test "${with_sysio+set}" = set; then
  withval=$with_sysio;
else

		case $lb_target_os in
			linux)
				with_sysio='yes'
				;;
			*)
				with_sysio='no'
				;;
		esac

fi

{ $as_echo "$as_me:$LINENO: checking location of libsysio" >&5
$as_echo_n "checking location of libsysio... " >&6; }
enable_sysio="$with_sysio"
case x$with_sysio in
	xyes)
		{ $as_echo "$as_me:$LINENO: result: internal" >&5
$as_echo "internal" >&6; }
		as_lb_File=`$as_echo "lb_cv_file_$srcdir/libsysio/src/rmdir.c" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $srcdir/libsysio/src/rmdir.c" >&5
$as_echo_n "checking for $srcdir/libsysio/src/rmdir.c... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$srcdir/libsysio/src/rmdir.c"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  :
else

			{ { $as_echo "$as_me:$LINENO: error: A complete internal libsysio was not found." >&5
$as_echo "$as_me: error: A complete internal libsysio was not found." >&2;}
   { (exit 1); exit 1; }; }

fi

		LIBSYSIO_SUBDIR="libsysio"
		SYSIO="$PWD/libsysio"
		;;
	xno)
		{ $as_echo "$as_me:$LINENO: result: disabled" >&5
$as_echo "disabled" >&6; }
		;;
	*)
		{ $as_echo "$as_me:$LINENO: result: $with_sysio" >&5
$as_echo "$with_sysio" >&6; }
		as_lb_File=`$as_echo "lb_cv_file_$with_sysio/lib/libsysio.a" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $with_sysio/lib/libsysio.a" >&5
$as_echo_n "checking for $with_sysio/lib/libsysio.a... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$with_sysio/lib/libsysio.a"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  :
else

			{ { $as_echo "$as_me:$LINENO: error: A complete (built) external libsysio was not found." >&5
$as_echo "$as_me: error: A complete (built) external libsysio was not found." >&2;}
   { (exit 1); exit 1; }; }

fi

		SYSIO=$with_sysio
		with_sysio="yes"
		;;
esac

# We have to configure even if we don't build here for make dist to work
subdirs="$subdirs libsysio"


as_lb_File=`$as_echo "lb_cv_file_$srcdir/snmp/lustre-snmp.c" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $srcdir/snmp/lustre-snmp.c" >&5
$as_echo_n "checking for $srcdir/snmp/lustre-snmp.c... " >&6; }
if { as_var=$as_lb_File; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  if test -r "$srcdir/snmp/lustre-snmp.c"; then
	eval "$as_lb_File=yes"
else
	eval "$as_lb_File=no"
fi
fi
ac_res=`eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
if test `eval 'as_val=${'$as_lb_File'}
		 $as_echo "$as_val"'` = yes; then
  SNMP_DIST_SUBDIR="snmp"
fi




# Check whether --enable-iokit was given.
if test "${enable_iokit+set}" = set; then
  enableval=$enable_iokit;
else

		enable_iokit='yes'

fi

{ $as_echo "$as_me:$LINENO: checking whether to build iokit" >&5
$as_echo_n "checking whether to build iokit... " >&6; }
{ $as_echo "$as_me:$LINENO: result: $enable_iokit" >&5
$as_echo "$enable_iokit" >&6; }
if test "x$enable_iokit" = xyes; then
  LUSTREIOKIT_SUBDIR="lustre-iokit"
else
  LUSTREIOKIT_SUBDIR=""
fi

 if test "x$enable_iokit" = xyes; then
  BUILD_LUSTREIOKIT_TRUE=
  BUILD_LUSTREIOKIT_FALSE='#'
else
  BUILD_LUSTREIOKIT_TRUE='#'
  BUILD_LUSTREIOKIT_FALSE=
fi





# Check whether --with-ldiskfsprogs was given.
if test "${with_ldiskfsprogs+set}" = set; then
  withval=$with_ldiskfsprogs;
else
  withval='no'
fi


{ $as_echo "$as_me:$LINENO: checking whether to use alternate names for e2fsprogs" >&5
$as_echo_n "checking whether to use alternate names for e2fsprogs... " >&6; }
if test x$withval = xyes ; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_LDISKFSPROGS 1
_ACEOF

	E2FSPROGS="ldiskfsprogs"
	MKE2FS="mkfs.ldiskfs"
	DEBUGFS="debugfs.ldiskfs"
	TUNE2FS="tunefs.ldiskfs"
	E2LABEL="label.ldiskfs"
	DUMPE2FS="dumpfs.ldiskfs"
	E2FSCK="fsck.ldiskfs"
	PFSCK="pfsck.ldiskfs"
	{ $as_echo "$as_me:$LINENO: result: enabled" >&5
$as_echo "enabled" >&6; }
else
	E2FSPROGS="e2fsprogs"
	MKE2FS="mke2fs"
	DEBUGFS="debugfs"
	TUNE2FS="tune2fs"
	E2LABEL="e2label"
	DUMPE2FS="dumpe2fs"
	E2FSCK="e2fsck"
	PFSCK="fsck"
	{ $as_echo "$as_me:$LINENO: result: disabled" >&5
$as_echo "disabled" >&6; }
fi


cat >>confdefs.h <<_ACEOF
#define E2FSPROGS "$E2FSPROGS"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define MKE2FS "$MKE2FS"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define DEBUGFS "$DEBUGFS"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define TUNE2FS "$TUNE2FS"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define E2LABEL "$E2LABEL"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define DUMPE2FS "$DUMPE2FS"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define E2FSCK "$E2FSCK"
_ACEOF


cat >>confdefs.h <<_ACEOF
#define PFSCK "$PFSCK"
_ACEOF


E2FSPROGS=$E2FSPROGS

MKE2FS=$MKE2FS

DEBUGFS=$DEBUGFS

TUNE2FS=$TUNE2FS

E2LABEL=$E2LABEL

DUMPE2FS=$DUMPE2FS

E2FSCK=$E2FSCK

PFSCK=$PFSCK



{ $as_echo "$as_me:$LINENO: checking whether to build Lustre library" >&5
$as_echo_n "checking whether to build Lustre library... " >&6; }
# Check whether --enable-liblustre was given.
if test "${enable_liblustre+set}" = set; then
  enableval=$enable_liblustre;
else
  enable_liblustre=$with_sysio
fi

{ $as_echo "$as_me:$LINENO: result: $enable_liblustre" >&5
$as_echo "$enable_liblustre" >&6; }
# only build sysio if liblustre is built
with_sysio="$enable_liblustre"

{ $as_echo "$as_me:$LINENO: checking whether to build liblustre tests" >&5
$as_echo_n "checking whether to build liblustre tests... " >&6; }
# Check whether --enable-liblustre-tests was given.
if test "${enable_liblustre_tests+set}" = set; then
  enableval=$enable_liblustre_tests;
else
  enable_liblustre_tests=$enable_tests
fi

if test x$enable_liblustre != xyes ; then
   enable_liblustre_tests='no'
fi
{ $as_echo "$as_me:$LINENO: result: $enable_liblustre_tests" >&5
$as_echo "$enable_liblustre_tests" >&6; }

{ $as_echo "$as_me:$LINENO: checking whether to enable liblustre acl" >&5
$as_echo_n "checking whether to enable liblustre acl... " >&6; }
# Check whether --enable-liblustre-acl was given.
if test "${enable_liblustre_acl+set}" = set; then
  enableval=$enable_liblustre_acl;
else
  enable_liblustre_acl=yes
fi

{ $as_echo "$as_me:$LINENO: result: $enable_liblustre_acl" >&5
$as_echo "$enable_liblustre_acl" >&6; }
if test x$enable_liblustre_acl = xyes ; then

cat >>confdefs.h <<\_ACEOF
#define LIBLUSTRE_POSIX_ACL 1
_ACEOF

fi

#
# --enable-mpitest
#
# Check whether --enable-mpitests was given.
if test "${enable_mpitests+set}" = set; then
  enableval=$enable_mpitests;
	 enable_mpitests=yes
         case $enableval in
         yes)
		MPICC_WRAPPER=mpicc
		;;
         no)
		enable_mpitests=no
		;;
         *)
		MPICC_WRAPPER=$enableval
                 ;;
	 esac

else

	MPICC_WRAPPER=mpicc
	enable_mpitests=yes


fi


if test x$enable_mpitests != xno; then
	{ $as_echo "$as_me:$LINENO: checking whether mpitests can be built" >&5
$as_echo_n "checking whether mpitests can be built... " >&6; }
	oldcc=$CC
	CC=$MPICC_WRAPPER
	cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

		    #include <mpi.h>

int
main ()
{

		    int flag;
		    MPI_Initialized(&flag);

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then

		    { $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


		    { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		    enable_mpitests=no

fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
	CC=$oldcc
fi


{ $as_echo "$as_me:$LINENO: Enabling Lustre configure options for libsysio" >&5
$as_echo "$as_me: Enabling Lustre configure options for libsysio" >&6;}
ac_configure_args="$ac_configure_args --with-lustre-hack --with-sockets"

{ $as_echo "$as_me:$LINENO: checking whether to enable pinger support" >&5
$as_echo_n "checking whether to enable pinger support... " >&6; }
# Check whether --enable-pinger was given.
if test "${enable_pinger+set}" = set; then
  enableval=$enable_pinger;
else
  enable_pinger='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_pinger" >&5
$as_echo "$enable_pinger" >&6; }
if test x$enable_pinger != xno ; then

cat >>confdefs.h <<\_ACEOF
#define ENABLE_PINGER 1
_ACEOF

fi

{ $as_echo "$as_me:$LINENO: checking whether to enable liblustre recovery support" >&5
$as_echo_n "checking whether to enable liblustre recovery support... " >&6; }
# Check whether --enable-liblustre-recovery was given.
if test "${enable_liblustre_recovery+set}" = set; then
  enableval=$enable_liblustre_recovery;
else
  enable_liblustre_recovery='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_liblustre_recovery" >&5
$as_echo "$enable_liblustre_recovery" >&6; }
if test x$enable_liblustre_recovery != xno ; then

cat >>confdefs.h <<\_ACEOF
#define ENABLE_LIBLUSTRE_RECOVERY 1
_ACEOF

fi


# lnet/utils/portals.c



for ac_header in asm/types.h endian.h sys/ioctl.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
$as_echo_n "checking $ac_header usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
$as_echo_n "checking $ac_header presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <$ac_header>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  eval "$as_ac_Header=\$ac_header_preproc"
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }

fi
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF

fi

done


# lnet/utils/debug.c

for ac_header in linux/version.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
$as_echo_n "checking $ac_header usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
$as_echo_n "checking $ac_header presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <$ac_header>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  eval "$as_ac_Header=\$ac_header_preproc"
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }

fi
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF

fi

done


{ $as_echo "$as_me:$LINENO: checking for spinlock_t" >&5
$as_echo_n "checking for spinlock_t... " >&6; }
if test "${ac_cv_type_spinlock_t+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_type_spinlock_t=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <linux/spinlock.h>

int
main ()
{
if (sizeof (spinlock_t))
       return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <linux/spinlock.h>

int
main ()
{
if (sizeof ((spinlock_t)))
	  return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_type_spinlock_t=yes
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_spinlock_t" >&5
$as_echo "$ac_cv_type_spinlock_t" >&6; }
if test "x$ac_cv_type_spinlock_t" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_SPINLOCK_T 1
_ACEOF

fi


# lnet/utils/wirecheck.c

for ac_func in strnlen
do
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
$as_echo_n "checking for $ac_func... " >&6; }
if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
#define $ac_func innocuous_$ac_func

/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.
    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
    <limits.h> exists even on freestanding compilers.  */

#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif

#undef $ac_func

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char $ac_func ();
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined __stub_$ac_func || defined __stub___$ac_func
choke me
#endif

int
main ()
{
return $ac_func ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_var=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_var=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
fi
ac_res=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF

fi
done


# lnet/libcfs/user-prim.c, missing for RHEL5 and earlier userspace

for ac_func in strlcpy
do
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
$as_echo_n "checking for $ac_func... " >&6; }
if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
#define $ac_func innocuous_$ac_func

/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.
    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
    <limits.h> exists even on freestanding compilers.  */

#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif

#undef $ac_func

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char $ac_func ();
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined __stub_$ac_func || defined __stub___$ac_func
choke me
#endif

int
main ()
{
return $ac_func ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_var=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_var=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
fi
ac_res=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF

fi
done


# libcfs/libcfs/user-prim.c, missing for RHEL5 and earlier userspace

for ac_func in strlcat
do
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
$as_echo_n "checking for $ac_func... " >&6; }
if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
#define $ac_func innocuous_$ac_func

/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.
    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
    <limits.h> exists even on freestanding compilers.  */

#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif

#undef $ac_func

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char $ac_func ();
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined __stub_$ac_func || defined __stub___$ac_func
choke me
#endif

int
main ()
{
return $ac_func ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_var=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_var=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
fi
ac_res=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF

fi
done


{ $as_echo "$as_me:$LINENO: checking for umode_t" >&5
$as_echo_n "checking for umode_t... " >&6; }
if test "${ac_cv_type_umode_t+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_type_umode_t=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof (umode_t))
       return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof ((umode_t)))
	  return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_type_umode_t=yes
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_type_umode_t" >&5
$as_echo "$ac_cv_type_umode_t" >&6; }
if test "x$ac_cv_type_umode_t" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_UMODE_T 1
_ACEOF

fi


{ $as_echo "$as_me:$LINENO: checking for __s8" >&5
$as_echo_n "checking for __s8... " >&6; }
if test "${ac_cv_type___s8+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_type___s8=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof (__s8))
       return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof ((__s8)))
	  return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_type___s8=yes
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_type___s8" >&5
$as_echo "$ac_cv_type___s8" >&6; }
if test "x$ac_cv_type___s8" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE___S8 1
_ACEOF

fi


{ $as_echo "$as_me:$LINENO: checking for __u8" >&5
$as_echo_n "checking for __u8... " >&6; }
if test "${ac_cv_type___u8+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_type___u8=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof (__u8))
       return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof ((__u8)))
	  return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_type___u8=yes
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_type___u8" >&5
$as_echo "$ac_cv_type___u8" >&6; }
if test "x$ac_cv_type___u8" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE___U8 1
_ACEOF

fi


{ $as_echo "$as_me:$LINENO: checking for __s16" >&5
$as_echo_n "checking for __s16... " >&6; }
if test "${ac_cv_type___s16+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_type___s16=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof (__s16))
       return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof ((__s16)))
	  return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_type___s16=yes
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_type___s16" >&5
$as_echo "$ac_cv_type___s16" >&6; }
if test "x$ac_cv_type___s16" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE___S16 1
_ACEOF

fi


{ $as_echo "$as_me:$LINENO: checking for __u16" >&5
$as_echo_n "checking for __u16... " >&6; }
if test "${ac_cv_type___u16+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_type___u16=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof (__u16))
       return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof ((__u16)))
	  return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_type___u16=yes
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_type___u16" >&5
$as_echo "$ac_cv_type___u16" >&6; }
if test "x$ac_cv_type___u16" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE___U16 1
_ACEOF

fi


{ $as_echo "$as_me:$LINENO: checking for __s32" >&5
$as_echo_n "checking for __s32... " >&6; }
if test "${ac_cv_type___s32+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_type___s32=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof (__s32))
       return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof ((__s32)))
	  return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_type___s32=yes
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_type___s32" >&5
$as_echo "$ac_cv_type___s32" >&6; }
if test "x$ac_cv_type___s32" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE___S32 1
_ACEOF

fi


{ $as_echo "$as_me:$LINENO: checking for __u32" >&5
$as_echo_n "checking for __u32... " >&6; }
if test "${ac_cv_type___u32+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_type___u32=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof (__u32))
       return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof ((__u32)))
	  return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_type___u32=yes
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_type___u32" >&5
$as_echo "$ac_cv_type___u32" >&6; }
if test "x$ac_cv_type___u32" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE___U32 1
_ACEOF

fi


{ $as_echo "$as_me:$LINENO: checking for __u64" >&5
$as_echo_n "checking for __u64... " >&6; }
if test "${ac_cv_type___u64+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_type___u64=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof (__u64))
       return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof ((__u64)))
	  return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_type___u64=yes
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_type___u64" >&5
$as_echo "$ac_cv_type___u64" >&6; }
if test "x$ac_cv_type___u64" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE___U64 1
_ACEOF

fi


{ $as_echo "$as_me:$LINENO: checking for __s64" >&5
$as_echo_n "checking for __s64... " >&6; }
if test "${ac_cv_type___s64+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_type___s64=no
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof (__s64))
       return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <asm/types.h>

int
main ()
{
if (sizeof ((__s64)))
	  return 0;
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  :
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_type___s64=yes
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_type___s64" >&5
$as_echo "$ac_cv_type___s64" >&6; }
if test "x$ac_cv_type___s64" = x""yes; then

cat >>confdefs.h <<\_ACEOF
#define HAVE___S64 1
_ACEOF

fi


# check userland __u64 type
{ $as_echo "$as_me:$LINENO: checking userspace __u64 is long long type" >&5
$as_echo_n "checking userspace __u64 is long long type... " >&6; }
tmp_flags="$CFLAGS"
CFLAGS="$CFLAGS -Werror"
cat >conftest.$ac_ext <<_ACEOF

	#include <stdio.h>
	#include <linux/types.h>
	#include <linux/stddef.h>
	int main(void) {
		unsigned long long *data1;
		__u64 *data2 = NULL;

		data1 = data2;
		data2 = data1;
		return 0;
	}

_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_USER__U64_LONG_LONG 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
CFLAGS="$tmp_flags"

# --------  Check for required packages  --------------


{ $as_echo "$as_me:$LINENO: checking if efence debugging support is requested" >&5
$as_echo_n "checking if efence debugging support is requested... " >&6; }
# Check whether --enable-efence was given.
if test "${enable_efence+set}" = set; then
  enableval=$enable_efence;
else
  enable_efence='no'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_efence" >&5
$as_echo "$enable_efence" >&6; }
if test "$enable_efence" = "yes" ; then
	LIBEFENCE="-lefence"

cat >>confdefs.h <<\_ACEOF
#define HAVE_LIBEFENCE 1
_ACEOF

else
	LIBEFENCE=""
fi



# -------- check for -lpthread support ----
{ $as_echo "$as_me:$LINENO: checking whether to use libpthread for libcfs library" >&5
$as_echo_n "checking whether to use libpthread for libcfs library... " >&6; }
# Check whether --enable-libpthread was given.
if test "${enable_libpthread+set}" = set; then
  enableval=$enable_libpthread;
else
  enable_libpthread=yes
fi

if test "$enable_libpthread" = "yes" ; then
	{ $as_echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5
$as_echo_n "checking for pthread_create in -lpthread... " >&6; }
if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lpthread  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char pthread_create ();
int
main ()
{
return pthread_create ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  ac_cv_lib_pthread_pthread_create=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_lib_pthread_pthread_create=no
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5
$as_echo "$ac_cv_lib_pthread_pthread_create" >&6; }
if test "x$ac_cv_lib_pthread_pthread_create" = x""yes; then
  ENABLE_LIBPTHREAD="yes"
else
  ENABLE_LIBPTHREAD="no"
fi

	if test "$ENABLE_LIBPTHREAD" = "yes" ; then
		{ $as_echo "$as_me:$LINENO: result: $ENABLE_LIBPTHREAD" >&5
$as_echo "$ENABLE_LIBPTHREAD" >&6; }
		PTHREAD_LIBS="-lpthread"

cat >>confdefs.h <<\_ACEOF
#define HAVE_LIBPTHREAD 1
_ACEOF

	else
		PTHREAD_LIBS=""
		{ $as_echo "$as_me:$LINENO: result: no libpthread is found" >&5
$as_echo "no libpthread is found" >&6; }
	fi

else
	{ $as_echo "$as_me:$LINENO: result: no (disabled explicitly)" >&5
$as_echo "no (disabled explicitly)" >&6; }
	ENABLE_LIBPTHREAD="no"
fi




# lnet/utils/portals.c





for ac_header in netdb.h netinet/tcp.h asm/types.h endian.h sys/ioctl.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
$as_echo_n "checking $ac_header usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
$as_echo_n "checking $ac_header presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <$ac_header>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  eval "$as_ac_Header=\$ac_header_preproc"
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }

fi
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF

fi

done




for ac_func in gethostbyname socket connect
do
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
$as_echo_n "checking for $ac_func... " >&6; }
if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
#define $ac_func innocuous_$ac_func

/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.
    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
    <limits.h> exists even on freestanding compilers.  */

#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif

#undef $ac_func

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char $ac_func ();
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined __stub_$ac_func || defined __stub___$ac_func
choke me
#endif

int
main ()
{
return $ac_func ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_var=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_var=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
fi
ac_res=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF

fi
done


# lnet/utils/debug.c

for ac_header in linux/version.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
$as_echo_n "checking $ac_header usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
$as_echo_n "checking $ac_header presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <$ac_header>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  eval "$as_ac_Header=\$ac_header_preproc"
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }

fi
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF

fi

done


# lnet/utils/wirecheck.c

for ac_func in strnlen
do
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
$as_echo_n "checking for $ac_func... " >&6; }
if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
#define $ac_func innocuous_$ac_func

/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.
    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
    <limits.h> exists even on freestanding compilers.  */

#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif

#undef $ac_func

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char $ac_func ();
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined __stub_$ac_func || defined __stub___$ac_func
choke me
#endif

int
main ()
{
return $ac_func ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_var=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_var=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
fi
ac_res=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF

fi
done


# --------  Check for required packages  --------------

#
# LC_CONFIG_READLINE
#
# Build with readline
#
{ $as_echo "$as_me:$LINENO: checking whether to enable readline support" >&5
$as_echo_n "checking whether to enable readline support... " >&6; }
# Check whether --enable-readline was given.
if test "${enable_readline+set}" = set; then
  enableval=$enable_readline;
else
  enable_readline='yes'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_readline" >&5
$as_echo "$enable_readline" >&6; }

# -------- check for readline if enabled ----
if test x$enable_readline = xyes ; then
	LIBS_save="$LIBS"
	LIBS="-lncurses $LIBS"
	{ $as_echo "$as_me:$LINENO: checking for readline in -lreadline" >&5
$as_echo_n "checking for readline in -lreadline... " >&6; }
if test "${ac_cv_lib_readline_readline+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lreadline  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char readline ();
int
main ()
{
return readline ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  ac_cv_lib_readline_readline=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_lib_readline_readline=no
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_readline_readline" >&5
$as_echo "$ac_cv_lib_readline_readline" >&6; }
if test "x$ac_cv_lib_readline_readline" = x""yes; then

	LIBREADLINE="-lreadline -lncurses"

cat >>confdefs.h <<\_ACEOF
#define HAVE_LIBREADLINE 1
_ACEOF


else

	LIBREADLINE=""

fi

	LIBS="$LIBS_save"
else
	LIBREADLINE=""
fi


# -------- enable acceptor libwrap (TCP wrappers) support? -------
{ $as_echo "$as_me:$LINENO: checking if libwrap support is requested" >&5
$as_echo_n "checking if libwrap support is requested... " >&6; }
# Check whether --enable-libwrap was given.
if test "${enable_libwrap+set}" = set; then
  enableval=$enable_libwrap; case "${enableval}" in
		yes) enable_libwrap=yes ;;
		no) enable_libwrap=no ;;
		*) { { $as_echo "$as_me:$LINENO: error: bad value ${enableval} for --enable-libwrap" >&5
$as_echo "$as_me: error: bad value ${enableval} for --enable-libwrap" >&2;}
   { (exit 1); exit 1; }; } ;;
	esac
else
  enable_libwrap=no
fi

{ $as_echo "$as_me:$LINENO: result: $enable_libwrap" >&5
$as_echo "$enable_libwrap" >&6; }
if test x$enable_libwrap = xyes ; then
	LIBWRAP="-lwrap"

cat >>confdefs.h <<\_ACEOF
#define HAVE_LIBWRAP 1
_ACEOF

else
	LIBWRAP=""
fi


# ----------------------------------------
# some tests for catamount-like systems
# ----------------------------------------
# Check whether --enable-sysio_init was given.
if test "${enable_sysio_init+set}" = set; then
  enableval=$enable_sysio_init;
else
  enable_sysio_init=yes
fi

{ $as_echo "$as_me:$LINENO: checking whether to initialize libsysio" >&5
$as_echo_n "checking whether to initialize libsysio... " >&6; }
{ $as_echo "$as_me:$LINENO: result: $enable_sysio_init" >&5
$as_echo "$enable_sysio_init" >&6; }
if test x$enable_sysio_init != xno ; then

cat >>confdefs.h <<\_ACEOF
#define INIT_SYSIO 1
_ACEOF

fi

# Check whether --enable-urandom was given.
if test "${enable_urandom+set}" = set; then
  enableval=$enable_urandom;
else
  enable_urandom=yes
fi

{ $as_echo "$as_me:$LINENO: checking whether to use /dev/urandom for liblustre" >&5
$as_echo_n "checking whether to use /dev/urandom for liblustre... " >&6; }
{ $as_echo "$as_me:$LINENO: result: $enable_urandom" >&5
$as_echo "$enable_urandom" >&6; }
if test x$enable_urandom != xno ; then

cat >>confdefs.h <<\_ACEOF
#define LIBLUSTRE_USE_URANDOM 1
_ACEOF

fi

# -------- check for -lcap support ----
if test x$enable_liblustre = xyes ; then
	{ $as_echo "$as_me:$LINENO: checking for cap_get_proc in -lcap" >&5
$as_echo_n "checking for cap_get_proc in -lcap... " >&6; }
if test "${ac_cv_lib_cap_cap_get_proc+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lcap  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char cap_get_proc ();
int
main ()
{
return cap_get_proc ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  ac_cv_lib_cap_cap_get_proc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_lib_cap_cap_get_proc=no
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_cap_cap_get_proc" >&5
$as_echo "$ac_cv_lib_cap_cap_get_proc" >&6; }
if test "x$ac_cv_lib_cap_cap_get_proc" = x""yes; then

			CAP_LIBS="-lcap"

cat >>confdefs.h <<\_ACEOF
#define HAVE_LIBCAP 1
_ACEOF


else

			CAP_LIBS=""

fi



fi

{ $as_echo "$as_me:$LINENO: checking for non-default maximum LNET payload" >&5
$as_echo_n "checking for non-default maximum LNET payload... " >&6; }

# Check whether --with-max-payload-mb was given.
if test "${with_max_payload_mb+set}" = set; then
  withval=$with_max_payload_mb;
		{ $as_echo "$as_me:$LINENO: result: $with_max_payload_mb" >&5
$as_echo "$with_max_payload_mb" >&6; }
		CONFIG_LNET_MAX_PAYLOAD_MB=$with_max_payload_mb
		CONFIG_LNET_MAX_PAYLOAD="(($with_max_payload_mb)<<20)"

else

		{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
		CONFIG_LNET_MAX_PAYLOAD="LNET_MTU"

fi


cat >>confdefs.h <<_ACEOF
#define CONFIG_LNET_MAX_PAYLOAD $CONFIG_LNET_MAX_PAYLOAD
_ACEOF



if test -z "$ENABLEPORTALS"; then
	{ $as_echo "$as_me:$LINENO: checking for portals" >&5
$as_echo_n "checking for portals... " >&6; }

# Check whether --with-portals was given.
if test "${with_portals+set}" = set; then
  withval=$with_portals;
		case $with_portals in
			no)     ENABLEPORTALS=0
				;;
			*)	PORTALS="${with_portals}"
				ENABLEPORTALS=1
				;;
		esac

else

		ENABLEPORTALS=0

fi

PTLLNDCPPFLAGS=""
if test $ENABLEPORTALS -eq 0; then
	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
elif test ! \( -f ${PORTALS}/include/portals/p30.h \); then
	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
	{ { $as_echo "$as_me:$LINENO: error: bad --with-portals path" >&5
$as_echo "$as_me: error: bad --with-portals path" >&2;}
   { (exit 1); exit 1; }; }
else
	PORTALS=$(readlink --canonicalize $PORTALS)
	{ $as_echo "$as_me:$LINENO: result: $PORTALS" >&5
$as_echo "$PORTALS" >&6; }
	PTLLNDCPPFLAGS="-I${PORTALS}/include"
fi


fi

{ $as_echo "$as_me:$LINENO: checking whether to build the userspace portals LND" >&5
$as_echo_n "checking whether to build the userspace portals LND... " >&6; }

UPTLLND=""
if test $ENABLEPORTALS -ne 0; then
	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
	UPTLLND="ptllnd"
else
	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


{ $as_echo "$as_me:$LINENO: checking whether to build usocklnd" >&5
$as_echo_n "checking whether to build usocklnd... " >&6; }
# Check whether --enable-usocklnd was given.
if test "${enable_usocklnd+set}" = set; then
  enableval=$enable_usocklnd;
else
  enable_usocklnd='yes'
fi


if test x$enable_usocklnd = xyes ; then
	if test "$ENABLE_LIBPTHREAD" = "yes" ; then
		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
      		USOCKLND="usocklnd"
	else
		{ $as_echo "$as_me:$LINENO: result: no (libpthread not present or disabled)" >&5
$as_echo "no (libpthread not present or disabled)" >&6; }
		USOCKLND=""
	fi
else
	{ $as_echo "$as_me:$LINENO: result: no (disabled explicitly)" >&5
$as_echo "no (disabled explicitly)" >&6; }
     	USOCKLND=""
fi




{ $as_echo "$as_me:$LINENO: checking maximum OBD ioctl size" >&5
$as_echo_n "checking maximum OBD ioctl size... " >&6; }

# Check whether --with-obd-buffer-size was given.
if test "${with_obd_buffer_size+set}" = set; then
  withval=$with_obd_buffer_size;
		OBD_BUFFER_SIZE=$with_obd_buffer_size

else

		OBD_BUFFER_SIZE=8192

fi

{ $as_echo "$as_me:$LINENO: result: $OBD_BUFFER_SIZE bytes" >&5
$as_echo "$OBD_BUFFER_SIZE bytes" >&6; }

cat >>confdefs.h <<_ACEOF
#define CONFIG_LUSTRE_OBD_MAX_IOCTL_BUFFER $OBD_BUFFER_SIZE
_ACEOF



if test $target_cpu == "i686" -o $target_cpu == "x86_64"; then
        CFLAGS="$CFLAGS -Werror"
fi

# maximum MDS thread count


# Check whether --with-mds_max_threads was given.
if test "${with_mds_max_threads+set}" = set; then
  withval=$with_mds_max_threads;
		MDS_THREAD_COUNT=$with_mds_max_threads

cat >>confdefs.h <<_ACEOF
#define MDS_MAX_THREADS $MDS_THREAD_COUNT
_ACEOF


fi



# include/liblustre.h




for ac_header in sys/user.h sys/vfs.h stdint.h blkid/blkid.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
$as_echo_n "checking $ac_header usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
$as_echo_n "checking $ac_header presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <$ac_header>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  eval "$as_ac_Header=\$ac_header_preproc"
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }

fi
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF

fi

done


# liblustre/llite_lib.h


for ac_header in xtio.h file.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
$as_echo_n "checking $ac_header usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
$as_echo_n "checking $ac_header presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <$ac_header>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  eval "$as_ac_Header=\$ac_header_preproc"
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }

fi
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF

fi

done


# liblustre/dir.c




for ac_header in linux/types.h sys/types.h linux/unistd.h unistd.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
$as_echo_n "checking $ac_header usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
$as_echo_n "checking $ac_header presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <$ac_header>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  eval "$as_ac_Header=\$ac_header_preproc"
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }

fi
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF

fi

done


# liblustre/lutil.c



for ac_header in netinet/in.h arpa/inet.h catamount/data.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
$as_echo_n "checking $ac_header usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
$as_echo_n "checking $ac_header presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <$ac_header>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  eval "$as_ac_Header=\$ac_header_preproc"
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }

fi
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF

fi

done


for ac_func in inet_ntoa
do
as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
$as_echo_n "checking for $ac_func... " >&6; }
if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
#define $ac_func innocuous_$ac_func

/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char $ac_func (); below.
    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
    <limits.h> exists even on freestanding compilers.  */

#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif

#undef $ac_func

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char $ac_func ();
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined __stub_$ac_func || defined __stub___$ac_func
choke me
#endif

int
main ()
{
return $ac_func ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  eval "$as_ac_var=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_var=no"
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
fi
ac_res=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_var'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
_ACEOF

fi
done


# libsysio/src/readlink.c
{ $as_echo "$as_me:$LINENO: checking if readlink returns ssize_t" >&5
$as_echo_n "checking if readlink returns ssize_t... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

	#include <unistd.h>

int
main ()
{

	ssize_t readlink(const char *, char *, size_t);

  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then

	{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }

cat >>confdefs.h <<\_ACEOF
#define HAVE_POSIX_1003_READLINK 1
_ACEOF


else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5


	{ $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }

fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext


# lvfs/prng.c - depends on linux/types.h from liblustre/dir.c

for ac_header in linux/random.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#ifdef HAVE_LINUX_TYPES_H
                  # include <linux/types.h>
                  #endif


#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  eval "$as_ac_Header=yes"
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	eval "$as_ac_Header=no"
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF

fi

done


# utils/llverfs.c

for ac_header in ext2fs/ext2fs.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
$as_echo_n "checking $ac_header usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
$as_echo_n "checking $ac_header presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <$ac_header>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  eval "$as_ac_Header=\$ac_header_preproc"
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }

fi
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF

fi

done


# check for -lz support
ZLIB=""
{ $as_echo "$as_me:$LINENO: checking for adler32 in -lz" >&5
$as_echo_n "checking for adler32 in -lz... " >&6; }
if test "${ac_cv_lib_z_adler32+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lz  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char adler32 ();
int
main ()
{
return adler32 ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  ac_cv_lib_z_adler32=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_lib_z_adler32=no
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_adler32" >&5
$as_echo "$ac_cv_lib_z_adler32" >&6; }
if test "x$ac_cv_lib_z_adler32" = x""yes; then

for ac_header in zlib.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
$as_echo_n "checking $ac_header usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
$as_echo_n "checking $ac_header presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <$ac_header>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  eval "$as_ac_Header=\$ac_header_preproc"
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }

fi
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
 ZLIB="-lz"

cat >>confdefs.h <<\_ACEOF
#define HAVE_ADLER 1
_ACEOF

else
  { $as_echo "$as_me:$LINENO: WARNING: No zlib-devel package found,
                                             unable to use adler32 checksum" >&5
$as_echo "$as_me: WARNING: No zlib-devel package found,
                                             unable to use adler32 checksum" >&2;}
fi

done

else
  { $as_echo "$as_me:$LINENO: WARNING: No zlib package found, unable to use adler32 checksum" >&5
$as_echo "$as_me: WARNING: No zlib package found, unable to use adler32 checksum" >&2;}

fi



SELINUX=""
{ $as_echo "$as_me:$LINENO: checking for is_selinux_enabled in -lselinux" >&5
$as_echo_n "checking for is_selinux_enabled in -lselinux... " >&6; }
if test "${ac_cv_lib_selinux_is_selinux_enabled+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lselinux  $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char is_selinux_enabled ();
int
main ()
{
return is_selinux_enabled ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  ac_cv_lib_selinux_is_selinux_enabled=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_lib_selinux_is_selinux_enabled=no
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_lib_selinux_is_selinux_enabled" >&5
$as_echo "$ac_cv_lib_selinux_is_selinux_enabled" >&6; }
if test "x$ac_cv_lib_selinux_is_selinux_enabled" = x""yes; then

for ac_header in selinux.h
do
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
$as_echo_n "checking $ac_header usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <$ac_header>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
$as_echo_n "checking $ac_header presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <$ac_header>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
$as_echo_n "checking for $ac_header... " >&6; }
if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
  $as_echo_n "(cached) " >&6
else
  eval "$as_ac_Header=\$ac_header_preproc"
fi
ac_res=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
	       { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
$as_echo "$ac_res" >&6; }

fi
as_val=`eval 'as_val=${'$as_ac_Header'}
		 $as_echo "$as_val"'`
   if test "x$as_val" = x""yes; then
  cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
 SELINUX="-lselinux"

cat >>confdefs.h <<\_ACEOF
#define HAVE_SELINUX 1
_ACEOF

else
  { $as_echo "$as_me:$LINENO: WARNING: No selinux-devel package found,
						unable to build selinux enabled
						tools" >&5
$as_echo "$as_me: WARNING: No selinux-devel package found,
						unable to build selinux enabled
						tools" >&2;}
fi

done

else
  { $as_echo "$as_me:$LINENO: WARNING: No selinux package found, unable to build selinux
				enabled tools" >&5
$as_echo "$as_me: WARNING: No selinux package found, unable to build selinux
				enabled tools" >&2;}

fi



# Super safe df
# Check whether --enable-mindf was given.
if test "${enable_mindf+set}" = set; then
  enableval=$enable_mindf;
fi

if test "$enable_mindf" = "yes" ;  then

cat >>confdefs.h <<\_ACEOF
#define MIN_DF 1
_ACEOF

fi

# Check whether --enable-fail_alloc was given.
if test "${enable_fail_alloc+set}" = set; then
  enableval=$enable_fail_alloc;
else
  enable_fail_alloc=yes
fi

{ $as_echo "$as_me:$LINENO: checking whether to randomly failing memory alloc" >&5
$as_echo_n "checking whether to randomly failing memory alloc... " >&6; }
{ $as_echo "$as_me:$LINENO: result: $enable_fail_alloc" >&5
$as_echo "$enable_fail_alloc" >&6; }
if test x$enable_fail_alloc != xno ; then

cat >>confdefs.h <<\_ACEOF
#define RANDOM_FAIL_ALLOC 1
_ACEOF

fi

# Check whether --enable-invariants was given.
if test "${enable_invariants+set}" = set; then
  enableval=$enable_invariants;
fi

{ $as_echo "$as_me:$LINENO: checking whether to check invariants (expensive cpu-wise)" >&5
$as_echo_n "checking whether to check invariants (expensive cpu-wise)... " >&6; }
{ $as_echo "$as_me:$LINENO: result: $enable_invariants" >&5
$as_echo "$enable_invariants" >&6; }
if test x$enable_invariants = xyes ; then

cat >>confdefs.h <<\_ACEOF
#define CONFIG_LUSTRE_DEBUG_EXPENSIVE_CHECK 1
_ACEOF

fi

# Check whether --enable-lu_ref was given.
if test "${enable_lu_ref+set}" = set; then
  enableval=$enable_lu_ref;
fi

{ $as_echo "$as_me:$LINENO: checking whether to track references with lu_ref" >&5
$as_echo_n "checking whether to track references with lu_ref... " >&6; }
{ $as_echo "$as_me:$LINENO: result: $enable_lu_ref" >&5
$as_echo "$enable_lu_ref" >&6; }
if test x$enable_lu_ref = xyes ; then

cat >>confdefs.h <<\_ACEOF
#define USE_LU_REF 1
_ACEOF

fi

# Check whether --enable-pgstate-track was given.
if test "${enable_pgstate_track+set}" = set; then
  enableval=$enable_pgstate_track; enable_pgstat_track='yes'
fi

{ $as_echo "$as_me:$LINENO: checking whether to enable page state tracking" >&5
$as_echo_n "checking whether to enable page state tracking... " >&6; }
{ $as_echo "$as_me:$LINENO: result: $enable_pgstat_track" >&5
$as_echo "$enable_pgstat_track" >&6; }
if test x$enable_pgstat_track = xyes ; then

cat >>confdefs.h <<\_ACEOF
#define CONFIG_DEBUG_PAGESTATE_TRACKING 1
_ACEOF

fi


if test "$SNMP_DIST_SUBDIR" ; then
	{ $as_echo "$as_me:$LINENO: checking whether to try to build SNMP support" >&5
$as_echo_n "checking whether to try to build SNMP support... " >&6; }
# Check whether --enable-snmp was given.
if test "${enable_snmp+set}" = set; then
  enableval=$enable_snmp;
else
  enable_snmp='auto'
fi

{ $as_echo "$as_me:$LINENO: result: $enable_snmp" >&5
$as_echo "$enable_snmp" >&6; }

if test x$enable_snmp != xno ; then
	# Extract the first word of "net-snmp-config", so it can be a program name with args.
set dummy net-snmp-config; ac_word=$2
{ $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
if test "${ac_cv_prog_NET_SNMP_CONFIG+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  if test -n "$NET_SNMP_CONFIG"; then
  ac_cv_prog_NET_SNMP_CONFIG="$NET_SNMP_CONFIG" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  for ac_exec_ext in '' $ac_executable_extensions; do
  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
    ac_cv_prog_NET_SNMP_CONFIG="net-snmp-config"
    $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
    break 2
  fi
done
done
IFS=$as_save_IFS

fi
fi
NET_SNMP_CONFIG=$ac_cv_prog_NET_SNMP_CONFIG
if test -n "$NET_SNMP_CONFIG"; then
  { $as_echo "$as_me:$LINENO: result: $NET_SNMP_CONFIG" >&5
$as_echo "$NET_SNMP_CONFIG" >&6; }
else
  { $as_echo "$as_me:$LINENO: result: no" >&5
$as_echo "no" >&6; }
fi


	if test "$NET_SNMP_CONFIG" ; then
		NET_SNMP_CFLAGS=$($NET_SNMP_CONFIG --base-cflags)
		NET_SNMP_LIBS=$($NET_SNMP_CONFIG --agent-libs)

		CPPFLAGS_save="$CPPFLAGS"
		CPPFLAGS="$CPPFLAGS $NET_SNMP_CFLAGS"

		LIBS_save="$LIBS"
		LIBS="$LIBS $NET_SNMP_LIBS"

		if test "${ac_cv_header_net_snmp_net_snmp_config_h+set}" = set; then
  { $as_echo "$as_me:$LINENO: checking for net-snmp/net-snmp-config.h" >&5
$as_echo_n "checking for net-snmp/net-snmp-config.h... " >&6; }
if test "${ac_cv_header_net_snmp_net_snmp_config_h+set}" = set; then
  $as_echo_n "(cached) " >&6
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_net_snmp_net_snmp_config_h" >&5
$as_echo "$ac_cv_header_net_snmp_net_snmp_config_h" >&6; }
else
  # Is the header compilable?
{ $as_echo "$as_me:$LINENO: checking net-snmp/net-snmp-config.h usability" >&5
$as_echo_n "checking net-snmp/net-snmp-config.h usability... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
$ac_includes_default
#include <net-snmp/net-snmp-config.h>
_ACEOF
rm -f conftest.$ac_objext
if { (ac_try="$ac_compile"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_compile") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest.$ac_objext; then
  ac_header_compiler=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_header_compiler=no
fi

rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
$as_echo "$ac_header_compiler" >&6; }

# Is the header present?
{ $as_echo "$as_me:$LINENO: checking net-snmp/net-snmp-config.h presence" >&5
$as_echo_n "checking net-snmp/net-snmp-config.h presence... " >&6; }
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
#include <net-snmp/net-snmp-config.h>
_ACEOF
if { (ac_try="$ac_cpp conftest.$ac_ext"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } >/dev/null && {
	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
	 test ! -s conftest.err
       }; then
  ac_header_preproc=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

  ac_header_preproc=no
fi

rm -f conftest.err conftest.$ac_ext
{ $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
$as_echo "$ac_header_preproc" >&6; }

# So?  What about this header?
case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
  yes:no: )
    { $as_echo "$as_me:$LINENO: WARNING: net-snmp/net-snmp-config.h: accepted by the compiler, rejected by the preprocessor!" >&5
$as_echo "$as_me: WARNING: net-snmp/net-snmp-config.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: net-snmp/net-snmp-config.h: proceeding with the compiler's result" >&5
$as_echo "$as_me: WARNING: net-snmp/net-snmp-config.h: proceeding with the compiler's result" >&2;}
    ac_header_preproc=yes
    ;;
  no:yes:* )
    { $as_echo "$as_me:$LINENO: WARNING: net-snmp/net-snmp-config.h: present but cannot be compiled" >&5
$as_echo "$as_me: WARNING: net-snmp/net-snmp-config.h: present but cannot be compiled" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: net-snmp/net-snmp-config.h:     check for missing prerequisite headers?" >&5
$as_echo "$as_me: WARNING: net-snmp/net-snmp-config.h:     check for missing prerequisite headers?" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: net-snmp/net-snmp-config.h: see the Autoconf documentation" >&5
$as_echo "$as_me: WARNING: net-snmp/net-snmp-config.h: see the Autoconf documentation" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: net-snmp/net-snmp-config.h:     section \"Present But Cannot Be Compiled\"" >&5
$as_echo "$as_me: WARNING: net-snmp/net-snmp-config.h:     section \"Present But Cannot Be Compiled\"" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: net-snmp/net-snmp-config.h: proceeding with the preprocessor's result" >&5
$as_echo "$as_me: WARNING: net-snmp/net-snmp-config.h: proceeding with the preprocessor's result" >&2;}
    { $as_echo "$as_me:$LINENO: WARNING: net-snmp/net-snmp-config.h: in the future, the compiler will take precedence" >&5
$as_echo "$as_me: WARNING: net-snmp/net-snmp-config.h: in the future, the compiler will take precedence" >&2;}
    ( cat <<\_ASBOX
## ----------------------------------------- ##
## Report this to http://bugs.whamcloud.com/ ##
## ----------------------------------------- ##
_ASBOX
     ) | sed "s/^/$as_me: WARNING:     /" >&2
    ;;
esac
{ $as_echo "$as_me:$LINENO: checking for net-snmp/net-snmp-config.h" >&5
$as_echo_n "checking for net-snmp/net-snmp-config.h... " >&6; }
if test "${ac_cv_header_net_snmp_net_snmp_config_h+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  ac_cv_header_net_snmp_net_snmp_config_h=$ac_header_preproc
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_header_net_snmp_net_snmp_config_h" >&5
$as_echo "$ac_cv_header_net_snmp_net_snmp_config_h" >&6; }

fi
if test "x$ac_cv_header_net_snmp_net_snmp_config_h" = x""yes; then

			{ $as_echo "$as_me:$LINENO: checking for register_mib" >&5
$as_echo_n "checking for register_mib... " >&6; }
if test "${ac_cv_func_register_mib+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
/* Define register_mib to an innocuous variant, in case <limits.h> declares register_mib.
   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
#define register_mib innocuous_register_mib

/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char register_mib (); below.
    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
    <limits.h> exists even on freestanding compilers.  */

#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif

#undef register_mib

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char register_mib ();
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined __stub_register_mib || defined __stub___register_mib
choke me
#endif

int
main ()
{
return register_mib ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  ac_cv_func_register_mib=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_func_register_mib=no
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_register_mib" >&5
$as_echo "$ac_cv_func_register_mib" >&6; }
if test "x$ac_cv_func_register_mib" = x""yes; then
  SNMP_SUBDIR="snmp"
else

				LIBS="$LIBS -lwrap"
				NET_SNMP_LISB="$NET_SNMP_LIBS -lwrap"
				# fail autoconf's cache
				unset ac_cv_func_register_mib
				{ $as_echo "$as_me:$LINENO: checking for register_mib" >&5
$as_echo_n "checking for register_mib... " >&6; }
if test "${ac_cv_func_register_mib+set}" = set; then
  $as_echo_n "(cached) " >&6
else
  cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */
/* Define register_mib to an innocuous variant, in case <limits.h> declares register_mib.
   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
#define register_mib innocuous_register_mib

/* System header to define __stub macros and hopefully few prototypes,
    which can conflict with char register_mib (); below.
    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
    <limits.h> exists even on freestanding compilers.  */

#ifdef __STDC__
# include <limits.h>
#else
# include <assert.h>
#endif

#undef register_mib

/* Override any GCC internal prototype to avoid an error.
   Use char because int might match the return type of a GCC
   builtin and then its argument prototype would still apply.  */
#ifdef __cplusplus
extern "C"
#endif
char register_mib ();
/* The GNU C library defines this for functions which it implements
    to always fail with ENOSYS.  Some functions are actually named
    something starting with __ and the normal name is an alias.  */
#if defined __stub_register_mib || defined __stub___register_mib
choke me
#endif

int
main ()
{
return register_mib ();
  ;
  return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (ac_try="$ac_link"
case "(($ac_try" in
  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
  *) ac_try_echo=$ac_try;;
esac
eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
$as_echo "$ac_try_echo") >&5
  (eval "$ac_link") 2>conftest.er1
  ac_status=$?
  grep -v '^ *+' conftest.er1 >conftest.err
  rm -f conftest.er1
  cat conftest.err >&5
  $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
  (exit $ac_status); } && {
	 test -z "$ac_c_werror_flag" ||
	 test ! -s conftest.err
       } && test -s conftest$ac_exeext && {
	 test "$cross_compiling" = yes ||
	 $as_test_x conftest$ac_exeext
       }; then
  ac_cv_func_register_mib=yes
else
  $as_echo "$as_me: failed program was:" >&5
sed 's/^/| /' conftest.$ac_ext >&5

	ac_cv_func_register_mib=no
fi

rm -rf conftest.dSYM
rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
      conftest$ac_exeext conftest.$ac_ext
fi
{ $as_echo "$as_me:$LINENO: result: $ac_cv_func_register_mib" >&5
$as_echo "$ac_cv_func_register_mib" >&6; }
if test "x$ac_cv_func_register_mib" = x""yes; then
  SNMP_SUBDIR="snmp"
fi


fi


fi



		LIBS="$LIBS_save"
		CPPFLAGS="$CPPFLAGS_save"
	fi
	{ $as_echo "$as_me:$LINENO: checking for SNMP support" >&5
$as_echo_n "checking for SNMP support... " >&6; }
	if test "$SNMP_SUBDIR" ; then
		{ $as_echo "$as_me:$LINENO: result: yes" >&5
$as_echo "yes" >&6; }
	else
		{ $as_echo "$as_me:$LINENO: result: no (see config.log for errors)" >&5
$as_echo "no (see config.log for errors)" >&6; }
		if test x$enable_snmp = xyes ; then
			{ { $as_echo "$as_me:$LINENO: error: SNMP support was requested, but unavailable" >&5
$as_echo "$as_me: error: SNMP support was requested, but unavailable" >&2;}
   { (exit 1); exit 1; }; }
		fi
	fi
fi

agentdir='${pkglibdir}/snmp'
mibdir='${pkgdatadir}/snmp/mibs'






fi


 if test x$enable_modules = xyes; then
  MODULES_TRUE=
  MODULES_FALSE='#'
else
  MODULES_TRUE='#'
  MODULES_FALSE=
fi

 if test x$enable_utils = xyes; then
  UTILS_TRUE=
  UTILS_FALSE='#'
else
  UTILS_TRUE='#'
  UTILS_FALSE=
fi

 if test x$enable_tests = xyes; then
  TESTS_TRUE=
  TESTS_FALSE='#'
else
  TESTS_TRUE='#'
  TESTS_FALSE=
fi

 if test x$ENABLE_DOC = x1; then
  DOC_TRUE=
  DOC_FALSE='#'
else
  DOC_TRUE='#'
  DOC_FALSE=
fi

 if test x$ENABLE_INIT_SCRIPTS = "x1"; then
  INIT_SCRIPTS_TRUE=
  INIT_SCRIPTS_FALSE='#'
else
  INIT_SCRIPTS_TRUE='#'
  INIT_SCRIPTS_FALSE=
fi

 if test x$lb_target_os = "xlinux"; then
  LINUX_TRUE=
  LINUX_FALSE='#'
else
  LINUX_TRUE='#'
  LINUX_FALSE=
fi

 if test x$lb_target_os = "xdarwin"; then
  DARWIN_TRUE=
  DARWIN_FALSE='#'
else
  DARWIN_TRUE='#'
  DARWIN_FALSE=
fi

 if test x$lb_target_os = "xSunOS"; then
  SUNOS_TRUE=
  SUNOS_FALSE='#'
else
  SUNOS_TRUE='#'
  SUNOS_FALSE=
fi

 if test x$uses_dpkg = "xyes"; then
  USES_DPKG_TRUE=
  USES_DPKG_FALSE='#'
else
  USES_DPKG_TRUE='#'
  USES_DPKG_FALSE=
fi

 if test x$use_quilt = xyes; then
  USE_QUILT_TRUE=
  USE_QUILT_FALSE='#'
else
  USE_QUILT_TRUE='#'
  USE_QUILT_FALSE=
fi


# Sanity check for PCLMULQDQ instruction availability
# PCLMULQDQ instruction is a new instruction available beginning with
# the all new Core processor family based on the 32nm microarchitecture
# codename Westmere. So, $target_cpu = x86_64 should have this instruction
# except MIC microarchitecture (k1om).
 if test x$target_cpu = "xx86_64" -a x$target_vendor != "xk1om"; then
  HAVE_PCLMULQDQ_TRUE=
  HAVE_PCLMULQDQ_FALSE='#'
else
  HAVE_PCLMULQDQ_TRUE='#'
  HAVE_PCLMULQDQ_FALSE=
fi

if test x$target_cpu = "xx86_64" -a x$target_vendor != "xk1om" ; then

cat >>confdefs.h <<\_ACEOF
#define HAVE_PCLMULQDQ 1
_ACEOF

fi

# this lets lustre cancel libsysio, per-branch or if liblustre is
# disabled
if test "x$LIBSYSIO_SUBDIR" = xlibsysio ; then
	if test "x$with_sysio" != xyes ; then
		SYSIO=""
		LIBSYSIO_SUBDIR=""
	fi
fi








 if test x$QSWLND = "xqswlnd"; then
  BUILD_QSWLND_TRUE=
  BUILD_QSWLND_FALSE='#'
else
  BUILD_QSWLND_TRUE='#'
  BUILD_QSWLND_FALSE=
fi

 if test x$MXLND = "xmxlnd"; then
  BUILD_MXLND_TRUE=
  BUILD_MXLND_FALSE='#'
else
  BUILD_MXLND_TRUE='#'
  BUILD_MXLND_FALSE=
fi

 if test x$O2IBLND = "xo2iblnd"; then
  BUILD_O2IBLND_TRUE=
  BUILD_O2IBLND_FALSE='#'
else
  BUILD_O2IBLND_TRUE='#'
  BUILD_O2IBLND_FALSE=
fi

 if test x$RALND = "xralnd"; then
  BUILD_RALND_TRUE=
  BUILD_RALND_FALSE='#'
else
  BUILD_RALND_TRUE='#'
  BUILD_RALND_FALSE=
fi

 if test x$GNILND = "xgnilnd"; then
  BUILD_GNILND_TRUE=
  BUILD_GNILND_FALSE='#'
else
  BUILD_GNILND_TRUE='#'
  BUILD_GNILND_FALSE=
fi

 if test x$GNILNDRCA = "xgnilndrca"; then
  BUILD_GNILND_RCA_TRUE=
  BUILD_GNILND_RCA_FALSE='#'
else
  BUILD_GNILND_RCA_TRUE='#'
  BUILD_GNILND_RCA_FALSE=
fi

 if test x$PTLLND = "xptllnd"; then
  BUILD_PTLLND_TRUE=
  BUILD_PTLLND_FALSE='#'
else
  BUILD_PTLLND_TRUE='#'
  BUILD_PTLLND_FALSE=
fi

 if test x$USOCKLND = "xusocklnd"; then
  BUILD_USOCKLND_TRUE=
  BUILD_USOCKLND_FALSE='#'
else
  BUILD_USOCKLND_TRUE='#'
  BUILD_USOCKLND_FALSE=
fi


 if test x$enable_liblustre = xyes; then
  LIBLUSTRE_TRUE=
  LIBLUSTRE_FALSE='#'
else
  LIBLUSTRE_TRUE='#'
  LIBLUSTRE_FALSE=
fi

 if test x$enable_liblustre_tests = xyes; then
  LIBLUSTRE_TESTS_TRUE=
  LIBLUSTRE_TESTS_FALSE='#'
else
  LIBLUSTRE_TESTS_TRUE='#'
  LIBLUSTRE_TESTS_FALSE=
fi

 if test x$enable_mpitests = xyes; then
  MPITESTS_TRUE=
  MPITESTS_FALSE='#'
else
  MPITESTS_TRUE='#'
  MPITESTS_FALSE=
fi

 if test x$enable_client = xyes; then
  CLIENT_TRUE=
  CLIENT_FALSE='#'
else
  CLIENT_TRUE='#'
  CLIENT_FALSE=
fi

 if test x$enable_server = xyes; then
  SERVER_TRUE=
  SERVER_FALSE='#'
else
  SERVER_TRUE='#'
  SERVER_FALSE=
fi

 if test x$enable_split = xyes; then
  SPLIT_TRUE=
  SPLIT_FALSE='#'
else
  SPLIT_TRUE='#'
  SPLIT_FALSE=
fi

 if test x$ac_cv_header_blkid_blkid_h = xyes; then
  BLKID_TRUE=
  BLKID_FALSE='#'
else
  BLKID_TRUE='#'
  BLKID_FALSE=
fi

 if test x$ac_cv_header_ext2fs_ext2fs_h = xyes; then
  EXT2FS_DEVEL_TRUE=
  EXT2FS_DEVEL_FALSE='#'
else
  EXT2FS_DEVEL_TRUE='#'
  EXT2FS_DEVEL_FALSE=
fi

 if test x$enable_gss = xyes; then
  GSS_TRUE=
  GSS_FALSE='#'
else
  GSS_TRUE='#'
  GSS_FALSE=
fi

 if test x$enable_gss_keyring = xyes; then
  GSS_KEYRING_TRUE=
  GSS_KEYRING_FALSE='#'
else
  GSS_KEYRING_TRUE='#'
  GSS_KEYRING_FALSE=
fi

 if test x$enable_gss_pipefs = xyes; then
  GSS_PIPEFS_TRUE=
  GSS_PIPEFS_FALSE='#'
else
  GSS_PIPEFS_TRUE='#'
  GSS_PIPEFS_FALSE=
fi

 if test x$enable_libpthread = xyes; then
  LIBPTHREAD_TRUE=
  LIBPTHREAD_FALSE='#'
else
  LIBPTHREAD_TRUE='#'
  LIBPTHREAD_FALSE=
fi

 if test x$enable_llite_lloop_module = xyes; then
  LLITE_LLOOP_TRUE=
  LLITE_LLOOP_FALSE='#'
else
  LLITE_LLOOP_TRUE='#'
  LLITE_LLOOP_FALSE=
fi




	ac_config_headers="$ac_config_headers config.h"

	CPPFLAGS="-include $PWD/config.h $CPPFLAGS"
	EXTRA_KCFLAGS="-include $PWD/config.h $EXTRA_KCFLAGS"



ac_config_files="$ac_config_files libcfs/Kernelenv libcfs/Makefile libcfs/autoMakefile libcfs/autoconf/Makefile libcfs/include/Makefile libcfs/include/libcfs/Makefile libcfs/include/libcfs/linux/Makefile libcfs/include/libcfs/posix/Makefile libcfs/include/libcfs/util/Makefile libcfs/libcfs/Makefile libcfs/libcfs/autoMakefile libcfs/libcfs/linux/Makefile libcfs/libcfs/posix/Makefile libcfs/libcfs/util/Makefile libcfs/include/libcfs/darwin/Makefile libcfs/libcfs/darwin/Makefile"



	ac_config_files="$ac_config_files Makefile autoMakefile config/Makefile Rules:build/Rules.in lustre.spec contrib/Makefile contrib/lbuild/Makefile contrib/scripts/Makefile ldiskfs/Makefile ldiskfs/autoMakefile lustre-iokit/Makefile lustre-iokit/obdfilter-survey/Makefile lustre-iokit/ost-survey/Makefile lustre-iokit/sgpdd-survey/Makefile lustre-iokit/mds-survey/Makefile lustre-iokit/ior-survey/Makefile lustre-iokit/stats-collect/Makefile"


ac_config_files="$ac_config_files lnet/Kernelenv lnet/Makefile lnet/autoMakefile lnet/autoconf/Makefile lnet/doc/Makefile lnet/include/Makefile lnet/include/lnet/Makefile lnet/include/lnet/linux/Makefile lnet/klnds/Makefile lnet/klnds/autoMakefile lnet/klnds/mxlnd/autoMakefile lnet/klnds/mxlnd/Makefile lnet/klnds/o2iblnd/Makefile lnet/klnds/o2iblnd/autoMakefile lnet/klnds/qswlnd/Makefile lnet/klnds/qswlnd/autoMakefile lnet/klnds/ralnd/Makefile lnet/klnds/ralnd/autoMakefile lnet/klnds/gnilnd/Makefile lnet/klnds/gnilnd/autoMakefile lnet/klnds/socklnd/Makefile lnet/klnds/socklnd/autoMakefile lnet/klnds/ptllnd/Makefile lnet/klnds/ptllnd/autoMakefile lnet/lnet/Makefile lnet/lnet/autoMakefile lnet/selftest/Makefile lnet/selftest/autoMakefile lnet/ulnds/Makefile lnet/ulnds/autoMakefile lnet/ulnds/socklnd/Makefile lnet/utils/Makefile lnet/include/lnet/darwin/Makefile"


ac_config_files="$ac_config_files lustre/Makefile lustre/autoMakefile lustre/autoconf/Makefile lustre/conf/Makefile lustre/contrib/Makefile lustre/doc/Makefile lustre/include/Makefile lustre/include/lustre_ver.h lustre/include/linux/Makefile lustre/include/darwin/Makefile lustre/include/lustre/Makefile lustre/kernel_patches/targets/2.6-rhel6.target lustre/kernel_patches/targets/2.6-rhel5.target lustre/kernel_patches/targets/2.6-sles11.target lustre/kernel_patches/targets/3.0-sles11.target lustre/kernel_patches/targets/3.0-sles11sp3.target lustre/kernel_patches/targets/2.6-fc11.target lustre/kernel_patches/targets/2.6-fc12.target lustre/kernel_patches/targets/2.6-fc15.target lustre/kernel_patches/targets/3.x-fc18.target lustre/ldlm/Makefile lustre/fid/Makefile lustre/fid/autoMakefile lustre/liblustre/Makefile lustre/liblustre/tests/Makefile lustre/liblustre/tests/mpi/Makefile lustre/llite/Makefile lustre/llite/autoMakefile lustre/lclient/Makefile lustre/lov/Makefile lustre/lov/autoMakefile lustre/lvfs/Makefile lustre/lvfs/autoMakefile lustre/mdc/Makefile lustre/mdc/autoMakefile lustre/lmv/Makefile lustre/lmv/autoMakefile lustre/lfsck/Makefile lustre/lfsck/autoMakefile lustre/mdt/Makefile lustre/mdt/autoMakefile lustre/mdd/Makefile lustre/mdd/autoMakefile lustre/fld/Makefile lustre/fld/autoMakefile lustre/obdclass/Makefile lustre/obdclass/autoMakefile lustre/obdclass/linux/Makefile lustre/obdecho/Makefile lustre/obdecho/autoMakefile lustre/ofd/Makefile lustre/ofd/autoMakefile lustre/osc/Makefile lustre/osc/autoMakefile lustre/ost/Makefile lustre/ost/autoMakefile lustre/osd-ldiskfs/Makefile lustre/osd-ldiskfs/autoMakefile lustre/osd-zfs/Makefile lustre/osd-zfs/autoMakefile lustre/mgc/Makefile lustre/mgc/autoMakefile lustre/mgs/Makefile lustre/mgs/autoMakefile lustre/target/Makefile lustre/ptlrpc/Makefile lustre/ptlrpc/autoMakefile lustre/ptlrpc/gss/Makefile lustre/ptlrpc/gss/autoMakefile lustre/quota/Makefile lustre/quota/autoMakefile lustre/scripts/Makefile lustre/tests/Makefile lustre/tests/mpi/Makefile lustre/utils/Makefile lustre/utils/gss/Makefile lustre/osp/Makefile lustre/osp/autoMakefile lustre/lod/Makefile lustre/lod/autoMakefile lustre/obdclass/darwin/Makefile"


if test "$SNMP_DIST_SUBDIR" ; then
	ac_config_files="$ac_config_files snmp/Makefile snmp/autoconf/Makefile"


fi



MOSTLYCLEANFILES='.*.cmd .*.flags *.o *.ko *.mod.c .depend .*.1.* Modules.symvers Module.symvers'


cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
# tests run on this system so they can be shared between configure
# scripts and configure runs, see configure's option --config-cache.
# It is not useful on other systems.  If it contains results you don't
# want to keep, you may remove or edit it.
#
# config.status only pays attention to the cache file if you give it
# the --recheck option to rerun configure.
#
# `ac_cv_env_foo' variables (set or unset) will be overridden when
# loading this file, other *unset* `ac_cv_foo' will be assigned the
# following values.

_ACEOF

# The following way of writing the cache mishandles newlines in values,
# but we know of no workaround that is simple, portable, and efficient.
# So, we kill variables containing newlines.
# Ultrix sh set writes to stderr and can't be redirected directly,
# and sets the high bit in the cache file unless we assign to the vars.
(
  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
    eval ac_val=\$$ac_var
    case $ac_val in #(
    *${as_nl}*)
      case $ac_var in #(
      *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
      esac
      case $ac_var in #(
      _ | IFS | as_nl) ;; #(
      BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
      *) $as_unset $ac_var ;;
      esac ;;
    esac
  done

  (set) 2>&1 |
    case $as_nl`(ac_space=' '; set) 2>&1` in #(
    *${as_nl}ac_space=\ *)
      # `set' does not quote correctly, so add quotes (double-quote
      # substitution turns \\\\ into \\, and sed turns \\ into \).
      sed -n \
	"s/'/'\\\\''/g;
	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
      ;; #(
    *)
      # `set' quotes correctly as required by POSIX, so do not add quotes.
      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
      ;;
    esac |
    sort
) |
  sed '
     /^ac_cv_env_/b end
     t clear
     :clear
     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
     t end
     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
     :end' >>confcache
if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
  if test -w "$cache_file"; then
    test "x$cache_file" != "x/dev/null" &&
      { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
$as_echo "$as_me: updating cache $cache_file" >&6;}
    cat confcache >$cache_file
  else
    { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
  fi
fi
rm -f confcache

test "x$prefix" = xNONE && prefix=$ac_default_prefix
# Let make expand exec_prefix.
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'

DEFS=-DHAVE_CONFIG_H

ac_libobjs=
ac_ltlibobjs=
for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
  # 1. Remove the extension, and $U if already installed.
  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
  ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
  #    will be set to the directory where LIBOBJS objects are built.
  ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
  ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
done
LIBOBJS=$ac_libobjs

LTLIBOBJS=$ac_ltlibobjs


 if test -n "$EXEEXT"; then
  am__EXEEXT_TRUE=
  am__EXEEXT_FALSE='#'
else
  am__EXEEXT_TRUE='#'
  am__EXEEXT_FALSE=
fi

if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"MAINTAINER_MODE\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"MAINTAINER_MODE\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"AMDEP\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"am__fastdepCC\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${am__fastdepCCAS_TRUE}" && test -z "${am__fastdepCCAS_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"am__fastdepCCAS\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"am__fastdepCCAS\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${LDISKFS_ENABLED_TRUE}" && test -z "${LDISKFS_ENABLED_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"LDISKFS_ENABLED\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"LDISKFS_ENABLED\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${ZFS_ENABLED_TRUE}" && test -z "${ZFS_ENABLED_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"ZFS_ENABLED\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"ZFS_ENABLED\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${BUILD_LUSTREIOKIT_TRUE}" && test -z "${BUILD_LUSTREIOKIT_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_LUSTREIOKIT\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"BUILD_LUSTREIOKIT\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${MODULES_TRUE}" && test -z "${MODULES_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"MODULES\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"MODULES\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${UTILS_TRUE}" && test -z "${UTILS_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"UTILS\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"UTILS\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${TESTS_TRUE}" && test -z "${TESTS_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"TESTS\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"TESTS\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${DOC_TRUE}" && test -z "${DOC_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"DOC\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"DOC\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${INIT_SCRIPTS_TRUE}" && test -z "${INIT_SCRIPTS_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"INIT_SCRIPTS\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"INIT_SCRIPTS\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${LINUX_TRUE}" && test -z "${LINUX_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"LINUX\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"LINUX\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${DARWIN_TRUE}" && test -z "${DARWIN_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"DARWIN\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"DARWIN\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${SUNOS_TRUE}" && test -z "${SUNOS_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"SUNOS\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"SUNOS\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${USES_DPKG_TRUE}" && test -z "${USES_DPKG_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"USES_DPKG\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"USES_DPKG\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${USE_QUILT_TRUE}" && test -z "${USE_QUILT_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"USE_QUILT\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"USE_QUILT\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${HAVE_PCLMULQDQ_TRUE}" && test -z "${HAVE_PCLMULQDQ_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"HAVE_PCLMULQDQ\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"HAVE_PCLMULQDQ\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${BUILD_QSWLND_TRUE}" && test -z "${BUILD_QSWLND_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_QSWLND\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"BUILD_QSWLND\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${BUILD_MXLND_TRUE}" && test -z "${BUILD_MXLND_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_MXLND\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"BUILD_MXLND\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${BUILD_O2IBLND_TRUE}" && test -z "${BUILD_O2IBLND_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_O2IBLND\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"BUILD_O2IBLND\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${BUILD_RALND_TRUE}" && test -z "${BUILD_RALND_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_RALND\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"BUILD_RALND\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${BUILD_GNILND_TRUE}" && test -z "${BUILD_GNILND_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_GNILND\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"BUILD_GNILND\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${BUILD_GNILND_RCA_TRUE}" && test -z "${BUILD_GNILND_RCA_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_GNILND_RCA\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"BUILD_GNILND_RCA\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${BUILD_PTLLND_TRUE}" && test -z "${BUILD_PTLLND_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_PTLLND\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"BUILD_PTLLND\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${BUILD_USOCKLND_TRUE}" && test -z "${BUILD_USOCKLND_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"BUILD_USOCKLND\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"BUILD_USOCKLND\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${LIBLUSTRE_TRUE}" && test -z "${LIBLUSTRE_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"LIBLUSTRE\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"LIBLUSTRE\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${LIBLUSTRE_TESTS_TRUE}" && test -z "${LIBLUSTRE_TESTS_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"LIBLUSTRE_TESTS\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"LIBLUSTRE_TESTS\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${MPITESTS_TRUE}" && test -z "${MPITESTS_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"MPITESTS\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"MPITESTS\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${CLIENT_TRUE}" && test -z "${CLIENT_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"CLIENT\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"CLIENT\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${SERVER_TRUE}" && test -z "${SERVER_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"SERVER\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"SERVER\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${SPLIT_TRUE}" && test -z "${SPLIT_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"SPLIT\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"SPLIT\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${BLKID_TRUE}" && test -z "${BLKID_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"BLKID\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"BLKID\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${EXT2FS_DEVEL_TRUE}" && test -z "${EXT2FS_DEVEL_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"EXT2FS_DEVEL\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"EXT2FS_DEVEL\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${GSS_TRUE}" && test -z "${GSS_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"GSS\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"GSS\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${GSS_KEYRING_TRUE}" && test -z "${GSS_KEYRING_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"GSS_KEYRING\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"GSS_KEYRING\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${GSS_PIPEFS_TRUE}" && test -z "${GSS_PIPEFS_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"GSS_PIPEFS\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"GSS_PIPEFS\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${LIBPTHREAD_TRUE}" && test -z "${LIBPTHREAD_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"LIBPTHREAD\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"LIBPTHREAD\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi
if test -z "${LLITE_LLOOP_TRUE}" && test -z "${LLITE_LLOOP_FALSE}"; then
  { { $as_echo "$as_me:$LINENO: error: conditional \"LLITE_LLOOP\" was never defined.
Usually this means the macro was only invoked conditionally." >&5
$as_echo "$as_me: error: conditional \"LLITE_LLOOP\" was never defined.
Usually this means the macro was only invoked conditionally." >&2;}
   { (exit 1); exit 1; }; }
fi

: ${CONFIG_STATUS=./config.status}
ac_write_fail=0
ac_clean_files_save=$ac_clean_files
ac_clean_files="$ac_clean_files $CONFIG_STATUS"
{ $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
#! $SHELL
# Generated by $as_me.
# Run this file to recreate the current configuration.
# Compiler output produced by configure, useful for debugging
# configure, is in config.log if it exists.

debug=false
ac_cs_recheck=false
ac_cs_silent=false
SHELL=\${CONFIG_SHELL-$SHELL}
_ACEOF

cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
## --------------------- ##
## M4sh Initialization.  ##
## --------------------- ##

# Be more Bourne compatible
DUALCASE=1; export DUALCASE # for MKS sh
if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
  emulate sh
  NULLCMD=:
  # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
  # is contrary to our usage.  Disable this feature.
  alias -g '${1+"$@"}'='"$@"'
  setopt NO_GLOB_SUBST
else
  case `(set -o) 2>/dev/null` in
  *posix*) set -o posix ;;
esac

fi




# PATH needs CR
# Avoid depending upon Character Ranges.
as_cr_letters='abcdefghijklmnopqrstuvwxyz'
as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
as_cr_Letters=$as_cr_letters$as_cr_LETTERS
as_cr_digits='0123456789'
as_cr_alnum=$as_cr_Letters$as_cr_digits

as_nl='
'
export as_nl
# Printing a long string crashes Solaris 7 /usr/bin/printf.
as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
  as_echo='printf %s\n'
  as_echo_n='printf %s'
else
  if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
    as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
    as_echo_n='/usr/ucb/echo -n'
  else
    as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
    as_echo_n_body='eval
      arg=$1;
      case $arg in
      *"$as_nl"*)
	expr "X$arg" : "X\\(.*\\)$as_nl";
	arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
      esac;
      expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
    '
    export as_echo_n_body
    as_echo_n='sh -c $as_echo_n_body as_echo'
  fi
  export as_echo_body
  as_echo='sh -c $as_echo_body as_echo'
fi

# The user is always right.
if test "${PATH_SEPARATOR+set}" != set; then
  PATH_SEPARATOR=:
  (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
    (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
      PATH_SEPARATOR=';'
  }
fi

# Support unset when possible.
if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
  as_unset=unset
else
  as_unset=false
fi


# IFS
# We need space, tab and new line, in precisely that order.  Quoting is
# there to prevent editors from complaining about space-tab.
# (If _AS_PATH_WALK were called with IFS unset, it would disable word
# splitting by setting IFS to empty value.)
IFS=" ""	$as_nl"

# Find who we are.  Look in the path if we contain no directory separator.
case $0 in
  *[\\/]* ) as_myself=$0 ;;
  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
  IFS=$as_save_IFS
  test -z "$as_dir" && as_dir=.
  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
done
IFS=$as_save_IFS

     ;;
esac
# We did not find ourselves, most probably we were run as `sh COMMAND'
# in which case we are not to be found in the path.
if test "x$as_myself" = x; then
  as_myself=$0
fi
if test ! -f "$as_myself"; then
  $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
  { (exit 1); exit 1; }
fi

# Work around bugs in pre-3.0 UWIN ksh.
for as_var in ENV MAIL MAILPATH
do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
done
PS1='$ '
PS2='> '
PS4='+ '

# NLS nuisances.
LC_ALL=C
export LC_ALL
LANGUAGE=C
export LANGUAGE

# Required to use basename.
if expr a : '\(a\)' >/dev/null 2>&1 &&
   test "X`expr 00001 : '.*\(...\)'`" = X001; then
  as_expr=expr
else
  as_expr=false
fi

if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
  as_basename=basename
else
  as_basename=false
fi


# Name of the executable.
as_me=`$as_basename -- "$0" ||
$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
	 X"$0" : 'X\(//\)$' \| \
	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X/"$0" |
    sed '/^.*\/\([^/][^/]*\)\/*$/{
	    s//\1/
	    q
	  }
	  /^X\/\(\/\/\)$/{
	    s//\1/
	    q
	  }
	  /^X\/\(\/\).*/{
	    s//\1/
	    q
	  }
	  s/.*/./; q'`

# CDPATH.
$as_unset CDPATH



  as_lineno_1=$LINENO
  as_lineno_2=$LINENO
  test "x$as_lineno_1" != "x$as_lineno_2" &&
  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {

  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
  # uniformly replaced by the line number.  The first 'sed' inserts a
  # line-number line after each line using $LINENO; the second 'sed'
  # does the real work.  The second script uses 'N' to pair each
  # line-number line with the line containing $LINENO, and appends
  # trailing '-' during substitution so that $LINENO is not a special
  # case at line end.
  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
  # scripts with optimization help from Paolo Bonzini.  Blame Lee
  # E. McMahon (1931-1989) for sed's syntax.  :-)
  sed -n '
    p
    /[$]LINENO/=
  ' <$as_myself |
    sed '
      s/[$]LINENO.*/&-/
      t lineno
      b
      :lineno
      N
      :loop
      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
      t loop
      s/-\n.*//
    ' >$as_me.lineno &&
  chmod +x "$as_me.lineno" ||
    { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
   { (exit 1); exit 1; }; }

  # Don't try to exec as it changes $[0], causing all sort of problems
  # (the dirname of $[0] is not the place where we might find the
  # original and so on.  Autoconf is especially sensitive to this).
  . "./$as_me.lineno"
  # Exit status is that of the last command.
  exit
}


if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
  as_dirname=dirname
else
  as_dirname=false
fi

ECHO_C= ECHO_N= ECHO_T=
case `echo -n x` in
-n*)
  case `echo 'x\c'` in
  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
  *)   ECHO_C='\c';;
  esac;;
*)
  ECHO_N='-n';;
esac
if expr a : '\(a\)' >/dev/null 2>&1 &&
   test "X`expr 00001 : '.*\(...\)'`" = X001; then
  as_expr=expr
else
  as_expr=false
fi

rm -f conf$$ conf$$.exe conf$$.file
if test -d conf$$.dir; then
  rm -f conf$$.dir/conf$$.file
else
  rm -f conf$$.dir
  mkdir conf$$.dir 2>/dev/null
fi
if (echo >conf$$.file) 2>/dev/null; then
  if ln -s conf$$.file conf$$ 2>/dev/null; then
    as_ln_s='ln -s'
    # ... but there are two gotchas:
    # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
    # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
    # In both cases, we have to default to `cp -p'.
    ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
      as_ln_s='cp -p'
  elif ln conf$$.file conf$$ 2>/dev/null; then
    as_ln_s=ln
  else
    as_ln_s='cp -p'
  fi
else
  as_ln_s='cp -p'
fi
rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
rmdir conf$$.dir 2>/dev/null

if mkdir -p . 2>/dev/null; then
  as_mkdir_p=:
else
  test -d ./-p && rmdir ./-p
  as_mkdir_p=false
fi

if test -x / >/dev/null 2>&1; then
  as_test_x='test -x'
else
  if ls -dL / >/dev/null 2>&1; then
    as_ls_L_option=L
  else
    as_ls_L_option=
  fi
  as_test_x='
    eval sh -c '\''
      if test -d "$1"; then
	test -d "$1/.";
      else
	case $1 in
	-*)set "./$1";;
	esac;
	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
	???[sx]*):;;*)false;;esac;fi
    '\'' sh
  '
fi
as_executable_p=$as_test_x

# Sed expression to map a string onto a valid CPP name.
as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"

# Sed expression to map a string onto a valid variable name.
as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"


exec 6>&1

# Save the log message, to keep $[0] and so on meaningful, and to
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by Lustre $as_me 2.5.1, which was
generated by GNU Autoconf 2.63.  Invocation command line was

  CONFIG_FILES    = $CONFIG_FILES
  CONFIG_HEADERS  = $CONFIG_HEADERS
  CONFIG_LINKS    = $CONFIG_LINKS
  CONFIG_COMMANDS = $CONFIG_COMMANDS
  $ $0 $@

on `(hostname || uname -n) 2>/dev/null | sed 1q`
"

_ACEOF

case $ac_config_files in *"
"*) set x $ac_config_files; shift; ac_config_files=$*;;
esac

case $ac_config_headers in *"
"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
esac


cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
# Files that config.status was made for.
config_files="$ac_config_files"
config_headers="$ac_config_headers"
config_commands="$ac_config_commands"

_ACEOF

cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
ac_cs_usage="\
\`$as_me' instantiates files from templates according to the
current configuration.

Usage: $0 [OPTION]... [FILE]...

  -h, --help       print this help, then exit
  -V, --version    print version number and configuration settings, then exit
  -q, --quiet, --silent
                   do not print progress messages
  -d, --debug      don't remove temporary files
      --recheck    update $as_me by reconfiguring in the same conditions
      --file=FILE[:TEMPLATE]
                   instantiate the configuration file FILE
      --header=FILE[:TEMPLATE]
                   instantiate the configuration header FILE

Configuration files:
$config_files

Configuration headers:
$config_headers

Configuration commands:
$config_commands

Report bugs to <bug-autoconf@gnu.org>."

_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_version="\\
Lustre config.status 2.5.1
configured by $0, generated by GNU Autoconf 2.63,
  with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"

Copyright (C) 2008 Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."

ac_pwd='$ac_pwd'
srcdir='$srcdir'
INSTALL='$INSTALL'
MKDIR_P='$MKDIR_P'
AWK='$AWK'
test -n "\$AWK" || AWK=awk
_ACEOF

cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# The default lists apply if the user does not specify any file.
ac_need_defaults=:
while test $# != 0
do
  case $1 in
  --*=*)
    ac_option=`expr "X$1" : 'X\([^=]*\)='`
    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
    ac_shift=:
    ;;
  *)
    ac_option=$1
    ac_optarg=$2
    ac_shift=shift
    ;;
  esac

  case $ac_option in
  # Handling of the options.
  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
    ac_cs_recheck=: ;;
  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
    $as_echo "$ac_cs_version"; exit ;;
  --debug | --debu | --deb | --de | --d | -d )
    debug=: ;;
  --file | --fil | --fi | --f )
    $ac_shift
    case $ac_optarg in
    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
    esac
    CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
    ac_need_defaults=false;;
  --header | --heade | --head | --hea )
    $ac_shift
    case $ac_optarg in
    *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
    esac
    CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
    ac_need_defaults=false;;
  --he | --h)
    # Conflict between --help and --header
    { $as_echo "$as_me: error: ambiguous option: $1
Try \`$0 --help' for more information." >&2
   { (exit 1); exit 1; }; };;
  --help | --hel | -h )
    $as_echo "$ac_cs_usage"; exit ;;
  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
  | -silent | --silent | --silen | --sile | --sil | --si | --s)
    ac_cs_silent=: ;;

  # This is an error.
  -*) { $as_echo "$as_me: error: unrecognized option: $1
Try \`$0 --help' for more information." >&2
   { (exit 1); exit 1; }; } ;;

  *) ac_config_targets="$ac_config_targets $1"
     ac_need_defaults=false ;;

  esac
  shift
done

ac_configure_extra_args=

if $ac_cs_silent; then
  exec 6>/dev/null
  ac_configure_extra_args="$ac_configure_extra_args --silent"
fi

_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
if \$ac_cs_recheck; then
  set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
  shift
  \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
  CONFIG_SHELL='$SHELL'
  export CONFIG_SHELL
  exec "\$@"
fi

_ACEOF
cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
exec 5>>config.log
{
  echo
  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
## Running $as_me. ##
_ASBOX
  $as_echo "$ac_log"
} >&5

_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
#
# INIT-COMMANDS
#
AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"

_ACEOF

cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1

# Handling of arguments.
for ac_config_target in $ac_config_targets
do
  case $ac_config_target in
    "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
    "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
    "libcfs/Kernelenv") CONFIG_FILES="$CONFIG_FILES libcfs/Kernelenv" ;;
    "libcfs/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/Makefile" ;;
    "libcfs/autoMakefile") CONFIG_FILES="$CONFIG_FILES libcfs/autoMakefile" ;;
    "libcfs/autoconf/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/autoconf/Makefile" ;;
    "libcfs/include/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/include/Makefile" ;;
    "libcfs/include/libcfs/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/include/libcfs/Makefile" ;;
    "libcfs/include/libcfs/linux/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/include/libcfs/linux/Makefile" ;;
    "libcfs/include/libcfs/posix/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/include/libcfs/posix/Makefile" ;;
    "libcfs/include/libcfs/util/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/include/libcfs/util/Makefile" ;;
    "libcfs/libcfs/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/libcfs/Makefile" ;;
    "libcfs/libcfs/autoMakefile") CONFIG_FILES="$CONFIG_FILES libcfs/libcfs/autoMakefile" ;;
    "libcfs/libcfs/linux/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/libcfs/linux/Makefile" ;;
    "libcfs/libcfs/posix/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/libcfs/posix/Makefile" ;;
    "libcfs/libcfs/util/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/libcfs/util/Makefile" ;;
    "libcfs/include/libcfs/darwin/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/include/libcfs/darwin/Makefile" ;;
    "libcfs/libcfs/darwin/Makefile") CONFIG_FILES="$CONFIG_FILES libcfs/libcfs/darwin/Makefile" ;;
    "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
    "autoMakefile") CONFIG_FILES="$CONFIG_FILES autoMakefile" ;;
    "config/Makefile") CONFIG_FILES="$CONFIG_FILES config/Makefile" ;;
    "Rules") CONFIG_FILES="$CONFIG_FILES Rules:build/Rules.in" ;;
    "lustre.spec") CONFIG_FILES="$CONFIG_FILES lustre.spec" ;;
    "contrib/Makefile") CONFIG_FILES="$CONFIG_FILES contrib/Makefile" ;;
    "contrib/lbuild/Makefile") CONFIG_FILES="$CONFIG_FILES contrib/lbuild/Makefile" ;;
    "contrib/scripts/Makefile") CONFIG_FILES="$CONFIG_FILES contrib/scripts/Makefile" ;;
    "ldiskfs/Makefile") CONFIG_FILES="$CONFIG_FILES ldiskfs/Makefile" ;;
    "ldiskfs/autoMakefile") CONFIG_FILES="$CONFIG_FILES ldiskfs/autoMakefile" ;;
    "lustre-iokit/Makefile") CONFIG_FILES="$CONFIG_FILES lustre-iokit/Makefile" ;;
    "lustre-iokit/obdfilter-survey/Makefile") CONFIG_FILES="$CONFIG_FILES lustre-iokit/obdfilter-survey/Makefile" ;;
    "lustre-iokit/ost-survey/Makefile") CONFIG_FILES="$CONFIG_FILES lustre-iokit/ost-survey/Makefile" ;;
    "lustre-iokit/sgpdd-survey/Makefile") CONFIG_FILES="$CONFIG_FILES lustre-iokit/sgpdd-survey/Makefile" ;;
    "lustre-iokit/mds-survey/Makefile") CONFIG_FILES="$CONFIG_FILES lustre-iokit/mds-survey/Makefile" ;;
    "lustre-iokit/ior-survey/Makefile") CONFIG_FILES="$CONFIG_FILES lustre-iokit/ior-survey/Makefile" ;;
    "lustre-iokit/stats-collect/Makefile") CONFIG_FILES="$CONFIG_FILES lustre-iokit/stats-collect/Makefile" ;;
    "lnet/Kernelenv") CONFIG_FILES="$CONFIG_FILES lnet/Kernelenv" ;;
    "lnet/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/Makefile" ;;
    "lnet/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/autoMakefile" ;;
    "lnet/autoconf/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/autoconf/Makefile" ;;
    "lnet/doc/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/doc/Makefile" ;;
    "lnet/include/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/include/Makefile" ;;
    "lnet/include/lnet/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/include/lnet/Makefile" ;;
    "lnet/include/lnet/linux/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/include/lnet/linux/Makefile" ;;
    "lnet/klnds/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/Makefile" ;;
    "lnet/klnds/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/autoMakefile" ;;
    "lnet/klnds/mxlnd/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/mxlnd/autoMakefile" ;;
    "lnet/klnds/mxlnd/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/mxlnd/Makefile" ;;
    "lnet/klnds/o2iblnd/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/o2iblnd/Makefile" ;;
    "lnet/klnds/o2iblnd/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/o2iblnd/autoMakefile" ;;
    "lnet/klnds/qswlnd/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/qswlnd/Makefile" ;;
    "lnet/klnds/qswlnd/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/qswlnd/autoMakefile" ;;
    "lnet/klnds/ralnd/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/ralnd/Makefile" ;;
    "lnet/klnds/ralnd/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/ralnd/autoMakefile" ;;
    "lnet/klnds/gnilnd/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/gnilnd/Makefile" ;;
    "lnet/klnds/gnilnd/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/gnilnd/autoMakefile" ;;
    "lnet/klnds/socklnd/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/socklnd/Makefile" ;;
    "lnet/klnds/socklnd/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/socklnd/autoMakefile" ;;
    "lnet/klnds/ptllnd/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/ptllnd/Makefile" ;;
    "lnet/klnds/ptllnd/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/klnds/ptllnd/autoMakefile" ;;
    "lnet/lnet/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/lnet/Makefile" ;;
    "lnet/lnet/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/lnet/autoMakefile" ;;
    "lnet/selftest/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/selftest/Makefile" ;;
    "lnet/selftest/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/selftest/autoMakefile" ;;
    "lnet/ulnds/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/ulnds/Makefile" ;;
    "lnet/ulnds/autoMakefile") CONFIG_FILES="$CONFIG_FILES lnet/ulnds/autoMakefile" ;;
    "lnet/ulnds/socklnd/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/ulnds/socklnd/Makefile" ;;
    "lnet/utils/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/utils/Makefile" ;;
    "lnet/include/lnet/darwin/Makefile") CONFIG_FILES="$CONFIG_FILES lnet/include/lnet/darwin/Makefile" ;;
    "lustre/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/Makefile" ;;
    "lustre/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/autoMakefile" ;;
    "lustre/autoconf/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/autoconf/Makefile" ;;
    "lustre/conf/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/conf/Makefile" ;;
    "lustre/contrib/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/contrib/Makefile" ;;
    "lustre/doc/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/doc/Makefile" ;;
    "lustre/include/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/include/Makefile" ;;
    "lustre/include/lustre_ver.h") CONFIG_FILES="$CONFIG_FILES lustre/include/lustre_ver.h" ;;
    "lustre/include/linux/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/include/linux/Makefile" ;;
    "lustre/include/darwin/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/include/darwin/Makefile" ;;
    "lustre/include/lustre/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/include/lustre/Makefile" ;;
    "lustre/kernel_patches/targets/2.6-rhel6.target") CONFIG_FILES="$CONFIG_FILES lustre/kernel_patches/targets/2.6-rhel6.target" ;;
    "lustre/kernel_patches/targets/2.6-rhel5.target") CONFIG_FILES="$CONFIG_FILES lustre/kernel_patches/targets/2.6-rhel5.target" ;;
    "lustre/kernel_patches/targets/2.6-sles11.target") CONFIG_FILES="$CONFIG_FILES lustre/kernel_patches/targets/2.6-sles11.target" ;;
    "lustre/kernel_patches/targets/3.0-sles11.target") CONFIG_FILES="$CONFIG_FILES lustre/kernel_patches/targets/3.0-sles11.target" ;;
    "lustre/kernel_patches/targets/3.0-sles11sp3.target") CONFIG_FILES="$CONFIG_FILES lustre/kernel_patches/targets/3.0-sles11sp3.target" ;;
    "lustre/kernel_patches/targets/2.6-fc11.target") CONFIG_FILES="$CONFIG_FILES lustre/kernel_patches/targets/2.6-fc11.target" ;;
    "lustre/kernel_patches/targets/2.6-fc12.target") CONFIG_FILES="$CONFIG_FILES lustre/kernel_patches/targets/2.6-fc12.target" ;;
    "lustre/kernel_patches/targets/2.6-fc15.target") CONFIG_FILES="$CONFIG_FILES lustre/kernel_patches/targets/2.6-fc15.target" ;;
    "lustre/kernel_patches/targets/3.x-fc18.target") CONFIG_FILES="$CONFIG_FILES lustre/kernel_patches/targets/3.x-fc18.target" ;;
    "lustre/ldlm/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/ldlm/Makefile" ;;
    "lustre/fid/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/fid/Makefile" ;;
    "lustre/fid/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/fid/autoMakefile" ;;
    "lustre/liblustre/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/liblustre/Makefile" ;;
    "lustre/liblustre/tests/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/liblustre/tests/Makefile" ;;
    "lustre/liblustre/tests/mpi/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/liblustre/tests/mpi/Makefile" ;;
    "lustre/llite/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/llite/Makefile" ;;
    "lustre/llite/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/llite/autoMakefile" ;;
    "lustre/lclient/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/lclient/Makefile" ;;
    "lustre/lov/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/lov/Makefile" ;;
    "lustre/lov/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/lov/autoMakefile" ;;
    "lustre/lvfs/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/lvfs/Makefile" ;;
    "lustre/lvfs/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/lvfs/autoMakefile" ;;
    "lustre/mdc/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/mdc/Makefile" ;;
    "lustre/mdc/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/mdc/autoMakefile" ;;
    "lustre/lmv/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/lmv/Makefile" ;;
    "lustre/lmv/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/lmv/autoMakefile" ;;
    "lustre/lfsck/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/lfsck/Makefile" ;;
    "lustre/lfsck/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/lfsck/autoMakefile" ;;
    "lustre/mdt/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/mdt/Makefile" ;;
    "lustre/mdt/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/mdt/autoMakefile" ;;
    "lustre/mdd/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/mdd/Makefile" ;;
    "lustre/mdd/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/mdd/autoMakefile" ;;
    "lustre/fld/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/fld/Makefile" ;;
    "lustre/fld/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/fld/autoMakefile" ;;
    "lustre/obdclass/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/obdclass/Makefile" ;;
    "lustre/obdclass/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/obdclass/autoMakefile" ;;
    "lustre/obdclass/linux/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/obdclass/linux/Makefile" ;;
    "lustre/obdecho/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/obdecho/Makefile" ;;
    "lustre/obdecho/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/obdecho/autoMakefile" ;;
    "lustre/ofd/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/ofd/Makefile" ;;
    "lustre/ofd/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/ofd/autoMakefile" ;;
    "lustre/osc/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/osc/Makefile" ;;
    "lustre/osc/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/osc/autoMakefile" ;;
    "lustre/ost/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/ost/Makefile" ;;
    "lustre/ost/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/ost/autoMakefile" ;;
    "lustre/osd-ldiskfs/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/osd-ldiskfs/Makefile" ;;
    "lustre/osd-ldiskfs/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/osd-ldiskfs/autoMakefile" ;;
    "lustre/osd-zfs/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/osd-zfs/Makefile" ;;
    "lustre/osd-zfs/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/osd-zfs/autoMakefile" ;;
    "lustre/mgc/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/mgc/Makefile" ;;
    "lustre/mgc/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/mgc/autoMakefile" ;;
    "lustre/mgs/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/mgs/Makefile" ;;
    "lustre/mgs/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/mgs/autoMakefile" ;;
    "lustre/target/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/target/Makefile" ;;
    "lustre/ptlrpc/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/ptlrpc/Makefile" ;;
    "lustre/ptlrpc/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/ptlrpc/autoMakefile" ;;
    "lustre/ptlrpc/gss/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/ptlrpc/gss/Makefile" ;;
    "lustre/ptlrpc/gss/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/ptlrpc/gss/autoMakefile" ;;
    "lustre/quota/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/quota/Makefile" ;;
    "lustre/quota/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/quota/autoMakefile" ;;
    "lustre/scripts/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/scripts/Makefile" ;;
    "lustre/tests/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/tests/Makefile" ;;
    "lustre/tests/mpi/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/tests/mpi/Makefile" ;;
    "lustre/utils/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/utils/Makefile" ;;
    "lustre/utils/gss/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/utils/gss/Makefile" ;;
    "lustre/osp/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/osp/Makefile" ;;
    "lustre/osp/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/osp/autoMakefile" ;;
    "lustre/lod/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/lod/Makefile" ;;
    "lustre/lod/autoMakefile") CONFIG_FILES="$CONFIG_FILES lustre/lod/autoMakefile" ;;
    "lustre/obdclass/darwin/Makefile") CONFIG_FILES="$CONFIG_FILES lustre/obdclass/darwin/Makefile" ;;
    "snmp/Makefile") CONFIG_FILES="$CONFIG_FILES snmp/Makefile" ;;
    "snmp/autoconf/Makefile") CONFIG_FILES="$CONFIG_FILES snmp/autoconf/Makefile" ;;

  *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
$as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
   { (exit 1); exit 1; }; };;
  esac
done


# If the user did not use the arguments to specify the items to instantiate,
# then the envvar interface is used.  Set only those that are not.
# We use the long form for the default assignment because of an extremely
# bizarre bug on SunOS 4.1.3.
if $ac_need_defaults; then
  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
  test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
fi

# Have a temporary directory for convenience.  Make it in the build tree
# simply because there is no reason against having it here, and in addition,
# creating and moving files from /tmp can sometimes cause problems.
# Hook for its removal unless debugging.
# Note that there is a small window in which the directory will not be cleaned:
# after its creation but before its name has been assigned to `$tmp'.
$debug ||
{
  tmp=
  trap 'exit_status=$?
  { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
' 0
  trap '{ (exit 1); exit 1; }' 1 2 13 15
}
# Create a (secure) tmp directory for tmp files.

{
  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
  test -n "$tmp" && test -d "$tmp"
}  ||
{
  tmp=./conf$$-$RANDOM
  (umask 077 && mkdir "$tmp")
} ||
{
   $as_echo "$as_me: cannot create a temporary directory in ." >&2
   { (exit 1); exit 1; }
}

# Set up the scripts for CONFIG_FILES section.
# No need to generate them if there are no CONFIG_FILES.
# This happens for instance with `./config.status config.h'.
if test -n "$CONFIG_FILES"; then


ac_cr='
'
ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
  ac_cs_awk_cr='\\r'
else
  ac_cs_awk_cr=$ac_cr
fi

echo 'BEGIN {' >"$tmp/subs1.awk" &&
_ACEOF


{
  echo "cat >conf$$subs.awk <<_ACEOF" &&
  echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
  echo "_ACEOF"
} >conf$$subs.sh ||
  { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
   { (exit 1); exit 1; }; }
ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
ac_delim='%!_!# '
for ac_last_try in false false false false false :; do
  . ./conf$$subs.sh ||
    { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
   { (exit 1); exit 1; }; }

  ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
  if test $ac_delim_n = $ac_delim_num; then
    break
  elif $ac_last_try; then
    { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
$as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
   { (exit 1); exit 1; }; }
  else
    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
  fi
done
rm -f conf$$subs.sh

cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
_ACEOF
sed -n '
h
s/^/S["/; s/!.*/"]=/
p
g
s/^[^!]*!//
:repl
t repl
s/'"$ac_delim"'$//
t delim
:nl
h
s/\(.\{148\}\).*/\1/
t more1
s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
p
n
b repl
:more1
s/["\\]/\\&/g; s/^/"/; s/$/"\\/
p
g
s/.\{148\}//
t nl
:delim
h
s/\(.\{148\}\).*/\1/
t more2
s/["\\]/\\&/g; s/^/"/; s/$/"/
p
b
:more2
s/["\\]/\\&/g; s/^/"/; s/$/"\\/
p
g
s/.\{148\}//
t delim
' <conf$$subs.awk | sed '
/^[^""]/{
  N
  s/\n//
}
' >>$CONFIG_STATUS || ac_write_fail=1
rm -f conf$$subs.awk
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
_ACAWK
cat >>"\$tmp/subs1.awk" <<_ACAWK &&
  for (key in S) S_is_set[key] = 1
  FS = ""

}
{
  line = $ 0
  nfields = split(line, field, "@")
  substed = 0
  len = length(field[1])
  for (i = 2; i < nfields; i++) {
    key = field[i]
    keylen = length(key)
    if (S_is_set[key]) {
      value = S[key]
      line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
      len += length(value) + length(field[++i])
      substed = 1
    } else
      len += 1 + keylen
  }

  print line
}

_ACAWK
_ACEOF
cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
  sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
else
  cat
fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
  || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
$as_echo "$as_me: error: could not setup config files machinery" >&2;}
   { (exit 1); exit 1; }; }
_ACEOF

# VPATH may cause trouble with some makes, so we remove $(srcdir),
# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
# trailing colons and then remove the whole line if VPATH becomes empty
# (actually we leave an empty line to preserve line numbers).
if test "x$srcdir" = x.; then
  ac_vpsub='/^[	 ]*VPATH[	 ]*=/{
s/:*\$(srcdir):*/:/
s/:*\${srcdir}:*/:/
s/:*@srcdir@:*/:/
s/^\([^=]*=[	 ]*\):*/\1/
s/:*$//
s/^[^=]*=[	 ]*$//
}'
fi

cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
fi # test -n "$CONFIG_FILES"

# Set up the scripts for CONFIG_HEADERS section.
# No need to generate them if there are no CONFIG_HEADERS.
# This happens for instance with `./config.status Makefile'.
if test -n "$CONFIG_HEADERS"; then
cat >"$tmp/defines.awk" <<\_ACAWK ||
BEGIN {
_ACEOF

# Transform confdefs.h into an awk script `defines.awk', embedded as
# here-document in config.status, that substitutes the proper values into
# config.h.in to produce config.h.

# Create a delimiter string that does not exist in confdefs.h, to ease
# handling of long lines.
ac_delim='%!_!# '
for ac_last_try in false false :; do
  ac_t=`sed -n "/$ac_delim/p" confdefs.h`
  if test -z "$ac_t"; then
    break
  elif $ac_last_try; then
    { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
$as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
   { (exit 1); exit 1; }; }
  else
    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
  fi
done

# For the awk script, D is an array of macro values keyed by name,
# likewise P contains macro parameters if any.  Preserve backslash
# newline sequences.

ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
sed -n '
s/.\{148\}/&'"$ac_delim"'/g
t rset
:rset
s/^[	 ]*#[	 ]*define[	 ][	 ]*/ /
t def
d
:def
s/\\$//
t bsnl
s/["\\]/\\&/g
s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
D["\1"]=" \3"/p
s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2"/p
d
:bsnl
s/["\\]/\\&/g
s/^ \('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/P["\1"]="\2"\
D["\1"]=" \3\\\\\\n"\\/p
t cont
s/^ \('"$ac_word_re"'\)[	 ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
t cont
d
:cont
n
s/.\{148\}/&'"$ac_delim"'/g
t clear
:clear
s/\\$//
t bsnlc
s/["\\]/\\&/g; s/^/"/; s/$/"/p
d
:bsnlc
s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
b cont
' <confdefs.h | sed '
s/'"$ac_delim"'/"\\\
"/g' >>$CONFIG_STATUS || ac_write_fail=1

cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  for (key in D) D_is_set[key] = 1
  FS = ""
}
/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
  line = \$ 0
  split(line, arg, " ")
  if (arg[1] == "#") {
    defundef = arg[2]
    mac1 = arg[3]
  } else {
    defundef = substr(arg[1], 2)
    mac1 = arg[2]
  }
  split(mac1, mac2, "(") #)
  macro = mac2[1]
  prefix = substr(line, 1, index(line, defundef) - 1)
  if (D_is_set[macro]) {
    # Preserve the white space surrounding the "#".
    print prefix "define", macro P[macro] D[macro]
    next
  } else {
    # Replace #undef with comments.  This is necessary, for example,
    # in the case of _POSIX_SOURCE, which is predefined and required
    # on some systems where configure will not decide to define it.
    if (defundef == "undef") {
      print "/*", prefix defundef, macro, "*/"
      next
    }
  }
}
{ print }
_ACAWK
_ACEOF
cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
  { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
$as_echo "$as_me: error: could not setup config headers machinery" >&2;}
   { (exit 1); exit 1; }; }
fi # test -n "$CONFIG_HEADERS"


eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS"
shift
for ac_tag
do
  case $ac_tag in
  :[FHLC]) ac_mode=$ac_tag; continue;;
  esac
  case $ac_mode$ac_tag in
  :[FHL]*:*);;
  :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
$as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
   { (exit 1); exit 1; }; };;
  :[FH]-) ac_tag=-:-;;
  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
  esac
  ac_save_IFS=$IFS
  IFS=:
  set x $ac_tag
  IFS=$ac_save_IFS
  shift
  ac_file=$1
  shift

  case $ac_mode in
  :L) ac_source=$1;;
  :[FH])
    ac_file_inputs=
    for ac_f
    do
      case $ac_f in
      -) ac_f="$tmp/stdin";;
      *) # Look for the file first in the build tree, then in the source tree
	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
	 # because $ac_f cannot contain `:'.
	 test -f "$ac_f" ||
	   case $ac_f in
	   [\\/$]*) false;;
	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
	   esac ||
	   { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
$as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
   { (exit 1); exit 1; }; };;
      esac
      case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
      ac_file_inputs="$ac_file_inputs '$ac_f'"
    done

    # Let's still pretend it is `configure' which instantiates (i.e., don't
    # use $as_me), people would be surprised to read:
    #    /* config.h.  Generated by config.status.  */
    configure_input='Generated from '`
	  $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
	`' by configure.'
    if test x"$ac_file" != x-; then
      configure_input="$ac_file.  $configure_input"
      { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
$as_echo "$as_me: creating $ac_file" >&6;}
    fi
    # Neutralize special characters interpreted by sed in replacement strings.
    case $configure_input in #(
    *\&* | *\|* | *\\* )
       ac_sed_conf_input=`$as_echo "$configure_input" |
       sed 's/[\\\\&|]/\\\\&/g'`;; #(
    *) ac_sed_conf_input=$configure_input;;
    esac

    case $ac_tag in
    *:-:* | *:-) cat >"$tmp/stdin" \
      || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
$as_echo "$as_me: error: could not create $ac_file" >&2;}
   { (exit 1); exit 1; }; } ;;
    esac
    ;;
  esac

  ac_dir=`$as_dirname -- "$ac_file" ||
$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
	 X"$ac_file" : 'X\(//\)[^/]' \| \
	 X"$ac_file" : 'X\(//\)$' \| \
	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X"$ac_file" |
    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)[^/].*/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\).*/{
	    s//\1/
	    q
	  }
	  s/.*/./; q'`
  { as_dir="$ac_dir"
  case $as_dir in #(
  -*) as_dir=./$as_dir;;
  esac
  test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
    as_dirs=
    while :; do
      case $as_dir in #(
      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
      *) as_qdir=$as_dir;;
      esac
      as_dirs="'$as_qdir' $as_dirs"
      as_dir=`$as_dirname -- "$as_dir" ||
$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
	 X"$as_dir" : 'X\(//\)[^/]' \| \
	 X"$as_dir" : 'X\(//\)$' \| \
	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X"$as_dir" |
    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)[^/].*/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\).*/{
	    s//\1/
	    q
	  }
	  s/.*/./; q'`
      test -d "$as_dir" && break
    done
    test -z "$as_dirs" || eval "mkdir $as_dirs"
  } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
$as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
   { (exit 1); exit 1; }; }; }
  ac_builddir=.

case "$ac_dir" in
.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
*)
  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
  # A ".." for each directory in $ac_dir_suffix.
  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
  case $ac_top_builddir_sub in
  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
  esac ;;
esac
ac_abs_top_builddir=$ac_pwd
ac_abs_builddir=$ac_pwd$ac_dir_suffix
# for backward compatibility:
ac_top_builddir=$ac_top_build_prefix

case $srcdir in
  .)  # We are building in place.
    ac_srcdir=.
    ac_top_srcdir=$ac_top_builddir_sub
    ac_abs_top_srcdir=$ac_pwd ;;
  [\\/]* | ?:[\\/]* )  # Absolute name.
    ac_srcdir=$srcdir$ac_dir_suffix;
    ac_top_srcdir=$srcdir
    ac_abs_top_srcdir=$srcdir ;;
  *) # Relative name.
    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
    ac_top_srcdir=$ac_top_build_prefix$srcdir
    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
esac
ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix


  case $ac_mode in
  :F)
  #
  # CONFIG_FILE
  #

  case $INSTALL in
  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
  *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
  esac
  ac_MKDIR_P=$MKDIR_P
  case $MKDIR_P in
  [\\/$]* | ?:[\\/]* ) ;;
  */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
  esac
_ACEOF

cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# If the template does not know about datarootdir, expand it.
# FIXME: This hack should be removed a few years after 2.60.
ac_datarootdir_hack=; ac_datarootdir_seen=

ac_sed_dataroot='
/datarootdir/ {
  p
  q
}
/@datadir@/p
/@docdir@/p
/@infodir@/p
/@localedir@/p
/@mandir@/p
'
case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
*datarootdir*) ac_datarootdir_seen=yes;;
*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
  { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
_ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
  ac_datarootdir_hack='
  s&@datadir@&$datadir&g
  s&@docdir@&$docdir&g
  s&@infodir@&$infodir&g
  s&@localedir@&$localedir&g
  s&@mandir@&$mandir&g
    s&\\\${datarootdir}&$datarootdir&g' ;;
esac
_ACEOF

# Neutralize VPATH when `$srcdir' = `.'.
# Shell code in configure.ac might set extrasub.
# FIXME: do we really want to maintain this feature?
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_sed_extra="$ac_vpsub
$extrasub
_ACEOF
cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
:t
/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
s|@configure_input@|$ac_sed_conf_input|;t t
s&@top_builddir@&$ac_top_builddir_sub&;t t
s&@top_build_prefix@&$ac_top_build_prefix&;t t
s&@srcdir@&$ac_srcdir&;t t
s&@abs_srcdir@&$ac_abs_srcdir&;t t
s&@top_srcdir@&$ac_top_srcdir&;t t
s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
s&@builddir@&$ac_builddir&;t t
s&@abs_builddir@&$ac_abs_builddir&;t t
s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
s&@INSTALL@&$ac_INSTALL&;t t
s&@MKDIR_P@&$ac_MKDIR_P&;t t
$ac_datarootdir_hack
"
eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
  || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
$as_echo "$as_me: error: could not create $ac_file" >&2;}
   { (exit 1); exit 1; }; }

test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
  { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
  { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
which seems to be undefined.  Please make sure it is defined." >&5
$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
which seems to be undefined.  Please make sure it is defined." >&2;}

  rm -f "$tmp/stdin"
  case $ac_file in
  -) cat "$tmp/out" && rm -f "$tmp/out";;
  *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
  esac \
  || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
$as_echo "$as_me: error: could not create $ac_file" >&2;}
   { (exit 1); exit 1; }; }
 ;;
  :H)
  #
  # CONFIG_HEADER
  #
  if test x"$ac_file" != x-; then
    {
      $as_echo "/* $configure_input  */" \
      && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
    } >"$tmp/config.h" \
      || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
$as_echo "$as_me: error: could not create $ac_file" >&2;}
   { (exit 1); exit 1; }; }
    if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
      { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
$as_echo "$as_me: $ac_file is unchanged" >&6;}
    else
      rm -f "$ac_file"
      mv "$tmp/config.h" "$ac_file" \
	|| { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
$as_echo "$as_me: error: could not create $ac_file" >&2;}
   { (exit 1); exit 1; }; }
    fi
  else
    $as_echo "/* $configure_input  */" \
      && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
      || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
$as_echo "$as_me: error: could not create -" >&2;}
   { (exit 1); exit 1; }; }
  fi
# Compute "$ac_file"'s index in $config_headers.
_am_arg="$ac_file"
_am_stamp_count=1
for _am_header in $config_headers :; do
  case $_am_header in
    $_am_arg | $_am_arg:* )
      break ;;
    * )
      _am_stamp_count=`expr $_am_stamp_count + 1` ;;
  esac
done
echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
	 X"$_am_arg" : 'X\(//\)[^/]' \| \
	 X"$_am_arg" : 'X\(//\)$' \| \
	 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X"$_am_arg" |
    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)[^/].*/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\).*/{
	    s//\1/
	    q
	  }
	  s/.*/./; q'`/stamp-h$_am_stamp_count
 ;;

  :C)  { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5
$as_echo "$as_me: executing $ac_file commands" >&6;}
 ;;
  esac


  case $ac_file$ac_mode in
    "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
  # Autoconf 2.62 quotes --file arguments for eval, but not when files
  # are listed without --file.  Let's play safe and only enable the eval
  # if we detect the quoting.
  case $CONFIG_FILES in
  *\'*) eval set x "$CONFIG_FILES" ;;
  *)   set x $CONFIG_FILES ;;
  esac
  shift
  for mf
  do
    # Strip MF so we end up with the name of the file.
    mf=`echo "$mf" | sed -e 's/:.*$//'`
    # Check whether this is an Automake generated Makefile or not.
    # We used to match only the files named `Makefile.in', but
    # some people rename them; so instead we look at the file content.
    # Grep'ing the first line is not enough: some people post-process
    # each Makefile.in and add a new line on top of each file to say so.
    # Grep'ing the whole file is not good either: AIX grep has a line
    # limit of 2048, but all sed's we know have understand at least 4000.
    if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
      dirpart=`$as_dirname -- "$mf" ||
$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
	 X"$mf" : 'X\(//\)[^/]' \| \
	 X"$mf" : 'X\(//\)$' \| \
	 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X"$mf" |
    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)[^/].*/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\).*/{
	    s//\1/
	    q
	  }
	  s/.*/./; q'`
    else
      continue
    fi
    # Extract the definition of DEPDIR, am__include, and am__quote
    # from the Makefile without running `make'.
    DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
    test -z "$DEPDIR" && continue
    am__include=`sed -n 's/^am__include = //p' < "$mf"`
    test -z "am__include" && continue
    am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
    # When using ansi2knr, U may be empty or an underscore; expand it
    U=`sed -n 's/^U = //p' < "$mf"`
    # Find all dependency output files, they are included files with
    # $(DEPDIR) in their names.  We invoke sed twice because it is the
    # simplest approach to changing $(DEPDIR) to its actual value in the
    # expansion.
    for file in `sed -n "
      s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
	 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
      # Make sure the directory exists.
      test -f "$dirpart/$file" && continue
      fdir=`$as_dirname -- "$file" ||
$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
	 X"$file" : 'X\(//\)[^/]' \| \
	 X"$file" : 'X\(//\)$' \| \
	 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X"$file" |
    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)[^/].*/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\).*/{
	    s//\1/
	    q
	  }
	  s/.*/./; q'`
      { as_dir=$dirpart/$fdir
  case $as_dir in #(
  -*) as_dir=./$as_dir;;
  esac
  test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
    as_dirs=
    while :; do
      case $as_dir in #(
      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
      *) as_qdir=$as_dir;;
      esac
      as_dirs="'$as_qdir' $as_dirs"
      as_dir=`$as_dirname -- "$as_dir" ||
$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
	 X"$as_dir" : 'X\(//\)[^/]' \| \
	 X"$as_dir" : 'X\(//\)$' \| \
	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X"$as_dir" |
    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)[^/].*/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\).*/{
	    s//\1/
	    q
	  }
	  s/.*/./; q'`
      test -d "$as_dir" && break
    done
    test -z "$as_dirs" || eval "mkdir $as_dirs"
  } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
$as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
   { (exit 1); exit 1; }; }; }
      # echo "creating $dirpart/$file"
      echo '# dummy' > "$dirpart/$file"
    done
  done
}
 ;;

  esac
done # for ac_tag


{ (exit 0); exit 0; }
_ACEOF
chmod +x $CONFIG_STATUS
ac_clean_files=$ac_clean_files_save

test $ac_write_fail = 0 ||
  { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
$as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
   { (exit 1); exit 1; }; }


# configure is writing to config.log, and then calls config.status.
# config.status does its own redirection, appending to config.log.
# Unfortunately, on DOS this fails, as config.log is still kept open
# by configure, so config.status won't be able to write to it; its
# output is simply discarded.  So we exec the FD to /dev/null,
# effectively closing config.log, so it can be properly (re)opened and
# appended to by config.status.  When coming back to configure, we
# need to make the FD available again.
if test "$no_create" != yes; then
  ac_cs_success=:
  ac_config_status_args=
  test "$silent" = yes &&
    ac_config_status_args="$ac_config_status_args --quiet"
  exec 5>/dev/null
  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
  exec 5>>config.log
  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
  # would make configure fail if this is the last instruction.
  $ac_cs_success || { (exit 1); exit 1; }
fi

#
# CONFIG_SUBDIRS section.
#
if test "$no_recursion" != yes; then

  # Remove --cache-file, --srcdir, and --disable-option-checking arguments
  # so they do not pile up.
  ac_sub_configure_args=
  ac_prev=
  eval "set x $ac_configure_args"
  shift
  for ac_arg
  do
    if test -n "$ac_prev"; then
      ac_prev=
      continue
    fi
    case $ac_arg in
    -cache-file | --cache-file | --cache-fil | --cache-fi \
    | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
      ac_prev=cache_file ;;
    -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
    | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
    | --c=*)
      ;;
    --config-cache | -C)
      ;;
    -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
      ac_prev=srcdir ;;
    -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
      ;;
    -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
      ac_prev=prefix ;;
    -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
      ;;
    --disable-option-checking)
      ;;
    *)
      case $ac_arg in
      *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
      esac
      ac_sub_configure_args="$ac_sub_configure_args '$ac_arg'" ;;
    esac
  done

  # Always prepend --prefix to ensure using the same prefix
  # in subdir configurations.
  ac_arg="--prefix=$prefix"
  case $ac_arg in
  *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
  esac
  ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"

  # Pass --silent
  if test "$silent" = yes; then
    ac_sub_configure_args="--silent $ac_sub_configure_args"
  fi

  # Always prepend --disable-option-checking to silence warnings, since
  # different subdirs can have different --enable and --with options.
  ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"

  ac_popdir=`pwd`
  for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue

    # Do not complain, so a configure script can configure whichever
    # parts of a large source tree are present.
    test -d "$srcdir/$ac_dir" || continue

    ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
    $as_echo "$as_me:$LINENO: $ac_msg" >&5
    $as_echo "$ac_msg" >&6
    { as_dir="$ac_dir"
  case $as_dir in #(
  -*) as_dir=./$as_dir;;
  esac
  test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
    as_dirs=
    while :; do
      case $as_dir in #(
      *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
      *) as_qdir=$as_dir;;
      esac
      as_dirs="'$as_qdir' $as_dirs"
      as_dir=`$as_dirname -- "$as_dir" ||
$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
	 X"$as_dir" : 'X\(//\)[^/]' \| \
	 X"$as_dir" : 'X\(//\)$' \| \
	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
$as_echo X"$as_dir" |
    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)[^/].*/{
	    s//\1/
	    q
	  }
	  /^X\(\/\/\)$/{
	    s//\1/
	    q
	  }
	  /^X\(\/\).*/{
	    s//\1/
	    q
	  }
	  s/.*/./; q'`
      test -d "$as_dir" && break
    done
    test -z "$as_dirs" || eval "mkdir $as_dirs"
  } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
$as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
   { (exit 1); exit 1; }; }; }
    ac_builddir=.

case "$ac_dir" in
.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
*)
  ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
  # A ".." for each directory in $ac_dir_suffix.
  ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
  case $ac_top_builddir_sub in
  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
  esac ;;
esac
ac_abs_top_builddir=$ac_pwd
ac_abs_builddir=$ac_pwd$ac_dir_suffix
# for backward compatibility:
ac_top_builddir=$ac_top_build_prefix

case $srcdir in
  .)  # We are building in place.
    ac_srcdir=.
    ac_top_srcdir=$ac_top_builddir_sub
    ac_abs_top_srcdir=$ac_pwd ;;
  [\\/]* | ?:[\\/]* )  # Absolute name.
    ac_srcdir=$srcdir$ac_dir_suffix;
    ac_top_srcdir=$srcdir
    ac_abs_top_srcdir=$srcdir ;;
  *) # Relative name.
    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
    ac_top_srcdir=$ac_top_build_prefix$srcdir
    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
esac
ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix


    cd "$ac_dir"

    # Check for guested configure; otherwise get Cygnus style configure.
    if test -f "$ac_srcdir/configure.gnu"; then
      ac_sub_configure=$ac_srcdir/configure.gnu
    elif test -f "$ac_srcdir/configure"; then
      ac_sub_configure=$ac_srcdir/configure
    elif test -f "$ac_srcdir/configure.in"; then
      # This should be Cygnus configure.
      ac_sub_configure=$ac_aux_dir/configure
    else
      { $as_echo "$as_me:$LINENO: WARNING: no configuration information is in $ac_dir" >&5
$as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
      ac_sub_configure=
    fi

    # The recursion is here.
    if test -n "$ac_sub_configure"; then
      # Make the cache file name correct relative to the subdirectory.
      case $cache_file in
      [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
      *) # Relative name.
	ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
      esac

      { $as_echo "$as_me:$LINENO: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5
$as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
      # The eval makes quoting arguments work.
      eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
	   --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
	{ { $as_echo "$as_me:$LINENO: error: $ac_sub_configure failed for $ac_dir" >&5
$as_echo "$as_me: error: $ac_sub_configure failed for $ac_dir" >&2;}
   { (exit 1); exit 1; }; }
    fi

    cd "$ac_popdir"
  done
fi
if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
  { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
fi


cat <<_ACEOF

CC:            $CC
LD:            $LD
CPPFLAGS:      $CPPFLAGS
LLCPPFLAGS:    $LLCPPFLAGS
CFLAGS:        $CFLAGS
EXTRA_KCFLAGS: $EXTRA_KCFLAGS
LLCFLAGS:      $LLCFLAGS

Type 'make' to build Lustre.
_ACEOF

