Re: [PATCH] {maint} Document in detail some limitations of aclocal. (was: Re: Strangeness with m4_include and aclocal.)

2010-11-04 Thread Nick Bowler
On 2010-11-04 20:47 +0100, Stefano Lattarini wrote:
> On Thursday 28 October 2010, Stefano Lattarini wrote:
> > On Wednesday 27 October 2010, Nick Bowler wrote:
> > > On 2010-10-23 15:23 +0200, Stefano Lattarini wrote:
> > > > So I think your first problem is "just" an aclocal limitation we should
> > > > resign to live with.  But I also think that such a limitation should be
> > > > documented explicitly, since it's by no means obvious.
> > > 
> > > It's especially non-obvious because the other autotools handle this just
> > > fine.
> > Agreed.
> I've gone ahead and documented this non-obvious limitation, and another
> similar one regarding AC_DEFUN.  See the attached patch.
> 
> Ralf, ok to apply to maint?
> 
> Nick, the attached patch also adds your name and e-mail address to the
> automake THANKS file; do you have any problem with that?

No problem.  I have a couple comments, however:

> -*-*-*-
> 
> Document in detail some limitations of aclocal.
[...]
> +...@example
> +## Let's see an @command{aclocal} limitation w.r.t.@: scanning
> +## of macro definitons.
> +$ @kbd{cat m4/foo.m4}
> +# Indirection used here, to avoid triggering the bug described
> +# above.
> +AC_DEFUN([MY_DEFUN], [m4_apply([AC_DEFUN], [$1], [$2])])

This is insufficiently quoted, it should be:
[m4_apply([AC_DEFUN], [[$1], [$2]])]

[...]
> +These limitations might be lifted in a future version of
> +...@command{aclocal}, but then again, they might not, so you
> +should be preperated to live with them.
 ^^
 prepared

[...]
> +++ b/tests/aclocal-limit-defun.test
[...]
> +cat > m4/foo.m4 <<'END'
> +AC_DEFUN([MY_DEFUN], [m4_apply([AC_DEFUN], [$1], [$2])])

Same quoting issue as above.

-- 
Nick Bowler, Elliptic Technologies (http://www.elliptictech.com/)



[PATCH] {maint} Document in detail some limitations of aclocal. (was: Re: Strangeness with m4_include and aclocal.)

2010-11-04 Thread Stefano Lattarini
On Thursday 28 October 2010, Stefano Lattarini wrote:
> On Wednesday 27 October 2010, Nick Bowler wrote:
> > On 2010-10-23 15:23 +0200, Stefano Lattarini wrote:
> > > So I think your first problem is "just" an aclocal limitation we should
> > > resign to live with.  But I also think that such a limitation should be
> > > documented explicitly, since it's by no means obvious.
> > 
> > It's especially non-obvious because the other autotools handle this just
> > fine.
> Agreed.
I've gone ahead and documented this non-obvious limitation, and another
similar one regarding AC_DEFUN.  See the attached patch.

Ralf, ok to apply to maint?

Nick, the attached patch also adds your name and e-mail address to the
automake THANKS file; do you have any problem with that?

Regards,
   Stefano

-*-*-*-

Document in detail some limitations of aclocal.

* doc/automake.texi (Limitations of aclocal): New section.
* tests/aclocal-limit-defun.test: New test, checking that the
aclocal limitation(s) exposed in the newly added manual section
does really hold.
* tests/aclocal-limit-include.test: Likewise.
* tests/Makefile.am (TESTS): Updated.
* .gitignore: Updated.
* THANKS: Updated.

From a report by Nick Bowler.
---
 ChangeLog|   13 +
 THANKS   |1 +
 doc/automake.texi|   95 ++
 tests/.gitignore |4 +-
 tests/Makefile.am|2 +
 tests/Makefile.in|2 +
 tests/aclocal-limit-defun.test   |   83 +
 tests/aclocal-limit-include.test |   88 +++
 8 files changed, 286 insertions(+), 2 deletions(-)
 create mode 100644 tests/aclocal-limit-defun.test
 create mode 100644 tests/aclocal-limit-include.test
From 9c4a6898f2b0119fdaff7e794a2b09372a83de78 Mon Sep 17 00:00:00 2001
From: Stefano Lattarini 
Date: Thu, 4 Nov 2010 20:12:59 +0100
Subject: [PATCH] Document in detail some limitations of aclocal.

* doc/automake.texi (Limitations of aclocal): New section.
* tests/aclocal-limit-defun.test: New test, checking that the
aclocal limitation(s) exposed in the newly added manual section
does really hold.
* tests/aclocal-limit-include.test: Likewise.
* tests/Makefile.am (TESTS): Updated.
* .gitignore: Updated.
* THANKS: Updated.

From a report by Nick Bowler.
---
 ChangeLog|   13 +
 THANKS   |1 +
 doc/automake.texi|   95 ++
 tests/.gitignore |4 +-
 tests/Makefile.am|2 +
 tests/Makefile.in|2 +
 tests/aclocal-limit-defun.test   |   83 +
 tests/aclocal-limit-include.test |   88 +++
 8 files changed, 286 insertions(+), 2 deletions(-)
 create mode 100644 tests/aclocal-limit-defun.test
 create mode 100644 tests/aclocal-limit-include.test

diff --git a/ChangeLog b/ChangeLog
index 18c5ff6..2f4ba06 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,16 @@
+2010-11-04  Stefano Lattarini  
+
+	Document in detail some limitations of aclocal.
+	* doc/automake.texi (Limitations of aclocal): New section.
+	* tests/aclocal-limit-defun.test: New test, checking that the
+	aclocal limitation(s) exposed in the newly added manual section
+	does really hold.
+	* tests/aclocal-limit-include.test: Likewise.
+	* tests/Makefile.am (TESTS): Updated.
+	* .gitignore: Updated.
+	* THANKS: Updated.
+	From a report by Nick Bowler.
+
 2010-11-01  Ralf Wildenhues  
 
 	Add FAQ entry for bug reporting instructions.
diff --git a/THANKS b/THANKS
index 78da1de..1869d14 100644
--- a/THANKS
+++ b/THANKS
@@ -240,6 +240,7 @@ Motoyuki Kasahara	m-kas...@sra.co.jp
 Nathanael Nerode	nero...@twcny.rr.com
 Nelson H. F. Beebe	be...@math.utah.edu
 Nicholas Wourms		nwou...@netscape.net
+Nick Bowler		nbow...@elliptictech.com
 Nicolas Joly		nj...@pasteur.fr
 Nicolas Thiery		nthi...@icare.mines.edu
 NightStrike		nightstr...@gmail.com
diff --git a/doc/automake.texi b/doc/automake.texi
index b75c7a5..ce1617f 100644
--- a/doc/automake.texi
+++ b/doc/automake.texi
@@ -188,6 +188,7 @@ Auto-generating aclocal.m4
 * Extending aclocal::   Writing your own aclocal macros
 * Local Macros::Organizing local macros
 * Serials:: Serial lines in Autoconf macros
+* Limitations of aclocal::  Some warts and limitations of aclocal
 * Future of aclocal::   aclocal's scheduled death
 
 Autoconf macros supplied with Automake
@@ -3099,6 +3100,7 @@ overridden using the @env{AUTOM4TE} environment variable.
 * Extending aclocal::   Writing your own aclocal macros
 * Local Macros::Organizing local macros
 * Serials:: Serial lines in Autoconf macros
+* Limitations of aclocal::  Some warts and limitations of aclocal
 * Future of aclocal::   aclocal's scheduled death
 @end men