Rename various spare fields in structs to include a namespace This should avoid accidental clashes with uses of the __unused symbol in upstream projects. eg currently it causes a compile error in dhcpcd 8.x and onwards due to their re-use of the __unused symbol as a macro
Recommend that in general continue to convert generic names to include the __uclibc_ prefix to namespace them. This follows the style of glibc which does something equivalent
signed-off-by: Ed Wildgoose lists@wildgooses.com
diff -ur libc/sysdeps/linux/alpha/bits/kernel_stat.h libc/sysdeps/linux/alpha/bits/kernel_stat.h --- a/libc/sysdeps/linux/alpha/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/alpha/bits/kernel_stat.h 2020-06-11 16:34:02.009197215 +0000 @@ -39,7 +39,7 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - long __unused[3]; + long __uclibc_unused[3]; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/alpha/bits/stat.h libc/sysdeps/linux/alpha/bits/stat.h --- a/libc/sysdeps/linux/alpha/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/alpha/bits/stat.h 2020-06-11 16:34:02.009197215 +0000 @@ -89,7 +89,7 @@ __ST_TIME(a); /* Time of last access. */ __ST_TIME(m); /* Time of last modification. */ __ST_TIME(c); /* Time of last status change. */ - long __unused[3]; + long __uclibc_unused[3]; };
#ifdef __USE_LARGEFILE64 @@ -110,7 +110,7 @@ __ST_TIME(a); /* Time of last access. */ __ST_TIME(m); /* Time of last modification. */ __ST_TIME(c); /* Time of last status change. */ - long __unused[3]; + long __uclibc_unused[3]; }; #endif
diff -ur libc/sysdeps/linux/arm/bits/kernel_stat.h libc/sysdeps/linux/arm/bits/kernel_stat.h --- a/libc/sysdeps/linux/arm/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/arm/bits/kernel_stat.h 2020-06-11 16:34:02.009197215 +0000 @@ -29,8 +29,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/avr32/bits/kernel_stat.h libc/sysdeps/linux/avr32/bits/kernel_stat.h --- a/libc/sysdeps/linux/avr32/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/avr32/bits/kernel_stat.h 2020-06-11 16:34:02.009197215 +0000 @@ -20,8 +20,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { @@ -46,8 +46,8 @@ struct timespec st_mtim; struct timespec st_ctim;
- unsigned long __unused1; - unsigned long __unused2; + unsigned long __uclibc_unused1; + unsigned long __uclibc_unused2; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/bfin/bits/kernel_stat.h libc/sysdeps/linux/bfin/bits/kernel_stat.h --- a/libc/sysdeps/linux/bfin/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/bfin/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -21,8 +21,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/c6x/bits/kernel_stat.h libc/sysdeps/linux/c6x/bits/kernel_stat.h --- a/libc/sysdeps/linux/c6x/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/c6x/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -21,8 +21,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
struct kernel_stat64 { @@ -41,8 +41,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/common/bits/stat.h libc/sysdeps/linux/common/bits/stat.h --- a/libc/sysdeps/linux/common/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/common/bits/stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -83,8 +83,8 @@ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif #ifndef __USE_FILE_OFFSET64 - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; #else __ino64_t st_ino; /* File serial number. */ #endif diff -ur libc/sysdeps/linux/common-generic/bits/stat.h libc/sysdeps/linux/common-generic/bits/stat.h --- a/libc/sysdeps/linux/common-generic/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/common-generic/bits/stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -68,8 +68,8 @@ int st_ctime; /* Time of last status change. */ unsigned int st_ctime_nsec; #endif - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; } __ARCH_64BIT_ALIGNMENT__;
@@ -106,8 +106,8 @@ int st_ctime; /* Time of last status change. */ unsigned int st_ctime_nsec; # endif - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; }; #endif
diff -ur libc/sysdeps/linux/cris/bits/kernel_stat.h libc/sysdeps/linux/cris/bits/kernel_stat.h --- a/libc/sysdeps/linux/cris/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/cris/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -19,8 +19,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
/* This matches struct kernel_stat64 in glibc2.1, hence the absolutely diff -ur libc/sysdeps/linux/csky/bits/kernel_stat.h libc/sysdeps/linux/csky/bits/kernel_stat.h --- a/libc/sysdeps/linux/csky/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/csky/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -34,8 +34,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/frv/bits/kernel_stat.h libc/sysdeps/linux/frv/bits/kernel_stat.h --- a/libc/sysdeps/linux/frv/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/frv/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -38,7 +38,7 @@ struct timespec st_mtim; struct timespec st_ctim;
- unsigned long long __unused4; + unsigned long long __uclibc_unused4; };
struct kernel_stat64 { @@ -68,7 +68,7 @@ struct timespec st_mtim; struct timespec st_ctim;
- unsigned long long __unused4; + unsigned long long __uclibc_unused4; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/frv/bits/stat.h libc/sysdeps/linux/frv/bits/stat.h --- a/libc/sysdeps/linux/frv/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/frv/bits/stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -84,16 +84,16 @@ # define st_mtime st_mtim.tv_sec # define st_ctime st_ctim.tv_sec #else - unsigned long int __unused1; + unsigned long int __uclibc_unused1; __time_t st_atime; /* Time of last access. */
- unsigned long int __unused2; + unsigned long int __uclibc_unused2; __time_t st_mtime; /* Time of last modification. */
- unsigned long int __unused3; + unsigned long int __uclibc_unused3; __time_t st_ctime; /* Time of last status change. */ #endif - unsigned long long __unused4; + unsigned long long __uclibc_unused4; };
#ifdef __USE_LARGEFILE64 @@ -131,16 +131,16 @@ # define st_mtime st_mtim.tv_sec # define st_ctime st_ctim.tv_sec #else - unsigned long int __unused1; + unsigned long int __uclibc_unused1; __time_t st_atime; /* Time of last access. */
- unsigned long int __unused2; + unsigned long int __uclibc_unused2; __time_t st_mtime; /* Time of last modification. */
- unsigned long int __unused3; + unsigned long int __uclibc_unused3; __time_t st_ctime; /* Time of last status change. */ #endif - unsigned long long __unused4; + unsigned long long __uclibc_unused4; }; #endif
diff -ur libc/sysdeps/linux/hppa/bits/kernel_stat.h libc/sysdeps/linux/hppa/bits/kernel_stat.h --- a/libc/sysdeps/linux/hppa/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/hppa/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -18,11 +18,11 @@ struct timespec st_ctim; int st_blksize; int st_blocks; - unsigned int __unused1; /* ACL stuff */ - unsigned int __unused2; /* network */ - ino_t __unused3; /* network */ - unsigned int __unused4; /* cnodes */ - unsigned short __unused5; /* netsite */ + unsigned int __uclibc_unused1; /* ACL stuff */ + unsigned int __uclibc_unused2; /* network */ + ino_t __uclibc_unused3; /* network */ + unsigned int __uclibc_unused4; /* cnodes */ + unsigned short __uclibc_unused5; /* netsite */ short st_fstype; unsigned int st_realdev; unsigned short st_basemode; diff -ur libc/sysdeps/linux/i386/bits/kernel_stat.h libc/sysdeps/linux/i386/bits/kernel_stat.h --- a/libc/sysdeps/linux/i386/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/i386/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -20,8 +20,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/ia64/bits/kernel_stat.h libc/sysdeps/linux/ia64/bits/kernel_stat.h --- a/libc/sysdeps/linux/ia64/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/ia64/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -24,7 +24,7 @@ struct timespec st_ctim; unsigned long st_blksize; long st_blocks; - unsigned long __unused[3]; + unsigned long __uclibc_unused[3]; };
/* ia64 stat64 is same as stat */ diff -ur libc/sysdeps/linux/ia64/bits/stat.h libc/sysdeps/linux/ia64/bits/stat.h --- a/libc/sysdeps/linux/ia64/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/ia64/bits/stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -61,7 +61,7 @@ #endif __blksize_t st_blksize; /* Optimal block size for I/O. */ __blkcnt_t st_blocks; /* Nr. 512-byte blocks allocated. */ - long int __unused[3]; + long int __uclibc_unused[3]; };
#ifdef __USE_LARGEFILE64 @@ -100,7 +100,7 @@ #endif __blksize_t st_blksize; /* Optimal block size for I/O. */ __blkcnt64_t st_blocks; /* Nr. 512-byte blocks allocated. */ - long int __unused[3]; + long int __uclibc_unused[3]; }; #endif
diff -ur libc/sysdeps/linux/lm32/bits/kernel_stat.h libc/sysdeps/linux/lm32/bits/kernel_stat.h --- a/libc/sysdeps/linux/lm32/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/lm32/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -22,8 +22,8 @@ struct timespec st_atim; /* Time of last access. */ struct timespec st_mtim; /* Time of last modification. */ struct timespec st_ctim; /* Time of last status change. */ - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
struct kernel_stat64 @@ -43,8 +43,8 @@ struct timespec st_atim; /* Time of last access. */ struct timespec st_mtim; /* Time of last modification. */ struct timespec st_ctim; /* Time of last status change. */ - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/m68k/bits/kernel_stat.h libc/sysdeps/linux/m68k/bits/kernel_stat.h --- a/libc/sysdeps/linux/m68k/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/m68k/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -21,8 +21,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/m68k/bits/stat.h libc/sysdeps/linux/m68k/bits/stat.h --- a/libc/sysdeps/linux/m68k/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/m68k/bits/stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -82,8 +82,8 @@ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif #ifndef __USE_FILE_OFFSET64 - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; #else __ino64_t st_ino; /* File serial number. */ #endif diff -ur libc/sysdeps/linux/microblaze/bits/kernel_stat.h libc/sysdeps/linux/microblaze/bits/kernel_stat.h --- a/libc/sysdeps/linux/microblaze/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/microblaze/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -20,8 +20,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
struct kernel_stat64 @@ -41,8 +41,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/nds32/bits/kernel_stat.h libc/sysdeps/linux/nds32/bits/kernel_stat.h --- a/libc/sysdeps/linux/nds32/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/nds32/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -30,8 +30,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/nds32/bits/stat.h libc/sysdeps/linux/nds32/bits/stat.h --- a/libc/sysdeps/linux/nds32/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/nds32/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -86,8 +86,8 @@ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif #ifndef __USE_FILE_OFFSET64 - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; #else __ino64_t st_ino; /* File serial number. */ #endif diff -ur libc/sysdeps/linux/powerpc/bits/kernel_stat.h libc/sysdeps/linux/powerpc/bits/kernel_stat.h --- a/libc/sysdeps/linux/powerpc/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/powerpc/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -22,8 +22,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; }; #endif
@@ -42,8 +42,8 @@ struct timespec st_atim; /* Time of last access. */ struct timespec st_mtim; /* Time of last modification. */ struct timespec st_ctim; /* Time of last status change. */ - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/powerpc/bits/stat.h libc/sysdeps/linux/powerpc/bits/stat.h --- a/libc/sysdeps/linux/powerpc/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/powerpc/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -80,8 +80,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; };
@@ -120,8 +120,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; }; # endif /* __USE_LARGEFILE64 */
diff -ur libc/sysdeps/linux/sh/bits/kernel_stat.h libc/sysdeps/linux/sh/bits/kernel_stat.h --- a/libc/sysdeps/linux/sh/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/sh/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -22,8 +22,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { @@ -69,8 +69,8 @@ struct timespec st_mtim; struct timespec st_ctim;
- unsigned long __unused1; - unsigned long __unused2; + unsigned long __uclibc_unused1; + unsigned long __uclibc_unused2; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/sparc/bits/kernel_stat.h libc/sysdeps/linux/sparc/bits/kernel_stat.h --- a/libc/sysdeps/linux/sparc/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/sparc/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -19,7 +19,7 @@ struct timespec st_ctim; long st_blksize; long st_blocks; - unsigned long __unused4[2]; + unsigned long __uclibc_unused4[2]; };
struct kernel_stat64 { @@ -38,8 +38,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/sparc/bits/stat.h libc/sysdeps/linux/sparc/bits/stat.h --- a/libc/sysdeps/linux/sparc/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/sparc/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -74,8 +74,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; };
#ifdef __USE_LARGEFILE64 @@ -114,8 +114,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; }; #endif
diff -ur libc/sysdeps/linux/sparc64/bits/kernel_stat.h libc/sysdeps/linux/sparc64/bits/kernel_stat.h --- a/libc/sysdeps/linux/sparc64/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/sparc64/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -19,8 +19,8 @@ struct timespec st_ctim; long st_blksize; long st_blocks; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { @@ -38,9 +38,9 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - long __unused4; - long __unused5; - long __unused6; + long __uclibc_unused4; + long __uclibc_unused5; + long __uclibc_unused6; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/sparc64/bits/stat.h libc/sysdeps/linux/sparc64/bits/stat.h --- a/libc/sysdeps/linux/sparc64/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/sparc64/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -79,8 +79,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; };
#ifdef __USE_LARGEFILE64 @@ -122,8 +122,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; }; #endif
diff -ur libc/sysdeps/linux/x86_64/bits/kernel_stat.h libc/sysdeps/linux/x86_64/bits/kernel_stat.h --- a/libc/sysdeps/linux/x86_64/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/x86_64/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -21,7 +21,7 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - long __unused[3]; + long __uclibc_unused[3]; };
/* x86-64 stat64 is same as stat */ diff -ur libc/sysdeps/linux/x86_64/bits/stat.h libc/sysdeps/linux/x86_64/bits/stat.h --- a/libc/sysdeps/linux/x86_64/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/x86_64/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -99,11 +99,11 @@ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif #if __WORDSIZE == 64 - long int __unused[3]; + long int __uclibc_unused[3]; #else # ifndef __USE_FILE_OFFSET64 - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; # else __ino64_t st_ino; /* File serial number. */ # endif @@ -160,7 +160,7 @@ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif #if __WORDSIZE == 64 - long int __unused[3]; + long int __uclibc_unused[3]; #else __ino64_t st_ino; /* File serial number. */ #endif diff -ur libc/sysdeps/linux/xtensa/bits/kernel_stat.h libc/sysdeps/linux/xtensa/bits/kernel_stat.h --- a/libc/sysdeps/linux/xtensa/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/xtensa/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -19,8 +19,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { @@ -33,13 +33,13 @@ unsigned long long st_rdev; /* Device number, if device. */ long long st_size; /* Size of file, in bytes. */ unsigned long st_blksize; /* Optimal block size for I/O. */ - unsigned long __unused2; + unsigned long __uclibc_unused2; unsigned long long st_blocks; /* Number 512-byte blocks allocated. */ struct timespec st_atim; /* Time of last access. */ struct timespec st_mtim; /* Time of last modification. */ struct timespec st_ctim; /* Time of last status change. */ - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/xtensa/bits/stat.h libc/sysdeps/linux/xtensa/bits/stat.h --- a/libc/sysdeps/linux/xtensa/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/xtensa/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -75,8 +75,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; };
#ifdef __USE_LARGEFILE64 @@ -112,8 +112,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; }; #endif
Hi Ed,
the patch does not apply on git master, any idea?
Ed W wrote,
Rename various spare fields in structs to include a namespace This should avoid accidental clashes with uses of the __unused symbol in upstream projects. eg currently it causes a compile error in dhcpcd 8.x and onwards due to their re-use of the __unused symbol as a macro
Recommend that in general continue to convert generic names to include the __uclibc_ prefix to namespace them. This follows the style of glibc which does something equivalent
signed-off-by: Ed Wildgoose lists@wildgooses.com
diff -ur libc/sysdeps/linux/alpha/bits/kernel_stat.h libc/sysdeps/linux/alpha/bits/kernel_stat.h --- a/libc/sysdeps/linux/alpha/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/alpha/bits/kernel_stat.h 2020-06-11 16:34:02.009197215 +0000 @@ -39,7 +39,7 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - long __unused[3]; + long __uclibc_unused[3]; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/alpha/bits/stat.h libc/sysdeps/linux/alpha/bits/stat.h --- a/libc/sysdeps/linux/alpha/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/alpha/bits/stat.h 2020-06-11 16:34:02.009197215 +0000 @@ -89,7 +89,7 @@ __ST_TIME(a); /* Time of last access. */ __ST_TIME(m); /* Time of last modification. */ __ST_TIME(c); /* Time of last status change. */ - long __unused[3]; + long __uclibc_unused[3]; };
#ifdef __USE_LARGEFILE64 @@ -110,7 +110,7 @@ __ST_TIME(a); /* Time of last access. */ __ST_TIME(m); /* Time of last modification. */ __ST_TIME(c); /* Time of last status change. */ - long __unused[3]; + long __uclibc_unused[3]; }; #endif
diff -ur libc/sysdeps/linux/arm/bits/kernel_stat.h libc/sysdeps/linux/arm/bits/kernel_stat.h --- a/libc/sysdeps/linux/arm/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/arm/bits/kernel_stat.h 2020-06-11 16:34:02.009197215 +0000 @@ -29,8 +29,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/avr32/bits/kernel_stat.h libc/sysdeps/linux/avr32/bits/kernel_stat.h --- a/libc/sysdeps/linux/avr32/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/avr32/bits/kernel_stat.h 2020-06-11 16:34:02.009197215 +0000 @@ -20,8 +20,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { @@ -46,8 +46,8 @@ struct timespec st_mtim; struct timespec st_ctim;
- unsigned long __unused1; - unsigned long __unused2; + unsigned long __uclibc_unused1; + unsigned long __uclibc_unused2; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/bfin/bits/kernel_stat.h libc/sysdeps/linux/bfin/bits/kernel_stat.h --- a/libc/sysdeps/linux/bfin/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/bfin/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -21,8 +21,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/c6x/bits/kernel_stat.h libc/sysdeps/linux/c6x/bits/kernel_stat.h --- a/libc/sysdeps/linux/c6x/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/c6x/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -21,8 +21,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
struct kernel_stat64 { @@ -41,8 +41,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/common/bits/stat.h libc/sysdeps/linux/common/bits/stat.h --- a/libc/sysdeps/linux/common/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/common/bits/stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -83,8 +83,8 @@ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif #ifndef __USE_FILE_OFFSET64 - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; #else __ino64_t st_ino; /* File serial number. */ #endif diff -ur libc/sysdeps/linux/common-generic/bits/stat.h libc/sysdeps/linux/common-generic/bits/stat.h --- a/libc/sysdeps/linux/common-generic/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/common-generic/bits/stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -68,8 +68,8 @@ int st_ctime; /* Time of last status change. */ unsigned int st_ctime_nsec; #endif - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; } __ARCH_64BIT_ALIGNMENT__;
@@ -106,8 +106,8 @@ int st_ctime; /* Time of last status change. */ unsigned int st_ctime_nsec; # endif - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; }; #endif
diff -ur libc/sysdeps/linux/cris/bits/kernel_stat.h libc/sysdeps/linux/cris/bits/kernel_stat.h --- a/libc/sysdeps/linux/cris/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/cris/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -19,8 +19,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
/* This matches struct kernel_stat64 in glibc2.1, hence the absolutely diff -ur libc/sysdeps/linux/csky/bits/kernel_stat.h libc/sysdeps/linux/csky/bits/kernel_stat.h --- a/libc/sysdeps/linux/csky/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/csky/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -34,8 +34,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/frv/bits/kernel_stat.h libc/sysdeps/linux/frv/bits/kernel_stat.h --- a/libc/sysdeps/linux/frv/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/frv/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -38,7 +38,7 @@ struct timespec st_mtim; struct timespec st_ctim;
- unsigned long long __unused4; + unsigned long long __uclibc_unused4; };
struct kernel_stat64 { @@ -68,7 +68,7 @@ struct timespec st_mtim; struct timespec st_ctim;
- unsigned long long __unused4; + unsigned long long __uclibc_unused4; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/frv/bits/stat.h libc/sysdeps/linux/frv/bits/stat.h --- a/libc/sysdeps/linux/frv/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/frv/bits/stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -84,16 +84,16 @@ # define st_mtime st_mtim.tv_sec # define st_ctime st_ctim.tv_sec #else - unsigned long int __unused1; + unsigned long int __uclibc_unused1; __time_t st_atime; /* Time of last access. */
- unsigned long int __unused2; + unsigned long int __uclibc_unused2; __time_t st_mtime; /* Time of last modification. */
- unsigned long int __unused3; + unsigned long int __uclibc_unused3; __time_t st_ctime; /* Time of last status change. */ #endif - unsigned long long __unused4; + unsigned long long __uclibc_unused4; };
#ifdef __USE_LARGEFILE64 @@ -131,16 +131,16 @@ # define st_mtime st_mtim.tv_sec # define st_ctime st_ctim.tv_sec #else - unsigned long int __unused1; + unsigned long int __uclibc_unused1; __time_t st_atime; /* Time of last access. */
- unsigned long int __unused2; + unsigned long int __uclibc_unused2; __time_t st_mtime; /* Time of last modification. */
- unsigned long int __unused3; + unsigned long int __uclibc_unused3; __time_t st_ctime; /* Time of last status change. */ #endif - unsigned long long __unused4; + unsigned long long __uclibc_unused4; }; #endif
diff -ur libc/sysdeps/linux/hppa/bits/kernel_stat.h libc/sysdeps/linux/hppa/bits/kernel_stat.h --- a/libc/sysdeps/linux/hppa/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/hppa/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -18,11 +18,11 @@ struct timespec st_ctim; int st_blksize; int st_blocks; - unsigned int __unused1; /* ACL stuff */ - unsigned int __unused2; /* network */ - ino_t __unused3; /* network */ - unsigned int __unused4; /* cnodes */ - unsigned short __unused5; /* netsite */ + unsigned int __uclibc_unused1; /* ACL stuff */ + unsigned int __uclibc_unused2; /* network */ + ino_t __uclibc_unused3; /* network */ + unsigned int __uclibc_unused4; /* cnodes */ + unsigned short __uclibc_unused5; /* netsite */ short st_fstype; unsigned int st_realdev; unsigned short st_basemode; diff -ur libc/sysdeps/linux/i386/bits/kernel_stat.h libc/sysdeps/linux/i386/bits/kernel_stat.h --- a/libc/sysdeps/linux/i386/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/i386/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -20,8 +20,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/ia64/bits/kernel_stat.h libc/sysdeps/linux/ia64/bits/kernel_stat.h --- a/libc/sysdeps/linux/ia64/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/ia64/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -24,7 +24,7 @@ struct timespec st_ctim; unsigned long st_blksize; long st_blocks; - unsigned long __unused[3]; + unsigned long __uclibc_unused[3]; };
/* ia64 stat64 is same as stat */ diff -ur libc/sysdeps/linux/ia64/bits/stat.h libc/sysdeps/linux/ia64/bits/stat.h --- a/libc/sysdeps/linux/ia64/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/ia64/bits/stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -61,7 +61,7 @@ #endif __blksize_t st_blksize; /* Optimal block size for I/O. */ __blkcnt_t st_blocks; /* Nr. 512-byte blocks allocated. */ - long int __unused[3]; + long int __uclibc_unused[3]; };
#ifdef __USE_LARGEFILE64 @@ -100,7 +100,7 @@ #endif __blksize_t st_blksize; /* Optimal block size for I/O. */ __blkcnt64_t st_blocks; /* Nr. 512-byte blocks allocated. */ - long int __unused[3]; + long int __uclibc_unused[3]; }; #endif
diff -ur libc/sysdeps/linux/lm32/bits/kernel_stat.h libc/sysdeps/linux/lm32/bits/kernel_stat.h --- a/libc/sysdeps/linux/lm32/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/lm32/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -22,8 +22,8 @@ struct timespec st_atim; /* Time of last access. */ struct timespec st_mtim; /* Time of last modification. */ struct timespec st_ctim; /* Time of last status change. */ - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
struct kernel_stat64 @@ -43,8 +43,8 @@ struct timespec st_atim; /* Time of last access. */ struct timespec st_mtim; /* Time of last modification. */ struct timespec st_ctim; /* Time of last status change. */ - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/m68k/bits/kernel_stat.h libc/sysdeps/linux/m68k/bits/kernel_stat.h --- a/libc/sysdeps/linux/m68k/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/m68k/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -21,8 +21,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/m68k/bits/stat.h libc/sysdeps/linux/m68k/bits/stat.h --- a/libc/sysdeps/linux/m68k/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/m68k/bits/stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -82,8 +82,8 @@ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif #ifndef __USE_FILE_OFFSET64 - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; #else __ino64_t st_ino; /* File serial number. */ #endif diff -ur libc/sysdeps/linux/microblaze/bits/kernel_stat.h libc/sysdeps/linux/microblaze/bits/kernel_stat.h --- a/libc/sysdeps/linux/microblaze/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/microblaze/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -20,8 +20,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
struct kernel_stat64 @@ -41,8 +41,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/nds32/bits/kernel_stat.h libc/sysdeps/linux/nds32/bits/kernel_stat.h --- a/libc/sysdeps/linux/nds32/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/nds32/bits/kernel_stat.h 2020-06-11 16:34:02.010197216 +0000 @@ -30,8 +30,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { diff -ur libc/sysdeps/linux/nds32/bits/stat.h libc/sysdeps/linux/nds32/bits/stat.h --- a/libc/sysdeps/linux/nds32/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/nds32/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -86,8 +86,8 @@ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif #ifndef __USE_FILE_OFFSET64 - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; #else __ino64_t st_ino; /* File serial number. */ #endif diff -ur libc/sysdeps/linux/powerpc/bits/kernel_stat.h libc/sysdeps/linux/powerpc/bits/kernel_stat.h --- a/libc/sysdeps/linux/powerpc/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/powerpc/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -22,8 +22,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; }; #endif
@@ -42,8 +42,8 @@ struct timespec st_atim; /* Time of last access. */ struct timespec st_mtim; /* Time of last modification. */ struct timespec st_ctim; /* Time of last status change. */ - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/powerpc/bits/stat.h libc/sysdeps/linux/powerpc/bits/stat.h --- a/libc/sysdeps/linux/powerpc/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/powerpc/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -80,8 +80,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; };
@@ -120,8 +120,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; }; # endif /* __USE_LARGEFILE64 */
diff -ur libc/sysdeps/linux/sh/bits/kernel_stat.h libc/sysdeps/linux/sh/bits/kernel_stat.h --- a/libc/sysdeps/linux/sh/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/sh/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -22,8 +22,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { @@ -69,8 +69,8 @@ struct timespec st_mtim; struct timespec st_ctim;
- unsigned long __unused1; - unsigned long __unused2; + unsigned long __uclibc_unused1; + unsigned long __uclibc_unused2; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/sparc/bits/kernel_stat.h libc/sysdeps/linux/sparc/bits/kernel_stat.h --- a/libc/sysdeps/linux/sparc/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/sparc/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -19,7 +19,7 @@ struct timespec st_ctim; long st_blksize; long st_blocks; - unsigned long __unused4[2]; + unsigned long __uclibc_unused4[2]; };
struct kernel_stat64 { @@ -38,8 +38,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned int __unused4; - unsigned int __unused5; + unsigned int __uclibc_unused4; + unsigned int __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/sparc/bits/stat.h libc/sysdeps/linux/sparc/bits/stat.h --- a/libc/sysdeps/linux/sparc/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/sparc/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -74,8 +74,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; };
#ifdef __USE_LARGEFILE64 @@ -114,8 +114,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; }; #endif
diff -ur libc/sysdeps/linux/sparc64/bits/kernel_stat.h libc/sysdeps/linux/sparc64/bits/kernel_stat.h --- a/libc/sysdeps/linux/sparc64/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/sparc64/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -19,8 +19,8 @@ struct timespec st_ctim; long st_blksize; long st_blocks; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { @@ -38,9 +38,9 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - long __unused4; - long __unused5; - long __unused6; + long __uclibc_unused4; + long __uclibc_unused5; + long __uclibc_unused6; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/sparc64/bits/stat.h libc/sysdeps/linux/sparc64/bits/stat.h --- a/libc/sysdeps/linux/sparc64/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/sparc64/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -79,8 +79,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; };
#ifdef __USE_LARGEFILE64 @@ -122,8 +122,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; }; #endif
diff -ur libc/sysdeps/linux/x86_64/bits/kernel_stat.h libc/sysdeps/linux/x86_64/bits/kernel_stat.h --- a/libc/sysdeps/linux/x86_64/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/x86_64/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -21,7 +21,7 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - long __unused[3]; + long __uclibc_unused[3]; };
/* x86-64 stat64 is same as stat */ diff -ur libc/sysdeps/linux/x86_64/bits/stat.h libc/sysdeps/linux/x86_64/bits/stat.h --- a/libc/sysdeps/linux/x86_64/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/x86_64/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -99,11 +99,11 @@ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif #if __WORDSIZE == 64 - long int __unused[3]; + long int __uclibc_unused[3]; #else # ifndef __USE_FILE_OFFSET64 - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; # else __ino64_t st_ino; /* File serial number. */ # endif @@ -160,7 +160,7 @@ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif #if __WORDSIZE == 64 - long int __unused[3]; + long int __uclibc_unused[3]; #else __ino64_t st_ino; /* File serial number. */ #endif diff -ur libc/sysdeps/linux/xtensa/bits/kernel_stat.h libc/sysdeps/linux/xtensa/bits/kernel_stat.h --- a/libc/sysdeps/linux/xtensa/bits/kernel_stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/xtensa/bits/kernel_stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -19,8 +19,8 @@ struct timespec st_atim; struct timespec st_mtim; struct timespec st_ctim; - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
struct kernel_stat64 { @@ -33,13 +33,13 @@ unsigned long long st_rdev; /* Device number, if device. */ long long st_size; /* Size of file, in bytes. */ unsigned long st_blksize; /* Optimal block size for I/O. */ - unsigned long __unused2; + unsigned long __uclibc_unused2; unsigned long long st_blocks; /* Number 512-byte blocks allocated. */ struct timespec st_atim; /* Time of last access. */ struct timespec st_mtim; /* Time of last modification. */ struct timespec st_ctim; /* Time of last status change. */ - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; };
#endif /* _BITS_STAT_STRUCT_H */ diff -ur libc/sysdeps/linux/xtensa/bits/stat.h libc/sysdeps/linux/xtensa/bits/stat.h --- a/libc/sysdeps/linux/xtensa/bits/stat.h 2020-03-09 07:43:31.000000000 +0000 +++ b/libc/sysdeps/linux/xtensa/bits/stat.h 2020-06-11 16:34:02.011197218 +0000 @@ -75,8 +75,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long int __unused4; - unsigned long int __unused5; + unsigned long int __uclibc_unused4; + unsigned long int __uclibc_unused5; };
#ifdef __USE_LARGEFILE64 @@ -112,8 +112,8 @@ __time_t st_ctime; /* Time of last status change. */ unsigned long int st_ctimensec; /* Nsecs of last status change. */ #endif - unsigned long __unused4; - unsigned long __unused5; + unsigned long __uclibc_unused4; + unsigned long __uclibc_unused5; }; #endif
devel mailing list devel@uclibc-ng.org https://mailman.uclibc-ng.org/cgi-bin/mailman/listinfo/devel
I'm so sorry, thankyou for humouring me... I can only assume that my mailer broke the formatting and mangled the tabs?
Can you accept as an attachment? See here for the same, prepared using git format-patch
Apologies for time wasted previously. Please ping me a message off-list if I'm still not sending this in a useful format
Kind regards
Ed W
On 19/06/2020 07:54, Waldemar Brodkorb wrote:
Hi Ed,
the patch does not apply on git master, any idea?
Ed W wrote,
Rename various spare fields in structs to include a namespace This should avoid accidental clashes with uses of the __unused symbol in upstream projects. eg currently it causes a compile error in dhcpcd 8.x and onwards due to their re-use of the __unused symbol as a macro
Recommend that in general continue to convert generic names to include the __uclibc_ prefix to namespace them. This follows the style of glibc which does something equivalent
signed-off-by: Ed Wildgoose lists@wildgooses.com
Hi, Any further comments on this? Was it unacceptable in this format?
Thanks
Ed W
On 19/06/2020 13:51, Ed W wrote:
I'm so sorry, thankyou for humouring me... I can only assume that my mailer broke the formatting and mangled the tabs?
Can you accept as an attachment? See here for the same, prepared using git format-patch
Apologies for time wasted previously. Please ping me a message off-list if I'm still not sending this in a useful format
Kind regards
Ed W
On 19/06/2020 07:54, Waldemar Brodkorb wrote:
Hi Ed,
the patch does not apply on git master, any idea?
Ed W wrote,
Rename various spare fields in structs to include a namespace This should avoid accidental clashes with uses of the __unused symbol in upstream projects. eg currently it causes a compile error in dhcpcd 8.x and onwards due to their re-use of the __unused symbol as a macro
Recommend that in general continue to convert generic names to include the __uclibc_ prefix to namespace them. This follows the style of glibc which does something equivalent
signed-off-by: Ed Wildgoose lists@wildgooses.com
devel mailing list devel@uclibc-ng.org https://mailman.uclibc-ng.org/cgi-bin/mailman/listinfo/devel
Hello Ed,
Your patch was merged 4 days ago: https://cgit.uclibc-ng.org/cgi/cgit/uclibc-ng.git/commit/?id=93277314f0ec844...
Thanks!
Yann
On 7/6/20 4:34 PM, Ed W wrote:
Hi, Any further comments on this? Was it unacceptable in this format?
Thanks
Ed W
On 19/06/2020 13:51, Ed W wrote:
I'm so sorry, thankyou for humouring me... I can only assume that my mailer broke the formatting and mangled the tabs?
Can you accept as an attachment? See here for the same, prepared using git format-patch
Apologies for time wasted previously. Please ping me a message off-list if I'm still not sending this in a useful format
Kind regards
Ed W
On 19/06/2020 07:54, Waldemar Brodkorb wrote:
Hi Ed,
the patch does not apply on git master, any idea?
Ed W wrote,
Rename various spare fields in structs to include a namespace This should avoid accidental clashes with uses of the __unused symbol in upstream projects. eg currently it causes a compile error in dhcpcd 8.x and onwards due to their re-use of the __unused symbol as a macro
Recommend that in general continue to convert generic names to include the __uclibc_ prefix to namespace them. This follows the style of glibc which does something equivalent
signed-off-by: Ed Wildgoose lists@wildgooses.com
devel mailing list devel@uclibc-ng.org https://mailman.uclibc-ng.org/cgi-bin/mailman/listinfo/devel
devel mailing list devel@uclibc-ng.org https://mailman.uclibc-ng.org/cgi-bin/mailman/listinfo/devel
Oh gosh... I'm making a lot of wasted noise on this list aren't I... I'm terribly sorry...
Ed W
On 06/07/2020 15:38, Yann Sionneau wrote:
Hello Ed,
Your patch was merged 4 days ago: https://cgit.uclibc-ng.org/cgi/cgit/uclibc-ng.git/commit/?id=93277314f0ec844...
Thanks!
Yann