diff mbox

Fix building xfsprogs on 32-bit platforms (again)

Message ID 20170201045144.29488-1-ebiggers3@gmail.com (mailing list archive)
State Accepted, archived
Headers show

Commit Message

Eric Biggers Feb. 1, 2017, 4:51 a.m. UTC
From: Eric Biggers <ebiggers@google.com>

Building xfsprogs on 32-bit platforms was broken again by the recent
split of BUILD_CFLAGS from CFLAGS.  -D_FILE_OFFSET_BITS=64 was not added
to BUILD_CFLAGS, but in fact BUILD_CFLAGS is used to compile
crc32selftest, which includes xfs.h and therefore requires this
declaration.  Fix this by adding -D_FILE_OFFSET_BITS=64 to BUILD_CFLAGS.

Fixes: 0a71e3839630 ("build: Allow compiling xfsprogs in a cross compile environment")
Signed-off-by: Eric Biggers <ebiggers@google.com>
---
 include/builddefs.in | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Eric Sandeen Feb. 1, 2017, 10:44 p.m. UTC | #1
On 1/31/17 10:51 PM, Eric Biggers wrote:
> From: Eric Biggers <ebiggers@google.com>
> 
> Building xfsprogs on 32-bit platforms was broken again by the recent
> split of BUILD_CFLAGS from CFLAGS.  -D_FILE_OFFSET_BITS=64 was not added
> to BUILD_CFLAGS, but in fact BUILD_CFLAGS is used to compile
> crc32selftest, which includes xfs.h and therefore requires this
> declaration.  Fix this by adding -D_FILE_OFFSET_BITS=64 to BUILD_CFLAGS.
> 
> Fixes: 0a71e3839630 ("build: Allow compiling xfsprogs in a cross compile environment")
> Signed-off-by: Eric Biggers <ebiggers@google.com>

Oh, I missed this, and sent exactly the same patch to
the person who just reported it on the list, so yes,

Reviewed-by: Eric Sandeen <sandeen@redhat.com>

Sorry - I need to add 32-bit builds to my testing, obviously :(

> ---
>  include/builddefs.in | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/include/builddefs.in b/include/builddefs.in
> index 612b547d..6554e421 100644
> --- a/include/builddefs.in
> +++ b/include/builddefs.in
> @@ -26,7 +26,7 @@ MALLOCLIB = @malloc_lib@
>  LOADERFLAGS = @LDFLAGS@
>  LTLDFLAGS = @LDFLAGS@
>  CFLAGS = @CFLAGS@ -D_FILE_OFFSET_BITS=64
> -BUILD_CFLAGS = @BUILD_CFLAGS@
> +BUILD_CFLAGS = @BUILD_CFLAGS@ -D_FILE_OFFSET_BITS=64
>  
>  LIBRT = @librt@
>  LIBUUID = @libuuid@
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/include/builddefs.in b/include/builddefs.in
index 612b547d..6554e421 100644
--- a/include/builddefs.in
+++ b/include/builddefs.in
@@ -26,7 +26,7 @@  MALLOCLIB = @malloc_lib@
 LOADERFLAGS = @LDFLAGS@
 LTLDFLAGS = @LDFLAGS@
 CFLAGS = @CFLAGS@ -D_FILE_OFFSET_BITS=64
-BUILD_CFLAGS = @BUILD_CFLAGS@
+BUILD_CFLAGS = @BUILD_CFLAGS@ -D_FILE_OFFSET_BITS=64
 
 LIBRT = @librt@
 LIBUUID = @libuuid@