Am 03.11.22 um 09:58 schrieb Daniel P. Berrangé:
On Wed, Nov 02, 2022 at 09:22:58PM +0100, Stefan Weil via wrote:The configure script fails because it tries to compile small C programs with a main function which is declared with arguments argc and argv although those arguments are unused.Running `configure -extra-cflags=-Wunused-parameter` triggers the problem. configure for a native build does abort but shows the error in config.log. A cross build configure for Windows with Debian stable aborts with an error. Avoiding unused arguments fixes this.I'm not convinced that we should allow -extra-cflags to influence the configure compile checks at all, as there are likely more cases where arbitrary -W$warn flag will impact the checks, potentially causing configure to silently take the wrong action.
I partially agree, but configure should fail if invalid -extra-cflags are specified, and the checks must also respect additional include paths given by -extra-cflags of course.
And I think that the changes in my patch are an improvement in any case. Stefan
OpenPGP_0xE08C21D5677450AD.asc
Description: OpenPGP public key
OpenPGP_signature
Description: OpenPGP digital signature