Print this page
Ensured various XPG7 stuff are declared properly in sys/stat.h (and cleanup)
New documentation for wcslen, wcsnlen, wcscasecmp (and friends), wcsdup.
Various other tweaks and markup improvements.
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/uts/common/sys/stat.h
+++ new/usr/src/uts/common/sys/stat.h
1 1 /*
2 2 * CDDL HEADER START
3 3 *
4 4 * The contents of this file are subject to the terms of the
5 5 * Common Development and Distribution License (the "License").
6 6 * You may not use this file except in compliance with the License.
7 7 *
8 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 9 * or http://www.opensolaris.org/os/licensing.
10 10 * See the License for the specific language governing permissions
11 11 * and limitations under the License.
12 12 *
13 13 * When distributing Covered Code, include this CDDL HEADER in each
↓ open down ↓ |
13 lines elided |
↑ open up ↑ |
14 14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 15 * If applicable, add the following below this CDDL HEADER, with the
16 16 * fields enclosed by brackets "[]" replaced with your own identifying
17 17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 18 *
19 19 * CDDL HEADER END
20 20 */
21 21
22 22 /*
23 23 * Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved.
24 + * Copyright 2014 Garrett D'Amore <garrett@damore.org>
24 25 */
25 26
26 27 /* Copyright (c) 1990, 1991 UNIX System Laboratories, Inc. */
27 28 /* Copyright (c) 1984, 1986, 1987, 1988, 1989, 1990 AT&T */
28 29 /* All Rights Reserved */
29 30
30 31 #ifndef _SYS_STAT_H
31 32 #define _SYS_STAT_H
32 33
33 34 #include <sys/feature_tests.h>
34 35 #include <sys/types.h>
35 36
36 37 #ifdef __cplusplus
37 38 extern "C" {
38 39 #endif
39 40
40 41 /*
41 42 * The implementation specific header <sys/time_impl.h> includes a
42 43 * definition for timestruc_t needed by the stat structure. However,
43 44 * including either <time.h>, which includes <sys/time_impl.h>, or
44 45 * including <sys/time_impl.h> directly will break both X/Open and
45 46 * POSIX namespace. Preceeding tag, structure, and structure member
46 47 * names with underscores eliminates the namespace breakage and at the
47 48 * same time, with unique type names, eliminates the possibility of
48 49 * timespec_t or timestruct_t naming conflicts that could otherwise
49 50 * result based on the order of inclusion of <sys/stat.h> and
50 51 * <sys/time.h>. The header <sys/time_std_impl.h> contains the
51 52 * standards namespace safe versions of these definitions.
52 53 */
53 54 #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__)
54 55 #include <sys/time_impl.h>
55 56 #else
56 57 #include <sys/time_std_impl.h>
57 58 #endif /* !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__) */
58 59
59 60 #define _ST_FSTYPSZ 16 /* array size for file system type name */
60 61
61 62 /*
62 63 * stat structure, used by stat(2) and fstat(2)
63 64 */
64 65
65 66 #if defined(_KERNEL)
66 67
67 68 /* Expanded stat structure */
68 69
69 70 #if defined(_LP64)
70 71
71 72 struct stat {
72 73 dev_t st_dev;
73 74 ino_t st_ino;
74 75 mode_t st_mode;
75 76 nlink_t st_nlink;
76 77 uid_t st_uid;
77 78 gid_t st_gid;
78 79 dev_t st_rdev;
79 80 off_t st_size;
80 81 timestruc_t st_atim;
81 82 timestruc_t st_mtim;
82 83 timestruc_t st_ctim;
83 84 blksize_t st_blksize;
84 85 blkcnt_t st_blocks;
85 86 char st_fstype[_ST_FSTYPSZ];
86 87 };
87 88
88 89 struct stat64 {
89 90 dev_t st_dev;
90 91 ino_t st_ino;
91 92 mode_t st_mode;
92 93 nlink_t st_nlink;
93 94 uid_t st_uid;
94 95 gid_t st_gid;
95 96 dev_t st_rdev;
96 97 off_t st_size;
97 98 timestruc_t st_atim;
98 99 timestruc_t st_mtim;
99 100 timestruc_t st_ctim;
100 101 blksize_t st_blksize;
101 102 blkcnt_t st_blocks;
102 103 char st_fstype[_ST_FSTYPSZ];
103 104 };
104 105
105 106 #else /* _LP64 */
106 107
107 108 struct stat {
108 109 dev_t st_dev;
109 110 long st_pad1[3]; /* reserve for dev expansion, */
110 111 /* sysid definition */
111 112 ino_t st_ino;
112 113 mode_t st_mode;
113 114 nlink_t st_nlink;
114 115 uid_t st_uid;
115 116 gid_t st_gid;
116 117 dev_t st_rdev;
117 118 long st_pad2[2];
118 119 off_t st_size;
119 120 long st_pad3; /* pad for future off_t expansion */
120 121 timestruc_t st_atim;
121 122 timestruc_t st_mtim;
122 123 timestruc_t st_ctim;
123 124 blksize_t st_blksize;
124 125 blkcnt_t st_blocks;
125 126 char st_fstype[_ST_FSTYPSZ];
126 127 long st_pad4[8]; /* expansion area */
127 128 };
128 129
129 130 struct stat64 {
130 131 dev_t st_dev;
131 132 long st_pad1[3]; /* reserve for dev expansion, */
132 133 /* sysid definition */
133 134 ino64_t st_ino;
134 135 mode_t st_mode;
135 136 nlink_t st_nlink;
136 137 uid_t st_uid;
137 138 gid_t st_gid;
138 139 dev_t st_rdev;
139 140 long st_pad2[2];
140 141 off64_t st_size; /* large file support */
141 142 timestruc_t st_atim;
142 143 timestruc_t st_mtim;
143 144 timestruc_t st_ctim;
144 145 blksize_t st_blksize;
145 146 blkcnt64_t st_blocks; /* large file support */
146 147 char st_fstype[_ST_FSTYPSZ];
147 148 long st_pad4[8]; /* expansion area */
148 149 };
149 150
150 151 #endif /* _LP64 */
151 152
152 153 #else /* !defined(_KERNEL) */
153 154
154 155 /*
155 156 * large file compilation environment setup
156 157 */
157 158 #if !defined(_LP64) && _FILE_OFFSET_BITS == 64
158 159 #ifdef __PRAGMA_REDEFINE_EXTNAME
159 160 #pragma redefine_extname fstat fstat64
160 161 #pragma redefine_extname stat stat64
161 162 #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__) || \
162 163 defined(_ATFILE_SOURCE)
163 164 #pragma redefine_extname fstatat fstatat64
164 165 #endif /* defined (_ATFILE_SOURCE) */
165 166
166 167 #if !defined(__XOPEN_OR_POSIX) || defined(_XPG_2) || defined(__EXTENSIONS__)
167 168 #pragma redefine_extname lstat lstat64
168 169 #endif
169 170 #else /* __PRAGMA_REDEFINE_EXTNAME */
170 171 #define fstat fstat64
171 172 #define stat stat64
172 173 #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__) || \
173 174 defined(_ATFILE_SOURCE)
174 175 #define fstatat fstatat64
175 176 #endif /* defined (_ATFILE_SOURCE) */
176 177 #if !defined(__XOPEN_OR_POSIX) || defined(_XPG_2) || defined(__EXTENSIONS__)
177 178 #define lstat lstat64
178 179 #endif
179 180 #endif /* __PRAGMA_REDEFINE_EXTNAME */
180 181 #endif /* !_LP64 && _FILE_OFFSET_BITS == 64 */
181 182
182 183 /*
183 184 * In the LP64 compilation environment, map large file interfaces
184 185 * back to native versions where possible.
185 186 */
186 187 #if defined(_LP64) && defined(_LARGEFILE64_SOURCE)
187 188 #ifdef __PRAGMA_REDEFINE_EXTNAME
188 189 #pragma redefine_extname fstat64 fstat
189 190 #pragma redefine_extname stat64 stat
190 191 #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__) || \
191 192 defined(_ATFILE_SOURCE)
192 193 #pragma redefine_extname fstatat64 fstatat
193 194 #endif /* defined (_ATFILE_SOURCE) */
194 195 #if !defined(__XOPEN_OR_POSIX) || defined(_XPG_2) || defined(__EXTENSIONS__)
195 196 #pragma redefine_extname lstat64 lstat
196 197 #endif
197 198 #else /* __PRAGMA_REDEFINE_EXTNAME */
198 199 #define fstat64 fstat
199 200 #define stat64 stat
200 201 #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__) || \
201 202 defined(_ATFILE_SOURCE)
202 203 #define fstatat64 fstatat
203 204 #endif /* defined (_ATFILE_SOURCE) */
204 205 #if !defined(__XOPEN_OR_POSIX) || defined(_XPG_2) || defined(__EXTENSIONS__)
205 206 #define lstat64 lstat
206 207 #endif
207 208 #endif /* __PRAGMA_REDEFINE_EXTNAME */
208 209 #endif /* _LP64 && _LARGEFILE64_SOURCE */
209 210
210 211 /*
211 212 * User level stat structure definitions.
212 213 */
213 214
214 215 #if defined(_LP64)
215 216
216 217 struct stat {
217 218 dev_t st_dev;
218 219 ino_t st_ino;
219 220 mode_t st_mode;
220 221 nlink_t st_nlink;
221 222 uid_t st_uid;
222 223 gid_t st_gid;
223 224 dev_t st_rdev;
224 225 off_t st_size;
225 226 #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__)
226 227 timestruc_t st_atim;
227 228 timestruc_t st_mtim;
228 229 timestruc_t st_ctim;
229 230 #else
230 231 _timestruc_t st_atim;
231 232 _timestruc_t st_mtim;
232 233 _timestruc_t st_ctim;
233 234 #endif
234 235 blksize_t st_blksize;
235 236 blkcnt_t st_blocks;
236 237 char st_fstype[_ST_FSTYPSZ];
237 238 };
238 239
239 240 #else /* _LP64 */
240 241
241 242 struct stat {
242 243 dev_t st_dev;
243 244 long st_pad1[3]; /* reserved for network id */
244 245 ino_t st_ino;
245 246 mode_t st_mode;
246 247 nlink_t st_nlink;
247 248 uid_t st_uid;
248 249 gid_t st_gid;
249 250 dev_t st_rdev;
250 251 long st_pad2[2];
251 252 off_t st_size;
252 253 #if _FILE_OFFSET_BITS != 64
253 254 long st_pad3; /* future off_t expansion */
254 255 #endif
255 256 #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__)
256 257 timestruc_t st_atim;
257 258 timestruc_t st_mtim;
258 259 timestruc_t st_ctim;
259 260 #else
260 261 _timestruc_t st_atim;
261 262 _timestruc_t st_mtim;
262 263 _timestruc_t st_ctim;
263 264 #endif
264 265 blksize_t st_blksize;
265 266 blkcnt_t st_blocks;
266 267 char st_fstype[_ST_FSTYPSZ];
267 268 long st_pad4[8]; /* expansion area */
268 269 };
269 270
270 271 #endif /* _LP64 */
271 272
272 273 /* transitional large file interface version */
273 274 #if defined(_LARGEFILE64_SOURCE) && !((_FILE_OFFSET_BITS == 64) && \
274 275 !defined(__PRAGMA_REDEFINE_EXTNAME))
275 276 #if defined(_LP64)
276 277
277 278 struct stat64 {
278 279 dev_t st_dev;
279 280 ino_t st_ino;
280 281 mode_t st_mode;
281 282 nlink_t st_nlink;
282 283 uid_t st_uid;
283 284 gid_t st_gid;
284 285 dev_t st_rdev;
285 286 off_t st_size;
286 287 #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__)
287 288 timestruc_t st_atim;
288 289 timestruc_t st_mtim;
289 290 timestruc_t st_ctim;
290 291 #else
291 292 _timestruc_t st_atim;
292 293 _timestruc_t st_mtim;
293 294 _timestruc_t st_ctim;
294 295 #endif
295 296 blksize_t st_blksize;
296 297 blkcnt_t st_blocks;
297 298 char st_fstype[_ST_FSTYPSZ];
298 299 };
299 300
300 301 #else /* _LP64 */
301 302
302 303 struct stat64 {
303 304 dev_t st_dev;
304 305 long st_pad1[3]; /* reserved for network id */
305 306 ino64_t st_ino;
306 307 mode_t st_mode;
307 308 nlink_t st_nlink;
308 309 uid_t st_uid;
309 310 gid_t st_gid;
310 311 dev_t st_rdev;
311 312 long st_pad2[2];
312 313 off64_t st_size;
313 314 #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__)
314 315 timestruc_t st_atim;
315 316 timestruc_t st_mtim;
316 317 timestruc_t st_ctim;
317 318 #else
318 319 _timestruc_t st_atim;
319 320 _timestruc_t st_mtim;
320 321 _timestruc_t st_ctim;
321 322 #endif
322 323 blksize_t st_blksize;
323 324 blkcnt64_t st_blocks;
324 325 char st_fstype[_ST_FSTYPSZ];
325 326 long st_pad4[8]; /* expansion area */
326 327 };
327 328
328 329 #endif /* _LP64 */
329 330 #endif
330 331
331 332 #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__)
332 333 #define st_atime st_atim.tv_sec
333 334 #define st_mtime st_mtim.tv_sec
334 335 #define st_ctime st_ctim.tv_sec
335 336 #else
336 337 #define st_atime st_atim.__tv_sec
337 338 #define st_mtime st_mtim.__tv_sec
338 339 #define st_ctime st_ctim.__tv_sec
339 340 #endif /* !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__) */
340 341
341 342 #endif /* end defined(_KERNEL) */
342 343
343 344 #if defined(_SYSCALL32)
344 345
345 346 /*
346 347 * Kernel's view of user ILP32 stat and stat64 structures
347 348 */
348 349
349 350 struct stat32 {
350 351 dev32_t st_dev;
351 352 int32_t st_pad1[3];
352 353 ino32_t st_ino;
353 354 mode32_t st_mode;
354 355 nlink32_t st_nlink;
355 356 uid32_t st_uid;
356 357 gid32_t st_gid;
357 358 dev32_t st_rdev;
358 359 int32_t st_pad2[2];
359 360 off32_t st_size;
360 361 int32_t st_pad3;
361 362 timestruc32_t st_atim;
362 363 timestruc32_t st_mtim;
363 364 timestruc32_t st_ctim;
364 365 int32_t st_blksize;
365 366 blkcnt32_t st_blocks;
366 367 char st_fstype[_ST_FSTYPSZ];
367 368 int32_t st_pad4[8];
368 369 };
369 370
370 371 #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
371 372 #pragma pack(4)
372 373 #endif
373 374
374 375 struct stat64_32 {
375 376 dev32_t st_dev;
376 377 int32_t st_pad1[3];
377 378 ino64_t st_ino;
378 379 mode32_t st_mode;
379 380 nlink32_t st_nlink;
380 381 uid32_t st_uid;
381 382 gid32_t st_gid;
382 383 dev32_t st_rdev;
383 384 int32_t st_pad2[2];
384 385 off64_t st_size;
385 386 timestruc32_t st_atim;
386 387 timestruc32_t st_mtim;
387 388 timestruc32_t st_ctim;
388 389 int32_t st_blksize;
389 390 blkcnt64_t st_blocks;
390 391 char st_fstype[_ST_FSTYPSZ];
391 392 int32_t st_pad4[8];
392 393 };
393 394
394 395 #if _LONG_LONG_ALIGNMENT == 8 && _LONG_LONG_ALIGNMENT_32 == 4
395 396 #pragma pack()
396 397 #endif
397 398
398 399 #endif /* _SYSCALL32 */
399 400
400 401 /* MODE MASKS */
401 402
402 403 /* de facto standard definitions */
403 404
404 405 #define S_IFMT 0xF000 /* type of file */
405 406 #define S_IAMB 0x1FF /* access mode bits */
406 407 #define S_IFIFO 0x1000 /* fifo */
407 408 #define S_IFCHR 0x2000 /* character special */
408 409 #define S_IFDIR 0x4000 /* directory */
409 410 /* XENIX definitions are not relevant to Solaris */
410 411 #define S_IFNAM 0x5000 /* XENIX special named file */
411 412 #define S_INSEM 0x1 /* XENIX semaphore subtype of IFNAM */
412 413 #define S_INSHD 0x2 /* XENIX shared data subtype of IFNAM */
413 414 #define S_IFBLK 0x6000 /* block special */
414 415 #define S_IFREG 0x8000 /* regular */
415 416 #define S_IFLNK 0xA000 /* symbolic link */
416 417 #define S_IFSOCK 0xC000 /* socket */
417 418 #define S_IFDOOR 0xD000 /* door */
418 419 #define S_IFPORT 0xE000 /* event port */
419 420 #define S_ISUID 0x800 /* set user id on execution */
420 421 #define S_ISGID 0x400 /* set group id on execution */
421 422 #define S_ISVTX 0x200 /* save swapped text even after use */
422 423 #define S_IREAD 00400 /* read permission, owner */
423 424 #define S_IWRITE 00200 /* write permission, owner */
424 425 #define S_IEXEC 00100 /* execute/search permission, owner */
425 426 #define S_ENFMT S_ISGID /* record locking enforcement flag */
426 427
427 428 /* the following macros are for POSIX conformance */
428 429
429 430 #define S_IRWXU 00700 /* read, write, execute: owner */
430 431 #define S_IRUSR 00400 /* read permission: owner */
431 432 #define S_IWUSR 00200 /* write permission: owner */
432 433 #define S_IXUSR 00100 /* execute permission: owner */
433 434 #define S_IRWXG 00070 /* read, write, execute: group */
434 435 #define S_IRGRP 00040 /* read permission: group */
435 436 #define S_IWGRP 00020 /* write permission: group */
436 437 #define S_IXGRP 00010 /* execute permission: group */
437 438 #define S_IRWXO 00007 /* read, write, execute: other */
438 439 #define S_IROTH 00004 /* read permission: other */
439 440 #define S_IWOTH 00002 /* write permission: other */
440 441 #define S_IXOTH 00001 /* execute permission: other */
441 442
442 443
443 444 #define S_ISFIFO(mode) (((mode)&0xF000) == 0x1000)
444 445 #define S_ISCHR(mode) (((mode)&0xF000) == 0x2000)
445 446 #define S_ISDIR(mode) (((mode)&0xF000) == 0x4000)
446 447 #define S_ISBLK(mode) (((mode)&0xF000) == 0x6000)
447 448 #define S_ISREG(mode) (((mode)&0xF000) == 0x8000)
448 449 #define S_ISLNK(mode) (((mode)&0xF000) == 0xa000)
449 450 #define S_ISSOCK(mode) (((mode)&0xF000) == 0xc000)
450 451 #define S_ISDOOR(mode) (((mode)&0xF000) == 0xd000)
451 452 #define S_ISPORT(mode) (((mode)&0xF000) == 0xe000)
452 453
453 454 /* POSIX.4 macros */
454 455 #define S_TYPEISMQ(_buf) (0)
455 456 #define S_TYPEISSEM(_buf) (0)
456 457 #define S_TYPEISSHM(_buf) (0)
457 458
458 459 #if defined(__i386) || (defined(__i386_COMPAT) && defined(_KERNEL))
459 460
460 461 /*
461 462 * A version number is included in the x86 SVR4 stat and mknod interfaces
462 463 * so that SVR4 binaries can be supported. An LP64 kernel that supports
↓ open down ↓ |
429 lines elided |
↑ open up ↑ |
463 464 * the i386 ABI need to be aware of this too.
464 465 */
465 466
466 467 #define _R3_MKNOD_VER 1 /* SVR3.0 mknod */
467 468 #define _MKNOD_VER 2 /* current version of mknod */
468 469 #define _R3_STAT_VER 1 /* SVR3.0 stat */
469 470 #define _STAT_VER 2 /* current version of stat */
470 471
471 472 #endif /* __i386 || (__i386_COMPAT && _KERNEL) */
472 473
473 -#if defined(__EXTENSIONS__) || \
474 - (!defined(_STRICT_STDC) && !defined(__XOPEN_OR_POSIX))
475 - /* || defined(_XPG7) */
476 -/* for use with futimens() and utimensat() */
477 -#define UTIME_NOW -1L
478 -#define UTIME_OMIT -2L
479 -#endif /* defined(__EXTENSIONS__) ... */
480 -
481 474 #if !defined(_KERNEL) || defined(_BOOT)
482 475
483 -#if defined(__STDC__)
484 -
485 476 #if !defined(__XOPEN_OR_POSIX) || (_POSIX_C_SOURCE > 2) || \
486 477 defined(_XPG4_2) || defined(__EXTENSIONS__)
487 478 extern int fchmod(int, mode_t);
488 479 #endif /* !defined(__XOPEN_OR_POSIX) || (_POSIX_C_SOURCE > 2)... */
489 480
490 481 extern int chmod(const char *, mode_t);
491 482 extern int mkdir(const char *, mode_t);
492 483 extern int mkfifo(const char *, mode_t);
493 484 extern mode_t umask(mode_t);
494 485
495 486 /* transitional large file interfaces */
496 487 #if defined(_LARGEFILE64_SOURCE) && !((_FILE_OFFSET_BITS == 64) && \
↓ open down ↓ |
2 lines elided |
↑ open up ↑ |
497 488 !defined(__PRAGMA_REDEFINE_EXTNAME))
498 489 extern int fstat64(int, struct stat64 *);
499 490 extern int stat64(const char *_RESTRICT_KYWD, struct stat64 *_RESTRICT_KYWD);
500 491 extern int lstat64(const char *_RESTRICT_KYWD, struct stat64 *_RESTRICT_KYWD);
501 492 #if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__) || \
502 493 defined(_ATFILE_SOURCE)
503 494 extern int fstatat64(int, const char *, struct stat64 *, int);
504 495 #endif /* defined (_ATFILE_SOURCE) */
505 496 #endif
506 497
507 -#if defined(__EXTENSIONS__) || defined(_ATFILE_SOURCE) || \
508 - (!defined(_STRICT_STDC) && !defined(__XOPEN_OR_POSIX))
509 - /* || defined(_XPG7) */
498 +#if defined(_XPG7) || defined(_ATFILE_SOURCE)
510 499 extern int mkdirat(int, const char *, mode_t);
511 500 extern int mkfifoat(int, const char *, mode_t);
512 501 extern int mknodat(int, const char *, mode_t, dev_t);
513 502 extern int fchmodat(int, const char *, mode_t, int);
503 +#endif
504 +
505 +#if defined(_XPG7) || !defined(_STRICT_SYMBOLS)
506 +#define UTIME_NOW -1L
507 +#define UTIME_OMIT -2L
514 508 extern int futimens(int, const struct timespec[2]);
515 509 extern int utimensat(int, const char *, const struct timespec[2], int);
516 -#endif /* defined(__EXTENSIONS__) ... */
517 -
518 -#else /* !__STDC__ */
519 -
520 -#if !defined(__XOPEN_OR_POSIX) || (_POSIX_C_SOURCE > 2) || \
521 - defined(_XPG4_2) || defined(__EXTENSIONS__)
522 -extern int fchmod();
523 -#endif /* !defined(__XOPEN_OR_POSIX) || (_POSIX_C_SOURCE > 2)... */
524 -
525 -extern int chmod();
526 -extern int mkdir();
527 -extern int mkfifo();
528 -extern mode_t umask();
529 -
530 -/* transitional large file interfaces */
531 -#if defined(_LARGEFILE64_SOURCE) && !((_FILE_OFFSET_BITS == 64) && \
532 - !defined(__PRAGMA_REDEFINE_EXTNAME))
533 -extern int fstat64();
534 -extern int stat64();
535 -extern int lstat64();
536 -#if !defined(__XOPEN_OR_POSIX) || defined(__EXTENSIONS__) || \
537 - defined(_ATFILE_SOURCE)
538 -extern int fstatat64();
539 -#endif /* defined (_ATFILE_SOURCE) */
540 510 #endif
541 511
542 -#if defined(__EXTENSIONS__) || defined(_ATFILE_SOURCE) || \
543 - (!defined(_STRICT_STDC) && !defined(__XOPEN_OR_POSIX))
544 - /* || defined(_XPG7) */
545 -extern int mkdirat();
546 -extern int mkfifoat();
547 -extern int mknodat();
548 -extern int fchmodat();
549 -extern int futimens();
550 -extern int utimensat();
551 -#endif /* defined(__EXTENSIONS__) ... */
552 -
553 -#endif /* defined(__STDC__) */
554 -
555 512 #include <sys/stat_impl.h>
556 513
557 514 #endif /* !defined(_KERNEL) */
558 515
559 516 #ifdef __cplusplus
560 517 }
561 518 #endif
562 519
563 520 #endif /* _SYS_STAT_H */
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX