/* >h.filetype */

/* The following defines are Archimedes filetypes of AIM files */

#define AIM    3

/* stdlib.h
 * Copyright (C) Acorn Computers Ltd., 1989
 * Copyright (C) Codemist Ltd., 1989
 * Modified for AIM Ed Doppenberg 19-04-90
 */
#ifndef __stdlib_h
#define __stdlib_h
#ifndef __size_t
#define __size_t 1
 typedef unsigned int size_t; 
#endif
#ifndef __wchar_t
 typedef int wchar_t; 
#define __wchar_t 1
#endif
#ifndef NULL
#define NULL 0 
#endif
typedef struct div_t { int quot, rem; } div_t;
 
typedef struct ldiv_t { long int quot, rem; } ldiv_t;
 
#ifdef __EXIT_FAILURE
#define EXIT_FAILURE __EXIT_FAILURE
 
#else
#define EXIT_FAILURE 1 
#endif
#define EXIT_SUCCESS 0
 
#define RAND_MAX 0x7fffffff 
 
#define _ANSI_RAND_MAX 0x7fff 
 
#define MB_CUR_MAX 1
 
extern double atof(const char * );
 
extern int atoi(const char * );
 
extern long int atol(const char * );
 
extern double strtod(const char * , char ** );
 
extern long int strtol(const char * , char **, int );
 
extern unsigned long int strtoul(const char * ,
 char ** , int );
 
extern int rand(void);
 
extern void srand(unsigned int );
 
extern int _ANSI_rand(void);
 
extern void _ANSI_srand(unsigned int );

/* Dpg 19-04-90 
extern void *calloc(size_t , size_t );
 
extern void free(void * );
 
extern void *malloc(size_t );
 
extern void *realloc(void * , size_t );
*/ 
extern void abort(void);
 
extern int atexit(void (* )(void));
 
extern void exit(int );
 
extern char *getenv(const char * );
 
extern int system(const char * );
 
extern void *bsearch(const void *key, const void * ,
 size_t , size_t ,
 int (* )(const void *, const void *));
 
extern void qsort(void * , size_t , size_t ,
 int (* )(const void *, const void *));
 
extern int abs(int );
 
extern div_t div(int , int );
 
extern long int labs(long int );
 
extern ldiv_t ldiv(long int , long int );
 
extern int mblen(const char * , size_t );
 
extern int mbtowc(wchar_t * , const char * , size_t );
 
extern int wctomb(char * , wchar_t );
 
extern size_t mbstowcs(wchar_t * , const char * , size_t );
 
extern size_t wcstombs(char * , const wchar_t * , size_t );
 
#endif
/* #include "mymem.h" */


#define GREYIM 4         /* AIM GREY   IMAGE */
#define COLIM  5         /* AIM COLOR  IMAGE */
#define BINIM  6         /* AIM BINAIR IMAGE */
#define HAWK   6
#define SPRITE 0xff9     /* ACORN SPRITE     */
/* space for other image types */

#define IMHEAD 16        /* AIM HEADER       */

/*#define MACRO  17  */

#define ASMF   17        /* =0x011 ASM SIGNAL FILE  */

#define HELPF  18        /* =0x012 AIM HELPFILE     */
#define SETUP  19        /* =0x013 AIM SETUP FILE   */
#define TCL    19        /* =0x013 TCL IMAGE FILE   */


/* If a file is written, all file names must be show in grey */
/* Directories in black as usual  */

#define SHOW_ALL  20
