configure.in -Wno-unused-parameter
if eval "test x$GCC = xyes"; then .. if test "`echo $CFLAGS | grep '\-W[^a]' 2> /dev/null`" = ""; then if test "`$CC -v 2>&1 | grep 'version 3'`" != ""; then CFLAGS="$CFLAGS -W -Wno-unused-parameter" fi fi .. fi It checks for 3.x specifically. 3.0 came out on June 18, 2001. And of course 4.x has been out since...let's see...April 20, 2005. 2.95 was still apparently around back in http://lists.auriga.wearlab.de/pipermail/dillo-dev/2003-December/001565.html , which prompted this code at the time. Can I rip out the version-checking and make it into an ordinary case of adding the argument if it isn't already in CFLAGS?
On Sun, May 15, 2011 at 10:34:00PM +0000, corvid wrote:
if eval "test x$GCC = xyes"; then .. if test "`echo $CFLAGS | grep '\-W[^a]' 2> /dev/null`" = ""; then if test "`$CC -v 2>&1 | grep 'version 3'`" != ""; then CFLAGS="$CFLAGS -W -Wno-unused-parameter" fi fi .. fi
It checks for 3.x specifically. 3.0 came out on June 18, 2001.
And of course 4.x has been out since...let's see...April 20, 2005.
2.95 was still apparently around back in http://lists.auriga.wearlab.de/pipermail/dillo-dev/2003-December/001565.html , which prompted this code at the time.
Can I rip out the version-checking and make it into an ordinary case of adding the argument if it isn't already in CFLAGS?
Sure. -- Cheers Jorge.-
Jorge wrote:
On Sun, May 15, 2011 at 10:34:00PM +0000, corvid wrote:
if eval "test x$GCC = xyes"; then .. if test "`echo $CFLAGS | grep '\-W[^a]' 2> /dev/null`" = ""; then if test "`$CC -v 2>&1 | grep 'version 3'`" != ""; then CFLAGS="$CFLAGS -W -Wno-unused-parameter" fi fi .. fi
It checks for 3.x specifically. 3.0 came out on June 18, 2001.
And of course 4.x has been out since...let's see...April 20, 2005.
2.95 was still apparently around back in http://lists.auriga.wearlab.de/pipermail/dillo-dev/2003-December/001565.html , which prompted this code at the time.
Can I rip out the version-checking and make it into an ordinary case of adding the argument if it isn't already in CFLAGS?
Right after committing it, I thought, "Wait, this is -Wno-unused-parameter, not -Wunused-parameter. Why do we want this?" So, new proposal: How about I remove it completely?
On Mon, May 16, 2011 at 01:17:45AM +0000, corvid wrote:
Jorge wrote:
On Sun, May 15, 2011 at 10:34:00PM +0000, corvid wrote:
if eval "test x$GCC = xyes"; then .. if test "`echo $CFLAGS | grep '\-W[^a]' 2> /dev/null`" = ""; then if test "`$CC -v 2>&1 | grep 'version 3'`" != ""; then CFLAGS="$CFLAGS -W -Wno-unused-parameter" fi fi .. fi
It checks for 3.x specifically. 3.0 came out on June 18, 2001.
And of course 4.x has been out since...let's see...April 20, 2005.
2.95 was still apparently around back in http://lists.auriga.wearlab.de/pipermail/dillo-dev/2003-December/001565.html , which prompted this code at the time.
Can I rip out the version-checking and make it into an ordinary case of adding the argument if it isn't already in CFLAGS?
Right after committing it, I thought, "Wait, this is -Wno-unused-parameter, not -Wunused-parameter. Why do we want this?"
Some callbacks don't make use of default parameters and this option avoids a lot of noise (making it simpler to spot other warnings).
So, new proposal: How about I remove it completely?
Currently I use gcc-4.4.3, and somehow the option gets into the compiler parameters, so I guess it makes its job. (I haven't checked without it to be sure). -- Cheers Jorge.-
Jorge wrote:
On Mon, May 16, 2011 at 01:17:45AM +0000, corvid wrote:
Jorge wrote:
On Sun, May 15, 2011 at 10:34:00PM +0000, corvid wrote:
if eval "test x$GCC = xyes"; then .. if test "`echo $CFLAGS | grep '\-W[^a]' 2> /dev/null`" = ""; then if test "`$CC -v 2>&1 | grep 'version 3'`" != ""; then CFLAGS="$CFLAGS -W -Wno-unused-parameter" fi fi .. fi
It checks for 3.x specifically. 3.0 came out on June 18, 2001.
And of course 4.x has been out since...let's see...April 20, 2005.
2.95 was still apparently around back in http://lists.auriga.wearlab.de/pipermail/dillo-dev/2003-December/001565.html , which prompted this code at the time.
Can I rip out the version-checking and make it into an ordinary case of adding the argument if it isn't already in CFLAGS?
Right after committing it, I thought, "Wait, this is -Wno-unused-parameter, not -Wunused-parameter. Why do we want this?"
Some callbacks don't make use of default parameters and this option avoids a lot of noise (making it simpler to spot other warnings).
I know we had that one in a_Http_ccc() that is suppressed with a (void)Data2; but I never see any other warnings around.
----------------------------------------
From: corvid@lavabit.com Date: Sun, 15 May 2011 22:34:00 +0000 To: dillo-dev@dillo.org Subject: [Dillo-dev] configure.in -Wno-unused-parameter
if eval "test x$GCC = xyes"; then .. if test "`echo $CFLAGS | grep '\-W[^a]' 2> /dev/null`" = ""; then if test "`$CC -v 2>&1 | grep 'version 3'`" != ""; then CFLAGS="$CFLAGS -W -Wno-unused-parameter" fi fi .. fi
It checks for 3.x specifically. 3.0 came out on June 18, 2001.
And of course 4.x has been out since...let's see...April 20, 2005.
2.95 was still apparently around back in http://lists.auriga.wearlab.de/pipermail/dillo-dev/2003-December/001565.html , which prompted this code at the time.
Can I rip out the version-checking and make it into an ordinary case of adding the argument if it isn't already in CFLAGS?
As an aside, why not change -W to -Wextra? ?While they are both supported, the gcc manual encourages the use of -Wextra. ?My guess is that -W will eventually be deprecated. ?On the other hand, how far back does gcc support -Wextra? ?I cannot remember when that change was made.
Rob wrote:
As an aside, why not change -W to -Wextra? ?While they are both supported, the gcc manual encourages the use of -Wextra. ?My guess is that -W will eventually be deprecated. ?On the other hand, how far back does gcc support -Wextra? ?I cannot remember when that change was made.
Apparently -Wextra came along in 3.4, which is from 2004. I personally lean toward leaving it alone unless they give the impression that they are actually going to remove -W at some point.
From: corvid@lavabit.com Apparently -Wextra came along in 3.4, which is from 2004. I personally lean toward leaving it alone unless they give the impression that they are actually going to remove -W at some point.
Yeah - probably best to leave well enough alone, seeing as somewhere someone could ?be trying to build with an older version of gcc. ?If and when the gcc devs break it, then it can be changed accordingly.
participants (3)
-
corvid@lavabit.com
-
jcid@dillo.org
-
mr_semantics@hotmail.com