[libcamera-devel] [PATCH 2/4] meson: enable no-psabi for gcc 9+

Tomi Valkeinen tomi.valkeinen at iki.fi
Wed Oct 7 16:17:57 CEST 2020


On 07/10/2020 16:47, Laurent Pinchart wrote:
> On Wed, Oct 07, 2020 at 04:45:04PM +0300, Tomi Valkeinen wrote:
>> On 07/10/2020 16:29, Laurent Pinchart wrote:
>>> Hi Tomi and Kieran,
>>>
>>> On Wed, Oct 07, 2020 at 10:45:40AM +0100, Kieran Bingham wrote:
>>>> On 07/10/2020 10:22, Tomi Valkeinen wrote:
>>>>> I get the warnings related to psabi with:
>>>>>
>>>>> gcc 9.3.0 "arm-buildroot-linux-gnueabihf-g++.br_real (Buildroot 2020.08-24-gc5c5f1fa46) 9.3.0"
>>>>>
>>>>> Remove the check for gcc-9, so that -Wno-psabi is used on all gcc
>>>>> versions over 7.1.
>>>>
>>>> It doesn't seem unreasonable to keep this disabled for now.
>>>>
>>>> Should it be < 10 instead though?
>>>
>>> I was going to suggest the same, for the exact same reasons :-)
>>
>> So what is the reason, I didn't quite get that.
>>
>> Do we not get the warnings on gcc 10?
>>
>> Why not just enable -Wno-psabi if the compiler supports it?
> 
> In order to be notified of future ABI changes. Currently we get warned
> that an ABI we use changed on gcc-7.1, and that's alright. If we
> suppress the warning unconditionally, once gcc 11 gets released for
> example, it may warn us of ABI changes introduced in gcc 11. I would
> expect the gcc 7.1 ABI warning to get disabled at some point. I wonder
> if there's a way to disable ABI warnings of gcc <= 7 only.

Hmm... So is the suggestion to keep increasing the gcc version number in meson.build whenever
someone tries a more recent gcc version and gets the warning spam?

And if in the future there's a new ABI change, we hit the warnings, and then we again add a gcc
version range where we add -Wno-psabi to get rid of the warnings?

This sounds a bit silly. Perhaps I'm missing something. I'm not sure what is the point with these
warnings if the solution is always to add -Wno-psabi, which silences all psabi changes.

 Tomi


More information about the libcamera-devel mailing list