[Fakeroot-commits] [SCM] fakeroot branch, master, updated. debian/1.14.3-200-gb232f8a

Kyle J. McKay mackyle at gmail.com
Tue Aug 23 13:03:42 UTC 2011


The following commit has been merged in the master branch:
commit e322e1c04e8419edf8e6391fbdede3bf2a9d4d49
Author: Kyle J. McKay <mackyle at gmail.com>
Date:   Thu May 26 05:43:47 2011 -0700

    For Mac OS X, only wrap fgetattrlist when present (10.6 or later)

diff --git a/configure.ac b/configure.ac
index 6261dfe..db1d01c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -274,7 +274,7 @@ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
   ])
 done
 
-AC_CHECK_FUNCS(fchmodat fchownat fstatat mkdirat mknodat openat renameat unlinkat lchmod)
+AC_CHECK_FUNCS(fchmodat fchownat fstatat mkdirat mknodat openat renameat unlinkat lchmod fgetattrlist)
 
 dnl find out how stat() etc are called. On linux systems, we really
 dnl need to wrap (IIRC):
diff --git a/libfakeroot.c b/libfakeroot.c
index ddde1cf..e12f740 100644
--- a/libfakeroot.c
+++ b/libfakeroot.c
@@ -1600,6 +1600,7 @@ getattrlist(const char *path, void *attrList, void *attrBuf,
   return 0;
 }
 
+#if HAVE_FGETATTRLIST
 #ifdef __LP64__
 int
 fgetattrlist(int fd, void *attrList, void *attrBuf,
@@ -1630,4 +1631,5 @@ fgetattrlist(int fd, void *attrList, void *attrBuf,
 
   return 0;
 }
+#endif /* if HAVE_FGETATTRLIST */
 #endif /* ifdef __APPLE__ */
diff --git a/wrapfunc.inp b/wrapfunc.inp
index dd3884e..4c11a5a 100644
--- a/wrapfunc.inp
+++ b/wrapfunc.inp
@@ -35,10 +35,14 @@ WRAP_FSTATAT64;int;FSTATAT64_ARG(int ver, int dir_fd, const char *path, struct s
 #ifdef __APPLE__
 #ifdef __LP64__
 getattrlist;int;(const char *path, void *attrList, void *attrBuf, size_t attrBufSize, unsigned int options);(path, attrList, attrBuf, attrBufSize, options)
+#ifdef HAVE_FGETATTRLIST
 fgetattrlist;int;(int fd, void *attrList, void *attrBuf, size_t attrBufSize, unsigned int options);(fd, attrList, attrBuf, attrBufSize, options)
+#endif
 #else
 getattrlist;int;(const char *path, void *attrList, void *attrBuf, size_t attrBufSize, unsigned long options);(path, attrList, attrBuf, attrBufSize, options)
+#ifdef HAVE_FGETATTRLIST
 fgetattrlist;int;(int fd, void *attrList, void *attrBuf, size_t attrBufSize, unsigned long options);(fd, attrList, attrBuf, attrBufSize, options)
+#endif
 getattrlist$UNIX2003;int;(const char *path, void *attrList, void *attrBuf, size_t attrBufSize, unsigned long options);(path, attrList, attrBuf, attrBufSize, options)
 #endif
 lstat$INODE64;int;(const char *file_name, struct stat *buf);(file_name, buf)

-- 
fakeroot



More information about the Fakeroot-commits mailing list