diff options
Diffstat (limited to 'include/fitz/sysdep.h')
-rw-r--r-- | include/fitz/sysdep.h | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/include/fitz/sysdep.h b/include/fitz/sysdep.h new file mode 100644 index 00000000..bb78521f --- /dev/null +++ b/include/fitz/sysdep.h @@ -0,0 +1,48 @@ +/* + * Include the basic standard libc headers. + */ + +#include <stdlib.h> +#include <string.h> +#include <assert.h> +#include <stdarg.h> + +#include <limits.h> /* INT_MIN, MAX ... */ +#include <float.h> /* DBL_EPSILON */ +#include <math.h> + +#include <errno.h> +#include <unistd.h> +#include <fcntl.h> /* O_RDONLY & co */ + +/* not supposed to be here, but printf debugging sorta needs it */ +#include <stdio.h> + +typedef unsigned char fz_u8; +typedef signed char fz_s8; +typedef unsigned short fz_u16; +typedef signed short fz_s16; +typedef unsigned long fz_u32; +typedef signed long fz_s32; +typedef unsigned long long fz_u64; +typedef signed long long fz_s64; + +/* + * Extras! Extras! Get them while they're hot! + */ + +#ifdef NEED_STRLCPY +extern int strlcpy(char *dst, const char *src, int n); +extern int strlcat(char *dst, const char *src, int n); +#endif + +#ifdef NEED_STRSEP +extern char *strsep(char **stringp, const char *delim); +#endif + +#ifdef NEED_GETOPT +extern int getopt(int nargc, char * const * nargv, const char *ostr); +extern int opterr, optind, optopt; +extern char *optarg; +#endif + |