source: trunk/binutils/include/mpw/sys/stat.h

Last change on this file was 10, checked in by bird, 22 years ago

Initial revision

  • Property cvs2svn:cvs-rev set to 1.1
  • Property svn:eol-style set to native
  • Property svn:executable set to *
File size: 889 bytes
Line 
1/* Imitation sys/stat.h. */
2
3#ifndef __SYS_STAT_H__
4#define __SYS_STAT_H__
5
6#include <sys/types.h>
7#include <time.h>
8
9struct stat {
10 dev_t st_dev;
11 ino_t st_ino;
12 mode_t st_mode;
13 short st_nlink;
14 uid_t st_uid;
15 gid_t st_gid;
16 dev_t st_rdev;
17 off_t st_size;
18 off_t st_rsize;
19 time_t st_atime;
20 int st_spare1;
21 time_t st_mtime;
22 int st_spare2;
23 time_t st_ctime;
24 int st_spare3;
25 long st_blksize;
26 long st_blocks;
27 long st_spare4[2];
28};
29
30#define S_IFMT 0170000L
31#define S_IFDIR 0040000L
32#define S_IFREG 0100000L
33#define S_IREAD 0400
34#define S_IWRITE 0200
35#define S_IEXEC 0100
36
37#define S_IFIFO 010000 /* FIFO special */
38#define S_IFCHR 020000 /* character special */
39#define S_IFBLK 030000 /* block special */
40
41int stat (char *path, struct stat *buf);
42int fstat (int fd, struct stat *buf);
43
44#endif /* __SYS_STAT_H___ */
Note: See TracBrowser for help on using the repository browser.