On 10/10/2010 08:19 PM, Gary V. Vaughan wrote:
The common way to get rid of these warnings is to insert an invocation of gl_USE_SYSTEM_EXTENSIONS at the appropriate place in configure.ac.Seems like a kludge to me. Either the AC_{RUN,COMPILE}_IFELSE using modules should AC_REQUIRE_ONCE([gl_USE_SYSTEM_EXTENSIONS]) themselves, or AC_{RUN, COMPILE}_IFELSE should invoke the require rather than the warning, no? And if that doesn't work, then AC_REQUIRE is not outputting macro expansions in the right order. What's the difference between AC_USE_SYSTEM_EXTENSIONS and gl_USE_SYSTEM_ EXTENSIONS? The warnings seem to indicate that adding AC_REQUIRE([AC_ USE_SYSTEM_EXTENSIONS]) to AC_{RUN,COMPILE}_IFELSE is the right solution.
AC_RUN_IFELSE must NOT require AC_USE_SYSTEM_EXTENSIONS - the whole point of having them as separate macros is that it MUST be possible to write a project that conforms to strict C89 and does not require the use of AC_USE_SYSTEM_EXTENSIONS. Rather, what needs to be fixed is the notion that _if_ you use AC_USE_SYSTEM_EXTENSIONS, then its use must precede AC_RUN_IFELSE. And right now, there is a known bug in AC_BEFORE (which is the mechanism for enforcing this order), which when that bug is fixed, starts failing the AC_USE_SYSTEM_EXTENSIONS testsuite in autoconf. Therefore, there is probably an upstream bug in autoconf's AC_USE_SYSTEM_EXTENSIONS that is not generating correctly ordered output.
-- Eric Blake [email protected] +1-801-349-2682 Libvirt virtualization library http://libvirt.org
