Blame SOURCES/nvptx-tools-no-ptxas.patch

f56e54
--- nvptx-tools/configure.ac
f56e54
+++ nvptx-tools/configure.ac
f56e54
@@ -51,6 +51,7 @@ LIBS="$LIBS -lcuda"
f56e54
 AC_CHECK_FUNCS([[cuGetErrorName] [cuGetErrorString]])
f56e54
 AC_CHECK_DECLS([[cuGetErrorName], [cuGetErrorString]],
f56e54
   [], [], [[#include <cuda.h>]])
f56e54
+AC_CHECK_HEADERS(unistd.h sys/stat.h)
f56e54
 
f56e54
 AC_MSG_CHECKING([for extra programs to build requiring -lcuda])
f56e54
 NVPTX_RUN=
f56e54
--- nvptx-tools/include/libiberty.h
f56e54
+++ nvptx-tools/include/libiberty.h
f56e54
@@ -390,6 +390,17 @@ extern void hex_init (void);
f56e54
 /* Save files used for communication between processes.  */
f56e54
 #define PEX_SAVE_TEMPS		0x4
f56e54
 
f56e54
+/* Max number of alloca bytes per call before we must switch to malloc.
f56e54
+
f56e54
+   ?? Swiped from gnulib's regex_internal.h header.  Is this actually
f56e54
+   the case?  This number seems arbitrary, though sane.
f56e54
+
f56e54
+   The OS usually guarantees only one guard page at the bottom of the stack,
f56e54
+   and a page size can be as small as 4096 bytes.  So we cannot safely
f56e54
+   allocate anything larger than 4096 bytes.  Also care for the possibility
f56e54
+   of a few compiler-allocated temporary stack slots.  */
f56e54
+#define MAX_ALLOCA_SIZE	4032
f56e54
+
f56e54
 /* Prepare to execute one or more programs, with standard output of
f56e54
    each program fed to standard input of the next.
f56e54
    FLAGS	As above.
f56e54
--- nvptx-tools/nvptx-as.c
f56e54
+++ nvptx-tools/nvptx-as.c
f56e54
@@ -30,6 +30,9 @@
f56e54
 #include <string.h>
f56e54
 #include <wait.h>
f56e54
 #include <unistd.h>
f56e54
+#ifdef HAVE_SYS_STAT_H
f56e54
+#include <sys/stat.h>
f56e54
+#endif
f56e54
 #include <errno.h>
f56e54
 #define obstack_chunk_alloc malloc
f56e54
 #define obstack_chunk_free free
f56e54
@@ -42,6 +45,38 @@
f56e54
 
f56e54
 #include "version.h"
f56e54
 
f56e54
+#ifndef R_OK
f56e54
+#define R_OK 4
f56e54
+#define W_OK 2
f56e54
+#define X_OK 1
f56e54
+#endif
f56e54
+
f56e54
+#ifndef DIR_SEPARATOR
f56e54
+#  define DIR_SEPARATOR '/'
f56e54
+#endif
f56e54
+
f56e54
+#if defined (_WIN32) || defined (__MSDOS__) \
f56e54
+    || defined (__DJGPP__) || defined (__OS2__)
f56e54
+#  define HAVE_DOS_BASED_FILE_SYSTEM
f56e54
+#  define HAVE_HOST_EXECUTABLE_SUFFIX
f56e54
+#  define HOST_EXECUTABLE_SUFFIX ".exe"
f56e54
+#  ifndef DIR_SEPARATOR_2 
f56e54
+#    define DIR_SEPARATOR_2 '\\'
f56e54
+#  endif
f56e54
+#  define PATH_SEPARATOR ';'
f56e54
+#else
f56e54
+#  define PATH_SEPARATOR ':'
f56e54
+#endif
f56e54
+
f56e54
+#ifndef DIR_SEPARATOR_2
f56e54
+#  define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR)
f56e54
+#else
f56e54
+#  define IS_DIR_SEPARATOR(ch) \
f56e54
+	(((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2))
f56e54
+#endif
f56e54
+
f56e54
+#define DIR_UP ".."
f56e54
+
f56e54
 static const char *outname = NULL;
f56e54
 
f56e54
 static void __attribute__ ((format (printf, 1, 2)))
f56e54
@@ -816,7 +851,7 @@ traverse (void **slot, void *data)
f56e54
 }
f56e54
 
f56e54
 static void
f56e54
-process (FILE *in, FILE *out)
f56e54
+process (FILE *in, FILE *out, int verify, const char *outname)
f56e54
 {
f56e54
   symbol_table = htab_create (500, hash_string_hash, hash_string_eq,
f56e54
                               NULL);
f56e54
@@ -824,6 +859,18 @@ process (FILE *in, FILE *out)
f56e54
   const char *input = read_file (in);
f56e54
   Token *tok = tokenize (input);
f56e54
 
f56e54
+  /* By default, when ptxas is not in PATH, do minimalistic verification,
f56e54
+     just require that the first non-comment directive is .version.  */
f56e54
+  if (verify < 0)
f56e54
+    {
f56e54
+      size_t i;
f56e54
+      for (i = 0; tok[i].kind == K_comment; i++)
f56e54
+	;
f56e54
+      if (tok[i].kind != K_dotted || !is_keyword (&tok[i], "version"))
f56e54
+	fatal_error ("missing .version directive at start of file '%s'",
f56e54
+		     outname);
f56e54
+    }
f56e54
+
f56e54
   do
f56e54
     tok = parse_file (tok);
f56e54
   while (tok->kind);
f56e54
@@ -897,9 +944,83 @@ fork_execute (const char *prog, char *const *argv)
f56e54
   do_wait (prog, pex);
f56e54
 }
f56e54
 
f56e54
+/* Determine if progname is available in PATH.  */
f56e54
+static bool
f56e54
+program_available (const char *progname)
f56e54
+{
f56e54
+  char *temp = getenv ("PATH");
f56e54
+  if (temp)
f56e54
+    {
f56e54
+      char *startp, *endp, *nstore, *alloc_ptr = NULL;
f56e54
+      size_t prefixlen = strlen (temp) + 1;
f56e54
+      size_t len;
f56e54
+      if (prefixlen < 2)
f56e54
+	prefixlen = 2;
f56e54
+
f56e54
+      len = prefixlen + strlen (progname) + 1;
f56e54
+#ifdef HAVE_HOST_EXECUTABLE_SUFFIX
f56e54
+      len += strlen (HOST_EXECUTABLE_SUFFIX);
f56e54
+#endif
f56e54
+      if (len < MAX_ALLOCA_SIZE)
f56e54
+	nstore = (char *) alloca (len);
f56e54
+      else
f56e54
+	alloc_ptr = nstore = (char *) malloc (len);
f56e54
+
f56e54
+      startp = endp = temp;
f56e54
+      while (1)
f56e54
+	{
f56e54
+	  if (*endp == PATH_SEPARATOR || *endp == 0)
f56e54
+	    {
f56e54
+	      if (endp == startp)
f56e54
+		{
f56e54
+		  nstore[0] = '.';
f56e54
+		  nstore[1] = DIR_SEPARATOR;
f56e54
+		  nstore[2] = '\0';
f56e54
+		}
f56e54
+	      else
f56e54
+		{
f56e54
+		  memcpy (nstore, startp, endp - startp);
f56e54
+		  if (! IS_DIR_SEPARATOR (endp[-1]))
f56e54
+		    {
f56e54
+		      nstore[endp - startp] = DIR_SEPARATOR;
f56e54
+		      nstore[endp - startp + 1] = 0;
f56e54
+		    }
f56e54
+		  else
f56e54
+		    nstore[endp - startp] = 0;
f56e54
+		}
f56e54
+	      strcat (nstore, progname);
f56e54
+	      if (! access (nstore, X_OK)
f56e54
+#ifdef HAVE_HOST_EXECUTABLE_SUFFIX
f56e54
+		  || ! access (strcat (nstore, HOST_EXECUTABLE_SUFFIX), X_OK)
f56e54
+#endif
f56e54
+		 )
f56e54
+		{
f56e54
+#if defined (HAVE_SYS_STAT_H) && defined (S_ISREG)
f56e54
+		  struct stat st;
f56e54
+		  if (stat (nstore, &st) >= 0 && S_ISREG (st.st_mode))
f56e54
+#endif
f56e54
+		    {
f56e54
+		      free (alloc_ptr);
f56e54
+		      return true;
f56e54
+		    }
f56e54
+		}
f56e54
+
f56e54
+	      if (*endp == 0)
f56e54
+		break;
f56e54
+	      endp = startp = endp + 1;
f56e54
+	    }
f56e54
+	  else
f56e54
+	    endp++;
f56e54
+	}
f56e54
+      free (alloc_ptr);
f56e54
+    }
f56e54
+  return false;
f56e54
+}
f56e54
+
f56e54
 static struct option long_options[] = {
f56e54
   {"traditional-format",     no_argument, 0,  0 },
f56e54
   {"save-temps",  no_argument,       0,  0 },
f56e54
+  {"verify",  no_argument,       0,  0 },
f56e54
   {"no-verify",  no_argument,       0,  0 },
f56e54
   {"help", no_argument, 0, 'h' },
f56e54
   {"version", no_argument, 0, 'V' },
f56e54
@@ -912,7 +1033,7 @@ main (int argc, char **argv)
f56e54
   FILE *in = stdin;
f56e54
   FILE *out = stdout;
f56e54
   bool verbose __attribute__((unused)) = false;
f56e54
-  bool verify = true;
f56e54
+  int verify = -1;
f56e54
   const char *smver = "sm_30";
f56e54
 
f56e54
   int o;
f56e54
@@ -923,7 +1044,9 @@ main (int argc, char **argv)
f56e54
 	{
f56e54
 	case 0:
f56e54
 	  if (option_index == 2)
f56e54
-	    verify = false;
f56e54
+	    verify = 1;
f56e54
+	  else if (option_index == 3)
f56e54
+	    verify = 0;
f56e54
 	  break;
f56e54
 	case 'v':
f56e54
 	  verbose = true;
f56e54
@@ -948,7 +1071,8 @@ Usage: nvptx-none-as [option...] [asmfile]\n\
f56e54
 Options:\n\
f56e54
   -o FILE               Write output to FILE\n\
f56e54
   -v                    Be verbose\n\
f56e54
+  --verify              Do verify output is acceptable to ptxas\n\
f56e54
   --no-verify           Do not verify output is acceptable to ptxas\n\
f56e54
   --help                Print this help and exit\n\
f56e54
   --version             Print version number and exit\n\
f56e54
 \n\
f56e54
@@ -983,11 +1108,17 @@ This program has absolutely no warranty.\n",
f56e54
   if (!in)
f56e54
     fatal_error ("cannot open input ptx file");
f56e54
 
f56e54
-  process (in, out);
f56e54
-  if  (outname)
f56e54
+  if (outname == NULL)
f56e54
+    verify = 0;
f56e54
+  else if (verify == -1)
f56e54
+    if (program_available ("ptxas"))
f56e54
+      verify = 1;
f56e54
+
f56e54
+  process (in, out, verify, outname);
f56e54
+  if (outname)
f56e54
     fclose (out);
f56e54
 
f56e54
-  if (verify && outname)
f56e54
+  if (verify > 0)
f56e54
     {
f56e54
       struct obstack argv_obstack;
f56e54
       obstack_init (&argv_obstack);
f56e54
--- nvptx-tools/configure
f56e54
+++ nvptx-tools/configure
f56e54
@@ -168,7 +168,8 @@ test x\$exitcode = x0 || exit 1"
f56e54
   as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
f56e54
   as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
f56e54
   eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
f56e54
-  test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1"
f56e54
+  test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
f56e54
+test \$(( 1 + 1 )) = 2 || exit 1"
f56e54
   if (eval "$as_required") 2>/dev/null; then :
f56e54
   as_have_required=yes
f56e54
 else
f56e54
@@ -552,11 +553,50 @@ PACKAGE_URL=
f56e54
 
f56e54
 ac_unique_file="nvptx-tools"
f56e54
 ac_unique_file="nvptx-as.c"
f56e54
+# Factoring default headers for most tests.
f56e54
+ac_includes_default="\
f56e54
+#include <stdio.h>
f56e54
+#ifdef HAVE_SYS_TYPES_H
f56e54
+# include <sys/types.h>
f56e54
+#endif
f56e54
+#ifdef HAVE_SYS_STAT_H
f56e54
+# include <sys/stat.h>
f56e54
+#endif
f56e54
+#ifdef STDC_HEADERS
f56e54
+# include <stdlib.h>
f56e54
+# include <stddef.h>
f56e54
+#else
f56e54
+# ifdef HAVE_STDLIB_H
f56e54
+#  include <stdlib.h>
f56e54
+# endif
f56e54
+#endif
f56e54
+#ifdef HAVE_STRING_H
f56e54
+# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
f56e54
+#  include <memory.h>
f56e54
+# endif
f56e54
+# include <string.h>
f56e54
+#endif
f56e54
+#ifdef HAVE_STRINGS_H
f56e54
+# include <strings.h>
f56e54
+#endif
f56e54
+#ifdef HAVE_INTTYPES_H
f56e54
+# include <inttypes.h>
f56e54
+#endif
f56e54
+#ifdef HAVE_STDINT_H
f56e54
+# include <stdint.h>
f56e54
+#endif
f56e54
+#ifdef HAVE_UNISTD_H
f56e54
+# include <unistd.h>
f56e54
+#endif"
f56e54
+
f56e54
 enable_option_checking=no
f56e54
 ac_subst_vars='LTLIBOBJS
f56e54
 LIBOBJS
f56e54
 subdirs
f56e54
 NVPTX_RUN
f56e54
+EGREP
f56e54
+GREP
f56e54
+CPP
f56e54
 CUDA_DRIVER_LDFLAGS
f56e54
 CUDA_DRIVER_CPPFLAGS
f56e54
 AR
f56e54
@@ -635,7 +675,8 @@ LIBS
f56e54
 CPPFLAGS
f56e54
 CXX
f56e54
 CXXFLAGS
f56e54
-CCC'
f56e54
+CCC
f56e54
+CPP'
f56e54
 ac_subdirs_all='libiberty'
f56e54
 
f56e54
 # Initialize some variables set by options.
f56e54
@@ -1267,6 +1308,7 @@ Some influential environment variables:
f56e54
               you have headers in a nonstandard directory <include dir>
f56e54
   CXX         C++ compiler command
f56e54
   CXXFLAGS    C++ compiler flags
f56e54
+  CPP         C preprocessor
f56e54
 
f56e54
 Use these variables to override the choices made by `configure' or to help
f56e54
 it to find libraries and programs with nonstandard names/locations.
f56e54
@@ -1575,6 +1617,203 @@ $as_echo "$ac_res" >&6; }
f56e54
   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
f56e54
 
f56e54
 } # ac_fn_c_check_decl
f56e54
+
f56e54
+# ac_fn_c_try_cpp LINENO
f56e54
+# ----------------------
f56e54
+# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
f56e54
+ac_fn_c_try_cpp ()
f56e54
+{
f56e54
+  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
f56e54
+  if { { ac_try="$ac_cpp conftest.$ac_ext"
f56e54
+case "(($ac_try" in
f56e54
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
f56e54
+  *) ac_try_echo=$ac_try;;
f56e54
+esac
f56e54
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
f56e54
+$as_echo "$ac_try_echo"; } >&5
f56e54
+  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
f56e54
+  ac_status=$?
f56e54
+  if test -s conftest.err; then
f56e54
+    grep -v '^ *+' conftest.err >conftest.er1
f56e54
+    cat conftest.er1 >&5
f56e54
+    mv -f conftest.er1 conftest.err
f56e54
+  fi
f56e54
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
f56e54
+  test $ac_status = 0; } >/dev/null && {
f56e54
+	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
f56e54
+	 test ! -s conftest.err
f56e54
+       }; then :
f56e54
+  ac_retval=0
f56e54
+else
f56e54
+  $as_echo "$as_me: failed program was:" >&5
f56e54
+sed 's/^/| /' conftest.$ac_ext >&5
f56e54
+
f56e54
+    ac_retval=1
f56e54
+fi
f56e54
+  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
f56e54
+  return $ac_retval
f56e54
+
f56e54
+} # ac_fn_c_try_cpp
f56e54
+
f56e54
+# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
f56e54
+# -------------------------------------------------------
f56e54
+# Tests whether HEADER exists, giving a warning if it cannot be compiled using
f56e54
+# the include files in INCLUDES and setting the cache variable VAR
f56e54
+# accordingly.
f56e54
+ac_fn_c_check_header_mongrel ()
f56e54
+{
f56e54
+  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
f56e54
+  if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
f56e54
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
f56e54
+$as_echo_n "checking for $2... " >&6; }
f56e54
+if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
f56e54
+  $as_echo_n "(cached) " >&6
f56e54
+fi
f56e54
+eval ac_res=\$$3
f56e54
+	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
f56e54
+$as_echo "$ac_res" >&6; }
f56e54
+else
f56e54
+  # Is the header compilable?
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
f56e54
+$as_echo_n "checking $2 usability... " >&6; }
f56e54
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f56e54
+/* end confdefs.h.  */
f56e54
+$4
f56e54
+#include <$2>
f56e54
+_ACEOF
f56e54
+if ac_fn_c_try_compile "$LINENO"; then :
f56e54
+  ac_header_compiler=yes
f56e54
+else
f56e54
+  ac_header_compiler=no
f56e54
+fi
f56e54
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
f56e54
+$as_echo "$ac_header_compiler" >&6; }
f56e54
+
f56e54
+# Is the header present?
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
f56e54
+$as_echo_n "checking $2 presence... " >&6; }
f56e54
+cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f56e54
+/* end confdefs.h.  */
f56e54
+#include <$2>
f56e54
+_ACEOF
f56e54
+if ac_fn_c_try_cpp "$LINENO"; then :
f56e54
+  ac_header_preproc=yes
f56e54
+else
f56e54
+  ac_header_preproc=no
f56e54
+fi
f56e54
+rm -f conftest.err conftest.$ac_ext
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
f56e54
+$as_echo "$ac_header_preproc" >&6; }
f56e54
+
f56e54
+# So?  What about this header?
f56e54
+case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
f56e54
+  yes:no: )
f56e54
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
f56e54
+$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
f56e54
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
f56e54
+$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
f56e54
+    ;;
f56e54
+  no:yes:* )
f56e54
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
f56e54
+$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
f56e54
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
f56e54
+$as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
f56e54
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
f56e54
+$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
f56e54
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
f56e54
+$as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
f56e54
+    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
f56e54
+$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
f56e54
+    ;;
f56e54
+esac
f56e54
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
f56e54
+$as_echo_n "checking for $2... " >&6; }
f56e54
+if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
f56e54
+  $as_echo_n "(cached) " >&6
f56e54
+else
f56e54
+  eval "$3=\$ac_header_compiler"
f56e54
+fi
f56e54
+eval ac_res=\$$3
f56e54
+	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
f56e54
+$as_echo "$ac_res" >&6; }
f56e54
+fi
f56e54
+  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
f56e54
+
f56e54
+} # ac_fn_c_check_header_mongrel
f56e54
+
f56e54
+# ac_fn_c_try_run LINENO
f56e54
+# ----------------------
f56e54
+# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
f56e54
+# that executables *can* be run.
f56e54
+ac_fn_c_try_run ()
f56e54
+{
f56e54
+  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
f56e54
+  if { { ac_try="$ac_link"
f56e54
+case "(($ac_try" in
f56e54
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
f56e54
+  *) ac_try_echo=$ac_try;;
f56e54
+esac
f56e54
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
f56e54
+$as_echo "$ac_try_echo"; } >&5
f56e54
+  (eval "$ac_link") 2>&5
f56e54
+  ac_status=$?
f56e54
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
f56e54
+  test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
f56e54
+  { { case "(($ac_try" in
f56e54
+  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
f56e54
+  *) ac_try_echo=$ac_try;;
f56e54
+esac
f56e54
+eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
f56e54
+$as_echo "$ac_try_echo"; } >&5
f56e54
+  (eval "$ac_try") 2>&5
f56e54
+  ac_status=$?
f56e54
+  $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
f56e54
+  test $ac_status = 0; }; }; then :
f56e54
+  ac_retval=0
f56e54
+else
f56e54
+  $as_echo "$as_me: program exited with status $ac_status" >&5
f56e54
+       $as_echo "$as_me: failed program was:" >&5
f56e54
+sed 's/^/| /' conftest.$ac_ext >&5
f56e54
+
f56e54
+       ac_retval=$ac_status
f56e54
+fi
f56e54
+  rm -rf conftest.dSYM conftest_ipa8_conftest.oo
f56e54
+  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
f56e54
+  return $ac_retval
f56e54
+
f56e54
+} # ac_fn_c_try_run
f56e54
+
f56e54
+# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
f56e54
+# -------------------------------------------------------
f56e54
+# Tests whether HEADER exists and can be compiled using the include files in
f56e54
+# INCLUDES, setting the cache variable VAR accordingly.
f56e54
+ac_fn_c_check_header_compile ()
f56e54
+{
f56e54
+  as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
f56e54
+  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
f56e54
+$as_echo_n "checking for $2... " >&6; }
f56e54
+if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
f56e54
+  $as_echo_n "(cached) " >&6
f56e54
+else
f56e54
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f56e54
+/* end confdefs.h.  */
f56e54
+$4
f56e54
+#include <$2>
f56e54
+_ACEOF
f56e54
+if ac_fn_c_try_compile "$LINENO"; then :
f56e54
+  eval "$3=yes"
f56e54
+else
f56e54
+  eval "$3=no"
f56e54
+fi
f56e54
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
f56e54
+fi
f56e54
+eval ac_res=\$$3
f56e54
+	       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
f56e54
+$as_echo "$ac_res" >&6; }
f56e54
+  eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
f56e54
+
f56e54
+} # ac_fn_c_check_header_compile
f56e54
 cat >config.log <<_ACEOF
f56e54
 This file contains any messages produced by compilers while
f56e54
 running configure, to aid debugging if configure makes a mistake.
f56e54
@@ -3284,6 +3523,418 @@ cat >>confdefs.h <<_ACEOF
f56e54
 #define HAVE_DECL_CUGETERRORSTRING $ac_have_decl
f56e54
 _ACEOF
f56e54
 
f56e54
+ac_ext=c
f56e54
+ac_cpp='$CPP $CPPFLAGS'
f56e54
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
f56e54
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
f56e54
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
f56e54
+$as_echo_n "checking how to run the C preprocessor... " >&6; }
f56e54
+# On Suns, sometimes $CPP names a directory.
f56e54
+if test -n "$CPP" && test -d "$CPP"; then
f56e54
+  CPP=
f56e54
+fi
f56e54
+if test -z "$CPP"; then
f56e54
+  if test "${ac_cv_prog_CPP+set}" = set; then :
f56e54
+  $as_echo_n "(cached) " >&6
f56e54
+else
f56e54
+      # Double quotes because CPP needs to be expanded
f56e54
+    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
f56e54
+    do
f56e54
+      ac_preproc_ok=false
f56e54
+for ac_c_preproc_warn_flag in '' yes
f56e54
+do
f56e54
+  # Use a header file that comes with gcc, so configuring glibc
f56e54
+  # with a fresh cross-compiler works.
f56e54
+  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
f56e54
+  # <limits.h> exists even on freestanding compilers.
f56e54
+  # On the NeXT, cc -E runs the code through the compiler's parser,
f56e54
+  # not just through cpp. "Syntax error" is here to catch this case.
f56e54
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f56e54
+/* end confdefs.h.  */
f56e54
+#ifdef __STDC__
f56e54
+# include <limits.h>
f56e54
+#else
f56e54
+# include <assert.h>
f56e54
+#endif
f56e54
+		     Syntax error
f56e54
+_ACEOF
f56e54
+if ac_fn_c_try_cpp "$LINENO"; then :
f56e54
+
f56e54
+else
f56e54
+  # Broken: fails on valid input.
f56e54
+continue
f56e54
+fi
f56e54
+rm -f conftest.err conftest.$ac_ext
f56e54
+
f56e54
+  # OK, works on sane cases.  Now check whether nonexistent headers
f56e54
+  # can be detected and how.
f56e54
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f56e54
+/* end confdefs.h.  */
f56e54
+#include <ac_nonexistent.h>
f56e54
+_ACEOF
f56e54
+if ac_fn_c_try_cpp "$LINENO"; then :
f56e54
+  # Broken: success on invalid input.
f56e54
+continue
f56e54
+else
f56e54
+  # Passes both tests.
f56e54
+ac_preproc_ok=:
f56e54
+break
f56e54
+fi
f56e54
+rm -f conftest.err conftest.$ac_ext
f56e54
+
f56e54
+done
f56e54
+# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
f56e54
+rm -f conftest.err conftest.$ac_ext
f56e54
+if $ac_preproc_ok; then :
f56e54
+  break
f56e54
+fi
f56e54
+
f56e54
+    done
f56e54
+    ac_cv_prog_CPP=$CPP
f56e54
+
f56e54
+fi
f56e54
+  CPP=$ac_cv_prog_CPP
f56e54
+else
f56e54
+  ac_cv_prog_CPP=$CPP
f56e54
+fi
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
f56e54
+$as_echo "$CPP" >&6; }
f56e54
+ac_preproc_ok=false
f56e54
+for ac_c_preproc_warn_flag in '' yes
f56e54
+do
f56e54
+  # Use a header file that comes with gcc, so configuring glibc
f56e54
+  # with a fresh cross-compiler works.
f56e54
+  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
f56e54
+  # <limits.h> exists even on freestanding compilers.
f56e54
+  # On the NeXT, cc -E runs the code through the compiler's parser,
f56e54
+  # not just through cpp. "Syntax error" is here to catch this case.
f56e54
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f56e54
+/* end confdefs.h.  */
f56e54
+#ifdef __STDC__
f56e54
+# include <limits.h>
f56e54
+#else
f56e54
+# include <assert.h>
f56e54
+#endif
f56e54
+		     Syntax error
f56e54
+_ACEOF
f56e54
+if ac_fn_c_try_cpp "$LINENO"; then :
f56e54
+
f56e54
+else
f56e54
+  # Broken: fails on valid input.
f56e54
+continue
f56e54
+fi
f56e54
+rm -f conftest.err conftest.$ac_ext
f56e54
+
f56e54
+  # OK, works on sane cases.  Now check whether nonexistent headers
f56e54
+  # can be detected and how.
f56e54
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f56e54
+/* end confdefs.h.  */
f56e54
+#include <ac_nonexistent.h>
f56e54
+_ACEOF
f56e54
+if ac_fn_c_try_cpp "$LINENO"; then :
f56e54
+  # Broken: success on invalid input.
f56e54
+continue
f56e54
+else
f56e54
+  # Passes both tests.
f56e54
+ac_preproc_ok=:
f56e54
+break
f56e54
+fi
f56e54
+rm -f conftest.err conftest.$ac_ext
f56e54
+
f56e54
+done
f56e54
+# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
f56e54
+rm -f conftest.err conftest.$ac_ext
f56e54
+if $ac_preproc_ok; then :
f56e54
+
f56e54
+else
f56e54
+  { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
f56e54
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
f56e54
+as_fn_error "C preprocessor \"$CPP\" fails sanity check
f56e54
+See \`config.log' for more details." "$LINENO" 5; }
f56e54
+fi
f56e54
+
f56e54
+ac_ext=c
f56e54
+ac_cpp='$CPP $CPPFLAGS'
f56e54
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
f56e54
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
f56e54
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
f56e54
+
f56e54
+
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
f56e54
+$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
f56e54
+if test "${ac_cv_path_GREP+set}" = set; then :
f56e54
+  $as_echo_n "(cached) " >&6
f56e54
+else
f56e54
+  if test -z "$GREP"; then
f56e54
+  ac_path_GREP_found=false
f56e54
+  # Loop through the user's path and test for each of PROGNAME-LIST
f56e54
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
f56e54
+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
f56e54
+do
f56e54
+  IFS=$as_save_IFS
f56e54
+  test -z "$as_dir" && as_dir=.
f56e54
+    for ac_prog in grep ggrep; do
f56e54
+    for ac_exec_ext in '' $ac_executable_extensions; do
f56e54
+      ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
f56e54
+      { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
f56e54
+# Check for GNU ac_path_GREP and select it if it is found.
f56e54
+  # Check for GNU $ac_path_GREP
f56e54
+case `"$ac_path_GREP" --version 2>&1` in
f56e54
+*GNU*)
f56e54
+  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
f56e54
+*)
f56e54
+  ac_count=0
f56e54
+  $as_echo_n 0123456789 >"conftest.in"
f56e54
+  while :
f56e54
+  do
f56e54
+    cat "conftest.in" "conftest.in" >"conftest.tmp"
f56e54
+    mv "conftest.tmp" "conftest.in"
f56e54
+    cp "conftest.in" "conftest.nl"
f56e54
+    $as_echo 'GREP' >> "conftest.nl"
f56e54
+    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
f56e54
+    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
f56e54
+    as_fn_arith $ac_count + 1 && ac_count=$as_val
f56e54
+    if test $ac_count -gt ${ac_path_GREP_max-0}; then
f56e54
+      # Best one so far, save it but keep looking for a better one
f56e54
+      ac_cv_path_GREP="$ac_path_GREP"
f56e54
+      ac_path_GREP_max=$ac_count
f56e54
+    fi
f56e54
+    # 10*(2^10) chars as input seems more than enough
f56e54
+    test $ac_count -gt 10 && break
f56e54
+  done
f56e54
+  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
f56e54
+esac
f56e54
+
f56e54
+      $ac_path_GREP_found && break 3
f56e54
+    done
f56e54
+  done
f56e54
+  done
f56e54
+IFS=$as_save_IFS
f56e54
+  if test -z "$ac_cv_path_GREP"; then
f56e54
+    as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
f56e54
+  fi
f56e54
+else
f56e54
+  ac_cv_path_GREP=$GREP
f56e54
+fi
f56e54
+
f56e54
+fi
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
f56e54
+$as_echo "$ac_cv_path_GREP" >&6; }
f56e54
+ GREP="$ac_cv_path_GREP"
f56e54
+
f56e54
+
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
f56e54
+$as_echo_n "checking for egrep... " >&6; }
f56e54
+if test "${ac_cv_path_EGREP+set}" = set; then :
f56e54
+  $as_echo_n "(cached) " >&6
f56e54
+else
f56e54
+  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
f56e54
+   then ac_cv_path_EGREP="$GREP -E"
f56e54
+   else
f56e54
+     if test -z "$EGREP"; then
f56e54
+  ac_path_EGREP_found=false
f56e54
+  # Loop through the user's path and test for each of PROGNAME-LIST
f56e54
+  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
f56e54
+for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
f56e54
+do
f56e54
+  IFS=$as_save_IFS
f56e54
+  test -z "$as_dir" && as_dir=.
f56e54
+    for ac_prog in egrep; do
f56e54
+    for ac_exec_ext in '' $ac_executable_extensions; do
f56e54
+      ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
f56e54
+      { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
f56e54
+# Check for GNU ac_path_EGREP and select it if it is found.
f56e54
+  # Check for GNU $ac_path_EGREP
f56e54
+case `"$ac_path_EGREP" --version 2>&1` in
f56e54
+*GNU*)
f56e54
+  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
f56e54
+*)
f56e54
+  ac_count=0
f56e54
+  $as_echo_n 0123456789 >"conftest.in"
f56e54
+  while :
f56e54
+  do
f56e54
+    cat "conftest.in" "conftest.in" >"conftest.tmp"
f56e54
+    mv "conftest.tmp" "conftest.in"
f56e54
+    cp "conftest.in" "conftest.nl"
f56e54
+    $as_echo 'EGREP' >> "conftest.nl"
f56e54
+    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
f56e54
+    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
f56e54
+    as_fn_arith $ac_count + 1 && ac_count=$as_val
f56e54
+    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
f56e54
+      # Best one so far, save it but keep looking for a better one
f56e54
+      ac_cv_path_EGREP="$ac_path_EGREP"
f56e54
+      ac_path_EGREP_max=$ac_count
f56e54
+    fi
f56e54
+    # 10*(2^10) chars as input seems more than enough
f56e54
+    test $ac_count -gt 10 && break
f56e54
+  done
f56e54
+  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
f56e54
+esac
f56e54
+
f56e54
+      $ac_path_EGREP_found && break 3
f56e54
+    done
f56e54
+  done
f56e54
+  done
f56e54
+IFS=$as_save_IFS
f56e54
+  if test -z "$ac_cv_path_EGREP"; then
f56e54
+    as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
f56e54
+  fi
f56e54
+else
f56e54
+  ac_cv_path_EGREP=$EGREP
f56e54
+fi
f56e54
+
f56e54
+   fi
f56e54
+fi
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
f56e54
+$as_echo "$ac_cv_path_EGREP" >&6; }
f56e54
+ EGREP="$ac_cv_path_EGREP"
f56e54
+
f56e54
+
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
f56e54
+$as_echo_n "checking for ANSI C header files... " >&6; }
f56e54
+if test "${ac_cv_header_stdc+set}" = set; then :
f56e54
+  $as_echo_n "(cached) " >&6
f56e54
+else
f56e54
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f56e54
+/* end confdefs.h.  */
f56e54
+#include <stdlib.h>
f56e54
+#include <stdarg.h>
f56e54
+#include <string.h>
f56e54
+#include <float.h>
f56e54
+
f56e54
+int
f56e54
+main ()
f56e54
+{
f56e54
+
f56e54
+  ;
f56e54
+  return 0;
f56e54
+}
f56e54
+_ACEOF
f56e54
+if ac_fn_c_try_compile "$LINENO"; then :
f56e54
+  ac_cv_header_stdc=yes
f56e54
+else
f56e54
+  ac_cv_header_stdc=no
f56e54
+fi
f56e54
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
f56e54
+
f56e54
+if test $ac_cv_header_stdc = yes; then
f56e54
+  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
f56e54
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f56e54
+/* end confdefs.h.  */
f56e54
+#include <string.h>
f56e54
+
f56e54
+_ACEOF
f56e54
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
f56e54
+  $EGREP "memchr" >/dev/null 2>&1; then :
f56e54
+
f56e54
+else
f56e54
+  ac_cv_header_stdc=no
f56e54
+fi
f56e54
+rm -f conftest*
f56e54
+
f56e54
+fi
f56e54
+
f56e54
+if test $ac_cv_header_stdc = yes; then
f56e54
+  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
f56e54
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f56e54
+/* end confdefs.h.  */
f56e54
+#include <stdlib.h>
f56e54
+
f56e54
+_ACEOF
f56e54
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
f56e54
+  $EGREP "free" >/dev/null 2>&1; then :
f56e54
+
f56e54
+else
f56e54
+  ac_cv_header_stdc=no
f56e54
+fi
f56e54
+rm -f conftest*
f56e54
+
f56e54
+fi
f56e54
+
f56e54
+if test $ac_cv_header_stdc = yes; then
f56e54
+  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
f56e54
+  if test "$cross_compiling" = yes; then :
f56e54
+  :
f56e54
+else
f56e54
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
f56e54
+/* end confdefs.h.  */
f56e54
+#include <ctype.h>
f56e54
+#include <stdlib.h>
f56e54
+#if ((' ' & 0x0FF) == 0x020)
f56e54
+# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
f56e54
+# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
f56e54
+#else
f56e54
+# define ISLOWER(c) \
f56e54
+		   (('a' <= (c) && (c) <= 'i') \
f56e54
+		     || ('j' <= (c) && (c) <= 'r') \
f56e54
+		     || ('s' <= (c) && (c) <= 'z'))
f56e54
+# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
f56e54
+#endif
f56e54
+
f56e54
+#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
f56e54
+int
f56e54
+main ()
f56e54
+{
f56e54
+  int i;
f56e54
+  for (i = 0; i < 256; i++)
f56e54
+    if (XOR (islower (i), ISLOWER (i))
f56e54
+	|| toupper (i) != TOUPPER (i))
f56e54
+      return 2;
f56e54
+  return 0;
f56e54
+}
f56e54
+_ACEOF
f56e54
+if ac_fn_c_try_run "$LINENO"; then :
f56e54
+
f56e54
+else
f56e54
+  ac_cv_header_stdc=no
f56e54
+fi
f56e54
+rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
f56e54
+  conftest.$ac_objext conftest.beam conftest.$ac_ext
f56e54
+fi
f56e54
+
f56e54
+fi
f56e54
+fi
f56e54
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
f56e54
+$as_echo "$ac_cv_header_stdc" >&6; }
f56e54
+if test $ac_cv_header_stdc = yes; then
f56e54
+
f56e54
+$as_echo "#define STDC_HEADERS 1" >>confdefs.h
f56e54
+
f56e54
+fi
f56e54
+
f56e54
+# On IRIX 5.3, sys/types and inttypes.h are conflicting.
f56e54
+for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
f56e54
+		  inttypes.h stdint.h unistd.h
f56e54
+do :
f56e54
+  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
f56e54
+ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
f56e54
+"
f56e54
+eval as_val=\$$as_ac_Header
f56e54
+   if test "x$as_val" = x""yes; then :
f56e54
+  cat >>confdefs.h <<_ACEOF
f56e54
+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
f56e54
+_ACEOF
f56e54
+
f56e54
+fi
f56e54
+
f56e54
+done
f56e54
+
f56e54
+
f56e54
+for ac_header in unistd.h sys/stat.h
f56e54
+do :
f56e54
+  as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
f56e54
+ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
f56e54
+eval as_val=\$$as_ac_Header
f56e54
+   if test "x$as_val" = x""yes; then :
f56e54
+  cat >>confdefs.h <<_ACEOF
f56e54
+#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
f56e54
+_ACEOF
f56e54
+
f56e54
+fi
f56e54
+
f56e54
+done
f56e54
+
f56e54
 
f56e54
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra programs to build requiring -lcuda" >&5
f56e54
 $as_echo_n "checking for extra programs to build requiring -lcuda... " >&6; }