Commits

Mark Dickinson  committed 1f69f28

Recorded merge of revisions 81077 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
r81077 | mark.dickinson | 2010-05-11 09:55:06 +0100 (Tue, 11 May 2010) | 3 lines

Issue #8510: Remove nested 'main' functions (causing failure) in 3 configure tests;
remove some unnecessary '#include "confdefs.h"' lines. Thanks Roumen Petrov.
........

  • Participants
  • Parent commits 8ac0f0d

Comments (0)

Files changed (2)

 #! /bin/sh
-# From configure.in Revision: 80728 .
+# From configure.in Revision: 80834 .
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by GNU Autoconf 2.65 for python 3.2.
 #
 int
 main ()
 {
-int main() { return 0; }
+
   ;
   return 0;
 }
            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
-
-int
-main ()
-{
-void f(int **x) {} int main() { double *x; f((int **) &x); return 0; }
+	       void f(int **x) {}
+int
+main ()
+{
+double *x; f((int **) &x);
   ;
   return 0;
 }
 int
 main ()
 {
-int main() { return 0; }
+
   ;
   return 0;
 }
 int
 main ()
 {
-int main() { return 0; }
+
   ;
   return 0;
 }
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
-#include "confdefs.h"
 #include <stdio.h>
 
 int
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
-#include "confdefs.h"
 #include <sys/file.h>
 
 int
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
-#include "confdefs.h"
 #include <unistd.h>
 
 int
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
-#include "confdefs.h"
 #include <netdb.h>
 
 int
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
-#include "confdefs.h"
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <netinet/in.h>
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
-#include "confdefs.h"
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <netinet/in.h>
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
 
-#include "confdefs.h"
 #include <unistd.h>
 #ifdef HAVE_GRP_H
 #include <grp.h>

File configure.in

      AC_CACHE_VAL(ac_cv_no_strict_aliasing,
        AC_COMPILE_IFELSE(
          [
-	   AC_LANG_PROGRAM([[]], [[int main() { return 0; }]])
+	   AC_LANG_PROGRAM([[]], [[]])
 	 ],[
 	   CC="$ac_save_cc -fstrict-aliasing"
            CFLAGS="$CFLAGS -Werror -Wstrict-aliasing"
            AC_COMPILE_IFELSE(
 	     [
-	       AC_LANG_PROGRAM([[]],
-	         [[void f(int **x) {} int main() { double *x; f((int **) &x); return 0; }]])
+	       AC_LANG_PROGRAM([[void f(int **x) {}]],
+	         [[double *x; f((int **) &x);]])
 	     ],[
 	       ac_cv_no_strict_aliasing=no
 	     ],[
 [ac_save_cc="$CC"
 CC="$CC -OPT:Olimit=0"
 AC_COMPILE_IFELSE(
-  [AC_LANG_PROGRAM([[]], [[int main() { return 0; }]])],
+  [AC_LANG_PROGRAM([[]], [[]])],
   [ac_cv_opt_olimit_ok=yes],
   [ac_cv_opt_olimit_ok=no]
   )
   [ac_save_cc="$CC"
   CC="$CC -Olimit 1500"
   AC_COMPILE_IFELSE(
-    [AC_LANG_PROGRAM([[]], [[int main() { return 0; }]])],
+    [AC_LANG_PROGRAM([[]], [[]])],
     [ac_cv_olimit_ok=yes],
     [ac_cv_olimit_ok=no]
     )
 
 AC_MSG_CHECKING(for ctermid_r)
 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
-#include "confdefs.h" 
 #include <stdio.h>
 ]], [[void* p = ctermid_r]])],
   [AC_DEFINE(HAVE_CTERMID_R, 1, Define if you have the 'ctermid_r' function.)
 
 AC_MSG_CHECKING(for flock)
 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
-#include "confdefs.h" 
 #include <sys/file.h>
 ]], [[void* p = flock]])],
   [AC_DEFINE(HAVE_FLOCK, 1, Define if you have the 'flock' function.)
 
 AC_MSG_CHECKING(for getpagesize)
 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
-#include "confdefs.h" 
 #include <unistd.h>
 ]], [[void* p = getpagesize]])],
   [AC_DEFINE(HAVE_GETPAGESIZE, 1, Define if you have the 'getpagesize' function.)
 
 AC_MSG_CHECKING(for hstrerror)
 AC_LINK_IFELSE([AC_LANG_PROGRAM([[
-#include "confdefs.h" 
 #include <netdb.h>
 ]], [[void* p = hstrerror; hstrerror(0)]])],
   [AC_DEFINE(HAVE_HSTRERROR, 1, Define if you have the 'hstrerror' function.)
 
 AC_MSG_CHECKING(for inet_aton)
 AC_LINK_IFELSE([AC_LANG_PROGRAM([[
-#include "confdefs.h" 
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <netinet/in.h>
 
 AC_MSG_CHECKING(for inet_pton)
 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
-#include "confdefs.h" 
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <netinet/in.h>
 # On some systems, setgroups is in unistd.h, on others, in grp.h
 AC_MSG_CHECKING(for setgroups)
 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
-#include "confdefs.h" 
 #include <unistd.h>
 #ifdef HAVE_GRP_H
 #include <grp.h>