Subject: Re: bug#49901: Bug in build c-ares [too many loops]

From: Nick Bowler <[email-masked]>
Date: Tue, 17 Aug 2021 17:13:13 -0400

On 17/08/2021, Brad House via Bug reports for Automake
<[email-masked]> wrote:
> This ended up being the fix to needing to run autoreconf -fi multiple
> times:
> https://github.com/c-ares/c-ares/commit/e73fb47

Probably an OK workaround.  I suspect the effect of this change is to get
aclocal to pull in the ax_require_defined.m4 file on the first pass which
avoids the "too many loops" problem but not the include order problem
(which may not actually matter).

> After that, there is also the issue that the newer ax_code_coverage.m4
> that is automatically pulled in is not API compatible as it removes
> @CODE_COVERAGE_RULES@ which isn't too friendly, plus adds a slew of
> additional .m4 dependencies that had to be imported.

You can avoid things being automatically imported by not enabling
aclocal --install mode by default (remove this setting from
ACLOCAL_AMFLAGS in your Makefile.am files).  The default behaviour
is to use the files distributed with your package in preference to
newer versions that happen to be installed on user's systems.

I expect this also would avoid the "too many loops" problem.

> And then finally, there is actually a bug in the latest
> ax_code_coverage.m4 that quotes AC_MSG_ERROR() which causes older
> autoconf/automake versions to barf.
> https://github.com/c-ares/c-ares/commit/3883d99b05a845e4b40fc25c43ca83db70f4f20f#diff-fe38622a6c742be1bb93e6e65a0728f659114b3dc8d88172cb8844fa963418f9

The original quotation looks reasonable, so this change seems
questionable to me.  Probably there are real quotation bugs
somewhere else.

> I'm not sure where to report the last 2 issues.

For issues with the autoconf-archive macros, they have their own mailing
lists:

  https://savannah.gnu.org/mail/?group=autoconf-archive

Cheers,
  Nick