autoconf
[Top][All Lists]
Advanced

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

How to prevent warning "The macro `AC_PROG_CC_C99' is obsolete"


From: R. Diez
Subject: How to prevent warning "The macro `AC_PROG_CC_C99' is obsolete"
Date: Sat, 18 Jun 2022 16:57:10 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1

Hi all:

Macro AC_PROG_CC_C99 is obsolete as of Autoconf version 2.70 . Projects like 
OpenOCD are resorting to this kind of workaround:

m4_version_prereq([2.70],[],[AC_PROG_CC_C99])

You can see it here:

https://sourceforge.net/p/openocd/code/ci/master/tree/configure.ac


Other projects are doing similar things, see for example the discussion here:

https://gitlab.torproject.org/tpo/core/tor/-/merge_requests/355

The interesting statement there is:

"neither including AC_PROG_CC_C99 macro nor leaving it out will give you the right 
behavior with both [Autoconf 2.69 and 2.70] versions"


The trouble is, with the m4_version_prereq solution mentioned above, I am still 
getting the following warning, at least with OpenOCD and Autoconf 2.71:

configure.ac:38: warning: The macro `AC_PROG_CC_C99' is obsolete.
configure.ac:38: You should run autoupdate.
/home/rdiez/[...blah blah...]/autoconf/c.m4:1659: AC_PROG_CC_C99 is expanded 
from...
configure.ac:38: the top level

I am no Autoconf guru. Is there a way to conditionally use AC_PROG_CC_C99 so that it does 
not generate such an "obsolete" warning? Many systems are still using Autoconf 
2.69, and will probably continue to do so for quite some time.

Thanks in advance,
  rdiez


reply via email to

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