On Thu, 18 Jan 2024 13:59:30 GMT, Erik Joelsson <er...@openjdk.org> wrote:

> > What fun, I just found out that omitting the call to AC_PROG_CC and 
> > AC_PROG_CXX has no effect, and they're _still_ called magically from 
> > somewhere by autoconf even if you don't call them. I'm genuinely at a loss 
> > for words :)
> 
> If I'm to guess, I think this is caused by AC_PROG_* being defined as 
> AC_DEFUN_ONCE and every other autoconf macro that uses compilers for checks 
> will implicitly call AC_PROG_* first if it hasn't been called yet. My 
> understanding of these implicit calls is to make a more declarative 
> programming style possible.

It's not so much the AC_DEFUN_ONCE, but actually due to other autoconf macros 
calling AC_REQUIRE([AC_PROG_CC]) and AC_REQUIRE([AC_PROG_CXX]), for instance 
our calls to AC_PROG_CPP and AC_PROG_CXXCPP will cause AC_PROG_CC and 
AC_PROG_CXX respectively to be implicitly called

-------------

PR Comment: https://git.openjdk.org/jdk/pull/17401#issuecomment-1898554535

Reply via email to