Add CVS checkout update instructions.
[gnulib.git] / m4 / openat.m4
index 6d21bc4..43f46d0 100644 (file)
@@ -1,4 +1,4 @@
-#serial 14
+#serial 15
 # See if we need to use our replacement for Solaris' openat et al functions.
 
 dnl Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
@@ -10,7 +10,6 @@ dnl with or without modifications, as long as this notice is preserved.
 
 AC_DEFUN([gl_FUNC_OPENAT],
 [
-  AC_LIBOBJ([openat-die])
   AC_LIBOBJ([openat-proc])
   AC_REQUIRE([gl_USE_SYSTEM_EXTENSIONS])
   AC_CHECK_FUNCS_ONCE([lchmod])
@@ -24,7 +23,7 @@ AC_DEFUN([gl_FUNC_OPENAT],
       [Define to rpl_ if the openat replacement function should be used.])
     gl_PREREQ_OPENAT;;
   esac
-  AC_REQUIRE([gl_FUNC_FCHOWNAT])
+  gl_FUNC_FCHOWNAT
 ])
 
 # gl_FUNC_FCHOWNAT_DEREF_BUG([ACTION-IF-BUGGY[, ACTION-IF-NOT_BUGGY]])
@@ -38,6 +37,7 @@ AC_DEFUN([gl_FUNC_FCHOWNAT_DEREF_BUG],
      rm -f $gl_dangle
      # Arrange for deletion of the temporary file this test creates.
      ac_clean_files="$ac_clean_files $gl_dangle"
+     ln -s conftest.no-such $gl_dangle
      AC_RUN_IFELSE(
        [AC_LANG_SOURCE(
          [[
@@ -74,10 +74,7 @@ AC_DEFUN([gl_FUNC_FCHOWNAT],
 
   AC_CHECK_FUNC([fchownat], [have_fchownat=yes], [have_fchownat=no])
   if test $have_fchownat = yes; then
-    gl_FUNC_FCHOWNAT_DEREF_BUG([have_fchownat_bug=yes])
-    if test $have_fchownat_bug = no; then
-      use_replacement_fchownat=no
-    fi
+    gl_FUNC_FCHOWNAT_DEREF_BUG([], [use_replacement_fchownat=no])
   fi
 
   if test $use_replacement_fchownat = yes; then