This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
[PATCH 2/2] Feature test macros overhaul: tar.h
- From: Yaakov Selkowitz <yselkowi at redhat dot com>
- To: newlib at sourceware dot org
- Date: Sun, 3 Apr 2016 17:29:21 -0500
- Subject: [PATCH 2/2] Feature test macros overhaul: tar.h
- Authentication-results: sourceware.org; auth=none
- References: <1459722561-8612-1-git-send-email-yselkowi at redhat dot com>
TSVTX was marked XSI beginning with SUSv3, compare:
http://pubs.opengroup.org/onlinepubs/007908799/xsh/tar.h.html
http://pubs.opengroup.org/onlinepubs/009695399/basedefs/tar.h.html
http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/tar.h.html
Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
---
newlib/libc/include/tar.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/newlib/libc/include/tar.h b/newlib/libc/include/tar.h
index 07b06dd..36437fc 100644
--- a/newlib/libc/include/tar.h
+++ b/newlib/libc/include/tar.h
@@ -5,6 +5,8 @@
#ifndef _TAR_H
#define _TAR_H
+#include <sys/features.h>
+
/* General definitions */
#define TMAGIC "ustar" /* ustar plus null byte. */
#define TMAGLEN 6 /* Length of the above. */
@@ -25,7 +27,9 @@
/* Mode field bit definitions (octal) */
#define TSUID 04000 /* Set UID on execution. */
#define TSGID 02000 /* Set GID on execution. */
+#if __XSI_VISIBLE || __POSIX_VISIBLE < 200112
#define TSVTX 01000 /* On directories, restricted deletion flag. */
+#endif
#define TUREAD 00400 /* Read by owner. */
#define TUWRITE 00200 /* Write by owner. */
#define TUEXEC 00100 /* Execute/search by owner. */
--
2.7.4