comparison src/sysdir.h @ 272:c5d627a313b1 r21-0b34

Import from CVS: tag r21-0b34
author cvs
date Mon, 13 Aug 2007 10:28:48 +0200
parents ac2d302a0011
children 74fd4e045ea6
comparison
equal deleted inserted replaced
271:c7b7086b0a39 272:c5d627a313b1
17 along with XEmacs; see the file COPYING. If not, write to 17 along with XEmacs; see the file COPYING. If not, write to
18 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, 18 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19 Boston, MA 02111-1307, USA. */ 19 Boston, MA 02111-1307, USA. */
20 20
21 /* Synched up with: Not really in FSF. */ 21 /* Synched up with: Not really in FSF. */
22
23 #ifdef HAVE_UNISTD_H
24 #include <unistd.h>
25 #endif
22 26
23 #ifdef SYSV_SYSTEM_DIR 27 #ifdef SYSV_SYSTEM_DIR
24 # include <dirent.h> 28 # include <dirent.h>
25 #elif defined (NONSYSTEM_DIR_LIBRARY) 29 #elif defined (NONSYSTEM_DIR_LIBRARY)
26 # include "ndir.h" 30 # include "ndir.h"
58 #endif 62 #endif
59 63
60 /* encapsulation: directory calls */ 64 /* encapsulation: directory calls */
61 65
62 #ifdef ENCAPSULATE_CHDIR 66 #ifdef ENCAPSULATE_CHDIR
63 extern int sys_chdir (CONST char *path); 67 int sys_chdir (CONST char *path);
64 #endif 68 #endif
65 #if defined (ENCAPSULATE_CHDIR) && !defined (DONT_ENCAPSULATE) 69 #if defined (ENCAPSULATE_CHDIR) && !defined (DONT_ENCAPSULATE)
66 # undef chdir 70 # undef chdir
67 # define chdir sys_chdir 71 # define chdir sys_chdir
68 #endif 72 #endif
69 #if !defined (ENCAPSULATE_CHDIR) && defined (DONT_ENCAPSULATE) 73 #if !defined (ENCAPSULATE_CHDIR) && defined (DONT_ENCAPSULATE)
70 # define sys_chdir chdir 74 # define sys_chdir chdir
71 #endif 75 #endif
72 76
73 #ifdef ENCAPSULATE_MKDIR 77 #ifdef ENCAPSULATE_MKDIR
74 extern int sys_mkdir (CONST char *path, int mode); 78 int sys_mkdir (CONST char *path, mode_t mode);
75 #endif 79 #endif
76 #if defined (ENCAPSULATE_MKDIR) && !defined (DONT_ENCAPSULATE) 80 #if defined (ENCAPSULATE_MKDIR) && !defined (DONT_ENCAPSULATE)
77 # undef mkdir 81 # undef mkdir
78 # define mkdir sys_mkdir 82 # define mkdir sys_mkdir
79 #endif 83 #endif
80 #if !defined (ENCAPSULATE_MKDIR) && defined (DONT_ENCAPSULATE) 84 #if !defined (ENCAPSULATE_MKDIR) && defined (DONT_ENCAPSULATE)
81 # define sys_mkdir mkdir 85 # define sys_mkdir mkdir
82 #endif 86 #endif
83 87
84 #ifdef ENCAPSULATE_OPENDIR 88 #ifdef ENCAPSULATE_OPENDIR
85 extern DIR *sys_opendir (CONST char *filename); 89 DIR *sys_opendir (CONST char *filename);
86 #endif 90 #endif
87 #if defined (ENCAPSULATE_OPENDIR) && !defined (DONT_ENCAPSULATE) 91 #if defined (ENCAPSULATE_OPENDIR) && !defined (DONT_ENCAPSULATE)
88 # undef opendir 92 # undef opendir
89 # define opendir sys_opendir 93 # define opendir sys_opendir
90 #endif 94 #endif
91 #if !defined (ENCAPSULATE_OPENDIR) && defined (DONT_ENCAPSULATE) 95 #if !defined (ENCAPSULATE_OPENDIR) && defined (DONT_ENCAPSULATE)
92 # define sys_opendir opendir 96 # define sys_opendir opendir
93 #endif 97 #endif
94 98
95 #ifdef ENCAPSULATE_READDIR 99 #ifdef ENCAPSULATE_READDIR
96 extern DIRENTRY *sys_readdir (DIR *dirp); 100 DIRENTRY *sys_readdir (DIR *dirp);
97 #endif 101 #endif
98 #if defined (ENCAPSULATE_READDIR) && !defined (DONT_ENCAPSULATE) 102 #if defined (ENCAPSULATE_READDIR) && !defined (DONT_ENCAPSULATE)
99 # undef readdir 103 # undef readdir
100 # define readdir sys_readdir 104 # define readdir sys_readdir
101 #endif 105 #endif
102 #if !defined (ENCAPSULATE_READDIR) && defined (DONT_ENCAPSULATE) 106 #if !defined (ENCAPSULATE_READDIR) && defined (DONT_ENCAPSULATE)
103 # define sys_readdir readdir 107 # define sys_readdir readdir
104 #endif 108 #endif
105 109
106 #ifdef ENCAPSULATE_CLOSEDIR 110 #ifdef ENCAPSULATE_CLOSEDIR
107 extern int sys_closedir (DIR *dirp); 111 int sys_closedir (DIR *dirp);
108 #endif 112 #endif
109 #if defined (ENCAPSULATE_CLOSEDIR) && !defined (DONT_ENCAPSULATE) 113 #if defined (ENCAPSULATE_CLOSEDIR) && !defined (DONT_ENCAPSULATE)
110 # undef closedir 114 # undef closedir
111 # define closedir sys_closedir 115 # define closedir sys_closedir
112 #endif 116 #endif
113 #if !defined (ENCAPSULATE_CLOSEDIR) && defined (DONT_ENCAPSULATE) 117 #if !defined (ENCAPSULATE_CLOSEDIR) && defined (DONT_ENCAPSULATE)
114 # define sys_closedir closedir 118 # define sys_closedir closedir
115 #endif 119 #endif
116 120
117 #ifdef ENCAPSULATE_RMDIR 121 #ifdef ENCAPSULATE_RMDIR
118 extern int sys_rmdir (CONST char *path); 122 int sys_rmdir (CONST char *path);
119 #endif 123 #endif
120 #if defined (ENCAPSULATE_RMDIR) && !defined (DONT_ENCAPSULATE) 124 #if defined (ENCAPSULATE_RMDIR) && !defined (DONT_ENCAPSULATE)
121 # undef rmdir 125 # undef rmdir
122 # define rmdir sys_rmdir 126 # define rmdir sys_rmdir
123 #endif 127 #endif