This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC 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]

Re: Can I build gcc so -Wall option is always on ?


Dennis Clarke wrote:
I'm helping on the Sage maths project

http://www.sagemath.org/

where there are a large number of packages built, most of which ignore
CFLAGS.
(Quite a few ignore CC and CXX too!) I'd like to display all the warnings,
but
its hard when people overwrite CFLAGS.

Is there a way I can build gcc such that effectively "-Wall" is enabled
all the
time?

If not, could anyone point me to where in the source code I might be able
to
hack it, to build a version which displays all the warnings?

I think it would actually be quite a useful option to have when one
configures gcc!

i.e

configure --prefix=/some/dir --always-display-all-warnings !!!


That isn't the only option I'd like to enforce. :-)

As a matter of interest, what would be your choice of options to enforce?


It really does annoy me when I see things like this.

g++ -O2 -g -Wa,-W -fno-exceptions -Wno-deprecated -DINCLUDE_PARI \
-I/rootpool2/local/kirkby/sage-4.1.1.alpha0/local/include/pari -I/rootpool2/local/kirkby/sage-4.1.1.alpha0/local/include\
-I ../include/ -L/rootpool2/local/kirkby/sage-4.1.1.alpha0/local/lib \
cmdline.c \
Lcommandline.cc Lcommandline_elliptic.cc Lcommandline_globals.cc \
Lcommandline_misc.cc Lcommandline_numbertheory.cc \
Lcommandline_twist.cc Lcommandline_values_zeros.cc \
Lgamma.cc Lglobals.cc Lmisc.cc Lriemannsiegel.cc \
-o lcalc -lpari -lmpfr -lgmpxx -lgmp -liberty
/usr/ccs/bin/as: error: unknown option 'W'



where someone has tried to add an option to the GNU assembler to suppress warnings, but it breaks their code with the Sun assembler. It would have been far better to actually fix the cause of warnings.


Merry Christmas David, you were really awesome and helpful this year. I
certainly hope that I can gain access to that HPUX server of yours again
in the new year and finish off GCC 4.3.4 as a reasonable package.  Maybe
now that it is colder you will have a reason to leave it running longer
and generate heat :-)



Merry Christmas to you too Dennis.


The HP-UX box is running now, and has been most of the time. I thought I sent you an email about it. Feel free to use it. Access is only via ssh now, but since port 22 is used for ssh to another machine, I've redirected the external port 2022 to this machine. So ssh to port 2022 and you will get to the HP-UX machine. I finally got around to installing a server and disabling telnet and ftp! Not before time.

BTW, you said you would get me an account on a 1.6 GHz SPARC, but I did not get any details.

Dave


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