xref: /OK3568_Linux_fs/buildroot/package/attr/0001-build-with-older-GCCs.patch (revision 4882a59341e53eb6f0b4789bf948001014eff981)
1*4882a593SmuzhiyunFrom 3ac428794ea0f95c854166c9c0cffb0267c5e98b Mon Sep 17 00:00:00 2001
2*4882a593SmuzhiyunFrom: Hollis Blanchard <hollis_blanchard@mentor.com>
3*4882a593SmuzhiyunDate: Mon, 30 Jul 2018 14:17:21 -0700
4*4882a593SmuzhiyunSubject: [PATCH] Remove messages in "deprecated" gcc attributes
5*4882a593Smuzhiyun
6*4882a593SmuzhiyunGCC versions up through 4.4.7 (which is used in RHEL 6) do not accept
7*4882a593Smuzhiyunany argument for the deprecated attribute. GCC 4.5 and later say the
8*4882a593Smuzhiyun"msg" argument is optional. We don't need the messages during
9*4882a593SmuzhiyunBuildroot builds anyways.
10*4882a593Smuzhiyun
11*4882a593SmuzhiyunSigned-off-by: Hollis Blanchard <hollis_blanchard@mentor.com>
12*4882a593Smuzhiyun---
13*4882a593Smuzhiyun include/attributes.h | 20 ++++++++++----------
14*4882a593Smuzhiyun 1 file changed, 10 insertions(+), 10 deletions(-)
15*4882a593Smuzhiyun
16*4882a593Smuzhiyundiff --git a/include/attributes.h b/include/attributes.h
17*4882a593Smuzhiyunindex 14beb8f..23c39c8 100644
18*4882a593Smuzhiyun--- a/include/attributes.h
19*4882a593Smuzhiyun+++ b/include/attributes.h
20*4882a593Smuzhiyun@@ -127,10 +127,10 @@ typedef struct attr_multiop {
21*4882a593Smuzhiyun  */
22*4882a593Smuzhiyun EXPORT int attr_get (const char *__path, const char *__attrname,
23*4882a593Smuzhiyun 			char *__attrvalue, int *__valuelength, int __flags)
24*4882a593Smuzhiyun-	__attribute__ ((deprecated ("Use getxattr or lgetxattr instead")));
25*4882a593Smuzhiyun+	__attribute__ ((deprecated));
26*4882a593Smuzhiyun EXPORT int attr_getf (int __fd, const char *__attrname, char *__attrvalue,
27*4882a593Smuzhiyun 			int *__valuelength, int __flags)
28*4882a593Smuzhiyun-	__attribute__ ((deprecated ("Use fgetxattr instead")));
29*4882a593Smuzhiyun+	__attribute__ ((deprecated));
30*4882a593Smuzhiyun
31*4882a593Smuzhiyun /*
32*4882a593Smuzhiyun  * Set the value of an attribute, creating the attribute if necessary.
33*4882a593Smuzhiyun@@ -139,11 +139,11 @@ EXPORT int attr_getf (int __fd, const char *__attrname, char *__attrvalue,
34*4882a593Smuzhiyun EXPORT int attr_set (const char *__path, const char *__attrname,
35*4882a593Smuzhiyun 			const char *__attrvalue, const int __valuelength,
36*4882a593Smuzhiyun 			int __flags)
37*4882a593Smuzhiyun-	__attribute__ ((deprecated ("Use setxattr or lsetxattr instead")));
38*4882a593Smuzhiyun+	__attribute__ ((deprecated));
39*4882a593Smuzhiyun EXPORT int attr_setf (int __fd, const char *__attrname,
40*4882a593Smuzhiyun 			const char *__attrvalue, const int __valuelength,
41*4882a593Smuzhiyun 			int __flags)
42*4882a593Smuzhiyun-	__attribute__ ((deprecated ("Use fsetxattr instead")));
43*4882a593Smuzhiyun+	__attribute__ ((deprecated));
44*4882a593Smuzhiyun
45*4882a593Smuzhiyun /*
46*4882a593Smuzhiyun  * Remove an attribute.
47*4882a593Smuzhiyun@@ -151,9 +151,9 @@ EXPORT int attr_setf (int __fd, const char *__attrname,
48*4882a593Smuzhiyun  */
49*4882a593Smuzhiyun EXPORT int attr_remove (const char *__path, const char *__attrname,
50*4882a593Smuzhiyun 			int __flags)
51*4882a593Smuzhiyun-	__attribute__ ((deprecated ("Use removexattr or lremovexattr instead")));
52*4882a593Smuzhiyun+	__attribute__ ((deprecated));
53*4882a593Smuzhiyun EXPORT int attr_removef (int __fd, const char *__attrname, int __flags)
54*4882a593Smuzhiyun-	__attribute__ ((deprecated ("Use fremovexattr instead")));
55*4882a593Smuzhiyun+	__attribute__ ((deprecated));
56*4882a593Smuzhiyun
57*4882a593Smuzhiyun /*
58*4882a593Smuzhiyun  * List the names and sizes of the values of all the attributes of an object.
59*4882a593Smuzhiyun@@ -164,10 +164,10 @@ EXPORT int attr_removef (int __fd, const char *__attrname, int __flags)
60*4882a593Smuzhiyun  */
61*4882a593Smuzhiyun EXPORT int attr_list(const char *__path, char *__buffer, const int __buffersize,
62*4882a593Smuzhiyun 		int __flags, attrlist_cursor_t *__cursor)
63*4882a593Smuzhiyun-	__attribute__ ((deprecated ("Use listxattr or llistxattr instead")));
64*4882a593Smuzhiyun+	__attribute__ ((deprecated));
65*4882a593Smuzhiyun EXPORT int attr_listf(int __fd, char *__buffer, const int __buffersize,
66*4882a593Smuzhiyun 		int __flags, attrlist_cursor_t *__cursor)
67*4882a593Smuzhiyun-	__attribute__ ((deprecated ("Use flistxattr instead")));
68*4882a593Smuzhiyun+	__attribute__ ((deprecated));
69*4882a593Smuzhiyun
70*4882a593Smuzhiyun /*
71*4882a593Smuzhiyun  * Operate on multiple attributes of the same object simultaneously.
72*4882a593Smuzhiyun@@ -188,10 +188,10 @@ EXPORT int attr_listf(int __fd, char *__buffer, const int __buffersize,
73*4882a593Smuzhiyun  */
74*4882a593Smuzhiyun EXPORT int attr_multi (const char *__path, attr_multiop_t *__oplist,
75*4882a593Smuzhiyun 			int __count, int __flags)
76*4882a593Smuzhiyun-	__attribute__ ((deprecated ("Use getxattr, setxattr, listxattr, removexattr instead")));
77*4882a593Smuzhiyun+	__attribute__ ((deprecated));
78*4882a593Smuzhiyun EXPORT int attr_multif (int __fd, attr_multiop_t *__oplist,
79*4882a593Smuzhiyun 			int __count, int __flags)
80*4882a593Smuzhiyun-	__attribute__ ((deprecated ("Use getxattr, setxattr, listxattr, removexattr instead")));
81*4882a593Smuzhiyun+	__attribute__ ((deprecated));
82*4882a593Smuzhiyun
83*4882a593Smuzhiyun #ifdef __cplusplus
84*4882a593Smuzhiyun }
85*4882a593Smuzhiyun--
86*4882a593Smuzhiyun2.13.0
87*4882a593Smuzhiyun
88