Re: AC_CHECK_DECL has wrong results on macOS

"Zack Weinberg" <[email protected]> Tue, 27 May 2025 14:15:34 -0400
Newsgroups gmane.comp.sysutils.autoconf.bugs
Message-ID <[email protected]>
On Mon, May 26, 2025, at 5:18 AM, Bruno Haible via Bug reports for autoconf wrote:
> Hi Paul,
>
>> > Here's a proposed fix for the issue along these lines.
>> 
>> Thanks. It'd be nicer if AC_CHECK_DECL didn't require AC_CANONICAL_HOST. 
>> We can do that by checking inside the C program rather than using 
>> AC_CANONICAL_HOST.
>
> This comes with the cost of an extra compiler invocation on all non-macOS
> systems. But I understand the desire to avoid AC_CANONICAL_HOST.

Just wanna endorse avoiding AC_CANONICAL_HOST in something as basic as
AC_CHECK_DECL.  The increased use of AC_CANONICAL_HOST in 2.70 and 2.71
caused problems for people who weren't expecting to need to ship
config.{sub,guess}, and the macros involved were way less frequently used.

zw