Blob Blame History Raw
diff -rupN Python-2.7.13/configure.ac Python-2.7.13-new/configure.ac
--- Python-2.7.13/configure.ac	2017-01-21 01:46:04.950624168 +0100
+++ Python-2.7.13-new/configure.ac	2017-01-21 01:46:04.953624136 +0100
@@ -1973,10 +1973,22 @@ AC_CHECK_SIZEOF(off_t, [], [
 ])
 
 AC_MSG_CHECKING(whether to enable large file support)
+have_largefile_support=no
 if test "$have_long_long" = yes
 then
 if test "$ac_cv_sizeof_off_t" -gt "$ac_cv_sizeof_long" -a \
 	"$ac_cv_sizeof_long_long" -ge "$ac_cv_sizeof_off_t"; then
+  have_largefile_support=yes
+else
+  case $host in
+  *-*-mingw*)
+    dnl Activate on windows platforms (32&64-bit) where off_t(4) < fpos_t(8)
+    have_largefile_support=yes
+    ;;
+  esac
+fi
+fi
+if test $have_largefile_support = yes ; then
   AC_DEFINE(HAVE_LARGEFILE_SUPPORT, 1, 
   [Defined to enable large file support when an off_t is bigger than a long
    and long long is available and at least as big as an off_t. You may need
@@ -1986,9 +1998,6 @@ if test "$ac_cv_sizeof_off_t" -gt "$ac_c
 else
   AC_MSG_RESULT(no)
 fi
-else
-  AC_MSG_RESULT(no)
-fi
 
 AC_CHECK_SIZEOF(time_t, [], [
 #ifdef HAVE_SYS_TYPES_H