bug-autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: 2.53a m4sh.at:74 failure


From: Patrick Welche
Subject: Re: 2.53a m4sh.at:74 failure
Date: Thu, 25 Apr 2002 18:37:48 +0100
User-agent: Mutt/1.3.19i

% ./testsuite -k lineno
## ------------------------------ ##
## GNU Autoconf 2.53b test suite. ##
## ------------------------------ ##
 15: m4sh.at:29        ok
## ---------------------------- ##
## All 1 tests were successful. ##
## ---------------------------- ##

with your patch :)

and
% diff test-1 test-1.t
246c246
< echo "Line: $LINENO"
---
> echo "Line: DOLLAR_LINENO"
% cd ..
% diff test-1.lineno test/test-1
...
246c246
< echo "Line: 246"
---
> echo "Line: $LINENO"


so it works.

Thank you!

Patrick

On Thu, Apr 25, 2002 at 07:27:52PM +0200, Akim Demaille wrote:
> 
> Here is my pre-proposal.  I still have to adjust the comments, make
> the ChangeLog etc.
> 
> Index: tests/m4sh.at
> ===================================================================
> RCS file: /cvsroot/autoconf/autoconf/tests/m4sh.at,v
> retrieving revision 1.33
> diff -u -u -r1.33 m4sh.at
> --- tests/m4sh.at 22 Apr 2002 12:18:36 -0000 1.33
> +++ tests/m4sh.at 25 Apr 2002 17:27:14 -0000
> @@ -42,13 +42,13 @@
>  #
>  # Use COUNTER, COUNTER-RE = [$@&address@hidden,   [LINENO]
>  #  or                     = [__@&address@hidden, [_oline__]
> -# to make sure we are not replace in the test suite itself and to avoid
> +# to make sure we are not replaced in the test suite itself and to avoid
>  # seeing the COUNTER-RE being replaced.
>  #
>  # UNSET-LINENO is a shell condition to make sure the scripts have the
>  # same number of lines in the output, so that their outputs be identical.
>  m4_define([AT_DATA_LINENO],
> -[AT_DATA([$1],
> +[AT_DATA([$1.as],
>  [[AS@&address@hidden
>  if $2; then
>    AS@&address@hidden([LINENO])
> @@ -59,13 +59,16 @@
>    AS@&address@hidden([cannot find original script])
>  exit 0
>  ]])
> +AT_CHECK([autom4te -l m4sh $1.as -o $1.t])
> +# If an occurrence of $LINENO was wanted, create it.
> +sed 's/DOLLAR_LINENO/$''LINENO/g' $1.t >$1
> +chmod +x $1
>  ])# AT_DATA_LINENO
>  
>  # `_oline_', once processed and ran, produces our reference.
>  # We check that we find ourselves by looking at a string which is
>  # available only in the original script: `_oline_'.
> -AT_DATA_LINENO([reference.as], [false], [__@&address@hidden, [_oline__])
> -AT_CHECK([autom4te -l m4sh reference.as -o reference])
> +AT_DATA_LINENO([reference], [false], [__@&address@hidden, [_oline__])
>  AT_CHECK([./reference], 0, [stdout])
>  
>  # The reference:
> @@ -75,16 +78,14 @@
>  # Be sure to be out of the PATH.
>  AT_CHECK([mkdir test || exit 77])
>  
> -AT_DATA_LINENO([test/test-1.as], [false], [$@&address@hidden, [LINENO])
> -AT_CHECK([autom4te -l m4sh test/test-1.as -o test/test-1])
> +AT_DATA_LINENO([test/test-1], [false], [DOLLAR_LINENO], [LINENO])
>  AT_CHECK([./test/test-1],                          0, [expout])
>  AT_CHECK([(PATH=test$PATH_SEPARATOR$PATH; export PATH; exec test-1)],
>                                                  0, [expout])
>  AT_CHECK([sh ./test/test-1],                       0, [expout])
>  
>  # Now using a disabled LINENO, with different call conventions.
> -AT_DATA_LINENO([test/test-2.as], [true], [$@&address@hidden, [LINENO])
> -AT_CHECK([autom4te -l m4sh test/test-2.as -o test/test-2])
> +AT_DATA_LINENO([test/test-2], [true], [DOLLAR_LINENO], [LINENO])
>  AT_CHECK([./test/test-2],                          0, [expout])
>  AT_CHECK([(PATH=test$PATH_SEPARATOR$PATH; export PATH; exec test-2)],
>                                                  0, [expout])



reply via email to

[Prev in Thread] Current Thread [Next in Thread]