| 1 | #include <fcntl.h> |
| 2 | #include <errno.h> |
| 3 | #include <stdio.h> |
| 4 | #include <sys/types.h> |
| 5 | #include <sys/stat.h> |
| 6 | #include <ctype.h> |
| 7 | #include <string.h> |
| 8 | #include <sys/file.h> |
| 9 | |
| 10 | #ifndef O_ACCMODE |
| 11 | #define O_ACCMODE (O_RDONLY | O_WRONLY | O_RDWR) |
| 12 | #endif |
| 13 | #define SEEK_SET 0 |
| 14 | #define SEEK_CUR 1 |
| 15 | |
| 16 | #ifndef DONTDECLARE_MALLOC |
| 17 | extern PTR EXFUN(malloc,(unsigned)); |
| 18 | extern PTR EXFUN(realloc, (PTR, unsigned)); |
| 19 | extern int EXFUN(free,(PTR)); |
| 20 | #endif |
| 21 | extern int EXFUN(abort,(void)); |
| 22 | extern void EXFUN(bcopy,(char*,char*,int)); |
| 23 | extern void EXFUN(exit,(int)); |
| 24 | extern void EXFUN(bzero,(char *, int)); |
| 25 | extern int strtol(); |
| 26 | |
| 27 | #include <machine/param.h> |
| 28 | #include <machine/vmparam.h> |
| 29 | #define HOST_PAGE_SIZE (NBPG*CLSIZE) |
| 30 | #define HOST_MACHINE_ARCH bfd_arch_vax |
| 31 | |
| 32 | #define HOST_TEXT_START_ADDR USRTEXT |
| 33 | #define HOST_STACK_END_ADDR USRSTACK |
| 34 | #undef HOST_BIG_ENDIAN_P |
| 35 | |
| 36 | /* EXACT TYPES */ |
| 37 | typedef char int8e_type; |
| 38 | typedef unsigned char uint8e_type; |
| 39 | typedef short int16e_type; |
| 40 | typedef unsigned short uint16e_type; |
| 41 | typedef int int32e_type; |
| 42 | typedef unsigned int uint32e_type; |
| 43 | |
| 44 | /* CORRECT SIZE OR GREATER */ |
| 45 | typedef char int8_type; |
| 46 | typedef unsigned char uint8_type; |
| 47 | typedef short int16_type; |
| 48 | typedef unsigned short uint16_type; |
| 49 | typedef int int32_type; |
| 50 | typedef unsigned int uint32_type; |
| 51 | #include "fopen-same.h" |