[Top][All Lists]

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

Re: How to enable to generate configure to must take argume

From: Eric Blake
Subject: Re: How to enable to generate configure to must take arguments ?
Date: Wed, 10 Mar 2010 13:50:40 -0700
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv: Gecko/20100301 Fedora/3.0.3-1.fc12 Lightning/1.0b1 Thunderbird/3.0.3

On 03/10/2010 01:35 PM, TJ Yang wrote:
> By default "./configure " will proceed to run itself and collect all
> the system information.
> I am thinking  of writing my own to generate configure to split 
> out
> the content of "--help"  or shoowing a usage message when there is no
> argument provided.

Why?  That violates the GNU Coding Standards - many developers have come
to expect configure to work without arguments, and your package would be
broken in their eyes.

> Following code in doesn't exit out right away when I type
> in "./configure"
> if test $#  ne $MYARGS

If you _absolutely_ must access $@ (or $*, $#), then your code to do so
must occur immediately after AC_INIT:

> then
>    echo "Need one argument at least.\n"
>    exit 0

Please don't.  If you are going to make configure exit without
completing, then at least exit with a non-zero status.

Eric Blake   address@hidden    +1-801-349-2682
Libvirt virtualization library

Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

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