[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: FYI: remove documentation for AU_DEFUN's third parameter
From: |
Paolo Bonzini |
Subject: |
Re: FYI: remove documentation for AU_DEFUN's third parameter |
Date: |
Tue, 25 Nov 2003 09:47:49 +0100 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.5) Gecko/20031020 Debian/1.5-1 |
I believe that your patch leaves warning in the updated file. That
was not the goal: the goal is to issue a warning until the macro is
updated. Some macros need work by hand, and in that case you put the
warning as part of the macro update itself, to force the user to go
and edit her code by hand.
I have not found macros that actually need work by hand. Most of them,
like AC_MEMORY_H, need updating because of outdated idioms such as the
NEED_MEMORY_H symbol. In this respect, AC_LINK_FILES (which was the
only macro that still used the three argument AU_DEFUN) is not any
different.
Leaving the warning in the updated file has the advantage of reminding
the Autoconf user if they invoke autoconf with warnings enabled.
AU_DEFINE does not use its $3 certainly because it was listened to via
traces.
I see.
The patch should be reverted.
I will certainly revert it, but I'd like to propose another fix: running
"autoconf -W obsolete" at the end of autoupdate (see the attached two-line
patch). If you have a suggestion on how to combine this with the final m4
run, please tell me because I could not do it.
Paolo
Index: bin/autoupdate.in
===================================================================
RCS file: /cvsroot/autoconf/autoconf/bin/autoupdate.in,v
retrieving revision 1.48
diff -u -r1.48 autoupdate.in
--- bin/autoupdate.in 27 Aug 2003 11:35:09 -0000 1.48
+++ bin/autoupdate.in 25 Nov 2003 08:39:48 -0000
@@ -403,6 +403,9 @@
. " $tmp/input.m4 >$tmp/updated");
update_file ("$tmp/updated",
"$file" eq "$tmp/stdin" ? '-' : "$file");
+
+ # And ask autoconf to show the warnings.
+ xsystem ("$autoconf --output=/dev/null -W obsolete $file");
}
exit 0;