mdocml: refresh config.h and README.DRAGONFLY
[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 HAVE_STRPTIME
11 #define HAVE_GETSUBOPT
12 #define HAVE_STRLCAT
13 #define HAVE_MMAP
14 #define HAVE_STRLCPY
15
16 #define VERSION "1.12.2"
17 #define OSNAME  "DragonFly 3.5"
18
19 #include <sys/types.h>
20
21 #if !defined(__BEGIN_DECLS)
22 #  ifdef __cplusplus
23 #  define       __BEGIN_DECLS           extern "C" {
24 #  else
25 #  define       __BEGIN_DECLS
26 #  endif
27 #endif
28 #if !defined(__END_DECLS)
29 #  ifdef __cplusplus
30 #  define       __END_DECLS             }
31 #  else
32 #  define       __END_DECLS
33 #  endif
34 #endif
35
36 #ifndef HAVE_BETOH64
37 #  if defined(__APPLE__)
38 #    define betoh64(x) OSSwapBigToHostInt64(x)
39 #    define htobe64(x) OSSwapHostToBigInt64(x)
40 #  else
41 #    define betoh64(x) be64toh(x)
42 #  endif
43 #endif
44
45 #ifndef HAVE_STRLCAT
46 extern  size_t    strlcat(char *, const char *, size_t);
47 #endif
48 #ifndef HAVE_STRLCPY
49 extern  size_t    strlcpy(char *, const char *, size_t);
50 #endif
51 #ifndef HAVE_GETSUBOPT
52 extern  int       getsubopt(char **, char * const *, char **);
53 extern  char     *suboptarg;
54 #endif
55 #ifndef HAVE_FGETLN
56 extern  char     *fgetln(FILE *, size_t *);
57 #endif
58
59 #endif /* MANDOC_CONFIG_H */