Guido van Rossum | d4d7728 | 1994-08-19 10:51:31 +0000 | [diff] [blame] | 1 | /* Useful #includes and #defines for programming a set of Unix |
| 2 | look-alike file system access functions on the Macintosh. |
| 3 | Public domain by Guido van Rossum, CWI, Amsterdam (July 1987). |
| 4 | */ |
| 5 | |
| 6 | #include <Types.h> |
| 7 | #include <Files.h> |
| 8 | #include <OSUtils.h> |
| 9 | |
Jack Jansen | 5495672 | 1997-04-08 15:24:58 +0000 | [diff] [blame] | 10 | #include <errno.h> |
| 11 | #include <string.h> |
Jack Jansen | 0c63770 | 1994-12-14 14:10:51 +0000 | [diff] [blame] | 12 | #ifdef __MWERKS__ |
| 13 | #include "errno_unix.h" |
Jack Jansen | d1d242e | 1997-05-07 15:45:01 +0000 | [diff] [blame] | 14 | #include <TextUtils.h> |
Jack Jansen | 0c63770 | 1994-12-14 14:10:51 +0000 | [diff] [blame] | 15 | #endif |
Guido van Rossum | d4d7728 | 1994-08-19 10:51:31 +0000 | [diff] [blame] | 16 | |
Jack Jansen | d50e4e1 | 1995-01-18 13:58:04 +0000 | [diff] [blame] | 17 | /* We may be able to use a std routine in think, don't know */ |
Jack Jansen | 9ae898b | 2000-07-11 21:16:03 +0000 | [diff] [blame] | 18 | extern unsigned char *Pstring(char *); |
| 19 | extern char *getbootvol(void); |
| 20 | extern char *getwd(char *); |
Jack Jansen | c3f593e | 2000-07-14 22:14:46 +0000 | [diff] [blame] | 21 | #ifndef USE_GUSI |
Jack Jansen | 9ae898b | 2000-07-11 21:16:03 +0000 | [diff] [blame] | 22 | extern int sync(void); |
Jack Jansen | c3f593e | 2000-07-14 22:14:46 +0000 | [diff] [blame] | 23 | #endif |
Guido van Rossum | d4d7728 | 1994-08-19 10:51:31 +0000 | [diff] [blame] | 24 | |
| 25 | /* Universal constants: */ |
| 26 | #define MAXPATH 256 |
Jack Jansen | 5495672 | 1997-04-08 15:24:58 +0000 | [diff] [blame] | 27 | #ifndef __MSL__ |
Guido van Rossum | d4d7728 | 1994-08-19 10:51:31 +0000 | [diff] [blame] | 28 | #define TRUE 1 |
| 29 | #define FALSE 0 |
Jack Jansen | 5495672 | 1997-04-08 15:24:58 +0000 | [diff] [blame] | 30 | #endif |
Guido van Rossum | d4d7728 | 1994-08-19 10:51:31 +0000 | [diff] [blame] | 31 | #ifndef NULL |
| 32 | #define NULL 0 |
| 33 | #endif |
| 34 | #define EOS '\0' |
| 35 | #define SEP ':' |