X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=m4%2Funlinkat.m4;h=32cfbc1182221bfb4f577db0d0cb1bdb40a6277f;hb=5191b3546cfb6c163228c23f214e325ddf60d46f;hp=cf735baf2413b048613131d96252c7a90a4c8821;hpb=1602f0afed21be664fcf5c42d59db07cc22c56d6;p=gnulib.git diff --git a/m4/unlinkat.m4 b/m4/unlinkat.m4 index cf735baf2..32cfbc118 100644 --- a/m4/unlinkat.m4 +++ b/m4/unlinkat.m4 @@ -1,5 +1,5 @@ -# unlinkat.m4 serial 1 -dnl Copyright (C) 2004-2012 Free Software Foundation, Inc. +# unlinkat.m4 serial 2 +dnl Copyright (C) 2004-2013 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. @@ -16,15 +16,18 @@ AC_DEFUN([gl_FUNC_UNLINKAT], if test $ac_cv_func_unlinkat = no; then HAVE_UNLINKAT=0 else - if test $gl_cv_func_lstat_dereferences_slashed_symlink != yes; then - # Solaris 9 has *at functions, but uniformly mishandles trailing - # slash in all of them. - REPLACE_UNLINKAT=1 - else - # GNU/Hurd has unlinkat, but it has the same bug as unlink. - if test $REPLACE_UNLINK = 1; then + case "$gl_cv_func_lstat_dereferences_slashed_symlink" in + *no) + # Solaris 9 has *at functions, but uniformly mishandles trailing + # slash in all of them. REPLACE_UNLINKAT=1 - fi - fi + ;; + *) + # GNU/Hurd has unlinkat, but it has the same bug as unlink. + if test $REPLACE_UNLINK = 1; then + REPLACE_UNLINKAT=1 + fi + ;; + esac fi ])