Go to the documentation of this file.
15 #ifndef OTF_PLATFORM_UNIX_H
16 #define OTF_PLATFORM_UNIX_H
28 #if defined(HAVE_SYS_PARAM_H) && HAVE_SYS_PARAM_H
29 # include <sys/param.h>
32 # define OTF_PATH_MAX (PATH_MAX + 1)
33 #elif defined(_POSIX_PATH_MAX)
34 # define OTF_PATH_MAX (_POSIX_PATH_MAX + 1)
36 # define OTF_PATH_MAX 256
39 #if !(defined(HAVE_FSEEKO) && HAVE_FSEEKO)
46 #if !(defined(HAVE_ASPRINTF) && HAVE_ASPRINTF)
48 # define asprintf OTF_asprintf
51 #if !(defined(HAVE_SNPRINTF) && HAVE_SNPRINTF)
53 # define snprintf OTF_snprintf
56 #if !(defined(HAVE_VASPRINTF) && HAVE_VASPRINTF)
58 # define vasprintf OTF_vasprintf
61 #if !(defined(HAVE_VSNPRINTF) && HAVE_VSNPRINTF)
63 # define vsnprintf OTF_vsnprintf
66 #if !(defined(HAVE_STRDUP) && HAVE_STRDUP)
68 # define strdup OTF_strdup
75 int OTF_asprintf(
char** ptr,
const char* fmt, ... );
76 int OTF_snprintf(
char* str,
size_t size,
const char* fmt, ... );
77 int OTF_vasprintf(
char** ptr,
const char* fmt, va_list ap );
78 int OTF_vsnprintf(
char* str,
size_t size,
const char* fmt, va_list ap );
79 char* OTF_strdup(
const char* s );