#ifndef LBX_H_ #define LBX_H_ #include /* Errors */ enum { LBX_ESUCCESS, LBX_EMAGIC, LBX_EEOF, LBX_ERANGE, }; extern int lbx_errno; /* Opaque */ typedef struct lbx_state LBX; struct lbx_statbuf { const char *name; size_t size; }; /* Archive operations */ LBX *lbx_fopen(FILE *, const char *); LBX *lbx_open(const char *); void lbx_close(LBX *); size_t lbx_numfiles(LBX *); /* File operations */ int lbx_stat(LBX *, size_t, struct lbx_statbuf *); size_t lbx_extract(LBX *, size_t, FILE *); /* Misc operations */ const char *lbx_strerror(void); #endif