On my freebsd box, a make on src/core of
http://www.inspirel.com/yami4/files/yami4-gpl-1.7.0.tar.gz provides error:
g++ -O2 -Iposix -c -o posix/io_error_handler.o posix/io_error_handler.cpp
posix/io_error_handler.cpp: In function 'void yami::details::handle_io_error_with_code(const char*, int, void (*)(void*, int, const char*), void*)':
posix/io_error_handler.cpp:45: error: 'snprintf' is not a member of 'std'
*** [posix/io_error_handler.o] Error code 1
uname: FreeBSD 9.1-RELEASE FreeBSD 9.1-RELEASE #0 r243826: Tue Dec 4 06:55:39 UTC 2012
Although probably not the best method, the below did fix this issue:
--- src/core/posix/io_error_handler.cpp.origin 2013-02-05 15:33:57.000000000 -0600
+++ src/core/posix/io_error_handler.cpp 2013-05-30 14:13:54.000000000 -0500
@@ -18,9 +18,13 @@
#include <cstdio>
#include <cstring>
-
#include <errno.h>
+#ifdef __FreeBSD__
+#include <stdio.h>
+#endif
+
+
void yami::details::handle_io_error(
const char * prefix,
core::io_error_function io_error_callback,
@@ -42,7 +46,11 @@
char msg[max_msg_size];
const char * error_str = std::strerror(error_code);
+#ifdef __FreeBSD__
+ snprintf(msg, max_msg_size, "%s: %s", prefix, error_str);
+#else
std::snprintf(msg, max_msg_size, "%s: %s", prefix, error_str);
+#endif
try
{