summaryrefslogtreecommitdiff
path: root/m4/lstat.m4
diff options
context:
space:
mode:
authorClint Adams <schizo@debian.org>2009-05-06 21:22:27 -0400
committerClint Adams <schizo@debian.org>2009-05-06 21:22:27 -0400
commit47c0ab9528ec53e5a0a6e761ba3789055e048638 (patch)
tree98fff27a1e9260ee6a8b5597e780236173b28838 /m4/lstat.m4
parent635221dbdbbaa74dfbb1672cb802d136f8208a1f (diff)
Imported Upstream version 4.2
Diffstat (limited to 'm4/lstat.m4')
-rw-r--r--m4/lstat.m426
1 files changed, 26 insertions, 0 deletions
diff --git a/m4/lstat.m4 b/m4/lstat.m4
new file mode 100644
index 0000000..74c78fe
--- /dev/null
+++ b/m4/lstat.m4
@@ -0,0 +1,26 @@
+# serial 19
+
+# Copyright (C) 1997-2001, 2003-2009 Free Software Foundation, Inc.
+#
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+dnl From Jim Meyering.
+
+AC_DEFUN([gl_FUNC_LSTAT],
+[
+ AC_REQUIRE([gl_SYS_STAT_H_DEFAULTS])
+ dnl If lstat does not exist, the replacement <sys/stat.h> does
+ dnl "#define lstat stat", and lstat.c does not need to be compiled.
+ AC_CHECK_FUNCS_ONCE([lstat])
+ if test $ac_cv_func_lstat = yes; then
+ AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK
+ dnl Note: AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK does AC_LIBOBJ([lstat]).
+ if test $ac_cv_func_lstat_dereferences_slashed_symlink = no; then
+ REPLACE_LSTAT=1
+ fi
+ # Prerequisites of lib/lstat.c.
+ AC_REQUIRE([AC_C_INLINE])
+ fi
+])