Patchwork [1/2] libx11.inc: disable warnings that don't work on certain compilers

login
register
mail settings
Submitter Matthew McClintock
Date Sept. 24, 2012, 7:55 p.m.
Message ID <1348516546-26005-1-git-send-email-msm@freescale.com>
Download mbox | patch
Permalink /patch/37137/
State New
Headers show

Comments

Matthew McClintock - Sept. 24, 2012, 7:55 p.m.
Fixes these sorts of issues present on older gcc (CentOS 5.x in this case)

| cc1: error: unrecognized command line option "-Werror=implicit"
| cc1: error: unrecognized command line option "-Werror=nonnull"
| cc1: error: unrecognized command line option "-Werror=init-self"
| cc1: error: unrecognized command line option "-Werror=main"
| cc1: error: unrecognized command line option "-Werror=missing-braces"
| cc1: error: unrecognized command line option "-Werror=sequence-point"
| cc1: error: unrecognized command line option "-Werror=return-type"
| cc1: error: unrecognized command line option "-Werror=trigraphs"
| cc1: error: unrecognized command line option "-Werror=array-bounds"
| cc1: error: unrecognized command line option "-Werror=write-strings"
| cc1: error: unrecognized command line option "-Werror=address"
| cc1: error: unrecognized command line option "-Werror=int-to-pointer-cast"
| cc1: error: unrecognized command line option "-Werror=pointer-to-int-cast"

Signed-off-by: Matthew McClintock <msm@freescale.com>
---
 meta/recipes-graphics/xorg-lib/libx11.inc |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
Martin Jansa - Sept. 24, 2012, 8 p.m.
On Mon, Sep 24, 2012 at 02:55:45PM -0500, Matthew McClintock wrote:
> Fixes these sorts of issues present on older gcc (CentOS 5.x in this case)
> 
> | cc1: error: unrecognized command line option "-Werror=implicit"
> | cc1: error: unrecognized command line option "-Werror=nonnull"
> | cc1: error: unrecognized command line option "-Werror=init-self"
> | cc1: error: unrecognized command line option "-Werror=main"
> | cc1: error: unrecognized command line option "-Werror=missing-braces"
> | cc1: error: unrecognized command line option "-Werror=sequence-point"
> | cc1: error: unrecognized command line option "-Werror=return-type"
> | cc1: error: unrecognized command line option "-Werror=trigraphs"
> | cc1: error: unrecognized command line option "-Werror=array-bounds"
> | cc1: error: unrecognized command line option "-Werror=write-strings"
> | cc1: error: unrecognized command line option "-Werror=address"
> | cc1: error: unrecognized command line option "-Werror=int-to-pointer-cast"
> | cc1: error: unrecognized command line option "-Werror=pointer-to-int-cast"

Shouldn't it be applied only for -native? version?

Cheers,

> 
> Signed-off-by: Matthew McClintock <msm@freescale.com>
> ---
>  meta/recipes-graphics/xorg-lib/libx11.inc |    3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/meta/recipes-graphics/xorg-lib/libx11.inc b/meta/recipes-graphics/xorg-lib/libx11.inc
> index 3ecd9e5..0e99442 100644
> --- a/meta/recipes-graphics/xorg-lib/libx11.inc
> +++ b/meta/recipes-graphics/xorg-lib/libx11.inc
> @@ -11,7 +11,7 @@ inherit siteinfo
>  FILESPATH = "${FILE_DIRNAME}/libx11"
>  
>  PE = "1"
> -INC_PR = "r8"
> +INC_PR = "r9"
>  
>  PROVIDES = "virtual/libx11"
>  
> @@ -23,6 +23,7 @@ DEPENDS += "xproto xextproto xtrans libxcb kbproto inputproto"
>  DEPENDS += "xproto-native"
>  
>  EXTRA_OECONF += "--with-keysymdefdir=${STAGING_INCDIR}/X11/"
> +EXTRA_OEMAKE = '-e CWARNFLAGS=""'
>  
>  # Let people with incredibly archaic requirements enable Xcms and BigFont, but
>  # disable them by default.
> -- 
> 1.7.9.7
> 
> 
> 
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core
McClintock Matthew-B29882 - Sept. 24, 2012, 8:06 p.m.
On Mon, Sep 24, 2012 at 3:00 PM, Martin Jansa <martin.jansa@gmail.com> wrote:
> On Mon, Sep 24, 2012 at 02:55:45PM -0500, Matthew McClintock wrote:
>> Fixes these sorts of issues present on older gcc (CentOS 5.x in this case)
>>
>> | cc1: error: unrecognized command line option "-Werror=implicit"
>> | cc1: error: unrecognized command line option "-Werror=nonnull"
>> | cc1: error: unrecognized command line option "-Werror=init-self"
>> | cc1: error: unrecognized command line option "-Werror=main"
>> | cc1: error: unrecognized command line option "-Werror=missing-braces"
>> | cc1: error: unrecognized command line option "-Werror=sequence-point"
>> | cc1: error: unrecognized command line option "-Werror=return-type"
>> | cc1: error: unrecognized command line option "-Werror=trigraphs"
>> | cc1: error: unrecognized command line option "-Werror=array-bounds"
>> | cc1: error: unrecognized command line option "-Werror=write-strings"
>> | cc1: error: unrecognized command line option "-Werror=address"
>> | cc1: error: unrecognized command line option "-Werror=int-to-pointer-cast"
>> | cc1: error: unrecognized command line option "-Werror=pointer-to-int-cast"
>
> Shouldn't it be applied only for -native? version?

That's reasonable. But, suppressing warnings to compile logs also did
not seem to matter much since we don't go line by line on warnings in
compile logs (does anyone?). I'll go with the consensus though.

-M

>
> Cheers,
>
>>
>> Signed-off-by: Matthew McClintock <msm@freescale.com>
>> ---
>>  meta/recipes-graphics/xorg-lib/libx11.inc |    3 ++-
>>  1 file changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/meta/recipes-graphics/xorg-lib/libx11.inc b/meta/recipes-graphics/xorg-lib/libx11.inc
>> index 3ecd9e5..0e99442 100644
>> --- a/meta/recipes-graphics/xorg-lib/libx11.inc
>> +++ b/meta/recipes-graphics/xorg-lib/libx11.inc
>> @@ -11,7 +11,7 @@ inherit siteinfo
>>  FILESPATH = "${FILE_DIRNAME}/libx11"
>>
>>  PE = "1"
>> -INC_PR = "r8"
>> +INC_PR = "r9"
>>
>>  PROVIDES = "virtual/libx11"
>>
>> @@ -23,6 +23,7 @@ DEPENDS += "xproto xextproto xtrans libxcb kbproto inputproto"
>>  DEPENDS += "xproto-native"
>>
>>  EXTRA_OECONF += "--with-keysymdefdir=${STAGING_INCDIR}/X11/"
>> +EXTRA_OEMAKE = '-e CWARNFLAGS=""'
>>
>>  # Let people with incredibly archaic requirements enable Xcms and BigFont, but
>>  # disable them by default.
>> --
>> 1.7.9.7
>>
>>
>>
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core@lists.openembedded.org
>> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core
>
> --
> Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com
>
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core
>
McClintock Matthew-B29882 - Sept. 24, 2012, 8:43 p.m.
On Mon, Sep 24, 2012 at 3:06 PM, Matthew McClintock <msm@freescale.com> wrote:
> On Mon, Sep 24, 2012 at 3:00 PM, Martin Jansa <martin.jansa@gmail.com> wrote:
>> On Mon, Sep 24, 2012 at 02:55:45PM -0500, Matthew McClintock wrote:
>>> Fixes these sorts of issues present on older gcc (CentOS 5.x in this case)
>>>
>>> | cc1: error: unrecognized command line option "-Werror=implicit"
>>> | cc1: error: unrecognized command line option "-Werror=nonnull"
>>> | cc1: error: unrecognized command line option "-Werror=init-self"
>>> | cc1: error: unrecognized command line option "-Werror=main"
>>> | cc1: error: unrecognized command line option "-Werror=missing-braces"
>>> | cc1: error: unrecognized command line option "-Werror=sequence-point"
>>> | cc1: error: unrecognized command line option "-Werror=return-type"
>>> | cc1: error: unrecognized command line option "-Werror=trigraphs"
>>> | cc1: error: unrecognized command line option "-Werror=array-bounds"
>>> | cc1: error: unrecognized command line option "-Werror=write-strings"
>>> | cc1: error: unrecognized command line option "-Werror=address"
>>> | cc1: error: unrecognized command line option "-Werror=int-to-pointer-cast"
>>> | cc1: error: unrecognized command line option "-Werror=pointer-to-int-cast"
>>
>> Shouldn't it be applied only for -native? version?
>
> That's reasonable. But, suppressing warnings to compile logs also did
> not seem to matter much since we don't go line by line on warnings in
> compile logs (does anyone?). I'll go with the consensus though.

Actually, this makes sense now because I'm seeing issues with
non-nativesdk packages with the '-e' I've added... thought I build
tested that... ;(

-M

>
> -M
>
>>
>> Cheers,
>>
>>>
>>> Signed-off-by: Matthew McClintock <msm@freescale.com>
>>> ---
>>>  meta/recipes-graphics/xorg-lib/libx11.inc |    3 ++-
>>>  1 file changed, 2 insertions(+), 1 deletion(-)
>>>
>>> diff --git a/meta/recipes-graphics/xorg-lib/libx11.inc b/meta/recipes-graphics/xorg-lib/libx11.inc
>>> index 3ecd9e5..0e99442 100644
>>> --- a/meta/recipes-graphics/xorg-lib/libx11.inc
>>> +++ b/meta/recipes-graphics/xorg-lib/libx11.inc
>>> @@ -11,7 +11,7 @@ inherit siteinfo
>>>  FILESPATH = "${FILE_DIRNAME}/libx11"
>>>
>>>  PE = "1"
>>> -INC_PR = "r8"
>>> +INC_PR = "r9"
>>>
>>>  PROVIDES = "virtual/libx11"
>>>
>>> @@ -23,6 +23,7 @@ DEPENDS += "xproto xextproto xtrans libxcb kbproto inputproto"
>>>  DEPENDS += "xproto-native"
>>>
>>>  EXTRA_OECONF += "--with-keysymdefdir=${STAGING_INCDIR}/X11/"
>>> +EXTRA_OEMAKE = '-e CWARNFLAGS=""'
>>>
>>>  # Let people with incredibly archaic requirements enable Xcms and BigFont, but
>>>  # disable them by default.
>>> --
>>> 1.7.9.7
>>>
>>>
>>>
>>> _______________________________________________
>>> Openembedded-core mailing list
>>> Openembedded-core@lists.openembedded.org
>>> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core
>>
>> --
>> Martin 'JaMa' Jansa     jabber: Martin.Jansa@gmail.com
>>
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core@lists.openembedded.org
>> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core
>>
Ross Burton - Sept. 24, 2012, 8:52 p.m.
On 24 September 2012 21:06, McClintock Matthew-B29882
<B29882@freescale.com> wrote:
>> Shouldn't it be applied only for -native? version?
>
> That's reasonable. But, suppressing warnings to compile logs also did
> not seem to matter much since we don't go line by line on warnings in
> compile logs (does anyone?). I'll go with the consensus though.

I'd prefer this to be a -native only thing too.

Ross
Chris Larson - Sept. 24, 2012, 9:07 p.m.
On Mon, Sep 24, 2012 at 1:43 PM, McClintock Matthew-B29882
<B29882@freescale.com> wrote:
> On Mon, Sep 24, 2012 at 3:06 PM, Matthew McClintock <msm@freescale.com> wrote:
>> On Mon, Sep 24, 2012 at 3:00 PM, Martin Jansa <martin.jansa@gmail.com> wrote:
>>> On Mon, Sep 24, 2012 at 02:55:45PM -0500, Matthew McClintock wrote:
>>>> Fixes these sorts of issues present on older gcc (CentOS 5.x in this case)
>>>>
>>>> | cc1: error: unrecognized command line option "-Werror=implicit"
>>>> | cc1: error: unrecognized command line option "-Werror=nonnull"
>>>> | cc1: error: unrecognized command line option "-Werror=init-self"
>>>> | cc1: error: unrecognized command line option "-Werror=main"
>>>> | cc1: error: unrecognized command line option "-Werror=missing-braces"
>>>> | cc1: error: unrecognized command line option "-Werror=sequence-point"
>>>> | cc1: error: unrecognized command line option "-Werror=return-type"
>>>> | cc1: error: unrecognized command line option "-Werror=trigraphs"
>>>> | cc1: error: unrecognized command line option "-Werror=array-bounds"
>>>> | cc1: error: unrecognized command line option "-Werror=write-strings"
>>>> | cc1: error: unrecognized command line option "-Werror=address"
>>>> | cc1: error: unrecognized command line option "-Werror=int-to-pointer-cast"
>>>> | cc1: error: unrecognized command line option "-Werror=pointer-to-int-cast"
>>>
>>> Shouldn't it be applied only for -native? version?
>>
>> That's reasonable. But, suppressing warnings to compile logs also did
>> not seem to matter much since we don't go line by line on warnings in
>> compile logs (does anyone?). I'll go with the consensus though.
>
> Actually, this makes sense now because I'm seeing issues with
> non-nativesdk packages with the '-e' I've added... thought I build
> tested that... ;(

Why is -e being added? It's almost always better to add the vars you
need explicitly, imo. I wish we could change the default EXTRA_OEMAKE
to drop it, personally. It can cause odd unintended consequences.
McClintock Matthew-B29882 - Sept. 24, 2012, 10:31 p.m.
On Mon, Sep 24, 2012 at 4:07 PM, Chris Larson <clarson@kergoth.com> wrote:
> On Mon, Sep 24, 2012 at 1:43 PM, McClintock Matthew-B29882
> <B29882@freescale.com> wrote:
>> On Mon, Sep 24, 2012 at 3:06 PM, Matthew McClintock <msm@freescale.com> wrote:
>>> On Mon, Sep 24, 2012 at 3:00 PM, Martin Jansa <martin.jansa@gmail.com> wrote:
>>>> On Mon, Sep 24, 2012 at 02:55:45PM -0500, Matthew McClintock wrote:
>>>>> Fixes these sorts of issues present on older gcc (CentOS 5.x in this case)
>>>>>
>>>>> | cc1: error: unrecognized command line option "-Werror=implicit"
>>>>> | cc1: error: unrecognized command line option "-Werror=nonnull"
>>>>> | cc1: error: unrecognized command line option "-Werror=init-self"
>>>>> | cc1: error: unrecognized command line option "-Werror=main"
>>>>> | cc1: error: unrecognized command line option "-Werror=missing-braces"
>>>>> | cc1: error: unrecognized command line option "-Werror=sequence-point"
>>>>> | cc1: error: unrecognized command line option "-Werror=return-type"
>>>>> | cc1: error: unrecognized command line option "-Werror=trigraphs"
>>>>> | cc1: error: unrecognized command line option "-Werror=array-bounds"
>>>>> | cc1: error: unrecognized command line option "-Werror=write-strings"
>>>>> | cc1: error: unrecognized command line option "-Werror=address"
>>>>> | cc1: error: unrecognized command line option "-Werror=int-to-pointer-cast"
>>>>> | cc1: error: unrecognized command line option "-Werror=pointer-to-int-cast"
>>>>
>>>> Shouldn't it be applied only for -native? version?
>>>
>>> That's reasonable. But, suppressing warnings to compile logs also did
>>> not seem to matter much since we don't go line by line on warnings in
>>> compile logs (does anyone?). I'll go with the consensus though.
>>
>> Actually, this makes sense now because I'm seeing issues with
>> non-nativesdk packages with the '-e' I've added... thought I build
>> tested that... ;(
>
> Why is -e being added? It's almost always better to add the vars you
> need explicitly, imo. I wish we could change the default EXTRA_OEMAKE
> to drop it, personally. It can cause odd unintended consequences.

I think this was a holdover from trying to fix the issue fixed by
patch 2/2. I don't think it belogs - I was working on this Friday and
forgot everything today ;)

-M

> --
> Christopher Larson
>
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core
McClintock Matthew-B29882 - Sept. 24, 2012, 10:55 p.m.
On Mon, Sep 24, 2012 at 3:52 PM, Burton, Ross <ross.burton@intel.com> wrote:
> On 24 September 2012 21:06, McClintock Matthew-B29882
> <B29882@freescale.com> wrote:
>>> Shouldn't it be applied only for -native? version?
>>
>> That's reasonable. But, suppressing warnings to compile logs also did
>> not seem to matter much since we don't go line by line on warnings in
>> compile logs (does anyone?). I'll go with the consensus though.
>
> I'd prefer this to be a -native only thing too.

I think the CWARNFLAGS needs to be on all the though (native,
nativesdk, etc), '-e' can go away entirely.

-M

>
> Ross
>
> _______________________________________________
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core

Patch

diff --git a/meta/recipes-graphics/xorg-lib/libx11.inc b/meta/recipes-graphics/xorg-lib/libx11.inc
index 3ecd9e5..0e99442 100644
--- a/meta/recipes-graphics/xorg-lib/libx11.inc
+++ b/meta/recipes-graphics/xorg-lib/libx11.inc
@@ -11,7 +11,7 @@  inherit siteinfo
 FILESPATH = "${FILE_DIRNAME}/libx11"
 
 PE = "1"
-INC_PR = "r8"
+INC_PR = "r9"
 
 PROVIDES = "virtual/libx11"
 
@@ -23,6 +23,7 @@  DEPENDS += "xproto xextproto xtrans libxcb kbproto inputproto"
 DEPENDS += "xproto-native"
 
 EXTRA_OECONF += "--with-keysymdefdir=${STAGING_INCDIR}/X11/"
+EXTRA_OEMAKE = '-e CWARNFLAGS=""'
 
 # Let people with incredibly archaic requirements enable Xcms and BigFont, but
 # disable them by default.