-Werror=format in developer builds (was: Re: No longer supported on FC13?)

Andrew Bartlett abartlet at samba.org
Tue Jul 31 17:11:17 MDT 2012

On Tue, 2012-07-31 at 14:39 -0400, Charles Tryon wrote:
> I've been building Samba4 on an older Fc13 box for a long time now, and I
> just started running into a problem where I can't build there.  I've gone
> to the point of cleanly removing the samba-master directory and rebuilding
> the git repository from scratch, and I'm still getting the same error.
> ...
> [2496/3924] Compiling source4/heimdal/lib/com_err/error.c
> ../source4/heimdal/lib/com_err/error.c: In function ‘com_right_r’:
> ../source4/heimdal/lib/com_err/error.c:68: error: format ‘%d’ expects type
> ‘int’, but argument 4 has type ‘long int’
> ../source4/heimdal/lib/com_err/error.c:68: error: format ‘%d’ expects type
> ‘int’, but argument 4 has type ‘long int’
> I'm wondering... is the build no longer supported on Fc13?  I have to
> admit, it IS pretty ragged around the edges...
> If not, then I will try to move the test domain I've had there to another
> (CentOS?) box and see if it works there.  (Currently, that box is still
> able to build and run the quicktest.)

I have added -Werror=format to the default configure line in developer
builds (also applies to recursive builds of smbtorture4 from the
autoconf build until I change that again). 

This asserts that this particular warning should never happen in the
build, because it is really important to find and fix these errors.
These warnings (now errors) are not hard to fix, we just need to correct
the error and sync it back upstream with Heimdal. 

In the meantime, you can configure with --enable-debug instead, but you
won't be able to run 'make test'.

If this becomes too much trouble, I can turn it back off, but if
possible I would like to slowly increase the number of these warnings
that we make fatal for developers so we can slowly and permanently
eradicate these from the tree. 

Andrew Bartlett

Andrew Bartlett                                http://samba.org/~abartlet/
Authentication Developer, Samba Team           http://samba.org

More information about the samba-technical mailing list