summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorNiels de Vos <ndevos@redhat.com>2015-06-21 16:59:15 +0200
committerJeff Darcy <jdarcy@redhat.com>2016-02-10 04:38:25 -0800
commit4b725f2576b06a739e159981c6124118e26ccfbd (patch)
tree9d68096611c56d05a2a0187d815e18bf4de6df9b /configure.ac
parent32935246bf884760800029cb20627ea94a865cee (diff)
posix: implement seek() FOP
The only lseek() options we need are SEEK_HOLE and SEEK_DATA. Change-Id: I5d15533c53fd710497f97c3cb4a8ea29fba47271 BUG: 1220173 Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/11484 Smoke: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com> NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org> CentOS-regression: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Jeff Darcy <jdarcy@redhat.com>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac8
1 files changed, 8 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index a02c72e0b71..e9f75a6a1b0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -901,6 +901,14 @@ if test "x${have_posix_fallocate}" = "xyes"; then
AC_DEFINE(HAVE_POSIX_FALLOCATE, 1, [define if posix_fallocate exists])
fi
+OLD_CFLAGS=${CFLAGS}
+CFLAGS="-D_GNU_SOURCE"
+AC_CHECK_DECL([SEEK_HOLE], , , [#include <unistd.h>])
+if test "x${ac_cv_have_decl_SEEK_HOLE}" = "xyes"; then
+ AC_DEFINE(HAVE_SEEK_HOLE, 1, [define if SEEK_HOLE is available])
+fi
+CFLAGS=${OLD_CFLAGS}
+
# Check the distribution where you are compiling glusterfs on
GF_DISTRIBUTION=