1 /* 2 * Public domain 3 * string.h compatibility shim 4 */ 5 6 #include_next <string.h> 7 8 #ifndef LIBCOMPAT_STRING_H 9 #define LIBCOMPAT_STRING_H 10 11 #include <sys/types.h> 12 13 #if defined(__sun) || defined(__hpux) 14 /* Some functions historically defined in string.h were placed in strings.h by 15 * SUS. Use the same hack as OS X and FreeBSD use to work around on Solaris and HPUX. 16 */ 17 #include <strings.h> 18 #endif 19 20 #ifndef HAVE_STRLCPY 21 size_t strlcpy(char *dst, const char *src, size_t siz); 22 #endif 23 24 #endif 25