mdocml: update to stable snapshot as per 12/23/13
[dragonfly.git] / contrib / mdocml / config.h
1 #ifndef MANDOC_CONFIG_H
2 #define MANDOC_CONFIG_H
3
4 #if defined(__linux__) || defined(__MINT__)
5 # define _GNU_SOURCE /* strptime(), getsubopt() */
6 #endif
7
8 #include <stdio.h>
9
10 #define VERSION "1.12.2"
11 #define HAVE_FGETLN
12 #define HAVE_STRPTIME
13 #define HAVE_GETSUBOPT
14 #define HAVE_STRLCAT
15 #define HAVE_MMAP
16 #define HAVE_STRLCPY
17
18 #define OSNAME  "DragonFly 3.7"
19
20 #include <sys/types.h>
21
22 #if !defined(__BEGIN_DECLS)
23 #  ifdef __cplusplus
24 #  define       __BEGIN_DECLS           extern "C" {
25 #  else
26 #  define       __BEGIN_DECLS
27 #  endif
28 #endif
29 #if !defined(__END_DECLS)
30 #  ifdef __cplusplus
31 #  define       __END_DECLS             }
32 #  else
33 #  define       __END_DECLS
34 #  endif
35 #endif
36
37 #ifndef HAVE_BETOH64
38 #  if defined(__APPLE__)
39 #    define betoh64(x) OSSwapBigToHostInt64(x)
40 #    define htobe64(x) OSSwapHostToBigInt64(x)
41 #  elif defined(__sun)
42 #    define betoh64(x) BE_64(x)
43 #    define htobe64(x) BE_64(x)
44 #  else
45 #    define betoh64(x) be64toh(x)
46 #  endif
47 #endif
48
49 #ifndef HAVE_STRLCAT
50 extern  size_t    strlcat(char *, const char *, size_t);
51 #endif
52 #ifndef HAVE_STRLCPY
53 extern  size_t    strlcpy(char *, const char *, size_t);
54 #endif
55 #ifndef HAVE_GETSUBOPT
56 extern  int       getsubopt(char **, char * const *, char **);
57 extern  char     *suboptarg;
58 #endif
59 #ifndef HAVE_FGETLN
60 extern  char     *fgetln(FILE *, size_t *);
61 #endif
62
63 #endif /* MANDOC_CONFIG_H */