On 14-08-07 02:58 PM, Colomban Wendling wrote:
Le 07/08/2014 23:38, Enrico Tröger a écrit :
On 07/08/14 18:41, Colomban Wendling wrote:
Le 07/08/2014 18:24, Enrico Tröger a écrit :
[...] I'd like to make the nightly builds a bit stricter especially if it helps to spoil out such problems.
Any idea how to make such warnings error without using -Werror? I'm afraid -Werror is too hard for cross-compiling.
-Werror-implicit-function-declaration
I use the following when building Geany, and although it shows a few warnings (one in Scintilla that is fixed upstream, a few harmless const promotions, and a few non-literals passed as printf-like formats) it's pretty neat, maybe we'd like to be able to look at these in the logs. Not sure it's so important though.
-Wall -Wextra -g -O2 -Wunused -Wno-unused-parameter -Wunreachable-code -Wformat=2 -Wundef -Wshadow -Wpointer-arith -Wwrite-strings -Waggregate-return -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wmissing-noreturn -Wmissing-format-attribute -Wredundant-decls -Wnested-externs -Werror-implicit-function-declaration -Wno-deprecated-declarations
Thanks. I applied these to the Windows nightly builds and also printed the used CFLAGS into the logfile (for reference).
Hum, this is weird. There are many more warnings that I saw locally, and the compiled code looks outdated -- when I go to e.g. "src/symbols.c:579: warning: will never be executed", I see... an accolade starting the function body.
s/accolade/brace/ ... maybe the hook/timer that updates from Git stopped working or something?
Also, the headers used seem to generate a lot of shadowing warnings, so maybe we should disable this one. Though, some are really weird, like having a math.h having a global "y0" symbol!?
Looking in my MinGW math.h, it seems you need to define _NO_OLDNAMES to get rid of those non-ANSII names. It might also be useful to define __STRICT_ANSI__ to get rid of more non-std/non-prefixed names.
Anyway, as-is it's not really useful, so maybe we should either fix the warnings or remove the flags triggering them when not important.
It would be a lot more useful if there's a way to hide errors that originate in "system headers" (ie. not any of ours).
@Enrico, is there anyway to make the "nightlies" rebuild on a Git hook instead of only once per day? Like maybe giving 10 minutes buffer time to allow merging massive branches without re-compiling a bunch of times. It would be more immediate feedback on how badly one has broken Windows build :)
Cheers, Matthew Brush