]> granicus.if.org Git - postgresql/commitdiff
Undo autoconf 2.69's attempt to #define _DARWIN_USE_64_BIT_INODE.
authorTom Lane <tgl@sss.pgh.pa.us>
Sun, 29 Dec 2013 17:57:45 +0000 (12:57 -0500)
committerTom Lane <tgl@sss.pgh.pa.us>
Sun, 29 Dec 2013 17:57:56 +0000 (12:57 -0500)
Defining this symbol causes OS X 10.5 to use a buggy version of readdir(),
which can sometimes fail with EINVAL if the previously-fetched directory
entry has been deleted or renamed.  In later OS X versions that bug has
been repaired, but we still don't need the #define because it's on by
default.  So this is just an all-around bad idea, and we can do without it.

configure
configure.in
src/include/pg_config.h.in

index a9eed6b3940b25424b06c4e58d014cb6561877a5..f2bdf77030653bc08dd01f8d98fb70e2f7ab6fcc 100755 (executable)
--- a/configure
+++ b/configure
@@ -11092,6 +11092,11 @@ rm -rf conftest*
 
 fi
 
+   # Autoconf 2.69's AC_SYS_LARGEFILE believes it's a good idea to #define
+   # _DARWIN_USE_64_BIT_INODE, but it isn't: on OS X 10.5 that activates a
+   # bug that causes readdir() to sometimes return EINVAL.  On later OS X
+   # versions where the feature actually works, it's on by default anyway.
+
 fi
 
 # Check for largefile support (must be after AC_SYS_LARGEFILE)
index fbe2d40292c885c73853d22142951f33bca34341..832b3a3458cce5cfce0b7b506599f91f3835aa9b 100644 (file)
@@ -1205,6 +1205,11 @@ esac
 # defines can affect what is generated for that.
 if test "$PORTNAME" != "win32"; then
    AC_SYS_LARGEFILE
+   # Autoconf 2.69's AC_SYS_LARGEFILE believes it's a good idea to #define
+   # _DARWIN_USE_64_BIT_INODE, but it isn't: on OS X 10.5 that activates a
+   # bug that causes readdir() to sometimes return EINVAL.  On later OS X
+   # versions where the feature actually works, it's on by default anyway.
+   AH_VERBATIM([_DARWIN_USE_64_BIT_INODE],[])
 fi
 
 # Check for largefile support (must be after AC_SYS_LARGEFILE)
index 3ed286f36c540da0b80d0d7bd79b56a35a27b44d..64717dfcd41eae50ce970382874df57d5fb00301 100644 (file)
    XLOG_BLCKSZ). Changing XLOG_SEG_SIZE requires an initdb. */
 #undef XLOG_SEG_SIZE
 
-/* Enable large inode numbers on Mac OS X 10.5.  */
-#ifndef _DARWIN_USE_64_BIT_INODE
-# define _DARWIN_USE_64_BIT_INODE 1
-#endif
+
 
 /* Number of bits in a file offset, on hosts where this is settable. */
 #undef _FILE_OFFSET_BITS