From: Eric Biggers <ebiggers@google.com>
To: Dave Chinner <david@fromorbit.com>
Cc: linux-xfs@vger.kernel.org
Subject: Re: [PATCH] Fix building xfsprogs on 32-bit platforms
Date: Wed, 30 Nov 2016 11:12:05 -0800 [thread overview]
Message-ID: <20161130191205.GA14029@google.com> (raw)
In-Reply-To: <20161129232548.GF31101@dastard>
Hi Dave,
On Wed, Nov 30, 2016 at 10:25:49AM +1100, Dave Chinner wrote:
>
> So, builddefs.in should really detect if autoconf set a "large file
> required" flag, and in that case add the _FILE_OFFSET_BITS value
> that autoconf has generated to the PCFLAGS variable, right? (PCFLAGS
> are "Platform CFLAGS")
>
> Or, if we are just going to unconditionally define
> -D_FILE_OFFSET_BITS=64 in CFLAGS, then the autoconf checks are
> completely useless and should be removed?
>
I don't believe it's possible to use the results of AC_SYS_LARGEFILE without
using a config header that is included *first* in all .c files.
So the other option is to define _FILE_OFFSET_BITS=64 ourselves in CFLAGS. (Or
PCFLAGS for just the platforms that need it; I know it's needed on 32-bit Linux,
but I don't know about other platforms.) And yes, in that case the autoconf
macros are useless and should be removed.
Sorry for not explaining more in the commit message --- I hadn't looked into the
details of what was going on with the autoconf macros (or that they were
recently added, for that matter) until you pointed them out.
Eric
> > The reason AC_NEED_LFS still passes is that 'configure' includes a
> > temporary header confdefs.h rather than the final generated
> > header, and the temporary header includes the _FILE_OFFSET_BITS
> > definition.
>
> IOWs, stupid code backed by ambiguous documentation means that
> developers that try to do the right thing still end up with broken
> builds.
>
> Eric, to speed things up a bit next time, can you try to explain how
> something is broken in the commit message, not just say "it's
> broken, fix it". This avoids the need to go back and forth multiple
> times just so we can understand what the problem is that you are
> fixing....
>
> Cheers,
>
> -Dave.
> --
> Dave Chinner
> david@fromorbit.com
prev parent reply other threads:[~2016-11-30 19:12 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-28 22:42 [PATCH] Fix building xfsprogs on 32-bit platforms Eric Biggers
2016-11-29 20:09 ` Christoph Hellwig
2016-11-29 21:44 ` Dave Chinner
2016-11-29 22:21 ` Eric Biggers
2016-11-29 23:25 ` Dave Chinner
2016-11-30 19:12 ` Eric Biggers [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20161130191205.GA14029@google.com \
--to=ebiggers@google.com \
--cc=david@fromorbit.com \
--cc=linux-xfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).