[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] meson: fix botched compile check conversions

From: Paolo Bonzini
Subject: Re: [PATCH] meson: fix botched compile check conversions
Date: Tue, 16 Nov 2021 15:24:24 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.2.0

On 11/16/21 12:13, Daniel P. Berrangé wrote:
On Tue, Nov 16, 2021 at 10:38:34AM +0100, Paolo Bonzini wrote:
Fix a bunch of incorrect conversions from configure to Meson, which result
in different outcomes with --extra-cflags=-Werror.

pthread_setname_np needs "#define _GNU_SOURCE" on Linux (which I am using
also for the non-Linux check, so that it correctly fails with an error
about having too few parameters).

Fix struct checks to use has_type instead of has_symbol, and "#define
_GNU_SOURCE" too in the case of struct mmsghdr.

Ok, so relies on fact that passing an incorrect number of arguments
is a fatal error, when function prototypes are available, even
without -Werror being set.

Side note, GCC looks to be trying to make explicit function prototypes
mandatory at last


Yes, and that's also why Meson adds the -Werror=implicit-declaration option; these days it's simply too dangerous to assume a function is present, if it links but you don't really know which header it comes from.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]