1 #ifndef LIBRARIES_BZ2_H 2 #define LIBRARIES_BZ2_H 3 4 /* 5 * bz2.library 6 * 7 * Copyright © 2016 The MorphOS Development Team, All Rights Reserved. 8 * 9 * $Id: bz2.h,v 1.3 2016/04/12 23:05:58 piru Exp $ 10 */ 11 12 #ifdef __cplusplus 13 extern "C" { 14 #endif 15 16 #define BZ_RUN ( 0) 17 #define BZ_FLUSH ( 1) 18 #define BZ_FINISH ( 2) 19 20 #define BZ_OK ( 0) 21 #define BZ_RUN_OK ( 1) 22 #define BZ_FLUSH_OK ( 2) 23 #define BZ_FINISH_OK ( 3) 24 #define BZ_STREAM_END ( 4) 25 #define BZ_SEQUENCE_ERROR (-1) 26 #define BZ_PARAM_ERROR (-2) 27 #define BZ_MEM_ERROR (-3) 28 #define BZ_DATA_ERROR (-4) 29 #define BZ_DATA_ERROR_MAGIC (-5) 30 #define BZ_IO_ERROR (-6) 31 #define BZ_UNEXPECTED_EOF (-7) 32 #define BZ_OUTBUFF_FULL (-8) 33 #define BZ_CONFIG_ERROR (-9) 34 35 typedef struct 36 { 37 char *next_in; 38 unsigned int avail_in; 39 unsigned int total_in_lo32; 40 unsigned int total_in_hi32; 41 42 char *next_out; 43 unsigned int avail_out; 44 unsigned int total_out_lo32; 45 unsigned int total_out_hi32; 46 47 void *state; 48 49 void *(*bzalloc)(void *,int,int); 50 void (*bzfree)(void *,void *); 51 void *opaque; 52 53 } bz_stream; 54 55 56 #define BZ_MAX_UNUSED 5000 57 58 typedef void BZFILE; 59 60 #ifdef __cplusplus 61 } 62 #endif 63 64 #endif /* LIBRARIES_BZ2_H */