autoconf-patches
[Top][All Lists]
Advanced

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

Re: [PATCH 2/3] Add and document AS_ME_PREPARE and AS_LINENO_PREPARE


From: Eric Blake
Subject: Re: [PATCH 2/3] Add and document AS_ME_PREPARE and AS_LINENO_PREPARE
Date: Fri, 10 Oct 2008 23:15:12 +0000 (UTC)
User-agent: Loom/3.14 (http://gmane.org/)

Paolo Bonzini <bonzini <at> gnu.org> writes:

> 
> This patch documents $as_me and $LINENO, which are the sole constructs
> (for now) that explicitly require a *_PREPARE macro because they are
> variables.  So those are defined without the hyphen and documented.
> 

OK to apply, after addressing these nits.

Add a NEWS item mentioning the new macros.

> 
> address@hidden AS_LINENO_PREPARE
> address@hidden
> +Find a shell that supports the special variable @code{$LINENO}, which
> +contains the number of the currently executing line.
> address@hidden defmac

I would consider writing this as @env{LINENO} rather than @code{$LINENO}.  
Also, add @evindex LINENO.  And it may be worth a mention that configure 
scripts have already done AS_{LINENO,ME}_PREPARE (these macros are only needed 
for third-party m4sh scripts that don't use the undocumented AS_PREPARE, and 
which don't use other m4sh features that pull in these two variables).

> +
> address@hidden AS_ME_PREPARE
> address@hidden
> +Set up variable @code{$as_me} to be the name of the currently executing
> +script.
> address@hidden defmac

I would mention that it is the basename (not the complete $0), but am not quite 
sure of the best wording to use for that.  Add @evindex as_me.

> +M4sh, and hence Autoconf, attempts to execute @command{configure} with
> +a shell that supports @code{LINENO}.  If no such shell is available, it
> +attempts to implement @code{LINENO} with a Sed prepass that replaces each
> +instance of the string @code{$LINENO} (not followed by an alphanumeric
> +character) with the line's number.  In M4sh scripts you should execute
> address@hidden so that these workarounds are included in
> +your script.

Worth another mention that configure does this automatically?

> 
> -dnl Delay this until after shell functions are defined.
> -AS_REQUIRE([_AS_ME_PREPARE])
> -

Looks like you sent this mail before rebasing (shouldn't be a problem, though).

-- 
Eric Blake






reply via email to

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