@@ -49,96 +49,162 @@ pub struct FsType(pub fs_type_t);
49
49
50
50
// These constants are defined without documentation in the Linux headers, so we
51
51
// can't very well document them here.
52
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
52
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
53
53
#[ allow( missing_docs) ]
54
54
pub const ADFS_SUPER_MAGIC : FsType = FsType ( libc:: ADFS_SUPER_MAGIC as fs_type_t ) ;
55
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
55
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
56
56
#[ allow( missing_docs) ]
57
57
pub const AFFS_SUPER_MAGIC : FsType = FsType ( libc:: AFFS_SUPER_MAGIC as fs_type_t ) ;
58
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
58
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
59
+ #[ allow( missing_docs) ]
60
+ pub const AFS_SUPER_MAGIC : FsType = FsType ( libc:: AFS_SUPER_MAGIC as fs_type_t ) ;
61
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
62
+ #[ allow( missing_docs) ]
63
+ pub const AUTOFS_SUPER_MAGIC : FsType = FsType ( libc:: AUTOFS_SUPER_MAGIC as fs_type_t ) ;
64
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
65
+ #[ allow( missing_docs) ]
66
+ pub const BPF_FS_MAGIC : FsType = FsType ( libc:: BPF_FS_MAGIC as fs_type_t ) ;
67
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
68
+ #[ allow( missing_docs) ]
69
+ pub const BTRFS_SUPER_MAGIC : FsType = FsType ( libc:: BTRFS_SUPER_MAGIC as fs_type_t ) ;
70
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
71
+ #[ allow( missing_docs) ]
72
+ pub const CGROUP2_SUPER_MAGIC : FsType = FsType ( libc:: CGROUP2_SUPER_MAGIC as fs_type_t ) ;
73
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
74
+ #[ allow( missing_docs) ]
75
+ pub const CGROUP_SUPER_MAGIC : FsType = FsType ( libc:: CGROUP_SUPER_MAGIC as fs_type_t ) ;
76
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
59
77
#[ allow( missing_docs) ]
60
78
pub const CODA_SUPER_MAGIC : FsType = FsType ( libc:: CODA_SUPER_MAGIC as fs_type_t ) ;
61
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
79
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
62
80
#[ allow( missing_docs) ]
63
81
pub const CRAMFS_MAGIC : FsType = FsType ( libc:: CRAMFS_MAGIC as fs_type_t ) ;
64
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
82
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
83
+ #[ allow( missing_docs) ]
84
+ pub const DEBUGFS_MAGIC : FsType = FsType ( libc:: DEBUGFS_MAGIC as fs_type_t ) ;
85
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
86
+ #[ allow( missing_docs) ]
87
+ pub const DEVPTS_SUPER_MAGIC : FsType = FsType ( libc:: DEVPTS_SUPER_MAGIC as fs_type_t ) ;
88
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
89
+ #[ allow( missing_docs) ]
90
+ pub const ECRYPTFS_SUPER_MAGIC : FsType = FsType ( libc:: ECRYPTFS_SUPER_MAGIC as fs_type_t ) ;
91
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
65
92
#[ allow( missing_docs) ]
66
93
pub const EFS_SUPER_MAGIC : FsType = FsType ( libc:: EFS_SUPER_MAGIC as fs_type_t ) ;
67
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
94
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
68
95
#[ allow( missing_docs) ]
69
96
pub const EXT2_SUPER_MAGIC : FsType = FsType ( libc:: EXT2_SUPER_MAGIC as fs_type_t ) ;
70
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
97
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
71
98
#[ allow( missing_docs) ]
72
99
pub const EXT3_SUPER_MAGIC : FsType = FsType ( libc:: EXT3_SUPER_MAGIC as fs_type_t ) ;
73
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
100
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
74
101
#[ allow( missing_docs) ]
75
102
pub const EXT4_SUPER_MAGIC : FsType = FsType ( libc:: EXT4_SUPER_MAGIC as fs_type_t ) ;
76
- #[ cfg( all( target_os = "linux" , not( any( target_env = "musl" , target_env = "uclibc" ) ) ) ) ]
103
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
104
+ #[ allow( missing_docs) ]
105
+ pub const F2FS_SUPER_MAGIC : FsType = FsType ( libc:: F2FS_SUPER_MAGIC as fs_type_t ) ;
106
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
77
107
#[ allow( missing_docs) ]
78
108
pub const FUSE_SUPER_MAGIC : FsType = FsType ( libc:: FUSE_SUPER_MAGIC as fs_type_t ) ;
79
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
109
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
110
+ #[ allow( missing_docs) ]
111
+ pub const FUTEXFS_SUPER_MAGIC : FsType = FsType ( libc:: FUTEXFS_SUPER_MAGIC as fs_type_t ) ;
112
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
113
+ #[ allow( missing_docs) ]
114
+ pub const HOSTFS_SUPER_MAGIC : FsType = FsType ( libc:: HOSTFS_SUPER_MAGIC as fs_type_t ) ;
115
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
80
116
#[ allow( missing_docs) ]
81
117
pub const HPFS_SUPER_MAGIC : FsType = FsType ( libc:: HPFS_SUPER_MAGIC as fs_type_t ) ;
82
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
118
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
83
119
#[ allow( missing_docs) ]
84
120
pub const HUGETLBFS_MAGIC : FsType = FsType ( libc:: HUGETLBFS_MAGIC as fs_type_t ) ;
85
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
121
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
86
122
#[ allow( missing_docs) ]
87
123
pub const ISOFS_SUPER_MAGIC : FsType = FsType ( libc:: ISOFS_SUPER_MAGIC as fs_type_t ) ;
88
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
124
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
89
125
#[ allow( missing_docs) ]
90
126
pub const JFFS2_SUPER_MAGIC : FsType = FsType ( libc:: JFFS2_SUPER_MAGIC as fs_type_t ) ;
91
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
127
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
92
128
#[ allow( missing_docs) ]
93
- pub const MINIX_SUPER_MAGIC : FsType = FsType ( libc:: MINIX_SUPER_MAGIC as fs_type_t ) ;
94
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
95
- #[ allow( missing_docs) ]
96
- pub const MINIX_SUPER_MAGIC2 : FsType = FsType ( libc:: MINIX_SUPER_MAGIC2 as fs_type_t ) ;
97
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
129
+ pub const MINIX2_SUPER_MAGIC2 : FsType = FsType ( libc:: MINIX2_SUPER_MAGIC2 as fs_type_t ) ;
130
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
98
131
#[ allow( missing_docs) ]
99
132
pub const MINIX2_SUPER_MAGIC : FsType = FsType ( libc:: MINIX2_SUPER_MAGIC as fs_type_t ) ;
100
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
133
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
101
134
#[ allow( missing_docs) ]
102
- pub const MINIX2_SUPER_MAGIC2 : FsType = FsType ( libc:: MINIX2_SUPER_MAGIC2 as fs_type_t ) ;
103
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
135
+ pub const MINIX3_SUPER_MAGIC : FsType = FsType ( libc:: MINIX3_SUPER_MAGIC as fs_type_t ) ;
136
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
137
+ #[ allow( missing_docs) ]
138
+ pub const MINIX_SUPER_MAGIC2 : FsType = FsType ( libc:: MINIX_SUPER_MAGIC2 as fs_type_t ) ;
139
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
140
+ #[ allow( missing_docs) ]
141
+ pub const MINIX_SUPER_MAGIC : FsType = FsType ( libc:: MINIX_SUPER_MAGIC as fs_type_t ) ;
142
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
104
143
#[ allow( missing_docs) ]
105
144
pub const MSDOS_SUPER_MAGIC : FsType = FsType ( libc:: MSDOS_SUPER_MAGIC as fs_type_t ) ;
106
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
145
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
107
146
#[ allow( missing_docs) ]
108
147
pub const NCP_SUPER_MAGIC : FsType = FsType ( libc:: NCP_SUPER_MAGIC as fs_type_t ) ;
109
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
148
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
110
149
#[ allow( missing_docs) ]
111
150
pub const NFS_SUPER_MAGIC : FsType = FsType ( libc:: NFS_SUPER_MAGIC as fs_type_t ) ;
112
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
151
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
152
+ #[ allow( missing_docs) ]
153
+ pub const NILFS_SUPER_MAGIC : FsType = FsType ( libc:: NILFS_SUPER_MAGIC as fs_type_t ) ;
154
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
155
+ #[ allow( missing_docs) ]
156
+ pub const OCFS2_SUPER_MAGIC : FsType = FsType ( libc:: OCFS2_SUPER_MAGIC as fs_type_t ) ;
157
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
113
158
#[ allow( missing_docs) ]
114
159
pub const OPENPROM_SUPER_MAGIC : FsType = FsType ( libc:: OPENPROM_SUPER_MAGIC as fs_type_t ) ;
115
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
160
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
116
161
#[ allow( missing_docs) ]
117
162
pub const OVERLAYFS_SUPER_MAGIC : FsType = FsType ( libc:: OVERLAYFS_SUPER_MAGIC as fs_type_t ) ;
118
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
163
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
119
164
#[ allow( missing_docs) ]
120
165
pub const PROC_SUPER_MAGIC : FsType = FsType ( libc:: PROC_SUPER_MAGIC as fs_type_t ) ;
121
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
166
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
122
167
#[ allow( missing_docs) ]
123
168
pub const QNX4_SUPER_MAGIC : FsType = FsType ( libc:: QNX4_SUPER_MAGIC as fs_type_t ) ;
124
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
169
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
170
+ #[ allow( missing_docs) ]
171
+ pub const QNX6_SUPER_MAGIC : FsType = FsType ( libc:: QNX6_SUPER_MAGIC as fs_type_t ) ;
172
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
173
+ #[ allow( missing_docs) ]
174
+ pub const RDTGROUP_SUPER_MAGIC : FsType = FsType ( libc:: RDTGROUP_SUPER_MAGIC as fs_type_t ) ;
175
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
125
176
#[ allow( missing_docs) ]
126
177
pub const REISERFS_SUPER_MAGIC : FsType = FsType ( libc:: REISERFS_SUPER_MAGIC as fs_type_t ) ;
127
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
178
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
179
+ #[ allow( missing_docs) ]
180
+ pub const SECURITYFS_MAGIC : FsType = FsType ( libc:: SECURITYFS_MAGIC as fs_type_t ) ;
181
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
182
+ #[ allow( missing_docs) ]
183
+ pub const SELINUX_MAGIC : FsType = FsType ( libc:: SELINUX_MAGIC as fs_type_t ) ;
184
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
185
+ #[ allow( missing_docs) ]
186
+ pub const SMACK_MAGIC : FsType = FsType ( libc:: SMACK_MAGIC as fs_type_t ) ;
187
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
128
188
#[ allow( missing_docs) ]
129
189
pub const SMB_SUPER_MAGIC : FsType = FsType ( libc:: SMB_SUPER_MAGIC as fs_type_t ) ;
130
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
190
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
191
+ #[ allow( missing_docs) ]
192
+ pub const SYSFS_MAGIC : FsType = FsType ( libc:: SYSFS_MAGIC as fs_type_t ) ;
193
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
131
194
#[ allow( missing_docs) ]
132
195
pub const TMPFS_MAGIC : FsType = FsType ( libc:: TMPFS_MAGIC as fs_type_t ) ;
133
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
196
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
134
197
#[ allow( missing_docs) ]
135
- pub const USBDEVICE_SUPER_MAGIC : FsType = FsType ( libc:: USBDEVICE_SUPER_MAGIC as fs_type_t ) ;
136
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
198
+ pub const TRACEFS_MAGIC : FsType = FsType ( libc:: TRACEFS_MAGIC as fs_type_t ) ;
199
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
137
200
#[ allow( missing_docs) ]
138
- pub const CGROUP_SUPER_MAGIC : FsType = FsType ( libc:: CGROUP_SUPER_MAGIC as fs_type_t ) ;
139
- #[ cfg( all( target_os = "linux" , not( target_env = "musl" ) ) ) ]
201
+ pub const UDF_SUPER_MAGIC : FsType = FsType ( libc:: UDF_SUPER_MAGIC as fs_type_t ) ;
202
+ #[ cfg( any ( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
140
203
#[ allow( missing_docs) ]
141
- pub const CGROUP2_SUPER_MAGIC : FsType = FsType ( libc:: CGROUP2_SUPER_MAGIC as fs_type_t ) ;
204
+ pub const USBDEVICE_SUPER_MAGIC : FsType = FsType ( libc:: USBDEVICE_SUPER_MAGIC as fs_type_t ) ;
205
+ #[ cfg( any( all( target_os = "linux" , not( target_env = "musl" ) ) , target_os = "android" ) ) ]
206
+ #[ allow( missing_docs) ]
207
+ pub const XENFS_SUPER_MAGIC : FsType = FsType ( libc:: XENFS_SUPER_MAGIC as fs_type_t ) ;
142
208
143
209
144
210
impl Statfs {
0 commit comments