From 4b725f2576b06a739e159981c6124118e26ccfbd Mon Sep 17 00:00:00 2001 From: Niels de Vos Date: Sun, 21 Jun 2015 16:59:15 +0200 Subject: 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 Reviewed-on: http://review.gluster.org/11484 Smoke: Gluster Build System Reviewed-by: Kaleb KEITHLEY NetBSD-regression: NetBSD Build System CentOS-regression: Gluster Build System Reviewed-by: Jeff Darcy --- configure.ac | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'configure.ac') 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 ]) +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= -- cgit