Hey,
in the manual, one can read in
http://www.gnu.org/software/autoconf/manual/autoconf.html#Generic-Headers
"For each given system header file header-file in the blank-separated
argument list that exists, define HAVE_header-file (in all capitals). If
action-if-found is given, it is additional shell code to execute when one
of the header files is found. You can give it a value of `break' to break
out of the loop on the first match. If action-if-not-found is given, it is
executed when one of the header files is not found."
if I do that:
AC_CHECK_HEADERS([foo.h bar.h], [have_headers="yes"], [have_headers="no"])
So, 'action-if-found' and 'action-if-not-found' are given.
Now, suppose that foo.h exists, but bar.h does not.
According to the first part of the doc : "If action-if-found is given, it
is additional shell code to execute when one of the header files is
found.", as foo.h exists, have_headers="yes" is executed.
But according to the second part: "If action-if-not-found is given, it is
executed when one of the header files is not found", as bar.h does not
exist, have_headers="no" is executed...
I don't know the real behavior of AC_CHECK_HEADERS, but clearly, there is
a problem with the documentation.
Imho, the correct behavior woul be "if action-if-found is given, it is
additional shell code to execute when all the header files are found. If
action-if-not-found is given, it is executed when one of the header files
is not found"
am I wrong ?
Vincent Torri
_______________________________________________
Autoconf mailing list
Autoconf@xxxxxxx
http://lists.gnu.org/mailman/listinfo/autoconf