Wireshark-dev: Re: [Wireshark-dev] [Wireshark-commits] rev 21195: /trunk/ /trunk/: configure.in
From: "ronnie sahlberg" <ronniesahlberg@xxxxxxxxx>
Date: Mon, 26 Mar 2007 06:53:51 +0000
I just checked in a different test for configure.in in trunk that works for me.

Please review.




On 3/26/07, Jeff Morriss <jeff.morriss@xxxxxxxxxxx> wrote:

Hmmm, that's weird, it works for me.

What version of GCC are you using?

What does:

echo yes | gcc -E -Wfoodeclaration-after-statement -

produce for you?  For me I get only:

> cc1: error: unrecognized command line option
"-Wfoodeclaration-after-statement"
> # 1 "<stdin>"

(but no "yes").

Oh, OK, it looks like older versions of GCC (I just tried 3.2) don't
error out when presented an invalid command line argument.

Hmmm, at least it should still compile on those GCC versions, but now I
have to think of a different test...

ronnie sahlberg wrote:
> The checks in configure.in
> for this doesnt work properly for
> GCC versions which do not support this -W directive.
>
> Eventhough it is not supported by GCC
> AC_MSG_CHECKING(to see if we can add '-Wdeclaration-after-statement'...
> still adds it to the compile flags.
>
> I will see if i can figure out why the test fails.
> Me and automake/configure are not on friendly terms.
>
>
>
> On 3/26/07, morriss@xxxxxxxxxxxxx <morriss@xxxxxxxxxxxxx> wrote:
>> http://anonsvn.wireshark.org/viewvc/viewvc.cgi?view=rev&revision=21195
>>
>> User: morriss
>> Date: 2007/03/26 12:32 AM
>>
>> Log:
>>  If we're using gcc, try to use -Wdeclaration-after-statement to catch
more
>> non-portable commits.  I'm not sure if this is the Right Way to test to
see
>> if the compiler can handle a specific option but it's simple and
efficient
>> enough.
>>
>> Directory: /trunk/
>>   Changes    Path            Action
>>   +8 -0      configure.in    Modified
>>
>> _______________________________________________
>> Wireshark-commits mailing list
>> Wireshark-commits@xxxxxxxxxxxxx
>> http://www.wireshark.org/mailman/listinfo/wireshark-commits
>>
> _______________________________________________
> Wireshark-dev mailing list
> Wireshark-dev@xxxxxxxxxxxxx
> http://www.wireshark.org/mailman/listinfo/wireshark-dev
>
>
_______________________________________________
Wireshark-dev mailing list
Wireshark-dev@xxxxxxxxxxxxx
http://www.wireshark.org/mailman/listinfo/wireshark-dev