This is the mail archive of the gdb@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

suggested compile warnings


Hi,

I've always been configuring gdb with --enable-gdb-build-warnings=-Werror
and thought that there where a bunch of gcc compile warnings issued.
Looking more closely at my builds, that doesn't seem to be true.

For my own apps, I like to use '-Wall -Werror' as it lets the compiler
catch a lot of my stupid mistakes. I tried '-Wall -Werror' for gdb,
but that seems to be too restrictive for gdb source.

Does anyone else compile gdb with any of the -W<foo> gcc options?
Is there a recommended list of these which should be used?

For example, adding -Wunused (without -Werror), turns up 149 wanrings.
Most are unused variables, some are static decl's for functions that
aren't defined. Most if not all of these should be trivial to fix.

Ted Roth


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]