Hello,
some time ago I noticed that autom4te calls m4 with stdin redirected
to /dev/null. The redirection was a hack to work around a problem
with CVS m4.
The bug was discussed here
http://lists.gnu.org/archive/html/m4-discuss/2006-04/threads.html
and resolved by Eric here
http://lists.gnu.org/archive/html/m4-patches/2006-09/msg00035.html
This allowed me to remove the hack from autom4te, see the attached
patch, which I committed.
Note:
This patch was one of the two pre-requisities for teaching autom4te
to handle `-' as a command line parameter.
The other one is to tell Automake/XFile.pm about `-' about it;
I'm not volunteering for that because of Perl. ;-)
The third step would be to tell the caching in autom4te that such
runs cannot be cached.
(And then we could implement `autoconf -'.)
Have a nice day,
Stepan Kasal
2006-10-24 Stepan Kasal <[EMAIL PROTECTED]>
* bin/autom4te.in (handle_m4): Do not redirect stdin to
/dev/null since the heuristics for interactive behaviour was
fixed in CVS m4.
Index: bin/autom4te.in
===================================================================
RCS file: /cvsroot/autoconf/autoconf/bin/autom4te.in,v
retrieving revision 1.103
diff -u -r1.103 autom4te.in
--- bin/autom4te.in 24 Oct 2006 15:57:57 -0000 1.103
+++ bin/autom4te.in 24 Oct 2006 18:10:54 -0000
@@ -454,8 +454,6 @@
# Run m4.
#
- # Neutralize its stdin, so that GNU M4 1.5 doesn't neutralize SIGINT.
- #
# We don't output directly to the cache files, to avoid problems
# when we are interrupted (that leaves corrupted files).
xsystem ("$m4"
@@ -465,7 +463,6 @@
. " @[EMAIL PROTECTED]" . $req->id . "t"
. join (' --trace=', '', sort @macro)
. " " . files_to_options (@ARGV)
- . ' </dev/null'
. " >$ocache" . $req->id . "t");
# Everything went ok: preserve the outputs.