2011-07-09 14:20:44 +05:30
|
|
|
#ifndef COMPAT_H
|
|
|
|
#define COMPAT_H
|
|
|
|
|
2014-07-14 12:20:14 +05:30
|
|
|
#include <inttypes.h>
|
2011-07-09 14:20:44 +05:30
|
|
|
#include <sys/types.h>
|
2011-11-24 15:53:08 +05:30
|
|
|
#include <stdarg.h>
|
2012-12-06 17:28:17 +05:30
|
|
|
|
|
|
|
#if HAVE_VISIBILITY
|
|
|
|
#define HIDDEN __attribute__ ((visibility("hidden")))
|
|
|
|
#else
|
|
|
|
#define HIDDEN
|
|
|
|
#endif
|
2011-07-09 14:20:44 +05:30
|
|
|
|
|
|
|
#ifndef HAVE_STRLCAT
|
2012-06-18 13:22:19 +05:30
|
|
|
size_t HIDDEN strlcat(char *, const char *, size_t);
|
2011-07-09 14:20:44 +05:30
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef HAVE_STRLCPY
|
2012-06-18 13:22:19 +05:30
|
|
|
size_t HIDDEN strlcpy(char *, const char *, size_t);
|
2011-07-09 14:20:44 +05:30
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifndef HAVE_STRCASESTR
|
2012-06-18 13:22:19 +05:30
|
|
|
char HIDDEN *strcasestr(const char *, const char *);
|
2011-07-09 14:20:44 +05:30
|
|
|
#endif
|
|
|
|
|
2014-01-20 23:20:33 +05:30
|
|
|
#ifndef HAVE_VASPRINTF
|
2012-06-18 13:22:19 +05:30
|
|
|
int HIDDEN vasprintf(char **, const char *, va_list);
|
2011-11-24 15:53:08 +05:30
|
|
|
#endif
|
|
|
|
|
2012-12-06 17:28:17 +05:30
|
|
|
#ifndef HAVE_HUMANIZE_HUMBER
|
|
|
|
#define HN_DECIMAL 0x01
|
|
|
|
#define HN_NOSPACE 0x02
|
|
|
|
#define HN_B 0x04
|
|
|
|
#define HN_DIVISOR_1000 0x08
|
|
|
|
#define HN_GETSCALE 0x10
|
|
|
|
#define HN_AUTOSCALE 0x20
|
|
|
|
int HIDDEN humanize_number(char *, size_t, int64_t, const char *, int, int);
|
|
|
|
#endif
|
|
|
|
|
2011-07-09 14:20:44 +05:30
|
|
|
#endif /* COMPAT_H */
|