From: Eric Sandeen Date: Wed, 10 Oct 2012 03:40:11 +0000 (+0000) Subject: xfs_io: include headers for preadv/pwritev X-Git-Tag: v3.1.9-rc1~5 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=64a933716bfec4d2267980afa3240fa2997cd3df;p=thirdparty%2Fxfsprogs-dev.git xfs_io: include headers for preadv/pwritev We need to include uio.h to avoid: [CC] pread.o pread.c: In function `do_pread': pread.c:198: warning: implicit declaration of function `preadv' [CC] pwrite.o pwrite.c: In function `do_pwrite': pwrite.c:85: warning: implicit declaration of function `pwritev' Signed-off-by: Eric Sandeen Reviewed-by: Dave Chinner Signed-off-by: Mark Tinguely --- diff --git a/include/builddefs.in b/include/builddefs.in index 81ebfcdb9..04590d2f8 100644 --- a/include/builddefs.in +++ b/include/builddefs.in @@ -106,7 +106,7 @@ GCCFLAGS = -funsigned-char -fno-strict-aliasing -Wall # -Wbitwise -Wno-transparent-union -Wno-old-initializer -Wno-decl ifeq ($(PKG_PLATFORM),linux) -PCFLAGS = -D_GNU_SOURCE -D_XOPEN_SOURCE=500 -D_FILE_OFFSET_BITS=64 $(GCCFLAGS) +PCFLAGS = -D_GNU_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=500 -D_FILE_OFFSET_BITS=64 $(GCCFLAGS) DEPENDFLAGS = -D__linux__ endif ifeq ($(PKG_PLATFORM),gnukfreebsd) diff --git a/io/pread.c b/io/pread.c index 0b9454bad..7e2ed7d64 100644 --- a/io/pread.c +++ b/io/pread.c @@ -16,6 +16,7 @@ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#include #include #include #include diff --git a/io/pwrite.c b/io/pwrite.c index 3689960fa..73acbac6f 100644 --- a/io/pwrite.c +++ b/io/pwrite.c @@ -16,6 +16,7 @@ * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ +#include #include #include #include