autoconf
[Top][All Lists]
Advanced

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

Re: Comma in AS_HELP_STRING string


From: Ralf Wildenhues
Subject: Re: Comma in AS_HELP_STRING string
Date: Wed, 14 Jun 2006 12:58:00 +0200
User-agent: Mutt/1.5.11

Hello Stepan, Jerry,

* Stepan Kasal wrote on Wed, Jun 14, 2006 at 11:46:37AM CEST:
> On Tue, Jun 13, 2006 at 11:36:40PM -0700, Micah J. Cowan wrote:
> > On Tue, Jun 13, 2006 at 08:17:01PM -0500, address@hidden wrote:
> > > AS_HELP_STRING([--with-wx=opt1,opt2], [specify 2 options separated by 
> > > comma])
> ...
> > Have you tried an extra set of []s?
> 
> this is known bug in AS_HELP_STRING.  Unfortunately, we have not
> managed to solve it for the upcming release, Autoconf 2.60.

I may come up with a patch to fix this, but as you said, it is probably
prudent to apply it only after 2.60.

> As a workaround you could try to add _three_ pairs of brackets:

No.  This advice is not only wrong, but it is also very bad advice.
Please do not teach users to blindly add brackets until some code
"appears" to work.  Such behavior ends up in huge amounts of legacy code
that stops to work when bugs are eventually fixed in Autoconf.  There
are historical precedents I've had the fun to debug, if you don't
believe me.

Jerry, for now just don't use AS_HELP_STRING at all, but pass a
preformatted string as second argument to AC_ARG_ENABLE:

AC_ARG_ENABLE([baz],
  [  --with-wx=opt1,opt2     specify 2 options separated by comma])])

This works, and will continue to work.

> (But I suppose that with 2.61 two or three of the bracket pairs will
> be displayed.  Nothing serious, just cosmetics.)

Gah.  People report bugs because of such behavior.  Come on, please do
not put off their expectation that output look sensible.

Cheers,
Ralf




reply via email to

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