OSDN Git Service

utime() is obsolescent in SUSv4
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Wed, 7 Oct 2009 17:42:09 +0000 (19:42 +0200)
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>
Thu, 8 Oct 2009 14:56:33 +0000 (16:56 +0200)
  LEGACY was removed for utimes() in SUSv4

Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
libc/sysdeps/linux/common/Makefile.in
libc/sysdeps/linux/common/utime.c
libc/sysdeps/linux/common/utimes.c

index c2584da..ec889ca 100644 (file)
@@ -55,6 +55,10 @@ ifneq ($(UCLIBC_HAS_ADVANCED_REALTIME),y)
 CSRC := $(filter-out posix_fadvise64.c posix_fadvise.c,$(CSRC))
 endif
 
+ifneq ($(UCLIBC_SUSV4_LEGACY),y)
+CSRC := $(filter-out utime.c,$(CSRC))
+endif
+
 ifneq ($(UCLIBC_HAS_EPOLL),y)
 CSRC := $(filter-out epoll.c,$(CSRC))
 endif
index a9f988a..c9fd1bf 100644 (file)
@@ -31,4 +31,5 @@ int utime(const char *file, const struct utimbuf *times)
        return utimes(file, times ? timevals : NULL);
 }
 #endif
+link_warning(utime, "the use of OBSOLESCENT `utime' is discouraged, use `utimes'")
 libc_hidden_def(utime)
index f4781e0..99d9202 100644 (file)
@@ -32,5 +32,4 @@ int utimes(const char *file, const struct timeval tvp[2])
        return utime(file, times);
 }
 #endif
-link_warning(utimes, "the use of LEGACY `utimes' is discouraged, use `utime'")
 libc_hidden_def(utimes)