[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
checking for headers presence even if usable
From: |
Karl Berry |
Subject: |
checking for headers presence even if usable |
Date: |
Mon, 21 Apr 2008 18:29:27 -0500 |
I'm not sure if this is really a bug, but I thought I'd mention it. It
seems that autoconf 2.62 checks headers for "presence" even if they are
already determined to have "usability". For instance, given this
configure.ac:
AC_INIT([foo], [4.12], address@hidden)
AC_CHECK_HEADER([stdio.h],
[AC_DEFINE([HAVE_STDIO_H], [1],
[Define to 1 if you have <stdio.h>.])],
[AC_MSG_ERROR([Sorry, can't do anything for you])])
AC_OUTPUT
autoconf && configure says (in part):
...
checking stdio.h usability... yes
checking stdio.h presence... yes
And looking at config.log, it seems both gcc and gcc -E are indeed being run.
I understand needing to check presence if usability fails, but surely if
it is usable, it is present? Can the presence check easily be omitted
if usability succeeds?
I started looking at this because someone (John Malmberg) who is working
on getting configure scripts working on VMS said that each such test is
depressingly expensive, and the "extra" presence tests can result in an
awful lot of wasted time. Anyway, aside from VMS that might be able to
speed up configure seems like a good thing in general.
Just thought I'd write FWIW. Sorry if it's a known topic already.
Thanks,
karl
- checking for headers presence even if usable,
Karl Berry <=