summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoger Meier <roger@apache.org>2015-09-19 20:49:50 +0200
committerRoger Meier <roger@apache.org>2015-09-19 20:49:50 +0200
commitff4a8edd50621fb6aab7dbbf6968d4322700ed7d (patch)
tree23edc7dcf5aa098c5afeb2abae7e8e7bd0fff5c8
parent6857b7fe90bd1561b9b982f9063bccaa25107b1d (diff)
downloadthrift-ff4a8edd50621fb6aab7dbbf6968d4322700ed7d.tar.gz
THRIFT-3326 Tests do not compile under *BSD
Patch: Joao Neves
-rwxr-xr-xlib/c_glib/test/testbinaryprotocol.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/c_glib/test/testbinaryprotocol.c b/lib/c_glib/test/testbinaryprotocol.c
index 517fd2556..cd6550135 100755
--- a/lib/c_glib/test/testbinaryprotocol.c
+++ b/lib/c_glib/test/testbinaryprotocol.c
@@ -20,7 +20,11 @@
/* Disable string-function optimizations when glibc is used, as these produce
compiler warnings about string length when a string function is used inside
a call to assert () */
+#if !defined(__APPLE__) && !defined(__FreeBSD__) && \
+ !defined(__OpenBSD__) && !defined(__NetBSD__)
#include <features.h>
+#endif
+
#ifdef __GLIBC__
#define __NO_STRING_INLINES 1
#endif