1 /* Replacement sys/stat.h file for building GNU Emacs on the Macintosh.
2 Copyright (C) 1999, 2000 Free Software Foundation, Inc.
4 This file is part of GNU Emacs.
6 GNU Emacs is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2, or (at your option)
11 GNU Emacs is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with GNU Emacs; see the file COPYING. If not, write to
18 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19 Boston, MA 02111-1307, USA. */
21 /* Contributed by Andrew Choi (akochoi@mac.com). */
45 #endif /* __MWERKS__ */
47 /* Need to redefine these for CW, filemode.c assumes Unix definitions which are
48 inconsistent with CW definitions because CW uses bits 8-12 for S_IFMT info.
49 Bit 8 is used by S_IRUSR on Unix! */
50 #define S_IFMT 0170000 /* type of file */
51 #define S_IFBLK 0060000 /* block special */
52 #define S_IFCHR 0020000 /* character special */
53 #define S_IFIFO 0010000 /* FIFO special */
54 #define S_IFREG 0100000 /* regular */
55 #define S_IFDIR 0040000 /* directory */
56 #define S_IFLNK 0030000 /* symbolic link */
59 #define S_IWRITE 00200
62 /* Need to redefine these for because mode_string in filemode.c assumes Unix
63 values in the lower 9 bits which are different from CW values. */
64 #define S_IRUSR S_IREAD
65 #define S_IWUSR S_IWRITE
66 #define S_IXUSR S_IEXEC
69 typedef unsigned long dev_t
;
72 dev_t st_dev
; /* ID of device containing file */
73 int st_ino
; /* file serial number */
74 unsigned short st_mode
; /* mode of file */
75 int st_nlink
; /* number of links to the file */
76 int st_uid
; /* user ID of file */
77 int st_gid
; /* group ID of file */
78 int st_rdev
; /* device ID (if file is character or block special) */
79 int st_size
; /* file size in bytes (if file is a regular file) */
80 int st_atime
; /* time of last access */
81 int st_mtime
; /* time of last data modification */
82 int st_ctime
; /* time of last status change */
86 #endif /* _SYS_STAT_H */
88 /* arch-tag: b7da83f5-3d3f-4b19-9cd2-790dd87145e4
89 (do not change this comment) */