Import mdocml-1.12.1
[dragonfly.git] / contrib / mdocml / config.h.post
CommitLineData
80387638
SW
1#include <sys/types.h>
2
3#if !defined(__BEGIN_DECLS)
4# ifdef __cplusplus
5# define __BEGIN_DECLS extern "C" {
6# else
7# define __BEGIN_DECLS
8# endif
9#endif
10#if !defined(__END_DECLS)
11# ifdef __cplusplus
12# define __END_DECLS }
13# else
14# define __END_DECLS
15# endif
16#endif
17
36342e81
SW
18#if defined(__APPLE__)
19# define htobe32(x) OSSwapHostToBigInt32(x)
20# define betoh32(x) OSSwapBigToHostInt32(x)
21# define htobe64(x) OSSwapHostToBigInt64(x)
22# define betoh64(x) OSSwapBigToHostInt64(x)
23#elif defined(__linux__)
24# define betoh32(x) be32toh(x)
25# define betoh64(x) be64toh(x)
26#endif
27
80387638
SW
28#ifndef HAVE_STRLCAT
29extern size_t strlcat(char *, const char *, size_t);
30#endif
31#ifndef HAVE_STRLCPY
32extern size_t strlcpy(char *, const char *, size_t);
33#endif
36342e81
SW
34#ifndef HAVE_GETSUBOPT
35extern int getsubopt(char **, char * const *, char **);
36extern char *suboptarg;
37#endif
38#ifndef HAVE_FGETLN
39extern char *fgetln(FILE *, size_t *);
40#endif
80387638
SW
41
42#endif /* MANDOC_CONFIG_H */